OFFSET
2,1
LINKS
Harry J. Smith, Table of n, a(n) for n = 2..1000
EXAMPLE
a(18) = 18/2 + 2 - 1 = 10;
a(19) = 19/19 + 19 - 1 = 19.
MATHEMATICA
a[n_] := (g = FactorInteger[n][[-1, 1]]; n/g + g - 1); a /@ Range[2, 76] (* Jean-François Alcover, Apr 06 2011 *)
PROG
(PARI) gpf(n)= { local(f); f=factor(n)~; return(f[1, length(f)]) } { for (n=2, 1000, g=gpf(n); a=n / g + g - 1; write("b064920.txt", n, " ", a) ) } \\ Harry J. Smith, Sep 29 2009
(PARI) a(n) = my(p = vecmax(factor(n)[, 1])); n/p + p - 1; \\ Michel Marcus, Jun 19 2018
CROSSREFS
KEYWORD
nice,nonn
AUTHOR
Reinhard Zumkeller, Oct 14 2001
STATUS
approved