A067756 Prime hypotenuses of Pythagorean triangles with a prime leg.
5, 13, 61, 181, 421, 1741, 1861, 2521, 3121, 5101, 8581, 9661, 16381, 19801, 36721, 60901, 71821, 83641, 100801, 106261, 135721, 161881, 163021, 199081, 205441, 218461, 273061, 282001, 337021, 388081, 431521, 491041, 531481, 539761, 552301
Offset: 1
Keywords
Examples
For a(1)=5, the right triangle is 3, 4, 5 with 3 and 5 prime. For a(10)=5101, the right triangle is 101, 5100, 5101 with 101 and 5101 prime.
Links
- Robert Israel, Table of n, a(n) for n = 1..10000 (first 184 terms from Andreas Boe)
- H. Dubner and T. Forbes, Prime Pythagorean triangles, J. Integer Seqs., Vol. 4 (2001), #01.2.3.
Crossrefs
Contains every value of A051859.
Programs
-
Maple
N:= 10^8: # to get all terms <= N Primes:= select(isprime,[$3..floor(sqrt(2*N-1))]): f:= proc(p) local q; q:= (p^2+1)/2; if isprime(q) then q else NULL fi end proc: map(f, Primes); # Robert Israel, Sep 16 2014
-
Mathematica
f[n_]:=((p-1)/2)^2+((p+1)/2)^2; lst={};Do[p=Prime[n];If[PrimeQ[f[p]],AppendTo[lst,f[p]]],{n,6!}];lst (* Vladimir Joseph Stephan Orlovsky, Jul 27 2009 *)
-
PARI
forprime(p=3,10^3,if(isprime(q=(p^2+1)/2),print1(q,", "))) \\ Derek Orr, Apr 30 2015
Comments