Skip to main content

eval_legendre

Function eval_legendre 

Source
pub fn eval_legendre<N, Z: JacobiArg<N>>(n: N, z: Z) -> Z
Expand description

Evaluate Legendre polynomial $P_n$ at a point.

Corresponds to scipy.special.eval_legendre, and xsf::eval_legendre.

§Definition

The Legendre polynomials can be defined via the Gauss hypergeometric function $_2F_1$ as

$$ P_n(z) = \hyp{2}{1}{-n,\enspace n+1}{1}{-{z-1 \over 2}} $$

When $n$ is an integer the result is a polynomial of degree $n$. See Abramowitz & Stegun 22.5.42 1 or DLMF 18.5.7 2 for details.

§See also

  • eval_jacobi: Evaluate Jacobi polynomials, $P_n^{(\alpha, \beta)}$
  • hyp2f1: Gauss’ hypergeometric function, $_2F_1$

  1. Milton Abramowitz and Irene A. Stegun, eds. Handbook of Mathematical Functions with Formulas, Graphs, and Mathematical Tables. New York: Dover, 1972. ↩

  2. NIST Digital Library of Mathematical Functions, https://dlmf.nist.gov/18.5.E7 ↩