Mathematical modelling: Cracking codes
View Sequence overviewInvestigating a problem in context allows us to consider how mathematics might be used as a tool to help solve the problem.
By finding and identifying patterns in language, we begin to recognise how mathematics can be used as a tool to decipher codes.
Lesson
Introduce substitution ciphers to the students. Explain that in substitution ciphers each letter of the alphabet is replaced with another letter, character, or symbol. Every occurrence of a letter is replaced with the same symbol. For example, every occurrence of the letter ‘a’ in a passage could be replaced by the symbol ‘£’.
Provide pairs or small groups of students access to computers or tablets. Ask them to decipher the substitution codes in the ASD Code Breaker challenge on the Australian Signal Directorate’s (ASD) website.
In the ASD Code Breaker challenge, a substitution cipher has been used to code passages of text which relate to the themes and stories of the ASD’s history in cryptography. The challenge starts off with easier codes and gets progressively harder. The TACTICS button at the side of the page suggests some strategies that students might use. Encourage students to have a go at deciphering the codes before clicking on the TACTICS button.
Conduct a class discussion: What strategies did you use to help decipher the messages? How helpful were your different strategies?
Create a class list of the different strategies that students used, such as letter frequencies, common words, and common letter patterns. The professional learning Code breaking strategies embedded below describes common word and letter patterns that can be used to help decipher codes.
Code breaking strategies
Patterns are at the heart of mathematics.
Mathematics is built on structure, which emerges from identifying, making sense of, and working with patterns. We can see patterns all around us, including in written language.
We can decipher encrypted messages by recognising and using the patterns we notice in written language.
The following are patterns that can be used to identify potential mappings between ciphertext and English plaintext.
Frequency of letters: The letter e is the most frequently occurring letter in the English language, while j, x, and z are used the least. In general vowels occur more frequently than consonants.
Digraphs and trigraphs: Some digraphs (two letter combinations) and trigraphs (three letter combinations) appear more frequently than others:
- Common digraphs include: th, er, on, an, re, he, in, ed, and nd.
- Common trigraphs include: the, and, tha, ent, ion, and tio.
Short words: Shorter words are useful clues when deciphering codes:
- The only single letter words are I (which is only used in uppercase form) and a.
- The most common two letter words are of, to, in, it, is, be, as, at, and so.
- The most common three letter words are the, and, for, are, but, not, and you.
Vowels: With very few exceptions all words have at least one vowel. Exceptions include words like by, fly, and sky where the y does the work of a vowel.
End of words: Some letters are very rarely found at the end of a word, such as q, v, o, u, and c.
Double letters: Common double consonants within words include ss, ll, pp, nn, tt, and ff. At the end of a word, the most common double consonants are ss and ll. The most common double vowels are ee and oo. aa, ii and uu do exist in rare cases, including aardvark, skiing, and vacuum.
Suffixes and prefixes: Common suffixes include tion, ing, ance, ence, ness, ly, and ful. Common prefixes include in, un, bi, and tri.
The Exploratorium has an excellent page on cryptography, which shares further letter patterns that can be used to decipher codes.
Patterns are at the heart of mathematics.
Mathematics is built on structure, which emerges from identifying, making sense of, and working with patterns. We can see patterns all around us, including in written language.
We can decipher encrypted messages by recognising and using the patterns we notice in written language.
The following are patterns that can be used to identify potential mappings between ciphertext and English plaintext.
Frequency of letters: The letter e is the most frequently occurring letter in the English language, while j, x, and z are used the least. In general vowels occur more frequently than consonants.
Digraphs and trigraphs: Some digraphs (two letter combinations) and trigraphs (three letter combinations) appear more frequently than others:
- Common digraphs include: th, er, on, an, re, he, in, ed, and nd.
- Common trigraphs include: the, and, tha, ent, ion, and tio.
Short words: Shorter words are useful clues when deciphering codes:
- The only single letter words are I (which is only used in uppercase form) and a.
- The most common two letter words are of, to, in, it, is, be, as, at, and so.
- The most common three letter words are the, and, for, are, but, not, and you.
Vowels: With very few exceptions all words have at least one vowel. Exceptions include words like by, fly, and sky where the y does the work of a vowel.
End of words: Some letters are very rarely found at the end of a word, such as q, v, o, u, and c.
Double letters: Common double consonants within words include ss, ll, pp, nn, tt, and ff. At the end of a word, the most common double consonants are ss and ll. The most common double vowels are ee and oo. aa, ii and uu do exist in rare cases, including aardvark, skiing, and vacuum.
Suffixes and prefixes: Common suffixes include tion, ing, ance, ence, ness, ly, and ful. Common prefixes include in, un, bi, and tri.
The Exploratorium has an excellent page on cryptography, which shares further letter patterns that can be used to decipher codes.