Part A: one unit at a time
The maximum flow is 2000: 1000 along and 1000 along . Every
augmentation pushes at least 1 unit, so no run takes more than 2000. The worst run takes
exactly that many. It pushes 1 along , then 1 along
using the arc that sends the middle pipe's flow back, and repeats. Each path's tightest pipe is
the middle one, with capacity 1. A good choice finishes in 2 augmentations.
Part B: the cautious rule walks straight into it
On part A's network with capacities 100, the smallest-bottleneck rule picks the middle path every
time, since its bottleneck is 1. It alternates exactly as above: 200 augmentations for a flow
of 200. Shortest augmenting paths (Edmonds–Karp) finish the same network in 2. The number of
augmentations of plain Ford–Fulkerson depends on the capacities, not just on the size of the
network.
Part C: augment along shortest paths, and read the cut off the end
Edmonds–Karp finds each augmenting path by breadth-first search in the residual network,
including the arcs that send flow back. The distance from to every junction never decreases,
and each pipe can be the bottleneck only times. So there are at most augmentations
whatever the capacities, even .
When no augmenting path is left, let be the junctions reachable from in the residual
network. Every pipe leaving is full, and every pipe entering carries nothing, otherwise
something more would be reachable. So the flow's value equals the capacity of the cut . That is
the max-flow min-cut theorem, and it is also the certificate the grader checks. The grader
never computes a maximum flow itself. It checks that your flow is feasible and that your cut's
capacity equals its value.
The reverse arcs are essential. On the grader's network "a route that blocks two others",
augmenting without them takes first and is stuck at 1. The maximum is 2:
send 's unit on to instead, and route 's through .
Going further
- Ford–Fulkerson need not stop when capacities are irrational. Zwick found the smallest
networks on which it runs forever, and its flow can even converge to the wrong value.
- Faster algorithms. Dinic's blocking flows take . Orlin gave an algorithm.
In 2022 Chen, Kyng, Liu, Peng, Probst Gutenberg and Sachdeva computed maximum flow in
almost-linear time, .
- The cut as a dual. The max-flow min-cut theorem is LP duality in disguise
(LP Duality): the cut is the dual solution that certifies the flow.
References
- L. R. Ford, D. R. Fulkerson. Maximal flow through a network. Canadian Journal of
Mathematics 8, 1956.
- J. Edmonds, R. M. Karp. Theoretical improvements in algorithmic efficiency for network flow
problems. Journal of the ACM 19(2), 1972.
- U. Zwick. The smallest networks on which the Ford–Fulkerson maximum flow procedure may fail to
terminate. Theoretical Computer Science 148(1), 1995.
- J. B. Orlin. Max flows in O(nm) time, or better. Proceedings of STOC, 2013.
- L. Chen, R. Kyng, Y. P. Liu, R. Peng, M. Probst Gutenberg, S. Sachdeva. Maximum flow and
minimum-cost flow in almost-linear time. Proceedings of FOCS, 2022.