HOME

TheInfoList



OR:

In
numerical analysis Numerical analysis is the study of algorithms that use numerical approximation (as opposed to symbolic computation, symbolic manipulations) for the problems of mathematical analysis (as distinguished from discrete mathematics). It is the study of ...
, polynomial interpolation is the
interpolation In the mathematics, mathematical field of numerical analysis, interpolation is a type of estimation, a method of constructing (finding) new data points based on the range of a discrete set of known data points. In engineering and science, one ...
of a given
data set A data set (or dataset) is a collection of data. In the case of tabular data, a data set corresponds to one or more table (database), database tables, where every column (database), column of a table represents a particular Variable (computer sci ...
by the
polynomial In mathematics, a polynomial is a Expression (mathematics), mathematical expression consisting of indeterminate (variable), indeterminates (also called variable (mathematics), variables) and coefficients, that involves only the operations of addit ...
of lowest possible degree that passes through the points in the dataset. Given a set of data points (x_0,y_0), \ldots, (x_n,y_n), with no two x_j the same, a polynomial function p(x)=a_0+a_1x+\cdots+a_nx^n is said to interpolate the data if p(x_j)=y_j for each j\in\. There is always a unique such polynomial, commonly given by two explicit formulas, the
Lagrange polynomial In numerical analysis, the Lagrange interpolating polynomial is the unique polynomial of lowest degree that interpolates a given set of data. Given a data set of coordinate pairs (x_j, y_j) with 0 \leq j \leq k, the x_j are called ''nodes'' ...
s and Newton polynomials.


Applications

The original use of interpolation polynomials was to approximate values of important transcendental functions such as
natural logarithm The natural logarithm of a number is its logarithm to the base of a logarithm, base of the e (mathematical constant), mathematical constant , which is an Irrational number, irrational and Transcendental number, transcendental number approxima ...
and
trigonometric function In mathematics, the trigonometric functions (also called circular functions, angle functions or goniometric functions) are real functions which relate an angle of a right-angled triangle to ratios of two side lengths. They are widely used in all ...
s. Starting with a few accurately computed data points, the corresponding interpolation polynomial will approximate the function at an arbitrary nearby point. Polynomial interpolation also forms the basis for algorithms in numerical quadrature ( Simpson's rule) and
numerical ordinary differential equations Numerical methods for ordinary differential equations are methods used to find Numerical analysis, numerical approximations to the solutions of ordinary differential equations (ODEs). Their use is also known as "numerical integration", although ...
( multigrid methods). In
computer graphics Computer graphics deals with generating images and art with the aid of computers. Computer graphics is a core technology in digital photography, film, video games, digital art, cell phone and computer displays, and many specialized applications. ...
, polynomials can be used to approximate complicated plane curves given a few specified points, for example the shapes of letters in
typography Typography is the art and technique of Typesetting, arranging type to make written language legibility, legible, readability, readable and beauty, appealing when displayed. The arrangement of type involves selecting typefaces, Point (typogra ...
. This is usually done with
Bézier curve A Bézier curve ( , ) is a parametric equation, parametric curve used in computer graphics and related fields. A set of discrete "control points" defines a smooth, continuous curve by means of a formula. Usually the curve is intended to approxima ...
s, which are a simple generalization of interpolation polynomials (having specified tangents as well as specified points). In numerical analysis, polynomial interpolation is essential to perform sub-quadratic multiplication and squaring, such as Karatsuba multiplication and Toom–Cook multiplication, where interpolation through points on a product polynomial yields the specific product required. For example, given ''a'' = ''f''(''x'') = ''a''0''x''0 + ''a''1''x''1 + ··· and ''b'' = ''g''(''x'') = ''b''0''x''0 + ''b''1''x''1 + ···, the product ''ab'' is a specific value of ''W''(''x'') = ''f''(''x'')''g''(''x''). One may easily find points along ''W''(''x'') at small values of ''x'', and interpolation based on those points will yield the terms of ''W''(''x'') and the specific product ''ab''. As fomulated in Karatsuba multiplication, this technique is substantially faster than quadratic multiplication, even for modest-sized inputs, especially on parallel hardware. In
computer science Computer science is the study of computation, information, and automation. Computer science spans Theoretical computer science, theoretical disciplines (such as algorithms, theory of computation, and information theory) to Applied science, ...
, polynomial interpolation also leads to algorithms for secure multi party computation and
secret sharing Secret sharing (also called secret splitting) refers to methods for distributing a secrecy, secret among a group, in such a way that no individual holds any intelligible information about the secret, but when a sufficient number of individuals c ...
.


Interpolation theorem

For any n+1 bivariate data points (x_0,y_0),\dotsc,(x_n,y_n) \in \R^2, where no two x_j are the same, there exists a unique polynomial p(x) of degree at most n that interpolates these points, i.e. p(x_0)=y_0, \ldots, p(x_n)=y_n. Equivalently, for a fixed choice of interpolation nodes x_j, polynomial interpolation defines a linear
bijection In mathematics, a bijection, bijective function, or one-to-one correspondence is a function between two sets such that each element of the second set (the codomain) is the image of exactly one element of the first set (the domain). Equival ...
L_n between the (''n''+1)-tuples of real-number values (y_0,\ldots,y_n)\in \R^ and the
vector space In mathematics and physics, a vector space (also called a linear space) is a set (mathematics), set whose elements, often called vector (mathematics and physics), ''vectors'', can be added together and multiplied ("scaled") by numbers called sc ...
P(n) of real polynomials of degree at most ''n'': L_n : \mathbb^ \stackrel\, P(n). This is a type of unisolvence theorem. The theorem is also valid over any infinite field in place of the real numbers \R, for example the rational or complex numbers.


First proof

Consider the Lagrange basis functions L_0(x),\ldots,L_n(x) given by: L_j(x)=\prod_\frac = \frac . Notice that L_j(x) is a polynomial of degree n, and we have L_j(x_k)=0 for each j\neq k, while L_k(x_k)=1. It follows that the linear combination: p(x) = \sum_^n y_j L_j(x) has p(x_k)=\sum_j y_j \,L_j(x_k) = y_k , so p(x) is an interpolating polynomial of degree n. To prove uniqueness, assume that there exists another interpolating polynomial q(x) of degree at most n, so that p(x_k)=q(x_k) for all k=0,\dotsc,n. Then p(x)-q(x) is a polynomial of degree at most n which has n+1 distinct zeros (the x_k). But a non-zero polynomial of degree at most n can have at most n zeros, so p(x)-q(x) must be the zero polynomial, i.e. p(x)=q(x).


Second proof

Write out the interpolation polynomial in the form Substituting this into the interpolation equations p(x_j) = y_j, we get a
system of linear equations In mathematics, a system of linear equations (or linear system) is a collection of two or more linear equations involving the same variable (math), variables. For example, : \begin 3x+2y-z=1\\ 2x-2y+4z=-2\\ -x+\fracy-z=0 \end is a system of th ...
in the coefficients a_j, which reads in matrix-vector form as the following
multiplication Multiplication is one of the four elementary mathematical operations of arithmetic, with the other ones being addition, subtraction, and division (mathematics), division. The result of a multiplication operation is called a ''Product (mathem ...
: \begin x_0^n & x_0^ & x_0^ & \ldots & x_0 & 1 \\ x_1^n & x_1^ & x_1^ & \ldots & x_1 & 1 \\ \vdots & \vdots & \vdots & & \vdots & \vdots \\ x_n^n & x_n^ & x_n^ & \ldots & x_n & 1 \end \begin a_n \\ a_ \\ \vdots \\ a_0 \end = \begin y_0 \\ y_1 \\ \vdots \\ y_n \end. An interpolant p(x) corresponds to a solution A = (a_n,\ldots,a_0) of the above matrix equation X \cdot A = Y. The matrix ''X'' on the left is a Vandermonde matrix, whose determinant is known to be \textstyle \det(X) = \prod_ (x_j - x_i), which is non-zero since the nodes x_j are all distinct. This ensures that the matrix is
invertible In mathematics, the concept of an inverse element generalises the concepts of opposite () and reciprocal () of numbers. Given an operation denoted here , and an identity element denoted , if , one says that is a left inverse of , and that ...
and the equation has the unique solution A = X^\cdot Y; that is, p(x) exists and is unique.


Corollary

If f(x) is a polynomial of degree at most n, then the interpolating polynomial of f(x) at n+1 distinct points is f(x) itself.


Constructing the interpolation polynomial


Lagrange Interpolation

We may write down the polynomial immediately in terms of
Lagrange polynomial In numerical analysis, the Lagrange interpolating polynomial is the unique polynomial of lowest degree that interpolates a given set of data. Given a data set of coordinate pairs (x_j, y_j) with 0 \leq j \leq k, the x_j are called ''nodes'' ...
s as: \begin p(x) &= \frac y_0 \\ pt &+ \fracy_1 \\ pt &+ \cdots\\ pt &+\fracy_n \\ pt&=\sum_^n \Biggl( \prod_ \frac \Biggr) y_i =\sum_^n \frac\,y_i \endFor matrix arguments, this formula is called Sylvester's formula and the matrix-valued Lagrange polynomials are the Frobenius covariants. :


Newton Interpolation


Theorem

For a polynomial p_n of degree less than or equal to n, that interpolates f at the nodes x_i where i = 0,1,2,3,\cdots,n. Let p_ be the polynomial of degree less than or equal to n+1 that interpolates f at the nodes x_i where i = 0,1,2,3,\cdots,n, n+1. Then p_ is given by:p_(x) = p_n(x) +a_w_n(x) where w_n(x) := \prod_^n (x-x_i) also known as Newton basis and a_ := . Proof: This can be shown for the case where i = 0,1,2,3,\cdots,n:p_(x_i) = p_n(x_i) +a_\prod_^n (x_i-x_j) = p_n(x_i) and when i = n+1:p_(x_) = p_n(x_) + w_n(x_) = f(x_) By the uniqueness of interpolated polynomials of degree less than n+1, p_(x) = p_n(x) +a_w_n(x) is the required polynomial interpolation. The function can thus be expressed as: p_(x) = a_0+a_1(x-x_0)+a_2(x-x_0)(x-x_1)+\cdots + a_n(x-x_0)\cdots(x-x_) .


Polynomial coefficients

To find a_i, we have to solve the lower triangular matrix formed by arranging p_ (x_i)=f(x_i)=y_i from above equation in matrix form: : \begin 1 & & \ldots & & 0 \\ 1 & x_1-x_0 & & & \\ 1 & x_2-x_0 & (x_2-x_0)(x_2-x_1) & & \vdots \\ \vdots & \vdots & & \ddots & \\ 1 & x_k-x_0 & \ldots & \ldots & \prod_^(x_n - x_j) \end \begin a_0 \\ \\ \vdots \\ \\ a_ \end = \begin y_0 \\ \\ \vdots \\ \\ y_ \end The coefficients are derived as : a_j := _0,\ldots,y_j/math> where : _0,\ldots,y_j/math> is the notation for divided differences. Thus, Newton polynomials are used to provide a polynomial interpolation formula of n points.


Newton forward formula

The Newton polynomial can be expressed in a simplified form when x_0, x_1, \dots, x_k are arranged consecutively with equal spacing. If x_0, x_1, \dots, x_k are consecutively arranged and equally spaced with _=_+ih for ''i'' = 0, 1, ..., ''k'' and some variable x is expressed as =_+sh, then the difference x-x_i can be written as (s-i)h. So the Newton polynomial becomes : \begin N(x) &= _0+ _0,y_1h + \cdots + _0,\ldots,y_ks (s-1) \cdots (s-k+1)^ \\ &= \sum_^s(s-1) \cdots (s-i+1)^ _0,\ldots,y_i\\ &= \sum_^i!^ _0,\ldots,y_i \end Since the relationship between divided differences and forward differences is given as: _j, y_, \ldots , y_= \frac\Delta^y_j,Taking y_i=f(x_i), if the representation of x in the previous sections was instead taken to be x=x_j+sh, the Newton forward interpolation formula is expressed as:f(x) \approx N(x)=N(x_j+sh) = \sum_^\Delta^ f(x_j) which is the interpolation of all points after x_j. It is expanded as:f(x_j+sh)=f(x_j)+\frac\Delta f(x_j)+ \frac\Delta^2 f(x_j)+\frac\Delta^3 f(x_j)+\frac\Delta^4 f(x_j)+\cdots


Newton backward formula

If the nodes are reordered as _,_,\dots,_, the Newton polynomial becomes : N(x)= _k , _x-_)+\cdots+ ,\ldots,_x-_)(x-_)\cdots(x-_). If _,\;_,\;\dots,\;_ are equally spaced with _=_-(k-i)h for ''i'' = 0, 1, ..., ''k'' and =_+sh, then, : \begin N(x) &= , _h+\cdots+ ,\ldots,_(s+1)\cdots(s+k-1)^ \\ &=\sum_^^i!^ ,\ldots,_ \end Since the relationship between divided differences and backward differences is given as: , y_,\ldots,_= \frac\nabla^y_j, taking y_i=f(x_i), if the representation of x in the previous sections was instead taken to be x=x_j+sh, the Newton backward interpolation formula is expressed as:f(x) \approx N(x) =N(x_j+sh)=\sum_^^\nabla^ f(x_j). which is the interpolation of all points before x_j. It is expanded as:f(x_j+sh)=f(x_j)+\frac\nabla f(x_j)+ \frac\nabla^2 f(x_j)+\frac\nabla^3 f(x_j)+\frac\nabla^4 f(x_j)+\cdots


Lozenge Diagram

A Lozenge diagram is a diagram that is used to describe different interpolation formulas that can be constructed for a given data set. A line starting on the left edge and tracing across the diagram to the right can be used to represent an interpolation formula if the following rules are followed: # Left to right steps indicate addition whereas right to left steps indicate subtraction # If the slope of a step is positive, the term to be used is the product of the difference and the factor immediately below it. If the slope of a step is negative, the term to be used is the product of the difference and the factor immediately above it. # If a step is horizontal and passes through a factor, use the product of the factor and the average of the two terms immediately above and below it. If a step is horizontal and passes through a difference, use the product of the difference and the average of the two terms immediately above and below it. The factors are expressed using the formula:C(u+k,n)=\frac


Proof of equivalence

If a path goes from \Delta^y_s to \Delta^y_ , it can connect through three intermediate steps, (a) through \Delta^y_ , (b) through C(u-s ,n) or (c) through \Delta^y_s . Proving the equivalence of these three two-step paths should prove that all (n-step) paths can be morphed with the same starting and ending, all of which represents the same formula. Path (a): C(u-s, n) \Delta^n y_+C(u-s+1, n+1) \Delta^ y_ Path (b): C(u-s, n) \Delta^n y_s + C(u-s, n+1) \Delta^ y_ Path (c): C(u-s, n) \frac \quad+\frac \Delta^ y_ Subtracting contributions from path a and b: \begin \text= & C(u-s, n)(\Delta^n y_-\Delta^n y_s) +(C(u-s+1, n+1)-C(u-s, n-1)) \Delta^ y_ \\ = & - C(u-s, n)\Delta^ y_ + C(u-s, n) \frac \Delta^ y_ \\ = & C(u-s, n)(-\Delta^ y_+\Delta^ y_ )=0 \\ \end Thus, the contribution of either path (a) or path (b) is the same. Since path (c) is the average of path (a) and (b), it also contributes identical function to the polynomial. Hence the equivalence of paths with same starting and ending points is shown. To check if the paths can be shifted to different values in the leftmost corner, taking only two step paths is sufficient: (a) y_ to y_ through \Delta y_ or (b) factor between y_ and y_ , to y_ through \Delta y_ or (c) starting from y_ . Path (a) y_+C(u-s-1,1) \Delta y_s - C(u-s, 1) \Delta y_s Path (b) \frac+\frac \Delta y_s - C(u-s, 1) \Delta y_s Path (c) y_ Since \Delta y_ = y_-y_s , substituting in the above equations shows that all the above terms reduce to y_ and are hence equivalent. Hence these paths can be morphed to start from the leftmost corner and end in a common point.


Newton formula

Taking negative slope transversal from y_0 to \Delta^n y_0 gives the interpolation formula of all the n+1 consecutively arranged points, equivalent to Newton's forward interpolation formula: \begin y(s) &=y_0+C(s, 1) \Delta y_0+C(s, 2) \Delta^2 y_0+C(s, 3) \Delta^3 y_0+\cdots \\ & =y_0+s \Delta y_0+\frac \Delta^2 y_0+\frac \Delta^3 y_0+\frac \Delta^4 y_0+\cdots \end whereas, taking positive slope transversal from y_n to \nabla^n y_n = \Delta^n y_0 , gives the interpolation formula of all the n+1 consecutively arranged points, equivalent to Newton's backward interpolation formula: \begin y(u) & = y_k+C(u-k, 1) \Delta y_+C(u-k+1,2) \Delta^2 y_ +C(u - k+2,3) \Delta^3 y_+\cdots \\ & = y_k+(u-k) \Delta y_ +\frac \Delta^2 y_+\frac \Delta^3 y_+\cdots \\ y(k+s) & = y_k+(s) \nabla y_ +\frac \nabla^2 y_+\frac \nabla^3 y_+\frac \nabla^4 y_+\cdots \\ \end where s=u-k is the number corresponding to that introduced in Newton interpolation.


Gauss formula

Taking a zigzag line towards the right starting from y_0 with negative slope, we get Gauss forward formula: y(u)=y_0+u \Delta y_0+\frac \Delta^2 y_ +\frac \Delta^3 y_+ \frac \Delta^4 y_ + \cdots whereas starting from y_0 with positive slope, we get Gauss backward formula: y(u)=y_0+u \Delta y_+\frac \Delta^2 y_ +\frac \Delta^3 y_+ \frac \Delta^4 y_ + \cdots


Stirling formula

By taking a horizontal path towards the right starting from y_0 , we get Stirling formula: \begin y(u)&= y_0 +u \frac+\frac \Delta^2 y_ +C(u+1,3) \frac+\cdots \\ & = y_0+u \frac+\frac \Delta^2 y_+\frac \frac+\frac\Delta^4 y_+\cdots \end Stirling formula is the average of Gauss forward and Gauss backward formulas.


Bessel formula

By taking a horizontal path towards the right starting from factor between y_0 and y_1 , we get Bessel formula: \begin y(u)&=1+\Delta y_+C(u,2)+\cdots\\ &= \frac+\left(u-\right)\Delta y_+\frac\frac+\frac\Delta^ y_ + \frac\frac+\cdots\\ \end


Vandermonde Algorithms

The Vandermonde matrix in the second proof above may have large
condition number In numerical analysis, the condition number of a function measures how much the output value of the function can change for a small change in the input argument. This is used to measure how sensitive a function is to changes or errors in the inpu ...
, causing large errors when computing the coefficients if the system of equations is solved using
Gaussian elimination In mathematics, Gaussian elimination, also known as row reduction, is an algorithm for solving systems of linear equations. It consists of a sequence of row-wise operations performed on the corresponding matrix of coefficients. This method can a ...
. Several authors have therefore proposed algorithms which exploit the structure of the Vandermonde matrix to compute numerically stable solutions in O(''n''2) operations instead of the O(''n''3) required by Gaussian elimination. These methods rely on constructing first a Newton interpolation of the polynomial and then converting it to a monomial form.


Non-Vandermonde algorithms

To find the interpolation polynomial ''p''(''x'') in the vector space ''P''(''n'') of polynomials of degree , we may use the usual
monomial basis In mathematics the monomial basis of a polynomial ring is its basis (as a vector space or free module over the field or ring of coefficients) that consists of all monomials. The monomials form a basis because every polynomial may be uniquely w ...
for ''P''(''n'') and invert the Vandermonde matrix by Gaussian elimination, giving a
computational cost A computation is any type of arithmetic or non-arithmetic calculation that is well-defined. Common examples of computation are mathematical equation solving and the execution of computer algorithms. Mechanical or electronic devices (or, historic ...
of O(''n''3) operations. To improve this algorithm, a more convenient basis for ''P''(''n'') can simplify the calculation of the coefficients, which must then be translated back in terms of the
monomial basis In mathematics the monomial basis of a polynomial ring is its basis (as a vector space or free module over the field or ring of coefficients) that consists of all monomials. The monomials form a basis because every polynomial may be uniquely w ...
. One method is to write the interpolation polynomial in the Newton form (i.e. using Newton basis) and use the method of divided differences to construct the coefficients, e.g. Neville's algorithm. The cost is O(''n''2) operations. Furthermore, you only need to do O(''n'') extra work if an extra point is added to the data set, while for the other methods, you have to redo the whole computation. Another method is preferred when the aim is not to compute the ''coefficients'' of ''p''(''x''), but only a ''single value'' ''p''(''a'') at a point ''x = a'' not in the original data set. The Lagrange form computes the value ''p''(''a'') with complexity O(''n''2). The
Bernstein form In the mathematical field of numerical analysis, a Bernstein polynomial is a polynomial expressed as a linear combination of Bernstein basis polynomials. The idea is named after mathematician Sergei Natanovich Bernstein. Polynomials in Bernste ...
was used in a constructive proof of the
Weierstrass approximation theorem Karl Theodor Wilhelm Weierstrass (; ; 31 October 1815 – 19 February 1897) was a German mathematician often cited as the " father of modern analysis". Despite leaving university without a degree, he studied mathematics and trained as a school t ...
by Bernstein and has gained great importance in computer graphics in the form of
Bézier curve A Bézier curve ( , ) is a parametric equation, parametric curve used in computer graphics and related fields. A set of discrete "control points" defines a smooth, continuous curve by means of a formula. Usually the curve is intended to approxima ...
s.


Interpolations as linear combinations of values

Given a set of (position, value) data points (x_0, y_0), \ldots, (x_j, y_j), \ldots, (x_n, y_n) where no two positions x_j are the same, the interpolating polynomial y(x) may be considered as a
linear combination In mathematics, a linear combination or superposition is an Expression (mathematics), expression constructed from a Set (mathematics), set of terms by multiplying each term by a constant and adding the results (e.g. a linear combination of ''x'' a ...
of the values y_j, using coefficients which are polynomials in x depending on the x_j. For example, the interpolation polynomial in the Lagrange form is the linear combination y(x) := \sum_^ y_j c_j(x) with each coefficient c_j(x) given by the corresponding Lagrange basis polynomial on the given positions x_j: c_j(x) = L_j(x_0,\ldots,x_n;x) = \prod_ \frac = \frac \cdots \frac \frac \cdots \frac. Since the coefficients depend only on the positions x_j, not the values y_j, we can use the ''same coefficients'' to find the interpolating polynomial for a second set of data points (x_0, v_0), \ldots, (x_n, v_n) at the same positions: v(x) := \sum_^ v_j c_j(x). Furthermore, the coefficients c_j(x) only depend on the relative spaces x_i-x_j between the positions. Thus, given a third set of data whose points are given by the new variable t = ax+b (an
affine transformation In Euclidean geometry, an affine transformation or affinity (from the Latin, '' affinis'', "connected with") is a geometric transformation that preserves lines and parallelism, but not necessarily Euclidean distances and angles. More general ...
of x, inverted by x=\tfrac): (t_0, w_0), \ldots, (t_j, w_j) \ldots, (t_n, w_n) \qquad \text\qquad t_j = ax_j + b, we can use a transformed version of the previous coefficient polynomials:
\tilde c_j(t) := c_j(\tfrac) = c_j(x),
and write the interpolation polynomial as:
w(t) := \sum_^ w_j \tilde c_j(t).
Data points (x_j,y_j) often have ''equally spaced positions'', which may be normalized by an affine transformation to x_j = j. For example, consider the data points
(0,y_0), (1,y_1), (2,y_2).
The interpolation polynomial in the Lagrange form is the
linear combination In mathematics, a linear combination or superposition is an Expression (mathematics), expression constructed from a Set (mathematics), set of terms by multiplying each term by a constant and adding the results (e.g. a linear combination of ''x'' a ...
\begin y(x) := \sum_^2 y_j c_j(x) &= y_0 \frac + y_1 \frac + y_2 \frac \\ &= \tfrac12 y_0 (x-1)(x-2) - y_1 (x-0)(x-2) + \tfrac12 y_2 (x-0)(x-1). \end For example, y(3) = y_3 = y_0 - 3y_1 + 3y_2 and y(1.5) = y_ = \tfrac18 (-y_0 + 6y_1 + 3y_2). The case of equally spaced points can also be treated by the method of finite differences. The first difference of a sequence of values v=\_^\infty is the sequence \Delta v = u = \_^\infty defined by u_j = v_-v_j . Iterating this operation gives the ''n''th difference operation \Delta^n v = u, defined explicitly by:u_j = \sum_^n (-1)^ v_, where the coefficients form a signed version of Pascal's triangle, the triangle of binomial transform coefficients: A polynomial y(x) of degree ''d'' defines a sequence of values at positive integer points, y_j = y(j), and the (d+1)^ difference of this sequence is identically zero:
\Delta^ y = 0.
Thus, given values y_0,\ldots,y_n at equally spaced points, where n=d+1 , we have: (-1)^n y_0 + (-1)^ \binom y_1 + \cdots - \binom n y_ + y_n= 0. For example, 4 equally spaced data points y_0,y_1,y_2,y_3 of a quadratic y(x) obey 0 = -y_0 + 3y_1 - 3y_2 + y_3, and solving for y_3 gives the same interpolation equation obtained above using the Lagrange method.


Interpolation error: Lagrange remainder formula

When interpolating a given function ''f'' by a polynomial p_n of degree at the nodes ''x''0,..., ''x''''n'' we get the error f(x) - p_n(x) = f _0,\ldots,x_n,x\prod_^n (x-x_i) where f _0,\ldots,x_n,x/math> is the (''n''+1)st divided difference of the data points
(x_0,f(x_0)),\ldots,(x_n,f(x_n)),(x,f(x)) .
Furthermore, there is a ''Lagrange remainder form'' of the error, for a function ''f'' which is times continuously differentiable on a closed interval I, and a polynomial p_n(x) of degree at most that interpolates ''f'' at distinct points x_0,\ldots,x_n\in I. For each x\in I there exists \xi\in I such that f(x) - p_n(x) = \frac \prod_^n (x-x_i). This error bound suggests choosing the interpolation points to minimize the product \left , \prod (x - x_i) \right , , which is achieved by the
Chebyshev nodes In numerical analysis, Chebyshev nodes (also called Chebyshev points or a Chebyshev grid) are a set of specific algebraic numbers used as nodes for polynomial interpolation and numerical integration. They are the Projection (linear algebra), pr ...
.


Proof of Lagrange remainder

Set the error term as R_n(x) = f(x) - p_n(x) , and define an auxiliary function: Y(t) = R_n(t) - \frac W(t) \qquad\text\qquad W(t) = \prod_^n (t-x_i). Thus: Y^(t) = R_n^(t) - \frac \ (n+1)! But since p_n(x) is a polynomial of degree at most , we have R_n^(t) = f^(t) , and: Y^(t) = f^(t) - \frac \ (n+1)! Now, since are roots of R_n(t) and W(t), we have Y(x)=Y(x_j)=0 , which means has at least roots. From Rolle's theorem, Y^\prime(t) has at least roots, and iteratively Y^(t) has at least one root in the interval . Thus: Y^(\xi) = f^(\xi) - \frac \ (n+1)! = 0 and: R_n(x) = f(x) - p_n(x) = \frac \prod_^n (x-x_i) . This parallels the reasoning behind the Lagrange remainder term in the Taylor theorem; in fact, the Taylor remainder is a special case of interpolation error when all interpolation nodes are identical. Note that the error will be zero when x = x_i for any ''i''. Thus, the maximum error will occur at some point in the interval between two successive nodes.


Equally spaced intervals

In the case of equally spaced interpolation nodes where x_i = a + ih, for i=0,1,\ldots,n, and where h = (b-a)/n, the product term in the interpolation error formula can be bound as \left, \prod_^n (x-x_i)\ = \prod_^n \left, x-x_i\ \leq \frac h^. Thus the error bound can be given as \left, R_n(x)\ \leq \frac \max_ \left, f^(\xi)\ However, this assumes that f^(\xi) is dominated by h^, i.e. f^(\xi) h^ \ll 1. In several cases, this is not true and the error actually increases as (see
Runge's phenomenon In the mathematical field of numerical analysis, Runge's phenomenon () is a problem of oscillation at the edges of an interval that occurs when using polynomial interpolation with polynomials of high degree over a set of equispaced interpolation ...
). That question is treated in the section ''Convergence properties''.


Lebesgue constants

We fix the interpolation nodes ''x''0, ..., ''x''''n'' and an interval 'a'', ''b''containing all the interpolation nodes. The process of interpolation maps the function ''f'' to a polynomial ''p''. This defines a mapping ''X'' from the space ''C''( 'a'', ''b'' of all continuous functions on 'a'', ''b''to itself. The map ''X'' is linear and it is a
projection Projection or projections may refer to: Physics * Projection (physics), the action/process of light, heat, or sound reflecting from a surface to another in a different direction * The display of images by a projector Optics, graphics, and carto ...
on the subspace P(n) of polynomials of degree ''n'' or less. The Lebesgue constant ''L'' is defined as the
operator norm In mathematics, the operator norm measures the "size" of certain linear operators by assigning each a real number called its . Formally, it is a norm defined on the space of bounded linear operators between two given normed vector spaces. Inform ...
of ''X''. One has (a special case of
Lebesgue's lemma In mathematics, Lebesgue's lemma is an important statement in approximation theory. It provides a bound for the projection error, controlling the error of approximation by a linear subspace based on a linear projection relative to the optimal err ...
): \left\, f-X(f)\right\, \le (L+1) \left\, f-p^*\right\, . In other words, the interpolation polynomial is at most a factor (''L'' + 1) worse than the best possible approximation. This suggests that we look for a set of interpolation nodes that makes ''L'' small. In particular, we have for
Chebyshev nodes In numerical analysis, Chebyshev nodes (also called Chebyshev points or a Chebyshev grid) are a set of specific algebraic numbers used as nodes for polynomial interpolation and numerical integration. They are the Projection (linear algebra), pr ...
: L \le \frac2\pi \log(n+1) + 1. We conclude again that Chebyshev nodes are a very good choice for polynomial interpolation, as the growth in ''n'' is exponential for equidistant nodes. However, those nodes are not optimal.


Convergence properties

It is natural to ask, for which classes of functions and for which interpolation nodes the sequence of interpolating polynomials converges to the interpolated function as ? Convergence may be understood in different ways, e.g. pointwise, uniform or in some integral norm. The situation is rather bad for equidistant nodes, in that uniform convergence is not even guaranteed for infinitely differentiable functions. One classical example, due to
Carl Runge Carl David Tolmé Runge (; 30 August 1856 – 3 January 1927) was a German mathematician, physicist, and spectroscopist. He was co-developer and co-eponym of the Runge–Kutta method (), in the field of what is today known as numerical analysi ...
, is the function ''f''(''x'') = 1 / (1 + ''x''2) on the interval . The interpolation error grows without bound as . Another example is the function ''f''(''x'') = , ''x'', on the interval , for which the interpolating polynomials do not even converge pointwise except at the three points ''x'' = ±1, 0. attributes the last example to . One might think that better convergence properties may be obtained by choosing different interpolation nodes. The following result seems to give a rather encouraging answer: The defect of this method, however, is that interpolation nodes should be calculated anew for each new function ''f''(''x''), but the algorithm is hard to be implemented numerically. Does there exist a single table of nodes for which the sequence of interpolating polynomials converge to any continuous function ''f''(''x'')? The answer is unfortunately negative: The proof essentially uses the lower bound estimation of the Lebesgue constant, which we defined above to be the operator norm of ''X''''n'' (where ''X''''n'' is the projection operator on Π''n''). Now we seek a table of nodes for which \lim_ X_n f = f,\textf \in C( ,b. Due to the Banach–Steinhaus theorem, this is only possible when norms of ''X''''n'' are uniformly bounded, which cannot be true since we know that \, X_n\, \geq \tfrac \log(n+1)+C. For example, if equidistant points are chosen as interpolation nodes, the function from
Runge's phenomenon In the mathematical field of numerical analysis, Runge's phenomenon () is a problem of oscillation at the edges of an interval that occurs when using polynomial interpolation with polynomials of high degree over a set of equispaced interpolation ...
demonstrates divergence of such interpolation. Note that this function is not only continuous but even infinitely differentiable on . For better
Chebyshev nodes In numerical analysis, Chebyshev nodes (also called Chebyshev points or a Chebyshev grid) are a set of specific algebraic numbers used as nodes for polynomial interpolation and numerical integration. They are the Projection (linear algebra), pr ...
, however, such an example is much harder to find due to the following result:


Related concepts

Runge's phenomenon In the mathematical field of numerical analysis, Runge's phenomenon () is a problem of oscillation at the edges of an interval that occurs when using polynomial interpolation with polynomials of high degree over a set of equispaced interpolation ...
shows that for high values of , the interpolation polynomial may oscillate wildly between the data points. This problem is commonly resolved by the use of
spline interpolation In the mathematical field of numerical analysis, spline interpolation is a form of interpolation where the interpolant is a special type of piecewise polynomial called a spline. That is, instead of fitting a single, high-degree polynomial to all ...
. Here, the interpolant is not a polynomial but a spline: a chain of several polynomials of a lower degree. Interpolation of
periodic function A periodic function, also called a periodic waveform (or simply periodic wave), is a function that repeats its values at regular intervals or periods. The repeatable part of the function or waveform is called a ''cycle''. For example, the t ...
s by
harmonic In physics, acoustics, and telecommunications, a harmonic is a sinusoidal wave with a frequency that is a positive integer multiple of the ''fundamental frequency'' of a periodic signal. The fundamental frequency is also called the ''1st har ...
functions is accomplished by
Fourier transform In mathematics, the Fourier transform (FT) is an integral transform that takes a function as input then outputs another function that describes the extent to which various frequencies are present in the original function. The output of the tr ...
. This can be seen as a form of polynomial interpolation with harmonic base functions, see trigonometric interpolation and
trigonometric polynomial In the mathematical subfields of numerical analysis and mathematical analysis, a trigonometric polynomial is a finite linear combination of functions sin(''nx'') and cos(''nx'') with ''n'' taking on the values of one or more natural numbers. The c ...
.
Hermite interpolation In numerical analysis, Hermite interpolation, named after Charles Hermite, is a method of polynomial interpolation, which generalizes Lagrange interpolation. Lagrange interpolation allows computing a polynomial of degree less than that takes th ...
problems are those where not only the values of the polynomial ''p'' at the nodes are given, but also all derivatives up to a given order. This turns out to be equivalent to a system of simultaneous polynomial congruences, and may be solved by means of the
Chinese remainder theorem In mathematics, the Chinese remainder theorem states that if one knows the remainders of the Euclidean division of an integer ''n'' by several integers, then one can determine uniquely the remainder of the division of ''n'' by the product of thes ...
for polynomials.
Birkhoff interpolation In mathematics, Birkhoff interpolation is an extension of polynomial interpolation. It refers to the problem of finding a polynomial P(x) of degree d such that ''only certain'' derivatives have specified values at specified points: : P^(x_i) = y_ ...
is a further generalization where only derivatives of some orders are prescribed, not necessarily all orders from 0 to a ''k''.
Collocation method In mathematics, a collocation method is a method for the numerical solution of ordinary differential equations, partial differential equations and integral equations. The idea is to choose a finite-dimensional space of candidate solutions (usually ...
s for the solution of differential and integral equations are based on polynomial interpolation. The technique of rational function modeling is a generalization that considers ratios of polynomial functions. At last,
multivariate interpolation In numerical analysis, multivariate interpolation or multidimensional interpolation is interpolation on ''multivariate functions'', having more than one variable or defined over a multi-dimensional domain. A common special case is bivariate inter ...
for higher dimensions.


See also

* Newton series *
Polynomial regression In statistics, polynomial regression is a form of regression analysis in which the relationship between the independent variable ''x'' and the dependent variable ''y'' is modeled as a polynomial in ''x''. Polynomial regression fits a nonlinear ...
* Spline smoothing


Notes


Citations


References

* * *


Further reading

* * * * * * J. L. Walsh: ''Interpolation and Approximation by Rational Functions in the Complex Domain'', AMS (Colloquium Publications, Vol.20), ISBN 0-8218-1020-0 (1960). Chapter VII:'Interpolation by Polynomials'.


External links

* {{springer, title=Interpolation process, id=p/i051970
ALGLIB
has an implementations in C++ / C#.
GSL
has a polynomial interpolation code in C
Polynomial Interpolation demonstration
Interpolation Polynomials Articles containing proofs