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-20 of 22 results. Next

A345697 Expansion of the e.g.f. sqrt(1 / (2*exp(x) - 2*x*exp(x) - 1)).

Original entry on oeis.org

1, 0, 1, 2, 12, 64, 485, 4038, 39991, 441992, 5492322, 75171700, 1127989577, 18381446004, 323527186957, 6114296752718, 123513004310640, 2655648779976640, 60554669008300565, 1459559515622280282, 37079264125376670955, 990226180225789628660, 27733277682719819190246, 812818183963966524137332, 24880254143735238825011057
Offset: 0

Views

Author

Mélika Tebni, Jun 24 2021

Keywords

Examples

			sqrt(1/(2*exp(x)-2*x*exp(x)-1)) = 1 + x^2/2! + 2*x^3/3! + 12*x^4/4! + 64*x^5/5! + 485*x^6/6! + 4038*x^7/7! + 39991*x^8/8! + 441992*x^9/9! + ...
a(13) = Sum_{k=1..6} A014307(k)*A008306(13,k) = 18381446004.
A014307(1)*A008306(13,1) == -1 (mod 13), because A014307(1) = 1 and A008306(13,1) = (13-1)!
For k>=2, A008306(13,k) == 0 (mod 13), result a(13) == -1 (mod 13).
		

Crossrefs

Programs

  • Maple
    A014307 := proc(n) option remember; `if`(n=0, 1 , 1+add((-1+binomial(n, k))*A014307(k), k=1..n-1)) end:
    A008306 := proc(n, k): if k=1 then (n-1)! ; elif n<=2*k-1 then 0; else (n-1)*procname(n-1, k)+(n-1)*procname(n-2, k-1) ; end if; end proc:
    a := n-> add((A014307(k)*A008306(n,k)), k=1..floor(n/2)):a(0):=1 ;
    seq(a(n), n=0..24);
    # second program:
    a := series(sqrt((1/(2*exp(x)-2*x*exp(x)-1))), x=0, 25):
    seq(n!*coeff(a, x, n), n=0..24);
  • Mathematica
    CoefficientList[Series[Sqrt[1/(2*E^x-2*x*E^x-1)], {x, 0, 24}], x] * Range[0, 24]!
  • PARI
    my(x='x+O('x^25)); Vec(serlaplace(sqrt(1 / (2*exp(x) - 2*x*exp(x) -1)))) \\ Michel Marcus, Jun 24 2021

Formula

E.g.f. y(x) satisfies y' = x*exp(x)*y^3.
a(0)=1, a(n) = Sum_{k=1..floor(n/2)} A014307(k)*A008306(n,k) for n >= 1.
For all p prime, a(p) == -1 (mod p).
a(n) ~ sqrt(2*c) * n^n / ((1-c)^(n+1) * exp(n)), where c = -LambertW(-exp(-1)/2). - Vaclav Kotesovec, Jun 25 2021

A345969 Expansion of the e.g.f. 1 / sqrt(3 - 2 / ((1 - x)*exp(x))).

Original entry on oeis.org

1, 0, 1, 2, 18, 104, 1015, 9666, 116557, 1504856, 22300704, 358916480, 6373675825, 122332173300, 2540560235161, 56558354414870, 1346402030278050, 34093192112537888, 915570658175517151, 25983157665663651150, 777141557158947654637, 24430880483991543481580
Offset: 0

Views

Author

Mélika Tebni, Jul 01 2021

Keywords

Examples

			1/sqrt(3-2/((1-x)*exp(x))) =  1 + x^2/2! + 2*x^3/3! + 18*x^4/4! + 104*x^5/5! + 1015*x^6/6! + 9666*x^7/7! + 116557*x^8/8! + 1504856*x^9/9! + ...
