# Fermat's last theorem

### Related subjects Mathematics

**Fermat's Last Theorem** is the name of the statement in number theory that:

- It is impossible to separate any power higher than the second into two like powers,

or, more precisely:

- If an integer
*n*is greater than 2, then the equation*a*^{n}+*b*^{n}=*c*^{n}has no solutions in non-zero integers*a*,*b*, and*c*.

In 1637 Pierre de Fermat wrote, in his copy of Claude-Gaspar Bachet's translation of the famous * Arithmetica* of Diophantus, "I have a truly marvelous proof of this proposition which this margin is too narrow to contain." (Original Latin: "Cuius rei demonstrationem mirabilem sane detexi. Hanc marginis exiguitas non caperet.")

Fermat's Last Theorem is strikingly different and much more difficult to prove than the analogous problem for *n* = 2, for which there are infinitely many integer solutions called Pythagorean triples (and the closely related Pythagorean theorem has many elementary proofs). The fact that the problem's statement is understandable by schoolchildren makes it all the more frustrating, and it has probably generated more incorrect proofs than any other problem in the history of mathematics. No correct proof was found for 357 years, when a proof was finally published by Andrew Wiles in 1995. The term "last theorem" resulted because all the other theorems and results proposed by Fermat were eventually proved or disproved, either by his own proofs or by other mathematicians, in the two centuries following their proposition. Although a theorem now that it has been proved, the status of Fermat's Last Theorem before then, in spite of the name, was that of a * conjecture*, a mathematical statement whose status (true or false) has not been conclusively settled.

Fermat's Last Theorem is the most famous solved problem in the history of mathematics, familiar to all mathematicians, and had achieved a recognizable status in popular culture prior to its proof. The avalanche of media coverage generated by the resolution of Fermat's Last Theorem was the first of its kind, including worldwide newspaper accounts and various popularizations in books and a BBC Horizon program (which aired in the United States as a PBS NOVA special, *The Proof*).

## Fermat's Last Theorem from a comment in a margin

In problem II.8 of his * Arithmetica*, Diophantus asks how to split a given square number into two other squares (in modern notation, given a rational number *k*, find *u* and *v*, both rational, such that *k*^{2} = *u*^{2} + *v*^{2}), and shows how to solve the problem for *k* = 4. Around 1640, Fermat wrote in the margin next to this problem in his copy of the *Arithmetica*:

Cubum autem in duos cubos, aut quadratoquadratum in duos quadratoquadratos, et generaliter nullam in infinitum ultra quadratum potestatem in duos eiusdem nominis fas est dividere cuius rei demonstrationem mirabilem sane detexi. Hanc marginis exiguitas non caperet. | (It is impossible to separate a cube into two cubes, or a fourth power into two fourth powers, or in general, any power higher than the second into two like powers. I have discovered a truly marvelous proof of this, which this margin is too narrow to contain.) |

While Fermat's original margin note was lost with his copy of *Arithmetica*, around 1670, his son produced a new edition of the book augmented with his father's comments. The note eventually became known as *Fermat's Last Theorem*, as it became the last of Fermat's asserted theorems to remain unproven.

In the case *n* = 2, it was already known by the ancient Chinese, Indians, Greeks, and Babylonians that the Diophantine equation *a*^{2} + *b*^{2} = *c*^{2} (linked with the Pythagorean theorem) has integer solutions, such as (3,4,5) (3^{2} + 4^{2} = 5^{2}) and (5,12,13). These solutions are known as Pythagorean triples, and there exist infinitely many of them, even excluding solutions for which *a*, *b* and *c* have a common divisor (that is, when the entire equation is multiplied by the square of an integer). Fermat's Last Theorem is an extension of this problem to higher powers *n*, and states that no such solution exists when the exponent 2 is replaced by a larger integer.

## History of the proof

A special case of Fermat's Last Theorem for n = 3 was first stated by Abu Mahmud Khujandi in the 10th century, but his attempted proof of the theorem was incorrect.

The first case of Fermat's Last Theorem to be proven, by Fermat himself, was the case *n* = 4 using the method of infinite descent. Using a similar method, Leonhard Euler proved the theorem for *n* = 3; although his published proof contains some errors, the needed assertions could be established with work Euler himself had proven elsewhere. While his original method contained a flaw, it generated a great deal of research about the theorem. Over the following centuries, the theorem was established for many other special exponents *n* (or classes of exponents), but the general case remained elusive.

