login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A060327
Primes the sum of both two and three consecutive composite numbers.
3
31, 41, 67, 71, 109, 113, 131, 139, 199, 211, 239, 251, 269, 293, 311, 337, 379, 409, 419, 487, 491, 499, 521, 571, 599, 631, 701, 751, 769, 773, 787, 829, 881, 919, 941, 953, 991, 1009, 1013, 1039, 1049, 1061, 1103, 1117, 1151, 1193, 1229, 1291, 1301
OFFSET
1,1
LINKS
EXAMPLE
a(2) = 41 which is equal to 20+21 and 12+14+15.
MATHEMATICA
composite[ n_Integer ] := (k = n + PrimePi[ n ] + 1; While[ k - PrimePi[ k ] - 1 != n, k++ ]; k); a = {}; Do[ p = composite[ n ] + composite[ n + 1 ]; If[ PrimeQ[ p ], a = Append[ a, p ] ], {n, 1, 1000} ]; b = {}; Do[ p = composite[ n ] + composite[ n + 1 ] + composite[ n + 2 ]; If[ PrimeQ[ p ], b = Append[ b, p ] ], {n, 1, 1000} ]; Intersection[ a, b ]
Module[{cmps=Select[Range[700], CompositeQ], c2, c3}, c2=Total/@Partition[cmps, 2, 1]; c3=Total/@Partition[cmps, 3, 1]; Select[Intersection[c2, c3], PrimeQ]] (* Harvey P. Dale, Nov 12 2022 *)
CROSSREFS
Sequence in context: A089721 A089442 A243704 * A202286 A285805 A141180
KEYWORD
nonn
AUTHOR
Robert G. Wilson v, Mar 30 2001
STATUS
approved