I am trying to find out how to find a good interpolation of a periodic function I have from some data points.
The only problem is that I need to make sure that derivatives at the starting and ending points are fixed (not at every point), the function must be constrained between 0 and 1, and of course, smooth.
For a better explanation of my objective, here's a picture, where the red additions are mine to show how interpolation should behave:
data = {{0, 0}, {1.1, 0.8}, {1.4, 1}, {1.7, 0.8}, {2.6, 0.2}, {3.6,
0.06}, {5, 0}}
g[t_] := Interpolation[data, t]
Show[
Plot[g[t], {t, 0, 5}],
ListPlot[data]
]
All my attempts with Fit, Interpolation, and Bezier curves failed.
Any hints?


g[t_] := Interpolation[data, t, InterpolationOrder -> 2, Method -> "Spline"]? – JimB Nov 13 '18 at 16:55