Early on we had thought of the book ``Fermat's last theorem'' by Simon Singh as the potential keytext. We had also thought about texts by Pierre de Fermat. During a game of the board game Othello between Lars and Gunnar, the famous marginal note by Fermat was suggested as a potential keytext. The objection was raised that this text surely must be too short, but to settle the question we searched for the text on the Internet. It turned out that the text was too short for the word counting approach, but had the right length for letter counting. After having tried an English and a French version, we stumbled over the text in Latin which turned out to be the original language. This text is as follows.
Cubem autem in duos cubos, aut quadratoquodratum in duos quadratoquadratos, et generaliter nullam in infinitum ultra quadratum potestatem in duos eiusdem nominis fas est dividere. Cuius rei demonstrationem mirabilem sane detexi hanc marginis exiguitas non careret.
Feeding this text into the letter counting program cwizard gave the following result.
sandman> cwizard < Fermat.latin.txt > Fermat.latin.out Building trie... Done 225: PLAIFAIRCIPHERESELPROXIMONIVELLAPALABRASECRETAESILLIAD P(0)LAI(3)FAIR(4)CIPHER(6)ESEL(0)PROXIMO(7)NI(0)VELL(4)APA(3) LABRA(5)SECRETA(7)E(0)SILL(4)IAD(0)
We observe that we had a bit of luck here. Even though the plaintext was in Spanish there were enough English words in the text for our program to classify it as a candidate text. If we format the text properly we get
Playfair cipher es el proximo nivel. La palabra secreta es Illiad.The keyword for this stage is thus ILLIAD.