On this page
If you are designing a building, laying out a sports pitch, or solving a coordinate geometry exam question, you often need to know if a corner is exactly 90 degrees. Pythagorean triplets provide an easy, reliable way to check this without measuring angles. A Pythagorean triplet is a set of three whole numbers—like 3, 4, and 5—that perfectly satisfy the Pythagorean theorem.
You can find as many of these numbers as you like without trial and error. Over the centuries, mathematicians have found several formulas to generate them. The most famous early method, the Platonic sequence, lets you generate triplets using a simple mathematical rule based on an even starting point.
How do you generate Pythagorean triplets?
For any integer m > 1, you can generate a Pythagorean triplet using three expressions: 2m, m² − 1, and m² + 1.
In this formula, 2m and m² − 1 are the lengths of the two shorter legs, and m² + 1 is always the length of the hypotenuse. Historically known as the Platonic sequence (attributed to the Greek philosopher Plato, c. 380 BC), this method always produces a right-angled triangle.
Let us see how it works for m = 4:
First leg: 2(4) = 8
Second leg: 4² − 1 = 15
Hypotenuse: 4² + 1 = 17
This gives the triplet 8, 15, and 17. Because 8² + 15² = 17² (64 + 225 = 289), we know for sure these numbers form a right-angled triangle.
If you have concept gaps on the underlying algebra, the Fermi Concept Library has a lesson on every concept in mathematics.
What is the rule for odd numbers?
Long before Plato, Pythagoras himself (c. 540 BC) came up with a different rule that starts with an odd number. For any odd integer a > 1, you can find the other two sides using a simple pattern.
If the shortest leg is a, the other leg is (a² − 1) / 2, and the hypotenuse is (a² + 1) / 2.
For example, if you start with a = 3:
First leg: 3
Second leg: (3² − 1) / 2 = 4
Hypotenuse: (3² + 1) / 2 = 5
This rule always produces a triangle where the hypotenuse is exactly 1 unit longer than the second leg. While it works perfectly, it only generates a specific subset of Pythagorean triplets.
How does Euclid's formula find all primitive triplets?
To find every possible unique right-angled triangle, you need a more powerful tool. Euclid's formula, which appears in his famous work Elements, is the definitive way to generate all primitive Pythagorean triplets. A primitive triplet is one where the three numbers share no common factors other than 1 (like 3, 4, 5, whereas 6, 8, 10 is not primitive).
Euclid's formula uses two positive integers, m and n, where m > n > 0. The three sides are generated by:
First leg: m² − n²
Second leg: 2mn
Hypotenuse: m² + n²
To guarantee the triplet is primitive, m and n must share no common factors, and exactly one of them must be even.
For instance, if m = 2 and n = 1:
First leg: 2² − 1² = 3
Second leg: 2(2)(1) = 4
Hypotenuse: 2² + 1² = 5
This method is incredibly useful in higher mathematics and programming challenges.
How do you spot multiples of a 3-4-5 triangle?
The most famous Pythagorean triplet is 3, 4, and 5. What many students miss is that any multiple of a Pythagorean triplet is also a Pythagorean triplet.
If you multiply 3, 4, and 5 by 2, you get 6, 8, and 10. By 3, you get 9, 12, and 15. If a word problem gives you a right-angled triangle with a hypotenuse of 50 and a leg of 40, you do not need to use the a² + b² = c² formula to find the missing side. By spotting that 40 and 50 are 10 × 4 and 10 × 5, you can immediately see the missing side is 10 × 3, which is 30.
Understanding how triangles scale proportionally is crucial. You can read more about this in our guide to Similar triangles in Class 10: the basic proportionality theorem.
How does the converse of the Pythagorean theorem work?
We know that if a triangle has a right angle, then a² + b² = c². But does the rule work backwards? Yes.
The converse of the Pythagorean theorem states that if the square of the longest side equals the sum of the squares of the other two sides, the triangle must have a right angle. Euclid proved this in his Elements over two thousand years ago.
If the numbers do not balance (assuming c is the longest side), the converse also tells you what shape the triangle is:
If a² + b² > c², the triangle is acute (all angles under 90 degrees).
If a² + b² < c², the triangle is obtuse (one angle over 90 degrees).
Testing these conditions is a common task in coordinate geometry. For example, you might use the distance formula to find the side lengths of a triangle on a graph, and then apply this test to find its shape. You can explore how these area relationships work in our post on the Area of a triangle using determinants, and the collinearity test.



