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.

Previous Showing 11-13 of 13 results.

A226392 Triangle with first column identical to 1 and the other entries defined by the sum of entries above and to the left.

Original entry on oeis.org

1, 1, 1, 1, 2, 3, 1, 4, 8, 13, 1, 8, 20, 42, 71, 1, 16, 48, 120, 256, 441, 1, 32, 112, 320, 792, 1698, 2955, 1, 64, 256, 816, 2256, 5532, 11880, 20805, 1, 128, 576, 2016, 6096, 16488, 40140, 86250, 151695, 1, 256, 1280, 4864, 15872, 46432, 123680
Offset: 0

Views

Author

R. J. Mathar, Jun 06 2013

Keywords

Comments

The sequence of row sums s(n) starts at n=0 as 1, 2, 6, 26, 142, 882, 5910, 41610, 303390,... and satisfies the hypergeometric recurrence n*s(n) +2*(7-5*n)*s(n-1) +9*(n-2)*s(n-2)=0.
For n>0, s(n) = 2*T(n,n) = 2*A162326(n). - Max Alekseyev, Feb 04 2021

Examples

			T(3,2) = 8 = 3 (above) +1+4 (to the left).
1;
1,1;
1,2,3;
1,4,8,13;
1,8,20,42,71;
1,16,48,120,256,441;
1,32,112,320,792,1698,2955;
1,64,256,816,2256,5532,11880,20805;
		

Crossrefs

Cf. A162326 (diagonal), A000079 (column k=1), A001792 (column k=2).

Programs

  • Maple
    A226392 := proc(n,k)
        option remember;
        if k = 0 then
            1;
        elif k > n or k < 0 then
            0 ;
        else
            add( procname(n,c),c=0..k-1) + add( procname(r,k),r=k..n-1) ;
        end if;
    end proc:
  • Mathematica
    t[, 0] = 1; t[n, k_] := t[n, k] = Sum[t[n, c], {c, 0, k-1}] + Sum[t[r, k], {r, k, n-1}]; Table[t[n, k], {n, 0, 9}, {k, 0, n}] // Flatten (* Jean-François Alcover, Jan 10 2014 *)

Formula

Definition: T(n,0)=1. T(n,k) = sum_{0<=c0.
T(n,3) = 6*T(n-1,3) -12*T(n-2,3)+8*T(n-3,3). T(n,3) = 2^n*(n+10)*(n-1)/16.
T(n,4) = 8*T(n-1,4) -24*T(n-2,4) +32*T(n-3,4) -16*T(n-4,4); T(n,4) = 2^n*(n^2/4 +65*n/96 -47/16 +n^3/96).
For 10, T(n,n) = 2*T(n,n-1) - T(n-1,n-1). - Max Alekseyev, Feb 04 2021

A341359 Square array T(m,n) read by antidiagonals, satisfying shifted Catalan recurrences: T(m,0) = 1 and T(m,n) = Sum_{k=0..n-1} T(m,k) * T(m,(n-1-k+m) mod n) for all n > 0.

Original entry on oeis.org

1, 1, 1, 1, 1, 2, 1, 1, 2, 5, 1, 1, 2, 5, 14, 1, 1, 2, 6, 15, 42, 1, 1, 2, 5, 26, 51, 132, 1, 1, 2, 5, 30, 142, 188, 429, 1, 1, 2, 6, 14, 305, 882, 731, 1430, 1, 1, 2, 5, 17, 210, 3955, 5910, 2950, 4862, 1, 1, 2, 5, 22, 50, 5894, 57855, 41610, 12235, 16796, 1, 1, 2, 6, 30, 65, 2550, 209146, 908880, 303390, 51822, 58786
Offset: 0

Views

Author

Max Alekseyev, Feb 09 2021

Keywords

Comments

Each column is periodic, and the period of column n divides A003418(n).

Examples

			Rows of the array:
m=0: 1, 1, 2, 5, 14,  42,  132,    429,     1430, ...
m=1: 1, 1, 2, 5, 15,  51,  188,    731,     2950, ...
m=2: 1, 1, 2, 6, 26, 142,  882,   5910,    41610, ...
m=3: 1, 1, 2, 5, 30, 305, 3955,  57855,   908880, ...
m=4: 1, 1, 2, 5, 14, 210, 5894, 209146,  8331582, ...
m=5: 1, 1, 2, 6, 17,  50, 2550, 255050, 32007550, ...
...
		

Crossrefs

Rows: A000108 (m=0), A181768 (m=1).
Columns: A000012 (n=0 and n=1), A007395 (n=2).

Programs

  • Mathematica
    T[m_, 0] := 1; T[m_, n_] := T[m, n] = Sum[T[m, k] * T[m, Mod[n - 1 - k + m, n]], {k, 0, n - 1}]; Table[T[m - n, n], {m, 0, 11}, {n, 0, m}] // Flatten (* Amiram Eldar, Feb 09 2021 *)

Formula

G.f. for row m: p_m(x) + x^(m-1)/2 * ( 1 + sqrt((1 -(4*T(m,m)+1)*x)/(1-x)) ), where p_m(x) = Sum_{n=0..m-1} T(m,n) * x^n.

A369580 a(n) := f(n, n), where f(0,0) = 1/3, f(0,k) = 0 and f(k,0) = 3^(k-1) if k > 0, and f(n, m) = f(n, m-1) + f(n-1, m) + 3*f(n-1, m-1) otherwise.

Original entry on oeis.org

2, 16, 138, 1216, 10802, 96336, 861114, 7708416, 69072354, 619380496, 5557080938, 49879087296, 447852531986, 4022246329936, 36132550233498, 324645166734336, 2917340834679234, 26219438520320016, 235672871308226634, 2118552629658530496, 19046140604787232242, 171241206828437556816
Offset: 1

Views

Author

Tadayoshi Kamegai, Jan 26 2024

Keywords

Comments

Take turns flipping a fair coin. The first to n heads wins. Sequence gives numerator of probability of first player winning. The denominator is .3^(2n-1).
It appears that a(n) for any n is divisible by 2^(A001511(n)).

Crossrefs

Cf. A001511 (see comments), A162326 (see formula).

Programs

  • Python
    def lis(n):
        table = [[0]*(n+1) for _ in range(n+1)]
        table[1][1] = 2
        for i in range(1, n+1) :
            table[i][0] = 3**(i-1)
        for i in range(1, n+1) :
            for j in range(1, n+1) :
                if (i == 1 and j == 1) :
                    continue
                table[i][j] = table[i][j-1] + table[i-1][j] + 3*table[i-1][j-1]
        return [int(table[i][i]) for i in range(1, n+1)]

Formula

Limit_{n->oo} a(n)/3^(2n-1) = 1/2.
a(n) = Sum_{i>=n} Sum_{j=0..n-1} binomial(i-1,n-1)*binomial(i-1,j)*3^(2n-1)/2^(2i-1).
9*a(n) - a(n+1) = 2*A162326(n) (conjectured).
a(n) = 3^(2n-1)*A(n, n) where A(0, k) = 0 for k > 0, A(k, 0) = 1 for k >= 0 and A(n, m) = (A(n-1, m) + A(n, m-1) + A(n-1, m-1))/3.
Previous Showing 11-13 of 13 results.