Network Flows and Max-Flow Min-Cut

How much material can you push through a pipeline network per unit time? Each pipe has a limited capacity. This concrete question was first formalized for railway logistics in the 1950s. It turns out to be one of the most productive problems in all of combinatorial optimization. A flow network models the pipeline as a directed graph with capacities on the edges. It has a source producing material and a sink consuming it. The problem asks for the largest amount of flow that can move from source to sink. This flow must never violate any capacity constraint. This problem matters far beyond plumbing. An enormous number of combinatorial questions can be encoded as flow problems. These include bipartite matching, edge- and vertex-connectivity, scheduling with resource constraints, image segmentation, and project selection. The max-flow min-cut theorem is due to Ford and Fulkerson. It was also discovered independently by Elias, Feinstein, and Shannon. It says that the maximum amount of flow you can send equals something specific. That quantity is the minimum "bottleneck" capacity of any cut separating source from sink. This duality is not just elegant. It is algorithmically constructive. It gives rise to the Ford–Fulkerson method and its many refinements. These remain workhorses of combinatorial optimization to this day. The big picture is that flow networks give a unifying language. They unify a family of min-max theorems in combinatorics. Once you have max-flow min-cut, several other results follow. Menger's Theorem on vertex-disjoint paths, König's theorem on bipartite matchings, and Hall's marriage theorem all become corollaries. They are close relatives, obtained by clever choices of capacities. This article builds the theory from the ground up. It offers precise definitions of networks, flows, and cuts. It gives a full proof of weak and strong duality via the Ford–Fulkerson augmenting-path method. It includes worked numerical examples tracing an actual execution of the algorithm. It also discusses why every hypothesis is load-bearing. These hypotheses include integrality, finiteness, and no negative capacities. By the end, you will be able to do several things. You will state and prove the max-flow min-cut theorem from first principles. You will run Ford–Fulkerson by hand on a small network. You will explain precisely why irrational capacities can break naive implementations. You will see how this single theorem seeds an entire research program. This program culminates in Menger's theorem and beyond.

Key takeaways
  • A flow network is a digraph with nonnegative edge capacities, a source ss, and a sink tt.
  • A flow obeys capacity constraints and conservation of flow at every vertex except s,ts, t.
  • An ss-tt cut partitions vertices into a source side and sink side; its capacity is the total capacity of edges crossing from source side to sink side.
  • Weak duality: every flow value is at most every cut capacity — flows and cuts bound each other from opposite sides.
  • The max-flow min-cut theorem says the maximum flow value exactly equals the minimum cut capacity, with equality certified by the absence of augmenting paths.
  • Key idea: pushing flow along augmenting paths in a residual graph until none remain simultaneously finds a maximum flow and exhibits a minimum cut.

Where this lives today

Flow networks underlie bipartite matching algorithms: constructing a unit-capacity bipartite flow network and computing max flow gives the maximum matching size directly, recovering König's theorem and Hall's marriage theorem as special cases. In connectivity theory, setting all capacities to 11 (or to vertex-splitting gadgets) and computing max flow between two vertices computes the maximum number of edge- (or vertex-) disjoint paths between them, which is precisely the content of Menger's Theorem — the natural next theorem in this circle of ideas, connecting flows back to Vertex and Edge Connectivity. In computer vision, min-cut/max-flow algorithms solve binary image segmentation (foreground/background) by modeling pixel similarity as edge capacities, an approach popularized by Boykov and Jolly. In operations research and scheduling, project selection problems with prerequisite and profit structures reduce to min-cut computations (the "closure problem"). In statistical physics, the max-flow min-cut duality is closely related to computing ground states of certain random-field Ising models via graph cuts. In cryptography and network reliability, min-cut values quantify the minimum number of compromised links needed to disconnect a network, directly informing robustness metrics. In circuit design and VLSI routing, flow techniques bound achievable wire routing capacity between terminal regions.

Ask the tutor: How does the max-flow min-cut theorem's proof structure directly yield Menger's theorem on disjoint paths?

DefinitionFlow network, flow, and cut

A flow network is a tuple N=(G,s,t,c)N = (G, s, t, c) where:

  • G=(V,E)G = (V, E) is a finite directed graph (loops and parallel edges disallowed for simplicity, though the theory extends to multigraphs),
  • s,t∈Vs, t \in V are distinguished vertices called the source and sink, with s≠ts \neq t,
  • c:E→R≥0c : E \to \mathbb{R}_{\geq 0} is a capacity function assigning a nonnegative real number to each edge.

We extend cc to all ordered pairs (u,v)∈V×V(u,v) \in V \times V by setting c(u,v)=0c(u,v) = 0 whenever (u,v)∉E(u,v) \notin E. A flow on NN is a function f:V×V→Rf : V \times V \to \mathbb{R} satisfying: 1. Capacity constraint: 0≤f(u,v)≤c(u,v)0 \leq f(u,v) \leq c(u,v) for every (u,v)∈V×V(u,v) \in V \times V. 2. Conservation: for every v∈V∖{s,t}v \in V \setminus \{s,t\},

