Ciphers and Matrices: The Hill Cipher

Lester S. Hill created the Hill cipher, which uses matrix manipulation. With this we have a matrix operator on the plaintext:

Ciphers and Matrices: The Hill Cipher

Lester S. Hill created the Hill cipher, which uses matrix manipulation. With this we have a matrix operator on the plaintext:

which is used to encode, and then the decoder is the inverse of this:

For example we take the matrix:

Then the reverse will be:

We thus use the first matrix (A) to encode two characters at a time, and then use the inverse of the matrix to decode. Initially we take our characters from the plaintext in two letters at at time. For example for “hello” we have “he”, “ll”, and “o “. Next we look at our table (where a space is replaced with a #):

So for the message “hello”, we take two characters at a time, such as “he” becomes [7,4], and multiply by the matrix given above:

We then do a (mod 27) on the result to get:

This will be a cipher of “#O”. A basic calculator is here.

Now take this Hill cipher challenge: