Arrow assignments and their excess #
A directed network on a vertex type V is described by an explicit arrow family
Q : V → V → Type*, where Q v w is the type of arrows from v to w; parallel arrows,
antiparallel arrows and loops are all allowed. An arrow assignment with values in a type K
attaches a value of K to every arrow, with no sign or capacity constraint. Flows, pseudoflows,
bounded assignments and residual updates are all arrow assignments subject to further conditions,
and they share the additive calculus developed here. Arrow sums only need K to be an additive
commutative monoid, while excess needs an additive commutative group.
The excess of an assignment f at a vertex v is the total value on arrows entering v minus
the total value on arrows leaving v. With this sign convention a demand vertex has positive
excess and a supply vertex negative excess, and the value of an ordinary s–t flow is its excess
at the sink t. A loop at v enters and leaves v, so it contributes nothing to the excess.
Main definitions #
TauCeti.Assignment Q K: arrow assignments of the arrow familyQwith values inK.TauCeti.arrowSum Q f S T: the total value offon the arrows fromStoT.TauCeti.excessAt Q f v: the excess offatv.TauCeti.excessHom Q: excess as an additive homomorphismAssignment Q K →+ (V → K).TauCeti.Assignment.single e q: the assignment with valueqon the arroweand zero elsewhere.TauCeti.IsCirculation f:fhas zero excess at every vertex.
Main results #
TauCeti.sum_excessAt_eq_arrowSum_sub: the total excess on a vertex setSis the value enteringSminus the value leavingS.TauCeti.sum_excessAt: the total excess over all vertices vanishes.TauCeti.sum_excessAt_eq_zero_of_forall_mem_iff: the total excess vanishes on a vertex set that no arrow enters or leaves.TauCeti.excessAt_single: a single arrow fromxtoycarryingqhas excessqatyand-qatx.TauCeti.excessAt_source_eq_neg_sink: an assignment conserved away fromsandthas opposite excesses atsandt, andTauCeti.excessAt_sink_eq_arrowSum_subcomputes the excess attas the net value across any vertex set containingsbut nott.TauCeti.isCirculation_iff_mem_ker: circulations form the kernel ofexcessHom, andTauCeti.setOf_excessAt_eq_eq_vadd_keridentifies every nonempty prescribed-excess fibre with a translate of that kernel.TauCeti.map_excessAtandTauCeti.excessAt_comp_equiv: excess commutes with additive maps of coefficients and with transport along an identification of arrow families.TauCeti.IsCirculation.mapandTauCeti.Assignment.map_mem_Icc: additive changes of coefficients preserve circulations, and monotone ones preserve feasibility.
Implementation notes #
The arrow family is an explicit argument rather than a Quiver instance, so that several arrow
families can coexist on one vertex type, and so that instance search finds Fintype (Q v w)
directly. An assignment binds its endpoints strict-implicitly, as ∀ ⦃v w⦄, Q v w → K: it is
applied to an arrow as f e, while f on its own is not specialised to unknown endpoints.
Single-arrow assignments #
The assignment with value q on the arrow e and zero on every other arrow.
Instances For
The total value of the assignment f on the arrows from a vertex of S to a vertex of T.
Every arrow is counted once, so parallel arrows add; when S and T meet, loops at their common
vertices are counted.
Instances For
An arrow sum as a sum over every arrow, with an indicator for its endpoints belonging to the specified sets.
The arrow sums of an assignment with values in an additive submonoid lie in the submonoid.
If every arrow leaving S ends in S, then the arrow sum from S to its complement
vanishes.
Mapping the values of an assignment along an additive monoid homomorphism commutes with summing them over the arrows between two vertex sets.
Summing over the arrows between two vertex sets is monotone in the assignment.
A nonnegative assignment has zero total value on the arrows from S to T exactly when it
vanishes on each of these arrows.
A nonnegative assignment has nonnegative total value on the arrows from S to T.
For a nonnegative assignment, the arrow sum is monotone in the set of source vertices.
For a nonnegative assignment, the arrow sum is monotone in the set of target vertices.
For a nonnegative assignment, the arrow sum is subadditive in the set of source vertices.
For a nonnegative assignment, the arrow sum is subadditive in the set of target vertices.
Adding the vertices of X to a vertex set S increases the nonnegative value leaving it by
at most the total value leaving X.
Removing the vertices of Y from a vertex set S increases the nonnegative value leaving it
by at most the total value entering Y.
The value of a nonnegative assignment on a single arrow from S to T is at most its total
value on the arrows from S to T.
The total value entering v for a single arrow from x to y is q when v = y and
zero otherwise.
The total value leaving v for a single arrow from x to y is q when v = x and
zero otherwise.
The unit assignment counts arrows: its total value on the arrows from S to T is the
number of these arrows, with parallel arrows counted separately.
The excess of the assignment f at the vertex v: the total value on arrows entering v
minus the total value on arrows leaving v. Loops at v cancel.
Instances For
The excess of an assignment with values in an additive subgroup lies in the subgroup.
The excess at v is the value entering {v} minus the value leaving {v}.
Excess as an additive homomorphism from arrow assignments to vertex functions.
Instances For
A nonnegative assignment that vanishes on every arrow entering v has nonpositive excess at
v.
A nonnegative assignment that vanishes on every arrow leaving v has nonnegative excess at
v.
An assignment between zero and cap has excess at v at most the total capacity of the arrows
entering v.
An assignment between zero and cap has minus its excess at v at most the total capacity of
the arrows leaving v.
Excess on a vertex set. The total excess of f on S is the value on arrows entering S
from its complement minus the value on arrows leaving S for its complement; arrows with both ends
in S cancel.
The total excess of an assignment over all vertices is zero: every arrow enters exactly one vertex and leaves exactly one vertex.
A vertex set that no arrow enters or leaves, such as a union of weakly connected components, has total excess zero.
If an assignment is conserved at every vertex other than s and t, then its excesses at s
and t are opposite. In particular a flow loses at its source exactly what it delivers to its
sink.
Value across a cut. If an assignment is conserved at every vertex other than s and t,
then for every vertex set S containing s but not t, the excess at t is the value on arrows
leaving S minus the value on arrows entering S.
Mapping the values of an assignment along an additive group homomorphism commutes with taking excess.
Excess is invariant under transport along an identification σ of the vertices and
identifications τ of the corresponding arrow types: pulling an assignment back along τ and
taking excess at v agrees with taking excess at σ v.
Excess of a single arrow. The assignment with value q on an arrow from x to y and
zero elsewhere has excess q at y and -q at x; for a loop the two cancel.
Circulations and prescribed excess #
A (signed) circulation is an arrow assignment conserved at every vertex: its excess vanishes everywhere. No sign or capacity constraint is imposed.
Instances For
Circulations are exactly the kernel of the excess homomorphism.
A circulation carries the same total value into any vertex set S as out of it.
Given one assignment f₀ with excess b, an assignment has excess b exactly when it differs
from f₀ by a circulation.
Every nonempty prescribed-excess fibre is a translate of the circulations: if f₀ has excess
b, the assignments with excess b are exactly f₀ + c for c in the kernel of excessHom.
Change of coefficients #
Subtracting a subgroup-valued reference preserves membership on each arrow.
A circulation stays a circulation after an additive change of coefficients.
Excess of an assignment on a network's arrow family. The network's bounds play no role.
Instances For
The additive excess map on a network's arrow family.