OFFSET
0,2
COMMENTS
A perfect partition of n contains a unique partition for any k in {0,...,n}. See also A002033.
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..3000
Eric Weisstein's World of Mathematics, Perfect Partition
FORMULA
a(n) = A258119(n,1).
EXAMPLE
For n=7 there are 4 perfect partitions: [4,1,1,1], [4,2,1], [2,2,2,1] and [1,1,1,1,1,1,1], their encodings as Product_{i:lambda} prime(i) give 56, 42, 54, 128, respectively. The smallest value is a(7) = 42.
MAPLE
b:= (n, l)-> `if`(n=1, 2^(l[1]-1)*mul(ithprime(mul(l[j],
j=1..i-1))^(l[i]-1), i=2..nops(l)), min(seq(b(n/d,
[l[], d]), d=numtheory[divisors](n) minus{1}))):
a:= n-> `if`(n=0, 1, b(n+1, [])):
seq(a(n), n=0..42);
MATHEMATICA
b[n_, l_] := If[n==1, 2^(l[[1]]-1)*Product[Prime[Product[l[[j]], {j, 1, i-1}]]^(l[[i]]-1), {i, 2, Length[l]}], Min[Table[b[n/d, Append[l, d]], {d, Divisors[n] ~Complement~ {1}}]]];
a[n_] := If[n==0, 1, b[n+1, {}]];
Table[a[n], {n, 0, 42}] (* Jean-François Alcover, Mar 23 2017, translated from Maple *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Jul 09 2015
STATUS
approved