Using a 7-bit Hamming code with even parity, number bit positions from right…

2010

Using a 7-bit Hamming code with even parity, number bit positions from right to left as 1 through 7. Place parity bits at positions 1, 2, and 4, and map the data bits 0011, from left to right, to positions 7, 6, 5, and 3. What is the encoded codeword, written as positions 7 through 1?

Answer: A. 0011110ConceptA Hamming(7,4) code stores four data bits and three parity bits. With the usual position numbering, parity bits occupy positions 1, 2, and 4. For even…

  1. A.

    0011110

  2. B.

    0101110

  3. C.

    0010110

  4. D.

    0011100

Attempted by 38 students.

Show answer & explanation

Correct answer: A

Concept

A Hamming(7,4) code stores four data bits and three parity bits. With the usual position numbering, parity bits occupy positions 1, 2, and 4.

For even parity, the parity groups are: p1 checks positions 1, 3, 5, 7; p2 checks positions 2, 3, 6, 7; and p4 checks positions 4, 5, 6, 7. Each group must contain an even number of 1-bits.

Application

  1. Map data bits 0, 0, 1, 1 to positions 7, 6, 5, 3. In positions 7 through 1, the incomplete word is 0 0 1 p4 1 p2 p1.

  2. For p1, positions 3, 5, 7 contain 1, 1, 0: two 1-bits are already present, so p1 = 0.

  3. For p2, positions 3, 6, 7 contain 1, 0, 0: one 1-bit is present, so p2 = 1 makes the count even.

  4. For p4, positions 5, 6, 7 contain 1, 0, 0: one 1-bit is present, so p4 = 1 makes the count even.

  5. Substituting the parity bits gives positions 7 through 1 as 0 0 1 1 1 1 0. Therefore, the encoded codeword is 0011110.

Cross-check

In 0011110, each check group contains two 1-bits: positions (1,3,5,7), (2,3,6,7), and (4,5,6,7) all have even parity. The codeword therefore satisfies all three parity checks.

Explore the full course: Nta Ugc Net Paper 2

Loading lesson…