Aitken’s and Neville’s Interpolation
Source inspiration: (Mathew 2000-2019).
Description
Neville’s interpolation algorithm evaluates the unique polynomial of degree at most \(n-1\) through data points \((x_i,y_i)\) without first converting to expanded polynomial coefficients. It uses a recursive tableau
\[ P_{i,i}(x)=y_i, \qquad P_{i,j}(x)=\frac{(x-x_i)P_{i+1,j}(x)-(x-x_j)P_{i,j-1}(x)}{x_j-x_i}, \quad i<j. \]
Here \(P_{i,j}\) is the interpolant on the consecutive nodes \(x_i,\dots,x_j\), and the final interpolated value at a query point \(x\) is \(P_{0,n-1}(x)\). Aitken’s scheme is a different arrangement of the same idea, repeated linear interpolation. With \(Q_{0,j}=y_j\), and \(Q_{k,j}\) the interpolant on \(x_0,\dots,x_{k-1},x_j\), it computes
\[ Q_{k,j}(x)=\frac{(x-x_{k-1})\,Q_{k-1,j}(x)-(x-x_j)\,Q_{k-1,k-1}(x)}{x_j-x_{k-1}}, \qquad j\ge k. \]
At stage \(k\) it combines the interpolant on \(x_0,\dots,x_{k-1}\) with the interpolant on \(x_0,\dots,x_{k-2},x_j\), so every entry in a column shares the same leading nodes, whereas Neville’s scheme combines interpolants on neighbouring runs of consecutive nodes. Entries built on different sets of nodes generally differ, but both schemes compute the interpolant on \(x_0,\dots,x_k\) for every \(k\), so they produce the same sequence \(Q_{k,k}=P_{0,k}\), \(k=0,\dots,n-1\) (the diagonal of Mathews’ two tableaux), and end with the same interpolated value. The animations below use Neville’s scheme.
Both recursions need only the values \(y_i\) and distinct nodes, since they divide by node differences; the nodes need not be equally spaced. Each query point costs \(n(n-1)/2\) new tableau entries.
In general, if \(y_i=f(x_i)\) and \(f\in C^{j+1}\) on an interval \(I\) that contains \(x\) and the nodes \(x_0,\dots,x_j\), the polynomial is the same as the Lagrange interpolant and has the same remainder term: for some \(c\in I\),
\[ f(x)-P_{0,j}(x)=\frac{f^{(j+1)}(c)}{(j+1)!}\prod_{i=0}^{j}(x-x_i). \]
Since \(f-P_{0,j-1}=(P_{0,j}-P_{0,j-1})+(f-P_{0,j})\), the change between successive diagonal entries estimates the error of the earlier one, and Mathews tests convergence on these values. Case 2 shows both: each error at \(\hat x=1.8\) lies within the remainder bounds with \(e^1\le f^{(j+1)}(c)\le e^{\max(x_j,1.8)}\), and the changes 2.47, 0.772, 0.0877, \(1.25\times10^{-3}\), \(-5.66\times10^{-5}\) track the errors 3.33, 0.861, 0.0889, \(1.19\times10^{-3}\), \(-5.23\times10^{-5}\) of \(P_{0,0},\dots,P_{0,4}\).
Adding a node does not guarantee a smaller error. In Case 1, \(P_{0,2}\) uses only \(0,\pi/4,\pi/2\), so at \(x=\pi\) it extrapolates: the product \(\prod_i(x-x_i)\) is 11.6 there, against at most 0.19 between the nodes, and the largest error on \([0,\pi]\) rises from 0.90 to 1.66. The convergence test can also mislead: in Case 1, \(P_{0,4}=P_{0,3}\), so the last change is zero everywhere, yet \(P_{0,3}\) is in error by up to \(8.1\times10^{-3}\) on \([0,\pi]\).
The polynomial is the one the Lagrange and Newton forms give; Chebyshev Approximation chooses nodes that keep the product term small, Romberg Integration is Neville’s scheme in the variable \(h^2\), applied to trapezoidal sums and evaluated at \(h^2=0\), and Aitken’s interpolation is a different method from Aitken’s \(\Delta^2\) acceleration.
Animations
The animations below illustrate Neville’s algorithm for polynomial interpolation. Each frame adds one node and shows \(P_{0,j}(x)\), the interpolant of degree at most \(j\) through the first \(j+1\) nodes: Case 1 uses \(f(x) = \cos(x)\) at 5 nodes \(x_0 = 0,\, \tfrac{\pi}{4},\, \tfrac{\pi}{2},\, \tfrac{3\pi}{4},\, \pi\) (\(j=0,\dots,4\)), and Case 2 uses \(f(x)=e^x\) at 6 nodes \(x_i = 1 + i/4\) (\(j=0,\dots,5\)).
Julia source scripts that generated these animations are linked under each case.
No archived animation GIF is available for this topic in the current snapshot; Mathews’ module has only static examples. Case 2 animates the module’s Example 3: \(e^x\) at the nodes \(x_i = 1 + i/4\), \(i=0,\dots,5\), evaluated at \(\hat x = 1.8\). Case 1 is the page’s own example, chosen to show that adding a node can increase the error and that symmetric nodes can make \(P_{0,4}=P_{0,3}\). The module’s other examples, 1, 2 and 4–7, are not animated here. Example 1 builds a quadratic through three nodes by recursion and plots the function with each linear interpolant and the quadratic. Examples 2–7 fill in Aitken’s and Neville’s tableaux at a single evaluation point, and Examples 3–5 also plot the function with the successive interpolants through the first one, two, three, … of their nodes (up to degree 3, 4 and 2 respectively), the kind of picture these animations build frame by frame, drawn there as one static plot; Case 2 carries Example 3’s picture on to degree 5. The explorations the module links to on its Theory and Proof page are not animated here either.
Case 1 — Neville’s algorithm: \(P_{0,0}\) through \(P_{0,4}\) for \(\cos(x)\)
Behavior: Neville’s algorithm builds the interpolating polynomial of degree at most \(n\) by combining two polynomials of degree at most \(n-1\): \(P_{i,j}(x) = \tfrac{(x-x_i)P_{i+1,j} - (x-x_j)P_{i,j-1}}{x_j - x_i}\). Adding a node does not always reduce the error: the largest error \(|P_{0,j}(x)-\cos x|\) on \([0,\pi]\) falls from 2.00 at \(j=0\) to 0.90 at \(j=1\), rises to 1.66 at \(j=2\) (at \(x=\pi\), where the quadratic reaches \(-2.66\)), then drops to \(8.1\times10^{-3}\) at \(j=3\). With these symmetric nodes the cubic \(P_{0,3}\) already passes through \((\pi,-1)\), because \(\cos\) is odd about \(\pi/2\), so the fifth node leaves the polynomial unchanged: \(P_{0,4}=P_{0,3}\), and the last two frames show the same curve.

Case 2 — Mathews’ Example 3: \(P_{0,0}\) through \(P_{0,5}\) for \(e^x\) at \(\hat x = 1.8\)
Behavior: The nodes are \(x_i = 1 + i/4\) (\(1, 1.25, \dots, 2.25\)), and each frame marks \(P_{0,j}(1.8)\), the top-row entry of Neville’s tableau. The values 2.718282, 5.188877, 5.960761, 6.048454, 6.049700 and 6.049643 match the diagonal of Mathews’ Neville tableau and approach \(e^{1.8}=6.049647\). Here every added node helps: the error \(e^{1.8}-P_{0,j}(1.8)\) falls in size at each step, through 3.33, 0.861, 0.0889, \(1.19\times10^{-3}\), \(-5.23\times10^{-5}\) and \(4.34\times10^{-6}\) (negative only at \(j=4\)), and the largest error on \([1,2.25]\) also falls at each step, from 6.77 at \(j=0\) to \(3.2\times10^{-5}\) at \(j=5\). From \(j=4\) on, \(P_{0,j}\) and \(e^x\) are indistinguishable at the plot’s scale (at \(j=3\) they part only toward the right edge), so the legend carries the values at \(\hat x\).
