Read this lesson as text

Frequency Analysis

Cryptography · Axiom Academy

Breaking substitution ciphers by analyzing letter frequencies and patterns 1. Letter Frequency Distribution in English In English text, letters don't appear with equal frequency. Some letters like E , T , and A appear very frequently, while letters like Q , Z , and X are rare. 2. Al-Kindi's 9th Century Discovery Around 850 CE, the Arab mathematician Al-Kindi wrote "A Manuscript on Deciphering Cryptographic Messages," describing the first known frequency analysis attack. This breakthrough made simple substitution ciphers (like the Caesar cipher) completely insecure against skilled cryptanalysts. 3. Counting Letter Frequencies in Ciphertext To perform frequency analysis, we first count how often each letter appears in the ciphertext and calculate its percentage. 4. Matching Ciphertext to Expected Frequencies Once we have the frequency counts, we match the most frequent ciphertext letters to the most common plaintext letters. Find the most frequent letter in ciphertext → likely E Find the 2nd most frequent → likely T or A Look for single-letter words → must be A or I Use context and common patterns to refine guesses For our example KHOOR ZRUOG , the high-frequency letters O and R might represent L and O in the original message. 5. Digraph and Trigraph Analysis Beyond single letters, pairs (digraphs) and triples (trigraphs) of letters also have predictable frequencies in English. HE, AN, IN, ER, ON, RE, ED, ND AND, ING, HER, HAT, HIS, THA, ERE

This is the written version of the interactive lesson above. See the full Cryptography course.