OFFSET
1,2
COMMENTS
a(a(n)) = A102440(a(n)) = a(n).
Completely multiplicative because A102440 is. The conversion of every prime into a 3-smooth number is independent of any other prime. - Andrew Howroyd, Jul 31 2018
LINKS
Andrew Howroyd, Table of n, a(n) for n = 1..1000
EXAMPLE
See A102442.
MATHEMATICA
g[p_] := (* greatest semiprime less than prime p *) g[p] = For[k = p - 1, True, k--, If[PrimeOmega[k] == 2, Return[k]]];
A102440[n_] := Product[{p, e} = pe; If[p <= 3, p, g[p]]^e, {pe, FactorInteger[n]}];
a[n_] := b[n, A102442[n]];
b[n_, 0] := n;
b[n_, k_] := A102440[b[n, k - 1]];
Table[a[n], {n, 1, 100}] (* Jean-François Alcover, Oct 16 2021 *)
PROG
(PARI) a(n)={while(1, my(f=factor(n)); if(!#select(t->t>3, f[, 1]), return(n), n=prod(i=1, #f~, my(p=f[i, 1]); while(p>4 && bigomega(p)<>2, p--); p^f[i, 2])))} \\ Andrew Howroyd, Jul 31 2018
CROSSREFS
KEYWORD
nonn,mult
AUTHOR
Reinhard Zumkeller, Jan 09 2005
STATUS
approved