xsize=15.8
ysize=8.1
size xsize ysize

begin texpreamble
    % set fonts used for text and maths to Palatino
    \usepackage{mathpazo}
    \renewcommand{\familydefault}{ppl}
    \usepackage{upgreek}
    \usepackage[load=abbr]{siunitx}
    \usepackage{bm}
end texpreamble

pt=0.0352777778 ! 1 postscript point

set font texcmr
set hei 11*pt
set texscale scale

tt=4*pt
lw=0.5*pt
set lwidth lw
set just tl

! graph settings
Tmn=0 ! temperature
Tmx=13
Tticks=5
Tsubticks=1
numn=0 !frequency
numx=13
nuticks=5
nusubticks=1
lambdamn=0 !relaxation
lambdamx=100
lambdaticks=20
lambdasubticks=10
timn=0 !for A(t) graphs, time should be consistent
timx=2
titicks=1
tisubticks=0.5

xgraphsize=5
ygraphsize=5
xbiggraphsize=7

xoffset=-0.7
yoffset=3.5

ticklength=0.1

!waterfalloffset=2

glw=2*lw
Aterrw=0.001
errw=glw*2
ms=3.5*pt ! marker size

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!NiPF6
amove 0.2 0.2+yoffset
begin graph
    size xbiggraphsize ygraphsize
    
    data NiPF6/1.5K.dat d1=c1,c2 d2=c1,c3
    
    !xtitle "\tex{$t$ (\si{\us})}"
    xaxis min timn max timx dticks titicks dsubticks tisubticks
    xaxis format "fix 1 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    xticks length ticklength
    xlabels off
    
    ytitle "\tex{$A(t)$ (\%)}"
    yaxis min 8 max 18 dticks 5 dsubticks 1
    yaxis format "fix 0 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    yticks length ticklength
    !ysubticks off
    !ylabels off
    
    d1 err d2 errwidth Aterrw lwidth lw color rgb(0,0.1,0.25)
end graph

begin key
 pos tr nobox
 text "\tex{(a)}"
end key

begin key
 pos tl nobox
 text "\tex{[Ni(HF$_2$)(pyz)$_2$]PF$_6$}"
end key

begin graph
    size xbiggraphsize ygraphsize
    
    data NiPF6/1.5K.fit d1=c1,c2
    
    xaxis min timn max timx
    xaxis off
    
    yaxis min 8 max 18
    yaxis off
    
    d1 line lwidth glw color rgb(0.25,0.65,1)
end graph


rmove xbiggraphsize+xoffset 0
begin graph
    size xgraphsize ygraphsize
    
    data NiPF6/try3-model.dat d1=c1,c3 d2=c1,c4
    data NiPF6/try3-model.tab d3=c1,c2
    let d1 = d1*1.3
    let d2 = d2*1.3
    let d4 = d3*1.3
    
    !xtitle "\tex{$T$ (K)}"
    xaxis min Tmn max Tmx dticks Tticks dsubticks Tsubticks
    xaxis format "fix 0 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    xticks length ticklength
    xlabels off
    !xsubticks off
    
    ytitle "\tex{$\nu$ (MHz)}" dist 0.01
    yaxis min numn max numx dticks nuticks dsubticks nusubticks !nolast
    yaxis format "fix 0 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    yticks length ticklength
    !ysubticks off
    
    d1 marker fcircle err d2 msize ms errwidth 0.05 lwidth 0.01
    d3 lstyle 5 lwidth glw color rgb255(255,13,13)
    d4 line lwidth glw color rgb255(48,80,248)
end graph

begin key
 pos tr nobox
 text "\tex{(b)}"
end key


rmove xgraphsize+xoffset+10*pt 0
begin graph
    size xgraphsize ygraphsize
    
    
    data NiPF6/try3-model.dat d5=c1,c9 d6=c1,c10 !d1=c1,c4 d2=c1,c5 d3=c1,c6 d4=c1,c7

    !xtitle "\tex{$T$ (K)}"
    xaxis min Tmn max Tmx dticks Tticks dsubticks Tsubticks
    xaxis format "fix 0 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    xticks length ticklength
    xlabels off
    !xsubticks off
    
    ytitle "\tex{$\lambda$ (MHz)}" dist 0.01
    yaxis min lambdamn max lambdamx dticks lambdaticks dsubticks lambdasubticks !nolast
    yaxis format "fix 0 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    yticks length ticklength
    !ysubticks off
    
    !d1 marker wcircle err d2 msize ms color rgb255(255,13,13) errwidth erw lwidth lw
    !d3 marker fcircle err d4 msize ms color rgb255(48,80,248) errwidth erw lwidth lw
    d5 marker ftriangle err d6 msize ms color rgb255(144,224,80) errwidth erw lwidth lw
end graph

begin key
 pos tr nobox
 text "\tex{(c)}"
