Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Theorem 2.1 — FOREST partitions E into E_1, …, E_|E| satisfying (2.1), with |E_i| ≤ |V| − 1, and |E_i| ≤ |V| − i, E_i = ∅ (i ≥ |V|) if G is simple

Proved
NagamochiIbaraki.EdgeConn.forest_partition_theorem_2_1

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

edge-connectivitygraph-algorithmsgraph-connectivityp2o-batch-p100bp2o-gran-per-chapterp2o-plan-paperp2o-v1sparse-certificate

Let G=(V,E)G = (V, E)G=(V,E) be a finite undirected graph with ∣V∣≥2|V| \ge 2∣V∣≥2 nodes and no self-loop, possibly with multiple edges. Run Procedure FOREST on GGG to completion, with any choices of ties at line 5 and of edge order at line 6, and let E1,E2,…,E∣E∣E_1, E_2, \dots, E_{|E|}E1​,E2​,…,E∣E∣​ be the classes it outputs; write Gi=(V,E1∪⋯∪Ei)G_i = (V, E_1 \cup \cdots \cup E_i)Gi​=(V,E1​∪⋯∪Ei​) and let λ(x,y;H)\lambda(x, y; H)λ(x,y;H) denote local edge-connectivity. Then:

  1. Partition. Every edge of GGG lies in exactly one class EiE_iEi​ with 1≤i≤∣E∣1 \le i \le |E|1≤i≤∣E∣.
  2. Connectivity (2.1). For every i=1,2,…,∣E∣i = 1, 2, \dots, |E|i=1,2,…,∣E∣,
λ(x,y;Gi)  ≥  min⁡{λ(x,y;G), i}for all x,y∈V.\lambda(x, y; G_i) \;\ge\; \min\{\lambda(x, y; G),\ i\} \qquad \text{for all } x, y \in V .λ(x,y;Gi​)≥min{λ(x,y;G), i}for all x,y∈V.
  1. Size, multiple graphs. ∣Ei∣≤∣V∣−1|E_i| \le |V| - 1∣Ei​∣≤∣V∣−1 for i=1,2,…,∣E∣i = 1, 2, \dots, |E|i=1,2,…,∣E∣.
  2. Size, simple graphs. If GGG is simple, then ∣Ei∣≤∣V∣−i|E_i| \le |V| - i∣Ei​∣≤∣V∣−i for i=1,2,…,∣V∣−1i = 1, 2, \dots, |V| - 1i=1,2,…,∣V∣−1, and ∣Ei∣=0|E_i| = 0∣Ei​∣=0 for i=∣V∣,…,∣E∣i = |V|, \dots, |E|i=∣V∣,…,∣E∣.

Consequently, for every kkk, the subgraph GkG_kGk​ preserves all local edge-connectivities up to kkk while having at most k(∣V∣−1)k(|V|-1)k(∣V∣−1) edges, and at most k∣V∣−k(k+1)/2k|V| - k(k+1)/2k∣V∣−k(k+1)/2 edges when GGG is simple: a sparse certificate of kkk-edge-connectivity computed by one graph search.

Formalization Note The paper's Theorem 2.1 also asserts that the partition "is found in O(|V| + |E|) time"; the running time is not formalized (there is no machine model), and only the structural conclusions are stated. The execution is a completed run σ0,…,σK\sigma_0, \dots, \sigma_Kσ0​,…,σK​ of the nondeterministic step relation encoding FOREST, and the classes are read off its final state; the theorem holds for every such run. The paper's "if GGG is multiple" bound ∣Ei∣≤∣V∣−1|E_i| \le |V| - 1∣Ei​∣≤∣V∣−1 is stated for every loopless graph, simple or not. Simplicity is injectivity of the end-node map. Local edge-connectivity takes values in ℕ∞ and is ∞\infty∞ at x=yx = yx=y.

Preamble
import Mathlib
import Definitions.Def_NagamochiIbaraki_EdgeConn_Multigraph
import Definitions.Def_NagamochiIbaraki_EdgeConn_localEdgeConn
import Definitions.Def_NagamochiIbaraki_EdgeConn_Forest
Formal statement
namespace NagamochiIbaraki.EdgeConn

