How Sherlock Solved "An Encirclement Thwarted"
Dearest detectives,
Happy New Year and welcome to the roaring ‘20s. Last month, Dear Holmes detectives worked to crack a German war-time code and helped Sherlock thwart enemy treachery. Sherlock long ago mailed his solution to “the Encirclement Thwarted” to detectives, but nevertheless we’re thrilled to share it here as well. Did you crack the code and solve the mystery?
To our new detectives, we hope you’re enjoying the start of your first mystery, and we encourge you to submit your thorough solution to it by February 5th at Dearholmes.com/solve. The detective who shares the most thorough, accurate, timely, and compelling solution will be named our “Featured Detective”, and awarded a special Detective’s Prize. And now, without further ado, here is Holmes’s solution to last month’s mystery.
Sincerely yours,
The Dear Holmes Team
———
221 b Baker Street
Marylebone
2 August 1914
Dear Mr. Gregson and Mr. Asquith,
The letter that follows sets out the meaning of the coded messages you have brought to my attention and is an urgent call to action for the prime minister.
The key message is that the Germans will attack Belgium at 4 am on 4 August, striking at Liege and Namur before swinging south to Dinant.
I would beg Mr. Asquith to spare not a second in advising our French allies of this plan. I would also plead with him to give the Germans no reason to think that their code has been decrypted. To this end, he must give the Germans an alternative reason for why their plans have been uncovered. I would suggest the use of spotter ‘planes over German territory who might be expected to pick up troop movements at the German/Belgian frontier.
I wish the Prime Minister God’s speed is fulfilling the commission above and the rest of the letter that follows is an appendix to the foregoing for Mr. Gregson’s elucidation. It must not for a second stand in the way of the action the Prime Minister should take immediately on receipt of this letter which I have despatched by London messenger.
As an elaboration to the above I would note that my chronicler, the good Dr. Watson, will doubtless one day soon publish the account of my work today when we took prisoner the chief of staff of Germany’s spy network in this country, Count von Bork.
We drove von Bork to London this evening and he sits in the cells of Scotland Yard. Watson has already asked me whether he can call the work His Last Bow. But criminals of all sorts should be aware that, even in retirement on the South Downs I remain eager for more cases and solving this first one will be the first of what I hope are a lot of cases solved after what was meant to be my last bow
Once we had delivered the Count, it was too late to return to Sussex but Dr. Watson and I, I am pleased to say, have repaired to our old rooms at Baker Street where Mrs. Hudson has kindly found space for us.
The matter Mr. Gregson had brought to my attention is a simple one to solve but its solution has only the gravest consequences for the life of the world.
In his published works my friend, Dr. Watson, has two accounts of me cracking replacement codes - in The Dancing Men and again in The Red Circle which you refer to in your first letter.
As you will see, The Red Circle is relevant to the solution to this problem, but I will start with what was the cracking of another mystery - that of the reason why Jack Stapleton had a motive in killing Sir Charles Baskerville and trying to kill the baronet’s nephew, Sir Henry Baskerville in The Hound of the Baskervilles. It was when I was at supper in Baskerville Hall that I saw the resemblance of Stapleton not only to Sir Henry Baskerville but also to the black sheep of the Baskerville family, Hugo Baskerville of the seventeenth century. I said to you then that the true detective must have trained his eyes to examine faces and not their trimmings.
This is a very relevant point to the matter before us.
We have assumed a replacement code, but we have assumed it is based on character-sets of three characters. Yet these provide no pattern to aid the decryptor.
I would adduce the following to indicate why the commas - trimmings to aiding the eye of the reader - mislead rather than aid the decryptor’s eye.
The messages are too short to have meaning. There must be more data conveyed in them than could be conveyed in messages that are only a maximum of thirteen characters long.
The number of numeric characters in each message is always divisible by three except in one case where an X is added at the end. To me this X is present to make the message conform to a number pattern.
Let us therefore consider what we get if we assume that the commas should in fact fall after every second character.
Such a message would reflect a significantly larger number of letters and hence considerably more information.
The first two messages are below
95,23, 95, 23,95, 23
31, 16, 97, 16, 41, 97
Even in the two character-set format, these do not convey very much meaning although the repetition of 95 and 23 and of 16 and 97 suggests that these are indeed letters and that this represents the direction to follow.
Let us therefore try the same methodology on the next two messages
The third message becomes thus.
31, 64, 97, 31, 33, 27, 83, 97 ,23 ,83 ,97 ,53 ,58 ,31 ,93 ,88X
We now see a repetition of characters and it is also obvious that the X is superfluous. The two 31’s and the 97’s. just as obviously, reflect the two “A’’s” and the two “T’s” of Altamont.
With this number of characters – including all those from the name Altamont – we are probably in a position to crack the whole code quite quickly, but I then wondered if there was a way of doing it at all at once.
Humans, when apparently selecting numbers at random, always display a bias and this code would be far harder to crack if the numbers were truly random.
A happy thought than struck me when I saw that the A at the beginning of Altamont – repeated at character-set four of the message – was 31. I realised that Pi – the irrational number giving the ratio of the circumference of a circle to its diameter - had been used to generate the random numbers for the code - which could therefore be expressed as follows.
A: 31
B: 41
C: 59
D: 26
E: 53
F: 58
G: 97
H: 93
I: 23
J: 84
K: 62
L: 64
M: 33
N: 83
O: 27
P: 95
Q: 02
R: 88
S: 41
T: 97
U: 16
V: 39
W: 93
X: 75
Y: 10
Z: 58
Armed with this insight, I could decipher the five messages and the reasoning behind them as follows:
Pi, pi, pi – this must have been a pre-arranged signal to selected senior German officials that the pi code, as must have been communicated to them previously, was about to be used to carry exceedingly sensitive messages.
August – this told the senior German officials the month when an attack was likely to take place. It is notable under the above code that “G” and “T” are the same although this weakness should not be a major obstacle to the code’s use.
Altamont in Gefahr – means Altamont in peril. Your bait worked, Mr. Gregson, but you had no way of recognising it.
Lüttich (German for Liège), Namur, Dinant -communication of the direction of the planned German advance
Der vierte August and um null vier null null – being the date and time of the first assault – 4 August at 4 o’clock in the morning.
Historical note by Howard Durham – former reader in History at King’s College London and adviser on matters of history to the editors of The Redacted Sherlock Holmes
I came across the papers of Dr. Watson and Sherlock Holmes at the public record office in Kew in the summer of 2015 and am still in the process of editing them for publication.
The revelation that Sherlock Holmes identified the German plans for their strike to the west in August 1914 explains much of what followed.
The Belgians, tipped off by the French and the British, conducted a most gallant defence of Liege and Namur, which had been heavily fortified over previous years.
This delayed the Germans in getting through to northern France and gave the French the time to build up their own defences. Had the Belgians been routed in the first days of August 1914, it is likely that the Germans would have broken through to Paris by the end of the month.
It is thus not too much to say that the cracking by Sherlock Holmes of what I shall call the pi code, while not preventing the war or ensuring a victorious outcome, did ensure that an early defeat for the Entente powers (France, Great Britain and her empire) was averted.