A198696 Positions of local maxima in differences of primes, A001223.
4, 6, 9, 11, 18, 21, 24, 27, 30, 32, 34, 42, 44, 51, 53, 58, 62, 66, 68, 72, 77, 80, 82, 84, 87, 91, 94, 97, 99, 101, 106, 114, 121, 125, 127, 132, 135, 137, 139, 141, 143, 146, 150, 154, 157, 162, 166, 168, 170, 172, 175, 177, 180, 186, 189, 191, 193, 197
Offset: 1
Keywords
Programs
-
Mathematica
nn = 1001; t = Differences[Prime[Range[nn]]]; t2 = {}; Do[If[t[[n - 1]] < t[[n]] && t[[n]] > t[[n + 1]], AppendTo[t2, {n, t[[n]]}]], {n, 2, nn - 2}]; Transpose[t2][[1]] (* T. D. Noe, Dec 27 2011 *)
Comments