login
A216145
Primes p such that p (mod 5) = p (mod 7).
3
2, 3, 37, 71, 73, 107, 109, 179, 211, 281, 283, 317, 353, 389, 421, 457, 491, 563, 599, 631, 701, 739, 773, 809, 877, 911, 947, 983, 1019, 1051, 1087, 1123, 1193, 1229, 1297, 1367, 1439, 1471, 1543, 1579, 1613, 1753, 1787, 1789, 1823, 1997, 1999, 2069, 2137
OFFSET
1,1
COMMENTS
Or primes p such that p (mod 35) = {1, 2, 3, 4}.
In general if 0 < m (mod p) = m (mod q) then m (mod p*q) < p (with p < q any primes).
LINKS
EXAMPLE
37 = 2 (mod 5) = 2 (mod 7);
71 = 1 (mod 5) = 1 (mod 7);
73 = 3 (mod 5) = 3 (mod 7);
109 = 4 (mod 5) = 4 (mod 7).
MAPLE
select(isprime, [seq(seq(35*i+j, j=1..4), i=0..1000)]); # Robert Israel, Jan 18 2016
MATHEMATICA
Select[Prime[Range[100]], Mod[#, 5]==Mod[#, 7]&]
Select[Prime[Range[100]], Mod[#, 35]<5&]
PROG
(Magma) [p: p in PrimesUpTo(2500) | p mod 5 eq p mod 7]; // Vincenzo Librandi, Jan 17 2016
(PARI) isok(n) = isprime(n) && ((n % 5) == (n % 7)); \\ Michel Marcus, Jan 17 2016
(PARI) lista(nn) = forprime(p=2, nn, if(p%5 == p%7, print1(p, ", "))); \\ Altug Alkan, Jan 18 2016
CROSSREFS
Sequence in context: A340845 A266758 A280539 * A109748 A062459 A258455
KEYWORD
nonn,easy
AUTHOR
Zak Seidov, Sep 02 2012
STATUS
approved