Clenshaw–Curtis quadrature and Fejér quadrature are methods for
numerical integration
In analysis, numerical integration comprises a broad family of algorithms for calculating the numerical value of a definite integral, and by extension, the term is also sometimes used to describe the numerical solution of differential equatio ...
, or "quadrature", that are based on an expansion of the
integrand in terms of
Chebyshev polynomials
The Chebyshev polynomials are two sequences of polynomials related to the trigonometric functions, cosine and sine functions, notated as T_n(x) and U_n(x). They can be defined in several equivalent ways, one of which starts with trigonometric ...
. Equivalently, they employ a
change of variables
Change or Changing may refer to:
Alteration
* Impermanence, a difference in a state of affairs at different points in time
* Menopause, also referred to as "the change", the permanent cessation of the menstrual period
* Metamorphosis, or change, ...
and use a
discrete cosine transform (DCT) approximation for the
cosine series. Besides having fast-converging accuracy comparable to
Gaussian quadrature
In numerical analysis, a quadrature rule is an approximation of the definite integral of a function, usually stated as a weighted sum of function values at specified points within the domain of integration. (See numerical integration for mor ...
rules, Clenshaw–Curtis quadrature naturally leads to
nested quadrature rules (where different accuracy orders share points), which is important for both
adaptive quadrature
Adaptive quadrature is a numerical integration method in which the integral of a function f(x) is approximated using static quadrature rules on adaptively refined subintervals of the region of integration. Generally, adaptive algorithms are just ...
and multidimensional quadrature (
cubature
In Numerical analysis, analysis, numerical integration comprises a broad family of algorithms for calculating the numerical value of a definite integral, and by extension, the term is also sometimes used to describe the numerical ordinary differ ...
).
Briefly, the
function
Function or functionality may refer to:
Computing
* Function key, a type of key on computer keyboards
* Function model, a structured representation of processes in a system
* Function object or functor or functionoid, a concept of object-oriente ...
to be integrated is evaluated at the
extrema or roots of a Chebyshev polynomial and these values are used to construct a polynomial approximation for the function. This polynomial is then integrated exactly. In practice, the integration weights for the value of the function at each node are precomputed, and this computation can be performed in
time by means of
fast Fourier transform
A fast Fourier transform (FFT) is an algorithm that computes the discrete Fourier transform (DFT) of a sequence, or its inverse (IDFT). Fourier analysis converts a signal from its original domain (often time or space) to a representation in ...
-related algorithms for the DCT.
[W. Morven Gentleman, "Implementing Clenshaw-Curtis quadrature I: Methodology and experience," ''Communications of the ACM'' 15(5), p. 337-342 (1972).][Jörg Waldvogel,]
Fast construction of the Fejér and Clenshaw-Curtis quadrature rules
" ''BIT Numerical Mathematics'' 46 (1), p. 195-202 (2006).
General method
A simple way of understanding the algorithm is to realize that Clenshaw–Curtis quadrature (proposed by those authors in 1960)
[C. W. Clenshaw and A. R. Curtis]
A method for numerical integration on an automatic computer
''Numerische Mathematik'' 2, 197 (1960). amounts to integrating via a
change of variable
Change or Changing may refer to:
Alteration
* Impermanence, a difference in a state of affairs at different points in time
* Menopause, also referred to as "the change", the permanent cessation of the menstrual period
* Metamorphosis, or change, ...
. The algorithm is normally expressed for integration of a function over the interval
��1,1(any other interval can be obtained by appropriate rescaling). For this integral, we can write:
That is, we have transformed the problem from integrating
to one of integrating
. This can be performed if we know the
cosine series for
:
in which case the integral becomes:
Of course, in order to calculate the cosine series coefficients
one must again perform a numeric integration, so at first this may not seem to have simplified the problem. Unlike computation of arbitrary integrals, however, Fourier-series integrations for
periodic functions
A periodic function is a function that repeats its values at regular intervals. For example, the trigonometric functions, which repeat at intervals of 2\pi radians, are periodic functions. Periodic functions are used throughout science to de ...
(like
, by construction), up to the
Nyquist frequency
In signal processing, the Nyquist frequency (or folding frequency), named after Harry Nyquist, is a characteristic of a sampler, which converts a continuous function or signal into a discrete sequence. In units of cycles per second ( Hz), it ...
, are accurately computed by the
equally spaced and equally weighted points
for
(except the endpoints are weighted by 1/2, to avoid double-counting, equivalent to the
trapezoidal rule
In calculus, the trapezoidal rule (also known as the trapezoid rule or trapezium rule; see Trapezoid for more information on terminology) is a technique for approximating the definite integral.
\int_a^b f(x) \, dx.
The trapezoidal rule works by ...
or the
Euler–Maclaurin formula). That is, we approximate the cosine-series integral by the type-I
discrete cosine transform (DCT):