0% found this document useful (0 votes)
22 views3 pages

Networks and Protocols Exercise Sheet 1

Uploaded by

Bekhedda Asma
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
22 views3 pages

Networks and Protocols Exercise Sheet 1

Uploaded by

Bekhedda Asma
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Intelligent Systems Engineering Department

The National School of Artificial Intelligence


3rd Year, Semester 1 — 2024/2025

NETWORKS AND PROTOCOLS

Exercises Sheet 1
Exercise 1
An image has a size of 4080x1830 pixels with true color, which means that 3 Bytes per pixel are
used for the color information.
How long does it take to transmit the uncompressed image via a:

(a) 56 kbps Modem connection?

(b) 64 kbps ISDN connection?

(c) 16 Mbps DSL connection?

(d) 100 Mbps Ethernet connection?

(e) 1 Gbps Ethernet connection?

Assume the image is compressed with a compression algorithm that reduces the image size by
85%. How long does it take to transmit the image via a :

(a) 1 Mbps DSL connection?

(b) 10 Mbps Ethernet connection?

(c) 10 Gbps Optical connection?

A MP3 file with a size of 30 · 106 bits must be transferred from terminal device A to terminal
device B. The signal propagation speed is 200,000 km/s. A and B are directly connected by a
link with a length of 5,000 km. The file is transferred as a single message that has a size of
30 · 106 bits. No network protocol headers or trailers exist.
Calculate the transfer time (latency) of the file, when the data rate of the computer network
between both terminal devices is:

(a) 56 kbps Modem connection?

(b) 64 kbps ISDN connection?

(c) 100 Mbps Ethernet connection?

(d) 1 Gbps Ethernet connection?


Calculate for each one of the above alternatives what the volume of the network connection is.
What is the maximum number of bits that can reside inside the line between the sender and
receiver?

Exercise 2
Assume there is one router and two links between the file server (S) and client (C), as shown
in the figure below. The first link has transmission rate R1 and the second link has transmission
rate R2. Assume the file gets broken into three packets, each of size L. Ignore all propagation
and processing delays. Answer the following three questions:

(a) How long does it take from when the server starts sending the file until the client has
received the whole file if R1 ≤ R2?

(b) How long does it take from when the server starts sending the file until the client has
received the whole file if R1 > R2?

(c) In case (b), how long does the second packet spend in the router’s queue?

R1[bps] R2[bps]
S R C

Exercise 3
Consider a single link with bandwidth B and propagation delay L. It takes 1 ms for an entire
500 bytes packet to arrive at the other end of the link (that is, it takes 1 ms from the time the
first bit starts being transmitted until the last bit arrives at the other end of the link). It takes
2 ms for an entire 1500 bytes packet to arrive at the other end of the link.

(a) What is the bandwidth B of the link? (in Mbps)

(b) What is the propagation delay L of the link? (in ms)

Exercise 4
Consider the diagram below. Link 1 has length L1 m (where m stands for meters) and allows
packets to be propagated at speed S1 (m/s) , while Link 2 has length L2 m but it only al-
lows packets to be propagated at speed S2 (m/s) (because the two links are made of different
materials). Link 1 has transmission rate T1 (bit/s) and Link 2 has transmission rate T2 (bit/s).

Link 1 Link 2
A B C

Assuming nodes can send and receive bits at full rate and ignoring processing delay, consider
the following scenarios:

(a) How long would it take to send a packet of 500 Bytes from Node A to Node B given T1 =
10000 bit/s, L1 = 100000 m, and S1 = 2.5 · 108 m/s?
(b) Compute RTT (round trip time) for a packet of B Bytes sent from Node A to Node C
(packet gets transmitted back from Node C immediately after Node C receives it).

(c) At time 0, Node A sends packet P1 with D1 Bytes and then it sends another packet P2
with D2 Bytes immediately after it pushes all bits of P1 onto Link 1. When will Node C
receive the last bit of P2 ?

