maximum_matching_size_from_independence
A maximum matching inside S covers enough vertices that |S| is at most twice its edge count plus the independence bound.
Statement
theorem maximum_matching_size_from_independence {V : Type*} [Fintype V] [DecidableEq V] (G : SimpleGraph V) (S : Finset V) (M : G.Subgraph) (hM : M.IsMatching) (hMS : M.verts ⊆ (S : Set V)) (hmax : ∀ N : G.Subgraph, N.IsMatching → N.verts ⊆ (S : Set V) → N.edgeSet.ncard ≤ M.edgeSet.ncard) (a : ℕ) (hind : ∀ U : Finset V, (∀ u ∈ U, ∀ v ∈ U, u ≠ v → ¬ G.Adj u v) → U.card ≤ a) : S.card ≤ 2*M.edgeSet.ncard+a
- Source
- Balanced-cut matching symmetry for OP-1957; https://arxiv.org/abs/2611.22690.
- Verified
- 26 Nov 2026
- Axioms
Classical.choiceQuot.soundpropext- Built on 2
- maximum_matching_unmatched_independentThe vertices left uncovered by a maximum matching inside a vertex set form an independent set.
- extendible_matchable_two_k_vertices_complement_matchableIn a finite k-extendible graph, the complement of any matchable set of exactly 2k vertices is matchable.
- Used by 4
- k7_balanced_cut_bound_of_deficiency_barrierUnder the displayed extendibility, separator, degree and independence conditions, the matching-deficiency barrier hypothesis implies at…
- extendible_k7_balanced_cut_odd_component_boundIn the stated 28-vertex, 7-extendible, high-degree setting with the separator and independence assumptions, any balanced cut has at most…
- op1957_dense_balanced_half_conditions_do_not_force_separatorThere is a graph on 16 vertices of minimum degree at least 10 and independence number at most two, whose every induced subgraph has at…
- extendible_balanced_cut_matching_symmetry_of_independenceIn the stated order-4k extendible graph with independence number at most k, maximum matchings in the balanced halves have equal size.
The proof, explained
The proof partitions S into the vertices D covered by the matching M and the remaining unmatched vertices U = S \ D. Because M is a matching, the number of covered vertices |D| equals twice the number of edges in M. By the maximality of M inside S, no two vertices in U can be adjacent, so U is an independent set and has size at most a. Decomposing |S| into |D| + |U| then yields |S| ≤ 2 * |M.edgeSet| + a.
The vertex set S is partitioned into the set D of vertices matched by M and the set U = S \ D of unmatched vertices, with D ⊆ S.
Under classical logic, D is defined as the vertices of the subgraph M (as a Finset) and U as the complement S \ D. Since M has all its vertices in S (by hypothesis hMS), every vertex in D belongs to S, establishing D ⊆ S.
set_option maxHeartbeats 4000000 in classical let D : Finset V := M.verts.toFinset let U : Finset V := S \ D have hDS : D ⊆ S := by intro v hv; exact hMS (by simpa [D] using hv)
The number of matched vertices |D| is twice the number of edges in M.
The cardinality of D as a Finset is converted to the set cardinality of M.verts via Set.ncard_eq_toFinset_card'. Since M is a matching, in1076_matching_twice_card proves that the number of matched vertices is exactly twice the number of edges.
uses
Set.ncard_eq_toFinset_card',in1076_matching_twice_cardhave hDcard : D.card = 2*M.edgeSet.ncard := by dsimp [D] rw [← Set.ncard_eq_toFinset_card'] exact (in1076_matching_twice_card hM).symm
The set of unmatched vertices U is an independent set in G.
Given any two distinct vertices u, v ∈ U, unpacking the set difference with Finset.mem_sdiff.mp shows that both belong to S but neither belongs to D (i.e., neither is covered by M). Because M is a maximum matching inside S, maximum_matching_unmatched_independent implies that u and v cannot be adjacent, since otherwise adding the edge uv would yield a larger matching in S.
uses
Finset.mem_sdiff.mp,maximum_matching_unmatched_independenthave hUind : ∀ u ∈ U, ∀ v ∈ U, u ≠ v → ¬ G.Adj u v := by intro u hu v hv hne have hu' := Finset.mem_sdiff.mp hu have hv' := Finset.mem_sdiff.mp hv apply maximum_matching_unmatched_independent G S M hM hMS hmax u hu'.1 ?_ v hv'.1 ?_ · simpa [D] using hu'.2 · simpa [D] using hv'.2
|S| ≤ 2 * |M.edgeSet| + a. automation
Because U is an independent set, the hypothesis hind guarantees |U| ≤ a. Furthermore, because D ⊆ S, the set S decomposes into the disjoint union of S \ D and D, so |S \ D| + |D| = |S| by Finset.card_sdiff_add_card_eq_card. Combining this partition formula with |D| = 2 * |M.edgeSet| and |S \ D| ≤ a, the linear arithmetic tactic omega closes the inequality.
uses
Finset.card_sdiff_add_card_eq_cardhave hU := hind U hUind have hcount := Finset.card_sdiff_add_card_eq_card hDS dsimp [U] at hU omega
Set.ncard_eq_toFinset_card'- For any finite set, its set cardinality (ncard) equals the cardinality of its Finset representation.
in1076_matching_twice_card- The number of vertices in a matching is twice the number of edges.
Finset.mem_sdiff.mp- An element is in the set difference s \ t if and only if it is in s and not in t.
maximum_matching_unmatched_independent- In a maximum matching inside S, any two distinct vertices in S that are not covered by the matching are not adjacent.
Finset.card_sdiff_add_card_eq_card- If s ⊆ t, then |t \ s| + |s| = |t|.
- The final arithmetic inequality combining the set partition equation |S \ D| + |D| = |S|, the matching vertex count |D| = 2 * |M.edgeSet|, and the independence bound |S \ D| ≤ a is closed automatically by the `omega` decision procedure for linear integer arithmetic.
Written by a model (gemini-3.8-flash) from the Lean proof and the goal states Lean reported at each step. Lean verified the proof; this explanation is a reading aid and is not itself machine-checked.
Lean source view module on GitHub
Choose a tactic — a marked line — to see the goals Lean had before and after it, as in Lean’s infoview. Step with ← → or j k.
theorem maximum_matching_size_from_independence {V : Type*} [Fintype V] [DecidableEq V] (G : SimpleGraph V) (S : Finset V) (M : G.Subgraph) (hM : M.IsMatching) (hMS : M.verts ⊆ (S : Set V)) (hmax : ∀ N : G.Subgraph, N.IsMatching → N.verts ⊆ (S : Set V) → N.edgeSet.ncard ≤ M.edgeSet.ncard) (a : ℕ) (hind : ∀ U : Finset V, (∀ u ∈ U, ∀ v ∈ U, u ≠ v → ¬ G.Adj u v) → U.card ≤ a) : S.card ≤ 2*M.edgeSet.ncard+a := by set_option maxHeartbeats 4000000 in classical let D : Finset V := M.verts.toFinset let U : Finset V := S \ D have hDS : D ⊆ S := by intro v hv; exact hMS (by simpa [D] using hv) have hDcard : D.card = 2*M.edgeSet.ncard := by dsimp [D] rw [← Set.ncard_eq_toFinset_card'] exact (in1076_matching_twice_card hM).symm have hUind : ∀ u ∈ U, ∀ v ∈ U, u ≠ v → ¬ G.Adj u v := by intro u hu v hv hne have hu' := Finset.mem_sdiff.mp hu have hv' := Finset.mem_sdiff.mp hv apply maximum_matching_unmatched_independent G S M hM hMS hmax u hu'.1 ?_ v hv'.1 ?_ · simpa [D] using hu'.2 · simpa [D] using hv'.2 have hU := hind U hUind have hcount := Finset.card_sdiff_add_card_eq_card hDS dsimp [U] at hU omega