E01AAF interpolates a function of one variable at a given point
x from a table of values
xi and
yi, for
i=1,2,…,n+1 using Aitken's method (see
Fröberg (1970)). The intermediate values of linear interpolations are stored to enable an estimate of the accuracy of the results to be made.
None.
An estimate of the accuracy of the result can be made from a comparison of the final result and the previous interpolates, given in the array
C. In particular, the first interpolate in the
ith set, for
i=1,2,…,n, is the value at
x of the polynomial interpolating the first
i+1 data points. It is given in position
i-12n-i+2/2 of the array
C. Ideally, providing
n is large enough, this set of
n interpolates should exhibit convergence to the final value, the difference between one interpolate and the next settling down to a roughly constant magnitude (but with varying sign). This magnitude indicates the size of the error (any subsequent increase meaning that the value of
n is too high). Better convergence will be obtained if the data points are supplied, not in their natural order, but ordered so that the first
i data points give good coverage of the neighbourhood of
x, for all
i. To this end, the following ordering is recommended as widely suitable: first the point nearest to
x, then the nearest point on the opposite side of
x, followed by the remaining points in increasing order of their distance from
x, that is of
xr-x. With this modification the Aitken method will generally perform better than the related method of Neville, which is often given in the literature as superior to that of Aitken.
This example interpolates at
x=0.28 the function value of a curve defined by the points