杏吧原创

Alice’s adventures in algebra: Wonderland solved

The absurdities of Lewis Carroll's classic disguise an attack on new-fangled mathematics, says literary scholar Melanie Bayley
Critical of the new mathematics
Critical of the new mathematics
(Image: Andrew Hem)

What would Lewis Carroll鈥檚 Alice鈥檚 Adventures in Wonderland be without the Cheshire Cat, the trial, the Duchess鈥檚 baby or the Mad Hatter鈥檚 tea party? Look at the original story that the author told Alice Liddell and her two sisters one day during a boat trip near Oxford, though, and you鈥檒l find that these famous characters and scenes are missing from the text.

As I embarked on my DPhil investigating Victorian literature, I wanted to know what inspired these later additions. The critical literature focused mainly on Freudian interpretations of the book as a wild descent into the dark world of the subconscious. There was no detailed analysis of the added scenes, but from the mass of literary papers, one stood out: in 1984 of the University of Wisconsin-Milwaukee had linked the trial of the Knave of Hearts with a Victorian book on algebra. Given the author鈥檚 day job, it was somewhat surprising to find few other reviews of his work from a mathematical perspective. Carroll was a pseudonym: his real name was Charles Dodgson, and he was a mathematician at Christ Church College, Oxford.

The 19th century was a turbulent time for mathematics, with many new and controversial concepts, like imaginary numbers, becoming widely accepted in the mathematical community. Putting Alice鈥檚 Adventures in Wonderland in this context, it becomes clear that Dodgson, a stubbornly conservative mathematician, used some of the missing scenes to satirise these radical new ideas.

Even Dodgson鈥檚 keenest admirers would admit he was a cautious mathematician who produced little original work. He was, however, a conscientious tutor, and, above everything, he valued the ancient Greek textbook Euclid鈥檚 as the epitome of mathematical thinking. Broadly speaking, it covered the geometry of circles, quadrilaterals, parallel lines and some basic trigonometry. But what鈥檚 really striking about Elements is its rigorous reasoning: it starts with a few incontrovertible truths, or axioms, and builds up complex arguments through simple, logical steps. Each proposition is stated, proved and finally signed off with QED.

For centuries, this approach had been seen as the pinnacle of mathematical and logical reasoning. Yet to Dodgson鈥檚 dismay, contemporary mathematicians weren鈥檛 always as rigorous as Euclid. He dismissed their writing as 鈥渟emi-colloquial鈥 and even 鈥渟emi-logical鈥. Worse still for Dodgson, this new mathematics departed from the physical reality that had grounded Euclid鈥檚 works.

By now, scholars had started routinely using seemingly nonsensical concepts such as imaginary numbers 鈥 the square root of a negative number 鈥 which don鈥檛 represent physical quantities in the same way that whole numbers or fractions do. No Victorian embraced these new concepts wholeheartedly, and all struggled to find a philosophical framework that would accommodate them. But they gave mathematicians a freedom to explore new ideas, and some were prepared to go along with these strange concepts as long as they were manipulated using a consistent framework of operations. To Dodgson, though, the new mathematics was absurd, and while he accepted it might be interesting to an advanced mathematician, he believed it would be impossible to teach to an undergraduate.

Outgunned in the specialist press, Dodgson took his mathematics to his fiction. Using a technique familiar from Euclid鈥檚 proofs, reductio ad absurdum, he picked apart the 鈥渟emi-logic鈥 of the new abstract mathematics, mocking its weakness by taking these premises to their logical conclusions, with mad results. The outcome is Alice鈥檚 Adventures in Wonderland.

Algebra and hookahs

Take the chapter 鈥淎dvice from a caterpillar鈥, for example. By this point, Alice has fallen down a rabbit hole and eaten a cake that has shrunk her to a height of just 3 inches. Enter the Caterpillar, smoking a hookah pipe, who shows Alice a mushroom that can restore her to her proper size. The snag, of course, is that one side of the mushroom stretches her neck, while another shrinks her torso. She must eat exactly the right balance to regain her proper size and proportions.

While some have argued that this scene, with its hookah and 鈥渕agic mushroom鈥, is about drugs, I believe it鈥檚 actually about what Dodgson saw as the absurdity of symbolic algebra, which severed the link between algebra, arithmetic and his beloved geometry. Whereas the book鈥檚 later chapters contain more specific mathematical analogies, this scene is subtle and playful, setting the tone for the madness that will follow.

The first clue may be in the pipe itself: the word 鈥渉ookah鈥 is, after all, of Arabic origin, like 鈥渁lgebra鈥, and it is perhaps striking that , the first British mathematician to lay out a consistent set of rules for symbolic algebra, uses the original Arabic translation in , which was published in 1849. He calls it 鈥渁l jebr e al mokabala鈥 or 鈥渞estoration and reduction鈥 鈥 which almost exactly describes Alice鈥檚 experience. Restoration was what brought Alice to the mushroom: she was looking for something to eat or drink to 鈥済row to my right size again鈥, and reduction was what actually happened when she ate some: she shrank so rapidly that her chin hit her foot.