end key

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!NiSbF6
amove 0.2 0.2
begin graph
    size xbiggraphsize ygraphsize
    
    data NiSbF6/1.5K.dat d1=c1,c2 d2=c1,c3
    
    xtitle "\tex{$t$ (\si{\us})}"
    xaxis min timn max timx dticks titicks dsubticks tisubticks
    xaxis format "fix 0 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    xticks length ticklength
    !xlabels off
    
    ytitle "\tex{$A(t)$ (\%)}"
    yaxis min 12 max 24 dticks 5 dsubticks 1
    yaxis format "fix 0 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    yticks length ticklength
    !ysubticks off
    !ylabels off
    
    d1 err d2 errwidth Aterrw lwidth lw color rgb(0,0.1,0.25)
end graph

begin key
 pos tr nobox
 text "\tex{(d)}"
end key

begin key
 pos tl nobox
 text "\tex{[Ni(HF$_2$)(pyz)$_2$]SbF$_6$}"
end key

begin graph
    size xbiggraphsize ygraphsize
    
    data NiSbF6/1.5K.fit d1=c1,c2
    
    xaxis min timn max timx
    xaxis off
    
    yaxis min 12 max 24
    yaxis off
    
    d1 line lwidth glw color rgb(0.25,0.65,1)
end graph


rmove xbiggraphsize+xoffset 0
begin graph
    size xgraphsize ygraphsize
    
    data NiSbF6/try6-model.dat d1=c1,c3 d2=c1,c4
    data NiSbF6/try6-model.tab d3=c1,c2
    let d1=d1*1.369
    let d2=d2*1.369
    let d4=d3*1.369
    
    xtitle "\tex{$T$ (K)}"
    xaxis min Tmn max Tmx dticks Tticks dsubticks Tsubticks
    xaxis format "fix 0 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    xticks length ticklength
    !xlabels off
    !xsubticks off
    
    ytitle "\tex{$\nu$ (MHz)}" dist 0.01
    yaxis min numn max numx dticks nuticks dsubticks nusubticks !nolast
    yaxis format "fix 0 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    yticks length ticklength
    !ysubticks off
    
    d1 marker fcircle err d2 msize ms errwidth 0.05 lwidth 0.01
    d3 lstyle 5 lwidth glw color rgb255(255,13,13)
    d4 line lwidth glw color rgb255(48,80,248)
end graph

begin key
 pos tr nobox
 text "\tex{(e)}"
end key

rmove xgraphsize+xoffset+10*pt 0
begin graph
    size xgraphsize ygraphsize
    
    data NiSbF6/try6-model.dat d5=c1,c5 d6=c1,c6 ! d1=c1,c4 d2=c1,c5 d3=c1,c6 d4=c1,c7

    xtitle "\tex{$T$ (K)}"
    xaxis min Tmn max Tmx dticks Tticks dsubticks Tsubticks
    xaxis format "fix 0 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    xticks length ticklength
    !xlabels off
    !xsubticks off
    
    ytitle "\tex{$\lambda$ (MHz)}" dist 0.15
    yaxis min lambdamn max lambdamx dticks lambdaticks dsubticks lambdasubticks nolast
    yaxis format "fix 0 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    yticks length ticklength
    !ysubticks off
    
    !d1 marker wcircle err d2 msize ms color rgb255(255,13,13) errwidth erw lwidth lw
    !d3 marker fcircle err d4 msize ms color rgb255(48,80,248) errwidth erw lwidth lw
    d5 marker ftriangle err d6 msize ms color rgb255(144,224,80) errwidth erw lwidth lw
end graph

begin key
 pos tr nobox
 text "\tex{(f)}"
end key


set hei 8*pt

!nu vs lambda inset
rmove 1.2 1.1
begin graph
    size 2 2
    
    data NiSbF6/try6-model.dat d1=c3,c5 d2=c3,c6 d3=c3,c4 !x/y,x/yerr,x/xerr

    xtitle "\tex{$\nu$ (MHz)}" dist -0.1
    xaxis min 1 max 10 log
    xaxis format "fix 0 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    xticks length ticklength
    xplaces 1 10
    xnames \tex{$1$} \tex{$10$}
    !xlabels off
    !xsubticks off
    
    ytitle "\tex{$\lambda$ (MHz)}" dist -0.25
    yaxis min 1 max 100 dticks 2 log
    yaxis format "fix 0 prepend \tex{$ append $}" ! makes axis labels TeX. dec is just padding, because for some reason it doesn't work if prepend or append is first
    yticks length ticklength
    !ysubticks off
    
    d1 marker wcircle err d2 herr d3 msize ms color rgb255(255,13,13) !red, like nu2 in the previous graph
    let d4=x^2
    d4 lstyle 1 color black lwidth glw
end graph


set color rgb(0.25,0.65,1)
amove 4.5 6.3
text \tex{1.6 K}

amove 4.5 2.85
text \tex{1.8 K}