The Legendre polynomials are a sequence of polynomials that are mutually orthogonal on the interval with respect to ordinary integration. Under the standard normalization , each has degree and satisfies
They form one of the principal classical families of orthogonal polynomials, distinguished by a constant weight function and a close connection with the geometry of the sphere.
Named after Adrien-Marie Legendre, the polynomials entered mathematics through eighteenth-century investigations of gravitational attraction and potential theory. Their importance extends well beyond their original setting: they provide angular components of solutions to Laplace’s equation, determine the nodes of highly accurate numerical integration rules, and serve as basis functions for approximating functions and solving differential equations. Their differential equation, orthogonality, recurrence relations, and generating function are complementary descriptions of the same structure.
Definition, normalization, and historical setting
For nonnegative integers and , the defining orthogonality relation is
The integration weight is : no additional factor modifies the contribution of different points in the interval. Consequently, is orthogonal not only to the other Legendre polynomials of lower degree but to every polynomial of degree less than . Orthogonality together with uniquely determines the sequence.
The first six members are
These examples exhibit the parity relation
Thus even-degree members are even functions and odd-degree members are odd functions. At the endpoints,
The coefficient of is
The standard polynomials are therefore not monic, except in degrees zero and one.
Alternative normalizations are common and must be distinguished. The monic polynomial is , whereas the orthonormal polynomial is
The latter has squared integral equal to one. In probabilistic applications involving a uniform distribution on , the integration measure is instead ; the orthonormal functions are then . These changes alter numerical coefficients but not the roots or the underlying orthogonality.
Legendre’s work in the 1780s on the attraction of spheroids helped establish the polynomials in mathematical physics. Related investigations by Pierre-Simon Laplace placed such functions within the broader study of potentials and spherical expansions. In the nineteenth century, Rodrigues-type differentiation formulas, Gaussian quadrature, and Sturm–Liouville theory revealed their algebraic, numerical, and spectral roles.
A useful abstract construction starts with and applies the Gram–Schmidt process using the inner product
Normalizing each result to equal one at produces the Legendre sequence. This construction explains why Legendre polynomials provide a natural replacement for monomials when orthogonality is more useful than direct access to powers of .
Generating functions, Rodrigues’ formula, and recurrence relations
The principal generating function is
For real , this expansion converges for . Expanding the left-hand side in powers of gives all degrees simultaneously, while differentiation with respect to or produces identities connecting neighboring degrees. The square root is chosen to equal one at , which fixes the relevant analytic branch.
A second explicit construction is Rodrigues’ formula:
It immediately shows that the result is a polynomial of degree . More importantly, it proves orthogonality directly. If has degree less than , repeated integration by parts gives
All boundary terms vanish because has zeros of order at both endpoints. The remaining integral vanishes because .
Expanding Rodrigues’ formula yields the finite expression
Although exact, this formula is usually less suitable for numerical evaluation than a recurrence: the individual terms can become large and cancel strongly. Its main uses include symbolic manipulation, extraction of coefficients, and proofs of parity and leading-term formulas.
The standard three-term recurrence relation, often called Bonnet’s recurrence, is
Together with and , it generates the entire sequence. Rearranging it shows that multiplication by only couples neighboring degrees:
This sparse algebraic structure is central to quadrature algorithms and spectral discretizations.
Useful derivative identities include
and
The second identity also gives an antiderivative:
These relations allow differentiation, integration, and multiplication to be performed directly on Legendre expansions rather than by first converting them to monomials.
Differential equation and Sturm–Liouville structure
The Legendre equation is the second-order ordinary differential equation
When for a nonnegative integer , it has the polynomial solution . A power-series calculation explains the discrete parameter values. Substitution of gives
The even and odd coefficients evolve independently. If , the chain with the parity of terminates at degree , producing the polynomial solution.
The equation is naturally written in the self-adjoint form
This places the polynomials within Sturm–Liouville theory, where orthogonal functions arise as eigenfunctions of differential operators. Unlike a regular problem on a closed interval, the coefficient vanishes at the endpoints. Endpoint behavior must therefore be included in the operator’s definition. The standard Legendre realization selects the nonsingular endpoint behavior; its eigenfunctions are the , with eigenvalues .
The mechanism behind orthogonality can be seen without the full operator theory. Multiply the equations for and by and , respectively, subtract them, and integrate. This gives
The boundary expression is zero because the functions and their derivatives are finite while vanishes. Distinct eigenvalues then force the integral to vanish.
The same structure gives an energy identity:
It describes how the oscillatory complexity of the eigenfunction increases with degree. The constant function corresponds to eigenvalue zero, while every higher mode has positive energy.
A second linearly independent solution, conventionally denoted , is a Legendre function of the second kind, not a polynomial. For example, on ,
These functions have logarithmic endpoint singularities. Both and are needed for general local solutions, but only has the regularity appropriate to the usual angular problem on the whole sphere. Thus polynomial termination and endpoint regularity are two closely related ways of identifying the physically relevant discrete family.
Zeros, interlacing, and large-degree behavior
For every , has exactly distinct real zeros, all strictly inside . This is a general consequence of orthogonality with a positive weight. To see the essential argument, suppose that had fewer than sign-changing zeros in the interval. Multiplying it by the product of the corresponding linear factors would produce a function of constant sign, apart from its zeros. Its integral could not vanish, contradicting orthogonality to all polynomials of degree less than .
Parity makes the zeros symmetric about the origin. An odd-degree polynomial has a zero at , whereas an even-degree one does not. The zeros of consecutive degrees interlace: between any two neighboring zeros of lies exactly one zero of . Interlacing follows from the three-term recurrence or the oscillation theory of the differential equation. It supplies useful brackets for root-finding algorithms and explains why successive Gaussian quadrature rules distribute their nodes in a highly organized way.
On the whole interval,
One route to this bound uses the integral representation
The complex quantity inside the power has modulus at most one. Although the integrand is complex, its imaginary part cancels under integration, leaving the real polynomial. The bound is attained at the endpoints.
For large , behavior in the interior differs sharply from behavior near the endpoints. Writing , the leading interior asymptotic expansion is
uniformly when stays in a closed subinterval of . It shows oscillations that are approximately equally spaced in the angular coordinate , with amplitude of order away from the endpoints.
The empirical distribution of the zeros approaches the density
Consequently, zeros crowd near rather than being uniformly spaced in . The closest zeros lie at distances of order from the endpoints.
The interior cosine approximation does not remain uniform as . In an endpoint scaling, the limiting form instead involves Bessel functions:
This Mehler–Heine limit connects the smallest angular zeros to the positive zeros of . It also explains why accurate high-degree algorithms often use different approximations in the interior and in narrow endpoint regions.
Legendre series, completeness, and projection kernels
A square-integrable function on has a Legendre expansion
The coefficients are determined by orthogonality, in the same general manner as the coefficients of a Fourier series. The essential difference is that the basis functions are algebraic polynomials rather than sines and cosines. No periodic extension of the function is built into the basis.
The sequence is complete in the Hilbert space : if a square-integrable function is orthogonal to every , it is zero almost everywhere. One explanation combines the fact that span all polynomials of degree at most with the density of polynomials in . Completeness implies convergence of the partial sums
to in the norm.
Each partial sum is the orthogonal projection onto the polynomial subspace of degree at most . It therefore uniquely minimizes
over all polynomials of that degree. Orthogonality also gives Parseval’s identity,
and the exact truncation-error formula
These identities distinguish convergence in mean square from stronger claims about values at individual points.
Projection can also be written as an integral:
where
The Christoffel–Darboux identity compresses this sum to
The value on the diagonal follows by a limit. This kernel reproduces every polynomial of degree at most , making it useful in interpolation theory and estimates for polynomial approximation.
Pointwise and uniform convergence require additional hypotheses. Mean-square convergence alone does not imply convergence at every point. Smoothness generally produces faster coefficient decay, while analyticity in a complex neighborhood of the interval gives geometric decay and correspondingly rapid approximation. Discontinuities can produce local oscillations analogous to the Gibbs phenomenon in Fourier analysis. Endpoint behavior also matters because the magnitude of individual basis functions and of the projection kernel is not spatially uniform. Legendre series are therefore best understood through both function-space convergence and local regularity, rather than through a single universal convergence rule.
Gauss–Legendre quadrature
The zeros of are the nodes of Gauss–Legendre quadrature, a central instance of Gaussian quadrature. If these zeros are , the rule is
with
Every weight is positive, and the weights sum to . The remarkable property is exactness for every polynomial of degree at most , even though the rule uses only function values.
Orthogonality explains this degree of exactness. Given a polynomial of degree at most , polynomial division gives
The integral of is zero by orthogonality, while at every node. Integrating the degree- interpolant of therefore integrates exactly. No rule with distinct real nodes can integrate every polynomial of degree : the square of the product of the node factors vanishes at all nodes but has strictly positive integral.
For example, the two-point rule has nodes , each with weight :
It is exact through degree three. The three-point rule uses nodes , with weights , respectively, and is exact through degree five.
If has a continuous derivative of order , the error has the form
for some . This expression is a theoretical error statement rather than an automatic practical estimator, since the relevant derivative may be difficult to bound.
Rules on a finite interval follow from
The transformed nodes are , and each weight is multiplied by . Endpoint-inclusive alternatives include Gauss–Lobatto–Legendre rules: with total nodes, they use both endpoints and the zeros of , and are exact through degree .
A powerful computational interpretation comes from the orthonormal recurrence
The eigenvalues of the resulting symmetric tridiagonal matrix are the Gaussian nodes. The weights are twice the squared first components of its normalized eigenvectors. This is the Legendre instance of the Golub–Welsch algorithm, connecting numerical integration directly with matrix eigenvalue problems.
Spherical geometry and potential theory
Legendre polynomials arise from separating Laplace’s equation in spherical coordinates. For an axisymmetric potential , independent of the azimuthal angle, write
Separation leads to the angular equation
The substitution turns it into the Legendre equation. Regularity at both poles selects and , where is a nonnegative integer.
The radial equation is
with solutions and . Consequently, an axisymmetric harmonic potential can be expanded in terms of
Regularity at the origin eliminates the negative powers in an interior problem, while decay at infinity eliminates the growing powers in an exterior problem. Boundary data on a sphere determine the remaining coefficients through Legendre orthogonality.
The generating function has an immediate physical interpretation. Let be the angle between vectors and , and put , . For ,
This expands the inverse-distance kernel governing Newtonian gravitational and electrostatic potentials. The terms of degree zero, one, and two give the monopole, dipole, and quadrupole angular structures. Higher terms describe progressively finer spatial organization of the source.
For non-axisymmetric functions, the natural objects are spherical harmonics, denoted . Their connection to the ordinary Legendre polynomials is expressed by the addition theorem:
assuming the spherical harmonics are orthonormal on the unit sphere. The left side depends only on the angle between the directions, whereas the right side resolves that rotationally invariant quantity into coordinate-dependent components.
Legendre expansions also describe rotationally symmetric integral kernels on the sphere. For example, an isotropic covariance function can be expanded in , with angular power assigned to each degree. In scattering theory, an amplitude depending only on scattering angle is often decomposed into Legendre modes, called partial waves in the appropriate physical setting. In each case, degree labels an angular scale, while spherical symmetry prevents different degrees from mixing under rotationally invariant operations.
Associated functions and related polynomial families
When azimuthal dependence is retained in spherical separation, the angular equation acquires an additional term:
For integers , a standard solution is
These are the associated Legendre functions. The factor is the Condon–Shortley phase; some conventions omit it. For odd , the factor means that the function is not an ordinary polynomial in , despite the traditional expression “associated Legendre polynomial.”
For fixed , their orthogonality is
Combining with gives the angular dependence of spherical harmonics. Negative integer orders are related by
Normalization and phase conventions are especially important when comparing mathematical tables, geophysical models, and quantum-mechanical formulas.
Ordinary Legendre polynomials are also special cases of larger orthogonal families. In the standard normalization of the Jacobi polynomials,
Jacobi polynomials are orthogonal with weight , for ; setting both parameters to zero produces the constant Legendre weight. Similarly,
where denotes a Gegenbauer polynomial. The Gegenbauer family extends the spherical setting to angular problems in other dimensions.
A hypergeometric representation is
The hypergeometric series terminates because one upper parameter is the nonpositive integer . Replacing by a general degree leads to Legendre functions that need not be polynomials. Such extensions require attention to branches and singularities, particularly for complex arguments or for arguments outside .
A frequently used interval transformation defines the shifted Legendre polynomials
Their orthogonality is
They are convenient when the natural domain is a probability interval, a finite time segment, or a standard finite element. This shift changes the argument and integration scale, not the essential polynomial family.
Numerical evaluation and spectral approximation
For moderate degree and , the three-term recurrence is the standard way to compute Legendre polynomials. It avoids the factorials and large alternating terms in explicit coefficient formulas. Starting with and , it computes all values through degree using a number of arithmetic operations proportional to . Nevertheless, relative errors can be large near a zero because the exact value is small, even when absolute errors remain modest. This distinction is important in discussions of numerical stability.
A whole Legendre series can be evaluated without storing every polynomial by Clenshaw’s algorithm, a backward recurrence adapted to the three-term relation. Derivatives can likewise be computed by differentiating the recurrence. The identity
is useful away from the endpoints but can suffer cancellation close to . At the endpoints, exact formulas are preferable:
Legendre polynomials are fundamental basis functions in a spectral method for differential equations. A solution is approximated as
and the differential equation is enforced either weakly, through weighted integrals, or at selected collocation points. Orthogonality makes the unweighted mass matrix diagonal:
This contrasts with a monomial basis, whose integral matrix becomes badly conditioned as degree increases.
Boundary conditions can be built into modified bases. For a homogeneous Dirichlet problem, the functions
vanish at both endpoints. Their derivatives satisfy
so the stiffness matrix for the operator is diagonal:
This illustrates how identities specific to the polynomial family can simplify a differential-equation solver.
Legendre bases also appear in high-order versions of the finite element method, where each mesh element carries a local polynomial expansion. Gauss–Lobatto points provide endpoint degrees of freedom, making it convenient to connect neighboring elements. Their quadrature does not integrate every product of degree- basis functions exactly, since such products can have degree , one above the rule’s exactness threshold. The resulting distinction between exact and quadrature-based mass matrices matters in spectral-element implementations.
In uncertainty quantification, Legendre polynomials form the natural polynomial-chaos basis for uniformly distributed inputs. Products of one-dimensional orthonormal Legendre polynomials provide bases for several independent uniform variables. Expansion coefficients then encode means and variances through orthogonality, while truncating the basis gives a finite surrogate model. The number of multivariate terms grows rapidly with dimension, so sparse truncation and adaptive selection are often as important as the efficiency of the underlying one-dimensional recurrences.