Pythagorean Triple Generator and Checker
Generate a list, create one triple from m and n, find triples containing a known side, or verify three integers.
All calculations happen locally in your browser; your inputs are not uploaded.
What do you want to do?
Use m > n > 0. A primitive result requires gcd(m,n)=1, opposite parity, and k=1.
The checker orders the values, then treats the largest as the possible hypotenuse.
Results
5 triples shown. Select a row to preview its triangle.
| Triple | Type | Actions |
|---|---|---|
| (3, 4, 5) | Primitive | 3² + 4² = 9 + 16 = 25 = 5² |
| (6, 8, 10) | Scaled ×2 | 2 × (3, 4, 5) |
| (5, 12, 13) | Primitive | 5² + 12² = 25 + 144 = 169 = 13² |
| (8, 15, 17) | Primitive | 8² + 15² = 64 + 225 = 289 = 17² |
| (7, 24, 25) | Primitive | 7² + 24² = 49 + 576 = 625 = 25² |
Advertisement
How Pythagorean triples work
A Pythagorean triple is a set of positive integers (a, b, c) satisfying a² + b² = c², where c is the hypotenuse. To check a candidate, order its sides and square them: 7² + 24² = 49 + 576 = 625 = 25².
Primitive and scaled triples
A triple is primitive when gcd(a,b,c)=1. Thus (3,4,5) is primitive, while (12,16,20) has GCD 4 and is the scaled triple 4×(3,4,5).
Euclid’s formula and its exact conditions
For integers m>n>0, the scaled formula is a=k(m²−n²), b=2kmn, c=k(m²+n²). It produces a primitive triple precisely when gcd(m,n)=1, m and n have opposite parity, and k=1. Other valid inputs can produce non-primitive triples.
Algebraic check: (m²−n²)²+(2mn)² = m⁴−2m²n²+n⁴+4m²n² = m⁴+2m²n²+n⁴ = (m²+n²)².
Finding a triple containing a known side
Select “Find a known leg” or another finder option. A side can belong to more than one triple, so the tool searches every Euclid seed and scale up to a sufficient calculated bound and reports that bound. For example, leg 20 has four matches through (20,99,101), not just the matches below the old default c≤200 by coincidence.
Common primitive triples below 100
| a | b | c | Perimeter |
|---|---|---|---|
| 3 | 4 | 5 | 12 |
| 5 | 12 | 13 | 30 |
| 8 | 15 | 17 | 40 |
| 7 | 24 | 25 | 56 |
| 20 | 21 | 29 | 70 |
| 12 | 35 | 37 | 84 |
| 9 | 40 | 41 | 90 |
| 28 | 45 | 53 | 126 |
| 11 | 60 | 61 | 132 |
| 33 | 56 | 65 | 154 |
| 16 | 63 | 65 | 144 |
| 48 | 55 | 73 | 176 |
| 13 | 84 | 85 | 182 |
| 36 | 77 | 85 | 198 |
| 39 | 80 | 89 | 208 |
| 65 | 72 | 97 | 234 |
Examples of scaled triples
| Triple | Primitive base | Scale | GCD |
|---|---|---|---|
| (6,8,10) | (3,4,5) | 2 | 2 |
| (9,12,15) | (3,4,5) | 3 | 3 |
| (12,16,20) | (3,4,5) | 4 | 4 |
| (10,24,26) | (5,12,13) | 2 | 2 |
Frequently asked questions
What is the smallest Pythagorean triple?
The smallest Pythagorean triple is (3, 4, 5), because 3² + 4² = 9 + 16 = 25 = 5².
Is 6-8-10 a primitive Pythagorean triple?
No. (6, 8, 10) is valid, but its greatest common divisor is 2, so it is 2 × (3, 4, 5).
How do I test whether three numbers form a Pythagorean triple?
Order the positive integers from smallest to largest and check whether the squares of the two smaller numbers add to the square of the largest: a² + b² = c².
What conditions make Euclid's formula produce a primitive triple?
Use integers m > n > 0 with gcd(m,n)=1 and opposite parity, then set a=m²−n², b=2mn, and c=m²+n². Use scale factor k=1 for a primitive triple.
Can one side occur in multiple Pythagorean triples?
Yes. For example, leg 20 occurs in (15,20,25), (20,21,29), (20,48,52), and (20,99,101).
Are there infinitely many Pythagorean triples?
Yes. Euclid's formula produces infinitely many primitive triples, and every positive integer multiple of a triple is also a triple.
Can an integer right triangle be isosceles?
No. Equal integer legs would require c=a√2, which is not an integer for any positive integer a.
Method and validation
The list and finder enumerate primitive seeds using Euclid’s formula, then apply positive scale factors. Legs are ordered a≤b and a composite key removes duplicates. The checker independently compares a²+b² with c².
Known test cases: (3,4,5), (5,12,13), (7,24,25), scaled (6,8,10), invalid (2,3,4), leg 20’s four matches, and both primitive triples with c=65.
References: Wolfram MathWorld: Pythagorean Triple; Euclid’s Elements, Book I, Proposition 47 (Trinity College Dublin).
Last reviewed: 17 July 2026. No named mathematical reviewer is claimed.
