A323138 Multiples of 6 that are not the sum of two consecutive primes.
6, 48, 54, 66, 72, 96, 102, 108, 114, 126, 132, 150, 156, 168, 174, 180, 192, 228, 234, 246, 252, 264, 270, 282, 294, 306, 312, 318, 324, 336, 342, 348, 354, 366, 378, 402, 408, 414, 420, 426, 432, 438, 444, 468, 474, 486, 498, 504, 510, 516, 522, 528, 534, 546, 552, 570, 582
Offset: 1
Keywords
Examples
6 belongs to the sequence because there are no two consecutive primes adding up to 6. 12 is not in the sequence because 12 = 5 + 7.
Programs
-
Mathematica
Complement[6 Range[Last[#]/6], #] &@ Select[Total /@ Partition[Prime@ Range@ 63, 2, 1], Mod[#, 6] == 0 &] (* Michael De Vlieger, Jan 07 2019 *)
-
PARI
isok(n) = !(n % 6) && (precprime((n-1)/2) + nextprime(n/2) != n); \\ Michel Marcus, Jan 05 2019
Comments