login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A322748 Primes p such that q=p^2+p+1 is prime and (q^2+q+1)/3 is prime. 1

%I #14 Dec 26 2018 05:17:26

%S 2,3,5,41,71,383,827,1217,1931,2729,2969,3491,3671,4751,5039,6551,

%T 6791,6833,9323,9689,10223,11933,13163,14549,15413,15797,17393,17573,

%U 19991,22349,24533,25523,25943,28409,28517,30593,31277,31337,32507,34319,35747,38069,38603,38993,41177,42089,42839,44507

%N Primes p such that q=p^2+p+1 is prime and (q^2+q+1)/3 is prime.

%C Except for 2 and 3, all terms == 5 (mod 6). If p == 2 (mod 3), q == 1 (mod 3), and so q^2+q+1 is divisible by 3.

%H Robert Israel, <a href="/A322748/b322748.txt">Table of n, a(n) for n = 1..10000</a>

%e a(3)=41 is a term because 41^2+41+1=1723 is prime and (1723^2+1723+1)/3=990151 is prime.

%p filter:= proc(p) local r;

%p r:= p^2 + p + 1;

%p isprime(p) and isprime(r) and isprime((r^2+r+1)/3)

%p end proc:

%p select(filter, [2,3,seq(i,i=5..10^5,6)]); # _Robert Israel_, Dec 25 2018

%t f[n_] := n^2 + n + 1; Select[Range[45000], PrimeQ[#] && PrimeQ[f[#]] && PrimeQ[f[f[#]]/3] &] (* _Amiram Eldar_, Dec 25 2018 *)

%o (PARI) is(n) = isprime(n) && isprime(q=(n^3-1)/(n-1)) && isprime((q^3-1)/(3*q-3)) \\ _David A. Corneth_, Dec 25 2018

%Y Cf. A002061.

%K nonn

%O 1,1

%A _Robert Israel_, Dec 25 2018

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 26 21:53 EDT 2024. Contains 372004 sequences. (Running on oeis4.)