#!/home/soroush/gnuplot/bin/gnuplot -persist

set encoding iso_8859_1
set terminal postscript portrait enhanced color dashed lw 1.5 font 'Arial-Bold, 25'
set output "Figure_2_9.ps"
set size 4,2.5
set size ratio 0.33
set origin 0,0
set key autotitle columnhead font 'Arial-Bold,25' out horiz top
set label 1 '(a)' at screen 2.73,1.70 font 'Arial-Bold 25'
set label 2 '(b)' at screen 3.75,1.70 font 'Arial-Bold 25'
set label 3 '(c)' at screen 2.83,0.84 font 'Arial-Bold 25'
set label 4 '(d)' at screen 3.75,0.84 font 'Arial-Bold 25'

set multiplot layout 4,2






set key autotitle columnhead font 'Arial-Bold,25' out horiz right top
set ylabel 'DOS' font 'Arial-Bold, 25'
set tics font 'Arial-Bold,25'
set border lw 1.5
unset logscale y
set grid
set grid lc rgb '#D3D3D3'  lw 0.5


unset key
unset title
set size 3,1
set origin 0,0.0
set xrange [ 0.0 : 4000 ]
set ylabel  'DOS ' font 'Arial-Bold, 25' offset +1.5
set xlabel  'Frequency (cm^{-1}) ' font 'Arial-Bold, 25' offset +1.5
set yrange[0:9]
unset arrow
set arrow from 3208, graph 0 to 3208, graph 1 nohead lw 2 lc rgb 'black' 
plot "Figure_2_9_1.txt" using 1:2 with lines lw 2 lc rgb 'red', "" using 1:3 with lines lw 2 lc rgb 'black',"" using 1:4 with lines lw 2 lc rgb 'blue'


unset key
set size 3,1
set origin 0.0,0.87

set xrange [ 0.0 : 4000 ]

set ylabel 'DOS' font 'Arial-Bold, 25' offset +1.5
set xlabel 'Frequency (cm^{-1})' font 'Arial-Bold, 25' offset +1.5
set yrange[0:9]
unset arrow
set arrow from 3208, graph 0 to 3208, graph 1 nohead lw 2 lc rgb 'black' 
plot "Figure_2_9_2.txt" using 1:2 with lines lw 2 lc rgb 'red', "" using 1:3 with lines lw 2 lc rgb 'black', "" using 1:4 with lines lw 2 lc rgb 'blue'

unset yrange
unset xrange
set xrange [258.82/12:328.6/12]
set size ratio 1
unset ylabel
set xtics  nomirror 0,22/12,600
set ytics 0.05

set size 0.7,0.7
set origin 3.1,0
set border 1+2+8
set ylabel 'U(V)(eV)' font 'Arial-Bold, 25' offset +1.5
set xlabel  'Volume ({\305}^3/H_2O)' font 'Arial-Bold, 23' offset +1.5
set yrange [ -0.02 : 0.2 ]
unset arrow
set arrow from 24.288, graph 0 to 24.288, graph 1 nohead lw 2
plot "Figure_2_9_3.txt" using ($1/12):($2+7.2459) with lines lw 2 lc rgb "#90EE90"

#unset xrange
set yrange [ 8.9 : 9.1 ]
unset xtics
unset xlabel
set x2tics  nomirror 0,22/12,600
set border 2+4+8
set size 0.7,0.75
set origin 3.1,0.35
set ylabel 'F(V,T=0)(eV)' font 'Arial-Bold, 25' offset +1.5
unset arrow
set arrow from 25.2591, graph 0 to 25.2591, graph 1 nohead lw 2
plot "Figure_2_9_3.txt" using ($1/12):($3+7.2459) with lines lw 2 lc rgb "#006320"

###
set ytics
set xtics  nomirror 0,22/12,600

unset x2tics

set xlabel
set border 1+2+8

set size 0.7,0.7
set origin 3.1,0.86
set ylabel 'U(V)(eV)' font 'Arial-Bold, 25' offset +1.5
set xlabel 'Volume ({\305}^3/H_2O) ' font 'Arial-Bold, 23' offset +1.5
unset yrange
set yrange [ -0.02 :0.2  ]
unset arrow
set arrow from 291.89/12, graph 0 to 291.89/12, graph 1 nohead lw 2
plot "Figure_2_9_4.txt" using ($1/12):($2+7.2323) with lines lw 2 lc rgb "#90EE90"

unset xtics
unset xlabel
set x2tics  nomirror 0,22/12,600
set border 2+4+8
set size 0.7,0.7
set origin 3.1,1.24
set yrange [ 9.3 : 9.5 ]
set ylabel 'F(V,T=0)(eV)' font 'Arial-Bold, 25' offset +1.5
unset arrow
set arrow from 309.304/12, graph 0 to 309.304/12, graph 1 nohead lw 2
plot "Figure_2_9_4.txt"  using ($1/12):($3+7.2323) with lines lw 2 lc rgb "#006320"

set size 2.5,0.1
set origin 1.1,0.84
set key outside horizontal
set border 0
unset title
unset tics
unset xlabel
unset ylabel
set yrange [0:0.001]
set xrange [0:0.001]
plot "Figure_2_9_1.txt" using 1:2 with lines lw 3 lc rgb 'red', "" using 1:3 with lines lw 3 lc rgb 'black',"" using 1:4 with lines lw 3 lc rgb 'blue'

set size 2.9,0.1
set origin 1.2,1.7
set key outside horizontal
set border 0
unset title
unset tics
unset xlabel

unset ylabel
set yrange [0:0.001]
set xrange [0:0.001]

plot "Figure_2_9_2.txt" using 1:2 with lines lw 3 lc rgb 'red', "" using 1:3 with lines lw 3 lc rgb 'black',"" using 1:4 with lines lw 3 lc rgb 'blue'


unset multiplot


