Right Triangle Solver logo
Right Triangle Solver

Pythagorean Triples

Pythagorean Triples Calculator

Check or generate whole-number right triangle triples with step-by-step results.

Calculator Mode

Check a Pythagorean triple

A Pythagorean triple is a set of three whole numbers that perfectly fit the rule a² + b² = c². When three numbers satisfy this equation, they can always form the sides of a right triangle. The most familiar example is 3, 4, 5 — but there are infinitely many others.

This calculator gives you two ways to work with Pythagorean triples. You can check whether any three numbers form a valid triple, or you can generate a new triple using the m and n formula. Both modes show full step-by-step solutions so you can follow the math.

Enter three side lengths to check a triple, or use m and n values to generate one. The calculator validates your inputs and shows detailed solution steps.

Formula

Every Pythagorean triple satisfies the equation a² + b² = c², where c is the hypotenuse and a and b are the two legs. If all three values are whole numbers and the equation holds true, you have a valid Pythagorean triple.

You can also generate triples using two positive integers m and n, where m is greater than n. The formulas a = m² − n², b = 2mn, and c = m² + n² will always produce a valid triple. When m and n share no common factors and are not both odd, the result is called a primitive triple.

a2+b2=c2a^2 + b^2 = c^2
a=m2n2a = m^2 - n^2
b=2mnb = 2mn
c=m2+n2c = m^2 + n^2

Triangle Diagram

a b c 90°

Triangle Diagram Key

  • a and b are the two legs of the right triangle.
  • c is always the hypotenuse — the longest side, opposite the right angle.
  • In a Pythagorean triple, all three values are whole numbers.
  • The right angle is between sides a and b.

How to Use This Calculator

  1. Select a mode: Check a triple or Generate a triple.
  2. For checking: enter three side values with c as the largest.
  3. For generating: enter two positive integers m and n where m is greater than n.
  4. Click Calculate to see the result and step-by-step solution.
  5. Click Reset to clear all fields and start over.

Step-by-Step Examples

Example 1: Check whether 3, 4, 5 is a Pythagorean triple

a2+b2=c2a^2 + b^2 = c^2
32+42=523^2 + 4^2 = 5^2
9+16=259 + 16 = 25
25=2525 = 25 \quad \checkmark
Result: 3, 4, 5 is a valid Pythagorean triple.\text{Result: 3, 4, 5 is a valid Pythagorean triple.}

Example 2: Generate a triple using m = 2, n = 1

a=m2n2=2212=41=3a = m^2 - n^2 = 2^2 - 1^2 = 4 - 1 = 3
b=2mn=2×2×1=4b = 2mn = 2 \times 2 \times 1 = 4
c=m2+n2=22+12=4+1=5c = m^2 + n^2 = 2^2 + 1^2 = 4 + 1 = 5
Result: 3, 4, 5\text{Result: 3, 4, 5}

Example 3: Check whether 7, 24, 25 is a Pythagorean triple

a2+b2=c2a^2 + b^2 = c^2
72+242=2527^2 + 24^2 = 25^2
49+576=62549 + 576 = 625
625=625625 = 625 \quad \checkmark
Result: 7, 24, 25 is a valid Pythagorean triple.\text{Result: 7, 24, 25 is a valid Pythagorean triple.}

What the Result Means

When checking a triple, the calculator tells you whether the three numbers satisfy a² + b² = c². If the left side equals the right side, the numbers form a valid Pythagorean triple and can be the sides of a right triangle.

When generating a triple, the calculator produces three whole numbers using the m and n formulas. These numbers are guaranteed to form a right triangle. If m and n share no common factor and are not both odd, the triple is primitive — meaning it cannot be simplified further.

Side Ratio

A Pythagorean triple has whole-number side lengths in the form a : b : c.

The exact ratio changes from one triple to another, but every valid triple satisfies a² + b² = c² with c as the hypotenuse.

When to Use This Calculator

Common Mistakes

help

FAQs

Answers to the most common right-triangle solving questions.

01 What is a Pythagorean triple? expand_more

A Pythagorean triple is a set of three whole numbers a, b, and c that satisfy the equation a² + b² = c². These three numbers can always be the side lengths of a right triangle.

02 How do I use the m and n formula to generate a Pythagorean triple? expand_more

Pick two positive integers where m is greater than n. Then calculate a = m² − n², b = 2mn, and c = m² + n². The result is always a valid Pythagorean triple.

03 What is a primitive Pythagorean triple? expand_more

A primitive Pythagorean triple is one where a, b, and c share no common factor other than 1. For example, 3, 4, 5 is primitive, but 6, 8, 10 is not because all three are divisible by 2.

04 Can decimal numbers form a Pythagorean triple? expand_more

No. Pythagorean triples are defined as sets of whole numbers only. Decimal values may satisfy a² + b² = c², but they are not considered triples.

05 Is 5, 12, 13 a Pythagorean triple? expand_more

Yes. Checking: 5² + 12² = 25 + 144 = 169 = 13². Since all three are whole numbers and the equation holds, it is a valid Pythagorean triple.

06 Why does the calculator say my values are not a triple? expand_more

The calculator checks whether a² + b² equals c² exactly. If there is any difference — even a small one from rounding — the values do not form a Pythagorean triple. Make sure c is the largest value.

Related Calculators