1) For the 8-bit data 010010112 develop the Hamming codeword for one-bit error correction:

1 2 3 4 5 6 7 8 9 10 11 12
P1 P2 D7 P4 D6 D5 D4 P8 D3 D2 D1 D0
    0   1 0 0   1 0 1 1
1 2 1+2 4 1+4 2+4 1+2+4 8 1+8 2+8 1+2+8 4+8

Check bit P1 looks at bit positions 1, 3, 5, 7, 9, and 11

Check bit P2 looks at bit positions 2, 3, 6, 7, 10, and 11

Check bit P4 looks at bit positions 4, 5, 6, 7, and 12

Check bit P8 looks at bit positions 8, 9, 10, 11, and 12

2) The CRC, Cyclic Redundancy Check, are used to detect errors in long data transmissions/blocks that are subject to burst errors (several bits in sequence that are corrupted). The main idea is to append to the data-bits a small (16 or 32 bits) amount of information to help detect errors. Retransmission of the data is done if an error is detected.

The basic calculation of the CRC is integer division.

a) What is the quotient of (D - R) / G?

b) What is the remainder of (D - R) / G?

c) What is the range of the remainders of D / G?

To simplify calculations all CRC calculations are done in modulo-2 arithmetic without carries in addition or borrows in subtraction. Therefore, both addition and subtraction are identical and equivalent to bitwise XOR (exclusive OR). For example,

Let

D = d-bit data,

G = degree n polynomial generator, e.g., G = x5 + x2 + 1 is 1001012

R = n-bit remainder

C = (d+n)-bit codeword to be transmitted

The goal is to generate C such that C / G would have no remainder. To do this, we generate R as

= , where Q is the quotient and R is the remainder.

The sender sends the codeword . When the receiver receives C, it divides by G,

= = = = .

e) What is ?

Let

D = 101001012 (8-bit data),

G = x5 + x2 + 1 is 1001012 (degree 5 polynomial)

f) Determine the remainder

g) What codeword is sent by the sender?

h) Divide the codeword by the generator G = x5 + x2 + 1 (1001012 ) to check for an error. Remainder should be zero if no errors.

i) Introduce some random error into the codeword and check for an error by dividing by the generator G = x5 + x2 + 1 (1001012)