Prove2Me
Navigate
DiscoverFormalpediaBlogsUsersMomentumMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

Lemma 3.5 — from a vertex with positive excess the source is reachable in the residual graph

Proved
GoldbergTarjan.Generic.positive_excess_reaches_source

by mikedeng1 · Sep 27, 2026 · Mathlib 0df444a (Lean v4.33.1)

network-flowsp2o-batch-p100bp2o-gran-per-chapterp2o-plan-paperp2o-v1preflow

Let NNN be a flow network with source sss, let fff be a preflow and let vvv be a vertex with positive excess, e(v)=∑uf(u,v)>0e(v) = \sum_{u} f(u,v) > 0e(v)=∑u​f(u,v)>0. Then

s is reachable from v in the residual graph Gf.s \text{ is reachable from } v \text{ in the residual graph } G_f.s is reachable from v in the residual graph Gf​.

Lemma 3.5 is the structural fact behind the label bound of Lemma 3.7: excess can always be returned to the source.

Preamble
import Mathlib
import Definitions.Def_GoldbergTarjan_Generic_Preflow
Formal statement
namespace GoldbergTarjan.Generic

/-- Lemma 3.5 (Goldberg–Tarjan 1988, p. 926). If `f` is a preflow and `v` is a vertex with
positive excess, then the source `s` is reachable from `v` in the residual graph `G_f`. -/
theorem positive_excess_reaches_source {V : Type} [Fintype V]
    (N : Network V) (f : V → V → ℝ) (v : V)
    (hf : IsPreflow N f) (hv : 0 < excess f v) :
    ResidualReachable N f v N.s := by sorry

end GoldbergTarjan.Generic
Source
Goldberg, Tarjan, A New Approach to the Maximum-Flow Problem, J. ACM 35(4), 1988, p. 926, Lemma 3.5
Read-back

What the Lean code literally says, in plain math · claude-opus-5-5

The statement concerns an arbitrary finite type VVV, a network NNN with capacities ccc, source sss and sink ttt, a real function fff on V×VV \times VV×V, and a vertex vvv. Two hypotheses are assumed.

  1. fff is a preflow:
    • f(x,y)≤c(x,y)f(x,y) \le c(x,y)f(x,y)≤c(x,y);
    • f(x,y)=−f(y,x)f(x,y) = -f(y,x)f(x,y)=−f(y,x);
    • ∑uf(u,x)≥0\sum_u f(u,x) \ge 0∑u​f(u,x)≥0 for every x≠sx \ne sx=s.
  2. vvv has positive excess:
∑u∈Vf(u,v)>0.\sum_{u \in V} f(u,v) > 0.u∈V∑​f(u,v)>0.

Conclusion. sss is reachable from vvv in the residual graph. That is, there is a finite sequence v=x0,…,xk=sv = x_0, \dots, x_k = sv=x0​,…,xk​=s with k≥0k \ge 0k≥0 and c(xi,xi+1)−f(xi,xi+1)>0c(x_i, x_{i+1}) - f(x_i, x_{i+1}) > 0c(xi​,xi+1​)−f(xi​,xi+1​)>0 for every iii.

Degenerate cases. The vertex vvv is not restricted: it may be ttt, and it may be sss. If v=sv = sv=s, the conclusion holds trivially through the empty path. No labeling is involved.

Human review
  • Endorsed by Shuze Chen · Sep 27, 2026

    Confirmed by the moderator at approval.

  • Endorsed by mikedeng1 · Sep 27, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paper
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me