P1.
Design and describe an application-level protocol to be used between an automatic teller machine and a bank’s centralized computer. Your protocol should allow a user’s card and password to be verified, the account balance (which is maintained at the centralized computer) to be queried, and an account withdrawal to be made (that is, money disbursed to the user). Your protocol entities should be able to handle the all-too-common case in which there is not enough money in the account to cover the withdrawal. Specify your protocol by listing the messages exchanged and the action taken by the automatic teller machine or the bank’s centralized computer on transmission and receipt of messages. Sketch the operation of your protocol for the case of a simple withdrawal with no errors, using a diagram similar to that in Figure 1.2 . Explicitly state the assumptions made by your protocol about the underlying end-to-end transport service.
设计并描述一种在银行中心服务器和自动柜员机间通信的应用层协议,你的协议应当允许验证用户卡和口令,査询账目结算(这些都在中央计算机中进行维护),支取账目(即向用户支付钱)。 你的协议实体应当能够处理取钱时账目中钱不够的常见问题。通过列出自动柜员机和银行中央计算机在报文传输和接收过程中交换的报文和采取的动作来定义你的协议。使用类似于图1.2所示的图,拟定在简单无差错取钱情况下该协议的操作。明确地阐述在该协议中关于底层端到端运输服务所做的假设。
答案:
从柜员机到服务器发送的消息:

服务器向柜员机发送的消息:

握手与校对

假如钱不够了

P2.
Equation 1.1 gives a formula for the end-to-end delay of sending one packet of length L over N links of transmission rate R. Generalize this formula for sending P such packets back-to-back over the N links. 式1.1( d 端到端 = N L R d_{端到端}=N\frac{L}{R} d端到端=NRL) 给出了经传输速率为R的N段链路发送长度L的一个分组的端到端时延。对于经过N段链路一个接一个地发送P个这样的分组,一般化地表示出这个公式。
答案:
( N + P − 1 ) L R (N+P-1)\frac{L}{R} (N+P−1)RL
P3.
Consider an application that transmits data at a steady rate (for example, the sender generates an N-bit unit of data every k time units, where k is small and fixed). Also, when such an application starts, it will continue running for a relatively long period of time. Answer the following questions, briefly justifying your answer:
a. Would a packet-switched network or a circuit-switched network be more appropriate for this application? Why?
b. Suppose that a packet-switched network is used and the only traffic in this network comes from such applications as described above. Furthermore, assume that the sum of the application data rates is less than the capacities of each and every link. Is some form of congestion control needed? Why?
考虑某一应用以稳定速率传输数据(比如每k个时间段发送N比特数据块,k是一个小的常数),且该应用一旦开始服务,就会持续长时间运行,回答下列问题,并且简要地论证你的答案。
a, 应当选择分组交换网络还是电路交换网络?为什么?
b,假设使用分组交换网络,并且该网络上的流量仅来自于上面描述的应用。并且假设应用的数据总和低于每段链路的传输能力。这种情况需不需要设置拥塞控制机制呢?
答案:
a, 电路交换网络。 应用需要持续地传输速率,也就是线路不会存在闲置时间。传输速率是一定的,这样很方便预留一定速率的网络,既不会速率不足也不会浪费。 而假如使用分组交换网络,会增加分组管理开销(比如时延)。
b,不需要。当链路的传输能力始终能满足传输的数据量时,不会存在拥堵和排队的情况,也就不需要有拥塞控制机制。
P4.