∑u∈Vf(u,v)=∑w∈Vf(v,w).\sum_{u \in V} f(u,v) = \sum_{w \in V} f(v,w).

The value of a flow ff is

∣f∣=∑v∈Vf(s,v)−∑v∈Vf(v,s),|f| = \sum_{v \in V} f(s,v) - \sum_{v \in V} f(v,s),

the net flow leaving the source. An ss-tt cut is a partition (S,T)(S,T) of VV with s∈Ss \in S and t∈Tt \in T. Its capacity is

c(S,T)=∑u∈S∑v∈Tc(u,v),c(S,T) = \sum_{u \in S} \sum_{v \in T} c(u,v),

the total capacity of edges directed from SS to TT (edges from TT to SS do not count). A maximum flow is a flow of maximum possible value; a minimum cut is an ss-tt cut of minimum possible capacity.

Intuition

Picture the network as a system of one-way pipes, with ss a pump station and tt a reservoir. Water flows along edges, each pipe has a maximum throughput given by its capacity, and at every intermediate junction whatever flows in must flow out — no water is created, destroyed, or stored anywhere except at ss (production) and tt (consumption). The value of the flow is the total rate at which water leaves the pump. Now imagine trying to sabotage this system by cutting a set of pipes so that no water can possibly get from ss to tt. A cut (S,T)(S,T) corresponds to grouping junctions into "source side" SS and "sink side" TT; to physically disconnect ss from tt you must sever every pipe running from SS into TT (pipes running backward from TT into SS do not need to be touched, since water is not trying to flow that way). The capacity of the cut is the total bandwidth you must destroy. Intuitively, no flow can ever exceed the capacity of any single cut, because every unit of flow that reaches tt must, at some point, cross from the SS-side to the TT-side of that cut. The深 theorem asserts something stronger and non-obvious: not only is max-flow bounded by every cut, it is achieved by the tightest possible cut — there is no gap.

Figure
A small flow network with a candidate ss-tt cut separating S={s,a}S=\{s,a\} from T={b,t}T=\{b,t\}
cut (S,T) s a b t c=10 c=4 c=6 c=8 c=10

Key structural device: the residual graph

The proof of the max-flow min-cut theorem is built on the notion of a residual graph, which records how much more flow can still be pushed along, or canceled back along, each edge.

DefinitionResidual graph

Given a flow network N=(G,s,t,c)N=(G,s,t,c) and a flow ff, the residual capacity of an ordered pair (u,v)∈V×V(u,v) \in V \times V is

cf(u,v)=c(u,v)−f(u,v)+f(v,u).c_f(u,v) = c(u,v) - f(u,v) + f(v,u).

The residual graph GfG_f has vertex set VV and an edge (u,v)(u,v) whenever cf(u,v)>0c_f(u,v) > 0, with capacity cf(u,v)c_f(u,v). An augmenting path is a directed path from ss to tt in GfG_f.

The term c(u,v)−f(u,v)c(u,v) - f(u,v) is the leftover forward capacity on edge (u,v)(u,v); the term f(v,u)f(v,u) is the amount of flow on the reverse edge that could be "undone" by pushing flow the other way. Both contribute usable residual capacity.

LemmaAugmenting increases value

Let ff be a flow on NN and let PP be an augmenting path in GfG_f with bottleneck capacity

γ=min⁡(u,v)∈Pcf(u,v)>0.\gamma = \min_{(u,v) \in P} c_f(u,v) > 0.

Define f′f' by, for each ordered pair (u,v)(u,v) on PP (in the direction traversed by PP), decreasing whichever of f(u,v),f(v,u)f(u,v), f(v,u) can absorb the change: formally set

f′(u,v)=f(u,v)+γ,f′(v,u)=f(v,u)−γif f(v,u)≥γ,f'(u,v) = f(u,v) + \gamma, \quad f'(v,u) = f(v,u) - \gamma \quad \text{if } f(v,u) \geq \gamma,

and otherwise split the increment between raising f(u,v)f(u,v) and reducing f(v,u)f(v,u) to 00 so that net flow along (u,v)(u,v) increases by exactly γ\gamma; leave ff unchanged on pairs not on PP. Then f′f' is a valid flow with ∣f′∣=∣f∣+γ|f'| = |f| + \gamma.

Proof

We must check that f′f' satisfies the capacity constraint, conservation, and the value formula.

