Lecture from: 08.05.2025 | Video: Homelab
Many problems in computer science, operations research, and logistics can be modeled as moving something through a network: data, water, goods, traffic, etc. A central question in such settings is:
What is the maximum amount of flow that can be pushed from a source node to a sink node, respecting the capacity constraints of the network?
This is the maximum flow problem, and today we study it rigorously.
Flow Networks
Let be a directed graph representing a network. A flow network has the following properties:
- Each edge has a capacity .
- There is a distinguished source vertex .
- There is a distinguished sink vertex , with .
Think of the network as a system of pipes. The source pumps fluid in, and the sink collects the outflow.
Definition and Constraints
A flow in the network is a function:
satisfying:
Capacity Constraint
Flow Conservation (except at source and sink):
Skew Symmetry (convenience condition):
This ensures that defining for existing edges is enough - the reverse flow is implicitly handled.
Value of a Flow
The value of a flow , denoted , is (given there is no inflow at the source) the total flow leaving the source:
By flow conservation, this is also equal to the flow entering the sink :
Cuts in Flow Networks
A cut in the network is a partition of the vertex set into two disjoint subsets and such that:
The capacity of a cut is the total capacity of all edges from to :
Example:
How Cuts Bound the Value of a Flow
Before proving the Max-Flow Min-Cut Theorem, it’s important to understand the role of cuts in bounding flows.
Observation
Any - cut in a flow network places an upper bound on the value of any feasible flow.
Let’s see why this is true.
Setup: Flow and Cut
Let be any valid flow in the network, and let be any cut with:
- ,
Define the net flow across the cut from to as:
That is, total flow out of minus flow into from .
Key Lemma
This may seem surprising at first, but it’s true for any - cut. Here’s the intuition:
The total flow leaving the source must eventually cross from to , because the sink lies beyond the cut. All flow must “escape” through the cut.
Let’s sketch a brief justification.
Sketch of Proof
-
By Flow Conservation: For every node , inflow equals outflow.
-
Sum net flow over all nodes in : This collapses (due to conservation) to:
-
Only the source can have net outflow , and everything else balances. So:
Bounding Flow with Cut Capacity
Now, since for all edges (capacity constraint), and for , we have:
Hence:
The Max-Flow Min-Cut Theorem
The Max-Flow Min-Cut Theorem is one of the most elegant results in combinatorial optimization. It connects the maximum amount of flow that can be pushed through a network with the minimum bottleneck that separates source from sink.
Intuition
Flow through a network is constrained not by the largest paths, but by the narrowest bottlenecks.
Imagine a system of pipes from a source to a sink. The maximum water flow isn’t determined by the biggest pipes-it’s limited by the thinnest one that separates the source from the rest. That’s exactly what the Min-Cut is.
Theorem (Max-Flow Min-Cut)
In any flow network, the maximum value of a flow equals the minimum capacity of an - cut.
Formally:
This holds for:
- integer capacities without anti-parallel edges (proved with Ford-Fulkerson)
- arbitrary real capacities (via more advanced arguments)
Proof (via Ford-Fulkerson Residual Network)
Assumption
We assume Ford-Fulkerson has been applied and terminated. That is, no more augmenting - paths exist in the residual graph .
Step 1: Build the Residual Graph
From flow , we define a residual network with residual capacities :
- Forward edge if , with
- Backward edge if , with
Step 2: Construct a Cut
Let:
This gives us an - cut . Importantly:
- (since in )
Step 3: Analyze the Flow Across the Cut
Every edge with , must be saturated:
(else would be in , and would be reachable, contradicting )
Every edge with , must be empty:
(otherwise a backward edge would exist in , making , a contradiction)
Step 4: Use the Value Identity
From the earlier lemma:
Given:
Hence:
This proves:
- is a max flow
- is a min cut
Summary
- Every flow is upper bounded by the capacity of any cut.
- When Ford-Fulkerson halts, the flow equals the capacity of some cut.
- Therefore, the max flow equals the min cut.
Fold-Fulkerson Algorithm
Continue here: 22 Ford-Fulkerson with Integer Capacities, Applications of Max Flow (Max Bipartite Matching, Edge-Disjoint Paths, Image Segmentation)