Skip to main content

Module parametric_maxflow

Module parametric_maxflow 

Source
Expand description

Parametric maximum flow (Gallo-Grigoriadis-Tarjan 1989 / Hochbaum 2008).

Solves a family of s-t maximum-flow problems in which some arc capacities vary monotonically with a scalar parameter lambda. Each arc capacity is modelled as an affine function cap(lambda) = base + slope * lambda (clamped at 0). The Gallo-Grigoriadis-Tarjan (GGT) monotone structure is enforced:

  • arcs leaving the source (from == source) have non-decreasing capacity (slope >= 0),
  • arcs entering the sink (to == sink) have non-increasing capacity (slope <= 0),
  • every other arc has a constant capacity (slope == 0).

Under this structure the minimal source side S(lambda) of the minimum cut is a non-decreasing (nested) function of lambda: for l1 <= l2 we have S(l1) ⊆ S(l2). This module exposes

The per-lambda solves are exact single-parameter max-flows, so they agree with an independent solve at every lambda.

Structs§

ParametricArc
An arc whose capacity is affine in the parameter: cap(lambda) = base + slope * lambda.
ParametricBreakpoint
A lambda value at which the optimal minimal min-cut source side changes.
ParametricMaxFlow
A parametric s-t flow network with affine, GGT-monotone arc capacities.
ParametricSolution
Result of one single-lambda parametric solve.