De Morgan鈥檚 work explained the departure from universal arithmetic 鈥 where algebraic symbols stand for specific numbers rooted in a physical quantity 鈥 to that of symbolic algebra, where any 鈥渁bsurd鈥 operations involving negative and impossible solutions are allowed, provided they follow an internal logic. Symbolic algebra is essentially what we use today as a finely honed language for communicating the relations between mathematical objects, but Victorians viewed algebra very differently. Even the early attempts at symbolic algebra retained an indirect relation to physical quantities.

De Morgan wanted to lose even this loose association with measurement, and proposed instead that symbolic algebra should be considered as a system of grammar. 鈥淩educe鈥 algebra from a universal arithmetic to a series of logical but purely symbolic operations, he said, and you will eventually be able to 鈥渞estore鈥 a more profound meaning to the system 鈥 though at this point he was unable to say exactly how.

When Alice loses her temper

The madness of Wonderland, I believe, reflects Dodgson鈥檚 views on the dangers of this new symbolic algebra. Alice has moved from a rational world to a land where even numbers behave erratically. In the hallway, she tried to remember her multiplication tables, but they had slipped out of the base-10 number system we are used to. In the caterpillar scene, Dodgson鈥檚 qualms are reflected in the way Alice鈥檚 height fluctuates between 9 feet and 3 inches. Alice, bound by conventional arithmetic where a quantity such as size should be constant, finds this troubling: 鈥淏eing so many different sizes in a day is very confusing,鈥 she complains. 鈥淚t isn鈥檛,鈥 replies the Caterpillar, who lives in this absurd world.

鈥淲onderland鈥檚 madness reflects Carroll鈥檚 views on the dangers of the new symbolic algebra鈥

The Caterpillar鈥檚 warning, at the end of this scene, is perhaps one of the most telling clues to Dodgson鈥檚 conservative mathematics. 鈥淜eep your temper,鈥 he announces. Alice presumes he鈥檚 telling her not to get angry, but although he has been abrupt he has not been particularly irritable at this point, so it鈥檚 a somewhat puzzling thing to announce. To intellectuals at the time, though, the word 鈥渢emper鈥 also retained its original sense of 鈥渢he proportion in which qualities are mingled鈥, a meaning that lives on today in phrases such as 鈥渏ustice tempered with mercy鈥. So the Caterpillar could well be telling Alice to keep her body in proportion 鈥 no matter what her size.

This may again reflect Dodgson鈥檚 love of Euclidean geometry, where absolute magnitude doesn鈥檛 matter: what鈥檚 important is the ratio of one length to another when considering the properties of a triangle, for example. To survive in Wonderland, Alice must act like a Euclidean geometer, keeping her ratios constant, even if her size changes.

Of course, she doesn鈥檛. She swallows a piece of mushroom and her neck grows like a serpent with predictably chaotic results 鈥 until she balances her shape with a piece from the other side of the mushroom. It鈥檚 an important precursor to the next chapter, 鈥淧ig and pepper鈥, where Dodgson parodies another type of geometry.

By this point, Alice has returned to her proper size and shape, but she shrinks herself down to enter a small house. There she finds the Duchess in her kitchen nursing her baby, while her Cook adds too much pepper to the soup, making everyone sneeze except the Cheshire Cat. But when the Duchess gives the baby to Alice, it somehow turns into a pig.

The target of this scene is projective geometry, which examines the properties of figures that stay the same even when the figure is projected onto another surface 鈥 imagine shining an image onto a moving screen and then tilting the screen through different angles to give a family of shapes. The field involved various notions that Dodgson would have found ridiculous, not least of which is the 鈥減rinciple of continuity鈥.

, the French mathematician who set out the principle, describes it as follows: 鈥淟et a figure be conceived to undergo a certain continuous variation, and let some general property concerning it be granted as true, so long as the variation is confined within certain limits; then the same property will belong to all the successive states of the figure.鈥

The case of two intersecting circles is perhaps the simplest example to consider. Solve their equations, and you will find that they intersect at two distinct points. According to the principle of continuity, any continuous transformation to these circles 鈥 moving their centres away from one another, for example 鈥 will preserve the basic property that they intersect at two points. It鈥檚 just that when their centres are far enough apart the solution will involve an imaginary number that can鈥檛 be understood physically (see diagram).

The continuity principle

Of course, when Poncelet talks of 鈥渇igures鈥, he means geometric figures, but Dodgson playfully subjects Poncelet鈥檚 鈥渟emi-colloquial鈥 argument to strict logical analysis and takes it to its most extreme conclusion. What works for a triangle should also work for a baby; if not, something is wrong with the principle, QED. So Dodgson turns a baby into a pig through the principle of continuity. Importantly, the baby retains most of its original features, as any object going through a continuous transformation must. His limbs are still held out like a starfish, and he has a queer shape, turned-up nose and small eyes. Alice only realises he has changed when his sneezes turn to grunts.

The baby鈥檚 discomfort with the whole process, and the Duchess鈥檚 unconcealed violence, signpost Dodgson鈥檚 virulent mistrust of 鈥渕odern鈥 projective geometry. Everyone in the pig and pepper scene is bad at doing their job. The Duchess is a bad aristocrat and an appallingly bad mother; the Cook is a bad cook who lets the kitchen fill with smoke, over-seasons the soup and eventually throws out her fire irons, pots and plates.

