Function: rec2ortho - from three term recurrence to orthogonal polynomials, Copyright 1996, 1997, 1998, 2005 by Tom H. Koornwinder and Rene' F. Swarttouw. email thk@science.uva.nl Calling Sequence: rec2ortho(an,bn,cn,A0,B0,C1) Parameters: an,bn,cn - coeficients in three term recurrence for general n A0,B0,C1 - optional coefficients in three term recurrence for n=0 or 1 Version: 1b3 (for Maple 6, 7, 8 or 9), 19 March 2005. Description: * Let the sequence of polynomials p(n,x) of degree n in x be generated by the recurrence x*p(n,x) = an*p(n+1,x) + bn*p(n,x) + cn*p(n-1,x) The function tries to return p(n,x) in the form coef(n) * named_polynomial(n, u*x+v, parameters) with named_polynomial being a Hermite, Charlier, Laguerre, Meixner, Krawtchouk, Meixner-Pollaczek or Jacobi polynomial, provided u, v and the parameters (possibly under further assumptions) admit a positive orthogonality measure for the polynomial p(n,x). if such a form is not possible then the function returns FAIL. The function can thus recognize all systems of orthogonal polynomials in the Askey scheme up to the two-parameter level * For the named orthogonal polynomials standard notation (linearized) and standard normalization will be followed (see [1, Appendix] or [2]): Hermite: H(n,x) Charlier: C(n,x,a) a>0 Laguerre: L(n,x,alpha) alpha>-1 Meixner-Pollaczek: P(n,x,lambda,phi) lambda>0, 00, 01 Krawtchouk: K(n,x,p,N) 0-1, beta>-1 In the Meixner-Pollaczek case the normalizations of [1] and [2] differ. We follow [2]: P(n,x,lambda,phi)=(2*sin(phi)^n/n!)*x^n + ... * Always p(0,x):=1. For n=0 the above recurrence is x = A0*p(1,x) + B0 If A0 is not given then A0:=subs(n=0,an). If B0 is not given then B0:=subs(n=0,bn). If C1 is given then, for n=1, cn is replaced by C1. Only changing A0,B0 or C1 will highly influence the output. * n and x are global variables. * an,bn,cn may depend on n. A0,B0,C1 are not allowed to depend on n. an,bn,cn,A0,B0,C1 may depend on other parameters. Properties of these parameters may be assumed with the assume facility. rec2ortho may give additional properties to these parameters in order to guarantee the existence of a positive orthogonality measure. If a is a parameter occurring in the output and if the output mentions that there are assumptions on a, then these assumptions can be obtained with the command: about(a); * The tilde notation for variables with assumed properties is avoided, since rec2ortho puts: interface(showassumed=2): * In the output it is silently assumed that x is real and that n is nonnegative integer. Moreover, in the Krawtchouk case K(n,x,p,N), N is explicitly assumed to be positive integer, and it is silently assumed that n=0,1,...,N. * A0 should be nonzero and an should be nonzero for positive integer n. Then the ouput coefficient coeff(n) will be nonzero for nonnegative integer n. This will not be checked exhaustively by rec2ortho. The user should already check this in advance. Possibly make assumptions on parameters such that an and A0 do not vanish. * Strictly speaking, the output coefficient coef(n) should also be real. This will not be checked by rec2ortho. * Often, because of symmetry transformations for the named orthogonal polynomials, two different forms of the output are possible. It cannot be predicted which of the two forms rec2ortho will give. * In some cases it will depend on some quantity being positive, zero or negative whether we may be in the Meixner-Pollaczek case, Laguerre case or Meixner and Krawtchouk case, respectively. In the third case the sign of another quantity will decide between the Meixner and Krawtchouk case. rec2ortho will tell that the user should make such a choice (by the assume facility) and then rerun rec2ortho. References: [1] R. Askey and J.A. Wilson, Some basic hypergeometric orthogonal polynomials that geenralize Jacobi polynomials, Memoirs Amer. Math. Soc., No.319 (1985). [2] R. Koekoek and R.F. Swarttouw, The Askey scheme of hypergeometric orthogonal polynomials and its q-analogue, Delft University of Technology, Faculty of Information Technology and Systems, Report 98-17, 1998; online: http://aw.twi.tudelft.nl/~koekoek/askey/ Examples: > read rec2ortho: > rec2ortho(1/2,0,n);# Hermite Hermite H(n, x) > rec2ortho(2*(n+1)*(n+alpha+beta+1)/(2*n+alpha+beta+1)/(2*n+alpha+beta+ > 2),(beta^2-alpha^2)/(2*n+alpha+beta)/(2*n+alpha+beta+2),2*(n+alpha)*(n > +beta)/(2*n+alpha+beta)/(2*n+alpha+beta+1));# Jacobi Jacobi P(n, x, alpha, beta) with assumptions on alpha and beta > about(alpha); about(beta); Originally alpha, renamed alpha~: is assumed to be: RealRange(Open(-1),infinity) Originally beta, renamed beta~: is assumed to be: RealRange(Open(-1),infinity) > rec2ortho(-p*(N-n),p*(N-n)+n*(1-p),-n*(1-p));# Krawtchouk possibly Meixner or Krawtchouk, assume more about the sign of -N FAIL > assume(N>0): > rec2ortho(-p*(N-n),p*(N-n)+n*(1-p),-n*(1-p));# Krawtchouk again Krawtchouk K(n, x, p, N) with assumptions on p and N > about(N); about(p); Originally N, renamed N~: is assumed to be: AndProp(RealRange(1,infinity),integer) Originally p, renamed p~: is assumed to be: RealRange(Open(0),Open(1)) > rec2ortho(1,-(n+lambda)*c,n*(n+2*lambda-1)/4); possibly Meixner or Krawtchouk or Meixner-Pollaczek, assume more about the sign of 2 c - 1 FAIL # Meixner-Pollaczek (-11) Files: rec2ortho (source code) rec2orthotest.mws (Maple worksheet for Maple 6, 7, 8 with many further examples) rec2orthotest.mw (idem for Maple 9)