2 # This script takes a .vol file that has neighbor information created with
3 # the custom output string "%i %q %v %n", and creates a map of the network, by
4 # drawing a line between all particles which are neighbors
6 open A
,"@ARGV[0].vol" or die "Can't open input file";
7 open B
,">@ARGV[0].net" or die "Can't open output file";
18 $l[$n][$_-5]=@A[$_] foreach 5..$#A;
22 foreach $n (1..$maxn) {
25 print B
"$x[$j] $y[$j] $z[$j]\n$x[$n] $y[$n] $z[$n]\n\n\n" if $j>=$n;