<< legendre_pdf Legendre legendre_quadrature >>

Orthogonal Polynomials >> Orthogonal Polynomials > Legendre > legendre_poly

legendre_poly

Create Legendre polynomial

Calling Sequence

y=legendre_poly(n)

Parameters

n :

a 1-by-1 matrix of doubles, integer value, n>=0.

y :

a polynomial

Description

Create a Legendre polynomial of degree n at point x. To evaluate it, we can use the horner function, but legendre_eval might be faster and more accurate.

The Legendre polynomials are orthogonals with respect to the scalar product :

where w(x) is the Legendre weight.

Examples

for n=0:10
y=legendre_poly(n)
end

Authors


Report an issue
<< legendre_pdf Legendre legendre_quadrature >>