Algorithm in Computer Network
Algorithm in Computer Network
The transmission rates between the sending host and the switch and between the switch and
Assuming that the switch uses store-and-forward packet switching, what is the total end-to-end delay
to send a packet of length L? (Ignore queuing, propagation delay, and processing delay.)
R1= Transmission rates between the sending host and the switch
R2= Transmission rates between the switch and the receiving host
L= Packet of length
Q>--Suppose users share a 2 Mbps link. Also suppose each user transmits
continuously at 1 Mbps when transmitting, but each user transmits only 20 percent of
the time. (See the discussion of statistical multiplexing 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. Why will
there be essentially no queuing delay before the link if two or fewer users transmit at
the same time? Why will there be a queuing delay if three users transmit at the same
time?
c. Find the probability that a given user is transmitting.
d. Suppose now there are three users. Find the probability that at any given time, all
three users are transmitting simultaneously. Find the fraction of time during which the
queue grows.
Ans--a) 2 users can be supported because each user requires half of the link
bandwidth.
b) Since each user requires 1Mbps when transmitting, if two or fewer users transmit
simultaneously, a maximum of 2Mbps will be required. Since the available bandwidth
of the shared link is 2Mbps, there will be no queuing delay before the link. Whereas, if
three users transmit simultaneously, the bandwidth required will be 3Mbps which is
more than the available bandwidth of the shared link. In this case, there will be
queuing delay before the link.
c) Probability that a given user is transmitting = 0.2
d) Probability that all three users are transmitting simultaneously =
Since the queue grows when all the users are transmitting, the fraction of time during which
the queue grows (which is equal to the probability that all three users are transmitting
simultaneously) is 0.008.
Q>-- Visit the Transmission Versus Propagation Delay applet at the companion Web
site. Among the rates, propagation delay, and packet sizes available, find a
combination for which the sender finishes transmitting before the first bit of the
packet reaches the receiver. Find another combination for which the first bit of the
packet reaches the receiver before the sender finishes transmitting.
Ans-- Given the Transmission Versus Propagation Delay applet at the companion Web
site:
s=Propagation speed = 2.8*108 m/s
E=End-to-End delay = 3.620 ms
L=Packet length=1 KBytes
d=link length=1000 km
R=Transmission rate=10Mbps
Q>-- Visit the Queuing and Loss applet at the companion Web site. What is the maximum
emission rate and the minimum transmission rate? With those rates, what is the traffic
intensity? Run the applet with these rates and determine how long it takes for packet loss to
occur. Then repeat the experiment a second time and determine again how long it takes for
packet loss to occur.
Are the values different? Why or why not?
Ans--Consider to visit the Queuing and Loss applet at the companion Web site:
The maximum emission rate =500 packets/s
The minimum transmission rate=350 packets/s
The traffic intensity=500/350
=1.42
Q>-- Suppose Host A wants to send a large file to Host B. The path from Host A to
Host B has three links, of rates R1 = 500 kbps, R2 = 2 Mbps, and R3 = 1 Mbps.
a. Assuming no other traffic in the network, what is the throughput for the file
transfer?
b. Suppose the file is 4 million bytes. Dividing the file size by the throughput, roughly
how long will it take to transfer the file to Host B?
c. Repeat (a) and (b), but now with R2 reduced to 100 kbps.
Q>>Consider the queuing delay in a router buffer. Let I denote traffic intensity; that is, I = La/R. Suppose that the
queuing delay takes the form IL/R (1 – I) for I < 1.
a. Provide a formula for the total delay, that is, the queuing delay plus the transmission delay.
b. Plot the total delay as a function of L/R.
Ans>>Given rate of the transmission link and the rate of packets arriving at a link.
Reduce
Question by Anonymous on 07 Sep, 2018 at 05:21 PM
Consider a router buffer preceding an outbound link. In this problem, you will use
Little’s formula, a famous formula from queuing theory. Let N denote the average
number of packets in the buffer plus the packet being transmitted. Let a denote the
rate of packets arriving at the link. Let d denote the average total delay (i.e., the
queuing delay plus the transmission delay) experienced by a packet. Little’s formula
is N = a · d. Suppose that on average, the buffer contains 10 packets, and the
average packet queuing delay is 10 msec. The link’s transmission rate is 100
packets/sec. Using Little’s formula, what is the average packet arrival rate, assuming
there is no packet loss?
Answer by Geroge on 01 May, 2017 at 03:06 PM
a)
Consider Data,
Generalize Equation 1.2 in Section 1.4.3 for heterogeneous processing rates,
transmission rates,and propagation delays.
Total end-to-end delay = Transmission delay + Propagation delay
b)
Consider data,
Suppose that there is an average queuing delay of dqueue at each node.
Total end-to-end delay = Transmission delay + Propagation delay + Queuing
delay
Reduce
Question by Anonymous on 17 Mar, 2018 at 08:26 AM
Suppose two hosts, A and B, are separated by 20,000 kilometers and are connected
by a direct link of R = 2 Mbps. Suppose the propagation speed over the link is 2.5 x
10^8 meters/sec.
a. Calculate the bandwidth-delay product, R _ dprop.
b. Consider sending a file of 800,000 bits from Host A to Host B. Suppose the file is
sent continuously as one large message. What is the maximum number of bits that
will be in the link at any given time?
c. Provide an interpretation of the bandwidth-delay product.
d. What is the width (in meters) of a bit in the link? Is it longer than a football field?
e. Derive a general expression for the width of a bit in terms of the propagation
speed s, the transmission rate R, and the length of the link m.
Answer by Samuel on 12 Mar, 2016 at 09:55 AM
Referring to problem P25, suppose we can modify R. For what value of R is the width
of a bit as long as the length of the link?
Answer by Geroge on 28 Sep, 2016 at 04:57 PM
Consider problem P25 but now with a link of R = 1 Gbps.
a. Calculate the bandwidth-delay product, R _ dprop.
b. Consider sending a file of 800,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?
c. What is the width (in meters) of a bit in the link?
a)
Therefore, the bandwidth-delay product is 8000000 bits.
b)
c)
Reduce
Question by Anonymous on 24 Mar, 2018 at 01:02 PM
As per problem 25, two hosts (A and B) are connected using direct link.
The distance between these two hosts A and B = 20,000km
= 20000x10^3 m
=2x10^7 m
Transmission rate (speed) of the direct link between A and B(R) = 2Mbps
= 2 x 10^6
bps
Propagation speed of the link between A and B(S) = 2.5x10^8 meters/sec
a)
Here, length of the file is transmitted continuously and it is represented as L.
The length of the file (L) = 800,000bits
Calculating the propagation delay = distance/speed
= 2x10^7 / 2.5 x 10^8 = 0.08sec = 80msec
Calculate the transmission delay =
b)
The length of the file (L) = 800,000bits
The file is divided into 20 packets. So, the length of each packet =40,000bits
c)
The time taken to transfer the file continuously from the host A to B is 480 msec as
per part(a).
The time taken to transfer the file by divided into multiple packets from the host A to
B is 3600 msec as per part(b).
Hence, transmitting the file continuously is more efficient than transmitting the file as
multiple packets.
Reduce
Question by Anonymous on 07 Sep, 2018 at 05:33 PM
Consider sending a large file of F bits from Host Ato Host B. There are three links (and
two switches) 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 80 bits of
header to each segment, forming packets of L = 80 + 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.
Answer by Samuel on 17 Mar, 2016 at 12:49 AM
Consider sending a large file of F bits from Host Ato Host B. There are three links (and
two switches) between Aand B, and the links are uncongested (that is, no queuing
delays). Host Asegments the file into segments of S bits each and adds 80 bits of
header to each segment, forming packets of L = 80 + 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 Ato Host B. Disregard propagation delay.
Answer by Geroge on 16 Oct, 2018 at 01:58 AM
=(80+S)/R seconds
Time (T) required for the first packet to be transmitted to destination:
T=T delay * Number of links
=(80+S)/R *3