>> TGS_phase_analysis('Fe_single_crystal-2019-06-29-06.40um-25degrees#2-POS-1.txt','Fe_single_crystal-2019-06-29-06.40um-25degrees#2-NEG-1.txt',6.4,1)

f2 = 

     General model:
     f2(x) = A.*(erfc(q*sqrt(k*(x+start_time)))-beta*exp(-q^2*k*(x+start_time)
                    )./sqrt((x+start_time)))+B.*sin(2*pi*(peak_freq)*(x+
                    start_time)+p)*exp(-(x+start_time)/t)+D
     Coefficients (with 95% confidence bounds):
       A =      0.1532  (0.1497, 0.1568)
       k =   2.323e-05  (2.286e-05, 2.359e-05)
       beta =   1.065e-05  (9.814e-06, 1.149e-05)
       B =    0.005445  (0.004701, 0.006189)
       p =       1.844  (1.744, 1.945)
       t =   1.568e-08  (1.254e-08, 1.881e-08)
       D =  -0.0004078  (-0.0005502, -0.0002653)
     Problem parameters:
       q =   9.817e+05
       start_time =    1.15e-09
       peak_freq =   4.823e+08

ans =

   4.8227e+08