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.

A204293 Pascal's triangle interspersed with rows of zeros, and the rows of Pascal's triangle are interspersed with zeros.

Original entry on oeis.org

1, 0, 0, 1, 0, 1, 0, 0, 0, 0, 1, 0, 2, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 3, 0, 3, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 4, 0, 6, 0, 4, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 5, 0, 10, 0, 10, 0, 5, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 6, 0, 15, 0, 20
Offset: 0

Views

Author

Reinhard Zumkeller, Jan 14 2012

Keywords

Comments

Auxiliary array for computing Losanitsch's triangle A034851;
T(n, k) + T(n, k + 2) = T(n + 2, k + 2) for k < n - 1.

Crossrefs

Cf. A077957 (row sums), A126869 (central terms); A108044, A007318.

Programs

  • Haskell
    a204293 n k = a204293_tabl !! n !! k
    a204293_row n = a204293_tabl !! n
    a204293_tabl = [1] : [0,0] : f [1] [0,0] where
       f xs ys = xs' : f ys xs' where
         xs' = zipWith (+) ([0,0] ++ xs) (xs ++ [0,0])
  • Mathematica
    t[n_?EvenQ, k_?EvenQ] := Binomial[n/2, k/2]; t[, ] = 0; Flatten[Table[t[n, k], {n, 0, 12}, {k, 0, n}]] (* Jean-François Alcover, Feb 07 2012 *)

Formula

T(n, k) = (1 - n mod 2) * (1 - k mod 2) * binomial(floor(n/2),floor(k/2)).

Extensions

Formula for T(n,k) corrected by Peter Bala, Jul 06 2015