OFFSET
1,2
LINKS
Antti Karttunen, Table of n, a(n) for n = 1..16384
FORMULA
EXAMPLE
phi(4) = 7 and the least prime > 7 is 11; hence a(4) = 11 - 7 = 4.
MATHEMATICA
ps[n_]:=Module[{sn=DivisorSigma[1, n]}, NextPrime[sn]-sn]; ps/@Range[100] (* Harvey P. Dale, Feb 02 2011 *)
PROG
(PARI) A072918(n) = (nextprime(1+sigma(n)) - sigma(n)); \\ Antti Karttunen, Nov 07 2017
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Joseph L. Pe, Aug 11 2002
STATUS
approved