login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Primes congruent to {1, 2} mod 7.
4

%I #14 Sep 08 2022 08:44:56

%S 2,23,29,37,43,71,79,107,113,127,149,163,191,197,211,233,239,281,317,

%T 331,337,359,373,379,401,421,443,449,457,463,491,499,541,547,569,617,

%U 631,653,659,673,701,709,743,751

%N Primes congruent to {1, 2} mod 7.

%H Vincenzo Librandi, <a href="/A045391/b045391.txt">Table of n, a(n) for n = 1..1000</a>

%t Select[Prime[Range[300]],MemberQ[{1,2},Mod[#,7]]&] (* _Vincenzo Librandi_, Aug 10 2012 *)

%t Select[Flatten[#+{1,2}&/@(7*Range[0,120])],PrimeQ] (* _Harvey P. Dale_, Sep 15 2019 *)

%o (Magma) [p: p in PrimesUpTo(1000) | p mod 7 in [1, 2]]; // _Vincenzo Librandi_, Aug 10 2012

%Y Cf. A000040, A045344, A045372.

%K nonn,easy

%O 1,1

%A _N. J. A. Sloane_