50 Mathematical Ideas You Really Need to Know

(Marcin) #1

40 Codes


What does Julius Caesar have in common with the transmission of modern digital
signals? The short answer is codes and coding. To send digital signals to a computer or a
digital television set, the coding of pictures and speech into a stream of zeros and ones



  • a binary code – is essential for it is the only language these devices understand.
    Caesar used codes to communicate with his generals and kept his messages secret by
    changing around the letters of his message according to a key which only he and they
    knew.


Accuracy was essential for Caesar and it is also required for the effective
transmission of digital signals. Caesar also wanted to keep his codes to himself as
do the cable and satellite broadcasting television companies who only want
paying subscribers to be able make sense of their signals.
Let’s look at accuracy first. Human error or ‘noise along the line’ can always
occur, and must be dealt with. Mathematical thinking allows us to construct
coding systems that automatically detect errors and even make corrections.


Error detection and correction


One of the first binary coding systems was the Morse code which makes use of
two symbols, dots • and dashes –. The American inventor Samuel F.B. Morse
sent the first intercity message using his code from Washington to Baltimore in



  1. It was a code designed for the electric telegraph of the mid-19th century
    with little thought to an efficient design. In Morse code, the letter A is coded as •



  • , B as – •••, C as – • – • and other letters as different sequences of dots and
    dashes. A telegraph operator sending ‘CAB’ would send the string – • – • / • – /

  • •••. Whatever its merits, Morse code is not very good at error detection let
    alone correction. If the Morse code operator wished to send ‘CAB’, but mistyped
    a dot for a dash in C, forgot the dash in A and noise on the wire substituted a
    dash for a dot in B, the receiver getting •• – • / • / –– ••, would see nothing
    wrong and interpret it as ‘FEZ’.
    At a more primitive level we could look at a coding system consisting of just 0
    and 1 where 0 represents one word and 1 another. Suppose an army
    commander has to transmit a message to his troops which is either ‘invade’ or

Free download pdf