Documentation

CslibFrontier.Foundations.Combinatorics.SimpleGraph.EvenEdges

Graphs with an even number of edges #

SimpleGraph.EvenEdges G says that a finite graph G has an even number of edges, counted with Set.ncard. Toggling one potential edge, that is, taking the symmetric difference with SimpleGraph.edge u v for distinct u and v, flips this parity.

Main definitions #

Main results #

def SimpleGraph.EvenEdges {V : Type u_1} [Finite V] (G : SimpleGraph V) :

A graph on finitely many vertices has an even number of edges. The finite vertex type ensures that Set.ncard counts the edges rather than returning 0 on an infinite edge set.

theorem SimpleGraph.evenEdges_symmDiff_edge_iff {V : Type u_1} [Finite V] {u v : V} (huv : u ≠ v) (G : SimpleGraph V) :

Toggling one potential edge uv of a graph on finitely many vertices changes the parity of its number of edges.