The case *n* = 5 was proved by Dirichlet and Legendre in 1825 using a generalisation of Euler's proof for *n* = 3. The proof for the next prime number (it is enough to prove the theorem for prime numbers: see below), *n* = 7 was found 15 years later by Gabriel Lamé in 1839. Unfortunately, this demonstration was relatively long and unlikely to be generalised to higher numbers. From this point, mathematicians started to demonstrate the theorem for classes of exponents, instead of individual numbers, and develop more general results related to the theorem.

These general ideas can be traced back to a novel approach introduced by Sophie Germain. Rather than proving that there were no solutions to a given value *n*, she demonstrated that if there was a solution, a certain condition would have to apply. This insight was already used in the proof of Fermat's Last Theorem for the case *n* = 5. In 1847, Kummer proved that the theorem was true for all regular prime numbers (which include all prime numbers between 2 and 100 except for 37, 59 and 67).

In 1823 and then in 1850, the French Academy of Sciences offered a prize for a correct proof. This initiative caused only a wave of thousands of mathematical misadventures. A third prize was offered in 1883 by the Academy of Brussels. In 1908, the German industrialist and amateur mathematician Paul Friedrich Wolfskehl bequeathed 100,000 marks to the Göttingen Academy of Sciences to be offered as a prize for a complete proof of Fermat's Last Theorem. As a result, from 1908-1911, a flood of over 1000 incorrect proofs were presented. According to mathematical historian Howard Eves:

- "
*Fermat's Last Theorem, has the peculiar distinction of being the mathematical problem for which the greatest number of incorrect proofs have been published*".

## Elliptic curves and Wiles' proof

The history of the *correct* proof of Fermat's Last Theorem begins in the late 1960s, when Yves Hellegouarch came up with an idea of associating to any solution (*a*,*b*,*c*) of Fermat's equation a completely different mathematical object: an elliptic curve. The curve consists of all points in the plane whose coordinates (*x*,*y*) satisfy the relation

*y*^{2}=*x*(*x*−*a*^{p})(*x*+*b*^{p}).