a(17) = Sum_{k=1..8} A305404(k)*A008306(17,k) = 34093192112537888.
For k=1, A305404(1)*A008306(17,1) == -1 (mod 17), because A305404(1) = 1 and A008306(17,1) = (17-1)!
For k>=2, A305404(k)*A008306(17,k) == 0 (mod 17), because A008306(17,k) == 0 (mod 17), result a(17) == -1 (mod 17).
		

Crossrefs

Programs

  • Maple
    A305404:= n-> add(Stirling2(n,k)*doublefactorial(2*k-1), k=0..n):
    A008306 := proc(n, k): if k=1 then (n-1)! ; elif n<=2*k-1 then 0; else (n-1)*procname(n-1, k)+(n-1)*procname(n-2, k-1) ; end if; end proc:
    a := n-> add((A305404(k)*A008306(n, k)), k=1..iquo(n,2)):a(0):=1 ; seq(a(n), n=0..24);
    # second program:
    a := series(1/sqrt(3-2/((1-x)*exp(x))), x=0, 25):seq(n!*coeff(a, x, n), n=0..24);
  • Mathematica
    CoefficientList[Series[1/Sqrt[3-2/((1-x)*E^x)], {x, 0, 24}], x] * Range[0, 24]!
  • PARI
    my(x='x+O('x^30)); Vec(serlaplace(1/sqrt(3 - 2 / ((1 - x)*exp(x))))) \\ Michel Marcus, Jul 01 2021

Formula

E.g.f. y(x) satisfies y' = exp(-x)*y^3*x/(1-x)^2.
a(0)=1, a(n) = Sum_{k=1..floor(n/2)} A305404(k)*A008306(n,k) for n > 0.
For all p prime, a(p) == -1 (mod p).
a(n) ~ sqrt(-2*LambertW(-2*exp(-1)/3)/3) * n^n / (exp(n) * (1 + LambertW(-2*exp(-1)/3))^(n+1)). - Vaclav Kotesovec, Jul 01 2021

A050211 Triangle of number of permutations of {1, 2, ..., n} having exactly k cycles, each of which is of length >=r for r=3.

Original entry on oeis.org

2, 6, 24, 120, 40, 720, 420, 5040, 3948, 40320, 38304, 2240, 362880, 396576, 50400, 3628800, 4419360, 859320, 39916800, 53048160, 13665960, 246400, 479001600, 684478080, 216339552, 9609600, 6227020800, 9464307840, 3501834336
Offset: 3

Views

Author

Keywords

Comments

Generalizes Stirling numbers of the first kind

Examples

			Table begins:
   n\k |      u     u^2    u^3
  = = = = = = = = = = = = = = =
    3  |      2
    4  |      6
    5  |     24
    6  |    120     40
    7  |    720    420
    8  |   5040   3948
    9  |  40320  38304    2240
   ...
		

References

  • L. Comtet, Advanced Combinatorics, Reidel, 1974, p. 257.

Crossrefs

Programs

  • Maple
    b:= proc(n) option remember; expand(`if`(n=0, 1, add(
          b(n-i)*x*binomial(n-1, i-1)*(i-1)!, i=3..n)))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=1..degree(p)))(b(n)):
    seq(T(n), n=3..15);  # Alois P. Heinz, Sep 25 2016
  • Mathematica
    t[n_ /; n >= 3, k_ /; k >= 1] := t[n, k] = (n - 1)*t[n - 1, k] + (n - 2)*(n - 1)*t[n - 3, k - 1] ; t[, ] = 0; t[3, 1] = 2; Flatten[ Table[t[n, k], {n, 3, 15}, {k, 1, Floor[n/3]}]] (* Jean-François Alcover, Nov 05 2012, after Peter Bala *)

Formula

From Peter Bala, Sep 06 2011: (Start)
E.g.f.: (1-t)^(-u)*exp(-u*(t+t^2/2)) - 1 = (2*u)*t^3/3!+(6*u)*t^4/4!+(24*u)*t^5/5!+(120*u+40*u^2)*t^6/6!+(720*u+420*u^2)*t^7/7!+....
E.g.f. for column k: 1/k!*(-log(1-x)-x-x^2/2)^k.
Starting at row 3, row lengths are 1, 1, 1, 2, 2, 2, 3, 3, 3, ....
Recurrence: T(n,k) = (n-1)*T(n-1,k) + (n-1)*(n-2)*T(n-3,k-1). (End)

