OFFSET
2,1
EXAMPLE
7+-4->primes, 31+-12->primes, 127+-24->primes, 8191+-30->primes, 131071+-30->primes, 524287+-66->primes..
MATHEMATICA
g[n_]:=2^Prime[n]-1; f[n_]:=Block[{k}, If[OddQ[n], k=2, k=1]; While[ !PrimeQ[n-k]||!PrimeQ[n+k], k+=2]; k]; lst={}; Do[If[PrimeQ[g[n]], AppendTo[lst, f[g[n]]]], {n, 2, 40}]; lst
CROSSREFS
KEYWORD
nonn
AUTHOR
Vladimir Joseph Stephan Orlovsky, May 09 2010
STATUS
approved