theorem forest_partition_theorem_2_1
    {V E : Type*} [Fintype V] [DecidableEq V] [Fintype E] [DecidableEq E]
    (hV : 2 ≤ Fintype.card V)
    (ends : E → Sym2 V) (hloop : ∀ e, ¬ (ends e).IsDiag)
    (σ : ℕ → State V E) (K : ℕ) (hrun : IsCompletedRun ends σ K) :
    (∀ e : E, 1 ≤ (σ K).idx e ∧ (σ K).idx e ≤ Fintype.card E) ∧
    (∀ i : ℕ, 1 ≤ i → i ≤ Fintype.card E → ∀ x y : V,
      min (localEdgeConn ends Finset.univ x y) (i : ℕ∞) ≤
        localEdgeConn ends (upto (σ K) i) x y) ∧
    (∀ i : ℕ, 1 ≤ i → i ≤ Fintype.card E →
      (cls (σ K) i).card ≤ Fintype.card V - 1) ∧
    (Function.Injective ends →
      (∀ i : ℕ, 1 ≤ i → i ≤ Fintype.card V - 1 →
        (cls (σ K) i).card ≤ Fintype.card V - i) ∧
      (∀ i : ℕ, Fintype.card V ≤ i → i ≤ Fintype.card E → cls (σ K) i = ∅)) := by sorry

end NagamochiIbaraki.EdgeConn
Source
Nagamochi, Ibaraki, A Linear-Time Algorithm for Finding a Sparse k-Connected Spanning Subgraph of a k-Connected Graph, Algorithmica 7 (1992), pp. 588–589, Theorem 2.1 (running time excluded)
Read-back

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

Throughout, VVV and EEE are arbitrary finite types (vertices and edges) with decidable equality. The statement also uses the following objects, which come from imported files whose definitions are not shown: State, IsCompletedRun, localEdgeConn, upto, cls, and the field idx of a state. This read-back describes them only by the types and roles visible in the statement. It does not unfold them.

Hypotheses. The theorem takes the following data and assumptions:

  • At least two vertices: ∣V∣≥2|V| \ge 2∣V∣≥2.
  • Edge endpoints: a map ends:E→Sym2(V)\mathrm{ends} : E \to \mathrm{Sym}^2(V)ends:E→Sym2(V). It gives each edge eee an unordered pair of vertices ends(e)={u,v}\mathrm{ends}(e) = \{u, v\}ends(e)={u,v}. Two different edges may have the same pair of endpoints, so parallel edges are allowed.
  • No loops: for every edge eee, the pair ends(e)\mathrm{ends}(e)ends(e) is not of the form {v,v}\{v, v\}{v,v}. So every edge has two distinct endpoints.
  • The run: a sequence of states σ0,σ1,σ2,…\sigma_0, \sigma_1, \sigma_2, \dotsσ0​,σ1​,σ2​,… (one for each n∈Nn \in \mathbb{N}n∈N, each of type State V E) and a natural number KKK. Together they satisfy the imported predicate IsCompletedRun for ends\mathrm{ends}ends, σ\sigmaσ and KKK.

Write S=σKS = \sigma_KS=σK​ for the state at step KKK. Also write:

  • idxS(e)\mathrm{idx}_S(e)idxS​(e) for the natural-number label the state SSS gives edge eee;
  • upto(S,i)\mathrm{upto}(S, i)upto(S,i) for the edge set the state determines for the number iii;
  • cls(S,i)\mathrm{cls}(S, i)cls(S,i) for the finite set the state determines for the number iii. The statement takes its cardinality and compares it with ∅\emptyset∅.

For a finite edge set FFF and vertices x,yx, yx,y, write λF(x,y)\lambda_F(x,y)λF​(x,y) for localEdgeConn ends F x y. This is a value in N∪{∞}\mathbb{N} \cup \{\infty\}N∪{∞}, defined in an imported file. λE(x,y)\lambda_E(x,y)λE​(x,y) is this value for the full edge set.

