Simple NonlinearModelFit
data = {{0, 7.77238*10^-43}, {10, 4.80845*10^-14}, {20,
1.83671*10^-13}, {30, 3.79201*10^-13}, {40, 5.87258*10^-13}, {50,
7.47558*10^-13}, {60, 8.14542*10^-13}, {70, 7.90253*10^-13}, {80,
7.1244*10^-13}, {90, 6.1629*10^-13}};
model = a x + b x^2 + c x ^3 + d x^4 + e;
nlm = NonlinearModelFit[data, model, {a, b, c, d, e}, x]
Plot[nlm[x], {x, 0, 90}, Epilog -> Point[data], PlotRange -> All]
6.8861328671318974*^-15-7.317406274281032*^-15 x+1.1455851486013915*^-15 x^2-1.8092531662781587*^-17 x^3+7.885912004661972*^-20 x^4
You can also use Interpolation[]
ip = Interpolation[data];
Show[ListPlot[data], Plot[ip[x], {x, 0, 90}]]
If you do use Interpolation
, note that the derivative may not be what you want. You can choose the order of Interpolation by using InterpolationOrder->4
within the Interpolation[]
function (4 is the default).
Plot[{nlm'[x], ip'[x]}, {x, 0, 90}]
data = Times[#, {1, 10^13}] & /@ data;
, this can lead to better results when doing fitting. $\endgroup$