|
|
A032022
|
|
Number of compositions (ordered partitions) of n into distinct parts >= 2.
|
|
17
|
|
|
1, 0, 1, 1, 1, 3, 3, 5, 5, 13, 13, 21, 27, 35, 65, 79, 109, 147, 207, 245, 449, 517, 745, 957, 1335, 1691, 2237, 3463, 4273, 5787, 7611, 10109, 13061, 17413, 21493, 32853, 39627, 53675, 68321, 91663, 114997, 152811, 192063, 245885, 346649, 428869, 557305
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,6
|
|
LINKS
|
|
|
FORMULA
|
"AGK" (ordered, elements, unlabeled) transform of 0, 1, 1, 1...
G.f.: sum(i>=0, i! * x^((i^2+3*i)/2) / prod(j=1..i, 1-x^j ) ). - Vladeta Jovovic, May 21 2006
|
|
MAPLE
|
b:= proc(n, i) option remember; local s; s:= i*(i+1)/2-1;
`if`(n=0, [1], `if`(i<2 or n>s, [], zip((x, y)->x+y,
b(n, i-1), [0, `if`(i>n, [], b(n-i, i-1))[]], 0)))
end:
a:= proc(n) option remember; local l; l:= b(n$2);
add(l[i]*(i-1)!, i=1..nops(l))
end:
|
|
MATHEMATICA
|
zip = With[{m = Max[Length[#1], Length[#2]]}, PadRight[#1, m] + PadRight[#2, m]]&; b[n_, i_] := b[n, i] = With[{s = i*(i+1)/2-1}, If[n == 0, {1}, If[i<2 || n>s, {}, zip[ b[n, i-1], Join[{0}, If[i>n, {}, b[n-i, i - 1]]]]]]]; a[n_] := a[n] = Module[{l = b[n, n]}, Sum[l[[i]]*(i-1)!, {i, 1, Length[l]}]]; Table[a[n], {n, 0, 70}] (* Jean-François Alcover, Feb 13 2017, after Alois P. Heinz *)
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|