Function File: coefs= chebyshevpoly (kind,order,x)

Compute the coefficients of the Chebyshev polynomial, given the order. We calculate the Chebyshev polynomial using the recurrence relations Tn+1(x) = (2*x*Tn(x) - Tn-1(x)). The kind can be set to compute the first or second kind Chebyshev polynomial.

If the value x is specified, the polynomial is evaluated at x, otherwise just the coefficients of the polynomial are returned.

This is NOT the generalized Chebyshev polynomial.

Package: miscellaneous