Alice, angry now at the strange turn of events, leaves the Duchess鈥檚 house and wanders into the Mad Hatter鈥檚 tea party, which explores the work of the Irish mathematician . Hamilton died in 1865, just after Alice was published, but by this time his discovery of quaternions in 1843 was being hailed as an important milestone in abstract algebra, since they allowed rotations to be calculated algebraically.

Just as complex numbers work with two terms, quaternions belong to a number system based on four terms (see 鈥淚maginary mathematics鈥). Hamilton spent years working with three terms 鈥 one for each dimension of space 鈥 but could only make them rotate in a plane. When he added the fourth, he got the three-dimensional rotation he was looking for, but he had trouble conceptualising what this extra term meant. Like most Victorians, he assumed this term had to mean something, so in the preface to his Lectures on Quaternions of 1853 he added a footnote: 鈥淚t seemed (and still seems) to me natural to connect this extra-spatial unit with the conception of time.鈥

Where geometry allowed the exploration of space, Hamilton believed, algebra allowed the investigation of 鈥減ure time鈥, a rather esoteric concept he had derived from Immanuel Kant that was meant to be a kind of Platonic ideal of time, distinct from the real time we humans experience. Other mathematicians were polite but cautious about this notion, believing pure time was a step too far.

The parallels between Hamilton鈥檚 maths and the Hatter鈥檚 tea party 鈥 or perhaps it should read 鈥渢-party鈥 鈥 are uncanny. Alice is now at a table with three strange characters: the Hatter, the March Hare and the Dormouse. The character Time, who has fallen out with the Hatter, is absent, and out of pique he won鈥檛 let the Hatter move the clocks past six.

Reading this scene with Hamilton鈥檚 maths in mind, the members of the Hatter鈥檚 tea party represent three terms of a quaternion, in which the all-important fourth term, time, is missing. Without Time, we are told, the characters are stuck at the tea table, constantly moving round to find clean cups and saucers.

Their movement around the table is reminiscent of Hamilton鈥檚 early attempts to calculate motion, which was limited to rotatations in a plane before he added time to the mix. Even when Alice joins the party, she can鈥檛 stop the Hatter, the Hare and the Dormouse shuffling round the table, because she鈥檚 not an extra-spatial unit like Time.

The Hatter鈥檚 nonsensical riddle in this scene 鈥 鈥淲hy is a raven like a writing desk?鈥 鈥 may more specifically target the theory of pure time. In the realm of pure time, Hamilton claimed, cause and effect are no longer linked, and the madness of the Hatter鈥檚 unanswerable question may reflect this.

Alice鈥檚 ensuing attempt to solve the riddle pokes fun at another aspect of quaternions: their multiplication is non-commutative, meaning that xy is not the same as yx. Alice鈥檚 answers are equally non-commutative. When the Hare tells her to 鈥渟ay what she means鈥, she replies that she does, 鈥渁t least I mean what I say 鈥 that鈥檚 the same thing鈥. 鈥淣ot the same thing a bit!鈥 says the Hatter. 鈥淲hy, you might just as well say that 鈥業 see what I eat鈥 is the same thing as 鈥業 eat what I see鈥!鈥

It鈥檚 an idea that must have grated on a conservative mathematician like Dodgson, since non-commutative algebras contradicted the basic laws of arithmetic and opened up a strange new world of mathematics, even more abstract than that of the symbolic algebraists.

When the scene ends, the Hatter and the Hare are trying to put the Dormouse into the teapot. This could be their route to freedom. If they could only lose him, they could exist independently, as a complex number with two terms. Still mad, according to Dodgson, but free from an endless rotation around the table.

And there Dodgson鈥檚 satire of his contemporary mathematicians seems to end. What, then, would remain of Alice鈥檚 Adventures in Wonderland without these analogies? Nothing but Dodgson鈥檚 original nursery tale, Alice鈥檚 Adventures Under Ground, charming but short on characteristic nonsense. Dodgson was most witty when he was poking fun at something, and only then when the subject matter got him truly riled. He wrote two uproariously funny pamphlets, fashioned in the style of mathematical proofs, which ridiculed changes at the University of Oxford. In comparison, other stories he wrote besides the Alice books were dull and moralistic.

I would venture that without Dodgson鈥檚 fierce satire aimed at his colleagues, Alice鈥檚 Adventures in Wonderland would never have become famous, and Lewis Carroll would not be remembered as the unrivalled master of nonsense fiction.

Imaginary mathematics

The real numbers, which include fractions and irrational numbers like 蟺 that can nevertheless be represented as a point on a number line, are only one of many number systems.

Complex numbers, for example, consist of two terms 鈥 a real component and an 鈥渋maginary鈥 component formed of some multiple of the square root of -1, now represented by the symbol i. They are written in the form a + bi.

The Victorian mathematician William Rowan Hamilton took this one step further, adding two more terms to make quaternions, which take the form a + bi + cj + dk and have their own strange rules of arithmetic.

Topics: Festive science / Mathematics