A318157 Primes that are one more or one less than the sum of four consecutive composite numbers.
101, 103, 107, 137, 139, 197, 199, 223, 227, 257, 307, 347, 367, 373, 379, 461, 463, 467, 479, 487, 491, 499, 569, 571, 577, 587, 613, 617, 619, 641, 643, 677, 683, 701, 733, 739, 743, 751, 809, 811, 821, 823, 827, 829, 853, 857, 859, 863, 877, 881, 883, 941
Offset: 1
Keywords
Examples
24 + 25 + 26 + 27 - 1 = 101; 24 + 25 + 26 + 27 + 1 = 103; 25 + 26 + 27 + 28 + 1 = 107. 26 + 27 + 28 + 29 - 1 = 109, but 29 is not composite, so 109 is not in the sequence.
Links
- Chai Wah Wu, Table of n, a(n) for n = 1..10000
Crossrefs
Cf. A296012.
Programs
-
Mathematica
tempList = Table[(Plus@@Range[n, n + 3]) * KroneckerDelta[PrimePi[n - 1], PrimePi[n + 3]], {n, 250}]; Union[Select[tempList - 1, PrimeQ], Select[tempList + 1, PrimeQ]] (* Alonso del Arte, Sep 02 2018 *)
-
Python
from sympy import isprime A318157_list = [] for n in range(2,10**6): if not (isprime(n) or isprime(n+1) or isprime(n+2) or isprime(n+3)): if isprime(4*n+5): A318157_list.append(4*n+5) if isprime(4*n+7): A318157_list.append(4*n+7) # Chai Wah Wu, Jan 02 2019
Extensions
a(16)-a(52) from Jon E. Schoenfield, Aug 19 2018