TaraGurung
TaraGurung

Reputation: 135

Error detection and correction

My message bit is 10011010, so code word for this is 0110 and now the codeword is 011100101010.

Suppose the error is in 10th bits and it becomes 011100101110, so finding parity bits:

p1=1+3+5+7+9+11=010111=even number of 1 therefore=0
p2=2+3+6+7+10+11=110111=1
p4=4+5+6+7=1001=0
p8=8+9+10+11+12=01110=1

Comparing with the message the parity is false for 4 and 8 position ie 4+8=12, but in fact we have made errors in 10 bit. Where have I made a mistake?

Upvotes: 0

Views: 815

Answers (1)

Qiu
Qiu

Reputation: 5751

It works a little bit different. When you check parity, you don't use parity bits to count it (you count them now). So:

p1 = 3+5+7+9+11 = 10111 = 0 (OK)
p2 = 3+6+7+10+11 = 10111 = 0 (WRONG)
p4 = 5+6+7 = 010 = 1 (OK)
p8 = 9+10+11+12 = 1110 = 1 (WRONG)

So 2+8 = 10.

Upvotes: 1

Related Questions