DiscretePolynomialEnsembles
Documentation for DiscretePolynomialEnsembles.
Exported Functionality
DiscretePolynomialEnsembles.DiscretePolynomialEnsemble — Type
DiscretePolynomialEnsemble <: PolynomialEnsembleAbstract type for discrete polynomial ensembles.
Interface
Subtypes must implement:
ensemble[n](x): evaluate basis polynomial of degreenatxweight(ensemble, x): weight function atxLinearAlgebra.norm_sqr(ensemble[n]): squared norm of basis elementnfraction_leading_coefficients(ensemble, n): ratio of leading coefficients of degreesnandn-1
Optionally implement transform(ensemble, x) for coordinate transformations (default: identity).
DiscretePolynomialEnsembles.Kernel — Type
Kernel(ensemble, n)A rank-n kernel for ensemble constructed from the first n basis elements, using the Christoffel-Darboux formula.
DiscretePolynomialEnsembles.weight — Function
weight(ensemble, x)Weight function of ensemble at point x.
Available Ensembles
DiscretePolynomialEnsembles.BesselJ — Type
BesselJ(; θ)Bessel J ensemble with parameter θ > 0. Construct the Bessel kernel via Kernel(ensemble).
DiscretePolynomialEnsembles.Charlier — Type
Charlier(; a)Charlier polynomial ensemble with parameter a > 0.
DiscretePolynomialEnsembles.DiscreteLegendre — Type
DiscreteLegendre(; N)Discrete Legendre polynomial ensemble on {0, 1, ..., N}.
DiscretePolynomialEnsembles.Hahn — Type
Hahn(; α, β, M)Hahn polynomial ensemble with parameters α > -1, β > -1, and integer M.
DiscretePolynomialEnsembles.Krawtchouk — Type
Krawtchouk(; K, p)Krawtchouk polynomial ensemble with parameters K (number of trials) and 0 < p < 1 (success probability).
DiscretePolynomialEnsembles.Lanczos — Type
Lanczos(w, domain; ν = identity, simplify = identity)Orthonormal polynomial ensemble via Lanczos algorithm with weight function w on domain. If a transformation ν is specified, the inner product used for orthonormalization is $⟨f, g⟩ = ∑_{x ∈ 𝒟} w(x) f(ν(x)) g(ν(x))$ and the polynomials will be over ν(x).
DiscretePolynomialEnsembles.LanczosMonic — Type
LanczosMonic(w, domain; ν = identity, simplify = identity)Monic polynomial ensemble via Lanczos algorithm with weight function w on domain. If a transformation ν is specified, the inner product used for orthogonalization is $⟨f, g⟩ = ∑_{x ∈ 𝒟} w(x) f(ν(x)) g(ν(x))$ and the polynomials will be over ν(x).
DiscretePolynomialEnsembles.Meixner — Type
Meixner(; K, q)Meixner polynomial ensemble with parameters K > 0 and 0 < q < 1.
Internal Functions
DiscretePolynomialEnsembles.dJdν — Function
dJdν(ν, z, precision = 1.0e-14, max_steps = 10^6; prec)Compute the derivative of the Bessel function J_ν(z) with respect to ν.
DiscretePolynomialEnsembles.digamma_over_gamma — Method
digamma_over_gamma(n)Compute digamma(n)/gamma(n), handling the case when n is a non-positive integer.
DiscretePolynomialEnsembles.fraction_leading_coefficients — Function
fraction_leading_coefficients(ensemble, n)Ratio of leading coefficients κₙ₋₁/κₙ for basis polynomials of degrees n and n-1.
DiscretePolynomialEnsembles.grad_pfq — Function
grad_pFq(pfq_val, a, b, z, precision = 1.0e-14, max_steps = 10^6; prec)Returns the gradient of the generalized hypergeometric function wrt to the input arguments:
\[ _pF_q(a_1,...,a_p;b_1,...,b_q;z)\]
Where:
\[ \frac{\partial }{\partial a_1} = \sum_{k=1}^{\infty}{ \frac {\left(1 + \sum_{m=0}^{k-1}\frac{1}{m+a_1}\right) * \left(\prod_{j=1}^p\left(a_j\right)_k\right)z^k} {k!\prod_{j=1}^q\left(b_j\right)_k}} - {}_pF_q(a_1,...,a_p;b_1,...,b_q;z)\]
\[ \frac{\partial }{\partial b_1} = {}_pF_q(a_1,...,a_p;b_1,...,b_q;z) - \sum_{k=1}^{\infty}{ \frac {\left(1 + \sum_{m=0}^{k-1}\frac{1}{m+b_1}\right) * \left(\prod_{j=1}^p\left(a_j\right)_k\right)z^k} {k!\prod_{j=1}^q\left(b_j\right)_k}}\]
\[ \frac{\partial }{\partial z} = \frac{\prod_{j=1}^{p}(a_j)}{\prod_{j=1}^{q} (b_j)}\ {}_pF_q(a_1+1,...,a_p+1;b_1+1,...,b_q+1;z)\]
Noting the the recurrence relation for the digamma function: $\psi(x + 1) = \psi(x) + \frac{1}{x}$, the gradients for the function with respect to a and b then simplify to:
\[ \frac{\partial }{\partial a_1} = \sum_{k=1}^{\infty}{ \frac {\left(1 + \sum_{m=0}^{k-1}\frac{1}{m+a_1}\right) * \left(\prod_{j=1}^p\left(a_j\right)_k\right)z^k} {k!\prod_{j=1}^q\left(b_j\right)_k}} - {}_pF_q(a_1,...,a_p;b_1,...,b_q;z)\]
\[ \frac{\partial }{\partial b_1} = {}_pF_q(a_1,...,a_p;b_1,...,b_q;z) - \sum_{k=1}^{\infty}{ \frac {\left(1 + \sum_{m=0}^{k-1}\frac{1}{m+b_1}\right) * \left(\prod_{j=1}^p\left(a_j\right)_k\right)z^k} {k!\prod_{j=1}^q\left(b_j\right)_k}}\]
DiscretePolynomialEnsembles.transform — Method
transform(ensemble, x)Coordinate transformation applied before polynomial evaluation. Default: identity.
LinearAlgebra.norm_sqr — Method
norm_sqr(ensemble[n])Squared L² norm of basis element n with respect to the ensemble weight.