OFFSET
1,2
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
EXAMPLE
p(2)=3, 3^4 = 81; for odd k and n > 1, p(n)^r + k is even and thus not prime, so we only need consider even k.
for k = 2: 81 + 2 = 83, which is prime, so 2 is the smallest number that can be added to 81 to make a new prime.
Hence a(2) = 2.
MATHEMATICA
NextPrime[#]-#&/@(Prime[Range[80]]^4) (* Harvey P. Dale, May 17 2015 *)
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Carl R. White, Sep 14 2007
STATUS
approved