Definition 6.1 — Complete matching
DefinitionYogeshwaranDM_CompleteMatchingDefinition 6.1 — Complete matching. Let be a simple graph, a subgraph of , and . The subgraph is a complete matching on when every vertex of has exactly one neighbor in , and .
Formalization note. The matching condition is Mathlib's native ; a matching has no isolated vertices in its own vertex set. Isolated ambient vertices need not belong to . The definition does not assert that is nonempty. Perfect matching retains Mathlib's existing native meaning: a spanning matching.
import Mathlib.Combinatorics.SimpleGraph.Matching
set_option autoImplicit false
namespace YogeshwaranDM
def CompleteMatching {V : Type*} {G : SimpleGraph V}
(M : G.Subgraph) (S : Set V) : Prop :=
M.IsMatching ∧ S ⊆ M.verts
end YogeshwaranDM
Read-back
What the Lean code literally says, in plain math · Codex (exact model identifier unavailable in auditor runtime)
For every type , every simple undirected loopless graph on , every subgraph of , and every set , the proposition means precisely that every vertex belonging to the vertex set of has exactly one neighbor in , and that every element of belongs to the vertex set of . Here a subgraph consists of a chosen set of vertices together with a symmetric adjacency relation whose edges are edges of and whose endpoints belong to the chosen vertex set. Thus each vertex of has exactly one neighbor in , and every vertex of outside must also have exactly one neighbor in ; the definition does not require the vertex set of to equal , does not require every vertex of to belong to , and does not assert the existence or uniqueness of such a subgraph. There are no finiteness, nonemptiness, decidable-equality, or bipartiteness assumptions: , , and the vertex set of may be finite, infinite, or empty. If is empty, the definition still requires every vertex of to have exactly one neighbor in . If the vertex set of is empty, the definition holds exactly when is empty; in particular, it holds for the empty graph on an empty vertex type. No cardinality operation occurs in this definition.
Confirmed by the mission captain (proposal self-audit).