login
A328478
Divide n by the largest primorial that divides it and repeat until a fixed point is reached; a(n) is the fixed point.
8
1, 1, 3, 1, 5, 1, 7, 1, 9, 5, 11, 1, 13, 7, 15, 1, 17, 3, 19, 5, 21, 11, 23, 1, 25, 13, 27, 7, 29, 1, 31, 1, 33, 17, 35, 1, 37, 19, 39, 5, 41, 7, 43, 11, 45, 23, 47, 1, 49, 25, 51, 13, 53, 9, 55, 7, 57, 29, 59, 1, 61, 31, 63, 1, 65, 11, 67, 17, 69, 35, 71, 1, 73, 37, 75, 19, 77, 13, 79, 5, 81, 41, 83, 7, 85, 43, 87, 11, 89
OFFSET
1,3
FORMULA
If A111701(n) == n, then a(n) = n, otherwise a(n) = a(A111701(n)).
a(n) = n / A328479(n).
MATHEMATICA
A111701[n_] := A111701[n] = Block[{m = n, k = 1}, While[IntegerQ[m/Prime[k]], m = m/Prime[k]; k++]; m];
a[n_] := a[n] = If[A111701[n] == n, n, a[A111701[n]]];
Array[a, 105] (* Jean-François Alcover, Jan 11 2022, after Robert G. Wilson v in A111701 *)
PROG
(PARI)
A111701(n) = forprime(p=2, , if(n%p, return(n), n /= p));
A328478(n) = { my(u=A111701(n)); if(u==n, return(n), return(A328478(u))); };
CROSSREFS
Cf. A007814 (gives the number of iterations to reach a fixed point), A025487 (indices of 1's).
Cf. also A093411 for analogous sequence.
Sequence in context: A339421 A336898 A300330 * A093411 A147088 A346468
KEYWORD
nonn
AUTHOR
Antti Karttunen, Oct 19 2019
EXTENSIONS
Definition clarified by N. J. A. Sloane, Jan 19 2021
STATUS
approved