Consider the circuit-switched network in Figure 1.13 . Recall that there are 4 circuits on each link. Label the four switches A, B, C, and D, going in the clockwise direction.
a. What is the maximum number of simultaneous connections that can be in progress at any one time in this network?
b. Suppose that all connections are between switches A and C. What is the maximum number of simultaneous connections that can be in progress?
c. Suppose we want to make four connections between switches A and C, and another four connections between switches B and D. Can we route these calls through the four links to accommodate all eight connections?
考虑图1.13中的情况,每段链路有4段电路,将四个交换机按顺时针顺序标记为A、B、C、D。
a,在该网络中最多可以有多少连接同时存在?
b, 假设所有的连接都在A和C之间,在该网络中最多可以同时存在多少连接?
c, 假定我们要在交换机A和C之间建立4条连接,在交换机B和D之间建立另外4条连接。我们能够让这些呼叫通过这4条链路建立路由以容纳所有8条连接吗?
答案:
a,16条(每两个路由器之间可以建立4条)
b,8条 (4条A-B-C,4条A-D-C)
c, 可以。A-C之间的四条:A-B-C两条、A-D-C两条。 B-D之间的两条: B-C-D两条,B-A-D两条。
P5.
Review the car-caravan analogy in Section 1.4 . Assume a propagation speed of 100 km/hour.
a. Suppose the caravan travels 150 km, beginning in front of one tollbooth, passing through a second tollbooth, and finishing just after a third tollbooth. What is the end-to-end delay?
b. Repeat (a), now assuming that there are eight cars in the caravan instead of ten.
回顾在1.4节中的车队的类比。假定传播速度为100km/h
a,假定车队旅行150km:在一个收费站前面开始,通过第二个收费站,并且正好在第三个收费站后 面结束。其端到端时延是多少?
b,重复(a),现在假定车队中有8辆汽车而不是10辆。
答案:
a, 传播时延为90min,传输时延为31012s = 6min, 端到端时延是96min
b, 传输时延不变,端到端时延为3812s = 4min48s, 端到端时延是94min48s
P6.
This elementary problem begins to explore propagation delay and transmission delay, two central concepts in data networking. Consider two hosts, A and B, connected by a single link of rate R bps. Suppose that the two hosts are separated by m meters, and suppose the propagation speed along the link is s meters/sec. Host A is to send a packet of size L bits to Host B.
a. Express the propagation delay d p r o p d_{prop} dprop, in terms of m and s.
b. Determine the transmission time of the packet, d t r a n s d_{trans} dtrans , in terms of L and R.
c. Ignoring processing and queuing delays, obtain an expression for the end-to-end delay.
d. Suppose Host A begins to transmit the packet at time t = 0 t = 0 t=0. At time t = d t r a n s t = d_{trans} t=dtrans , where is the last bit of the packet?
e. Suppose d p r o p d_{prop} dprop is greater than d t r a n s d_{trans} dtrans. At time t = d t r a n s t = d_{trans} t=dtrans, where is the first bit of the packet?
f. Suppose d p r o p d_{prop} dprop is less than d t r a n s d_{trans} dtrans . At time t = d t r a n s t = d_{trans} t=dtrans, where is the first bit of the packet?
g. Suppose s = 2.5 × 1 0 8 2.5\times10^8 2.5×108 , L = 120bits and R = 56kbps find the distance m so that d p r o p d_{prop} dprop equals d t r a n s d_{trans} dtrans
让我们简单地探究一下数据网络中的两个核心问题:传输时延和传播时延。假设有两个主机A和B, 通过一条速率为R bps的链路连接。假设两个主机距离m米,传播速率是s 米/秒, A要向B发送一个大小为L比特的包。
a, 用m和s表示传播时延 d p r o p d_{prop} dprop
b, 根据L和R,确定传输时延 d t r a n s d_{trans} dtrans
c, 忽略处理和排队时延,求出端到端时延的表达式
d, 假设A在t = 0时开始发送该分组,在 d t r a n s d_{trans} dtrans时,分组的最后一个比特正处在什么位置?
e, 假设传播时延大于传输时延,在 d t r a n s d_{trans} dtrans时,分组的第一个比特正处在什么位置?
f, 假设传播时延小于传输时延,在 d t r a n s d_{trans} dtrans时,分组的第一个比特正处在什么位置?
g, 假设s = 2.5 × 1 0 8 2.5\times10^8 2.5×108 , L = 120 and R = 56kbps, 求出使得传输时延与传播时延相等的距离m
答案:
a, d p r o p = m / s d_{prop} = m/s dprop=m/s
b, d t r a n s = L / R d_{trans} = L/R dtrans=L/R
c, d = m / s + L / R d = m/s+L/R d=m/s+L/R
d, 临近主机A的链路上
e, AB之间的链路上
f, 主机B的缓冲区中
g, 535714 m
P7.
In this problem, we consider sending real-time voice from Host A to Host B over a packet-switched network (VoIP). Host A converts analog voice to a digital 64 kbps bit stream on the fly. Host A then groups the bits into 56-byte packets. There is one link between Hosts A and B; its transmission rate is 2 Mbps and its propagation delay is 10 msec. As soon as Host A gathers a packet, it sends it to Host B. As soon as Host B receives an entire packet, it converts the packet’s bits to an analog signal. How much time elapses from the time a bit is created (from the original analog signal at Host A) until the bit is decoded (as part of the analog signal at Host B)?
本题中,我们假设从主机A到主机B通过分组交换网发送实时的声音数据(IP电话)。主机A动态地将模拟声音信号转换为64kbps的数字信号,并将其打包为56字节的分组。在A和B之间有一条传输速率是2 Mbps、传播时延是10毫秒的通路,当A打包完成一个分组后,它立即将其发送到主机B,B接收到整个分组后,它将分组的比特流转换为模拟信号。一个比特从创建到解码为模拟信号花费的时间是多少?
答案:
A收集整个分组所用时间: d 1 = 56 × 8 64 × 1 0 3 = 0.07 s = 7 m s d_1=\frac{56\times8}{64\times10^3} =0.07s = 7ms d1=64×10356×8=0.07s=7ms
A发送整个分组所用的时间: d 2 = 56 × 8 2 × 1 0 6 = 0.000224 s = 0.224 m s d_2=\frac{56\times8}{2\times10^6}=0.000224s=0.224ms d2=2×10656×8=0.000224s=0.224ms
传播时延 d 3 = 10 m s d_3=10ms d3=10ms
总时延d= d 1 + d 2 + d 3 = 17.224 m s d_1+d_2+d_3=17.224ms d1+d2+d3=17.224ms
P8.
Suppose users share a 3 Mbps link. Also suppose each user requires 150 kbps when transmitting, but each user transmits only 10 percent of the time. (See the discussion of packet switching versus circuit switching in Section 1.3 .)
a. When circuit switching is used, how many users can be supported?
b. For the remainder of this problem, suppose packet switching is used. Find the probability that a given user is transmitting.
c. Suppose there are 120 users. Find the probability that at any given time, exactly n users are transmitting simultaneously. (Hint: Use the binomial distribution.)
d. Find the probability that there are 21 or more users transmitting simultaneously
假设用户共享一条3Mbps的链路,且每个用户的传输所需的速率是150kbps,但是每个用户仅占用10%的时间(可参照1.3节关于分组交换和电路交换的比较)。
a, 使用电路交换时,最多可以支持多少用户?
b, 假如使用分组交换,给出某位用户正在传输的概率
c, 假设有120位用户,求出在某个时间恰好有n个用户正在传输的概率。(提示:使用二项分布)
d,计算出同时传输的用户数量大于等于21的概率
答案:
a,20
b,0.1
c, C ( n , 120 ) ∗ 0. 1 n ∗ 0. 9 120 − n C(n,120)*0.1^n*0.9^{120-n} C(n,120)∗0.1n∗0.9120−n
d, 0.079
P9.
Consider the discussion in Section 1.3 of packet switching versus circuit switching in which an example is provided with a 1 Mbps link. Users are generating data at a rate of 100 kbps when busy, but are busy generating data only with probability p = 0.1. Suppose that the 1 Mbps link is replaced by a 1 Gbps link.
a. What is N, the maximum number of users that can be supported simultaneously under circuit switching?
b. Now consider packet switching and a user population of M users. Give a formula (in terms of p, M, N) for the probability that more than N users are sending data.
考虑在1.3节中分组交换和电路交换的对比,原题中提供的是一个1Mbps的链路,用户使用时的速率是100kbps,用户的使用概率p=0.1。假设原本的1Mbps链路更改为1Gbps。
a, 若使用电路交换,最大能支撑多少用户?
b, 考虑分组交换,用户数量为M,求出使用的用户数量大于N的概率(用符号p,M,n表示)。
答案:
a, 10000
b, 
P10.
Consider a packet of length L that begins at end system A and travels over three links to a destination end system. These three links are connected by two packet switches. Let d i d_i di , s i s_i si , and R i R_i Ri denote the length, propagation speed, and the transmission rate of link i, for i=1,2,3 . The packet switch delays each packet by d p r o c d_{proc} d

本文深入探讨了网络通信协议的设计,包括应用层协议在ATM网络和互联网之间的交互,以及端到端延迟计算。讨论了电路交换与分组交换的优缺点,并举例说明了在不同场景下如何选择合适的通信方式。此外,还分析了ATM网络中自动告诉机与银行中心服务器的通信协议,涵盖了验证、查询账户余额和转账操作。文章还涉及了传播延迟、传输延迟和队列延迟的计算,并探讨了在高带宽和低延迟环境下数据传输的效率。最后,文章讨论了分组交换网络中实时语音传输的挑战,包括丢包率和传播时延的影响。
最低0.47元/天 解锁文章
5380

被折叠的 条评论
为什么被折叠?



