added function Fit_2 to fit a certain range only after first thickness is found, good speedup but use with caution