A050212 Triangle of number of permutations of {1, 2, ..., n} having exactly k cycles, each of which is of length >=r for r=4.

Original entry on oeis.org

6, 24, 120, 720, 5040, 1260, 40320, 18144, 362880, 223776, 3628800, 2756160, 39916800, 35307360, 1247400, 479001600, 476910720, 38918880, 6227020800, 6822541440, 889945056, 87178291200, 103440879360, 18478684224
Offset: 4

Views

Author

Keywords

Comments

Generalizes Stirling numbers of the first kind.

Examples

			Triangle begins:
:        6;
:       24;
:      120;
:      720;
:     5040,     1260;
:    40320,    18144;
:   362880,   223776;
:  3628800,  2756160;
: 39916800, 35307360, 1247400;
		

References

  • L. Comtet, Advanced Combinatorics, Reidel, 1974, p. 257.

Crossrefs

Programs

  • Maple
    b:= proc(n) option remember; expand(`if`(n=0, 1, add(
          b(n-i)*x*binomial(n-1, i-1)*(i-1)!, i=4..n)))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=1..degree(p)))(b(n)):
    seq(T(n), n=4..20);  # Alois P. Heinz, Sep 25 2016
  • Mathematica
    b[n_] := b[n] = Expand[If[n==0, 1, Sum[b[n-i] x Binomial[n-1, i-1] (i-1)!, {i, 4, n}]]];
    T[n_] := Function[p, Table[Coefficient[p, x, i], {i, Exponent[p, x]}]][b[n]];
    Table[T[n], {n, 4, 20}] // Flatten (* Jean-François Alcover, Dec 07 2019, after Alois P. Heinz *)

Extensions

Offset changed from 1 to 4 by Alois P. Heinz, Sep 25 2016

A050213 Triangle of number of permutations of {1, 2, ..., n} having exactly k cycles, each of which is of length >=r for r=5.

Original entry on oeis.org

24, 120, 720, 5040, 40320, 362880, 72576, 3628800, 1330560, 39916800, 20338560, 479001600, 303937920, 6227020800, 4643084160, 87178291200, 73721007360, 1743565824, 1307674368000, 1224694598400, 69742632960, 20922789888000
Offset: 5

Views

Author

Keywords

Comments

Generalizes Stirling numbers of the first kind.

Examples

			Triangle begins:
05:       24;
06:      120;
07:      720;
08:     5040;
09:    40320;
10:   362880,    72576;
11:  3628800,  1330560;
12: 39916800, 20338560;
		

References

  • L. Comtet, Advanced Combinatorics, Reidel, 1974, p. 257.

Crossrefs

Programs

  • Maple
    b:= proc(n) option remember; expand(`if`(n=0, 1, add(
          b(n-i)*x*binomial(n-1, i-1)*(i-1)!, i=5..n)))
        end:
    T:= n-> (p-> seq(coeff(p, x, i), i=1..degree(p)))(b(n)):
    seq(T(n), n=5..20);  # Alois P. Heinz, Sep 25 2016
  • Mathematica
    b[n_] := b[n] = Expand[If[n == 0, 1, Sum[b[n - i]*x*Binomial[n - 1, i - 1]* (i - 1)!, {i, 5, n}]]];
    T[n_] := Function[p, Table[Coefficient[p, x, i], {i, 1, Exponent[p, x]}]][ b[n]];
    T /@ Range[5, 20] // Flatten (* Jean-François Alcover, Dec 08 2019, after Alois P. Heinz *)

Extensions

Offset changed from 1 to 5 by Alois P. Heinz, Sep 25 2016

