math number-theory history proof

Fermat's Last Theorem: 358 Years to Prove One Sentence

In 1637, a French lawyer and amateur mathematician named Pierre de Fermat was reading a 1,400-year-old geometry book in his study when he scribbled a note in the margin that would haunt the best mathematical minds on Earth for the next 358 years.

The note was tantalizing in its simplicity. Fermat claimed he had discovered a "truly marvelous proof" of a deceptively simple fact — and that the margin was simply too small to contain it. What followed was the longest, strangest treasure hunt in the history of mathematics: a chase across continents and centuries, involving secret work, a near-miss that became international news, a catastrophic error, and finally a breakthrough that brought one man to tears alone in his office at Princeton.

The theorem itself? You can understand it if you remember the Pythagorean theorem from high school.

The Concept

You already know that a² + b² = c² has whole-number solutions — the famous Pythagorean triples. Take 3² + 4² = 5² (9 + 9 = 25... wait, 9 + 16 = 25). Or 5² + 12² = 13². There are infinitely many of them.

Now ask a simple follow-up: what about cubes? Does a³ + b³ = c³ have any whole-number solutions? What about fourth powers? What about any power higher than 2?

Fermat's answer was no. His claim — which became known as Fermat's Last Theorem — states:

The equation aⁿ + bⁿ = cⁿ has no solutions in positive integers a, b, and c when n is greater than 2.

That's it. One sentence. Infinitely many Pythagorean triples exist, but the moment you step up to cubes, the party is over. No three perfect cubes can sum to another perfect cube. No fourth powers. No fifth powers. Nothing, for any exponent greater than 2.

The statement is elementary enough to appear in a middle-school textbook. The proof required some of the most sophisticated mathematics invented in the 20th century.

Why It Matters

Fermat wrote his note around 1637, but he died in 1665 without publishing the proof. His son published a collection of Pierre's margin notes in 1670, and the problem was officially unleashed on the mathematical world.

What followed was 325 years of incremental progress — and spectacular failure.

Leonhard Euler, history's most prolific mathematician, proved the theorem for the case n = 3 in his Algebra in 1770, though his proof contained a gap that others later filled. In 1825, two mathematicians independently proved n = 5: Peter Dirichlet and Adrien-Marie Legendre. In 1839, Gabriel Lamé proved n = 7.

The pattern seemed encouraging — case by case, the theorem was being conquered. But there was a catch: you can't prove an infinite number of cases one at a time. Even if you spent a trillion years proving each exponent, you'd still have infinitely many left.

Sophie Germain made the most ambitious early systematic attack. Barred from academic institutions because she was a woman, she initially corresponded with the great Carl Friedrich Gauss under a male pseudonym — "Antoine Le Blanc." When Gauss finally discovered her true identity, he wrote back with undisguised admiration. Germain developed a theorem that verified the result for all odd prime exponents less than 100 in one stroke — a massive leap. But her technique, while brilliant, ultimately couldn't scale to cover all primes.

Then came 1847 — and the most dramatic false alarm in mathematical history.

Gabriel Lamé stood before the Paris Académie des Sciences on March 1, 1847, and announced a complete proof. His method used complex numbers to factor the equation aᵖ + bᵖ. It was elegant. The room was electric. Lamé was about to be immortal.

Immediately, another mathematician named Joseph Liouville raised his hand. He pointed out that Lamé's proof assumed unique factorization held in his complex number system — the idea that every number breaks down into prime factors in exactly one way. For ordinary integers, this is guaranteed by the Fundamental Theorem of Arithmetic. But did it hold for the exotic complex numbers Lamé was using?

It did not. Within weeks, Ernst Kummer delivered the fatal blow: unique factorization breaks down for these complex numbers starting at a certain point. Lamé's proof was dead.

Kummer salvaged enough of the wreckage to prove the theorem for a large class of prime exponents called regular primes. But infinitely many irregular primes remained untouched. The general theorem stood.

In 1908, a German industrialist named Paul Wolfskehl — saved from a planned suicide by a sleepless night working on Fermat's problem — left 100,000 gold marks in his will (roughly $2 million at the time) to whoever could prove the theorem. The prize triggered a flood of amateur attempts: 621 submissions arrived in the first year alone. By 1997, when the prize was finally collected, inflation had reduced it to about $50,000.

The Details

The real breakthrough didn't come from attacking Fermat's equation directly. It came from an astonishing detour through two completely different areas of mathematics that, on the surface, have nothing to do with whole-number equations.

In 1955, a young Japanese mathematician named Yutaka Taniyama posed a conjecture at a Tokyo symposium. He suggested a deep connection between two seemingly unrelated mathematical objects:

  • Elliptic curves: smooth curves defined by equations like y² = x³ + ax + b, with rich algebraic structure
  • Modular forms: highly symmetric complex functions that arise in number theory

