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

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A240709 Primes p such that no number among p+-6 and p+-12 is also a prime. 2

%I #13 Mar 28 2015 17:23:42

%S 2,3,523,617,691,701,709,719,743,787,911,937,967,1153,1171,1259,1381,

%T 1399,1409,1637,1667,1723,1787,1831,1847,1931,1933,1949,1951,2053,

%U 2113,2161,2179,2203,2221,2311,2437,2477,2503,2521,2593,2617,2749,2767,2819,2833

%N Primes p such that no number among p+-6 and p+-12 is also a prime.

%C The union of A240709 and A240710 is the set of all prime numbers, i.e., A000040.

%H Lei Zhou, <a href="/A240709/b240709.txt">Table of n, a(n) for n = 1..10000</a>

%e For 2, 2+-6 and 2+-12 are all even numbers and composite. So 2 is included.

%e For 3, 3+-6 and 3+-12 are all multiples of 3. So 3 is included.

%e For each prime number p between 5 and 521, at least one number among p+-6 and p+-12 is a prime number, thus p is excluded.

%e For 523, 523 - 12 = 511 = 7*73, 523 - 6 = 517 = 11*47, 523 + 6 = 529 = 23^2, 523 + 12 = 535 = 5*107. They are all composites. So 523 is included.

%t p = 1; Table[While[p = NextPrime[p]; ok = 0; a1 = p - 12; a2 = p - 6; a3 = p + 6; a4 = p + 12; If[a1 > 0, If[PrimeQ[a1], ok = 1]]; If[a2 > 0, If[PrimeQ[a2], ok = 1]]; If[PrimeQ[a3], ok = 1]; If[PrimeQ[a4], ok = 1]; ok != 0]; p, {n, 1, 46}]

%Y Cf. A000040, A240710.

%K nonn,easy

%O 1,1

%A _Lei Zhou_, Apr 10 2014

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | 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 April 19 16:38 EDT 2024. Contains 371794 sequences. (Running on oeis4.)