### Warm-up:

Secret message decoders

(care of www.treasuretrails.co.uk)

### The Problem:

HZMMT XCMDNOHVN VIY V CVKKT IZR TZVM

-/|\-

### Solution:

Decoding encrypted messages is part mathematics and part investigation.

There is a clue in the title of this problem: Festive.

This might inspire us to make a good guess as to the meaning of the message.

Continuing the investigation, we might conclude that this message contains seven words and that the forth is either an **A** or an **I**. These being the most common single letter words.

There are two three letter words. However, that doesn't narrow it down too much as there are 17576
$\left({26}^{3}\right)$combinations of three letters.

This however coupled with the idea that **V** is either **A** or **I**, we might conclude that **VIY** is **AND**.

Let's now see if we can make sense of this with some mathematics.

So far, we have:

V | → | A |

Y | → | D |

I | → | N |

Look at **I** → **N** we've moved five letters on from **I** to get **N**.

So let's try this idea with **V**. By moving five letters on from **V** we go one beyond the end of the alphabet.

By thinking of the alphabet as a continuous line of alphabets, one after the other, the next letter would be **A** which is correct.

So, it seems that we move five letters up the alphabet to get the real letter. If we drop of the end of the alphabet, we just wrap around to the beginning again.

Now we have a method (an algorithm) that we think might work, what does it decode the message to?

MERRY CHRISTMAS AND A HAPPY NEW YEAR

Definitely a festive message.

Here's the full decoding algorithm.

Encrypted Message Character | V | W | X | Y | Z | A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | U | $\alpha $ |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|

Maps to ... | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ | ↓ |

Real Message Character | A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | U | V | W | X | Y | Z | $\beta =\alpha +5$ |

The last column is the algorithm that gives the entire algorithm in one easy equation. In this case it is extremely easy and so not difficult to break.

In general, the more complex this algorithm is the more difficult it is to break the code,

but we must be careful not to make the algorithm too complex or it'll be too time consuming to for the intended reader to get the message.

Coding is also easy as it's the inverse action of the decoding algorithm.

Have some fun making your own code or see encryption to learn more.

-oOo-