unset multiplot set term pdf fontscale 0.6 size 4.95in,3.3in norm=0 if(norm == 0){outfile = 'compiled_vparam_-2mrad_G.pdf'} if(norm == 1){outfile = 'compiled_vparam_-2mrad_norm.pdf'} set output outfile column1 = 11 # kicker 1 set timestamp offset graph 1.04,0.7 rotate font 'Verdana,6' set label 'plotting_scripts/compile_vparam_-2mrad.gnu' at graph 1.02,0.02 rotate left font 'Verdana,6' noenhance nturns = 10000 set yrange [0:3] set ylabel "captured [%]" set xlabel 'kick [G]' if(norm == 1){set xlabel 'Bumlein voltage [arb]'} set label at graph 0.05,0.95 'Inflector tilt = -2 mrad' font ',10' set label at graph 0.05,0.91 'Injection angle = -2 mrad' font ',10' dir1 = 'Ge' N=2 dir1= 'Cm' f1='Cm:CapMatch+2sections' subdir1='/20180515_072246' subdir1='/20180518_071011' dir2 = 'Db' f2='Db:+2sections' subdir2='/20180515_072356' subdir2='/20180518_071136' dir3 = 'Ge' f3 = 'Ge:PerfectMatch' subdir3='/20180515_072502' subdir3='/20180518_110013' dir4 = 'Ir' f4 = 'Ir:AsBuilt' subdir4='/20180515_072545' subdir4='/20180518_105841' dir5 ='Nb' f5 = 'Nb:CapMatch' subdir5='/20180515_102045' subdir5='/20180518_110225' dir6='Pr' f6='Pr:CapMatch+3sections' subdir6='/20180515_102117' subdir6='/20180518_110747' dir7='Ru' f7='Ru:StaggerCabLengths' subdir7='/20180515_102149' subdir7='/20180518_111127' dir8='Sn' f8='Sn:FourKickPlates' subdir8='/20180517_144008' subdir8='/20180518_114330' dir9='Zr' f9='Zr:+4sections' subdir9='/20180514_145259' subdir9='/20180518_111813' Cm = 228.59 Db=201.95 Ge=216.94 Ir=194.62 Nb=226.11 Pr=228.53 Ru=194.63 Sn=197.99 Zr=204.92 if(norm == 0){Cm=1.;Db=1.;Ge=1.;Ir=1.;Nb=1.;Pr=1.;Ru=1.;Sn=1.;Zr=1.} filename1 = dir1.subdir1.'/VparamDependence.dat' filename2 = dir2.subdir2.'/VparamDependence.dat' filename3 = dir3.subdir3.'/VparamDependence.dat' filename4 = dir4.subdir4.'/VparamDependence.dat' filename5 = dir5.subdir5.'/VparamDependence.dat' filename6 = dir6.subdir6.'/VparamDependence.dat' filename7 = dir7.subdir7.'/VparamDependence.dat' filename8 = dir8.subdir8.'/VparamDependence.dat' filename9 = dir9.subdir9.'/VparamDependence.dat' set key top right Left font ',8' if(norm == 1){set xrange [0.4:2.4] set xtics 0.4,0.2} if(norm == 0){set xrange [100:450]} #plot for [i=1:N] u ($11*10000):($16*100/$14) w p ps 0.5 pt 5 t dir(i) plot filename1 u ($19/Cm):($16*100/$14) w lp ps 0.5 pt 5 t f1,\ filename2 u ($19/Db):($16*100/$14) w lp ps 0.5 pt 5 t f2,\ filename3 u ($19/Ge):($16*100/$14) w lp ps 0.5 pt 5 t f3,\ filename4 u ($19/Ir):($16*100/$14) w lp ps 0.5 pt 5 t f4,\ filename5 u ($19/Nb):($16*100/$14) w lp ps 0.5 pt 5 t f5,\ filename6 u ($19/Pr):($16*100/$14) w lp ps 0.5 pt 5 t f6,\ filename7 u ($19/Ru):($16*100/$14) w lp ps 0.5 pt 5 t f7,\ filename8 u ($19/Sn):($16*100/$14) w lp ps 0.5 pt 5 t f8,\ filename9 u ($19/Zr):($16*100/$14) w lp ps 0.5 pt 6 t f9 reset set autoscale y if(norm == 0){set xlabel 'kick [G]' set xrange [100:450]} if(norm == 1){set xlabel 'Bumlein voltage [arb]' set xrange [0.4:2.4] set xtics 0.4,0.2} set ylabel "{/Symbol s}_p [%]" set label at graph 0.1,0.95 'Inflector tilt = -2 mrad, Injection angle = -2 mrad' set key Left left bottom font ',8' plot filename1 u ($19/Cm):($13*100) w lp ps 0.5 pt 5 t f1,\ filename2 u ($19/Db):($13*100) w lp ps 0.5 pt 5 t f2,\ filename3 u ($19/Ge):($13*100) w lp ps 0.5 pt 5 t f3,\ filename4 u ($19/Ir):($13*100) w lp ps 0.5 pt 5 t f4,\ filename5 u ($19/Nb):($13*100) w lp ps 0.5 pt 5 t f5,\ filename6 u ($19/Pr):($13*100) w lp ps 0.5 pt 5 t f6,\ filename7 u ($19/Ru):($13*100) w lp ps 0.5 pt 5 t f7,\ filename8 u ($19/Sn):($13*100) w lp ps 0.5 pt 5 t f8,\ filename9 u ($19/Zr):($13*100) w lp ps 0.5 pt 6 t f9 reset set autoscale y if(norm == 0){set xlabel 'kick [G]' set xrange [100:450]} if(norm == 1){set xlabel 'Bumlein voltage [arb]' set xrange [0.4:2.4] set xtics 0.4,0.2} set label at graph 0.1,0.95 'Inflector tilt = -2 mrad, Injection angle = -2 mrad' font ',10' set ylabel "<{/Symbol D}p/p> [%]" set key left Left bottom font ',8' plot filename1 u ($19/Cm):($35*100) w lp ps 0.5 pt 5 t f1,\ filename2 u ($19/Db):($35*100) w lp ps 0.5 pt 5 t f2,\ filename3 u ($19/Ge):($35*100) w lp ps 0.5 pt 5 t f3,\ filename4 u ($19/Ir):($35*100) w lp ps 0.5 pt 5 t f4,\ filename5 u ($19/Nb):($35*100) w lp ps 0.5 pt 5 t f5,\ filename6 u ($19/Pr):($35*100) w lp ps 0.5 pt 5 t f6,\ filename7 u ($19/Ru):($35*100) w lp ps 0.5 pt 5 t f7,\ filename8 u ($19/Sn):($35*100) w lp ps 0.5 pt 5 t f8,\ filename9 u ($19/Zr):($35*100) w lp ps 0.5 pt 6 t f9 reset if(norm == 0){set xlabel 'kick [G]' set xrange [100:450]} if(norm == 1){set xlabel 'Bumlein voltage [arb]' set xrange [0.4:2.4] set xtics 0.4,0.2} set ylabel "CBO p-p [mm]" set key right Left bottom font ',8' set label at graph 0.1,0.95 'Inflector tilt = -2 mrad, Injection angle = -2 mrad' plot filename1 u ($19/Cm):($4) w lp ps 0.5 pt 5 t f1,\ filename2 u ($19/Db):($4) w lp ps 0.5 pt 5 t f2,\ filename3 u ($19/Ge):($4) w lp ps 0.5 pt 5 t f3,\ filename4 u ($19/Ir):($4) w lp ps 0.5 pt 5 t f4,\ filename5 u ($19/Nb):($4) w lp ps 0.5 pt 5 t f5,\ filename6 u ($19/Pr):($4) w lp ps 0.5 pt 5 t f6,\ filename7 u ($19/Ru):($4) w lp ps 0.5 pt 5 t f7,\ filename8 u ($19/Sn):($4) w lp ps 0.5 pt 5 t f8,\ filename9 u ($19/Zr):($4) w lp ps 0.5 pt 6 t f9 print outfile