login
Primes p such that p^2+p-1 is prime.
26

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

%S 2,3,5,11,13,19,31,41,53,59,83,89,101,103,131,149,163,181,191,193,199,

%T 233,241,263,281,331,349,373,401,419,431,433,449,461,463,499,541,569,

%U 571,659,673,683,691,709,739,743,761,769,809,863,881,941,1013,1039

%N Primes p such that p^2+p-1 is prime.

%H Pierre CAMI, <a href="/A053184/b053184.txt">Table of n, a(n) for n = 1..10000</a>

%t Select[Prime[Range[175]], PrimeQ[#^2+#-1]&] (* _Bruno Berselli_, Nov 08 2011 *)

%o (PARI) isA053184(n)=isprime(n) && isprime(n^2+n-1) \\ _Michael B. Porter_, May 10 2010

%o (Magma) [p: p in PrimesUpTo(1050) | IsPrime(p^2+p-1)]; // _Bruno Berselli_, Nov 08 2011

%Y Cf. A053182, A065508, A091567.

%K nonn,easy

%O 1,1

%A _Enoch Haga_, Mar 01 2000