您好,欢迎访问三七文档
当前位置:首页 > 电子/通信 > 综合/其它 > 计算机与通信网络实验报告
计算机与通信网络实验报告041220111戴妍实验一隐终端和暴露终端问题分析一、实验设定:基本参数配置:仿真时长100s;随机数种子1;仿真区域2000x2000;节点数4。节点位置配置:本实验用[1]、[2]、[3]、[4]共两对节点验证隐终端问题。节点[1]、[2]距离为200m,节点[3]、[4]距离为200m,节点[2]、[3]距离为370m。业务流配置:业务类型为恒定比特流CBR。[1]给[2]发,发包间隔为0.01s,发包大小为512bytes;[3]给[4]发,发包间隔为0.01s,发包大小为512bytes。二、实验结果:Node:1,Layer:AppCbrClient,(0)Serveraddress:2Node:1,Layer:AppCbrClient,(0)Firstpacketsentat[s]:0.000000000Node:1,Layer:AppCbrClient,(0)Lastpacketsentat[s]:99.990000000Node:1,Layer:AppCbrClient,(0)Sessionstatus:NotclosedNode:1,Layer:AppCbrClient,(0)Totalnumberofbytessent:5120000Node:1,Layer:AppCbrClient,(0)Totalnumberofpacketssent:10000Node:1,Layer:AppCbrClient,(0)Throughput(bitspersecond):409600Node:2,Layer:AppCbrServer,(0)Clientaddress:1Node:2,Layer:AppCbrServer,(0)Firstpacketreceivedat[s]:0.007438001Node:2,Layer:AppCbrServer,(0)Lastpacketreceivedat[s]:99.999922073Node:2,Layer:AppCbrServer,(0)Averageend-to-enddelay[s]:0.739902205Node:2,Layer:AppCbrServer,(0)Sessionstatus:NotclosedNode:2,Layer:AppCbrServer,(0)Totalnumberofbytesreceived:4975616Node:2,Layer:AppCbrServer,(0)Totalnumberofpacketsreceived:9718Node:2,Layer:AppCbrServer,(0)Throughput(bitspersecond):398078Node:3,Layer:AppCbrClient,(0)Serveraddress:4Node:3,Layer:AppCbrClient,(0)Firstpacketsentat[s]:0.000000000Node:3,Layer:AppCbrClient,(0)Lastpacketsentat[s]:99.990000000Node:3,Layer:AppCbrClient,(0)Sessionstatus:NotclosedNode:3,Layer:AppCbrClient,(0)Totalnumberofbytessent:5120000Node:3,Layer:AppCbrClient,(0)Totalnumberofpacketssent:10000Node:3,Layer:AppCbrClient,(0)Throughput(bitspersecond):409600Node:4,Layer:AppCbrServer,(0)Clientaddress:3Node:4,Layer:AppCbrServer,(0)Firstpacketreceivedat[s]:0.003058001Node:4,Layer:AppCbrServer,(0)Lastpacketreceivedat[s]:99.993058001Node:4,Layer:AppCbrServer,(0)Averageend-to-enddelay[s]:0.003119031Node:4,Layer:AppCbrServer,(0)Sessionstatus:NotclosedNode:4,Layer:AppCbrServer,(0)Totalnumberofbytesreceived:5120000Node:4,Layer:AppCbrServer,(0)Totalnumberofpacketsreceived:10000Node:4,Layer:AppCbrServer,(0)Throughput(bitspersecond):409612通过仿真结果可以看出,节点[2]无法收到数据。由于节点[3]是节点[1]的一个隐终端,节点[1]无法通过物理载波检测侦听到节点[3]的发送,且节点[3]在节点[2]的传输范围外,节点[3]无法通过虚拟载波检测延迟发送,所以在节点[1]传输数据的过程中,节点[3]完成退避发送时将引起冲突。三、课后思考1、RTS/CTS能完全解决隐终端问题吗?如果不能,请说明理由。答:能。对于隐发送终端问题,[2]和[3]使用控制报文进行握手(RTS-CTS),听到回应握手信号的[3]知道自己是隐终端,便能延迟发送;对于隐接受终端问题,在多信道的情况下,[3]给[4]回送CTS告诉[4]它是隐终端,现在不能发送报文,以避免[4]收不到[3]的应答而超时重发浪费带宽。2、如何设计仿真场景来验证暴露终端问题?答:只需更改业务流配置:业务类型为恒定比特流CBR。[2]给[1]发,发包间隔为0.01s,发包大小为512bytes;[3]给[4]发,发包间隔为0.01s,发包大小为512bytes。观察在[2]给[1]发送数据的同时,[3]给[4]发送数据会不会被影响。3、如何设计协议使暴露终端场景下的流实现并发?答:至少要使用两个信道资源,在数据信道上进行RTS-CTS握手,在数据信道上发送数据报文。在[2]给[1]发送数据报文时,[3]也想向[4]发送数据报文,通过控制信道向[4]发送RTS,[4]也从控制信道向[3]回送CTS,这样[3]就不会因为[2]的数据信号和[4]的回应信号产生碰撞而听不到[4]的回应了。这样就可以实现并发了。实验二无线局域网DCF协议饱和吞吐量验证一、实验设定基本参数配置:仿真时长100S随机数种子1仿真区域150x150节点数100。业务流配置:业务类型为CBR,发包大小为512bytes,发包间隔为0.01S,分别测出5、10、15、20、25、30、35、40、45、50条流的吞吐量。二、实验结果:5条:Node:1,Layer:AppCbrClient,(4)Serveraddress:55Node:1,Layer:AppCbrClient,(4)Firstpacketsentat[s]:0.000000000Node:1,Layer:AppCbrClient,(4)Lastpacketsentat[s]:99.990000000Node:1,Layer:AppCbrClient,(4)Sessionstatus:NotclosedNode:1,Layer:AppCbrClient,(4)Totalnumberofbytessent:5120000Node:1,Layer:AppCbrClient,(4)Totalnumberofpacketssent:10000Node:1,Layer:AppCbrClient,(4)Throughput(bitspersecond):409600Node:1,Layer:AppCbrClient,(3)Serveraddress:54Node:1,Layer:AppCbrClient,(3)Firstpacketsentat[s]:0.000000000Node:1,Layer:AppCbrClient,(3)Lastpacketsentat[s]:99.990000000Node:1,Layer:AppCbrClient,(3)Sessionstatus:NotclosedNode:1,Layer:AppCbrClient,(3)Totalnumberofbytessent:5120000Node:1,Layer:AppCbrClient,(3)Totalnumberofpacketssent:10000Node:1,Layer:AppCbrClient,(3)Throughput(bitspersecond):409600Node:1,Layer:AppCbrClient,(2)Serveraddress:53Node:1,Layer:AppCbrClient,(2)Firstpacketsentat[s]:0.000000000Node:1,Layer:AppCbrClient,(2)Lastpacketsentat[s]:99.990000000Node:1,Layer:AppCbrClient,(2)Sessionstatus:NotclosedNode:1,Layer:AppCbrClient,(2)Totalnumberofbytessent:5120000Node:1,Layer:AppCbrClient,(2)Totalnumberofpacketssent:10000Node:1,Layer:AppCbrClient,(2)Throughput(bitspersecond):409600Node:1,Layer:AppCbrClient,(1)Serveraddress:52Node:1,Layer:AppCbrClient,(1)Firstpacketsentat[s]:0.000000000Node:1,Layer:AppCbrClient,(1)Lastpacketsentat[s]:99.990000000Node:1,Layer:AppCbrClient,(1)Sessionstatus:NotclosedNode:1,Layer:AppCbrClient,(1)Totalnumberofbytessent:5120000Node:1,Layer:AppCbrClient,(1)Totalnumberofpacketssent:10000Node:1,Layer:AppCbrClient,(1)Throughput(bitspersecond):409600Node:1,Layer:AppCbrClient,(0)Serveraddress:51Node:1,Layer:AppCbrClient,(0)Firstpacketsentat[s]:0.000000000Node:1,Layer:AppCbrClient,(0)Lastpacketsentat[s]:99.990000000Node:1,Layer:AppCbrClient,(0)Sessionstatus:NotclosedNode:1,Layer:AppCbrClient,(0)Totalnumberofbytessent:5120000Node:1,Layer:AppCbrClient,(0)Totalnumberofpacketssent:10000Node:1,Layer:AppCbrClient,(0)Throughput(bitspersecond):409600Node:51,Layer:AppCbrServer,(0)Clientaddress:1Node:51,Layer:AppCbrServer,(0)Firstpacketreceivedat[s]:0.003056858Node:51,Layer:AppCbrServer,(0)Lastpacketreceivedat[s]:99
本文标题:计算机与通信网络实验报告
链接地址:https://www.777doc.com/doc-2041911 .html