# Pythagorean Triples Calculator

URL: https://speedycalculator.com/calculators/math/pythagorean-triples/
Last updated: 2026-10-30

> The Pythagorean triples calculator checks whether three whole numbers form a Pythagorean triple and whether it is primitive, or generates a triple from Euclid's formula with numbers m, n and a multiplier k.

## Inputs

- Mode
- First number
- Second number
- Third number
- m
- n
- Multiplier k

## Results

- Result
- Check
- Primitive?

## Formula

```
a² + b² = c²
Euclid: a = k(m² − n²),  b = 2kmn,  c = k(m² + n²),  m > n > 0
```

## Explanation

Pythagorean triples – like 3-4-5, 5-12-13 and 8-15-17 – are whole-number sides of right triangles. Babylonian tablets list them, builders use them to set out right angles, and Euclid's formula generates every primitive triple.

### How to use the Pythagorean Triples Calculator

- **Mode**
- **First number**
- **Second number**
- **Third number**
- **m**
- **n**
- **Multiplier k**

Everything is calculated in your browser, so results appear instantly and nothing you type is sent to a server.

### How it works

In check mode the numbers are sorted and the smallest two squares are compared with the largest. In generate mode, m and n give a primitive triple when they are coprime and of opposite parity; k scales it.

## Worked example

Inputs — Mode: Generate a triple (Euclid's formula); m: 2; n: 1; Multiplier k: 1.

Results — **Result = (3, 4, 5)**; Check = 3² + 4² = 25 = 5²; Primitive? = Primitive (no common factor).

## Key terms

- **Pythagorean triple**: Positive integers a, b, c with a² + b² = c².

## FAQ

**What is a primitive triple?**
One with no common factor, like 3-4-5 (6-8-10 is not primitive).

**Are there infinitely many triples?**
Yes – Euclid's formula gives infinitely many primitive ones.

**What is the smallest triple?**
3, 4, 5.

**Is one leg always even?**
Yes, in every primitive triple exactly one leg is even.


## Sources

- [Wolfram MathWorld – Pythagorean triple](https://mathworld.wolfram.com/PythagoreanTriple.html)
