#!/usr/bin/gnuplot set terminal postscript eps color enhanced solid font "Helvetica,22" size 12.6cm,8cm set output "../refl_sat.eps" #set output "tx_refl.eps" set border linewidth 1.5 set border 3 #f1 = '2016-07-05/tx_2016_07_05' #f1 = '2016-07-18/2016-07-18' #f1 = '2016-07-19/2016-07-19' f1 = '2016-07-22_sat_curve_4us' #f2='2016-07-05/sat_spec_2016_07_05' #f2='2016-07-17_sat_refl/2016-07-17_sat_refl' f2 = '2016-07-22_refl' set samples 5000 set multiplot set bar 2 unset key ##### tx diff plots #### set origin 0.5,0 set size 0.47,1 set tmargin 2 set lmargin 8 set bmargin 4 set rmargin 0 set xtics nomirror set ytics nomirror set label 1 "b)" at graph -0.3,1.05 center attenuation = 0.00493 # use 0.0073 for '2016-07-05/sat_curve_2us/sat_curve_2016_07_05' fibercoupling = 0.62 apdeff_blue = 0.56 # 0.52 opticalpath = 0.9 bg_red= 300*1e-6 bg_blue= 155*1e-6 gamma = 1/26.24e-9 h = 6.626e-34 c = 3e8 lambda = 780.24e-9 probetime = 4 conversion_countrate_to_pW = 1/(apdeff_blue*fibercoupling*attenuation*opticalpath*1e-6) * h*c/lambda *1e12 f(x)=a*x/(b+x) a=0.25 b=30 fit f(x) f1 u (($4-bg_blue)*conversion_countrate_to_pW):($2-bg_red):(sqrt($3)/$8/probetime)via b,a set ytics 0.1 nomirror format "%g" set xtics autofreq nomirror set logscale x set yrange [0:0.33] set xrange [0.61:250] unset title set xlabel 'incident probe power (pW)' set ylabel 'reflection counts (1/{/Symbol m}s)' unset grid unset key plot f1 u (($4-bg_blue)*conversion_countrate_to_pW):($2-bg_red):(sqrt($3)/$8/probetime) w yerr pt 7 ps 1.0 lc rgb "red" lw 3 , f(x) lw 3 lc rgb "red" ################################# ####### set origin 0,0 set size 0.47,1 unset key set border 3 set xtics nomirror unset logscale x unset label 1 set label 2 "a)" at graph -0.3,1.05 center attenuation = 0.00493 # from 15/07/2016 6pm #before 15/07/2016 6pm: attenuation =0.0073 #0.012 fibercoupling = 0.62 apdeff_blue = 0.56 apdeff_red = 0.59 opticalpath = 0.9 col_attn = 1.0 #0.726 bg_red = 300*20e-6 # bg per atom bin bg_blue = 155*20e-6 # bg per atom bin gamma = 1/26.24e-9 h = 6.626e-34 c = 3e8 lambda = 780.24e-9 eff_correction = apdeff_red/(fibercoupling*attenuation*opticalpath*apdeff_blue ) a=0 refl=0.008 gamma0 = 6.8 x0 = 54 lorentz(x) = refl * gamma0**2 * 1 / ( 4*(x0-x)**2 + (gamma0)**2 ) f(x) = 0.006 * 7**2 * 1 / ( 4*(x0-x)**2 + (7)**2 ) fit lorentz(x) f2 u (($1-190000)/1000*2):(($3-bg_red*$8)/(($5-bg_blue*$8)*eff_correction)*100):(sqrt ( (sqrt($3)/($5*eff_correction) )**2 + (sqrt($5)*$3/($5**2*eff_correction))**2 )*100) via refl,x0,gamma0 set ytics 0.2 set xtics 10 set yrange [0:0.7] set xrange [30:66] set xlabel 'probe detuning (MHz)' set ylabel 'reflection (%)' unset grid plot f2 u (($1-190000)/1000*2):(($3-bg_red*$8)/(($5-bg_blue*$8)*eff_correction)*100):(sqrt ( (sqrt($3)/($5*eff_correction) )**2 + (sqrt($5)*$3/($5**2*eff_correction))**2 )*100) w yerr ps 1 pt 7 lw 3 not , lorentz(x) lc 1 lw 3 not unset multiplot unset output pause -1