Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I need a function (a curve -- preferably a simple one) that, given $n$ points of a 2D space ($R^2$) passes (interpolates) through all points in a smooth/continuous way.

Found out that what I need is a spline, however cannot find one that behaves how I need. $n$-degree Bezier curves and B-splines don't pass through the $n$ points, just move from the first to the last one using the others as control points.

A Bezier spline of $n-1$ Bezier curves (defined between each pair of adjacent points) should do the trick, but to have a smooth result I would need some control points which I don't have and don't know how to compute.

Any hints?

share|cite|improve this question
up vote 1 down vote accepted

A parametric cubic spline is what you want; I've talked about them at some length in this answer (and in probably a few other places on this site, since it seems to be a common question), so I won't repeat myself now. Suffice it to say that yes, Bézier isn't what you need here.

share|cite|improve this answer
Thanks, I missed the other question. Using parametric cube spline is fine for my purpose, anyway, just for curiosity, why is it not possible to find some control points to build a Bezier spline? Many computer graphics programs are able to do that... We just need to have control points at opposite directions, control points, don't we? – peoro Dec 13 '10 at 10:27
@peoro: What I said in that answer is that there's no way to derive the control points if what you only have is the Bézier polynomials. That's why routines maintain the control points and evaluate the Bézier polynomials from them as appropriate. – J. M. Dec 13 '10 at 10:46

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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