If you have ever doubted that geometry and algebra are linked, then remember Pythagoras’s theorem. The picture showing the squares on the sides of a right-angled triangle goes hand in hand with the equation \[a^2+b^2=c^2.\]

A right angled triangle pictured with 3 orange squares that each share a side with one of the edges

Right-angled triangles turn up all over the place, whether it’s in DIY or high-end engineering, and the algebraic formulation gives us an algebraic way to work out the length of one of their sides if we know the other two, by solving an equation and without having to measure anything. Because of this, Pythagoras’s theorem is probably one of the most frequently applied mathematical results in history. If the sides of the triangles, the numbers \(a\), \(b\) and \(c\), are all positive whole numbers then they form what is called a Pythagorean triple. Examples are \((3,4,5)\), \((5,12,13)\) and \((8,15,17)\), but it turns out that we could continue indefinitely—there are infinitely many such triples.

Geometric intuition quickly leaves us, however, if we tweak the equation a little and consider powers higher than \(2\). What if we consider \[a^3+b^3=c^3,\] or \[a^4+b^4=c^4,\] or, more generally, \[a^n+b^n=c^n,\] for \(n\) a positive integer greater than \(2\)? Can we still find positive whole numbers \(a\), \(b\) and \(c\) satisfying the equation, the equivalent of Pythagorean triples?

The 17th century mathematician Pierre de Fermat convinced himself that such triples don’t exist for any natural number \(n>2\). In 1637 he wrote into the margin of his maths book that he had found a “marvellous proof” for this fact, which the margin was too narrow to contain. That tantalising scribble was to taunt mathematicians for 357 years. Many tried their hand at proving what became known as Fermat’s last theorem—the problem is so easy to state that many hoped a solution should be equally straightforward.

A British mathematician called Andrew Wiles eventually proved them wrong. His proof of the theorem involved sophisticated mathematics that goes beyond anything Fermat could have dreamed of. It also ventured back into geometry, making use of a particular class of curves. Wiles had spent seven years working on the problem in secret, avoiding the attention he would have attracted had he admitted to what he was doing. In fact, he had been working on a more general problem, called the Taniyama-Shimura conjecture, whose solution implied Fermat’s last theorem, but which was considered pretty inaccessible by most mathematicians at the time. He announced his proof at the Isaac Newton Institute in Cambridge on 23rd June 1993. In the days before his lecture rumours had been circulating that he was about to let the cat out of the bag and the atmosphere, according to eyewitnesses, was electric—not a word often used in connection with maths lectures. The lecture room was packed and, when he finished his lecture with the understated “I think I’ll stop here”, his announcement was greeted with thunderous applause. Unfortunately his initial proof contained a flaw, not that surprising given it was over 150 pages long and contained groundbreaking mathematics. But with the help of a former student, Richard Taylor, Wiles was able to fix it within just over a year.