# Transcript

ALLAN JONES
Hello, again. I’m Allan Jones, and I'm talking now to David Chapman, who produced the material in Section 2 of this course. Hello, David.
DAVID CHAPMAN
Hello.
ALLAN JONES
With digital data, two important concepts relating to its representation and transmission are source coding and channel coding. First of all, what is source coding?
DAVID CHAPMAN
Source coding is about representing a source, such as text, audio, pictures or video, by patterns of binary bits. So with a text file, we need some way of representing the letters of the alphabet by patterns of bits. The so-called ASCII code is one standardised way of doing that, using seven binary bits for each character.
For example, in ASCII code, the letter A is coded to 1100001, and the letter B is coded to 1100011. Anything we want to send over a digital communication system must first be coded like this, be it text, audio, or whatever.
ALLAN JONES
OK, so what’s channel coding.
DAVID CHAPMAN
Having got the source represented by bits, we might need to send those bits over a communication channel. But there are things you can do with the bits before turning them into waveforms on the channel, things that can make the communication work better. This is channel coding. It consists of taking bits or groups of bits and changing them into different groups of bits.
So for example, the ASCII code for the letter A, which as I said before, is 1100001, might be changed by adding an extra digit, a one in this case, at the end. With the added digit, what we now call the code word, becomes 11000011.
ALLAN JONES
OK, so the net effect of that is you’ve turned a representation of A that used seven binary digits into one that uses eight. So what do you gain by doing that?
DAVID CHAPMAN
Well, what we gain is the possibility of error control. And in fact, you could say that the main job of channel coding is error control. Error control consists of either error-detection or error-correction. Error-detecting codes enable the receiver to work out if there’s been any errors in transmission. Error-correcting codes go further and enable the receiver to correct errors that have arisen in transmission.
Adding the one bit to the ASCII code is an example of an error-detecting code known as a parity check. The added digit is chosen so as to ensure that the number of ones in the code word is even. So in this example, there were originally three ones in the ASCII code for the letter A, and that’s an odd number. Adding another one at the end increases the number of ones to four, which is an even number. With the parity check in place, it’s possible to tell if there’s been a single error in transmission, because a single error anywhere in the code word will result in the received code word having an odd number of ones.
ALLAN JONES
OK, you’ve mentioned error-correcting codes as another branch of error control. Error-correction enables the receiver itself to fix errors that arise in transmission without the need to request re-transmission. That sounds too good to be true. So how is it possible?
DAVID CHAPMAN
Actually, it’s quite easy to see one way to do error-correction. Just send every bit three times. So instead of one, you send three ones, 111. Instead of a zero, you send 000. So what’s transmitted consists entirely of groups of three ones and three zeros. If there’s an error in a group of three ones, the receiver will get two ones and a zero instead.
Alternatively, if there’s an error in a group of three zeros, the receiver will get two zeros and a one instead. In either case, you can correct the error by taking a majority decision. A group of two zeros and a one was meant to be three zeros. A group of two ones and a zero was meant to be three ones. Something to notice here is that, once again, error control has required extra bits to be added, as with error-detection.
ALLAN JONES
So if you can correct errors, why bother trying to avoid them?
DAVID CHAPMAN
Error control, whether it’s error-detection or error-correction, has its limits. Error-correcting codes can't correct an unlimited number of errors. If you get too many errors in a period of time, the error-correcting properties of the code are defeated. That means some errors can still sneak through without being spotted by error-detecting codes.
Furthermore, you pay a price for using error-control codes. You'll always need extra bits, such as the addition of the parity bit to the ASCII code that I mentioned before or the tripling of the number of bits by sending every bit three times to get error correction. In that sense, there’s a reduction in efficiency with error control. Advanced error-correcting codes aren’t as inefficient as the example of tripling the number of bits, but they do still require significant numbers of extra bits.
ALLAN JONES
Well, thanks, David.