A327647 Number of parts in all proper many times partitions of n into distinct parts.
0, 1, 1, 3, 6, 15, 38, 133, 446, 1913, 7492, 36293, 175904, 953729, 5053294, 31353825, 188697696, 1268175779, 8356974190, 61775786301, 448436391810, 3579695446911, 27848806031468, 239229189529685, 2019531300063238, 18477179022470655, 165744369451885256
Offset: 0
Keywords
Examples
a(4) = 6 = 1 + 2 + 3, counting the (final) parts in 4, 4->31, 4->31->211.
Links
- Alois P. Heinz, Table of n, a(n) for n = 0..300
- Wikipedia, Partition (number theory)
Programs
-
Maple
b:= proc(n, i, k) option remember; `if`(n=0, [1, 0], `if`(k=0, [1, 1], `if`(i*(i+1)/2
(f-> f +[0, f[1]*h[2]/h[1]])(h[1]* b(n-i, min(n-i, i-1), k)))(b(i$2, k-1))))) end: a:= n-> add(add(b(n$2, i)[2]*(-1)^(k-i)* binomial(k, i), i=0..k), k=0..max(0, n-2)): seq(a(n), n=0..27); -
Mathematica
b[n_, i_, k_] := b[n, i, k] = If[n == 0, {1, 0}, If[k == 0, {1, 1}, If[i(i + 1)/2 < n, 0, b[n, i - 1, k] + Function[h, Function[f, f + {0, f[[1]]* h[[2]]/h[[1]]}][h[[1]] b[n-i, Min[n - i, i - 1], k]]][b[i, i, k - 1]]]]]; a[n_] := Sum[Sum[b[n, n, i][[2]] (-1)^(k-i) Binomial[k, i], {i, 0, k}], {k, 0, Max[0, n-2]}]; a /@ Range[0, 27] (* Jean-François Alcover, May 03 2020, after Maple *)
Comments