2
$\begingroup$

Start with a monotone nonincreasing function and sample it at finite set of points $x_0, ..., x_n$, $x_i<x_{i+1}$ so that $f(x_i)<f(x_{i+1})$. If you approximate $f$ with a linear spline then the resulting piecewise-linear approximation will certainly preserve monotonicity.

The question is: if you approximate $f$ with natural cubic spline will monotonicity be preserved as well?

$\endgroup$
10
$\begingroup$

I assume you mean nondecreasing, i.e., monotonically increasing. If so, the answer is "no." For example, interpolate (0,0), (1,10) and (2,11) with a natural cubic spline:

enter image description here

$\endgroup$
2
$\begingroup$

Not only is the answer "no", but for any number $N$ you can construct a monotone function and sample it such that the natural spline approximation will have $N$ extremum points.

See the figure (and its enlargement) below for an example. A full explanation of this function can be found in this answer.

enter image description here enter image description here

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.