### 11.4.4 Chebyshev polynomials of the first kind

The Chebyshev polynomial of first kind T(n,x) is defined by

T(n,x)=cos(n arccosx)

and satisfy the recurrence relation:

T(0,x)=1, T(1,x)=x, T(n,x)=2xT(n−1,x)−T(n−2,x).

The polynomials T(n,x) are orthogonal for the scalar product

⟨ f,g⟩= | ∫ |
1
−1
f(x)g(x)
√ |
1−x2
| d x.

The tchebyshev1 command finds the Chebyshev polynomials of the first kind.

- tchebyshev1 takes one mandatory argument and one optional argument:
  - n, an integer.
  - Optionally x, a variable name (by default x).
- tchebyshev1(n ⟨,x⟩) returns the Chebyshev polynomial of first kind of degree n.

#### Examples

tchebyshev1(4)

8 x4−8 x2+1 |  |  |  |  |  |  |  |  |  |

tchebyshev1(4,y)

8 y4−8 y2+1 |  |  |  |  |  |  |  |  |  |

Indeed, cos(4x)=Re((cosx+i sinx)4)=cos4 x−6cos2 x (1−cos2 x)+((1−cos2 x))2=T(4,cos(x)).