Course overviewTopic 18 / 31
Computer Networks • Deep Lesson 14 min Transport Layer: TCP & UDP

Flow Control vs Congestion Control: rwnd, cwnd & Slow Start

TCP has two different reasons to limit how much data can be in flight. Flow control protects the receiver from being overwhelmed; congestion control protects the network from overload. The receiver advertises a receive window (rwnd), while the sender also maintains a congestion window (cwnd). The amount of outstanding data is constrained by both.

LEARNING LOOPWatch→Read→Inspect→Retrieve→Teach back
Flow Control vs Congestion Control: rwnd, cwnd & Slow Start
Week 3–4 · Topic 18 / 31
Visual model

Watch the structure first. Then read the technical details.

rwnd
min(rwnd,cwnd)
in-flight bytes
ACK/loss feedback
new cwnd
Article companion· Week 3–4

TCP has two different reasons to limit how much data can be in flight. Flow control protects the receiver from being overwhelmed; congestion control protects the network from overload. The receiver advertises a receive window (rwnd), while the sender also maintains a congestion window (cwnd). The amount of outstanding data is constrained by both.

01

Flow control

The receiver advertises available buffer space. If the receiver cannot keep up, the sender must slow down even when the network itself is healthy.

02

Congestion control

The sender infers network capacity from acknowledgements and loss/ECN signals. Slow start probes capacity rapidly, while congestion avoidance grows more cautiously.

03

The effective window

A simplified mental model is send_window ≈ min(rwnd, cwnd). Real TCP behavior includes many additional limits and algorithms, but this minimum is the crucial conceptual anchor.

DUAL CODING

See the mechanism before you memorize it

One diagram, one causal story, one reconstruction task.

VISUAL RECONSTRUCTION

Flow control (rwnd) vs congestion control (cwnd, slow start) — causal map

4 stages
01

Receiver

Advertises rwnd based on available receive buffer.

02

Sender

Tracks cwnd based on congestion-control state.

03

In flight

Outstanding bytes cannot exceed the effective sending window.

04

Feedback

ACK progress, loss and ECN-like signals update the control state.

Trace the mechanism from left to right. On smaller screens, follow the numbered sequence. Then redraw the same flow without looking.
ACTIVE RECONSTRUCTION

Draw the idea yourself

Rebuild the core flow on a real canvas before moving to the worked walkthrough.

SKETCHFLOW

Flow control (rwnd) vs congestion control (cwnd, slow start) — practice canvas

Sketch the Flow control (rwnd) vs congestion control (cwnd, slow start) mechanism from memory. Label the input, transformation, observation, and transfer.

Practice canvas ready

The canvas loads when you reach this section.

Draw first. Compare second.Touch + mouse friendly
STEP BY STEP

Walk the system

01

Receiver

Advertises rwnd based on available receive buffer.

02

Sender

Tracks cwnd based on congestion-control state.

03

In flight

Outstanding bytes cannot exceed the effective sending window.

04

Feedback

ACK progress, loss and ECN-like signals update the control state.

05

Adapt

The sender grows, holds or reduces its sending rate.

CONCRETE ARTIFACT

Core relationship

Keep the two causes separate in your head. A slow receiver and a congested network are not the same problem.

textcopy → rebuild → modify
effective_window = min(rwnd, cwnd)
slow start: rapid probing
congestion avoidance: cautious growth
loss/congestion signal: reduce sending rate
MISCONCEPTIONS

What usually goes wrong

Use rwnd and cwnd interchangeably.

Say slow start is 'slow' in absolute speed; it can increase aggressively.

Assume packet loss always means the physical cable is broken.

RETRIEVAL PRACTICE

Close the tab. Rebuild it from memory.

Read the question, answer aloud, then reveal.

Who controls rwnd?Reveal answer

The receiver, based on available receive buffer capacity.

Who controls cwnd?Reveal answer

The sender's congestion-control algorithm, using network feedback.

Why is min(rwnd, cwnd) useful?Reveal answer

It reminds you that either the receiver or the network can be the current bottleneck.

FEYNMAN

Teach it back in plain English

Tell two stories: a fast network with a slow receiver and a fast receiver behind a congested link. Explain which window limits each story.

EXAM / INTERVIEW

What a strong answer sounds like

This topic is frequently tested conceptually because it distinguishes host capacity from network capacity.

NEXT CONNECTION

Make this idea travel.

Connect it next to: udp-quic • tcp-packet-analysis • dns.

COURSE CONTENTS

Flow control (rwnd) vs congestion control (cwnd, slow start)

01How the Internet Works + OSI ModelWeek 1 · 4 topics0/4
02Physical & Data Link LayersWeek 1–2 · 5 topics0/5
03Network Layer: IP & RoutingWeek 2–3 · 6 topics0/6
04Transport Layer: TCP & UDPWeek 3–4 · 5 topics0/5
05Application Layer: HTTP, DNS & FriendsWeek 4–5 · 6 topics0/6
06Security & Troubleshooting ToolkitWeek 5 · 5 topics0/5