2 ways to curve fit & linear curvefit fn
minor bug not finished