A079510 Triangle T(n,k) read by rows; related to number of preorders.

Original entry on oeis.org

1, 0, 2, 0, 3, 6, 0, 0, 20, 24, 0, 0, 15, 130, 120, 0, 0, 0, 210, 924, 720, 0, 0, 0, 105, 2380, 7308, 5040, 0, 0, 0, 0, 2520, 26432, 64224, 40320, 0, 0, 0, 0, 945, 44100, 303660, 623376, 362880, 0, 0, 0, 0, 0, 34650, 705320, 3678840, 6636960, 3628800
Offset: 1

Views

Author

N. J. A. Sloane, Jan 21 2003

Keywords

Comments

There are only m nonzero entries in the m-th column.

Examples

			Triangle begins:
  1;
  0,   2;
  0,   3,   6;
  0,   0,  20,  24;
  0,   0,  15, 130, 120;
  ...
		

Crossrefs

A rearrangement of the triangle in A008306. - Benoit Cloitre, Jan 27 2003

Programs

  • Mathematica
    T[n_, k_]:= If[k < 1 || k > n, 0, If[n==1 && k==1, 1, n*(T[n-1, k-1] + T[n-2, k-1])]]; Table[T[n, k], {n, 1, 10}, {k, 1, n}]//Flatten (* G. C. Greubel, Jan 17 2019 *)
  • PARI
    T(n,k)=if(k<=0 || k>n, 0, if(n==1 && k==1, 1, n*(T(n-1,k-1)+T(n-2,k-1))));

Extensions

Recurrence and more terms from Michael Somos, Jan 23 2003
Offset changed to 1 by G. C. Greubel, Jan 17 2019

A346119 Expansion of the e.g.f. sqrt(2*x*exp(x) - 2*exp(x) + 3).

Original entry on oeis.org

1, 0, 1, 2, 0, -16, -35, 342, 2779, -6424, -239382, -822460, 22393657, 278844084, -1553468891, -68399947042, -275025888900, 15302175612416, 243541868882077, -2463105309082902, -121649966081262521, -473088821582805820, 50905612811064360006, 945133249101683013812, -15321255878414345388335
Offset: 0

Views

Author

Mélika Tebni, Jul 05 2021

Keywords

Examples

			sqrt(2*x*exp(x)-2*exp(x)+3) = 1 + x^2/2! + 2*x^3/3! - 16*x^5/5! - 35*x^6/6! + 342*x^7/7! + 2779*x^8/8! - 6424*x^9/9! + ...
a(11) = Sum_{k=1..5} (-1)^(k-1)*A006677(k)*A008306(11,k) = -822460.
For k=1, (-1)^(1-1)*A006677(1)*A008306(11,1) == -1 (mod 11), because A006677(1) = 1 and A008306(11,1) = (11-1)!
For k>=2, (-1)^(k-1)*A006677(k)*A008306(11,k) == 0 (mod 11), because A008306(11,k) == 0 (mod 11), result a(11) == -1 (mod 11).
a(8) = Sum_{k=1..4} (-1)^(k-1)*A006677(k)*A008306(8,k) = 2779.
a(8) == 0 (mod (8-1)), because for k >= 1, A008306(8,k) == 0 (mod 7).
		

Crossrefs

Programs

  • Maple
    stirtr:= proc(p) proc(n) add(p(k)*Stirling2(n, k), k=0..n) end end: f:= n-> `if`(n=0, 1, (2*n-2)!/ (n-1)!/ 2^(n-1)): A006677:= stirtr(f): # Alois P. Heinz, 2008.
    A008306 := proc(n, k): if k=1 then (n-1)! ; elif n<=2*k-1 then 0; else (n-1)*procname(n-1, k)+(n-1)*procname(n-2, k-1) ; end if; end proc:
    a:= n-> add(((-1)^(k-1)*A006677(k)*A008306(n,k)), k=1..iquo(n,2)):a(0):=1 ; seq(a(n), n=0..24);
    # second program:
    a := series(sqrt(2*x*exp(x)-2*exp(x)+3), x=0, 25):seq(n!*coeff(a, x, n), n=0..24);
  • Mathematica
    CoefficientList[Series[Sqrt(2*x*E^x-2*E^x+3), {x, 0, 24}], x] * Range[0, 24]!
  • PARI
    my(x='x+O('x^30)); Vec(serlaplace(sqrt(2*x*exp(x) - 2*exp(x) + 3))) \\ Michel Marcus, Jul 05 2021

