What are the necessary conditions for two of the terms in the Pythagorean triplet $a^2 = b^2 + c^2$ to be prime numbers?


There is a well-known parametrization of Phythagorean triples as $k(m^2 - n^2)$, $2kmn$ , $k(m^2 + n^2)$ with positive integers $k,m,n$ and $m$ greater $n$.

Now, if two are prime we get $k=1$. And also the middle term is never prime. So the question is when are $m^2 - n^2$ and $m^2 + n^2$ both prime. The former factors as $(m-n) (m+n)$. For this to be prime we need $m-n = 1$.

So we get two of three are prime if and only if $2n+1$ and $2n^2 + 2n + 1$ are prime for some positive integer $n$.

  • 5
    $\begingroup$ ...which, in turn, probably happens infinitely often, but this is unknown. $\endgroup$ – Cam McLeman Oct 5 '11 at 15:41
  • 2
    $\begingroup$ @Cam: thank for adding this information. A very general conjecture from which this would follow is Schinzel's Hypothesis H en.wikipedia.org/wiki/Schinzel's_hypothesis_H $\endgroup$ – user9072 Oct 5 '11 at 15:46
  • 4
    $\begingroup$ Also, letting $p=2n+1$ we find that $2n^2+2n+1=\frac{p^2+1}{2}$. So you're basically looking for odd primes $p$ such that $\frac{p^2+1}{2}$ is also prime. $\endgroup$ – Faisal Oct 5 '11 at 15:52
  • 14
    $\begingroup$ See oeis.org/A048161 $\endgroup$ – Barry Cipra Oct 5 '11 at 16:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.