open(F,">ncd(natural.gz).csv");
for($x=1;$x<=20;$x++){
    for($y=1;$y<=20;$y++){
	$a = -s "./momotxt/momo$x.txt.gz";
	$b = -s "./momotxt/momo$y.txt.gz";
	$c = -s "./momotxt/momo[$x][$y].txt.gz";
	if ( $a >= $b ){
	    $ncd=($c-$b)/$a;
	}else{
	    $ncd=($c-$a)/$b;
	}
	printf F ("\"%6f\"",$ncd);
	if($y!=20){print F ",";}
    }
    print F "\n";
}
