scipy 1.8.0 Pypi GitHub Homepage
Other Docs
NotesParametersReturnsBackRef
genlaguerre(n, alpha, monic=False)

Defined to be the solution of

$$x\frac{d^2}{dx^2}L_n^{(\alpha)} + (\alpha + 1 - x)\frac{d}{dx}L_n^{(\alpha)} + nL_n^{(\alpha)} = 0,$$

where $\alpha > -1$ ; $L_n^{(\alpha)}$ is a polynomial of degree $n$ .

Notes

For fixed $\alpha$ , the polynomials $L_n^{(\alpha)}$ are orthogonal over $[0, \infty)$ with weight function $e^{-x}x^\alpha$ .

The Laguerre polynomials are the special case where $\alpha = 0$ .

Parameters

n : int

Degree of the polynomial.

alpha : float

Parameter, must be greater than -1.

monic : bool, optional

If :None:None:`True`, scale the leading coefficient to be 1. Default is :None:None:`False`.

Returns

L : orthopoly1d

Generalized Laguerre polynomial.

Generalized (associated) Laguerre polynomial.

See Also

hyp1f1

confluent hypergeometric function

laguerre

Laguerre polynomial.

Examples

The generalized Laguerre polynomials are closely related to the confluent hypergeometric function ${}_1F_1$ :

$$L_n^{(\alpha)} = \binom{n + \alpha}{n} {}_1F_1(-n, \alpha +1, x)$$

This can be verified, for example, for $n = \alpha = 3$ over the interval $[-1, 1]$ :

>>> from scipy.special import binom
... from scipy.special import genlaguerre
... from scipy.special import hyp1f1
... x = np.arange(-1.0, 1.0, 0.01)
... np.allclose(genlaguerre(3, 3)(x), binom(6, 3) * hyp1f1(-3, 4, x)) True

This is the plot of the generalized Laguerre polynomials $L_3^{(\alpha)}$ for some values of $\alpha$ :

>>> import matplotlib.pyplot as plt
... from scipy.special import genlaguerre
... x = np.arange(-4.0, 12.0, 0.01)
... fig, ax = plt.subplots()
... ax.set_ylim(-5.0, 10.0)
... ax.set_title(r'Generalized Laguerre polynomials $L_3^{\alpha}$')
... for alpha in np.arange(0, 5):
...  ax.plot(x, genlaguerre(3, alpha)(x), label=rf'$L_3^{(alpha)}$')
... plt.legend(loc='best')
... plt.show()
See :

Back References

The following pages refer to to this document either explicitly or contain code examples using this.

scipy.special._orthogonal.genlaguerre scipy.special._orthogonal.laguerre

Local connectivity graph

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


GitHub : /scipy/special/_orthogonal.py#557
type: <class 'function'>
Commit: