PolynomialNumberTheoryFunctionsΒΆ
numtheor.spad line 451 [edit on github]
This package provides various polynomial number theoretic functions over the integers.
- bernoulli: Integer -> SparseUnivariatePolynomial Fraction Integer
bernoulli(n)returns thenth Bernoulli polynomialB[n](x). Note: Bernoulli polynomials denotedB(n, x)computed by solving the differential equationdifferentiate(B(n, x), x) = n B(n-1, x)whereB(0, x) = 1and initial condition comes fromB(n) = B(n, 0).
- chebyshevT: Integer -> SparseUnivariatePolynomial Integer
chebyshevT(n)returns thenth Chebyshev polynomialT[n](x). Note: Chebyshev polynomials of the first kind, denotedT[n](x), computed from the two term recurrence. The generating function(1-t*x)/(1-2*t*x+t^2) = sum(T[n](x)*t^n, n=0..infinity).
- chebyshevU: Integer -> SparseUnivariatePolynomial Integer
chebyshevU(n)returns thenth Chebyshev polynomialU[n](x). Note: Chebyshev polynomials of the second kind, denotedU[n](x), computed from the two term recurrence. The generating function1/(1-2*t*x+t^2) = sum(T[n](x)*t^n, n=0..infinity).
- cyclotomic: Integer -> SparseUnivariatePolynomial Integer
cyclotomic(n)returns thenth cyclotomic polynomialphi[n](x). Note:phi[n](x)is the factor ofx^n - 1whose roots are the primitiventh roots of unity.
- euler: Integer -> SparseUnivariatePolynomial Fraction Integer
euler(n)returns thenth Euler polynomialE[n](x). Note: Euler polynomials denotedE(n, x)are computed by solving the differential equationdifferentiate(E(n, x), x) = n E(n-1, x)whereE(0, x) = 1and initial condition comes fromE(n) = 2^n E(n, 1/2).
- fixedDivisor: SparseUnivariatePolynomial Integer -> Integer
fixedDivisor(a)fora(x)inZ[x]is the largest integerfsuch thatfdividesa(x=k)for all integersk. Note: fixed divisor ofaisreduce(gcd, [a(x=k) for k in 0..degree(a)]).
- hermite: Integer -> SparseUnivariatePolynomial Integer
hermite(n)returns thenth Hermite polynomialH[n](x). Note: Hermite polynomials, denotedH[n](x), are computed from the two term recurrence. The generating function is:exp(2*t*x-t^2) = sum(H[n](x)*t^n/n!, n=0..infinity).
- laguerre: Integer -> SparseUnivariatePolynomial Integer
laguerre(n)returns thenth Laguerre polynomialL[n](x). Note: Laguerre polynomials, denotedL[n](x), are computed from the two term recurrence. The generating function is:exp(x*t/(t-1))/(1-t) = sum(L[n](x)*t^n/n!, n=0..infinity).
- legendre: Integer -> SparseUnivariatePolynomial Fraction Integer
legendre(n)returns thenth Legendre polynomialP[n](x). Note: Legendre polynomials, denotedP[n](x), are computed from the two term recurrence. The generating function is:1/sqrt(1-2*t*x+t^2) = sum(P[n](x)*t^n, n=0..infinity).