The eight-bit words can be classified into three types.
- Words of the $[8,4,4]$ extended Hamming code. There are 16 of these, and they have even weight.
- Words that are distance 1 from a codeword. There are 128 of these, and they have odd weight.
- Words that are distance 2 from a codeword. There are 112 of these, and they have even weight. Each such word is equidistant from four codewords.
From this it is clear that if there are three errors in transmission of a codeword, the received word will have odd weight, and therefore will fall into class 2. It will therefore be decoded as if it were distance 1 from a codeword. That is, it will always be decoded to the wrong codeword.
Added: As for decoding, suppose we use the parity check matrix
$$H=\begin{bmatrix}1 & 1 & 1 & 1 & 1 & 1 & 1 & 1\\
0 & 0 & 0 & 1 & 1 & 1 & 1 & 0\\
0 & 1 & 1 & 0 & 0 & 1 & 1 & 0\\
1 & 0 & 1 & 0 & 1 & 0 & 1 & 0\end{bmatrix}$$
and regard the first seven bits as coming from the $[7,4,3]$ Hamming code with the eighth bit as parity check bit. Given received word $w,$ we compute $Hw,$ which is a four-bit word. If the received word is a codeword, $Hw$ will equal $0000.$ If the received word has odd weight, bit $1$ of $Hw$ will be set, and the decoder will assume one error. Under this assumption, if $Hw=1000$ then the error was in bit $8;$ otherwise, the last three bits of $Hw$ are the binary encoding of the position of the error. Finally, if the received word has even weight but is not a codeword, then $Hw$ will not equal $0000$ but its first bit will not be set. The decoder will then report a noncorrectable error.
Let $c(x) = \sum_{i=0}^{N-1} c_i x^i$ denote the polynomial corresponding
to the codeword $\mathbf c = [c_0, c_1, \ldots, c_{N-1}]$ of a cyclic binary Hamming
code with generator polynomial $g(x)$. Note that $N = 2^m-1$ for some
positive integer $m$ and that $g(x)$ is a primitive
polynomial of degree $m$. Let $\alpha \in \mathbb F_{2^m}$ be a root of
$g(x)$ and note that $\alpha$ has order $2^m-1$.
The parity check matrix $H$ of this cyclic binary Hamming code can be viewed as
$[1, \alpha, \cdots, \alpha^{N-1}]$. If you are unfamiliar with this notion, then
express each $\alpha^i$ as a column vector to get the
usual binary representation. But, with this formulation,
$H\mathbf c^T = \mathbf0$ is equivalent to $c(\alpha) = 0$ which is
exactly what the polynomial formulation says in other terms: each
codeword polynomial is a multiple of $g(x)$ which happens to have
$\alpha$ as a root, and so $c(\alpha) = 0$.
Let $\mathbf c$ be transmitted and $\mathbf r = \mathbf c + \mathbf e$ denote
the received word. In terms of polynomials, $r(x) = \sum_i r_ix^i$
is the received word polynomial where $r_i = c_i + e_i$ with
$e(x)$ denoting the error word polynomial corresponding to the error
word $\mathbf e$. Note that $r(x) = c(x) + e(x)$. The receiver computes
$$H\mathbf r^T = H(\mathbf c + \mathbf e)^T =
H\mathbf c^T + H\mathbf e^T = \mathbf 0 + H\mathbf e^T = H\mathbf e^T.$$
In terms of polynomials, computing $H\mathbf r^T$ is the same as
evaluating $r(x)$ at $\alpha$, andso the above equation can be
expressed as
$$r(\alpha) = c(\alpha) + e(\alpha) = 0 + e(\alpha) = e(\alpha).$$
If a single error has occurred, then $\mathbf e$ has Hamming weight $1$,
and $e(x)$ is a monomial $x^i$ for some $i$, $0 \leq i \leq N-1$.
Thus, the bit in the $i$-th position has been received incorrectly.
In terms of polynomials, the syndrome is
$e(\alpha) = x^i\bigr |_{x=\alpha^i} = \alpha^i$. If two errors
have occurred, the syndrome is $\alpha^i + \alpha^{i^\prime} = \alpha^j$.
The decoder for the cyclic Hamming code cannot tell whether one
or two errors have occurred: if the symdrome equals $\alpha^\ell$,
it simply inverts $r_\ell$ to correct the error.
The extended Hamming code has an overall parity bit $c_N$
whose value is chosen to ensure that the extended codeword
$\hat{\mathbf c} = (\mathbf c, c_N)$ has even Hamming weight.
Suppose that an extended Hamming code is being used and
it is known that if there are two channel errors,
then they are adjacent errors not involving the overall
parity bit.
Let $\hat{\mathbf r} = (\mathbf r, r_N)$ be the received word for
the extended Hamming code. If $\hat{\mathbf r}$ has odd Hamming
weight, then the decoder assumes that a single error has
occurred, and if $r(\alpha) = \alpha^\ell$, the decoder inverts
$r_\ell$.
But if $\hat{\mathbf r}$ has even Hamming weight and
$r(\alpha) = \alpha^\ell \neq 0$, then the decoder assumes that
$e(x) = x^i + x^{i+1}$ (double adjacent error) and so
$r(\alpha) = e(\alpha) = \alpha^i + \alpha^{i+1} = \alpha^\ell.$
Since $\alpha^i = \alpha^\ell(1+\alpha)^{-1}$, the
decoder can find the value of $i$ and then invert $r_i$ and $r_{i+1}$.
In this way, single errors and double adjacent errors not involving
the overall parity bit can be corrected with an extended Hamming code.
Best Answer
The correct answer should be point 2). This is because bit errors and bursts of up to $n$ bits will be detected by polynomial $P(x)$ of degree $n$. This means that $16$ check bits would be required to detect errors for the data. Hamming code needs $\log n$ check bits for a word of length $n$ in order to detect single error which is only $4$ bits in the example.