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.

A156348 Triangle T(n,k) read by rows. Column of Pascal's triangle interleaved with k-1 zeros.

Original entry on oeis.org

1, 1, 1, 1, 0, 1, 1, 2, 0, 1, 1, 0, 0, 0, 1, 1, 3, 3, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 1, 4, 0, 4, 0, 0, 0, 1, 1, 0, 6, 0, 0, 0, 0, 0, 1, 1, 5, 0, 0, 5, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 6, 10, 10, 0, 6, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 7, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0
Offset: 1

Views

Author

Mats Granvik, Feb 08 2009

Keywords

Comments

The rows of the Pascal triangle are here found as square root parabolas like in the plots at www.divisorplot.com. Central binomial coefficients are found at the square root boundary.
A156348 * A000010 = A156834: (1, 2, 3, 5, 5, 12, 7, 17, 19, 30, 11, ...). - Gary W. Adamson, Feb 16 2009
Row sums give A157019.

Examples

			Table begins:
1
1  1
1  0  1
1  2  0  1
1  0  0  0  1
1  3  3  0  0  1
1  0  0  0  0  0  1
1  4  0  4  0  0  0  1
1  0  6  0  0  0  0  0  1
1  5  0  0  5  0  0  0  0  1
1  0  0  0  0  0  0  0  0  0  1
1  6 10 10  0  6  0  0  0  0  0  1
1  0  0  0  0  0  0  0  0  0  0  0  1
1  7  0  0  0  0  7  0  0  0  0  0  0  1
1  0 15  0 15  0  0  0  0  0  0  0  0  0  1
1  8  0 20  0  0  0  8  0  0  0  0  0  0  0  1
1  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  1
1  9 21  0  0 21  0  0  9  0  0  0  0  0  0  0  0  1
1  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0  1
1 10  0 35 35  0  0  0  0 10  0  0  0  0  0  0  0  0  0  1
		

Crossrefs

Programs

  • Haskell
    Following Mathar's Maple program.
    a156348 n k = a156348_tabl !! (n-1) !! (k-1)
    a156348_tabl = map a156348_row [1..]
    a156348_row n = map (f n) [1..n] where
       f n k = if r == 0 then a007318 (n' - 2 + k) (k - 1) else 0
               where (n', r) = divMod n k
    -- Reinhard Zumkeller, Jan 31 2014
  • Maple
    A156348 := proc(n,k)
        if k < 1 or k > n then
            return 0 ;
        elif n mod k = 0 then
            binomial(n/k-2+k,k-1) ;
        else
            0 ;
        end if;
    end proc: # R. J. Mathar, Mar 03 2013
  • Mathematica
    T[n_, k_] := Which[k < 1 || k > n, 0, Mod[n, k] == 0, Binomial[n/k - 2 + k, k - 1], True, 0];
    Table[T[n, k], {n, 1, 14}, {k, 1, n}] // Flatten (* Jean-François Alcover, Nov 16 2017 *)