On this page
Fermat's Last Theorem says xⁿ + yⁿ = zⁿ has no solution in positive whole numbers when n is 3 or more. Andrew Wiles' proof of the general case was published in the Annals of Mathematics in 1995 (Wiles, Annals of Mathematics, 1995). The case n = 4 is centuries older, and short enough to follow in one sitting.
Pierre de Fermat (1601–1665) wrote his claim in the margin of Bachet's translation of Diophantus' Arithmetica, and his son Samuel published an edition with those notes in 1670 (MacTutor biography of Fermat). Only one complete proof by Fermat survives. It uses infinite descent, and the n = 4 case follows straight from it (Fermat's right triangle theorem).
What is infinite descent?
Infinite descent is a proof method: you show that any positive-integer solution produces a smaller one, which would give an endless decreasing chain of positive integers, and that is impossible (Keith Conrad, Proofs by descent). It is the same idea behind the lowest-terms proof that √2 is irrational, which we walk through in proof by contradiction examples.
Every descent proof has four parts to check:
A size that is a positive integer (here, z).
A clean-up step (cancel common factors).
The descent step, which builds a new solution.
Proof that the new size is strictly smaller.
Why prove x⁴ + y⁴ = z² instead of x⁴ + y⁴ = z⁴?
If a⁴ + b⁴ = c⁴ had a solution, then x = a, y = b, z = c² would solve x⁴ + y⁴ = z². So the stronger statement covers the weaker one. It is also the only one descent can prove. Conrad points out that running the argument on a⁴ + b⁴ = c⁴ fails, because the smaller solution it produces has a square on the right, not a fourth power (Conrad, section 3).
How does the descent proof for n = 4 work?
The only tool is Euclid's formula: a primitive Pythagorean triple has the form m² − n², 2mn, m² + n², where m > n > 0 are coprime and exactly one of them is even (Pythagorean triple). If the theorem itself needs a refresher, start with our guide to the Baudhayana-Pythagoras theorem. The steps below follow Conrad's proof.
Suppose positive integers satisfy x⁴ + y⁴ = z². If a prime p divides both x and y, then p⁴ divides z², so p² divides z, and you can cancel. Repeat until x and y are coprime.
They cannot both be odd, because then z² would leave remainder 2 when divided by 4, and no square does. So take x odd and y even, which makes z odd.
First parametrisation: (x², y², z) is a primitive triple with y² even, so x² = k² − ℓ², y² = 2kℓ and z = k² + ℓ², where k > ℓ > 0 are coprime.
Second parametrisation: the first equation says x² + ℓ² = k², another primitive triple with x odd. So x = a² − b², ℓ = 2ab and k = a² + b², where a > b > 0 are coprime.
Put these into y² = 2kℓ to get (y/2)² = (a² + b²)ab. The three factors are positive and pairwise coprime, and their product is a square, so each one is a square: a = x′², b = y′² and a² + b² = z′².
That last equation says x′⁴ + y′⁴ = z′², which is a new solution. Its size: z′ ≤ z′² = a² + b² = k ≤ k² < z.
So every solution gives another with a smaller z, and that one gives a smaller one again, forever. Positive integers cannot keep decreasing, so there was never a solution. The drop is steep: Conrad shows z = z′⁴ + 4x′⁴y′⁴, so z′ is less than the fourth root of z.
Worked example: where a real triple falls short
Try the steps with real numbers. Take k = 5 and ℓ = 4. Then k² − ℓ² = 9 = 3², so x = 3 passes step 3's first condition. Step 4 works too: (3, 4, 5) is a triple with a = 2 and b = 1, since a² − b² = 3, 2ab = 4 and a² + b² = 5.
The chain breaks at y² = 2kℓ = 40, which is not a square. Step 5 tells you why: a solution would need a = 2 to be a perfect square. To test yourself, pick any coprime a > b with one even, compute k = a² + b² and ℓ = 2ab, and find which square condition fails first.
Why does n = 4 settle every exponent divisible by 4?
If n = 4m, then xⁿ + yⁿ = zⁿ can be rewritten as (xᵐ)⁴ + (yᵐ)⁴ = (z²ᵐ)², which is a solution of x⁴ + y⁴ = z². For n = 12, a solution would give (x³)⁴ + (y³)⁴ = (z⁶)², which the proof has ruled out. Every n of 3 or more is divisible by 4 or by an odd prime, so it is enough to prove the theorem for n = 4 and for each odd prime (Fermat's Last Theorem for specific exponents).
Fermat also sketched a descent proof that every prime of the form 4k + 1 is a sum of two squares; Euler supplied the missing steps (MacTutor). See which primes are a sum of two squares.
This proof chains three ideas: Pythagorean triples, coprimality and parity. If one feels shaky, review it on its own in the Fermi Concept Library. If you get stuck on a practice problem, the Fermi Problem Library has a step-by-step solver that explains the reasoning.



