Consider a parity check code with three data bits and four parity check bits.…
2004
Consider a parity check code with three data bits and four parity check bits. Three of the code words are 0101011, 1001101 and 1110001. Which of the following are also code words?
I. 0010111 II. 0110110 III. 1011010 IV. 0111010
- A.
I and III
- B.
I, II and III
- C.
II and IV
- D.
I, II, III and IV
Attempted by 72 students.
Show answer & explanation
Correct answer: A
Key idea: the code is linear, so the bitwise XOR of any codewords is also a codeword.
Given codewords: 0101011, 1001101, 1110001.
Compute XOR of 0101011 and 1110001: 0101011 ⊕ 1110001 = 1011010. Therefore the string 1011010 is a codeword.
Compute XOR of all three: 0101011 ⊕ 1001101 ⊕ 1110001 = 0010111. Therefore the string 0010111 is a codeword.
The full set of linear combinations (the span) of the given codewords is: 0000000, 0101011, 1001101, 1110001, 1100110, 1011010, 0111100, 0010111.
Conclusion: among the candidate strings, 0010111 and 1011010 are in the code; the other two candidates are not.