22-Elec-B4 Information Technology Networks · December 2018
Nivaar worked solution (AI-drafted; not reviewed by a licensed engineer)
Paper format. Professional Engineers of Ontario — National Examinations, December 2018, 16-Elec-B4 Information Technology Networks. Three hours, closed book; one approved Casio or Sharp calculator permitted. The paper prints five questions of 25 marks each, and any four constitute a complete paper worth 100 marks, with the marks for every sub-part shown in the left margin. All five questions are solved here, because this set is a study resource rather than an exam attempt, and a candidate choosing which four to write benefits from seeing the fifth worked out.
Reference texts. A. Leon-Garcia and I. Widjaja, Communication Networks: Fundamental Concepts and Key Architectures, 2nd ed. (the syllabus reference for this code); J. F. Kurose and K. W. Ross, Computer Networking: A Top-Down Approach, 8th ed.; A. S. Tanenbaum and D. J. Wetherall, Computer Networks, 5th ed.; W. Stallings, Wireless Communications and Networks, 2nd ed.; T. S. Rappaport, Wireless Communications: Principles and Practice, 2nd ed.; S. Sesia, I. Toufik and M. Baker, LTE — The UMTS Long Term Evolution, 2nd ed.
Question text not reproduced: the examination questions are © Engineers and Geoscientists BC. Open the official past paper (linked at the top of this page) to read the question, then follow the worked solution below.
UDP, with loss concealment and rate adaptation supplied by the application. Streamed video is delay-sensitive and loss-tolerant: a frame that arrives after its playout instant is worthless even if it is perfect, whereas a frame with a few missing macroblocks is concealed by the decoder and the viewer barely notices. TCP's reliability is bought with retransmission and in-order delivery, so a single lost segment stalls delivery of every later segment until the retransmission arrives — exactly the head-of-line blocking that empties a playout buffer — and TCP's congestion control halves the sending rate on a loss that, over a mobile link, was probably caused by fading rather than by congestion.
UDP with RTP over it gives the application timestamps and sequence numbers so it can order and time packets itself, drop what is late, conceal what is missing, and choose its own rate-adaptation policy. The honest caveat is that this is a design decision rather than a rule: streaming over HTTP, and therefore over TCP, dominates commercial video distribution because a large client-side buffer of several seconds hides the retransmissions and TCP passes through firewalls and NATs that block UDP. The distinction is between interactive or tightly buffered video, where UDP is clearly right, and pre-buffered on-demand video, where TCP is acceptable. In an exam answer, state the choice, the reason, and the condition under which the other choice becomes reasonable.
A packet switch is a statistical multiplexer with finite memory. Each output port is served at the line rate of its link, and packets destined for that port that arrive faster than the line rate are stored in the port's queue. Congestion means precisely that the aggregate arrival rate for some output exceeds its service rate, so the queue grows; and because the buffer is finite, once it is full the only thing the switch can do with the next arrival is discard it. Wired links themselves are extremely reliable — a modern fibre or copper Ethernet link has a bit-error ratio around $10^{-12}$ or better — so essentially every packet lost in a wired network is a packet that a router deliberately dropped for want of buffer space, not one corrupted in transit. That is the reasoning behind TCP's central assumption: a loss is a congestion signal.
Given. A TCP connection with initial congestion window $cwnd_1 = 1$ segment (measured in maximum segment sizes, MSS) and slow-start threshold $ssthresh = 16$ segments. Every segment sent is acknowledged, and the window is examined once per round-trip time.
Find. The value of $cwnd$ in each successive round, both while the window is below the threshold and after it has passed it.
Approach. Apply the two growth laws in turn: exponential doubling per round-trip while $cwnd$ is below $ssthresh$ (slow start), and an increase of one segment per round-trip once it reaches $ssthresh$ (congestion avoidance).
Given. The connection of part (c), but a segment sent in the third window — the round in which $cwnd = 4$ — is not acknowledged, and the sender detects the loss by retransmission timeout, so TCP re-enters slow start.
Find. The window sequence after the loss, and the features of TCP that the sequence displays.
Approach. On a timeout, Tahoe-style TCP sets $ssthresh$ to half the window in flight, resets $cwnd$ to one segment, and repeats the slow-start then congestion-avoidance cycle against the new threshold.
The example displays every mechanism the question asks to be illustrated: slow start (exponential growth from one segment), the slow-start threshold that ends it, congestion avoidance (additive linear growth), multiplicative decrease of the threshold to half the window in flight, loss as the congestion signal, and retransmission of the missing segment with timer backoff. It is worth adding that TCP Reno would behave differently had the loss been detected by three duplicate acknowledgements instead of a timeout: fast retransmit plus fast recovery would set $cwnd$ to the new $ssthresh$ of 2 rather than to 1, because the duplicate acknowledgements prove that packets are still flowing. A timeout, by contrast, is evidence that the pipe has emptied, which is why the window is reset all the way to one segment.
TCP's congestion control rests on the inference established in part (b): a lost packet means a full router queue. Over a wireless link that inference is false. A momentary fade, a burst of interference or a handover corrupts frames for a few tens of milliseconds and destroys packets while every queue in the path is empty and the bottleneck link is idle. TCP cannot tell the two causes apart — it sees only a missing acknowledgement — so it applies the congestion remedy to a non-congestion problem: it halves the threshold, drops the window to one segment, and rebuilds it over many round-trip times.
The performance loss compounds in three ways. The sender withdraws capacity precisely when the channel has recovered and is free, so the link runs far below its capability. Recovery is slow because it takes $\log_2(ssthresh)$ round-trips of slow start plus a linear climb thereafter, and a mobile round-trip time of 50–100 ms makes that a visible stall to a user. And because fades recur, the connection may be knocked back to one segment before it has recovered from the previous fade, so its average window — and hence its throughput, which is roughly $cwnd \cdot MSS / RTT$ — stays a small fraction of what the radio link could carry. The standard remedies all attack the same misdiagnosis: link-layer ARQ and hybrid ARQ hide short fades from TCP entirely, split-connection or performance-enhancing proxies terminate TCP at the base station, explicit loss notification tells the sender that a loss was not congestion, and modern congestion controllers such as BBR infer congestion from measured delay and delivery rate rather than from loss alone.
| Quantity | Result |
|---|---|
| Transport for streamed video on a mobile link | UDP (with RTP); TCP acceptable only with deep pre-buffering |
| Cause of loss in wired networks | Buffer overflow at a congested output port |
| Part (c) window sequence, rounds 1–9 | 1, 2, 4, 8, 16, 17, 18, 19, 20 |
| Segments delivered by the end of slow start | 31 |
| Part (d) new threshold after the timeout | 2 segments |
| Part (d) window sequence, rounds 1–9 | 1, 2, 4, 1, 2, 3, 4, 5, 6 |