File tree Expand file tree Collapse file tree
Mathlib/Combinatorics/SimpleGraph Expand file tree Collapse file tree Original file line number Diff line number Diff line change 88public import Mathlib.Combinatorics.SimpleGraph.Maps
99public import Mathlib.Data.Finset.Max
1010public import Mathlib.Data.Sym.Card
11+ public import Mathlib.Order.Interval.Finset.Defs
1112
1213/-!
1314# Definitions for finite and locally finite graphs
@@ -529,6 +530,25 @@ theorem card_commonNeighbors_top [DecidableEq V] {v w : V} (h : v ≠ w) :
529530
530531end Finite
531532
533+ section LocallyFiniteOrder
534+
535+ variable [Fintype V]
536+
537+ /-- `G ≤ H` is decidable when adjacency is decidable on both sides. -/
538+ instance decidableLE {G H : SimpleGraph V}
539+ [DecidableRel G.Adj] [DecidableRel H.Adj] : Decidable (G ≤ H) :=
540+ decidable_of_iff (∀ v w, G.Adj v w → H.Adj v w) Iff.rfl
541+
542+ /-- The lattice of simple graphs on a finite type is locally finite when the order is
543+ decidable. -/
544+ instance [DecidableEq V] [DecidableLE (SimpleGraph V)] :
545+ LocallyFiniteOrder (SimpleGraph V) :=
546+ LocallyFiniteOrder.ofIcc' (SimpleGraph V)
547+ (fun G₁ G₂ => {G | G₁ ≤ G ∧ G ≤ G₂})
548+ (fun _ _ _ => by simp)
549+
550+ end LocallyFiniteOrder
551+
532552namespace Iso
533553
534554variable {G} {W : Type *} {G' : SimpleGraph W}
You can’t perform that action at this time.
0 commit comments