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.

Showing 1-3 of 3 results.

A167194 Triangle read by rows. A130713 in the columns.

Original entry on oeis.org

1, 2, 1, 1, 2, 1, 0, 1, 2, 1, 0, 0, 1, 2, 1, 0, 0, 0, 1, 2, 1, 0, 0, 0, 0, 1, 2, 1, 0, 0, 0, 0, 0, 1, 2, 1, 0, 0, 0, 0, 0, 0, 1, 2, 1, 0, 0, 0, 0, 0, 0, 0, 1, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 2, 1
Offset: 1

Views

Author

Mats Granvik, Oct 30 2009

Keywords

Examples

			Table begins:
  1;
  2,1;
  1,2,1;
  0,1,2,1;
  0,0,1,2,1;
  0,0,0,1,2,1;
  0,0,0,0,1,2,1;
  0,0,0,0,0,1,2,1;
  0,0,0,0,0,0,1,2,1;
  0,0,0,0,0,0,0,1,2,1;
  0,0,0,0,0,0,0,0,1,2,1;
  ...
		

Crossrefs

Programs

  • Mathematica
    Array[PadLeft[{1, 2, 1}, #] &,15] (* Paolo Xausa, Jun 27 2024 *)

Formula

From Peter Bala, Sep 12 2012: (Start)
T(n,k) = binomial(2,n-k).
O.g.f.: (1+x)^2/(1-t*x).
Riordan array ((1+x)^2,x).
Matrix inverse is signed version of A004736. (End)

A202241 Array F(n,m) read by antidiagonals: F(0,m)=1, F(n,0) = A130713(n), and column m+1 is recursively defined as the partial sums of column m.

Original entry on oeis.org

1, 2, 1, 1, 3, 1, 0, 4, 4, 1, 0, 4, 8, 5, 1, 0, 4, 12, 13, 6, 1, 0, 4, 16, 25, 19, 7, 1, 0, 4, 20, 41, 44, 26, 8, 1, 0, 4, 24, 61, 85, 70, 34, 9, 1, 0, 4, 28, 85, 146, 155, 104, 43, 10, 1, 0, 4, 32, 113, 231, 301, 259, 147, 53, 11, 1, 0, 4, 36, 145, 344, 532, 560, 406, 200, 64, 12, 1
Offset: 0

Views

Author

Paul Curtz, Dec 16 2011

Keywords

Comments

The array F(n,m), beginning with row n=0, is:
1, 1, 1, 1, 1, 1, 1,
2, 3, 4, 5, 6, 7, 8,
1, 4, 8, 13, 19, 26, 34,
0, 4, 12, 25, 44, 70, 104,
0, 4, 16, 41, 85, 155, 259,
0, 4, 20, 61, 146, 301, 560,
0, 4, 24, 85, 231, 532, 1092.
Columns after A130713, A113311, A008574 have signatures (3,-3,1), (4,-6,4,-1), (5,-10,10,-5,1), (6,-15,20,-15,6,-1) (from A135278(n+3)).
Inserting columns of zeros and pushing the columns down, plus alternating sign switches defines the following triangle T(n,2m) = (-1)^(m/2)*F(n-2m,m):
1,
2 0,
1 0 -1,
0 0 -3 0,
0 0 -4 0 1,
0 0 -4 0 4 0,
0 0 -4 0 8 0 -1
The row sums in the triangle are (-1)^n*A099838(n).
The companion to A201863 is
1
1 0
1 0 0
1 0 -2 0
1 0 -4 0 1
1 0 -6 0 5 0
1 0 -8 0 13 0 -2
1 0 -10 0 25 0 -12 0
1 0 -12 0 41 0 -38 0 4
1 0 -14 0 61 0 -88 0 28 0
1 0 -16 0 85 0 -170 0 104 0 -8
5th column: A001844; 7th column: -A035597=-2*A005900(n+1); 9th column: 4*A006325(n+2); 11th column: -8*(1,8,34,104) (from columns 4,5,6,7 of F(n,m)).
As a triangular array, this is the Riordan array ((1+x)^2, x/(1-x)). - Philippe Deléham, Feb 21 2012

Examples

			Triangle T(n,k) begins:
  1
  2, 1
  1, 3,  1
  0, 4,  4,  1
  0, 4,  8,  5,   1
  0, 4, 12, 13,   6,   1
  0, 4, 16, 25,  19,   7,   1
  0, 4, 20, 41,  44,  26,   8,  1
  0, 4, 24, 61,  85,  70,  34,  9,  1
  0, 4, 28, 85, 146, 155, 104, 43, 10, 1
- _Philippe Deléham_, Feb 21 2012
		

Crossrefs

Cf. A130713 (column 0), A113311 (column 1), A008574 (column 2), A001844 (column 3), A005900 (column 4), A006325 (column 5), A033455 (column 6).
Cf. A267633.

Programs

  • GAP
    Flat(List([0..12],n->List([0..n],k->Binomial(n,n-k)+Binomial(n-1,n-k-1)-Binomial(n-2,n-k-2)-Binomial(n-3,n-k-3)))); # Muniru A Asiru, Mar 22 2018
  • Maple
    A130713 := proc(n)
        if n <= 2 and n >=0 then
            op(n+1,[1,2,1]) ;
        else
            0;
        end if;
    end proc:
    A202241 := proc(n,m)
        option remember;
        if n < 0 then
            0 ;
        elif m = 0 then
            A130713(n);
        else
            procname(n,m-1)+procname(n-1,m) ;
        end if;
    end proc:
    for d from 0 to 12 do
        for m from 0 to d do
            printf("%d,",A202241(d-m,m)) ;
        end do:
    end do: # R. J. Mathar, Dec 22 2011
    C := proc (n, k) if 0 <= k and k <= n then factorial(n)/(factorial(k)*factorial(n-k)) else 0 end if end proc:
    for n from 0 to 10 do
         seq(C(n, n-k) + C(n-1, n-k-1) - C(n-2, n-k-2) - C(n-3, n-k-3), k = 0..n);
    end do; # Peter Bala, Mar 20 2018
  • Mathematica
    rows = 12;
    T[0] = PadRight[{1, 2, 1}, rows];
    T[n_ /; nJean-François Alcover, Jun 29 2019 *)
  • Sage
    def Trow(n): return [binomial(n, n-k) + binomial(n-1, n-k-1) - binomial(n-2, n-k-2) - binomial(n-3, n-k-3) for k in (0..n)]
    for n in (0..9): print(Trow(n)) # Peter Luschny, Mar 21 2018
    

Formula

F(1,m) = m+2.
F(2,m) = A034856(m+1).
F(3,m) = A000297(m-1).
Sum_{m=0..d} F(d-m,m) = A116453(d-3), d >= 3 (antidiagonal sums).
As a triangular array T(n,k), 0 <= k <= n, satisfies: T(n,k) = T(n-1,k) + T(n-1,k-1) with T(0,0) = 1, T(1,0) = 2, T(2,0) = 1, T(3,0) = 0. - Philippe Deléham, Feb 21 2012
Unsigned diagonals of A267633 (beginning with its main diagonal) appear to be the reverse rows of this entry's triangle beginning with the fourth row. - Tom Copeland, Jan 26 2016
T(n,k) = C(n, n-k) + C(n-1, n-k-1) - C(n-2, n-k-2) - C(n-3, n-k-3), where C(n, k) = n!/(k!*(n-k)!) if 0 <= k <= n, otherwise 0. - Peter Bala, Mar 20 2018

A267883 Number of OFF (white) cells in the n-th iteration of the "Rule 233" elementary cellular automaton starting with a single ON (black) cell.

Original entry on oeis.org

0, 3, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Robert Price, Jan 21 2016

Keywords

References

  • S. Wolfram, A New Kind of Science, Wolfram Media, 2002; p. 55.

Crossrefs

Programs

  • Mathematica
    rule=233; rows=20; ca=CellularAutomaton[rule,{{1},0},rows-1,{All,All}]; (* Start with single black cell *) catri=Table[Take[ca[[k]],{rows-k+1,rows+k-1}],{k,1,rows}]; (* Truncated list of each row *) nbc=Table[Total[catri[[k]]],{k,1,rows}]; (* Number of Black cells in stage n *) Table[Length[catri[[k]]]-nbc[[k]],{k,1,rows}] (* Number of White cells in stage n *)
Showing 1-3 of 3 results.