Capacity constraint. Fix an edge of PP, traversed from uu to vv. By definition of residual capacity, γ≤cf(u,v)=c(u,v)−f(u,v)+f(v,u)\gamma \le c_f(u,v) = c(u,v) - f(u,v) + f(v,u). The update rule increases the net forward flow along (u,v)(u,v) by exactly γ\gamma, meaning f′(u,v)−f′(v,u)=f(u,v)−f(v,u)+γf'(u,v) - f'(v,u) = f(u,v) - f(v,u) + \gamma. Since f(u,v)−f(v,u)+γ≤c(u,v)f(u,v) - f(v,u) + \gamma \le c(u,v) (rearranging the residual capacity inequality), and since the update only moves mass between f(u,v)f(u,v) and f(v,u)f(v,u) while keeping both nonnegative (the "otherwise" clause specifically caps f(v,u)f(v,u) at 00 before raising f(u,v)f(u,v) further), we get 0≤f′(u,v)≤c(u,v)0 \le f'(u,v) \le c(u,v) and 0≤f′(v,u)≤c(v,u)0 \le f'(v,u) \le c(v,u). All edges off PP are unchanged, so capacity constraints continue to hold everywhere.

Conservation. Let w∈V∖{s,t}w \in V \setminus \{s,t\} be an internal vertex of PP, entered via edge (u,w)(u,w) and left via edge (w,x)(w,x) (these are consecutive edges of the path PP, which is a simple path in GfG_f). The net inflow to ww increases by exactly γ\gamma (from the (u,w)(u,w) update) and the net outflow from ww increases by exactly γ\gamma (from the (w,x)(w,x) update); all other edges touching ww are untouched since PP is a simple path visiting ww once. Hence conservation at ww is preserved. For v∈V∖{s,t}v \in V \setminus \{s,t\} not on PP, no incident edge is modified, so conservation trivially holds.

Value. The path PP begins at ss with some first edge (s,v1)(s,v_1). The net flow leaving ss along this edge increases by γ\gamma, and no other term in the definition of ∣f∣|f| (flows on edges into or out of ss not on PP) changes, because PP is simple and passes through ss only as its starting vertex. Hence ∣f′∣=∣f∣+γ|f'| = |f| + \gamma. ■\blacksquare

∎
TheoremMax-Flow Min-Cut

Let N=(G,s,t,c)N = (G,s,t,c) be a finite flow network with a finite vertex set and finitely many edges, each with a finite nonnegative capacity, and suppose a maximum flow exists (guaranteed, for instance, whenever the total capacity is finite and either all capacities are rational or the vertex/edge set is finite and capacities are arbitrary reals — see the discussion below). Then:

max⁡f a flow on N∣f∣  =  min⁡(S,T) an s-t cutc(S,T).\max_{f \text{ a flow on } N} |f| \;=\; \min_{(S,T) \text{ an } s\text{-}t \text{ cut}} c(S,T).

Moreover, a flow f∗f^* has maximum value if and only if the residual graph Gf∗G_{f^*} contains no augmenting path from ss to tt; in that case, letting S∗S^* be the set of vertices reachable from ss in Gf∗G_{f^*} and T∗=V∖S∗T^* = V \setminus S^*, the cut (S∗,T∗)(S^*,T^*) achieves capacity c(S∗,T∗)=∣f∗∣c(S^*,T^*) = |f^*|, hence is a minimum cut.

Proof

We proceed in three steps: weak duality (every flow value is at most every cut capacity), the equivalence of flow-maximality with the absence of augmenting paths, and the exhibition of a matching cut when no augmenting path exists. Together these give the theorem. The technique is a direct combinatorial argument together with the augmenting-path (Ford–Fulkerson) construction; no circular appeal to the theorem itself is made anywhere.

Step 1 (Weak duality). Let ff be any flow and (S,T)(S,T) any ss-tt cut. We show ∣f∣≤c(S,T)|f| \leq c(S,T). By the conservation law, for every v∈S∖{s}v \in S \setminus \{s\},

∑u∈Vf(u,v)−∑w∈Vf(v,w)=0,\sum_{u \in V} f(u,v) - \sum_{w \in V} f(v,w) = 0,

and by definition of value, for v=sv = s,

∑u∈Vf(u,s)−∑w∈Vf(s,w)=−∣f∣.\sum_{u \in V} f(u,s) - \sum_{w \in V} f(s,w) = -|f|.

Summing these equations over all v∈Sv \in S gives

∑v∈S(∑u∈Vf(u,v)−∑w∈Vf(v,w))=−∣f∣.\sum_{v \in S} \left( \sum_{u \in V} f(u,v) - \sum_{w \in V} f(v,w) \right) = -|f|.

Split each inner sum over u∈Vu \in V (respectively w∈Vw \in V) into the part inside SS and the part in TT. Terms with both endpoints in SS cancel exactly, since f(u,v)f(u,v) for u,v∈Su,v \in S appears once with a ++ sign (as an inflow to vv) and once with a −- sign (as an outflow from uu), for every such pair with u≠vu \ne v; contributions from u=vu = v do not arise since f(v,v)f(v,v) is not part of the network (GG has no loops). What remains is

