I’ve written before about how the order in which books come my way often shapes what I get out of them. Recently, this peculiar phenomenon happened again. The last three books I’ve read all referenced the Monte Carlo method, a computational technique pivotal to the invention of the atomic bomb. Before encountering these books, I had only a vague awareness of the term. Now, through this serendipitous triangulation, I feel as though I’m beginning to grasp its essence.

The first appearance occurred in The MANIAC, Chilean author Benjamín Labatut’s lyrical account of John von Neumann and his circle. Labatut recounts how von Neumann’s friend, the Hungarian mathematician Stanislaw Ulam, stumbled upon the Monte Carlo method while convalescing in hospital after a life-threatening brain infection. Forbidden from thinking too hard, Ulam passed the time playing Solitaire:

The doctors had told him that he really shouldn’t think too much. He should make an effort not to think at all. If he put too much strain on his brain, he could very well die. So what did this wonderful mathematician do? He started playing patience. Solitaire with cards. So he plays one hand after another with his mind on idle, almost completely unengaged. In patience, you really don’t have to think, do you? There are no choices to make, it’s almost fully automatic, and yet he began to spot patterns—he came to see that he could predict, with at least some level of precision, the outcome of the game after just a few cards. So he analyzes that and comes up with the Monte Carlo method, which is essentially a computational algorithm, a way to make statistical guesses and solve complex problems not by actually working them out, but by making a series of random approximations. Say you want to know the probability of winning a game of patience with a particular shuffle of the pack: normally you would have to sit down and calculate, look at the problem abstracly, but with Monte Carlo, you would play out a very large number of these games—say, a thousand games—and from those results you could simply observe and count the number of succesful plays, and infer your answer from that information. Monte Carlo is a sort of weaponized randomness, a method to sift through overwhelming amounts of data in search of meaning, a way to make predictions and deal with uncertainty by modelling the many possible futures of complex situations and chose between the roads that branch out from ambiguous and unpredictable events. It’s unbelievably powerful and sort of humbling, or humiliating really, because it shows the limits of traditional calculations, of our rational and logical step-by-step thinking.

The MANIAC captivated me and left me eager to dive further into the world of John von Neumann, which led me to George Dyson’s Turing’s Cathedral.

The author of this book, the son of von Neumann’s colleague Freeman Dyson, chronicles the birth of modern computing and programming during the Manhattan Project. Here, the Monte Carlo method is described as follows:

Monte Carlo opened a new domain in mathematical physics: distinct from classical physics, which considers the precise behavior of a small number of idealized objects, or statistical mechanics, which considers the collective behavior, on average, of a very large number of objects, Monte Carlo considers the individual probabilistic behavior of an arbitrarily large number of individual objects, and is thus closer than either of the other two methods to the way the physical universe works.

There’s an obvious common denominator between The MANIAC and Turing’s Cathedral, but from there, I jumped genres and thoroughly enjoyed Chinese author Cixin Liu’s science fiction novel The Three-Body Problem. In this story, Monte Carlo resurfaces in the desperate efforts of an alien civilisation to survive the chaotic orbits of their three suns. Predicting these movements is a matter of life and death:

Have you heard about the Monte Carlo method? Ah, it’s a computer algorithm often used for calculating the area of irregular shapes. Specifically, the software puts the figure of interest in a figure of known area, such as a circle, and randomly strikes it with many tiny balls, never targeting the same spot twice. After a large number of balls, the proportion of balls that fall within the irregular shape compared to the total number of balls used to hit the circle will yield the area of the shape. Of course, the smaller the balls used, the more accurate the result. Although the method is simple, it shows how, mathematically, random brute force can overcome precise logic. It’s a numerical approach that uses quantity to derive quality.

I still can’t claim to truly understand the Monte Carlo method—I doubt I ever will without more mathematical grounding. Yet, I’m struck by how even such a deeply technical concept can be intuitively appreciated when seen through different lenses. Serendipity, it seems, can be an excellent teacher.