A111723
Number of partitions of an n-set with an odd number of blocks of size 1.
Original entry on oeis.org
1, 0, 4, 4, 31, 86, 449, 1968, 10420, 56582, 333235, 2069772, 13606113, 94065232, 682242552, 5175100432, 40954340995, 337362555010, 2886922399649, 25616738519384, 235313456176512, 2234350827008170, 21899832049913999, 221292603495494488, 2302631998398438321
Offset: 1
-
b:= proc(n, t) option remember; `if`(n=0, t, add(b(n-j,
`if`(j=1, 1-t, t))*binomial(n-1, j-1), j=1..n))
end:
a:= n-> b(n, 0):
seq(a(n), n=1..30); # Alois P. Heinz, May 10 2016
-
Rest[ Range[0, 23]! CoefficientList[ Series[ Sinh[x]Exp[Exp[x] - 1 - x], {x, 0, 23}], x]] (* Robert G. Wilson v *)
-
from sympy.core.cache import cacheit
from sympy import binomial
@cacheit
def b(n, t):
return t if n==0 else sum(b(n - j, (1 - t if j==1 else t))*binomial(n - 1, j - 1) for j in range(1, n + 1))
def a(n):
return b(n, 0)
print([a(n) for n in range(1, 51)]) # Indranil Ghosh, Aug 10 2017
A111724
Number of partitions of an n-set with an even number of blocks of size 1.
Original entry on oeis.org
0, 2, 1, 11, 21, 117, 428, 2172, 10727, 59393, 345335, 2143825, 14038324, 96834090, 700715993, 5305041715, 41910528809, 344714251149, 2945819805408, 26107419715988, 239556359980239, 2272364911439153, 22252173805170347, 224666265799310801, 2335958333831561032
Offset: 1
-
b:= proc(n, t) option remember; `if`(n=0, t, add(b(n-j,
`if`(j=1, 1-t, t))*binomial(n-1, j-1), j=1..n))
end:
a:= n-> b(n, 1):
seq(a(n), n=1..30); # Alois P. Heinz, May 10 2016
-
Rest[ Range[0, 24]! CoefficientList[ Series[ Cosh[x]Exp[Exp[x] - 1 - x], {x, 0, 23}], x]] (* Robert G. Wilson v *)
-
from sympy.core.cache import cacheit
from sympy import binomial
@cacheit
def b(n, t): return t if n==0 else sum(b(n - j, (1 - t if j==1 else t))*binomial(n - 1, j - 1) for j in range(1, n + 1))
def a(n): return b(n, 1)
print([a(n) for n in range(1, 51)]) # Indranil Ghosh, Aug 10 2017
A111752
Number of partitions of {1,..,n} into lists with an even number of lists of size 1, where a list means an ordered subset (cf. A000262).
Original entry on oeis.org
1, 0, 3, 6, 49, 300, 2491, 22890, 239457, 2782584, 35595091, 496577070, 7499663953, 121855323876, 2118793593099, 39245026343250, 771255810671041, 16025261292247920, 350956070419872547, 8078570913162379734, 194969375055353840241, 4922311437793379501340
Offset: 0
-
b:= proc(n, t) option remember; `if`(n=0, t, add(b(n-j,
`if`(j=1, 1-t, t))*binomial(n-1, j-1)*j!, j=1..n))
end:
a:= n-> b(n, 1):
seq(a(n), n=0..30); # Alois P. Heinz, May 10 2016
-
b[n_, t_] := b[n, t] = If[n == 0, t, Sum[b[n-j, If[j == 1, 1-t, t]] * Binomial[n-1, j-1]*j!, {j, 1, n}]]; a[n_] := b[n, 1]; Table[a[n], {n, 0, 30}] (* Jean-François Alcover, Jan 21 2017, after Alois P. Heinz *)
-
from sympy.core.cache import cacheit
from sympy import binomial, factorial as f
@cacheit
def b(n, t): return t if n==0 else sum(b(n - j, (1 - t if j==1 else t))*binomial(n - 1, j - 1)*f(j) for j in range(1, n + 1))
def a(n): return b(n, 1)
print([a(n) for n in range(51)]) # Indranil Ghosh, Aug 10 2017
A111753
Number of partitions of {1,..,n} into lists with an odd number of lists of size 1, where a list means an ordered subset, cf. A000262.
Original entry on oeis.org
0, 1, 0, 7, 24, 201, 1560, 14743, 154896, 1813969, 23346000, 327496071, 4970498280, 81121077337, 1416223931304, 26328776843671, 519178407998880, 10821355158998433, 237677397895531296, 5485802780426178439, 132728552830731814200, 3358841601972480225001
Offset: 0
-
b:= proc(n, t) option remember; `if`(n=0, t, add(b(n-j,
`if`(j=1, 1-t, t))*binomial(n-1, j-1)*j!, j=1..n))
end:
a:= n-> b(n, 0):
seq(a(n), n=0..30); # Alois P. Heinz, May 10 2016
-
b[n_, t_] := b[n, t] = If[n==0, t, Sum[b[n-j, If[j==1, 1-t, t]]*Binomial[ n-1, j-1]*j!, {j, 1, n}]]; a[n_] := b[n, 0]; Table[a[n], {n, 0, 30}] (* Jean-François Alcover, Feb 03 2017, after Alois P. Heinz *)
-
from sympy.core.cache import cacheit
from sympy import binomial, factorial as f
@cacheit
def b(n, t): return t if n==0 else sum([b(n - j, (1 - t if j==1 else t))*binomial(n - 1, j - 1)*f(j) for j in range(1, n + 1)])
def a(n): return b(n, 0)
print([a(n) for n in range(51)]) # Indranil Ghosh, Aug 10 2017
A113236
Number of partitions of {1,..,n} into any number of lists of size not equal to 3, where a list means an ordered subset, cf. A000262.
Original entry on oeis.org
1, 1, 3, 7, 49, 321, 2851, 24823, 256257, 2887489, 36759331, 507010791, 7597222513, 122184356737, 2106356007939, 38693238713431, 754792977928321, 15572911248409473, 338800604611562947, 7749991799652960199, 185934065196259734321, 4667877395135551746241
Offset: 0
-
m:=25; R:=PowerSeriesRing(Rationals(), m); b:=Coefficients(R!(Exp(x*(1-x^2+x^3)/(1-x)))); [Factorial(n-1)*b[n]: n in [1..m]]; // G. C. Greubel, May 17 2018
-
a:= proc(n) option remember; `if`(n=0, 1, add(
`if`(j=3, 0, a(n-j)*binomial(n-1, j-1)*j!), j=1..n))
end:
seq(a(n), n=0..30); # Alois P. Heinz, May 10 2016
-
Range[0, 18]!*CoefficientList[ Series[ Exp[x*(1-x^2+x^3)/(1 - x)], {x, 0, 18}], x] (* Zerinvary Lajos, Mar 23 2007 *)
a[n_] := a[n] = If[n==0, 1, Sum[If[j==3, 0, a[n-j]*Binomial[n-1, j-1]*j!], {j, 1, n}]]; Table[a[n], {n, 0, 30}] (* Jean-François Alcover, Feb 11 2017, after Alois P. Heinz *)
-
x='x+O('x^30); Vec(serlaplace(exp(x*(1-x^2+x^3)/(1-x)))) \\ G. C. Greubel, May 17 2018
A113237
E.g.f.: exp(x*(1 - x^3 + x^4)/(1-x)).
Original entry on oeis.org
1, 1, 3, 13, 49, 381, 2971, 26713, 291873, 3262969, 41245651, 569262981, 8433896593, 136060620853, 2342471665899, 42987065380561, 838321137046081, 17272648375895793, 375413770580941603, 8579701021461918589, 205637099039964274161, 5158188565847339152621
Offset: 0
-
a:= proc(n) option remember; `if`(n=0, 1, add(
`if`(j=4, 0, a(n-j)*binomial(n-1, j-1)*j!), j=1..n))
end:
seq(a(n), n=0..30); # Alois P. Heinz, May 10 2016
-
f[n_] := n!*Sum[(-1)^k*LaguerreL[n - 4*k, -1, -1]/k!, {k, 0, Floor[n/4]}]; Table[ f[n], {n, 0, 19}]
Range[0, 19]!* CoefficientList[ Series[ Exp[x*(1 - x^3 + x^4)/(1 - x)], {x, 0, 19}], x] (* Robert G. Wilson v, Oct 21 2005 *)
A351823
Triangular array read by rows. T(n,k) is the number of sets of lists (as in A000262(n)) with exactly k size 2 lists, n >= 0, 0 <= k <= floor(n/2).
Original entry on oeis.org
1, 1, 1, 2, 7, 6, 49, 12, 12, 301, 140, 60, 2281, 1470, 180, 120, 21211, 12642, 2940, 840, 220417, 127736, 41160, 3360, 1680, 2528569, 1527192, 455112, 70560, 15120, 32014801, 19837530, 5748120, 1234800, 75600, 30240, 442974511, 278142590, 83995560, 16687440, 1940400, 332640
Offset: 0
Triangle T(n,k) begins:
1;
1;
1, 2;
7, 6;
49, 12, 12;
301, 140, 60;
2281, 1470, 180, 120;
21211, 12642, 2940, 840;
...
-
b:= proc(n) option remember; expand(`if`(n=0, 1, add(j!*
`if`(j=2, x, 1)*b(n-j)*binomial(n-1, j-1), j=1..n)))
end:
T:= n-> (p-> seq(coeff(p, x, i), i=0..n/2))(b(n)):
seq(T(n), n=0..12); # Alois P. Heinz, Feb 20 2022
-
nn = 7; Map[Select[#, # > 0 &] &,Range[0, nn]! CoefficientList[Series[Exp[ x/(1 - x) - x ^2 + y x^2], {x, 0, nn}], {x, y}]] // Grid
Showing 1-7 of 7 results.
Comments