login
Primes p such that 5+38*p^2 is also prime.
4

%I #17 Sep 08 2022 08:45:50

%S 2,3,7,11,13,17,19,23,29,31,37,53,59,61,71,79,83,137,139,149,151,157,

%T 163,167,181,191,193,199,211,223,227,229,239,269,281,283,307,311,313,

%U 317,347,353,359,367,379,383,389,401,419,491,509,521,523,541,557

%N Primes p such that 5+38*p^2 is also prime.

%H Bruno Berselli, <a href="/A173555/b173555.txt">Table of n, a(n) for n = 1..1000</a>

%t Select[Prime[Range[200]],PrimeQ[5+38#^2]&] (* _Harvey P. Dale_, Jul 24 2011 *)

%o (Magma) [p: p in PrimesUpTo(1000) | IsPrime(5+38*p^2)]; // _Vincenzo Librandi_, Sep 13 2015

%o (PARI) lista(nn) = forprime(p=2, nn, if (isprime(5+38*p^2), print1(p, ", "))); \\ _Michel Marcus_, Sep 13 2015

%Y Subsequence of A173552.

%Y Cf. A173553, A173554.

%K nonn,easy

%O 1,1

%A _Vincenzo Librandi_, Feb 21 2010

%E Edited, corrected and extended by _Alonso del Arte_ and _N. J. A. Sloane_, Jun 18 2010