∑v∈S∑u∈Tf(u,v)−∑v∈S∑w∈Tf(v,w)=−∣f∣,\sum_{v \in S} \sum_{u \in T} f(u,v) - \sum_{v \in S} \sum_{w \in T} f(v,w) = -|f|,

i.e.

∑v∈S∑w∈Tf(v,w)−∑v∈S∑u∈Tf(u,v)=∣f∣.\sum_{v \in S}\sum_{w \in T} f(v,w) - \sum_{v \in S}\sum_{u \in T} f(u,v) = |f|.

The first sum is over edges from SS to TT and is bounded above by c(S,T)c(S,T) since 0≤f(v,w)≤c(v,w)0 \le f(v,w) \le c(v,w) for each such pair; the second sum is a sum of nonnegative quantities (f(u,v)≥0f(u,v)\ge 0) and so is itself nonnegative. Hence

∣f∣≤∑v∈S∑w∈Tf(v,w)≤∑v∈S∑w∈Tc(v,w)=c(S,T).|f| \le \sum_{v \in S}\sum_{w \in T} f(v,w) \le \sum_{v \in S}\sum_{w \in T} c(v,w) = c(S,T).

This proves ∣f∣≤c(S,T)|f| \le c(S,T) for every flow ff and every cut (S,T)(S,T), establishing weak duality.

Step 2 (No augmenting path   ⟺  \iff maximum flow). (⇐\Leftarrow, contrapositive) Suppose ff admits an augmenting path PP in GfG_f. By the Lemma, there is a flow f′f' with ∣f′∣=∣f∣+γ>∣f∣|f'| = |f| + \gamma > |f| for some γ>0\gamma > 0. Hence ff is not a maximum flow. (⇒\Rightarrow) Suppose GfG_f has no augmenting path, i.e. tt is not reachable from ss in GfG_f. Let S∗S^* be the set of all vertices reachable from ss in GfG_f (including ss itself), and let T∗=V∖S∗T^* = V \setminus S^*. Since t∉S∗t \notin S^*, this is a valid ss-tt cut. We compute c(S∗,T∗)c(S^*,T^*). For any u∈S∗u \in S^* and v∈T∗v \in T^*: since vv is not reachable from ss while uu is, the edge (u,v)(u,v) cannot be a residual edge — otherwise vv would be reachable via uu, contradicting v∉S∗v \notin S^*. Hence cf(u,v)=0c_f(u,v) = 0, i.e.

c(u,v)−f(u,v)+f(v,u)=0.c(u,v) - f(u,v) + f(v,u) = 0.

Since c(u,v)≥0c(u,v) \ge 0 and f(u,v),f(v,u)≥0f(u,v), f(v,u) \ge 0, and since c(u,v)−f(u,v)≥0c(u,v) - f(u,v) \geq 0 by the capacity constraint on ff, the equation c(u,v)−f(u,v)=−f(v,u)≤0c(u,v) - f(u,v) = -f(v,u) \leq 0 together with c(u,v)−f(u,v)≥0c(u,v)-f(u,v) \ge 0 forces both to be 00:

f(u,v)=c(u,v),f(v,u)=0.f(u,v) = c(u,v), \qquad f(v,u) = 0.

That is, every edge from S∗S^* to T∗T^* is saturated (carries flow equal to its capacity), and every edge from T∗T^* to S∗S^* carries zero flow. Now apply the identity derived in Step 1 (which holds for the specific cut (S∗,T∗)(S^*,T^*), for the specific flow ff):

∣f∣=∑v∈S∗∑w∈T∗f(v,w)−∑v∈S∗∑u∈T∗f(u,v)=∑v∈S∗∑w∈T∗c(v,w)−0=c(S∗,T∗).|f| = \sum_{v \in S^*}\sum_{w \in T^*} f(v,w) - \sum_{v \in S^*}\sum_{u \in T^*} f(u,v) = \sum_{v \in S^*}\sum_{w \in T^*} c(v,w) - 0 = c(S^*,T^*).

