Error control, Hamming codes and CRC
A channel code selects a subset of possible transmitted bit patterns. Distance determines guaranteed detection and correction; a parity-check matrix implements a syndrome test. CRC is usually used to detect errors, not to identify which bit to correct.
9.1 Linear block codes and distance
Past papers · EC 2020–2026 (7 papers): 2 questions, 3 marks
All arithmetic in this chapter is over unless stated otherwise: addition and subtraction are XOR, and . Use row vectors for messages and codewords. An code carries information bits in coded bits.
The XOR of codewords is a codeword. With generator rows, enumerate all nonzero row combinations to find ; the smallest individual row weight alone is insufficient. Equivalently, is the smallest number of columns of whose XOR is zero. A zero syndrome means a valid codeword was received, not proof that no error occurred.
9.2 Hamming construction and block error
Past papers · EC 2020–2026 (7 papers): 3 questions, 5 marks
A binary Hamming code uses every nonzero -bit column once in its parity-check matrix. A single-bit error has the syndrome equal to the corresponding column, so the decoder can identify its location.
Adding an overall even-parity bit to a Hamming code yields extended Hamming parameters and , enabling single-error correction and double-error detection. Ordinary Hamming codes can detect two errors if used only for detection, but a decoder that automatically corrects a nonzero syndrome can miscorrect a two-bit error.
9.3 Cyclic redundancy check
Past papers · EC 2020–2026 (7 papers): 1 question, 2 marks
Represent the leftmost transmitted bit by the highest polynomial power. A generator of degree has coefficient bits. The appended CRC contains exactly bits, including leading zero remainder bits.
Last-minute recall
- Binary code arithmetic uses XOR, not integer addition.
- Linear-code minimum distance is the minimum nonzero codeword weight.
- Generator and parity-check matrices obey .
- A syndrome locates a single error only under the decoder's error model.
- Hamming codes correct one error; extended Hamming can also flag two.
- Block failure needs an error-count distribution, not BER alone.
- CRC division starts after appending degree-many zero bits.
- A zero CRC remainder does not rule out an error polynomial divisible by the generator.