CPE442 – Computer Networks

1. Consider sending a file of size F bits over a path of N links. Each link transmits at R bps. The file is divided into P packets before sending. Suppose that the propagation speed along each link is S meters/second and that the length of the link is M meters. The network is lightly loaded so that there are no queuing delays. a. Suppose the network is a packet-switched virtual-circuit network. Denote the VC setup time by t s seconds. Suppose the sending layers add a total of H bits of header to each packet. How long does it take to send the file from source to destination? b. Suppose the network is a packet-switched datagram network and a connectionless service is used. Now suppose each packet has H bits of header. How long does it take to send the file? c. Finally, suppose that the network is a circuit-switched network. Further suppose that the transmission rate of the circuit between source and destination is R bps. Assuming t s setup time and H bits of header appended to each packet, how long does it take to send the file? Consider transferring a file of 100,000 bits between two hosts that have a direct link with a bandwidth of 5 Mbps. Assume that the propagation delay between the sender and the receiver is 45 ms, packet size is 500 bits (ignore the headers), and the transmission is error free. Calculate the total time required to transmit the file: a. Assuming that packets can be sent continuously. b. Assuming that after sending each packet, we must wait for the packet to be acknowledged by the receiver (and the transmission time of an acknowledgement is negligible). c. Assuming that the link allows an infinite data transfer rate, but limits bandwidth such that only 10 packets can be sent every 45 ms. 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. Ignoring processing and queuing delays, obtain an expression for the end-to-end delay. b. Suppose Host A begins to transmit the packet at time t = 0. At time t = d trans , where is the last bit of the packet? c. Suppose d prop  2 dtrans . At time t  2 dtrans , where is the first bit of the packet? d. e. 4. Suppose d prop  1 d trans . At time t  1 dtrans where is the first bit of the packet? 2 2 Suppose s  2.5  108 , L = 1000 bits, and R = 10 Mbps. Find the distance m so that d prop = d trans .



In this problem we consider sending voice from Host A to Host B over a packet-switched network (for example, Internet phone). Host A converts analog voice to a digital 56 kbps bit stream on the fly. Host A then groups the bits into 100-byte packets. There is one link between Host A and B; its transmission rate is 1.54Mbps and its propagation delay is 1 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 3 Mbps link is to be shared among number of users. Suppose each user requires 100 kbps when transmitting, but each user transmits only 30 percent of the time. (See the discussion Packet Switching Versus Circuit Switching in Section 1.3.) a. When circuit switching is used, how many users can be supported? a. For the remainder of this problem, suppose packet switching is used. Find the probability that a given user is transmitting. b. Suppose there are 40 users. Find the probability that at any given time; exactly 30 users are transmitting simultaneously. (Hint: Use the binomial distribution. Use MS-Excel to calculate) c. Find the probability that there more than 30 users are transmitting simultaneously.


Dr. Fahed Awad

Page 1 of 2

CPE442 – Computer Networks
5. Suppose that a 20 Mbps point-to-point link is available between two hosts A and B. The distance between them, is 375000Km and data travels over this link at the speed of light (i.e., 3x10 8 m/s). a. Calculate the bandwidth-delay product, R  t prop ? b. Consider sending a file of 900,000 bits from Host A to Host B. Suppose the file is sent continuously as one big message. What is the maximum number of bits that will be in the link at any given time? What is the width (in meters) of a bit in the link (in fact, it is the distance between any two consecutive bit on the link)? Derive a general expression for the width of a bit in, terms of the propagation speed s, transmission rate R, and the length of the link m. How long does it take to send the 900,000 bit file, assuming that it is sent continuously? Suppose now the 900,000 bit file is broken up into 20 packets with each packet containing 45,000 bits. Suppose that each packet is acknowledged by the receiver and the transmission time of an acknowledgement packet is negligible. Finally, assume that the sender cannot send a packet until the preceding packet is acknowledged. How long does it take to send the file? Compare the result with previous result.

c. d. e. f.


In modern packet-switched networks, the source host segments long, application layer messages (for example, an image or a music file) into smaller packets and sends the packets into the network. The receiver then reassembles the packets back into the original message. We refer to this process as message segmentation. Figure 1.21 illustrates the end-to-end transport of a message with and without message segmentation. Consider a message that is 7.5Mbits long that is to be sent from source to destination in Figure 1.21. Suppose each link #1 and link #3 in the figure are 3 Mbps each, and link #2 is 2.5 Mbps. Ignore propagation, queuing, and processing delays. b. Consider sending the message from source to destination without message segmentation. How long does it take to move the message from the source host to the first packet switch? Keeping in mind that each switch uses store-and-forward packet switching, what is the total time to move the message from source host to destination host? c. Now suppose that the message is segmented into 3000 packets, with each packet being 3000 bits long (data & headers). How long does it take to move the first packet from source host to the first switch? When the first packet is being sent from the first switch to the second switch, the second packet is being sent from the source host to the first switch. At what time will the second packet be fully received at the first switch? How long does it take to move the file from source host to destination host when message segmentation is used? Compare this result with your answer in part (a) and comment. d. Discuss the drawbacks of message segmentation Consider sending a large file of F bits from Host A to Host B. There are two links (and one switch) between A and B, and the links are uncongested (that is, no queuing delays). Host A segments the file into segments of S bits each and adds H bits of header to each segment, forming packets of L = H + S bits. Each link has a transmission rate of R bps. Find the value of S that minimizes the delay of moving the file from Host A to Host B. Disregard propagation delay.


Dr. Fahed Awad

Page 2 of 2