Digraph Substitution Ciphers
Digraph Substitution Ciphers are similar to Monoalphabetic Substitution Ciphers, except that instead of replacing individual letters in the plaintext, they replace pairs of letters with another pair of letters (or digraph).
In its simplest version a grid like the one below can be used to find a new pair of letters to use in each substitution. For example, to encipher the digraph "he" you find "h" across the top, and "e" down the side, and where these two intercept is the new digraph "NY".
When using a Digraph Substitution Cipher, the first step is to split the plaintext up into digraphs. Each of these will then be enciphered using a grid like the one above into a new digraph. If there is a lone letter, then we must add a null letter to form a digraph, and this is usually "x".
For example, let's encrypt the plaintext "simple example". First of all we must split the plaintext into digraphs: "si mp le ex am pl ex". Notice that we have added an "x" on the end to make sure the lone "e" forms part of a digraph. Now we use the grid above to encrypt each digraph in turn. We get the table below.
So our ciphertext is "RJYDNCGVVRUGGV", which could be split into groups of 5 "RJYDN CGVVR UGGV" or split to match the original structure "RJYDNC GVVRUGGV".
Of course, we need a way to come up with the digraph substitution table. The easiest way is to use two Caesar Shifts. One of these dictates the first letter of the digraph, and the other the second letter. Also, one letter changes across the columns, whilst the other remains the same, and the other changes down the rows, whilst the former remains constant. Can you spot this pattern in the table above?
In a similar way we could use any mixed alphabet to create the two parts to each digraph within the grid. If we use the keywords mixed and alphabet then we use the keyword mixed to create the mixed alphabet to go down through the rows, and the keyword alphabet to create the mixed alphabet to go across the columns. Finally we combine the two letters within each box to create a digraph (we must decide which way round the letters are combined).