Formula

E.g.f. y(x) satisfies y*y' = x*exp(x).
a(0)=1, a(n) = Sum_{k=1..floor(n/2)} (-1)^(k-1)*A006677(k)*A008306(n,k) for n > 0.
For all p prime, a(p) == -1 (mod p).
For n > 1, a(n) == 0 (mod (n-1)).
Conjecture: a(n) = 0 for only n = 1 and n = 4.

A162973 Number of cycles in all derangement permutations of {1,2,...,n}.

Original entry on oeis.org

0, 1, 2, 12, 64, 425, 3198, 27216, 258144, 2701737, 30933770, 384675148, 5163521856, 74417353985, 1146203362822, 18790377267840, 326682354342336, 6003886529652657, 116305541572943826, 2368629865508978284
Offset: 1

Views

Author

Emeric Deutsch, Jul 22 2009

Keywords

Examples

			a(4)=12 because in the derangements of {1,2,3,4}, namely (12)(34), (13)(24), (14)(23), (1234), (1243), (1324), (1342), (1423), and (1432), we have a total of 2+2+2+1+1+1+1+1+1=12 cycles.
		

Crossrefs

Programs

  • Maple
    G := exp(-z)*(z+ln(1-z))/(z-1): Gser := series(G, z = 0, 25): seq(factorial(n)*coeff(Gser, z, n), n = 1 .. 22);
  • Mathematica
    With[{nn=20},Rest[CoefficientList[Series[Exp[-x] (x+Log[1-x])/(x-1), {x,0,nn}],x] Range[0,nn]!]] (* Harvey P. Dale, Jul 25 2013 *)
  • PARI
    x='x+O('x^30); concat([0], Vec(serlaplace(exp(-x)*(x+log(1-x))/(x -1)))) \\ G. C. Greubel, Sep 01 2018

Formula

a(n) = Sum_{k>=1} k*A008306(n,k).
E.g.f.: exp(-z)*(z+log(1-z))/(z-1).
a(n) ~ n! * (log(n) + gamma - 1)/exp(1), where gamma is the Euler-Mascheroni constant (A001620). - Vaclav Kotesovec, Sep 25 2013
a(n) = A000254(n) - A162972(n). - Anton Zakharov, Oct 18 2016
D-finite with recurrence a(n) +2*(-n+2)*a(n-1) +(n-2)*(n-6)*a(n-2) +(3*n-8)*(n-3)*a(n-3) +3*(n-3)^2*a(n-4) +(n-3)*(n-4)*a(n-5)=0. - R. J. Mathar, Jul 26 2022

A343482 Expansion of the e.g.f. sqrt(-1 + 2 / (1 - x) / exp(x)).

Original entry on oeis.org

1, 0, 1, 2, 6, 24, 135, 930, 7105, 59192, 549360, 5746080, 66713361, 839528052, 11308954657, 163038260294, 2520332282910, 41640324943968, 730119174449151, 13507292654421390, 263004450921933817, 5385277610047242620, 115775314245285797256, 2606072891349667903152, 61248210450060537498321
Offset: 0

Views

Author

Mélika Tebni, Jul 06 2021

Keywords

Examples

			sqrt(-1+2/(1-x)/exp(x)) =  1 + x^2/2! + 2*x^3/3! + 6*x^4/4! + 24*x^5/5! + 135*x^6/6! + 930*x^7/7! + 7105*x^8/8! + 59192*x^9/9! + ...
