# Why we can't find a lot more general pattern between pythagorean triples?

Although there are patterns between primitive Pythagorean triples but why we can't find any pattern between all of them(i.e. all existing Pythagorean triplets)or why there is not a very generalisation of this concept?Why it's random? Any specific reason?

• The primitive pythagorean triples are perfectly classified. There is no "randomness". What do you mean with "pattern" ? This is a very vague word. Commented Oct 9, 2020 at 10:19
• @Peter: I think he's referring to pythagorean triples $(a,b,c)$ where $a,b,c$ aren't necessarily pairwise coprime. If $\gcd(a,b,c)=d$ and they have no other pairwise common factors, then we can simply reduce it to a primitive one, namely $(a/d,b/d,c/d)$; but what about triples such that $\gcd(a,b)\neq\gcd(a,c)\neq\gcd(b,c)$? Commented Oct 9, 2020 at 10:24
• I didn't asked anything about primitive Pythagorean triples my point was on the context of random triples which guys generally don't follow any specific pattern although the context is so pattern full so it's hard to believe isn't? So in my ignorance I asked if there exist any kind of generalisation further beyond the primitives and some other. Commented Oct 9, 2020 at 22:02

There is definitely a classified pattern to all Pythagorean triples. However, the primitive triples are the exciting ones to classify.

Once we have established a classification of all the primitive Pythagorean triples (which is a cool result), the classification of all Pythagorean triples follows automatically and almost trivially. We simply multiply each primitive triple by all possible natural numbers to get all possible triples. Thus authors rarely even bother to mention this broader classification.

Note that for a Pythagorean triple $$(a, b, c)$$, $$\gcd(a, b, c) = 1$$ is equivalent to $$a, b, c$$ being pairwise coprime (and, more generally, $$\gcd(a, b, c) = d$$ is equivalent to $$\gcd(a, b) = \gcd(b, c) = \gcd(a, c) = d$$). This is because their defining relationship $$a^2+b^2=c^2$$ forces any factor shared by two of the numbers to also be shared by the third.

• Can there be a triple $(a,b,c)$ such that $\gcd(a,b,c)=d$ but $a/d,b/d,c/d$ are not necessarily pairwise coprime? Commented Oct 9, 2020 at 10:26
• @PrasunBiswas By the Pythagorean theorem and Euclid's lemma, if two of the entries in a triple have a prime factor in common, the third one has that prime factor too. Thus if $(a, b, c)$ is a Pythagorean triple with $\gcd(a, b, c) = 1$, they must be pairwise coprime. Similarily, if $\gcd(a, b, c) = d$, we get $\gcd(a/d, b/d, c/d) = 1$, and $(a/d, b/d, c/d)$ is still a Pythagorean triple, so they must be pairwise coprime. Commented Oct 9, 2020 at 10:34
• Oh right! Now that I see it, I feel stupid for asking that. I think your comment is really the answer OP is looking for. You should add it to your answer. +1 Commented Oct 9, 2020 at 10:43
• @PrasunBiswas Maybe you're right about that. I added a paragraph about it. Commented Oct 9, 2020 at 10:57

Perhaps you are wondering if there is a pattern in their generation? Euclid's formula here shown as $$F(m,k)$$ $$\quad A=m^2-k^2,\quad B=2mk,\quad C=m^2+k^2\quad$$ generates primitives triangles if $$(m,k)$$ are mutually prime and of opposite parity. All triples may be generated by multiplying each term by a constant but those are not "interesting" because who cares about $$(6,8,10), (9,12,15), etc?$$ one problem with Euclid's formula is that it generates trivial triples such as $$(0,2,2)$$ if $$m=k$$ and non-primitives if$$(m,n)$$ are the same parity, i.e. both odd or both even. Viewing the results of this formula "can" give one the impression that there are no "simple" patterns in Pythagorean triples.

I developed a formula $$G(n,k)$$ that generates only the subset where $$GCD(A,B,C)=(2x-1)^2, x\in\mathbb{N}$$.

$$$$A=(2n-1)^2+2(2n-1)k\qquad B=2(2n-1)k+2k^2\qquad C=(2n-1)^2+2(2n-1)k+2k^2$$$$ This formula makes some patterns easier to "see" (as seen in this sample table). $$\begin{array}{c|c|c|c|c|c|c|} n & k=1 & k=2 & k=3 & k=4 & k=5 & k=6 \\ \hline Set_1 & 3,4,5 & 5,12,13& 7,24,25& 9,40,41& 11,60,61 & 13,84,85 \\ \hline Set_2 & 15,8,17 & 21,20,29 &27,36,45 &33,56,65 & 39,80,89 & 45,108,117 \\ \hline Set_3 & 35,12,37 & 45,28,53 &55,48,73 &65,72,97 & 75,100,125 & 85,132,157 \\ \hline Set_{4} &63,16,65 &77,36,85 &91,60,109 &105,88,137 &119,120,169 & 133,156,205 \\ \hline Set_{5} &99,20,101 &117,44,125 &135,72,153 &153,104,185 &171,140,221 & 189,180,261 \\ \hline \end{array}$$

Note that the difference between $$A$$-values in any set is always the same $$A_x+2(2n-1)=A_{x+1}$$. Note that only $$Set_1$$ or when $$k=1$$ are all triples primitive and only in $$Set_1$$ can both $$A$$ and $$C$$ be prime.

Note that $$(C-B)=(2n-1)^2$$ for all triples generated.

Note that $$C-A=2k^2$$ for all members of any column.

Note how (for primitives) $$|B=A|= X$$ where $$X$$ is a prime number $$p$$ raised to any non-negative power $$n$$ and $$p\equiv \pm 1 \mod 8$$. Under $$100$$, $$X\in \{1,7, 17, 23, 31, 41, 47, 49, 71, 73, 79, 89, 97\}$$

Note how $$G(n,k)=F(2m-1+k,k)$$ if you separately compare the formulas' triples generated.

Of course there are many more relationships to be found here and here and elsewhere. The two formulas shown appear to be the most useful in "finding triples" but that is another topic altogether.