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.

A008313 Triangle of expansions of powers of x in terms of Chebyshev polynomials U_n(x).

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 2, 3, 1, 5, 4, 1, 5, 9, 5, 1, 14, 14, 6, 1, 14, 28, 20, 7, 1, 42, 48, 27, 8, 1, 42, 90, 75, 35, 9, 1, 132, 165, 110, 44, 10, 1, 132, 297, 275, 154, 54, 11, 1, 429, 572, 429, 208, 65, 12, 1, 429, 1001, 1001, 637, 273, 77, 13, 1
Offset: 0

Views

Author

Keywords

Comments

This is another reading (by shallow diagonals) of the triangle A009766; rows of Catalan triangle A008315 read backwards. - Philippe Deléham, Feb 15 2004
"The Catalan triangle is formed in the same manner as Pascal's triangle, except that no number may appear on the left of the vertical bar." [Conway and Smith]

Examples

			.|...1
.|.......1
.|...1.......1
.|.......2.......1
.|...2.......3.......1
.|.......5.......4.......1
.|...5.......9.......5.......1
.|......14......14.......6.......1
.|..14......28......20.......7.......1
.|......42......48......27.......8.......1
		

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. 796.
  • J. H. Conway and D. A. Smith, On Quaternions and Octonions, A K Peters, Ltd., Natick, MA, 2003. See p. 60. MR1957212 (2004a:17002)
  • P. J. Larcombe, A question of proof..., Bull. Inst. Math. Applic. (IMA), 30, Nos. 3/4, 1994, 52-54.

Crossrefs

Cf. A039598, A039599. A053121 is essentially the same triangle.
Row sums = A001405 (central binomial coefficients).

Programs

  • Haskell
    a008313 n k = a008313_tabf !! n !! k
    a008313_row n = a008313_tabf !! n
    a008313_tabf = map (filter (> 0)) a053121_tabl
    -- Reinhard Zumkeller, Feb 24 2012
    
  • Maple
    T := proc(n, k): if n=0 then 1 else binomial(n-1, floor(n/2 )-k) -binomial(n-1, floor(n/2) -k-2) fi: end: seq(seq(T(n, k), k = 0..floor(n/2)), n = 0..14); # Johannes W. Meijer, Jul 10 2011, revised Nov 22 2012
  • Mathematica
    t[n_, k_] /; n < k || OddQ[n - k] = 0; t[n_, k_] := (k+1)*Binomial[n+1, (n-k)/2]/(n+1); Flatten[ Table[ t[n, k], {n, 0, 15}, {k, Mod[n, 2], n + Mod[n, 2], 2}]] (* Jean-François Alcover, Jan 12 2012 *)
  • PARI
    {T(n, k) = if( k<0 || 2*k>n, 0, polcoeff((1 - x) * (1 + x)^n, n\2 - k))}; /* Michael Somos, May 28 2005 */
    
  • PARI
    T(n, k) = binomial(n-1, n\2-k)-binomial(n-1, n\2-k-2);
    for(n=0, 14, for(k=0, n\2, print1(T(n,k),", "))); \\ Seiichi Manyama, Mar 24 2025
    
  • Sage
    # Algorithm of L. Seidel (1877)
    # Prints the first n rows of the triangle.
    def A008313_triangle(n) :
        D = [0]*((n+5)//2); D[1] = 1
        b = True; h = 1
        for i in range(n) :
            if b :
                for k in range(h,0,-1) : D[k] += D[k-1]
                h += 1
            else :
                for k in range(1,h, 1) : D[k] += D[k+1]
            b = not b
            print([D[z] for z in (1..h-1)])
    A008313_triangle(13) # Peter Luschny, May 01 2012

Formula

Row n: C(n-1, [n/2]-k) - C(n-1, [n/2]-k-2) for k=0, 1, ..., n.
Sum_{k>=0} T(n, k)^2 = A000108(n); A000108: Catalan numbers. - Philippe Deléham, Feb 14 2004