# Does any given integer only occur in one primitive Pythagorean triple?

I know that all integers are part of at least one primitive triple. But can this statement be refined to exactly one? From looking at some lists of triples it seems to be true, but I have no clue where I'd start in showing it.

Update: I'm not sure what the etiquette is regarding actually changing the question altogether... hopefully this is alright. I realised I'm actually interested only in whether any numbers act as the smallest number in more than primitive triplet.

• Are you asking whether there exists an integer that appears in only one primitive triple, or whether every integer appears in at most one primitive triple? Aug 23, 2016 at 17:36
• @carmichael561 The latter, edited for clarification
– clb
Aug 23, 2016 at 17:40
• @fleablood It did.
– clb
Aug 23, 2016 at 17:51
• All right I stand corrected. 5 is in 2 primitives and 1 and 2 are in none. Aug 23, 2016 at 18:02
• 5 occurs in 3,4,5 and in 5,12,13. Aug 23, 2016 at 18:33

Yes, a number can appear as the smallest value in two distinct primitive triples. For example, $(57, 176, 185)$ and $(57, 1624, 1625)$.

In fact, choose any two relatively prime positive integers $p$ and $q$ with $q+1 < p < q(1+\sqrt{2})$ and having opposite parity. Then $p^2-q^2 < 2pq$, and $(a,b,c)=(p^2-q^2, 2pq, p^2+q^2)$ is a primitive triple. Another primitive triple with $a$ as smallest element can be derived from the generators $r=\frac{a+1}{2}, s=\frac{a-1}{2}$: $$(r^2-s^2, 2rs, r^2+s^2) = \left(a,\frac{a^2-1}{2}, \frac{a^2+1}{2}\right).$$

• You might add that both of these triples are primitive. Aug 23, 2016 at 18:20

The example $(3,4,5)$ and $(5,12,13)$ shows that some positive integers can appear in more than one primitive triple.

• D'oh, I managed to miss the most obvious one! Although as a probably more difficult follow up - is there a number that acts as $a$ (i.e. the smallest) in more than one primitive triplet? As opposed to being $a$ in one and $c$ in another. I now realise that's what I'm actually interested in anyway, I just didn't know it at the time of asking the question.
– clb
Aug 23, 2016 at 17:57
• $a^2 =(c-b)(c+b)$ Any $a$ so expressible can be in two triples. Example $15^2=2k+1$ so $15^2=(k+1 -k)(k +1 +k)$ and $(17-8)(17+8)$. I think $a$ has to be odd and composite and that's sufficient. Aug 23, 2016 at 18:59

There are integers that are in more than one primitive triple. For example $5$ occurs in $(3,4,5)$ and $(5,12,13)$. The number $65$ occurs in $(33,56,65)$, $(65,72,97)$ and $(63,16,65)$.

Any factorization of the even term into $2rs$ with $r,s$ relatively prime gives a triple with that term in it. For example, take $rs = 2\cdot3\cdot5$ and we get two triples

$$(6^2 - 5^2, 60, 6^2 + 5^2) = (11, 60, 61)$$ $$(10^2 - 3^2, 60, 10^2 + 3^2) = (91, 60, 109)$$ $$(15^2 - 2^2, 60, 15^2 + 2^2) = (221, 60, 229)$$

More generally, if we take $rs = 2\cdot3\cdot n$ where $\gcd(n,6) = 1$ and $n \neq 1$. Then, two triples where the even term appears as the smallest will be

$$(12n, 4n^2 - 9, 4n^2 + 9) \qquad (12n, 9n^2 - 4, 9n^2 + 4)$$

Let $1<n\equiv 1 \pmod 4$ such that $n=a^2b$ where any prime divisor (if any) of $a$ is $\equiv 3\pmod 4,$ and every prime divisor of $b$ is $\equiv 1 \pmod 4 ,$ and $b>1.$ Then $n=c^2+d^2$ for some co-prime $c,d\in N,$ with $c,d$ not both odd.

But since $n=2m+1$ with $m\in N$ we have $n=(m+1)^2-m^2,$ and $\gcd (m,m+1)=1.$

So $n$ appears as one of the 2 smaller members in $((m+1)^2-m^2, 2m(m+1), (m+1)^2+m^2)$ and as the largest member in $(|c^2-d^2|,2cd,c^2+d^2).$ For Examples: $n=5, c=2,d=1,m=2.$ And $n=13, c=3,d=2,m=6.$

Side $$A$$ will be the smallest whenever $$m,n$$ are very close together for Euclid's formula where $$A=m^2-n^2\quad B=2mn\quad C=m^2+n^2$$ We can find triples for any side $$A\ge3$$ by solving the A-function for $$n$$ and doing a defined finite search for values of $$A,m$$ that yield an integer.

$$A=m^2-n^2\implies n=\sqrt{m^2-A}\qquad where \qquad \lceil\sqrt{A+1}\space\rceil \le m \le \biggl\lceil\frac{A}{2}\biggr\rceil$$ The lower limit ensures $$m^2>A$$ and the upper limit ensures $$m-n\ge 1$$. Examples:

$$A=3\implies 2\le m \le 2\qquad n=f(3,2)=1\qquad F(2,1)=(3,4,5)$$ $$A=5\implies 2\le m \le 3\qquad n=f(5,3)=2\qquad F(3,2)=(5,12,13)$$ $$A=7\implies 2\le m \le 4\qquad n=f(7,4)=3\qquad F(4,3)=(7,24,25)$$ $$A=9\implies 3\le m \le 5\qquad n=f(9,5)=4\qquad F(5,4)=(9,40,41)$$ $$A=11\implies 3\le m \le 6\qquad n=f(11,6)=5\qquad F(6,5)=(11,60,61)$$

Sometimes there is more than one triple but $$A$$ is not always the smallest. $$A=105\implies 10\le m \le 53\qquad$$

$$n=f(105,11)=4\qquad F(11,4)=(105,88,137)$$ $$n=f(105,13)=8\qquad F(13,8)=(105,208,233)$$ $$n=f(105,19)=16\qquad F(19,16)=(105,608,617)$$ $$n=f(105,53)=52\qquad F(53,52)=(105,5512,5513)$$