# Code Breaking: Bletchley Park and Bill Tutte

While brainstorming ideas for a blog post, I found myself wondering if math has ever directly saved lives. After looking into many options, I ran into a story about a place called Bletchley Park. It was known as the Fortress of Secrets and was said to have saved millions of lives yet didn’t even appear on any map. Nicknamed ‘Station X,’ it was solely designated for breaking codes, specifically ciphers. In World War II, direct communication between leaders and various units around the world was a big problem. These orders/war plans were coded and broadcast via wireless radio, but because they could be so easily intercepted, they became increasingly vulnerable. The solution to this problem was the cipher machine. Adopted in 1926, the Germans’ answer was called the Enigma.

A Lorenz machine. Image: Public domain, via Wikimedia Commons.

The Enigma was thought by the Germans to be unbreakable and safe for them to use. Its code was especially hard to crack because each time a key was pressed, its internal wiring was changed. In light of this, the British started to recruit brilliant mathematicians to engage in a battle to learn the enemy’s secrets. The Enigma machine required 6 people to operate, so Hitler ordered even more security. Thus, the Tunny cipher machine was born (also known as the Lorenz Machine). This machine generated code with its 12 wheels and only required two operators to send and receive information. To function, it would first apply two keys, encoding the message twice. The first cipher used 5 wheels with, the second used another 5, and then 2 additional wheels would cause a stutter of random letters that would try to throw off unauthorized decoders. Each wheel had a different number of spokes or choices on it which resulted in 23*26*29*31*37*41*43*47*51*53*59*61 = 1.6 million billion possible combinations!

Here is an example of coding one letter into another: The initial letter is “A,” and the cipher code is “K.” They would be “added up,” and if the corresponding symbol was different, then you would mark down an “x.” Inversely, if it was the same, then you would mark down a *. Here we can see A being coded into the letter N:

A= x x * * *

K= x x x x *

———————–

* * x x * = N

The code’s downfall began with the Germans’ overconfidence in the Tunny machine. A 4000 character message was sent, but the receiver didn’t quite get it, so a re-send was requested. The sender failed to change the wheel settings and re-sent the 4000 character message but it was slightly different. This provided Bletchley with a data set with which he could attempt to crack the code. John Tiltman, a mathematician who led the research department at Bletchley, initially worked on this break but passed it onto Bill Tutte.

Bill began by putting the 4000 word message into columns and made a rectangle out of it. He then looked for repetitions/patterns. Every 23 characters there was a rotation, but he then thought maybe it was 25. So he tried to multiply 23*25 to see if the pattern extends along that but it was inconclusive. But the pattern did extend along 574. He then thought maybe it was 41 as that is the prime number of 574. Resonance occurring after 41 strokes made him deduce that the first wheel had 41 spokes. He then went to the next wheel and so forth. Bill Tutte managed to diagnose how the machine worked without ever actually seeing the machine.

He also worked out a statistical mathematical method of breaking the Tunny code, called the “1+2 – break in method.” To use this decoding method required a massive amount of number-crunching and checking. This is where his co-worker Thomas Flower’s brilliance came into play. He conceptualized Bill Tutte’s method and produced one of the first computers, The Colossus, the world’s first semi-programmable computer completely invented from scratch. With this cracked code—and the computer to help crack it—huge battles were won. It is widely credited with turning the tide of the entire war.

World War II is estimated to have cost 10 million lives per year. Cracking the Tunny code was said to have shortened the war by at least two full years! However, everything involving these machines and ciphers had to be kept secret. The brilliant men involved could not publicly get credit for their achievements for quite some time. Eventually, the secrets were declassified, and Bill Tutte was awarded a membership of the Royal Society. In 1987, he finally signed his name in the Royal Society book where his signature lies alongside those of Isaac Newton, Charles Darwin, Winston Churchill.

Sources:

BBC Documentary: http://vimeo.com/31185786

http://www.bletchleypark.org.uk/content/hist/worldwartwo/enigma.rhtm

http://www.bbc.com/news/uk-england-suffolk-29064159

http://www.english-heritage.org.uk/bletchleypark