OFFSET
1,1
COMMENTS
Primes of the form x^2 + y^2, where x > y > 0, such that x-y = p and x+y = q are primes. Proof: (p^2+q^2)/2 = ((x-y)^2+(x+y)^2)/2 = x^2+y^2 so we have x = (p+q)/2 and y = (q-p)/2. - Thomas Ordowski, Sep 24 2012
All terms == 1 or 5 (mod 12). - Thomas Ordowski, Jun 28 2013
Or, primes in A143850. - Zak Seidov, Jun 06 2015
LINKS
T. D. Noe, Table of n, a(n) for n = 1..1000
EXAMPLE
17 is in the sequence because (3^2 + 5^2) / 2 = 17.
MAPLE
Primes:= select(isprime, [seq(2*i+1, i=1..400)]):
Psq:= map(`^`, Primes, 2):
M:= max(Psq):
S:= select(t -> t <= M/2 and isprime(t), {seq(seq((Psq[i]+Psq[j])/2, j=1..i-1), i=1..nops(Psq))}):
sort(convert(S, list)); # Robert Israel, Jun 08 2015
PROG
(PARI) list(lim)=my(v=List(), p2, t); lim\=1; if(lim<9, lim=9); forprime(p=3, sqrtint(2*lim-9), p2=p^2; forprime(q=3, min(sqrtint(2*lim-p2), p), if(isprime(t=(p2+q^2)/2), listput(v, t)))); Set(v) \\ Charles R Greathouse IV, Feb 14 2017
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Giovanni Teofilatto, Mar 28 2005
EXTENSIONS
Corrected and extended by Walter Nissen, Jul 19 2005
STATUS
approved