Loading
A cubic spline joins the data points with a separate cubic on each interval, matched so the curve, its slope and its curvature are continuous at every point. The unknowns are the second derivatives .
Fit a natural cubic spline through (1, 2), (2, 3), (3, 5) and estimate y at x = 1.5.
Here h = 1 and natural means :
Each piece is built from the M values at its two ends:
Check: , ✓
The calculator below opens on these points, shows the system and every piece, and draws the spline.
Forgetting the end conditions.
Using the wrong right-hand side.
Using one cubic for the whole range.
Assuming equal steps.
Not checking the pieces.
Writing only the final answer.