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.

A124928 Triangle read by rows: T(n,0) = 1, T(n,k) = 3*binomial(n,k) if k>=0 (0<=k<=n).

Original entry on oeis.org

1, 1, 3, 1, 6, 3, 1, 9, 9, 3, 1, 12, 18, 12, 3, 1, 15, 30, 30, 15, 3, 1, 18, 45, 60, 45, 18, 3, 1, 21, 63, 105, 105, 63, 21, 3, 1, 24, 84, 168, 210, 168, 84, 24, 3, 1, 27, 108, 252, 378, 378, 252, 108, 27, 3, 1, 30, 135, 360, 630, 756, 630, 360, 135, 30, 3
Offset: 0

Views

Author

Gary W. Adamson, Nov 12 2006

Keywords

Comments

Row sums = A033484: (1, 4, 10, 22, 46, 94...); 3*2^n - 2.
Analogous triangle using (1,2,2,2...) as the main diagonal of M = A124927.
Except for the first column, entries in the Pascal triangle are tripled.

Examples

			First few rows of the triangle are:
  1;
  1,  3;
  1,  6,  3;
  1,  9,  9,  3;
  1, 12, 18, 12,  3;
  1, 15, 30, 30, 15,  3;
  1, 18, 45, 60, 45, 18, 3;
...
		

Crossrefs

Programs

  • GAP
    T:= function(n,k)
        if k=0 then return 1;
        else return 3*Binomial(n,k);
        fi;  end;
    Flat(List([0..12], n-> List([0..n], k-> T(n,k) ))); # G. C. Greubel, Nov 19 2019
  • Magma
    [k eq 0 select 1 else 3*Binomial(n,k): k in [0..n], n in [0..12]]; // G. C. Greubel, Nov 19 2019
    
  • Maple
    T:=proc(n,k) if k=0 then 1 else 3*binomial(n,k) fi end: for n from 0 to 12 do seq(T(n,k),k=0..n) od; # yields sequence in triangular form
  • Mathematica
    Flatten[Table[If[k==0,1,3*Binomial[n,k]],{n,0,20},{k,0,n}]] (* Harvey P. Dale, Oct 19 2013 *)
  • PARI
    T(n,k) = if(k==0, 1, 3*binomial(n,k)); \\ G. C. Greubel, Nov 19 2019
    
  • Sage
    def T(n, k):
        if (k==0): return 1
        else: return 3*binomial(n,k)
    [[T(n, k) for k in (0..n)] for n in (0..12)] # G. C. Greubel, Nov 19 2019
    

Formula

G.f.: G(t,z) = 3/(1-(1+t)*z) - 2/(1-z).

Extensions

Edited by N. J. A. Sloane, Nov 29 2006