[go: up one dir, main page]

login
A083714
(greatest prime <= n) - (greatest prime factor of n).
4
0, 0, 0, 1, 0, 2, 0, 5, 4, 2, 0, 8, 0, 6, 8, 11, 0, 14, 0, 14, 12, 8, 0, 20, 18, 10, 20, 16, 0, 24, 0, 29, 20, 14, 24, 28, 0, 18, 24, 32, 0, 34, 0, 32, 38, 20, 0, 44, 40, 42, 30, 34, 0, 50, 42, 46, 34, 24, 0, 54, 0, 30, 54, 59, 48, 50, 0, 50, 44, 60, 0, 68, 0, 36, 68, 54, 62, 60, 0, 74
OFFSET
1,6
COMMENTS
a(n) = A007917(n) - A006530(n);
n>1: a(n) = 0 iff n is prime.
MATHEMATICA
Join[{0}, Table[NextPrime[n+1, -1]-FactorInteger[n][[-1, 1]], {n, 2, 90}]] (* Harvey P. Dale, Nov 27 2011 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, May 04 2003
STATUS
approved