next up previous
Next: Generalized Lagrange Interpolation Up: interpolation Previous: interpolation

Lagrange Interpolation

Let's generalize the linear interpolation by denoting the values in the table by $(x_i,y_i)$ for $i = 0,\ldots{},n$. Then a linear function interpolating the first two values can be written as

P_{0,1}(x) = y_0\frac{x - x_1}{x_0 - x_1} +
y_1\frac{x - x_0}{x_1 - x_0}.

Since every term here is a constant except $x$, it is easy to see that the polynomial $P_{0,1}$ has degree 1 at most. It also satisfies

P_{0,1}(x_0) = y_0     P_{0,1}(x_1) = y_1,

as is required for an interpolation of the two values.

The linear interpolation can also be written in the form

P_{0,1}(x) = y_0 L^{(1)}_0(x) + y_1 L^{(1)}_1(x)


L^{(1)}_0(x) &=& \frac{x - x_1}{x_0 - x_1} \\
L^{(1)}_1(x) &=& \frac{x - x_0}{x_1 - x_0}

These are examples of Lagrange interpolating polynomials. They have the property

L^{(1)}_0(x_0) = 1,   L^{(1)}_0(x_1) = 0,   L^{(1)}_1(x_0) = 0,   L^{(1)}_1(x_1) = 1,

that is, $L^{(1)}_i(x_j) = \delta_{i,j}$.