OFFSET
1,2
COMMENTS
The Heinz number of an integer partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k).
This sequence is idempotent, meaning a(a(n)) = a(n) for all n.
All terms belong to A289509.
LINKS
Antti Karttunen, Table of n, a(n) for n = 1..65537
Wikipedia, Idempotence
MATHEMATICA
f[n_]:=If[n==1, 1, With[{pms=Flatten[Cases[FactorInteger[n], {p_, k_}:>Table[PrimePi[p], {k}]]]}, Times@@Prime/@(pms/GCD@@pms)]];
Table[f[n], {n, 100}]
PROG
(PARI) A316437(n) = if(1==n, 1, my(f = factor(n), pis = apply(p -> primepi(p), f[, 1]~), es = f[, 2]~, g = gcd(pis)); factorback(vector(#f~, k, prime(pis[k]/g)^es[k]))); \\ Antti Karttunen, Aug 06 2018
CROSSREFS
KEYWORD
nonn
AUTHOR
Gus Wiseman, Jul 03 2018
EXTENSIONS
More terms from Antti Karttunen, Aug 06 2018
STATUS
approved