a(23) = Sum_{k=1..11} (-1)^(k-1)*A014304(k-1)*A008306(23,k) = 2606072891349667903152.
For k=1, (-1)^(1-1)*A014304(1-1)*A008306(23,1) == -1 (mod 23), because A014304(0) = 1 and A008306(23,1) = (23-1)!
For k>=2, (-1)^(k-1)*A014304(k-1)*A008306(23,k) == 0 (mod 23), because A008306(23,k) == 0 (mod 23), result a(23) == -1 (mod 23).
a(18) = Sum_{k=1..9} (-1)^(k-1)*A014304(k-1)*A008306(18,k) = 730119174449151.
a(18) == 0 (mod (18-1)), because for k >= 1, A008306(18,k) == 0 (mod 17).
		

Crossrefs

Programs

  • Maple
    A014304:= proc(n) option remember; `if`(n=0, 1, (-1)^n + add(binomial(n,k)*A014304(k)* A014304(n-k-1), k=0..n-1)) end:
    A008306 := proc(n, k): if k=1 then (n-1)! ; elif n<=2*k-1 then 0; else (n-1)*procname(n-1, k)+(n-1)*procname(n-2, k-1) ; end if; end proc:
    a:= n-> add(((-1)^(k-1)*A014304(k-1)*A008306(n,k)), k=1..iquo(n,2)):a(0):=1 ; seq(a(n), n=0..24);
    # second program:
    a := series(sqrt(-1+2/(1-x)/exp(x)), x=0, 25):seq(n!*coeff(a, x, n), n=0..24);
  • Mathematica
    CoefficientList[Series[Sqrt[-1+2/(1-x)/E^x], {x, 0, 24}], x] * Range[0, 24]!
  • PARI
    my(x='x+O('x^30)); Vec(serlaplace(sqrt(-1 + 2 / (1 - x) / exp(x)))) \\ Michel Marcus, Jul 06 2021

Formula

E.g.f. y(x) satisfies y*y' = exp(-x)*x/(1-x)^2.
a(0)=1, a(n) = Sum_{k=1..floor(n/2)} (-1)^(k-1)*A014304(k-1)*A008306(n,k) for n > 0.
For all p prime, a(p) == -1 (mod p).
For n > 1, a(n) == 0 (mod (n-1)).
a(n) ~ 2 * n^n / exp(n + 1/2). - Vaclav Kotesovec, Jul 06 2021

A358622 Regular triangle read by rows. T(n, k) = [[n, k]], where [[n, k]] are the second order Stirling cycle numbers (or second order reciprocal Stirling numbers). T(n, k) for 0 <= k <= n.

Original entry on oeis.org

1, 0, 0, 0, 1, 0, 0, 2, 0, 0, 0, 6, 3, 0, 0, 0, 24, 20, 0, 0, 0, 0, 120, 130, 15, 0, 0, 0, 0, 720, 924, 210, 0, 0, 0, 0, 0, 5040, 7308, 2380, 105, 0, 0, 0, 0, 0, 40320, 64224, 26432, 2520, 0, 0, 0, 0, 0, 0, 362880, 623376, 303660, 44100, 945, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Peter Luschny, Nov 23 2022

Keywords

Comments

[[n, k]] are the number of permutations of an n-set having at least two elements in each orbit. These permutations have no fixed points and therefore [[n, k]] is the number of k-orbit derangements of an n-set. This is the definition and notation (doubling the stacked delimiters of the Stirling cycle numbers) as given by Fekete (see link).
The formal definition expresses the second order Stirling cycle numbers as a binomial sum over second order Eulerian numbers (see the first formula below). The terminology 'associated Stirling numbers of first kind' used elsewhere should be dropped in favor of the more systematic one used here.
Also the Bell transform of the factorial numbers with 0! = 0. For the definition of the Bell transform see A264428.

Examples

			Triangle T(n, k) starts:
