Consider the following set of data points:
$x$ | $y$
------- | --------
0 | 1.0
1 | 2.0
2 | 2.5
3 | 3.0
4 | 5.0
We want to fit a spline with one knot at $x = 2$, using two quadratic segments. Additionally, we require continuity at $x = 2$.
1. Determine the coefficients so that the spline passes exactly through all five data points and is continuous at $x = 2$.
2. Using the fitted spline, compute the predicted values of $y$ at $x = 1.5$ and $x = 3.5$.