AFTD Auto-Formalizing Theoretical Domains

Kruskal.SpansLike

defimported Lean

$\mathtt{SpansLike}\,F\,E$ holds when the edge list $F$ is at least as connected as $E$: for every pair of vertices $u, v$, if $u$ and $v$ are reachable in $E$ then they are also reachable in $F$.

Statement

set_option relaxedAutoImplicit false in
set_option autoImplicit false in
def Kruskal.SpansLike {n : ℕ} (F E : List (WEdge n)) : Prop
Defined in
TCSlib, `Kruskal.SpansLike`
Lean proof
By [Your Name], [Partner's Name (if applicable)], from github.com/Shilun-Allan-Li/tcslib at c8a02591b1e5 (Copyright (c) 2026 [Your Name] and [Partner's Name (if applicable)]. All rights reserved, Apache-2.0). Compiled here against leanprover/lean4:v4.33.1, Mathlib v4.33.1; written for leanprover/lean4:v4.25.0.
Verified
07 Oct 2026
Axioms
none listed
Built on 2
  • Kruskal.WEdgeA weighted edge over $n$ vertices is a structure with two endpoints $u, v : \mathrm{Fin}\,n$ and a natural-number weight…
  • Kruskal.Reach$\mathtt{Reach}\,\mathit{edges}$ is the reflexive--transitive closure of $\mathtt{SymAdj}\,\mathit{edges}$; that is,…
Used by 1
  • Kruskal.kruskal_optimalOptimality of Kruskal's algorithm. Let $E$ be a list of weighted edges on $n$ vertices, and let $S$ be another such list in which every…

Lean source view module on GitHub

set_option relaxedAutoImplicit false in
set_option autoImplicit false in
def Kruskal.SpansLike {n : ℕ} (F E : List (WEdge n)) : Prop :=
  ∀ u v : Fin n, Reach E u v → Reach F u v
See it in the graphDiscuss this resultChallenge it