So ∣f∣=c(S∗,T∗)|f| = c(S^*, T^*). Combined with weak duality (∣f∣≤c(S,T)|f| \le c(S,T) for every cut, in particular for (S∗,T∗)(S^*,T^*), giving no new information here, but also ∣f∣≤c(S,T)|f| \le c(S,T) for every other cut (S,T)(S,T) while ∣f∣|f| actually equals one specific cut's capacity), we get: for every cut (S,T)(S,T),

c(S∗,T∗)=∣f∣≤c(S,T).c(S^*,T^*) = |f| \le c(S,T).

Hence (S∗,T∗)(S^*,T^*) is a minimum cut, and ff, having value equal to the capacity of some cut while being ≤\le the capacity of every cut, cannot be improved — indeed by weak duality no flow can exceed c(S∗,T∗)=∣f∣c(S^*,T^*) = |f|, so ff is a maximum flow.

Step 3 (Existence and conclusion). By hypothesis a maximum flow f∗f^* exists. By Step 2 applied in the forward direction (contrapositive), f∗f^* admits no augmenting path in Gf∗G_{f^*} — otherwise it would not be maximum. By Step 2 applied in the reverse direction, the reachable set S∗S^* from ss in Gf∗G_{f^*} yields a cut with c(S∗,T∗)=∣f∗∣c(S^*,T^*) = |f^*|, and this cut is a minimum cut. Therefore

max⁡f∣f∣=∣f∗∣=c(S∗,T∗)=min⁡(S,T)c(S,T),\max_f |f| = |f^*| = c(S^*,T^*) = \min_{(S,T)} c(S,T),

proving the theorem. The equivalence "f∗f^* is maximum   ⟺  \iff Gf∗G_{f^*} has no augmenting path" is exactly the content of Step 2. ■\blacksquare

∎
CorollaryFord–Fulkerson terminates with integer capacities

If every capacity c(e)c(e) is a positive integer, then starting from the zero flow and repeatedly augmenting along any ss-tt path in the residual graph (the Ford–Fulkerson method) terminates after finitely many augmentations, at most ∣fmax⁡∣|f_{\max}| many, and produces a maximum flow together with a minimum cut.

Proof

By induction on the number of augmentations: the zero flow is integer-valued on every edge. If ff is integer-valued, then every residual capacity cf(u,v)=c(u,v)−f(u,v)+f(v,u)c_f(u,v) = c(u,v) - f(u,v) + f(v,u) is an integer (difference and sum of integers), so the bottleneck γ\gamma of any augmenting path is a positive integer, hence γ≥1\gamma \ge 1. By the Lemma, each augmentation strictly increases the flow value by an integer γ≥1\gamma \ge 1, so f′f' remains integer-valued and ∣f′∣≥∣f∣+1|f'| \ge |f|+1. Since the maximum flow value ∣fmax⁡∣|f_{\max}| is finite (bounded above by the capacity of any single cut, e.g. c({s},V∖{s})c(\{s\}, V\setminus\{s\}), which is finite as a finite sum of finite capacities), the value can increase at most ∣fmax⁡∣|f_{\max}| times before no augmenting path remains. By Max-Flow Min-Cut (Step 2 of the proof above), termination without an augmenting path certifies that the current flow is maximum and yields a matching minimum cut. ■\blacksquare

∎

Worked examples

Example 1: a network with an asymmetric structure and a bottleneck cut. Let GG have vertices {s,a,b,c,t}\{s,a,b,c,t\} and directed edges with capacities:

c(s,a)=9, c(s,b)=8, c(a,b)=2, c(a,c)=6, c(b,c)=1, c(b,t)=6, c(c,t)=10.c(s,a)=9,\ c(s,b)=8,\ c(a,b)=2,\ c(a,c)=6,\ c(b,c)=1,\ c(b,t)=6,\ c(c,t)=10.

Iteration 1. Start with f≡0f \equiv 0. Residual graph equals GG itself. Choose augmenting path s→a→c→ts \to a \to c \to t. Bottleneck =min⁡(9,6,10)=6= \min(9,6,10) = 6. Push 66: now

f(s,a)=6, f(a,c)=6, f(c,t)=6,∣f∣=6.f(s,a)=6,\ f(a,c)=6,\ f(c,t)=6, \qquad |f| = 6.

Iteration 2. Residual capacities: cf(s,a)=3c_f(s,a)=3, cf(a,c)=0c_f(a,c) = 0 (saturated, but reverse edge cf(c,a)=6c_f(c,a)=6 now exists), cf(c,t)=4c_f(c,t)=4, all others unchanged from GG. Choose path s→b→ts \to b \to t. Bottleneck =min⁡(8,6)=6=\min(8,6)=6. Push 66: now

f(s,b)=6, f(b,t)=6,∣f∣=12.f(s,b)=6,\ f(b,t)=6, \qquad |f| = 12.

Iteration 3. Residual capacities now: cf(s,a)=3c_f(s,a)=3, cf(s,b)=2c_f(s,b)=2, cf(b,t)=0c_f(b,t) = 0 (saturated; reverse cf(t,b)=6c_f(t,b)=6), cf(a,c)=0c_f(a,c)=0 (reverse cf(c,a)=6c_f(c,a)=6), cf(c,t)=4c_f(c,t)=4, cf(a,b)=2c_f(a,b)=2, cf(b,c)=1c_f(b,c)=1. Try path s→a→b→c→ts \to a \to b \to c \to t: capacities along it are 3,2,1,43, 2, 1, 4; bottleneck =1=1. Push 11: update

f(s,a)=7, f(a,b)=1, f(b,c)=1, f(c,t)=7,∣f∣=13.f(s,a) = 7,\ f(a,b)=1,\ f(b,c)=1,\ f(c,t) = 7,\qquad |f| = 13.

Iteration 4. Residual capacities: cf(s,a)=2c_f(s,a) = 2, cf(s,b)=2c_f(s,b)=2, cf(a,b)=1c_f(a,b) = 1 (net so far 11, capacity 22), cf(b,c)=0c_f(b,c) = 0 (saturated; reverse cf(c,b)=1c_f(c,b) = 1), cf(a,c)=0c_f(a,c) = 0 still (reverse cf(c,a)=6c_f(c,a)=6), cf(c,t)=3c_f(c,t) = 3, cf(b,t)=0c_f(b,t)=0 (reverse cf(t,b)=6c_f(t,b)=6). Is there still an augmenting path? From ss we can reach aa (via cf(s,a)=2c_f(s,a)=2) and bb (via cf(s,b)=2c_f(s,b)=2 and via a→ba\to b). From aa, edges available: a→ba\to b (cf=1c_f=1), reverse a→a \to nothing else new. From bb: b→cb \to c is saturated (0), but is there b→tb \to t? No, saturated. Reverse edges from bb: cf(b,a)c_f(b,a)? That would require f(a,b)>0f(a,b) > 0, and indeed f(a,b)=1>0f(a,b)=1>0 so cf(b,a)≥1c_f(b,a) \ge 1— but aa is already reached, no new information. From cc (not yet reached): can we reach cc? Only via b→cb \to c (saturated) or reverse of c→ac \to a, i.e. edge cf(c,a)c_f(c,a) which goes from cc, not to cc — irrelevant for reaching cc. Also reverse of c→tc\to t doesn't help reach cc from SS. So cc is unreachable, hence tt is unreachable (all paths to tt pass through cc or through the saturated b→tb\to t). So S∗={s,a,b}S^* = \{s,a,b\}, T∗={c,t}T^* = \{c,t\}. Compute c(S∗,T∗)c(S^*,T^*): edges from S∗S^* to T∗T^* are a→ca\to c (capacity 66) and b→cb \to c (capacity 11); note b→tb \to t also crosses (S∗S^* to T∗T^*), capacity 66. Total:

c(S∗,T∗)=6+1+6=13.c(S^*,T^*) = 6 + 1 + 6 = 13.

This matches ∣f∣=13|f|=13 exactly, confirming by the theorem that ff is maximum and (S∗,T∗)(S^*,T^*) is a minimum cut. The bottleneck of the whole network is the combined capacity out of {s,a,b}\{s,a,b\}, namely 1313, even though individual edges like c(s,a)=9c(s,a)=9 or c(c,t)=10c(c,t)=10 look larger in isolation — the theorem correctly identifies the global obstruction, not any single edge.

Example 2: using a residual back-edge to correct an earlier greedy choice. Take vertices {s,x,y,t}\{s,x,y,t\} with edges

c(s,x)=10,c(s,y)=10,c(x,y)=2,c(x,t)=4,c(y,t)=9.c(s,x) = 10,\quad c(s,y)=10,\quad c(x,y)=2,\quad c(x,t)=4,\quad c(y,t)=9.

Iteration 1. Greedily augment along s→x→ts\to x \to t with bottleneck min⁡(10,4)=4\min(10,4) = 4. Set f(s,x)=4,f(x,t)=4f(s,x)=4, f(x,t)=4, ∣f∣=4|f|=4. Iteration 2. Augment along s→y→ts \to y \to t, bottleneck min⁡(10,9)=9\min(10,9)=9. Set f(s,y)=9,f(y,t)=9f(s,y)=9, f(y,t)=9, ∣f∣=13|f| = 13. Iteration 3. Residual graph: cf(s,x)=6c_f(s,x) = 6, cf(s,y)=1c_f(s,y)=1, cf(x,y)=2c_f(x,y) = 2 (untouched), cf(x,t)=0c_f(x,t) = 0 (saturated; reverse cf(t,x)=4c_f(t,x) = 4), cf(y,t)=0c_f(y,t) = 0 (saturated; reverse cf(t,y)=9c_f(t,y)=9). Also reverse residuals cf(x,s)=4c_f(x,s) = 4, cf(y,s)=9c_f(y,s) = 9 exist but point the wrong way for reaching tt. Path attempt: s→x→y→⋯s \to x \to y \to \cdots? Edge x→yx\to y has residual capacity 2>02 > 0. From yy, forward to tt is saturated (residual 00). From yy, is there anywhere else? y→sy \to s (reverse of s→ys\to y) doesn't help. So this branch dead-ends at yy without reaching tt. Check all reachability from ss carefully: s→xs\to x (residual 6), s→ys \to y (residual 1), x→yx \to y (residual 2). So reachable set is {s,x,y}\{s,x,y\}. From xx: only x→yx\to y available (since x→tx\to t saturated). From yy: nothing forward-usable reaches tt (saturated), and y→sy\to s is not useful. So tt is unreachable: S∗={s,x,y}S^* = \{s,x,y\}, T∗={t}T^* = \{t\}.

c(S∗,T∗)=c(x,t)+c(y,t)=4+9=13=∣f∣.c(S^*, T^*) = c(x,t) + c(y,t) = 4 + 9 = 13 = |f|.

Max flow is 1313, matching the min cut exactly, and note the edge x→yx\to y (capacity 22) was never used in the final flow, illustrating that not every edge need carry flow in an optimal solution — its potential role was superseded once x→tx\to t and y→ty \to t were both saturated directly from ss.

CounterexampleDropping finiteness of capacities: irrational capacities can break termination

The theorem's guarantee that some maximum flow exists, and the corollary's proof of termination, both use finiteness/integrality in an essential way. Here is a classical example (due to Ford and Fulkerson) showing that with real-valued capacities, a poorly chosen sequence of augmenting paths in Ford–Fulkerson can fail to terminate and even converge to a value that is not the maximum flow — so the algorithm (not the theorem's existence statement) needs care. Consider a network with vertices s,ts, t and internal vertices A1,B1,A2,B2A_1, B_1, A_2, B_2 arranged so that there are two parallel "chains" from ss to tt crossed by two edges of capacity 11, and all other capacities set to a very large integer MM, except one designed edge whose capacity is

r=3−52,r = \frac{3-\sqrt5}{2},

an irrational number satisfying 0<r<10< r <1. By choosing augmenting paths adversarially — always picking the path that uses the small crossing edges rather than the direct high-capacity edges — one can force the sequence of augmentations to follow the recursion γn+1=γn⋅r\gamma_{n+1} = \gamma_n \cdot r (or a similar contracting recursion), so that the bottleneck amounts γn→0\gamma_n \to 0 but ∑γn\sum \gamma_n converges to a value strictly less than the true maximum flow value determined by the min cut. The algorithm runs forever, the flow value increases at every step (so naive "does the value increase?" monitoring gives no red flag), yet it never reaches, and does not even have a limit equal to, the true max flow. This shows precisely why the hypothesis of rational (or integer) capacities, or more generally a path-selection rule guaranteeing progress (such as always choosing a shortest augmenting path or a maximum-bottleneck path, as in the Edmonds–Karp refinement), is needed for the Ford–Fulkerson method to terminate correctly. The max-flow min-cut theorem itself remains true for arbitrary nonnegative real capacities on a finite graph (existence of a maximizer follows from compactness of the polytope of feasible flows and continuity of the value functional), but the naive augmenting-path algorithm, without a smarter path-selection rule, can fail to compute it.

Scope, edge cases & common traps

SituationWhat happens
Integer capacitiesFord–Fulkerson terminates in at most ∣fmax⁡∣|f_{\max}| augmentations; flow found is integral (integrality theorem).
Rational capacitiesClear denominators by scaling; reduces to the integer case, so termination is guaranteed.
Arbitrary real capacities, naive path choiceMax flow still exists and equals min cut (by compactness), but Ford–Fulkerson may fail to terminate or converge to the wrong value; use Edmonds–Karp (BFS shortest augmenting path) instead, which always terminates in O(VE)O(VE) augmentations.
Multiple sources/sinksReduce to single source/sink by adding a super-source and super-sink with infinite-capacity edges to each original source/sink.
Undirected edgesReplace each undirected edge of capacity cc by two opposite directed edges each of capacity cc (careful: this does not simply double capacity, since flow can use at most one direction's worth net).
Vertex capacitiesSplit each capacitated vertex vv into vin→voutv_{\text{in}} \to v_{\text{out}} with an edge of that capacity, to reduce to edge capacities.

The mathematician behind it

Origins · 1 minLester Randolph Ford Jr. and how this was discovered
LR
Lester Randolph Ford Jr.
1927–2017 · American mathematician, RAND Corporation and Washington University

Ford, together with Delbert Ray Fulkerson, developed the theory of network flows at the RAND Corporation in the 1950s, originally motivated by a classified study of Soviet railway capacity commissioned to identify bottleneck links. Their 1956 paper and subsequent 1962 book Flows in Networks established the max-flow min-cut theorem, the augmenting path method, and much of the vocabulary (cuts, residual capacity) still used today. Ford also co-developed the Bellman–Ford shortest path algorithm and made contributions to combinatorics and the theory of Markov chains.

History
- 1955: RAND Corporation memorandum by T. E. Harris and F. S. Ross models Soviet rail network bottlenecks as a flow problem, providing the applied origin of the theory.
- 1956: Ford and Fulkerson publish "Maximal Flow Through a Network," proving the max-flow min-cut theorem and introducing the augmenting path method.
- 1956: Independently, Elias, Feinstein, and Shannon prove an equivalent max-flow min-cut result in the context of information-theoretic network coding.
- 1962: Ford and Fulkerson publish the book Flows in Networks, systematizing the theory and applications to transportation and assignment problems.
- 1972: Edmonds and Karp publish a refinement using shortest augmenting paths, guaranteeing polynomial-time termination regardless of capacity values.
Does the max-flow min-cut theorem require the graph to have no cycles?

No. The theorem holds for arbitrary finite directed graphs, including those with directed cycles. Conservation of flow at internal vertices is a local balance condition and places no restriction on the global cycle structure of GG. In fact, an optimal flow can circulate flow around a cycle with no effect on the value (though such "wasted" circulation is never needed for an optimal solution and can always be removed without decreasing the value, by a standard flow-decomposition argument). The theorem's proof, based on reachability in the residual graph, works identically whether or not GG is acyclic.

Can capacities be zero on some edges, and does that cause problems?

Zero-capacity edges are permitted by the definition and cause no issues: such an edge simply can never carry flow (since 0≤f(u,v)≤c(u,v)=00 \le f(u,v) \le c(u,v) = 0 forces f(u,v)=0f(u,v)=0), so it behaves as if absent from the graph for the purposes of computing max flow. It is often convenient, in fact, to define c(u,v)=0c(u,v)=0 for all pairs not in EE, precisely so that the capacity function is total on V×VV \times V and formulas like c(S,T)=∑u∈S,v∈Tc(u,v)c(S,T) = \sum_{u\in S,v\in T} c(u,v) make sense without case analysis on which pairs are edges.

Is the maximum flow itself unique?

No, in general there can be many different maximum flows achieving the same optimal value, and Example 1 above touches on this: different augmenting path choices can route flow differently among edges while achieving the same total value. What the theorem guarantees is a unique optimal value, not a unique optimal flow function. Uniqueness of the flow itself typically requires additional structural assumptions (e.g., a network that is "series-parallel" with no alternative routing) and is not part of the standard theorem statement.

How does this relate to bipartite matching?

Given a bipartite graph with parts X,YX, Y, build a flow network with source ss connected to every vertex of XX by capacity-11 edges, sink tt connected from every vertex of YY by capacity-11 edges, and each original edge of the bipartite graph given capacity 11 directed from XX to YY. Because all capacities are 11, the integrality corollary guarantees an integral maximum flow, and such an integral flow of value kk corresponds exactly to a matching of size kk (each unit of flow traces out one matched pair). The max-flow min-cut theorem then shows the maximum matching size equals a minimum vertex cover size in the bipartite case, recovering König's theorem.

What is the difference between Ford–Fulkerson and Edmonds–Karp?

Ford–Fulkerson is a method: repeatedly augment along any ss-tt path in the residual graph until none exists. It is correct (terminates with a maximum flow) whenever capacities are integers or rationals, but the number of augmentations, and hence the running time, can depend badly on the specific path choices and on the capacity values, as the counterexample in this article illustrates. Edmonds–Karp is a specific implementation of Ford–Fulkerson that always chooses a shortest augmenting path (fewest edges), found via breadth-first search in the residual graph; this guarantees termination in O(VE)O(VE) augmentations regardless of capacity values, giving overall running time O(VE2)O(VE^2), and works even for irrational capacities.

Does the theorem extend to networks with multiple sources and sinks?

Yes, via a standard reduction. Introduce a super-source s∗s^* with an edge of infinite (or sufficiently large finite) capacity to each original source, and a super-sink t∗t^* with an edge of infinite capacity from each original sink. A maximum s∗s^*-t∗t^* flow in this augmented network corresponds exactly to a maximum total flow across all source-sink pairs in the original multi-terminal network, and the max-flow min-cut theorem applies directly to the augmented network, giving a min-cut characterization of the multi-source, multi-sink bottleneck as well.

Why is this theorem considered foundational rather than just a clever algorithmic trick?

Because it is a genuine combinatorial duality theorem: it asserts an exact equality between a maximization problem (largest flow) and a minimization problem (smallest cut) with no gap between them, a phenomenon called strong duality that is far from automatic in optimization (linear programming duality is the general machinery behind it, with max-flow min-cut as the integral special case). This duality pattern reappears throughout combinatorics — in Menger's theorem, König's theorem, Hall's theorem, and Dilworth's theorem — making max-flow min-cut a template for an entire family of "min-max" results, not merely an algorithm for pipeline scheduling.

Before this

Where this leads