A242562
Primes p such that 1000p+1, 1000p+3, 1000p+7 and 1000p+9 are prime.
Original entry on oeis.org
13, 1447, 5527, 28201, 36217, 75079, 81157, 95911, 187423, 188677, 202327, 210643, 248077, 263323, 282589, 283267, 423043, 466897, 472597, 478189, 478603, 631273, 640261, 695749, 730111, 736279, 806929, 808021, 917641, 964303, 1018177, 1026547, 1064263, 1108489, 1150861
Offset: 1
130001, 130003, 130007 and 130009 are all prime. Thus 13 is a member of this sequence.
-
for(n=1,10^5,s=prime(n);if(ispseudoprime(1000*s+1) && ispseudoprime(1000*s+3) && ispseudoprime(1000*s+7) && ispseudoprime(1000*s+9),print(s)));
-
import sympy
from sympy import isprime
from sympy import prime
{print(prime(n)) for n in range(1,10**5) if isprime(1000*prime(n)+1) and isprime(1000*prime(n)+3) and isprime(1000*prime(n)+7) and isprime(1000*prime(n)+9)}
A242564
Least prime p such that p*10^n+1, p*10^n+3, p*10^n+7 and p*10^n+9 are all prime.
Original entry on oeis.org
19, 1657, 13, 9001, 283, 115201, 61507, 249439, 375127, 472831, 786823, 172489, 1237, 2359033, 163063, 961981, 1442017, 457, 1208833, 4845583, 1146877, 11550193, 436831, 1911031, 581047, 4504351, 215737, 3685051, 27805381, 1343791, 82491967, 15696349, 20446423
Offset: 1
2*10^3+1 (2001), 2*10^3+3 (2003), 2*10^3+7 (2007) and 2*10^3+9 (2009) are not all prime.
3*10^3+1 (3001), 3*10^3+3 (3003), 3*10^3+7 (3007) and 3*10^3+9 (3009) are not all prime.
5*10^3+1 (5001), 5*10^3+3 (5003), 5*10^3+7 (5007) and 5*10^3+9 (5009) are not all prime.
7*10^3+1 (7001), 7*10^3+3 (7003), 7*10^3+7 (7007) and 7*10^3+9 (7009) are not all prime.
11*10^3+1 (11001), 11*10^3+3 (11003), 11*10^3+7 (11007) and 11*10^3+9 (11009) are not all prime.
13*10^3+1 (13001), 13*10^3+3 (13003), 13*10^3+7 (13007) and 13*10^3+9 (13009) are all prime. Thus, a(3) = 13.
-
lpp[n_]:=Module[{c=10^n,p=2},While[Not[AllTrue[p*c+{1,3,7,9},PrimeQ]], p= NextPrime[ p]];p]; Array[lpp,40] (* Harvey P. Dale, Mar 24 2018 *)
-
import sympy
from sympy import isprime
from sympy import prime
def Pr(n):
for p in range(1,10**7):
if isprime(prime(p)*(10**n)+1) and isprime(prime(p)*(10**n)+3) and isprime(prime(p)*(10**n)+7) and isprime(prime(p)*(10**n)+9):
return prime(p)
n = 1
while n < 50:
print(Pr(n))
n += 1
A243409
Primes p such that 100p-1, 100p-3, 100p-7, and 100p-9 are all prime.
Original entry on oeis.org
2, 797, 1193, 6803, 15773, 28793, 35507, 41579, 53189, 53279, 57347, 60161, 70457, 77549, 81839, 140549, 143387, 150779, 151241, 164447, 170627, 201011, 255083, 285287, 293831, 300317, 316073, 336671, 343661, 449921, 470087, 486947, 488603, 518801, 556289, 569243, 602087
Offset: 1
2 is prime, 100*2-1 = 199 is prime, 100*2-3 = 197 is prime, 100*2-7 = 193 is prime, and 100*2-9 = 191 is prime. Thus 2 is a member of this sequence.
-
Select[Prime[Range[50000]],PrimeQ[100# -1]&&PrimeQ[100# -3]&&PrimeQ[100# -7] &&PrimeQ[100# -9] &] (* K. D. Bajpai, Jun 13 2014 *)
Select[Prime[Range[50000]],AllTrue[100#-{1,3,7,9},PrimeQ]&] (* The program uses the AllTrue function from Mathematica version 10 *) (* Harvey P. Dale, Feb 06 2019 *)
-
for(n=1,10^5,if(ispseudoprime(100*prime(n)-1)&& ispseudoprime(100*prime(n)-3)&& ispseudoprime(100*prime(n)-7)&& ispseudoprime(100*prime(n)-9),print1(prime(n),", ")))
-
import sympy
from sympy import isprime
from sympy import prime
{print(prime(n),end=', ') for n in range(1,10**5) if isprime(100*prime(n)-1) and isprime(100*prime(n)-3) and isprime(100*prime(n)-7) and isprime(100*prime(n)-9)}
Showing 1-3 of 3 results.