chebyshev, a MATLAB code which constructs the Chebyshev interpolant to a function.
Note that the user is not free to choose the interpolation points. Instead, the function f(x) will be evaluated at points chosen by the algorithm. In the standard case, in which the interpolation interval is [-1,+1], these points will be the zeros of the Chebyshev polynomial of order N. However, the algorithm can also be applied to an interval of the form [a,b], in which case the evaluation points are linearly mapped from [-1,+1].
The resulting interpolant is defined by a set of N coefficients c(), and has the form:
C(f)(x) = sum ( 1 <= i <= n ) c(i) T(i-1,x) - 0.5 * c(1)where T(i-1,x) is the (i-1)-th Chebyshev polynomial.
Within the interval [-1,+1], or the generalized interval [a,b], the interpolant actually remains bounded by the sum of the absolute values of the coefficients c(). It is therefore common to use Chebyshev interpolants as approximating functions over a given interval.
The computer code and data files described and made available on this web page are distributed under the GNU LGPL license.
chebyshev is available in a C version and a C++ version and a FORTRAN90 version and a MATLAB version.
bernstein_polynomial, a MATLAB code which evaluates the Bernstein polynomials, useful for uniform approximation of functions;
chebyshev_polynomial, a MATLAB code which evaluates the Chebyshev polynomial and associated functions.
chebyshev_series, a MATLAB code which can evaluate a Chebyshev series approximating a function f(x), while efficiently computing one, two or three derivatives of the series, which approximate f'(x), f''(x), and f'''(x), by Manfred Zimmer.
clausen, a MATLAB code which evaluates a Chebyshev approximant to the Clausen function Cl2(x).
divdif, a MATLAB code which computes interpolants by divided differences.
hermite_cubic, a MATLAB code which can compute the value, derivatives or integral of a Hermite cubic polynomial, or manipulate an interpolating function made up of piecewise Hermite cubic polynomials.
hermite_polynomial, a MATLAB code which computes the Hermite interpolant, a polynomial that matches function values and derivatives.
interp, a MATLAB code which can be used for parameterizing and interpolating data;
lagrange_interp_1d, a MATLAB code which defines and evaluates the Lagrange polynomial p(x) which interpolates a set of data, so that p(x(i)) = y(i).
rbf_interp_1d, a MATLAB code which defines and evaluates radial basis function (RBF) interpolants to 1D data.
shepard_interp_1d, a MATLAB code which defines and evaluates Shepard interpolants to 1D data, which are based on inverse distance weighting.
spline, a MATLAB code which includes many routines to construct and evaluate spline interpolants and approximants.
test_approx, a MATLAB code which defines test problems for approximation, provided as a set of (x,y) data.
test_interp_1d, a MATLAB code which defines test problems for interpolation of data y(x), depending on a 1D argument.
vandermonde_approx_1d, a MATLAB code which finds a polynomial approximant to a function of 1D data by setting up and solving an overdetermined linear system for the polynomial coefficients, involving the Vandermonde matrix.
vandermonde_interp_1d, a MATLAB code which finds a polynomial interpolant to a function of 1D data by setting up and solving a linear system for the polynomial coefficients, involving the Vandermonde matrix.