Taniyama's conjecture said, roughly, that every elliptic curve is secretly a modular form in disguise. His colleague Goro Shimura helped refine the idea. The French mathematician André Weil later provided crucial evidence for it. Today the result is called the Shimura-Taniyama-Weil conjecture.

Taniyama died by suicide in 1958, age 31, never knowing his conjecture would unlock Fermat's secret.

The bridge was built in 1985 by Gerhard Frey, a German mathematician. Frey's insight was this: suppose Fermat's theorem is false — suppose there does exist some solution aᵖ + bᵖ = cᵖ. Then use those numbers to build a specific elliptic curve. Frey argued that this curve would be so bizarre, so asymmetric, so pathological in its behavior, that it could not possibly be a modular form.

The logic chain snapped shut. If the Shimura-Taniyama-Weil conjecture is true — all elliptic curves are modular — then Frey's curve cannot exist. And if Frey's curve cannot exist, neither can the assumed solution to Fermat's equation. Therefore Fermat's theorem must be true.

All that remained was proving Shimura-Taniyama-Weil. That was still a famously open and notoriously hard conjecture.

Ken Ribet at UC Berkeley completed the logical link in 1990, proving the precise technical statement needed to make Frey's argument watertight. Now the implications were stark: prove Shimura-Taniyama-Weil, and Fermat's Last Theorem falls as a consequence.

In 1986, a Princeton mathematician named Andrew Wiles heard about Ribet's result and made a decision. He had loved Fermat's problem since childhood — he'd found a library book about it at age ten and been captivated ever since. Now, for the first time in history, there was a plausible path to a proof.

Wiles disappeared into his attic office. He told no one except his wife, who learned the secret on their honeymoon. To avoid suspicion from colleagues — who would wonder why a productive researcher had suddenly stopped publishing — he released small, unrelated papers as decoys. For seven years, he worked in near-total secrecy.

On June 23, 1993, at the Isaac Newton Institute in Cambridge, Wiles delivered the third of three lectures titled with deliberate blandness: "Modular Forms, Elliptic Curves, and Galois Representations." By the end, the room understood what he had done. The New York Times ran the headline the next day. Wiles was on the front page.

Then came the nightmare.

During peer review, a mathematician named Nick Katz was checking the proof section by section and found himself unable to follow a key step. He raised the issue with Wiles. Wiles worked on the gap privately for weeks, then months. The hole grew. A method he had used — combining two sophisticated techniques called Iwasawa theory and the Kolyvagin-Flach method — turned out to be insufficient.

On December 4, 1993, Wiles publicly withdrew his claim. The proof was broken.

He labored alone for another year. Then, on September 19, 1994, in what he later called "the most important moment of my working life," the fix arrived in an instant. He realized that the very flaw in one method could be patched using the other — that Iwasawa theory and the Kolyvagin-Flach method, used together, completed each other's gaps. He stood staring at the argument in disbelief for twenty minutes. Then he called his wife.

On May 1995, the Annals of Mathematics published Wiles's proof — 109 pages in a single paper, accompanied by a supporting paper co-authored with his former student Richard Taylor. The journal devoted the entire issue to the two papers.

Fermat's Last Theorem was proven. 358 years after that margin note.

Takeaways

  • The simplest statements can require the deepest mathematics. Fermat's Last Theorem is something a ten-year-old can understand and something that defeated the world's best mathematicians for 358 years. Difficulty is not always proportional to complexity of statement.
  • Proof by connection is one of mathematics' most powerful tools. Wiles didn't solve Fermat's equation directly — he proved a theorem about elliptic curves and modular forms, and Fermat fell out as a corollary. The most powerful proofs often work by revealing unexpected bridges between distant fields.
  • Mathematics advances through partial victories. Euler, Germain, Kummer, Faltings, Frey, Ribet — each solved a piece of the puzzle without finishing it. Without their work, Wiles would have had nothing to build on. The proof is a collaboration across centuries.
  • Near-misses are part of the process. Lamé thought he had it in 1847. Wiles thought he had it in 1993. In both cases, the error led to deeper understanding. The gap in Wiles's first proof forced him to a more powerful technique than his original approach.
  • The proof opened more than it closed. Wiles's techniques — Galois representations, Hecke algebras, deformation rings — launched an entirely new research program. The full Shimura-Taniyama-Weil conjecture was proved for all elliptic curves in 2001 by a team extending Wiles's methods. The proof of one 17th-century margin note became the foundation of 21st-century number theory.

Resources: - Simon Singh's book Fermat's Last Theorem (published as Fermat's Enigma in the US) is the definitive popular account — unputdownable - The BBC documentary based on Singh's book features Wiles describing the breakthrough in his own words - For the mathematically adventurous: Wiles's original 1995 paper in the Annals of Mathematics is publicly available