Exercise 5
Unlike store-and-forward, cut-through switching or forwarding allows a node inside a network
to start forwarding a packet before it has been received in its entirety. Consider a path in a
network that connects a host A to a host B via n links (1..n) through n-1 intermediate routers,
each employing cut-through forwarding.

...
A R1 R2 Rn B

Ignore processing delay and assume that there is no queuing delay. Assume that all links have
the same length d and that the speed of light in the link medium is s. Also, assume that each
link has bandwidth R and that packets of length L bits are sent through the network. Each
switch can start forwarding the packet after Lc bits have been received.

(a) What is the total latency for a single packet (counted from first bit sent at A until last bit
received at B)?

(b) How much did cut-through switching reduce the latency for sending a single packet end-
to-end, compared to store-and-forward?

Common questions

Powered by AI

The propagation delay across a 5000 km link at 200,000 km/s is 5000 / 200,000 seconds = 0.025 seconds. For a 56 kbps connection transferring 30 * 10^6 bits, the transmission time is 30,000,000 / 56,000 = 535.714 seconds. Including propagation delay, total time is 535.739 seconds. For 1 Gbps, transmission time is 30 seconds, and total time is 30.025 seconds. This shows that propagation delay becomes negligible at higher speeds .

The max number of bits inside a link is derived from bandwidth (R) and propagation delay (d/s). Calculated as product of rate and delay: R * (d/s). It represents link's data occupancy under continuous transmission conditions, crucial for understanding channel utilization and optimizing flow control .

The image size is 4080x1830 pixels, with 3 bytes per pixel, resulting in a total size of 4080 * 1830 * 3 bytes = 22,377,600 bytes. To convert to bits, multiply by 8, giving 179,020,800 bits. The transmission time over a 56 kbps Modem connection is calculated as total bits divided by the transmission rate, i.e., 179,020,800 bits / 56,000 bits per second = 3,196.8 seconds or approximately 53.28 minutes .

When R1 > R2, the second packet must wait in the router's queue until the first packet completes its transmission on the slower link R2. The time taken depends on the packet size L and the rate R2, calculated as L/R2 seconds. This queue time arises because the faster link (R1) introduces a bottleneck at the router, forcing subsequent packets to wait .

Round-trip time (RTT) calculations must consider transmission rates (T1 and T2), link lengths (L1 and L2), and propagation speeds (S1 and S2). These factors dictate time taken for send/receive phases. For distinct packet sizes, each affects throughput and transmission, altering RTT. Using efficient speed ratios maximizes performance while lowering RTT .

With an 85% compression, the image size is reduced by 85%, resulting in 15% of the original size. Therefore, the compressed image size is 179,020,800 * 0.15 = 26,853,120 bits. Over a 1 Mbps (1,000,000 bits per second) DSL connection, the transmission time is 26,853,120 bits / 1,000,000 bits per second = 26.853 seconds .

Understanding packet transmission time aids in identifying bottlenecks, allowing optimizations like changing packet routing strategies, link upgrades, or queue management. These enhance throughput, reduce latency, and maintain quality of service, vital in networks supporting real-time applications or large data volumes .

Cut-through switching reduces latency as forwarding begins after Lc bits, unlike waiting for the entire L bits in store-and-forward. Total latency is reduced because each switch dynamically forwards as bits arrive, trimming per-link wait times to (L - Lc)/R, cumulatively across n links. The reduction is significant in high-speed connections and large L values .

For the 500-byte packet transfer time of 1 ms, the bandwidth B = (500 bytes * 8 bits/byte) / 0.001 s = 4,000,000 bps or 4 Mbps. For the 1500-byte packet taking 2 ms, B = (1500*8 bits)/0.002 s = 6,000,000 bps or 6 Mbps. Assuming similar propagation delays provide different bandwidth values implies calculation assumptions or constraints need review .

Optical links offer higher bandwidths (up to 10 Gbps) and near-light propagation speeds, reducing transmission times to fraction of that on electrical or radio links despite similar distances. Greater bandwidth allows larger data handling with marginal delay, significantly increasing efficiency for high-volume transfers .

You might also like