Can monotone cubic interpolation be implemented explicitly in B-spline form?

664 Views Asked by At

I have been interpolating cubic splines to some data, but it is now clear that I need my curves to be monotonic. Wikipedia and StackExchange sources describe how to impose the monotonicity condition while fitting with cubic Hermite splines. However I need my splines in B-spline form and I'm not sure how to translate from Hermite form to B-spline form. Is there a method to do this monotonic interpolation so that the resulting curve is explicitly in B-spline form (i.e. a list of knots and B-spline coefficients)? If not (and this might warrant its own question) how does one take a spline in Hermite form to B-spline form?

1

There are 1 best solutions below

0
On

With data $\{(x_1,y_1),\,\ldots\,,(x_n,y_n)\}$, there are multiple methods for choosing the derivatives $\{m_1,\,\ldots\,,m_n\}$ of the interpolant at the $x$-values. The cubic Hermite spline has discontinuous second derivative, so your knot sequence will be $$\text{knots}=\{x_1,x_1,x_1,x_1,x_2,x_2,x_3,x_3,\,\ldots\,x_{n-1},x_{n-1},x_n,x_n,x_n,x_n\}$$

which constitute $2n$ cubic basis functions whose coefficients $\{c_1,\,\ldots\,,c_{2n}\}$ are given by $$c_{\large i}=y_{\large\lceil i/2\rceil}+m_{\large\lceil i/2\rceil}(\text{knots}_{\large i+3}-\text{knots}_{\large i+1})/3$$

if the basis functions are normalized so as to sum to $1$.