Visual explanations of mathematics

It is thought that Euclid wrote Elements in about 300 BC, but Oliver Byrne turned it into one of the true gems of visualization — and made it about 100 times more readable. By seamlessly combining typeset text (Caslon, if you’re interested) with minimalist geometric drawings in primary colours, he didn’t just reproduce the text; he explained it in a new way.

annotated_byrne_euclid.png

If you like the look of it, it’s even cooler in Nicholas Rougeur’s beautiful interactive version.

This is a classic example of what Edward Tufte, the modern saint of visualization, calls a visual explanation (he wrote a whole book about the subject). We’ve written about the subject before (for example, see Evan’s 2014 post, Graphics that repay careful study). Figures and charts should do more than merely illustrate, they should elucidate.

Too often, equations — for example the myriad equations in any volume of GEOPHYSICS — do not elucidate. Indeed, they barely even illustrate. In some cases, it’s worse: they obfuscate. You might think mathematics is too dry, or too steeped in convention, for it to be any other way. Equations just are. But Byrne showed us that we can do better.

A few years ago, in an attempt to broaden my geophysical knowledge, I bought a copy of Daniel Fleisch’s book on Maxwell’s equations. It’s excellent, and the others in the series are good too. I especially liked the annotated equations; I’ve lightened the annotations in this version, to put them on a separate visual ‘layer’:

annotated_maxwell_by_fleisch.jpeg

In 2010, Randall Munroe of xkcd applied a similar strategy to label The Flake Equation, his parody of the Drake equation:

annotated_flake_equation.png

There are still other examples out there.

Later, I came across some lovely colourized equations by Stuart Riffle, a game developer. There was a bit of buzz about them on social media. Most people loved them, but a few pointed out that they suffer from the ‘legend lookup’ problem, and the colours he chose might not be great for colourblind people. Still, I like the concept — here’s the Fourier transform:

annotated_Fourier_Transform.png

Direct annotation, something Tufte always advocates, avoids the legend lookup problem. In his 2016 Geophysics Tutorial on finite volume methods, Rowan Cockett showed that colour and labels can work together:

annotated_equation_by_rowan_cockett.jpeg

And in his Observable post on the predator–prey interaction, modern visualization legend Mike Bostock avoids the problem entirely with the use of pictograms: direct representation of what the symbols represent:

annotated_predator_prey.png

Observable is interesting because the documents are runnable code. And this reminds us that mathematics — equations, data structures, and so on — has another expression: code. While symbolic representation speaks directly to some people, code speaks to others, probably more. Look at Randall Munroe’s annotation of a Wolfram Alpha equation (similar to an Excel formula) from his (wonderful) book, What If:

annotated_golf_xkcd.png

What I love about this is the direct path to exploring the function yourself. It would take me an hour to implement Fleisch’s electric field integral in code, even with the annotations. Typing in this — admittedly less useful — rocket golf equation will take me two minutes. Expressing mathematics in code is the ultimate explicit and practical expression of an idea.

We have lots of tools to write better mathematics: LaTeX, markdown, Jupyter Notebooks, and so on. But it feels like nothing has really converged yet. Technology that seamlessly mixes symbolic equations, illustrative-and-explicative annotation, and runnable code is, I am sure, not far off. Until then, we do the best we can with the tools we have.


Have you seen nice examples of annotated equations? I’d love to hear about them; let me know in the comments!


Don’t miss the follow-up post from 2021: Illuminated equations.


The work by Byrne is out of copyright. Those by Munroe and Cockett are openly licensed under Creative Commons. The work of Fleisch and Bostock are used in accordance with Fair Use doctrine.

Are these the heroes we need?

First rule of criticism: balance it with something positive.

Technical societies — AAPG, SEG, SPE, EAGE, and the many others — do important work in our discipline. They publish some quality content, they organize a lot of meetings, and they help attract talent to work in subsurface science and engineering.

The door is wide open for them to play a central role in the change that’s coming to our lives as subsurface professionals.

Second rule of criticism: stick to the facts.

In spite of their central role in many scientists’ professional lives, and the magnitude of the changes that are underway, technical societies have struggled to maintain relevance and therefore members. It’s hard to know the extent of the problem, as AAPG doesn’t report how many members it has (it’s been “approximately 30,000” for years) and SEG stopped reporting numbers in 2017. Make of that what you will.

Anecdotally, many of my friends have let their memberships lapse. I have too.

Third rule of criticism: avoid negative language.

AAPG came up with a couple of cool superheroes. They commissioned some artwork: two fit, handsome geologists, ready for anything. Their names? Trap Mitchell and Alluvia Hunt.

AAPG_Trap_and_Alluvia.jpg

The laudable appearance of a woman — a non-white woman! — in this context rightly prompted praise:

How appalling is it that a geoscientist had to wait 23 years to see a female geoscientist take centre stage like this? I’m embarrassed by that. Kudos to AAPG for that decision.

Kudos which we have to partially revoke, unfortunately. Because the decision, if it was a decision, to change Alluvia’s skin colour in different situations is… well, it doesn’t look good. At best, it’s weird.

Fourth rule of criticism: be honest.

When I saw this dynamic duo, I rolled my eyes. Of course I did: I’m predisposed to criticize the technical societies and I’m a well-known marketing whiner. And as a scientist in Software Underground pointed out, it’s not targeted at me; she also found it uplifting. (Obvious in hindsight, but the whole point of my various privileges is that everything seems to be about me — it’s good to be reminded of our blindspots.)

But I’m trying to be positive here. I rolled my eyes because I think AAPG and the other societies can have a far-reaching and positive impact on our community, and on society. There is hard work to be done finding enough energy and raw materials for people to prosper.


The door is wide open

If AAPG wants to be part of the future, they have to figure out what ‘relevant’ means. Being relevant does not mean:

  • Promoting oil & gas exploration with dysmorphic Barbie & Ken super-hero cartoon characters.

  • Paywalled everything, especially journals and conference papers.

  • Awards named after men and given to mostly men. And don’t get me started on ‘Distinguished’ people.

  • Doing all the other things you’ve always done which have led you to feel ‘not relevant’ today.

I would urge AAPG and all technical societies to consider becoming more relevant in some new ways:

  • Understand that oil & gas, while certainly important to society today, needs to end. The sooner the better.

  • Realize that subsurface professionals can contribute to society, and industry, in hundreds of other ways.

  • See that this change is going to require a massive educational effort, both for us, and for society.

  • Believe that we need to massively broaden our community if we are to have the impact we can have.

  • Remove barriers to knowledge by committing to open access content and open data.

  • Remove barriers to participation by welcoming and representing everyone with equity and compassion.

The days of the hero explorer — tanned and lean, chiselled and serious, whacking stuff with hammers — are gone. Really, they never existed, or at least they were accompanied by a masculine monoculture and a total neglect for the environment.

The future can be different. Ms Hunt and Trap can be part of it. I believe we all can. But it’s going to require hard work, uncomfortable decisions, and abrupt, profound change. The door is wide open for AAPG, SEG, EAGE, and the other technical societies, if they would only notice.


What do you think? Are Trap & Alluvia just a bit of fun that might attract a new generation? Or do our technical societies need a lot more than cartoon heros and heroines? Let us know in the comments.