UNIVERSITY OF CALIFORNIA, DAVIS
_____________________________________________________________________________________
BERKELEY
•
DAVIS
•
IRVINE
•
LOS ANGELES
•
RIVERSIDE
•
SAN DIEGO
•
SAN FRANCISCO
_____________________________________________________________________________________
________________________________
SANTA BARBARA
•
SANTA CRUZ
________________________________
EEC 173A/ECS 152A-Computer Networks
Winter 2014
Solution to Homework #5
Total: 100 points
1.(24 points) Framing & Error Detection(a)(3 pt.) Assume that a framing protocol uses bit stuffing. Show the bit sequence transmitted over the link when the intended transmission contains the following bit sequence: Mark the stuffed bits. 01111110 1101011111010111110110111110110 01111110(b)(3 pt.) Suppose the sequence of bits arrived are 1101011111010111110010111110110. Show the resulting frame after any stuffed bits have been removed.
(c)(5 pt.) A CRC is constructed to generate a 4-bit checksum for an 8-bit message. The generator polynomial is x4+ x2+1, i.e., G = 10101. Encode the data bit sequence 01011101 (note here we assume that the rightmost bit is the least significant) using the generator polynomial and give the code word. Code = 4 bits. First, shift the data sequence by 4 bits to the left, divide by G to find the
(d)(5 pt.) Suppose that code word in part (c) is transmitted. Now assume that 7th from the least significant bit (counting from the rightmost bit) in the code word is in error. Show that the error detection algorithm detects the error.
(e)(8 pt.) One way of detecting errors is to transmit data as a block of nrows of k bits per row and adding parity bits to each row and each column. Will this scheme detect all single errors? Double errors? Triple errors? Address your answer. (For simplicity, let assume that error occurs only in data part not in parity part.)