login
A266325
Smallest integer m such that there is a partition of m with product of multiplicities of parts equal to n.
2
0, 2, 3, 4, 5, 6, 7, 8, 9, 9, 11, 10, 13, 11, 11, 12, 17, 12, 19, 13, 13, 15, 23, 14, 15, 17, 15, 15, 29, 16, 31, 16, 17, 21, 17, 17, 37, 23, 19, 18, 41, 19, 43, 19, 19, 27, 47, 20, 21, 20, 23, 21, 53, 21, 21, 21, 25, 33, 59, 22, 61, 35, 22, 22, 23, 23, 67, 25
OFFSET
1,2
LINKS
FORMULA
a(n) = min { m >= 0 : A266477(m,n) > 0 }.
p in primes => a(p) = p.
MAPLE
b:= proc(n, i, p) option remember; `if`(n=0, `if`(p=1, 1, 0),
`if`(i<1, 0, b(n, i-1, p)+add(`if`(irem(p, j)=0,
b(n-i*j, i-1, p/j), 0), j=1..n/i)))
end:
a:= proc(n) option remember; local m;
if isprime(n) then return n fi;
for m from 0 do if b(m$2, n)>0 then return m fi od
end:
seq(a(n), n=1..100);
MATHEMATICA
b[n_, i_, p_] := b[n, i, p] = If[n == 0, If[p == 1, 1, 0], If[i < 1, 0, b[n, i - 1, p] + Sum[If[Mod[p, j] == 0, b[n - i*j, i - 1, p/j], 0], {j, 1, n/i}]]]; a[n_] := a[n] = Module[{m}, If[PrimeQ[n], Return[n]]; For[m = 0, True, m++, If[b[m, m, n] > 0, Return[m]]]]; Table[a[n], {n, 1, 100}] (* Jean-François Alcover, Dec 21 2016, translated from Maple *)
CROSSREFS
Cf. A266477.
Sequence in context: A239092 A017884 A072139 * A262087 A261914 A261423
KEYWORD
nonn
AUTHOR
STATUS
approved