Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F76934242
sum.pl
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Sun, Aug 11, 07:09
Size
451 B
Mime Type
text/x-perl
Expires
Tue, Aug 13, 07:09 (2 d)
Engine
blob
Format
Raw Data
Handle
19768941
Attached To
rLAMMPS lammps
sum.pl
View Options
#!/usr/bin/perl
# This script will take a .vol file created by voro++, and it will sum up the
# volumes of all the Voronoi cells. In many cases, this will equal the volume
# of the container, and it can be a useful check.
#
# It assumes that the volume is stored in the final column, so it works with
# both regular and polydisperse calculations.
open A,"@ARGV[0]" or die "Can't open input file";
while(<A>) {
@A=split;
$c+=pop @A;
}
print "$c\n";
Event Timeline
Log In to Comment