Such an elliptic curve would enjoy very special properties, which are due to the appearance of high powers of integers in its equation and the fact that *a*^{p} + *b*^{p} = *c*^{p} is a *p*th power as well. Gerhard Frey had an insight that such a curve would be so special that it would contradict a certain conjecture about elliptic curves which is now called the Taniyama–Shimura conjecture. This conjecture says that each elliptic curve with rational coefficients can be constructed in an entirely different way, not by giving its equation but by using modular functions to parametrize coordinates *x* and *y* of the points on it. Thus, according to the conjecture, any elliptic curve over **Q** would have to be a modular elliptic curve, yet if a solution to Fermat's equation with non-zero *a*, *b*, *c* and *p* greater than 2 existed, the corresponding curve would not be modular, resulting in a contradiction. The link between the Fermat's Last Theorem and the Taniyama–Shimura conjecture is a little subtle: in order to derive the former from the latter, one needs to know a bit more, or as mathematicians would have it, "an epsilon more". This extra piece of information was identified by Jean-Pierre Serre and became known as the epsilon conjecture. Serre's main interest was in an even more ambitious conjecture, Serre's conjecture on modular Galois representations, which would imply the Taniyama–Shimura conjecture. Although in the preceding twenty or thirty years a lot of evidence had been accumulated to form conjectures about elliptic curves, the main reason to believe that these various conjectures were true lay not in the numerical confirmations, but in a remarkably coherent and attractive mathematical picture that they presented. Moreover, it could have happened that one or more of these conjectures were actually false (for example, Serre's conjecture is still wide open), and yet Fermat's Last Theorem were nonetheless true. That would simply mean that one should try a different approach.

In the summer of 1986, Ken Ribet succeeded in proving the epsilon conjecture. (His article was published in 1990.) He demonstrated that, just as Frey had anticipated, a special case of the Taniyama–Shimura conjecture (still unproven at the time), together with the now proven epsilon conjecture, implies Fermat's Last Theorem. Thus, if the Taniyama–Shimura conjecture holds for a class of elliptic curves called semistable elliptic curves, then Fermat's Last Theorem would be true.

After learning about Ribet's work, Andrew Wiles set out to prove that every semistable elliptic curve is modular. He did so in almost complete secrecy, working for a full seven years with minimal outside help. Over the course of three lectures delivered at Isaac Newton Institute for Mathematical Sciences on June 21, 22, and 23 of 1993, Wiles announced his proof of the Taniyama–Shimura conjecture, and hence of the Fermat's Last Theorem. Wiles drew upon a wide variety of methods in the proof, some of them having been developed especially for this occasion.

Although Wiles had reviewed his argument beforehand with a Princeton colleague, Nick Katz, he soon discovered that the proof contained a gap. There was an error in a critical portion of the proof which gave a bound for the order of a particular group. Wiles and his former student Richard Taylor spent almost a year trying to repair the proof, under the close scrutiny of the media and the mathematical community. In September 1994, they were able to complete the proof by using a very novel approach in the troublesome part of the argument. Taylor and others would go on to prove the general form of the Taniyama–Shimura conjecture, now frequently called the modularity theorem, which applies to all elliptic curves over **Q**, not just the semistable curves that were relevant for the proof of Fermat's Last Theorem.

Taylor and Wiles's proof is extremely technical in that it relies on the mathematical techniques developed in the twentieth century, most of which would be totally alien to mathematicians who had worked on Fermat's Last Theorem only a century earlier. Fermat's alleged "marvelous proof", on the other hand, would have had to be fairly elementary, given the state of the mathematical knowledge at the time. And in fact, most mathematicians and science historians doubt that Fermat had a valid proof of his theorem for all exponents *n*.

## Mathematics of the theorem and its proof

Fermat's Last Theorem needs only to be proven for *n* = 4 and prime numbers greater than 2. If *n* > 2 is not a prime number or 4, it can be either a power of 2 or not. In the first case the number 4 is a factor of *n*, otherwise there is an odd prime number among its factors. In any case let any such factor be *p*, and let *m* be *n* / *p*. Now we can express the equation as (*a*^{m})^{p} + (*b*^{m})^{p} = (*c*^{m})^{p}. If we can prove the case with exponent *p*, exponent *n* is simply a subset of that case.

The research on Fermat's Last Theorem stimulated the development of a great deal of modern ring theory. In particular, the notion of an ideal and the ideal class group grew out of Kummer's work on the theorem, and his proof of it for regular primes.

In 1977, Guy Terjanian proved that if *p* is an odd prime number, and the natural numbers *x*, *y* and *z* satisfy *x*^{2p} + *y*^{2p} = *z*^{2p}, then 2*p* must divide *x* or *y*.

In 1985, Leonard Adleman, Roger Heath-Brown and Etienne Fouvry proved there exist infinitely many primes *p* such that the *first case* of Fermat's Last Theorem holds: if *x*^{p} + *y*^{p} = *z*^{p} then *x**y**z* is divisible by *p*.

The Mordell conjecture, proven by Gerd Faltings in 1983, implies that for any *n* > 2, there are at most finitely many coprime integers *a*, *b* and *c* with *a*^{n} + *b*^{n} = *c*^{n}.

The Taniyama–Shimura conjecture states that every elliptic curve can be parametrised by a rational map with integer coefficients using the classical modular curve; that is, all elliptic curves (over the rationals) can be described by modular forms.

On the other hand Ribet's theorem shows that for any nontrivial solution to Fermat's equation, *a*^{n} + *b*^{n} = *c*^{n}, the semistable elliptic curve of Hellegouarch and Frey, defined by

*y*^{2}=*x*(*x*−*a*^{n})(*x*+*b*^{n}),

is not modular. Fermat's Last Theorem therefore follows from the Taniyama–Shimura conjecture.

The proof of this theorem for semistable elliptic curves by Wiles (and, in part, Taylor) uses many techniques from algebraic geometry and number theory, and has many ramifications in these branches of mathematics. As well as standard constructions of modern algebraic geometry, using the category of schemes and Iwasawa theory, the proof involved the development of ideas from Barry Mazur on deformations of Galois representations and contributed to the Langlands program.

## Generalizations and similar equations

Many Diophantine equations have a form similar to the equation of Fermat's Last Theorem, without necessarily sharing its properties.

For example, it is known that there are infinitely many positive integers *x*, *y*, and *z* such that *x*^{n} + *y*^{n} = *z*^{m} in which *n* and *m* are any relatively prime natural numbers.