• edited by
21,579 views
53 53 votes
Consider a $3$-bit error detection and $1$-bit error correction hamming code for $4$-bit data. The extra parity bits required would be _____ and the $3$-bit error detection is possible because the code has a minimum distance of _______.

7 Answers

Best answer
60 60 votes

The Hamming distance between two-bit strings is the number of bits that would have to be flipped to make the strings identical.

To detect $d$ errors we require a minimum Hamming distance of $d + 1$.

Correcting $d$ bit flips requires a minimum Hamming distance of $2\times d + 1,$ where $d$ is number of bit in errors.

 For the first blank, each error detection we need $1$ parity bit

For $3$ bit error detection we need $3$ parity bits. So, $3$ parity bits requires here. 

Also, we can calculate this way, formula is $d+p+1 \leq 2^p$ where, $d=$ data bits , $p =$ parity bits , $d=4$ bits given.

According to $1^{\text{st}}$ question, $d=4$  so $4+p+1\leq 2^p$ 

$p+5 \leq 2^p$  now if  p$=2$ it becomes $7 \leq 4,$ Not possible.

If $p=3$ it becomes $8\leq 8,$ which is possible.

So, $p$ must be $3.$[ Minimum value of $p$ is $3$ ]

The second blank the $3$-bit error detection is possible because the code has a minimum distance of $\underline{\qquad}$answer is $3+1=4,$ where d$=3.$ Formula used is $d+1.$

The answer for $2$ blanks is $[ 3,4 ].$

• edited by
33 33 votes
let minimum Hamming distance is $t.$
so with this hamming distance $t-1\ bit$ error detection as well as $\dfrac{ (t-1)}{2}$
bit error correction is possible..

for $3\ bit$ error detection minimum Hamming distance $=3+1=4$
for $1\ bit$ error correction  minimum Hamming distance $=2\times1+1= 3$
no. of parity bits $=p$
$p + t + 1 <= 2^p$
$p + 4 +1 <= 2^p$
$p=3$
• edited by
2 2 votes

Now, (binary) Hamming Codes are usually depicted using the following notation: (n,k,d). Here, n is the number of bits in the code-word, k is the number of information/data bits, and d is again the Minimum Hamming Distance. The Hamming Bound for this code is a mathematical relation between n,k and d. The code can exist if and only is the Hamming Bound is satisfied.

Refer --> 

Harsh Aurora's answer on https://www.quora.com/How-many-check-bits-are-required-for-16-bit-data-word-to-detect-2-bit-errors-and-single-bit-error-correction-using-hamming-code

Now n = ? , k = 4, d = 3+1 (because this much minimum distance is required for 1 bit correction and 3 bit error detection)

so putting all values in the formula you will get 

$2^{n-k} \geqslant \binom{n}{0} + \binom{n}{1}$

n = 7. so extra parity bits are n-k = 3.

So final answer is [3,4]

2 2 votes

I think the question is wrong because Hamming codes cannot detect arbitrary 3-bit errors.

Intuition : Suppose that we flip the first three bits (first two bits are redundancy bits and the third bit is a message bit), then the error will go undetected in any version of the Hamming code.

Further explanation : Suppose that we are using Hamming code (7, 4) and the codeword is [1R, 2R, 3M, 4R, 5M, 6M, 7M]. Flipping 1R, 2R and 3M will never be detected. This is true for any arbitrary Hamming code as the first message bit affects only the first two redundancy bits. So maximum distance of any Hamming code can be 2. (Note that maximum distance of any two Hamming codewords can be greater than 2. But distance of a code is defined as the minimum distance of any two valid codewords in it.)

Reference : https://en.wikipedia.org/wiki/Hamming(7,4)

... Hamming codes cannot detect or recover from an arbitrary three-bit error

0 0 votes

Q.Consider a 3-bit error detection and 1-bit error correction hamming code for 4-bit data. The extra parity bits required would be _____ and the 3-bit error detection is possible because the code has a minimum distance of _______.
ans.after reading this question it fills hard,

tip 1)focus on what question is asking (1)min dist , 2)extra parity bits(with min hamming dist for correction of 1 bit only))

that it you have got the answer now
1)min dist=t+1.     (t is number of bits that can be detected)

min dist=3+1=4

2)extra parity bits in hamming code

so use formula 2^r >= m+r+1 
2^r >= 4+r+1 

2^r >= 5+r

r=3

ans.3,4 

0 0 votes

May be this question is referring to SECDED (extended hamming Code).

In the question it is asked to mention the extra parity bit required so it will 1  (3 +1)

and a minimum hamming distance of 4

ANSWER [ 1, 4] 

 

additional screen shot from:wiki

 

• edited by
Answer:
Position:
Show:

Related questions

19 19 votes
5 5 answers
7.4k
7.4k views
Kathleen asked Sep 12, 2014
7,428 views
The purpose of instruction location counter in an assembler is _______
20 20 votes
3 answers 3 answers
3.3k
3.3k views
Kathleen asked Sep 12, 2014
3,287 views
Many microprocessors have a specified lower limit on clock frequency (apart from the maximum clock frequency limit) because _____
35 35 votes
7 answers 7 answers
11.2k
11.2k views
Kathleen asked Sep 12, 2014
11,221 views
The Boolean function in sum of products form where K-map is given below (figure) is _______
17 17 votes
2 answers 2 answers
6.0k
6.0k views
Kathleen asked Sep 12, 2014
6,003 views
A simple and reliable data transfer can be accomplished by using the 'handshake protocol'. It accomplishes reliable data transfer because for every data item sent by the ...