@@ -703,6 +703,44 @@ instance {α} [CompleteAtomicBooleanAlgebra α] : IsAtomistic α :=
703703instance {α} [CompleteAtomicBooleanAlgebra α] : IsCoatomistic α :=
704704 isAtomistic_dual_iff_isCoatomistic.1 inferInstance
705705
706+ theorem exists_mem_le_of_le_sSup_of_isAtom {α} [CompleteAtomicBooleanAlgebra α] {a}
707+ (ha : IsAtom a) {s : Set α} (hs : a ≤ sSup s) : ∃ b ∈ s, a ≤ b := by
708+ by_contra! hnle
709+ have : ⨆ s₀ ∈ s, a ⊓ s₀ = ⊥ := by
710+ simp only [iSup_eq_bot]
711+ intro s₀ hs₀
712+ simpa [hnle s₀ hs₀] using ha.le_iff.mp (inf_le_left (b := s₀))
713+ obtain rfl := (inf_eq_left.mpr hs).symm.trans <| inf_sSup_eq.trans this
714+ exact ha.1 rfl
715+
716+ lemma eq_setOf_le_sSup_and_isAtom {α} [CompleteAtomicBooleanAlgebra α] {S : Set α}
717+ (hS : ∀ a ∈ S, IsAtom a) : S = {a | a ≤ sSup S ∧ IsAtom a} := by
718+ ext a
719+ refine ⟨fun h => ⟨CompleteLattice.le_sSup S a h, hS a h⟩, fun ⟨hale, hatom⟩ => ?_⟩
720+ obtain ⟨b, hbS, hba⟩ := exists_mem_le_of_le_sSup_of_isAtom hatom hale
721+ obtain rfl | rfl := (hS b hbS).le_iff.mp hba
722+ · simpa using hatom.1
723+ assumption
724+
725+ /--
726+ Representation theorem for complete atomic boolean algebras:
727+ For a complete atomic Boolean algebra `α`, `toSetOfIsAtom` is an order isomorphism
728+ between `α` and the set of subsets of its atoms.
729+ -/
730+ def toSetOfIsAtom {α} [CompleteAtomicBooleanAlgebra α] : α ≃o (Set {a : α // IsAtom a}) where
731+ toFun A := {a | a ≤ A}
732+ invFun S := sSup (Subtype.val '' S)
733+ left_inv A := by simp [Subtype.coe_image]
734+ right_inv S := by
735+ have h : ∀ a ∈ Subtype.val '' S, IsAtom a := by
736+ rintro a ⟨a', ha', rfl⟩
737+ exact a'.prop
738+ rw [← Subtype.val_injective.image_injective.eq_iff, eq_setOf_le_sSup_and_isAtom h]
739+ ext a
740+ simp
741+ map_rel_iff' {a b} := by
742+ simpa using le_iff_atom_le_imp.symm
743+
706744end CompleteAtomicBooleanAlgebra
707745
708746end Atomistic
0 commit comments