Documentation

CslibFrontier.Foundations.Combinatorics.SimpleGraph.Separator

Separating vertex sets #

A set Y of vertices separates A from B in a simple graph G (SimpleGraph.IsSeparator) when every walk from a vertex of A to a vertex of B visits a vertex of Y. This is the A–B separator of graph theory; Y may meet A and B, and a vertex of A ∩ B must lie in Y (the trivial walk). A walk avoiding Y contains a path avoiding Y with the same endpoints, so quantifying over walks or over paths gives the same notion (SimpleGraph.isSeparator_iff_forall_isPath). For single terminals A = {u}, B = {v} with u, v ∉ Y, this is the u–v vertex separator SimpleGraph.IsVertexSeparator of Menger's theorem ([Die25], §1.4; related by SimpleGraph.isVertexSeparator_iff_isSeparator).

SimpleGraph.reachAvoiding G A Y is the set of vertices reached from A by walks avoiding Y. Y separates A from B exactly when no vertex of B is reached (SimpleGraph.isSeparator_iff_forall_notMem_reachAvoiding). A Boolean labelling that is constant along edges outside Y, true on A \ Y and false on B \ Y, certifies that Y separates A from B (SimpleGraph.isSeparator_of_forall_adj). This is the form in which a minimum cut of a flow network certifies a vertex separator.

Main definitions #

Main results #

def SimpleGraph.IsSeparator {V : Type u_1} (G : SimpleGraph V) (A B Y : Set V) :

Y separates A from B in G: every walk from a vertex of A to a vertex of B visits a vertex of Y. A vertex of A ∩ B must lie in Y, because of its trivial walk.

def SimpleGraph.reachAvoiding {V : Type u_1} (G : SimpleGraph V) (A Y : Set V) :
Set V

The vertices reached from A by walks of G that avoid Y.

theorem SimpleGraph.IsSeparator.exists_mem_support {V : Type u_1} {G : SimpleGraph V} {A B Y : Set V} (h : G.IsSeparator A B Y) {a b : V} (ha : a ∈ A) (hb : b ∈ B) (p : G.Walk a b) :
∃ x ∈ p.support, x ∈ Y
theorem SimpleGraph.IsSeparator.mono {V : Type u_1} {G : SimpleGraph V} {A B Y Y' : Set V} (h : G.IsSeparator A B Y) (hY : Y ⊆ Y') :
G.IsSeparator A B Y'
theorem SimpleGraph.isSeparator_of_subset_left {V : Type u_1} {G : SimpleGraph V} {A B Y : Set V} (h : A ⊆ Y) :
G.IsSeparator A B Y

A set containing A separates A from any B: every walk starts in A.

theorem SimpleGraph.mem_reachAvoiding_of_mem {V : Type u_1} {G : SimpleGraph V} {A Y : Set V} {v : V} (hA : v ∈ A) (hY : v ∉ Y) :
theorem SimpleGraph.notMem_of_mem_reachAvoiding {V : Type u_1} {G : SimpleGraph V} {A Y : Set V} {v : V} (h : v ∈ G.reachAvoiding A Y) :
v ∉ Y
theorem SimpleGraph.mem_reachAvoiding_of_adj {V : Type u_1} {G : SimpleGraph V} {A Y : Set V} {u v : V} (hu : u ∈ G.reachAvoiding A Y) (huv : G.Adj u v) (hv : v ∉ Y) :

reachAvoiding is closed under edges to vertices outside Y.

theorem SimpleGraph.isSeparator_iff_forall_isPath {V : Type u_1} {G : SimpleGraph V} {A B Y : Set V} :
G.IsSeparator A B Y ↔ ∀ ⦃a : V⦄, a ∈ A → ∀ ⦃b : V⦄, b ∈ B → ∀ (p : G.Walk a b), p.IsPath → ∃ x ∈ p.support, x ∈ Y

It suffices to check paths: a walk avoiding Y contains a path (Walk.bypass) with the same endpoints and fewer vertices.

theorem SimpleGraph.isSeparator_iff_forall_notMem_reachAvoiding {V : Type u_1} {G : SimpleGraph V} {A B Y : Set V} :
G.IsSeparator A B Y ↔ ∀ b ∈ B, b ∉ G.reachAvoiding A Y

Y separates A from B exactly when no vertex of B is reached from A avoiding Y.

theorem SimpleGraph.isSeparator_of_forall_adj {V : Type u_1} {G : SimpleGraph V} {A B Y : Set V} (f : V → Bool) (hf : ∀ ⦃u v : V⦄, G.Adj u v → u ∉ Y → v ∉ Y → f u = f v) (hA : ∀ a ∈ A, a ∉ Y → f a = true) (hB : ∀ b ∈ B, b ∉ Y → f b = false) :
G.IsSeparator A B Y

Labelling certificate. If f is constant along edges outside Y, true on A \ Y and false on B \ Y, then Y separates A from B.

def SimpleGraph.IsVertexSeparator {V : Type u_1} (G : SimpleGraph V) (u v : V) (T : Finset V) :

T separates u from v in G ([Die25], §1.4): u, v ∉ T and every u–v path of G visits a vertex of T.

theorem SimpleGraph.isVertexSeparator_iff_isSeparator {V : Type u_1} {G : SimpleGraph V} {u v : V} {T : Finset V} :
G.IsVertexSeparator u v T ↔ u ∉ T ∧ v ∉ T ∧ G.IsSeparator {u} {v} ↑T

T is a u–v vertex separator iff u, v ∉ T and T separates {u} from {v} in the SimpleGraph.IsSeparator sense.

theorem SimpleGraph.isVertexSeparator_iff_forall_walk {V : Type u_1} {G : SimpleGraph V} {u v : V} {T : Finset V} :
G.IsVertexSeparator u v T ↔ u ∉ T ∧ v ∉ T ∧ ∀ (w : G.Walk u v), ∃ x ∈ w.support, x ∈ T

A finite u–v separator avoids u and v and meets every u–v walk.

theorem SimpleGraph.isVertexSeparator_iff_not_reachable_induce {V : Type u_1} {G : SimpleGraph V} {u v : V} {T : Finset V} :
G.IsVertexSeparator u v T ↔ ∃ (hu : u ∉ T) (hv : v ∉ T), ¬(induce (↑T)ᶜ G).Reachable ⟨u, hu⟩ ⟨v, hv⟩

T is a u–v vertex separator iff u, v ∉ T and u, v are unreachable in G - T.

theorem SimpleGraph.isVertexSeparator_of_forall_adj {V : Type u_1} {G : SimpleGraph V} {u v : V} {S T : Finset V} (hu : u ∈ S) (hv : v ∉ S) (huT : u ∉ T) (hvT : v ∉ T) (hST : ∀ x ∈ S, ∀ (y : V), G.Adj x y → y ∉ S → y ∈ T) :

Closed-set certificate for a vertex separator: if u ∈ S, v ∉ S, T avoids u and v, and every edge leaving S ends in T, then T separates u from v.