0

Hi,

How can I generate the equation of a curve that matches all arbitrarily given (x,y) pairs? I would like a polynomial of nth degree, where n does not matter, as long as the curve passes thru all the given points.

I guess this problem is NP-complete. If so, how do I find the closest matching curve in a feasible amount of time?

Furthermore; how do I generate a piecewise polynomial, in case the given (x,y) pairs are discontinuous, or they draw the shape of a, say, circle?

Thanks in advance.

flag
4 
This question will surely get closed, since it's not at research level. Look up Lagrange interpolation. – Andreas Blass Feb 5 2011 at 22:17

closed as too localized by Igor Rivin, Douglas Zare, Felipe Voloch, Qiaochu Yuan, Tom Leinster Feb 5 2011 at 23:03

1 Answer

1

Actually, there is an easy and standard procedure (Lagrange Interpolation) that does this. See:

http://en.wikipedia.org/wiki/Lagrange_polynomial

link|flag
Thank you very much. – Murat Feb 5 2011 at 22:32

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