login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 


A167915
Primes which are the sums of two consecutive nonprimes (A141468).
3
5, 17, 19, 29, 31, 41, 43, 53, 67, 71, 79, 89, 97, 101, 103, 109, 113, 127, 131, 137, 139, 149, 151, 163, 173, 181, 191, 197, 199, 211, 223, 229, 233, 239, 241, 251, 257, 269, 271, 281, 283, 293, 307, 311, 317, 331, 337, 349, 353, 367, 373, 379, 389, 401, 409
OFFSET
1,1
COMMENTS
Five together with primes that are the sum of two consecutive composite numbers.
LINKS
FORMULA
a(n+1) = A060254(n) = A176902(n+1). - Juri-Stepan Gerasimov, Apr 28 2010
EXAMPLE
a(1)=1+4=5, a(2)=8+9=17.
MATHEMATICA
2*Select[Range[300], !PrimeQ[#] == !PrimeQ[#+1] && PrimeQ[2*#+1] &] + 1 (* G. C. Greubel, Jul 01 2016; Nov 10 2023 *)
PROG
(Magma) [2*n+1: n in [1..300] | (not IsPrime(n) eq not IsPrime(n+1)) and IsPrime(2*n+1)]; // G. C. Greubel, Nov 10 2023
(SageMath) [2*n+1 for n in (1..300) if (not is_prime(n)) - (not is_prime(n+1)) == 0 and is_prime(2*n+1)] # G. C. Greubel, Nov 10 2023
CROSSREFS
KEYWORD
nonn
AUTHOR
EXTENSIONS
Typo corrected and terms checked by D. S. McNeil, Nov 17 2010
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 21 08:46 EDT 2024. Contains 376084 sequences. (Running on oeis4.)