#!/usr/bin/perl
#

$cmdfile = "plot.cmd";
$plotfile = "thin_thermal.png";

open(CMDFILE, ">$cmdfile") || die("can't open command file");

printf CMDFILE "set term png color med\n";
printf CMDFILE "set output '$plotfile' \n";

printf CMDFILE "set grid \n";
printf CMDFILE "set key bot right \n";
printf CMDFILE "plot [6562:6564][-0.1:1.1] ";
#printf CMDFILE "  'thin_thermal_0_1.out' using 1:3 t 'tau = 0.1' with linespoints ps 0.3  ";
#printf CMDFILE " , 'thin_thermal_0_2.out' using 1:3 t 'tau = 0.2' with linespoints ps 0.3  ";
#printf CMDFILE " , ";
# printf CMDFILE " 'thin_thermal_0_4.out' using 1:3 t 'tau 0.4' with linespoints ps 0.3  ";
#printf CMDFILE " 'thin_thermal_0_8.out' using 1:3 t 'tau 0.8' with linespoints ps 0.3  ";
#printf CMDFILE " , 'thin_thermal_1_6.out' using 1:3 t 'tau 1.6' with linespoints ps 0.3  ";
#printf CMDFILE " 'thin_thermal_6_4.out' using 1:3 t 'tau 6.4' with linespoints ps 0.3  ";
printf CMDFILE " 'thin_thermal_6_4.out' using 1:3 t '6.4' with linespoints ps 0.3  ";
printf CMDFILE " , 'thin_thermal_20.out' using 1:3 t '20' with linespoints ps 0.3  ";
printf CMDFILE " , 'thin_thermal_40.out' using 1:3 t '40' with linespoints ps 0.3  ";
printf CMDFILE " , 'thin_thermal_80.out' using 1:3 t '80' with linespoints ps 0.3  ";

printf CMDFILE "\n";

printf CMDFILE "set output \n";

close(CMDFILE);

$cmd = "gnuplot $cmdfile ";
$ret = `$cmd`;



exit 0;
