legendre(n, monic=False)
Defined to be the solution of
$$\frac{d}{dx}\left[(1 - x^2)\frac{d}{dx}P_n(x)\right] + n(n + 1)P_n(x) = 0;$$$P_n(x)$ is a polynomial of degree $n$ .
The polynomials $P_n$ are orthogonal over $[-1, 1]$ with weight function 1.
Degree of the polynomial.
If :None:None:`True`
, scale the leading coefficient to be 1. Default is :None:None:`False`
.
Legendre polynomial.
Legendre polynomial.
Generate the 3rd-order Legendre polynomial 1/2*(5x^3 + 0x^2 - 3x + 0):
>>> from scipy.special import legendreSee :
... legendre(3) poly1d([ 2.5, 0. , -1.5, 0. ])
The following pages refer to to this document either explicitly or contain code examples using this.
scipy.special._orthogonal.legendre
Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.
Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)
SVG is more flexible but power hungry; and does not scale well to 50 + nodes.
All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them