OFFSET
1,4
COMMENTS
EXAMPLE
n=50: d=2n=100, p=A020483(50)=3 because by definition, 3 is
the least prime so that p and p+100=103 are both primes;
a(50) here corresponds to the number of primes between
{p,p+100} = {3,103} not counting borders of interval;
thus a(50)=24, size of {5,7,...,97,101}.
MATHEMATICA
Table[fl=1; Do[s0=Prime[k]; s=2*n+Prime[k]; If[PrimeQ[s]&&Equal[fl, 1], Print[PrimePi[s]-k-1]; fl=0], {k, 1, 200}], {n, 1, 25}]
CROSSREFS
KEYWORD
nonn
AUTHOR
Labos Elemer, Aug 08 2003
STATUS
approved