modified general fitter to fit using sin term.