Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F88139629
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
Thu, Oct 17, 00:41
Size
451 B
Mime Type
text/x-perl
Expires
Sat, Oct 19, 00:41 (2 d)
Engine
blob
Format
Raw Data
Handle
21713183
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