Skip to content

Commit a7c79b4

Browse files
committed
feat: Add finite iff bounded lemmas (#5567)
This PR adds a lemma stating that finiteness is equivalent to boundedness above and below in a locally finite lattice, as well as one-way versions for both types of semilattice.
1 parent 2fd9a72 commit a7c79b4

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

Mathlib/Order/LocallyFinite.lean

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1364,4 +1364,27 @@ theorem map_subtype_embedding_Iio : (Iio a).map (Embedding.subtype p) = (Iio a :
13641364

13651365
end LocallyFiniteOrderBot
13661366

1367+
section Finite
1368+
1369+
variable {α : Type _} {s : Set α}
1370+
1371+
theorem finite_iff_bddAbove [SemilatticeSup α] [LocallyFiniteOrder α] [OrderBot α]:
1372+
s.Finite ↔ BddAbove s :=
1373+
fun h ↦ ⟨h.toFinset.sup id, fun x hx ↦ Finset.le_sup (f := id) (by simpa)⟩,
1374+
fun ⟨m, hm⟩ ↦ (Set.finite_Icc ⊥ m).subset (fun x hx ↦ ⟨bot_le, hm hx⟩)⟩
1375+
1376+
theorem finite_iff_bddBelow [SemilatticeInf α] [LocallyFiniteOrder α] [OrderTop α] :
1377+
s.Finite ↔ BddBelow s :=
1378+
finite_iff_bddAbove (α := αᵒᵈ)
1379+
1380+
theorem finite_iff_bddBelow_bddAbove [Nonempty α] [Lattice α] [LocallyFiniteOrder α] :
1381+
s.Finite ↔ BddBelow s ∧ BddAbove s := by
1382+
obtain (rfl | hs) := s.eq_empty_or_nonempty
1383+
· simp only [Set.finite_empty, bddBelow_empty, bddAbove_empty, and_self]
1384+
exact ⟨fun h ↦ ⟨⟨h.toFinset.inf' (by simpa) id, fun x hx ↦ Finset.inf'_le id (by simpa)⟩,
1385+
⟨h.toFinset.sup' (by simpa) id, fun x hx ↦ Finset.le_sup' id (by simpa)⟩⟩,
1386+
fun ⟨⟨a,ha⟩,⟨b,hb⟩⟩ ↦ (Set.finite_Icc a b).subset (fun x hx ↦ ⟨ha hx,hb hx⟩ )⟩
1387+
1388+
end Finite
1389+
13671390
end Finset

0 commit comments

Comments
 (0)