计算机网络第三章作业参考答案

上传人:桔**** 文档编号:488018047 上传时间:2022-07-31 格式:DOC 页数:8 大小:103KB
返回 下载 相关 举报
计算机网络第三章作业参考答案_第1页
第1页 / 共8页
计算机网络第三章作业参考答案_第2页
第2页 / 共8页
计算机网络第三章作业参考答案_第3页
第3页 / 共8页
计算机网络第三章作业参考答案_第4页
第4页 / 共8页
计算机网络第三章作业参考答案_第5页
第5页 / 共8页
点击查看更多>>
资源描述

《计算机网络第三章作业参考答案》由会员分享,可在线阅读,更多相关《计算机网络第三章作业参考答案(8页珍藏版)》请在金锄头文库上搜索。

1、Chapter3 THE DATA LINK LAYER2. The following data fragment occurs in the middle of a data stream for which the byte-stuffing algorithm described in the text is used: A B ESC C ESC FLAG FLAG D. What is the output after stuffing?Answer:A B ESC C ESC FLAG FLAG D= A B ESC ESC C ESC ESC ESC FLAG ESC FLAG

2、 D3. What is the maximum overhead in byte-stuffing algorithm?Answer:FLAGFLAGPayload fieldThis a frame delimited by flag bytes. (Ignore the header and trailer)Suppose that there is x bytes in payload field, and the worst case is that all of them are flag bytes or ESC, there should be 2x bytes in tota

3、l. So the max overhead in byte-stuffing should be:Or: (from 袁子超)if it has n bytes to send, and has m ESC. So the overhead is: .If the n bytes are all ESC, the overhead is maximum as: 4.When bit stuffing is used, is it possible for the loss, insertion, or modification of a single bit to cause an erro

4、r not detected by the checksum? If not, why not? If so, how? Does the checksum length play a role here?Answer:It is possible. Suppose that the original text contains the bit sequence 01111110 as data. After bit stuffing, this sequence will be rendered as 011111010. If the second 0 is lost due to a t

5、ransmission error, what is received is 01111110, which the receiver sees as end of frame. It then looks just before the end of the frame for the checksum and verifies it. If the checksum is 16 bits, there is 1 chance in 216 that it will accidentally be correct, leading to an incorrect frame being ac

6、cepted. The longer the checksum, the lower the probability of an error getting through undetected, but the probability is never zero.6. To provide more reliability than a single parity bit can give, an error-detecting coding scheme uses one parity bit for checking all the odd-numbered bits and a sec

7、ond parity bit for all the even-numbered bits. What is the Hamming distance of this code?Answer:Any single-bit error in the odd-numbered bits could change parity bit. Its the same as the even-numbered bits. And both two errors occur in the odd-numbered bits or in the even-numbered bits will not chan

8、ge the parity bit. That is to say , this code could only detect single-bit errors, which means the Hamming distance is 2.7.An 8-bit byte with binary value 10101111 is to be encoded using an even-parity Hamming code. What is the binary value after encoding?Answer:According to ,m=8 r=4P1=B1B3B5B7B9B11

9、 =(0,1,0,0,1,1)=1 P2=B2B3B6B7B10B11=(0,1,1,0,1,1)=0P3=B4B5B6B7 B12 =(0,0,1,0,1)=0 P4=B8B9B10B11B12 =(0,1,1,1,1)=0So, Hamming code is: 10100100111113. Suppose that a message 1001 1100 1010 0011 is transmitted using Internet Checksum (4-bit word). What is the value of the checksum?Solution:1001 1100 1

10、010 + 0011- 0010 (have 2 added bit),so: +1+1- 0100So, the Internet checksum is the ones complemnet of 0100, or 1011.14. What is the remainder obtained by dividingby the generator polynomial ?Solution:The remainder is .15.A bit stream 10011101 is transmitted using the standard CRC method described in

11、 the text. The generator polynomial is ,. Show the actual bit string transmitted. Suppose that the third bit from the left is inverted during transmission. Show that this error is detected at the receivers end. Give an example of bit errors in the bit string transmitted that will not be detected by

12、the receiver.Solution:(1) 100110011101000 mod 1001 = 100The actual bit string transmitted: 10011101000+100=10011101100(2) The bit string receiver receives:100111011001011110110010111101100 mod 1001 = 100 0 error!(3)example: 1001110110010011110101 10011110101 mod 1001 = 0 So the receiver may think th

13、at the received bit string is right while its wrong in fact.16. Data link protocols almost always put the CRC in a trailer than in a header. Why?Answer:CRC is calculated during sending. It could be appended to the data bit string as soon as the last data bit is send to the path. If it is put in the

14、header, it must scan the whole frame in order to calculate CRC. It means that we should dispose the code 2 times. And CRC in the trailer could help to drop the half time.Or: (from 袁子超 )CRC calculate during transmission. Once the last data sent out line, immediately put CRC code attached to the outpu

15、t stream from the back. If put CRC on the head of the frame, then we should check the frame to calculate CRC before sending. So that each byte has to deal with two times, the first is to calculate the check code, second times to send. Put CRC in the tail of the processing time can be halved.20. A 3000-km-long T1 trunk is used to transmit 64-byte frames using protocol 5. If the propagation speed is 6 sec/km, how many bits should the sequence numbers be?Solution: delay= 3000-

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 办公文档 > 工作计划

电脑版 |金锄头文库版权所有
经营许可证:蜀ICP备13022795号 | 川公网安备 51140202000112号