TEST_INTERP_FUN
Interpolation Tests Based on Functions
TEST_INTERP_FUN
is a C library which
can provide the values of certain functions that are useful for
testing an interpolation algorithm using a varying number of points.
The related packages TEST_INTERP and TEST_APPROX provide
discrete data sets of (x,y) pairs. However, when the convergence rate
of an interpolation process is of interest, it is important to be able
to sample an underlying but "unknown" function at an increasing number of
points. This library provides a few functions which are known to cause
problems for certain kinds of interpolation schemes.
The problems available include:
-
Runge example, f(x) = 1 / ( x * x + 1 ), [-5,5],
p01_plot.png;
-
Bernstein example, f(x) = abs ( x ), [-1,1],
p02_plot.png;
-
The Step function,
p03_plot.png;
-
The Doppler function,
p04_plot.png;
-
The Rabbit Ears function,
p05_plot.png;
Licensing:
The computer code and data files described and made available on this web page
are distributed under
the GNU LGPL license.
Languages:
TEST_INTERP_FUN is available in
a C version and
a C++ version and
a FORTRAN90 version and
a MATLAB version.
Related Data and Programs:
CHEBYSHEV,
a C library which
computes the Chebyshev interpolant/approximant to a given function
over an interval.
DIVDIF,
a C library which
includes many routines to construct and evaluate divided difference
interpolants.
RBF_INTERP,
a C library which
defines and evaluates radial basis function (RBF) interpolants to multidimensional data.
SPLINE,
a C library which
includes many routines to construct and evaluate spline
interpolants and approximants.
TEST_APPROX,
a C library which
defines test problems for approximation,
provided as a set of (x,y) data.
TEST_INTERP,
a C library which
defines a number of test problems for interpolation,
provided as a set of (x,y) data.
Reference:
-
Samuel Conte, Carl deBoor,
Elementary Numerical Analysis,
Second Edition,
McGraw Hill, 1972,
ISBN: 07-012446-4,
LC: QA297.C65.
-
Carl deBoor,
A Practical Guide to Splines,
Springer, 2001,
ISBN: 0387953663,
LC: QA1.A647.v27.
Source Code:
Examples and Tests:
List of Routines:
-
P00_FUN evaluates the function for any problem.
-
P00_LIM returns the limits of the approximation interval for any problem.
-
P00_PROB_NUM returns the number of problems.
-
P00_STORY prints the "story" for any problem.
-
P00_TITLE returns the title of any problem.
-
P01_FUN evaluates the function for problem 1.
-
P01_LIM returns the limits of the approximation interval for problem 1.
-
P01_STORY prints the "story" for problem 1.
-
P01_TITLE returns the title of problem 1.
-
P02_FUN evaluates the function for problem 2.
-
P02_LIM returns the limits of the approximation interval for problem 2.
-
P02_STORY prints the "story" for problem 2.
-
P02_TITLE returns the title of problem 2.
-
P03_FUN evaluates the function for problem 3.
-
P03_LIM returns the limits of the approximation interval for problem 3.
-
P03_STORY prints the "story" for problem 3.
-
P03_TITLE returns the title of problem 3.
-
P04_FUN evaluates the function for problem 4.
-
P04_LIM returns the limits of the approximation interval for problem 4.
-
P04_STORY prints the "story" for problem 4.
-
P04_TITLE returns the title of problem 4.
-
P05_FUN evaluates the function for problem 5.
-
P05_LIM returns the limits of the approximation interval for problem 5.
-
P05_STORY prints the "story" for problem 5.
-
P05_TITLE returns the title of problem 5.
-
R8_ABS returns the absolute value of an R8.
-
R8_MAX returns the maximum of two R8's.
You can go up one level to
the C source codes.
Last revised on 18 February 2012.