OFFSET
1,1
LINKS
Amiram Eldar, Table of n, a(n) for n = 1..10000
FORMULA
If n is prime a(n) = n+1.
Sum_{k=1..n} a(k) seems to be asymptotic to c*n^2 with c=0.35... [c = A065463/2 = 0.352221100499... . - Amiram Eldar, Feb 01 2024]
a(n) = SquareFreeKernel(n) + 1 = A007947(n) + 1. - Reinhard Zumkeller, Aug 10 2004
MATHEMATICA
a[n_] := 1 + Times @@ FactorInteger[n][[;; , 1]]; Array[a, 100] (* Amiram Eldar, Feb 01 2024 *)
PROG
(PARI) a(n)=if(n<0, 0, x=2; while(sumdiv(n, d, (x^d-1)%d)>0, x++); x)
(PARI) a(n) = 1 + vecprod(factor(n)[, 1]); \\ Amiram Eldar, Feb 01 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
Benoit Cloitre, Oct 22 2002
STATUS
approved