OFFSET
2,1
EXAMPLE
n=1: p(1)=2, 2p(1)=4 is between 3 and 5, their difference is 2=a(1); n=6: p(6)=13, 2p(6)=26 is between 23 and 29 and their difference is 6=a(6).
MAPLE
with(numtheory): [seq(nextprime(2*ithprime(j))-prevprime(2*ithprime(j)), j=2...256)];
MATHEMATICA
dsplp[n_]:=Module[{np=2Prime[n]}, NextPrime[np]-NextPrime[np, -1]]; Array[ dsplp, 90, 2] (* Harvey P. Dale, Mar 20 2013 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Labos Elemer, Mar 23 2001
STATUS
approved