[0] 1;
[1] 0,     0;
[2] 0,     1,     0;
[3] 0,     2,     0,     0;
[4] 0,     6,     3,     0,    0;
[5] 0,    24,    20,     0,    0,  0;
[6] 0,   120,   130,    15,    0,  0,  0;
[7] 0,   720,   924,   210,    0,  0,  0,  0;
[8] 0,  5040,  7308,  2380,  105,  0,  0,  0,  0;
[9] 0, 40320, 64224, 26432, 2520,  0,  0,  0,  0,  0;
		

References

  • Ronald L. Graham, Donald E. Knuth, and Oren Patashnik, Concrete Mathematics, Addison-Wesley, Reading, 2nd ed. 1994, thirty-fourth printing 2022.

Crossrefs

A008306 is an irregular subtriangle with more information.
Cf. A000166 (row sums), A024000 (alternating row sums).

Programs

  • Maple
    P := (n, x) -> (-x)^n*hypergeom([-n, x], [], 1/x):
    row := n -> seq(coeff(simplify(P(n, x)), x, k), k = 0..n):
    for n from 0 to 9 do row(n) od;
    # Alternative:
    T := (n, k) -> add(binomial(n, k - j)*abs(Stirling1(n - k + j, j))*(-1)^(k - j), j =  0..k): for n from 0 to 9 do seq(T(n, k), k = 0..n) od;
    # Using the e.g.f.:
    egf := (exp(t)*(1 - t))^(-z): ser := series(egf, t, 12):
    seq(print(seq(n!*coeff(coeff(ser, t, n), z, k), k=0..n)), n = 0..9);
    # Using second order Eulerian numbers:
    A358622 := proc(n, k) local j;
    add(binomial(j, n - 2*k)*combinat:-eulerian2(n - k, j), j = 0..n-k) end:
    seq(seq(A358622(n, k), k = 0..n), n = 0..12);
    # Using generalized Laguerre polynomials:
    P := (n, x) -> (-1)^n*n!*LaguerreL(n, -n - x, -x):
    row := n -> seq(coeff(simplify(P(n, x)), x, k), k = 0..n):
    seq(print(row(n)), n = 0..9);
  • Python
    # recursion over rows
    from functools import cache
    @cache
    def StirlingCycleOrd2(n: int) -> list[int]:
        if n == 0: return [1]
        if n == 1: return [0, 0]
        rov: list[int] = StirlingCycleOrd2(n - 2)
        row: list[int] = StirlingCycleOrd2(n - 1) + [0]
        for k in range(1, n // 2 + 1):
            row[k] = (n - 1) * (rov[k - 1] + row[k])
        return row
    for n in range(9): print(StirlingCycleOrd2(n))
    # Alternative, using function BellMatrix from A264428.
    from math import factorial
    def f(k: int) -> int:
        return factorial(k) if k > 0 else 0
    print(BellMatrix(f, 9))

Formula

T(n, k) = Sum_{j=0..n-k} binomial(j, n - 2*k)*<>, where <> denote the second order Eulerian numbers (extending Knuth's notation).
T(n, k) = [x^n] (-x)^n * hypergeom([-n, x], [], -1/x).
T(n, k) = n!*[z^k][t^n] (exp(t)*(1 - t))^(-z). (Compare with (exp(t)/(1 - t))^z, which is the e.g.f. of the Sylvester polynomials A341101.)
T(n, k) = [x^k] (-1)^n * n! * L(n, -x - n, -x), where L(n, a, x) is the n-th generalized Laguerre polynomial.
T(n, k) = Sum_{j=0..k} binomial(n, k - j)*[n - k + j, j]*(-1)^(k - j), where [n, k] denotes the (signless) Stirling cycle numbers.
T(n, k) = (n - 1) * (T(n-2, k-1) + T(n-1, k)) with suitable boundary conditions.
T(n + k, k) = A269940(n, k), which might be called the Ward cycle numbers.
Previous Showing 11-20 of 22 results. Next