Conclusions. The theorem asserts all four of the following.

  1. Labels are in range. For every edge eee:
1≤idxS(e)≤∣E∣.1 \le \mathrm{idx}_S(e) \le |E|.1≤idxS​(e)≤∣E∣.
  1. Connectivity is preserved up to iii. For every integer iii with 1≤i≤∣E∣1 \le i \le |E|1≤i≤∣E∣ and all vertices x,yx, yx,y (including x=yx = yx=y):
min⁡(λE(x,y), i)  ≤  λupto(S,i)(x,y),\min\bigl(\lambda_E(x,y),\ i\bigr) \;\le\; \lambda_{\mathrm{upto}(S,i)}(x,y),min(λE​(x,y), i)≤λupto(S,i)​(x,y),

where iii is treated as an element of N∪{∞}\mathbb{N} \cup \{\infty\}N∪{∞}.

  1. Size bound for every iii. For every iii with 1≤i≤∣E∣1 \le i \le |E|1≤i≤∣E∣:
∣cls(S,i)∣≤∣V∣−1.|\mathrm{cls}(S,i)| \le |V| - 1.∣cls(S,i)∣≤∣V∣−1.
  1. Extra claims when there are no parallel edges. If ends\mathrm{ends}ends is injective (no two distinct edges have the same pair of endpoints), then both of these hold:
    • (a) for every iii with 1≤i≤∣V∣−11 \le i \le |V| - 11≤i≤∣V∣−1:
∣cls(S,i)∣≤∣V∣−i;|\mathrm{cls}(S,i)| \le |V| - i;∣cls(S,i)∣≤∣V∣−i;
  • (b) for every iii with ∣V∣≤i≤∣E∣|V| \le i \le |E|∣V∣≤i≤∣E∣:
cls(S,i)=∅.\mathrm{cls}(S,i) = \emptyset.cls(S,i)=∅.

Injectivity is required only for part 4. Parts 1–3 hold without it.

Degenerate cases. The theorem says nothing about i=0i = 0i=0 or about i>∣E∣i > |E|i>∣E∣.

  • Subtraction: Because ∣V∣≥2|V| \ge 2∣V∣≥2, both ∣V∣−1|V| - 1∣V∣−1 and ∣V∣−i|V| - i∣V∣−i (for i≤∣V∣−1i \le |V| - 1i≤∣V∣−1) are ordinary positive natural numbers. No truncated subtraction to 000 ever happens.
  • No edges (E=∅E = \emptysetE=∅):
    • Part 1 is vacuous.
    • Parts 2, 3 and 4(b) are vacuous, because no iii satisfies 1≤i≤01 \le i \le 01≤i≤0.
    • Injectivity holds trivially, so part 4(a) still applies. It asserts ∣cls(S,i)∣≤∣V∣−i|\mathrm{cls}(S,i)| \le |V| - i∣cls(S,i)∣≤∣V∣−i for 1≤i≤∣V∣−11 \le i \le |V| - 11≤i≤∣V∣−1.
  • Fewer edges than vertices (∣E∣<∣V∣|E| < |V|∣E∣<∣V∣): the range in 4(b) is empty, so 4(b) says nothing.
  • Exactly two vertices (∣V∣=2|V| = 2∣V∣=2): part 4(a) covers only i=1i = 1i=1 and bounds ∣cls(S,1)∣|\mathrm{cls}(S,1)|∣cls(S,1)∣ by 111.
  • The case x=yx = yx=y is included in part 2. What it asserts there depends on the hidden value of λF(x,x)\lambda_F(x,x)λF​(x,x), which could be ∞\infty∞ or 000.
  • Satisfiability: the hypotheses on ∣V∣|V|∣V∣ and on loops can clearly be met. Whether some σ\sigmaσ and KKK satisfy IsCompletedRun cannot be decided from this code. If no such run exists for a given graph, the theorem is vacuously true for that graph.
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 paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me