|
|
A052126
|
|
a(1) = 1; for n>1, a(n)=n/(largest prime dividing n).
|
|
118
|
|
|
1, 1, 1, 2, 1, 2, 1, 4, 3, 2, 1, 4, 1, 2, 3, 8, 1, 6, 1, 4, 3, 2, 1, 8, 5, 2, 9, 4, 1, 6, 1, 16, 3, 2, 5, 12, 1, 2, 3, 8, 1, 6, 1, 4, 9, 2, 1, 16, 7, 10, 3, 4, 1, 18, 5, 8, 3, 2, 1, 12, 1, 2, 9, 32, 5, 6, 1, 4, 3, 10, 1, 24, 1, 2, 15, 4, 7, 6, 1, 16, 27, 2, 1, 12, 5, 2, 3, 8, 1, 18, 7, 4, 3, 2, 5, 32, 1
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,4
|
|
COMMENTS
|
For n>1, a(n)=1 if and only if n is prime. - Zak Seidov, Feb 09 2015
For n > 1, a(n) is the smallest divisor of n such that n/a(n) is prime. - David James Sycamore, Jan 03 2024
|
|
LINKS
|
|
|
FORMULA
|
|
|
EXAMPLE
|
a(15) = 15/(largest prime dividing 15) = 15/5 = 3.
|
|
MAPLE
|
a := n -> `if`(n=1, 1, n/max(numtheory[factorset](n)));
|
|
MATHEMATICA
|
a052126[n_] := Array[If[n == 1, 1, #/FactorInteger[#][[-1]][[1]]] &, n]; a052126[97] (* Michael De Vlieger, Dec 21 2014 *)
|
|
PROG
|
(PARI) gpf(n)=my(f=factor(n)[, 1]); f[#f]
|
|
CROSSREFS
|
|
|
KEYWORD
|
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|