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-2 of 2 results.

A228352 Triangle read by rows, giving antidiagonals of an array of sequences representing the number of compositions of n when there are N types of ones (the sequences in the array begin (1, N, ...)).

Original entry on oeis.org

1, 1, 1, 1, 2, 2, 1, 3, 5, 4, 1, 4, 10, 13, 8, 1, 5, 17, 34, 34, 16, 1, 6, 26, 73, 116, 89, 32, 1, 7, 37, 136, 314, 396, 233, 64, 1, 8, 50, 229, 712, 1351, 1352, 610, 128, 1, 9, 65, 358, 1418, 3728, 5813, 4616, 1597, 256, 1, 10, 82, 529, 2564, 8781, 19520, 25012, 15760, 4181, 512
Offset: 1

Views

Author

Gary W. Adamson, Aug 20 2013

Keywords

Comments

The array sequence beginning (1, N, ...) is such that a(n) in the sequence represents the numbers of compositions of n when there are N types of ones.

Examples

			Array sequence beginning (1, 3, 10, 34, 116, ...) is the binomial transform of (1, 2, 5, 12, 70, ...) in A073133.
First few sequences in the array:
  1, 1,  2,  4,   8,  16, ...; = A011782
  1, 2,  5, 13,  34,  89, ...; = A001519
  1, 3, 10, 34, 116, 396, ...; = A007052
... followed by A018902, A018903, A018904, the latter beginning (1, 6, ...). First few rows of the triangle:
  1;
  1,  1;
  1,  2,  2;
  1,  3,  5,   4;
  1,  4, 10,  13,    8;
  1,  5, 17,  34,   34,   16;
  1,  6, 26,  73,  116,   89,    32;
  1,  7, 37, 136,  314,  396,   233,    64;
  1,  8, 50, 229,  712, 1351,  1352,   610,   128;
  1,  9, 65, 358, 1418, 3728,  5813,  4616,  1597,  256;
  1, 10, 82, 529, 2564, 8781, 19520, 25012, 15760, 4181, 512;
  ...
		

Crossrefs

Programs

  • Maple
    A:= proc(N, n) option remember;
          `if`(n=0, 1, N*A(N, n-1) +add(A(N, n-j), j=2..n))
        end:
    seq(seq(A(d-n, n), n=0..d-1), d=1..11); # Alois P. Heinz, Aug 20 2013
  • Mathematica
    A[k_, n_] := A[k, n] = If[n == 0, 1, k*A[k, n-1] + Sum[A[k, n-j], {j, 2, n}]]; Table[A[d-n, n], {d, 1, 11}, {n, 0, d-1}] // Flatten (* Jean-François Alcover, May 27 2016, after Alois P. Heinz *)

Formula

Antidiagonals of an array in which a(n+2) = (N+1)*a(n+1) - (n-1)*a(n); with array sequences beginning (1, N, ...).
Array sequence beginning (1, N, ...) is the binomial transform of the sequence in A073133 beginning (1, (N-1), ...).
Given the first sequence of the array is (1, 1, 2, 4, 8, 16, ...), successive sequences are INVERT transforms of previous sequences.
Array sequence beginning (1, N, ...) is such that a(n), n>1 is N*(a) + a(n-1) + a(n-2) + a(n-3) + a(n-4) + ... + a(0).

A337129 Triangular array read by rows: T(n,0) = 2^n, T(n,k) = Sum_{i=n-k..n, j=0..i-n+k, i<>n or j<>k} T(i,j) for k > 0.

Original entry on oeis.org

1, 2, 3, 4, 6, 16, 8, 12, 32, 84, 16, 24, 64, 168, 440, 32, 48, 128, 336, 880, 2304, 64, 96, 256, 672, 1760, 4608, 12064, 128, 192, 512, 1344, 3520, 9216, 24128, 63168, 256, 384, 1024, 2688, 7040, 18432, 48256, 126336, 330752, 512, 768, 2048, 5376, 14080, 36864, 96512, 252672, 661504, 1731840
Offset: 0

Views

Author

Oboifeng Dira, Sep 14 2020

Keywords

Examples

			The triangle  T(n,k) begins:
   n\k  0    1    2    3    4    5
   0:   1
   1:   2    3
   2:   4    6    16
   3:   8    12   32  84
   4:   16   24   64  168  440
   5:   32   48   128 336  880  2304
   ...
T(3,2) = ((3+sqrt(5))^3-(3-sqrt(5))^3)*(2)/(4*sqrt(5)) = (64*sqrt(5))/(2*sqrt(5)) = 32.
		

Crossrefs

Cf. A000079 (1st column), A069429 (diagonal), A018903 (row sums), A001906, A004171.

Programs

  • Maple
    T := proc (n, k) if k = 0 and 0 <= n then 2^n elif 1 <= k and k <= n then round((((3+sqrt(5))^(k+1)-(3-sqrt(5))^(k+1))*(2^(n-k))/(4*sqrt(5)))) else 0 end if end proc:seq(print(seq(T(n, k), k=0..n)), n=0..9);
  • Mathematica
    T[n_, 0] := 2^n;
    T[n_, n_] := 2^(n-1) Fibonacci[2n+2];
    T[n_, k_] /; 0Jean-François Alcover, Nov 13 2020 *)
  • PARI
    T(n,k) = if (k == 0, 2^n, my(w=quadgen(5, 'w)); ((2*w+2)^(k+1)-(4-2*w)^(k+1))*(2^(n-k))/(4*(2*w-1))); \\ Michel Marcus, Sep 14 2020
    
  • PARI
    Row(n)={Vecrev(polcoef((1-x*y)*(1-2*x*y)/((1-6*x*y+4*x^2*y^2)*(1-2*x)) + O(x*x^n), n))} \\ Andrew Howroyd, Sep 23 2020

Formula

T(n,0) = 2^n.
T(n,k) = ((3+sqrt(5))^(k+1)-(3-sqrt(5))^(k+1))*(2^(n-k))/(4*sqrt(5)) for 1<=k<=n.
T(n+1,n) = 2*T(n,n).
T(n+m,n) = 2^m*T(n,n), for m>=1.
T(n,n) = A069429(n) = 2^(n-1)*A001906(n+1) for n>=1.
T(2*n,n) = (1/2)*A099157(n+1) = A004171(n-1)*A001906(n+1) for n>=1.
G.f.: (1 - x*y)*(1 - 2*x*y)/((1 - 6*x*y + 4*x^2*y^2)*(1 - 2*x)). - Andrew Howroyd, Sep 23 2020
Showing 1-2 of 2 results.