cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A039991 Triangle of coefficients of cos(x)^n in polynomial for cos(nx).

Original entry on oeis.org

1, 1, 0, 2, 0, -1, 4, 0, -3, 0, 8, 0, -8, 0, 1, 16, 0, -20, 0, 5, 0, 32, 0, -48, 0, 18, 0, -1, 64, 0, -112, 0, 56, 0, -7, 0, 128, 0, -256, 0, 160, 0, -32, 0, 1, 256, 0, -576, 0, 432, 0, -120, 0, 9, 0, 512, 0, -1280, 0, 1120, 0, -400, 0, 50, 0, -1, 1024, 0, -2816, 0, 2816, 0, -1232, 0, 220, 0, -11, 0
Offset: 0

Views

Author

Keywords

Comments

Also triangle of coefficients of Chebyshev polynomials of first kind (T(n,x)) in decreasing order of powers of x. A053120 gives the coefficients in increasing order.
The polynomials R(n,x) := Sum_{m=0..n} a(n,m)*sqrt(x)^m, have g.f. (1-z)/(1 - 2*z + x*z^2) = ((1-z)/(1-2*z))/(1 - x*(-z^2/(1-2*z))) (from the row reversion of the g.f. of A053120 and x^2 -> x). Therefore this triangle becomes the Riordan triangle ((1-z)/(1-2*z), -z^2/(1-2*z)) if the vanishing columns are deleted (see A028297) and zeros are appended in each row numbered n>=1 in order to obtain a triangle. This is then A201701 with negative odd numbered columns. - Wolfdieter Lang, Aug 06 2014

Examples

			Letting c = cos x, we have: cos 0x = 1, cos 1x = 1c; cos 2x = 2c^2-1; cos 3x = 4c^3-3c, cos 4x = 8c^4-8c^2+1, etc.
From _Wolfdieter Lang_, Aug 06 2014: (Start)
The triangle a(n,m) begins:
  n\m    0 1     2 3    4 5     6 7   8 9  10 11 ...
  0:     1
  1:     1 0
  2:     2 0    -1
  3:     4 0    -3 0
  4:     8 0    -8 0    1
  5:    16 0   -20 0    5 0
  6:    32 0   -48 0   18 0    -1
  7:    64 0  -112 0   56 0    -7 0
  8:   128 0  -256 0  160 0   -32 0   1
  9:   256 0  -576 0  432 0  -120 0   9 0
  10:  512 0 -1280 0 1120 0  -400 0  50 0  -1
  11: 1024 0 -2816 0 2816 0 -1232 0 220 0 -11  0
  ...
--------------------------------------------------------------------------
Chebyshev T-polynomials (decreasing even or odd powers):
n=3: T(3, x) = 4*x^3 - 3*x^1; n=4: T(4, x) = 8*x^4 - 8*x^2 + 1. (End)
		

References

  • M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964 (and various reprintings), p. 795.
  • Martin Aigner and Gunter M. Ziegler, Proofs From the Book, Springer 2004. See Chapter 18, Appendix.
  • E. A. Guilleman, Synthesis of Passive Networks, Wiley, 1957, p. 593.
  • Theodore J. Rivlin, Chebyshev polynomials: from approximation theory to algebra and number theory, 2. ed., Wiley, New York, 1990.

Crossrefs

Cf. A028297 (without vanishing columns). A008310 (zero columns deleted then rows reversed).
Triangle without zeros: A028297. Without signs: A081265.
Cf. A053120 (increasing powers of x).

Programs

  • Magma
    function T(n,k) // T = A039991
      if k lt 0 or k gt n then return 0;
      elif n lt 2 and k eq 0 then return 1;
      else return 2*T(n-1, k) - T(n-2, k-2);
      end if; return T;
    end function;
    [T(n,k): k in [0..n], n in [0..12]]; // G. C. Greubel, Aug 10 2022
    
  • Maple
    seq(seq(coeff(orthopoly[T](i,x),x,i-j),j=0..i),i=0..20); # Robert Israel, Aug 07 2014
  • Mathematica
    row[n_] := CoefficientList[ ChebyshevT[n, x], x] // Reverse; Table[row[n], {n, 0, 11}] // Flatten(* Jean-François Alcover, Sep 14 2012 *)
  • PARI
    T(n,m)=(1+(-1)^m)*(binomial(n-m/2,n-m)+binomial(n-1-m/2,n-m))*2^(n-m-2)*(-1)^((m+1-(-1)^m)/2) /* Tani Akinari, Jul 18 2024 */
  • SageMath
    def T(n, k): # T = A039991
        if (n<2 and k==0): return 1
        elif (k<0 or k>n): return 0
        else: return 2*T(n-1, k) - T(n-2, k-2)
    flatten([[T(n,k) for k in (0..n)] for n in (0..12)]) # G. C. Greubel, Aug 10 2022
    

Formula

T(n, m) = 0 if n= 2, m >= 0; T(n, -2) = T(n, -1) = 0, T(0, 0) = T(1, 0) = 1.
G.f. for m-th column: 0 if m odd, (1-x)/(1-2*x) if m=0, else ((-1)^(m/2))*(x^m)*(1-x)/(1-2*x)^(m/2+1). For g.f. for row polynomials and row sums, see A053120.
G.f. row polynomials: (1-z)/(1 - 2*z + (x*z)^2). - Wolfdieter Lang, Aug 06 2014
Recurrence for the row polynomials Trev(n, x):= x^n*T(n, 1/x) = Sum_{m=0..n} T(n, m)*x^m; Trev(n, x) = 2*Trev(n-1, x) - x^2*Trev(n-2, x), n >= 1, Trev(-1, x) = 1/x^2 and Trev(0, x) = 1. From the T(n, x) recurrence. Compare this with A081265. - Wolfdieter Lang, Aug 07 2014
T(n,m) = (1+(-1)^m)*(binomial(n-m/2,n-m)+binomial(n-1-m/2,n-m))*2^(n-m-2)*(-1)^((m+1-(-1)^m)/2). - Tani Akinari, Jul 18 2024

Extensions

Entry improved by comments from Wolfdieter Lang, Jan 11 2000.
Edited: A053120 added in comment and crossrefs. Cfs. A028297 and A008310 specified. - Wolfdieter Lang, Aug 06 2014