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

A276890 Number A(n,k) of ordered set partitions of [n] such that for each block b the smallest integer interval containing b has at most k elements; square array A(n,k), n>=0, k>=0, read by antidiagonals.

Original entry on oeis.org

1, 1, 0, 1, 1, 0, 1, 1, 2, 0, 1, 1, 3, 6, 0, 1, 1, 3, 10, 24, 0, 1, 1, 3, 13, 44, 120, 0, 1, 1, 3, 13, 62, 234, 720, 0, 1, 1, 3, 13, 75, 352, 1470, 5040, 0, 1, 1, 3, 13, 75, 466, 2348, 10656, 40320, 0, 1, 1, 3, 13, 75, 541, 3272, 17880, 87624, 362880, 0
Offset: 0

Views

Author

Alois P. Heinz, Sep 21 2016

Keywords

Comments

Column k > 0 is asymptotic to exp(k-1) * n!. - Vaclav Kotesovec, Sep 22 2016

Examples

			Square array A(n,k) begins:
  1,    1,     1,     1,     1,     1,     1,     1, ...
  0,    1,     1,     1,     1,     1,     1,     1, ...
  0,    2,     3,     3,     3,     3,     3,     3, ...
  0,    6,    10,    13,    13,    13,    13,    13, ...
  0,   24,    44,    62,    75,    75,    75,    75, ...
  0,  120,   234,   352,   466,   541,   541,   541, ...
  0,  720,  1470,  2348,  3272,  4142,  4683,  4683, ...
  0, 5040, 10656, 17880, 26032, 34792, 42610, 47293, ...
		

Crossrefs

Main diagonal gives: A000670.

Programs

  • Maple
    b:= proc(n, m, l) option remember; `if`(n=0, m!,
          add(b(n-1, max(m, j), [subsop(1=NULL, l)[],
          `if`(j<=m, 0, j)]), j={l[], m+1} minus {0}))
        end:
    A:= (n, k)-> `if`(k=0, `if`(n=0, 1, 0),
                 `if`(k=1, n!, b(n, 0, [0$(k-1)]))):
    seq(seq(A(n, d-n), n=0..d), d=0..12);
  • Mathematica
    b[n_, m_, l_List] := b[n, m, l] = If[n == 0, m!, Sum[b[n - 1, Max[m, j], Append[ReplacePart[l, 1 -> Nothing], If[j <= m, 0, j]]], {j, Append[l, m + 1] ~Complement~ {0}}]]; A[n_, k_] := If[k==0, If[n==0, 1, 0], If[k==1, n!, b[n, 0, Array[0&, k-1]]]]; Table[A[n, d-n], {d, 0, 12}, {n, 0, d}] // Flatten (* Jean-François Alcover, Jan 06 2017, after Alois P. Heinz *)

Formula

A(n,k) = Sum_{j=0..k} A276891(n,j).

A240921 G.f.: Sum_{n>=0} n^n * x^n * (1 + n*x)^n / (1 + n*x + n^2*x^2)^(n+1).

Original entry on oeis.org

1, 1, 3, 18, 146, 1530, 19620, 297360, 5201784, 103146120, 2286181800, 56011087440, 1503057473280, 43844234353920, 1381310964633600, 46743301840435200, 1690919874777893760, 65116170597269151360, 2659604669692822051200, 114838104572526535200000, 5226654647185285702752000
Offset: 0

Views

Author

Paul D. Hanna, Aug 02 2014

Keywords

Comments

a(n) is divisible by [n/2]!.
Compare definition to the following identity, which holds for all fixed k:
Sum_{n>=0} n!*x^n = Sum_{n>=0} x^n * (n + k*x)^n / (1 + n*x + k*x^2)^(n+1).

Examples

			G.f.: A(x) = 1 + x + 3*x^2 + 18*x^3 + 146*x^4 + 1530*x^5 + 19620*x^6 +...
where
A(x) = 1 + x*(1+x)/(1+x+x^2)^2 + 2^2*x^2*(1+2*x)^2/(1+2*x+4*x^2)^3 + 3^3*x^3*(1+3*x)^3/(1+3*x+9*x^2)^4 + 4^4*x^4*(1+4*x)^4/(1+4*x+16*x^2)^5 +...
		

Crossrefs

Programs

  • Mathematica
    Table[Sum[(n-k)! * StirlingS2[n, n-k] * Binomial[n-k,k],{k,0,Floor[n/2]}],{n,0,20}] (* Vaclav Kotesovec, Aug 03 2014 *)
  • PARI
    /* From definition: */
    {a(n)=local(A=1); A=sum(m=0, n, m^m*x^m*(1+m*x)^m/(1 + m*x + m^2*x^2 +x*O(x^n))^(m+1)); polcoeff(A, n)}
    for(n=0,30,print1(a(n),", "))
    
  • PARI
    /* From formula for a(n): */
    {Stirling2(n, k)=sum(i=0, k, (-1)^i*binomial(k, i)*i^n)*(-1)^k/k!}
    {a(n)=sum(k=0,n\2, (n-k)!*Stirling2(n, n-k)*binomial(n-k,k))}
    for(n=0,30,print1(a(n),", "))

