Gomory–Hu trees of weighted undirected graphs #
For a weighted multigraph W : V → V → ℕ (Cslib.WeightedCut.IsMultigraph: symmetric weights,
zero diagonal), the cut function X ↦ cutWeight W X is symmetric and submodular, so it has a
Gomory–Hu tree (Cslib.Algorithms.Lean.GomoryHu.exists_isGomoryHuTree). This module specializes
the abstract theory to graphs ([GH61]; [Sch03], Section 15.4):
- the Gomory–Hu tree is cut-equivalent: for each tree edge
uv, the side ofT - uvcontaininguis a minimumu–vcut of the graph; - it is flow-equivalent: weighting each tree edge
uvbyλ(u, v), the minimums–tcut weightλ(s, t)(Cslib.WeightedCut.minCutBetween) is the least weight of an edge on thes–tpath of the tree; - consequently, the values
λ(s, t)over all pairss ≠ ttake at most|V| - 1distinct values.
By max-flow min-cut (Cslib.Algorithms.Lean.MaxFlow.Network.exists_maxFlow_eq_minCut), λ(s, t)
is the value of a maximum s–t flow in the network with capacities W
(Cslib.Algorithms.Lean.MaxFlow.Network.Flow.IsMaxFlow.value_eq_minCutBetween), so the Gomory–Hu
tree also encodes all pairwise maximum flow values.
The results are existence statements for natural-number weights. Gusfield's construction of the
tree with |V| - 1 maximum flow computations, without the contractions of Gomory and Hu
([Gus90]), is in CslibFrontier.Algorithms.Lean.GomoryHu.Gusfield (abstract cut oracle) and
CslibFrontier.Algorithms.Lean.GomoryHu.Construction (Edmonds–Karp, with running time).
Main results #
Cslib.WeightedCut.isSubmodular_cutWeight: the cut function is submodular.Cslib.WeightedCut.isMinCutBetween_cutWeight_iff: minimums–tcuts of the cut function are the sets containings, missingt, of weightλ(s, t).Cslib.Algorithms.Lean.GomoryHu.exists_isGomoryHuTree_cutWeight: the Gomory–Hu theorem: every weighted multigraph on a nonempty finite vertex set has a cut-equivalent tree.Cslib.Algorithms.Lean.GomoryHu.IsGomoryHuTree.isLeast_minCutBetween: flow-equivalence of a Gomory–Hu tree.Cslib.Algorithms.Lean.GomoryHu.card_image_minCutBetween_le: at most|V| - 1distinct minimum cut values.Cslib.Algorithms.Lean.MaxFlow.Network.Flow.IsMaxFlow.value_eq_minCutBetween: a maximums–tflow has valueλ(s, t).
References #
The cut function of a non-negative weight matrix over an ordered additive monoid is submodular.
The cut function of a weight matrix is submodular.
The minimum s–t cuts of the cut function are the sets containing s and missing t
whose weight is λ(s, t).
Gomory–Hu theorem ([GH61]; [Sch03], Section 15.4): every weighted
multigraph W on a nonempty finite vertex set has a cut-equivalent tree, a spanning tree T on
the vertices in which for every edge uv, the side of T - uv containing u is a minimum u–v
cut of W. The edges of T need not be edges of W.
Flow-equivalence of a Gomory–Hu tree ([GH61]): with each tree edge uv weighted
by λ(u, v), the minimum s–t cut weight λ(s, t) is the least weight of an edge on the
s–t path of the tree.
An undirected weighted graph on n vertices has at most n - 1 distinct minimum cut values
λ(s, t) over pairs of distinct vertices ([GH61]).
A minimum cut of the network with capacities W, source s and sink t is a minimum s–t
cut of the cut function of W.
Max-flow min-cut for λ. In the network with capacities W, source s and sink t ≠ s,
a maximum flow has value λ(s, t), the minimum s–t cut weight of W.