login
A284723
Smallest odd prime that is relatively prime to n.
5
3, 3, 5, 3, 3, 5, 3, 3, 5, 3, 3, 5, 3, 3, 7, 3, 3, 5, 3, 3, 5, 3, 3, 5, 3, 3, 5, 3, 3, 7, 3, 3, 5, 3, 3, 5, 3, 3, 5, 3, 3, 5, 3, 3, 7, 3, 3, 5, 3, 3, 5, 3, 3, 5, 3, 3, 5, 3, 3, 7, 3, 3, 5, 3, 3, 5, 3, 3, 5, 3, 3, 5, 3, 3, 7, 3, 3, 5, 3, 3, 5, 3, 3, 5, 3, 3, 5, 3, 3, 7, 3, 3, 5, 3, 3, 5, 3, 3, 5, 3, 3
OFFSET
1,1
COMMENTS
More than the usual number of terms are shown in order to distinguish this from A239278.
a(n) = smallest odd prime missing from rad(n).
If rad(m) = rad(n), a(m) = a(n) (cf. A007947). - Bob Selcoe, Apr 04 2017
LINKS
FORMULA
a(n) = 3 unless n == 0 (mod 3).
For n>3, a(n) < 3*log(n).
a(n) = A355001(2*n). - Antti Karttunen, Jul 18 2022
Asymptotic mean: Limit_{m->oo} (1/m) * Sum_{k=1..m} a(k) = Sum_{p odd prime} ((p*(p-1)/Product_{q odd prime <= p} q)) = 3.8401019546... . - Amiram Eldar, Jul 25 2022
MATHEMATICA
a[n_] := Module[{p = 3}, While[Divisible[n, p], p = NextPrime[p]]; p]; Array[a, 100] (* Amiram Eldar, Jul 25 2022 *)
PROG
(PARI) a(n) = my(p=3); while(gcd(n, p) != 1, p=nextprime(p+1)); p; \\ Michel Marcus, Apr 04 2017; corrected Jun 13 2022
CROSSREFS
Similar to but different from A239278.
Even bisection of A355001.
Sequence in context: A013606 A372041 A206550 * A190911 A204903 A054906
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Apr 04 2017
STATUS
approved