Formula

a(n) = Sum_{k=0..[n/2]} (n-k)! * Stirling2(n, n-k) * binomial(n-k,k).
a(n) ~ c * d^n * n^n / exp(n), where d = r*(-1+3*r-3*r^2)/(1-3*r+2*r^2) = 2.334305682349197638435662..., where r = 0.722795640379451585372396... is the root of the equation (1-r) * (r + 1/LambertW(-exp(-1/r)/r)) + (2*r-1)^2 = 0, and c = 1.04764685950245700560418116727397... . - Vaclav Kotesovec, Aug 03 2014

A370510 Expansion of Sum_{k>=0} k! * ( x * (1+x^3) )^k.

Original entry on oeis.org

1, 1, 2, 6, 25, 124, 738, 5136, 40922, 367218, 3664224, 40240560, 482278326, 6263414736, 87618506160, 1313435465280, 21003904630824, 356910121855320, 6422020465846320, 121980351190294800, 2438956634267865720, 51206322309647263200, 1126314497201852150640
Offset: 0

Views

Author

Seiichi Manyama, Feb 20 2024

Keywords

Crossrefs

Programs

  • PARI
    my(N=30, x='x+O('x^N)); Vec(sum(k=0, N, k!*(x*(1+x^3))^k))
    
  • PARI
    a(n) = sum(k=0, n\4, (n-3*k)!*binomial(n-3*k, k));

Formula

a(n) = Sum_{k=0..floor(n/4)} (n-3*k)! * binomial(n-3*k,k).

A370509 Expansion of Sum_{k>=0} k! * ( x * (1+x^2) )^k.

Original entry on oeis.org

1, 1, 2, 7, 28, 138, 818, 5658, 44784, 399366, 3962256, 43289760, 516432984, 6679346280, 93091875120, 1390851720840, 22175338353120, 375794883339120, 6745177713093840, 127830886641354960, 2550687440585679360, 53451172032327664560, 1173650135526055272960
Offset: 0

Views

Author

Seiichi Manyama, Feb 20 2024

Keywords

Crossrefs

Programs

  • PARI
    my(N=30, x='x+O('x^N)); Vec(sum(k=0, N, k!*(x*(1+x^2))^k))
    
  • PARI
    a(n) = sum(k=0, n\3, (n-2*k)!*binomial(n-2*k, k));

Formula

a(n) = Sum_{k=0..floor(n/3)} (n-2*k)! * binomial(n-2*k,k).

A346550 Expansion of Sum_{k>=0} k! * x^k * (1 + x)^(k+1).

Original entry on oeis.org

1, 2, 4, 13, 54, 278, 1704, 12126, 98280, 893904, 9017280, 99918120, 1206500400, 15768729360, 221792780160, 3340515069360, 53641756586880, 914849722725120, 16514863528665600, 314599179867396480, 6306817346711481600, 132727279189258656000
Offset: 0

Views

Author

Seiichi Manyama, Nov 30 2021

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_] := Sum[k! * Binomial[k + 1, n - k], {k, Floor[n/2], n}]; Array[a, 22, 0] (* Amiram Eldar, Nov 30 2021 *)
  • PARI
    a(n) = sum(k=n\2, n, k!*binomial(k+1, n-k));
    
  • PARI
    a(n) = if(n<3, 2^n, (n-2)*a(n-1)+2*(n-1)*a(n-2)+(n-2)*a(n-3));
    
  • PARI
    my(N=40, x='x+O('x^N)); Vec(sum(k=0, N, k!*x^k*(1+x)^(k+1)))

Formula

a(n) = Sum_{k=floor(n/2)..n} k! * binomial(k+1,n-k).
a(n) = A240172(n-1) + A240172(n) for n > 0.
a(n) = (n-2) * a(n-1) + 2 * (n-1) * a(n-2) + (n-2) * a(n-3) for n > 2.
a(n) ~ exp(1) * n! * (1 - 1/n + 3/(2*n^2) - 2/(3*n^3) - 47/(24*n^4) + 49/(120*n^5) + 6421/(720*n^6) + ...). - Vaclav Kotesovec, Dec 11 2021

A370668 Expansion of Sum_{k>0} k! * ( x * (1+x^k) )^k.

Original entry on oeis.org

1, 3, 6, 28, 120, 740, 5040, 40416, 362898, 3629400, 39916800, 479006070, 6227020800, 87178326480, 1307674369200, 20922790210656, 355687428096000, 6402373709004720, 121645100408832000, 2432902008212929224, 51090942171709545840, 1124000727778046764800
Offset: 1

Views

Author

Seiichi Manyama, Feb 25 2024

Keywords

Crossrefs

Programs

  • PARI
    my(N=30, x='x+O('x^N)); Vec(sum(k=1, N, k!*(x*(1+x^k))^k))
    
  • PARI
    a(n) = sumdiv(n,d, d!*binomial(d, n/d-1));

Formula

a(n) = Sum_{d|n} d! * binomial(d,n/d-1).
If p is an odd prime, a(p) = p!.
Showing 1-6 of 6 results.