A missing solution becomes a curve

The equation looks like a small puzzle, but ruling out every possible whole-number triple requires more than checking examples. A proof must show that no solution can exist, no matter how large the numbers are. Mathematicians can also reduce the challenge: if a solution existed for some exponent above 2, one could use it to produce a solution for a prime exponent (or for 4). That turns infinitely many exponents into a more manageable set of cases, but it does not make the problem easy.

The decisive move was to translate a hypothetical solution into a different kind of object: an elliptic curve, a curve described by a cubic equation with rich arithmetic structure. In the 1980s, Gerhard Frey proposed a particular curve that could be built from a supposed solution to Fermat’s equation. The curve seemed to have properties that should not be able to coexist.

The contradiction comes from another field

The conflict involved modularity: a deep relationship between elliptic curves and certain functions studied in a separate branch of mathematics. Ribet showed that a Fermat solution would produce a curve that could not fit the expected modular pattern. Andrew Wiles then proved a major part of the modularity conjecture, covering the class of curves needed for the argument. If the hypothetical solution existed, its curve would have to be both modular and not modular—a contradiction.

That is why the proof, completed in the 1990s, did not resemble a direct manipulation of Fermat’s equation. It worked by showing that a solution would force an impossible object to exist. The route joined areas of mathematics that had seemed far apart, and its complexity helps explain why the theorem resisted proof for more than three centuries.

What was in the margin?

Fermat wrote his claim beside a passage in a book by the ancient mathematician Diophantus, adding that he had found a “truly marvelous” proof but that the margin was too narrow to contain it. Wiles’s proof depended on mathematical ideas developed long after Fermat’s time. That does not establish whether Fermat had a different proof, or whether he was mistaken about having one. The margin remains a tantalizing clue, not evidence that the modern proof was already there.