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!)
A084866 Primes that can be written in the form 2*p^2 + 3*q^2 with p and q prime. 5

%I #14 Dec 13 2021 08:04:32

%S 83,173,197,269,317,389,461,557,653,701,797,941,1091,1109,1181,1229,

%T 1637,1709,1949,1997,2069,2141,2309,2531,2549,2621,2789,2861,3221,

%U 3389,3461,3581,3821,4157,4229,4349,4493,5051,5261,5381,5501,5693

%N Primes that can be written in the form 2*p^2 + 3*q^2 with p and q prime.

%C Subsequence of A084864 and of A084865; A084863(a(n))>0.

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

%e A000040(40) = 173 = 98 + 75 = 2*7^2 + 3*5^2 = 2*A000040(4)^2 + 3*A000040(3)^2, therefore 173 is a term.

%p N:= 10^4: # to get terms <= N

%p P:= select(isprime, [2,seq(i,i=3..floor((N/2)^(1/2)))]):

%p m:= nops(P):

%p R:= {}:

%p for p in P do

%p for i from 2 to m while 3*P[i]^2 <= N - 2*p^2 do

%p v:= 2*p^2 + 3*P[i]^2;

%p if isprime(v) then R:= R union {v} fi

%p od od:

%p sort(convert(R,list)); # _Robert Israel_, Nov 05 2020

%t nn = 10^4; (* to get terms <= nn *)

%t P = Select[Join[{2}, Range[3, Floor[Sqrt[nn/2]]]], PrimeQ];

%t m = Length[P];

%t R = {};

%t Do[For[i = 2, 3*P[[i]]^2 <= nn - 2*p^2, i++,

%t v = 2*p^2 + 3*P[[i]]^2;

%t If[PrimeQ[v], R = R ~Union~ {v}]],

%t {p, P}];

%t Sort[R] (* _Jean-François Alcover_, Dec 13 2021, after _Robert Israel_ *)

%Y Cf. A084863, A084864, A084865.

%K nonn

%O 1,1

%A _Reinhard Zumkeller_, Jun 10 2003

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 19 19:02 EDT 2024. Contains 371798 sequences. (Running on oeis4.)