A071087 w values for A071352.
1, 3, 7, 13, 77, 182, 1100, 1821, 9230
Offset: 1
Examples
2^7 = 128 is the sum of two consecutive primes (61,67), therefore 7 is a member of the sequence.
Links
- Carlos B. Rivera F., Puzzle 223.
Programs
-
Mathematica
PrevPrim[n_] := Block[{k = n - 1}, While[ !PrimeQ[k], k-- ]; k]; NextPrim[n_] := Block[{k = n + 1}, While[ !PrimeQ[k], k++ ]; k]; Do[ p = PrevPrim[2^n]; q = NextPrim[2^n]; If[p + q == 2^(n + 1), Print[n+1]], {n, 2, 9230}] (* Robert G. Wilson v, Jan 24 2004 *)
Extensions
More terms from Carlos Rivera, Jun 07 2003
9230 from Jens Kruse Andersen, Jun 14 2003
Comments