S8 · Lesson 40 · ARQ and link throughput
Frame errors, stop-and-wait, go-back-N and selective repeat, window sizes, frame length and hybrid ARQ
Forward error correction leaves some residual errors, and most data must arrive perfectly. Links therefore add a cyclic redundancy check to every frame and ask for a retransmission when it fails: automatic repeat request. How much of the raw bit rate survives depends on the frame error rate, on how long the link takes to say "resend" compared with how long a frame takes to send, and on how many frames may be in flight at once. On a satellite hop, a naive protocol can waste 99.8% of the channel.
- The curve is a link's efficiency against frame length when each frame carries a fixed H-bit header and bits err independently with probability p: .
- Short frames waste the header; long frames are too often lost. The best length is near for small p.
- With a 48-bit header at p = 10⁻⁵, the best frames are about 2200 bits long and 95.7% efficient.
Predict
A geostationary satellite link runs at 10 Mb/s with 1500-byte frames and a one-way delay of 250 ms. With stop-and-wait ARQ and no errors, what fraction of the channel carries data?
A frame takes 1.2 ms to send but 500 ms to be acknowledged, so a = 250/1.2 = 208 and the efficiency is 1/(1 + 2a) = 0.24%. Keeping the channel full needs 1 + 2a = 418 frames in flight: a sliding window that large, or a protocol designed for long delays.
Name it
Frame errors
A frame of L bits with independent bit errors of probability p fails with probability . A CRC detects almost all of these (a 32-bit CRC misses about one in corrupted frames).
Protocols
With a = (propagation delay over transmission time), ignoring acknowledgment and processing times:
- Stop-and-wait: send, wait for the acknowledgment, repeat: .
- Go-back-N with window W ≥ 1 + 2a: on an error, resend that frame and all after it: .
- Selective repeat with W ≥ 1 + 2a: resend only the bad frames: , but the receiver must buffer out-of-order frames.
A window smaller than 1 + 2a caps the efficiency at about W/(1 + 2a) even without errors.
Frame length
With an H-bit header, the useful fraction is , maximized at
Hybrid ARQ
Instead of discarding a failed frame, hybrid ARQ keeps it: chase combining adds the retransmission's soft values, doubling the SNR (3 dB) with each copy; incremental redundancy sends extra parity bits instead, lowering the code rate step by step. Cellular systems (LTE, 5G) and Wi-Fi rely on it.
Worked example
A terrestrial link has a = 0.5 and 12 000-bit frames with bit error probability 10⁻⁵. Compare the three protocols.
Show the solution
- Frame error probability.
- Stop-and-wait.
- Go-back-N.
- Selective repeat.
- What sets the loss. Even with a short delay, waiting for each acknowledgment halves the throughput; once frames flow continuously, the error rate sets the remaining loss.
Answer 44.3% for stop-and-wait, 79.7% for go-back-N and 88.7% for selective repeat.
Worked example
Frames carry a 48-bit header and see bit errors with probability 10⁻⁵. What frame length is best, and how much is lost with 1000- or 10 000-bit frames?
Show the solution
- Best length.
- Efficiency there.
- 1000-bit frames. The header costs more: 94.3%.
- 10 000-bit frames. Too many frames fail: 90.0%.
- A broad optimum. The optimum is broad, so protocols pick a convenient size near it.
Answer about 2215 bits, for 95.7%; 1000-bit frames give 94.3% and 10 000-bit frames 90.0%.
Worked example
A hybrid-ARQ receiver chase-combines up to four copies of a frame. How much SNR does each extra copy add?
Show the solution
- Combining k copies. The k copies' signal amplitudes add coherently, k² times the power, while their independent noise adds only k times the noise power, so the SNR grows k-fold.
- Two, three and four copies.
- In practice. A frame that failed at 2 dB below the decoder's threshold usually succeeds on the first retransmission.
Answer the SNR grows k-fold: 3.0 dB with two copies, 4.8 dB with three and 6.0 dB with four.
Check
Frames of 1000 bits see independent bit errors with probability 1 × 10⁻⁵.
(a)
What is the frame error probability?
(b)
What fraction of frames gets through first time?
Check
A 10 Mb/s link sends 1500-byte frames over a one-way propagation delay of 250 ms.
(a)
What is a?
(b)
How many frames must be in flight to keep the channel full?
Check
A link has frame error probability 0.1 and a = 0.5, with windows large enough for go-back-N and selective repeat.
(a)
What efficiency does stop-and-wait give?
(b)
And go-back-N?
Check
Frames carry a 48-bit header; bits err with probability 1 × 10⁻⁶.
(a)
What frame length is best?
(b)
What efficiency does it reach?
Check
A hybrid-ARQ receiver chase-combines 3 copies, each received at −2 dB SNR.
(a)
What SNR does the combination reach?
Check
A sliding-window protocol has a window of 64 frames on a link with a = 10, and no errors.
(a)
What efficiency can it reach?
Check
Why does selective repeat beat go-back-N on a long-delay link with occasional errors?
Check
Frames of L bits (H of them header) see bit errors with probability p; a = propagation over frame time.
Step 1
What is the frame error probability P?
Type it the way you would write it, like 3sin(2πft) or 3*sin(2*pi*f*t). Angles can be in radians or carry a degree sign, like 45°.
Step 2
What is go-back-N's efficiency (ignoring the header)?
Step 3
What useful fraction does selective repeat leave after the header?
Check
Write efficiency(protocol, P, a) for 'sw', 'gbn' and 'sr', and best_frame(H, p): the integer frame length maximizing , checking the integers around the closed form.
Python 3.14 with numpy and matplotlib, running in your browser. Tab indents; press Esc and then Tab to move on.
Explain why
Why does stop-and-wait ARQ perform so badly on a satellite link, and what fixes it?
With stop-and-wait, the sender transmits one frame and then sits idle until its acknowledgment comes back, a full round trip later. On a geostationary satellite the round trip is about half a second, while a frame at megabits per second takes only a millisecond or so to send, so the channel is busy for a tiny fraction of the time. The fix is to keep sending while waiting: a sliding window lets many frames be in flight, and with a window of at least one plus twice the ratio of delay to frame time, the channel stays full. Errors are then handled by resending only the affected frames, which keeps efficiency close to the fraction of frames that arrive intact.
Practice
Keep practicing
9 kinds of problem on this topic, dealt one at a time with new numbers every time, for as long as you like.