• Roge Velez Mendoza

Alan Turing and How the Brain Uses Statistics to Make Decisions

When facing simple, unconscious decisions, the brain applies the same statistical method Turing used to break the Enigma code.

"Choosing" by George Frederic Watts
"Choosing" by George Frederic Watts. © National Portrait Gallery, London

When faced with a simple, fast, and mostly unconscious decision—for example, going around a table by one side or the other, moving your foot from the gas to the brake pedal in a potentially dangerous situation, or finding a way to prevent that baseball coming at you at 120 km/h from breaking your skull—our brains are applying the same basic statistical method Alan Turing used to break the Enigma code.


Well, maybe not ours, but Rhesus monkeys’ brains (but no worries, the physiological resemblance between macaques and humans has been quite helpful for science). A few years ago, a team of researchers led by Michael N. Shadlen of the Zuckerman Mind Brain Behavior Institute at the University of Columbia showed that when facing those fast, unconscious (sometimes lifesaving) decisions, the brain gathers information and adds positive and negative points to each available option. It continues to do so until it reaches a threshold where it is confident enough to make a decision.


I came across Shadlen’s research a while back but decided to revisit it after watching this fascinating presentation on “Jazz and the Neuroscience of Decision Making.” As a jazz fan and a science enthusiast, the title of the 2019 presentation immediately caught my attention. The show explored a few themes—both musical and scientific—related to decision making, the perception of time, and their relation to music.


The comparison between decision-making and code-breaking is not new and has received some media attention. But after watching the 2019 presentation, I felt the need to review this research and understand its significance for myself. It is also not a coincidence that I am writing around the 70th anniversary of Turing’s election as a Royal Society Fellow.


Turing was elected as a Royal Society Fellow on March 14, 1951.

Statistical Methods to Win Wars


What does Alan Turing has to do with how our brains make decisions? One of the British mathematician’s most outstanding achievements was his success in leading the team that cracked the German Enigma machine code during World War II. Turing and his cryptanalyst colleagues at Bletchley Park built a machine called “bombe” which analyzed the sequences of letters of encrypted messages to reveal valuable information. Yes, I know, we’ve all seen the movie.


The thing is, each of these encoded messages emerged from a machine with 150 million, million, million permutations that changed every one or two days. This type of encryption produced too many possibilities, even for a decoding machine. The work of the “bombe” (which in reality was an adaptation of a previous Polish design) was only part of the process. The cryptanalysts had to complement the deciphering process with a few manual techniques to help the machine do its work faster.


An Enigma Machine. Note the rotors, keys and wires. Photo: Michael Shadlen and Walker Library of the History of Human Imagination.

One of those complementary and crucial manual tasks was to find two messages that had been encrypted with the same Enigma settings. The team came up with a statistical test to determine whether two random messages were compatible enough to assume they originated from a particular Enigma configuration.


The work of the “bombe” (which in reality was an adaptation of a previous Polish design) was only part of the process

Being aware that in a particular language some letters are used more often than others, the cryptoanalysts noticed that the frequency of different characters in a message was not altered after it had been coded by the Enigma. In English, for example, the most common letter is E, followed by T and A; the least popular ones are Q and Z (that’s why they are worth 10 points). The Bletchley Park group also figured that some words would be repeated in messages more often than others (e.g. "Heil Hitler") and that the machine never coded a letter to itself (A to an A).


The test compared two encrypted messages, which were just an unintelligible string of random characters at this point. The two communications were analyzed statistically by aligning them next to each other and assigning a value to each pair of letters. If two letters matched, it was given a positive point; if not, a negative one. The two strings of letters could be compared starting in any position. After the sum of positive and negative points reached a threshold, it could be determined whether the pair was a match or not.



Turing called this process Banburismus because the pieces of cardboard used for this were made in Banbury, England. But the essence of the technique is now called Wald’s sequential probability ratio test, named after mathematician Abraham Wald. (If you ask me, Banburismus is much more fun to say.)


Alan Turing. Image: National Portrait Gallery, Londres. (Wikipedia).

Monkey Brains


Now, it turns out neurones in Rhesus monkeys' brains make the same sequential probability analysis when faced with a decision. Dr. Shadlen has been experimenting with this neural behaviour for some time now. Some of his related publications stemmed from his work as Professor of Neurology at the University of Washington and later as a Professor at Columbia and member of the Mortimer B. Zuckerman Mind Brain and Behavior Institute.


In his research, Shadlen recorded the cerebral activity of two monkeys when they made simple decisions. For example, after watching a sequence of symbols on a computer screen, flashing one after another for just 250 milliseconds, the primates had to choose between two places to receive a succulent treat. To make the right decision, the monkeys had to identify different clues among the symbols on the screen. Some of them were meaningless, while others would lead them to the treat.


Mother Rhesus macaque with her baby in Nepal. Photo by Shadow Ayush / CC BY-SA 4.0

When the symbols appeared on screen, the system recorded the neuronal activity to discover how the decisions were made. The brain assigned each symbol with a “positive“ value (food is on the right) or a “negative” one (food is on the left). Curiously enough, this was possible to detect because the velocity in which the neurons were fired varied according to the level of confidence in the clues. The most trustworthy symbols had a more substantial impact on the neurons than the others.


Just like Turing’s Banburismus system, when the brain reached a threshold of positive or negative values, the decision was complete, and it was snack time.


To Shadlen, this result is transferable to human brains. Our brains are continually considering the several possibilities presented to us and making those decisions in a very short time, mostly unconsciously.


Beyond the Decisions


This research suggests that the decisions we make every day are based on a simple statistical analysis to find the most convenient outcome. But its implications to understanding human behaviour and evolution are even more significant.


This type of involuntary, unconscious decision-making process seems to have evolved to reduce the burden of the constant stimulation from the environment around us on the thought process. Processing direct and nonstop information from our surroundings “in the background” has granted us what Shadlen calls “freedom from immediacy.“


Processing direct and nonstop information from our surroundings “in the background” has granted us what Shadlen calls “freedom from immediacy.“

“All of the mental things you do depend on having this freedom not to be beholden immediately to changes in the world or the real-time need to control your body,” commented Shadlen in 2019. “It’s that escape from that reflex-like behaviour that led to cognition.”


In a way, being able to make all those statistically-driven, unconscious decisions allowed us to focus on other thoughts and perhaps led us to the ability to wonder, to remember, to learn, and to know.