Locales.Compactness.CharacterizationOfCompactLocales
--- title: Characterizations of compact locales author: Ayberk Tosun date-started: 2025-04-23 date-completed: 2024-04-29 ---{-# OPTIONS --safe --without-K --lossy-unification #-} open import MLTT.Spartan hiding (J) open import UF.Base open import UF.Classifiers open import UF.FunExt open import UF.PropTrunc open import UF.Sets open import UF.Size open import UF.Subsingletons open import UF.Subsingletons-FunExt open import UF.Subsingletons-Properties open import UF.SubtypeClassifier module Locales.Compactness.CharacterizationOfCompactLocales (pt : propositional-truncations-exist) (fe : Fun-Ext) (pe : Prop-Ext) (sr : Set-Replacement pt) where open import Locales.AdjointFunctorTheoremForFrames open import Locales.CompactRegular pt fe using (clopens-are-compact-in-compact-frames; is-clopen; compacts-are-clopen-in-zero-dimensional-locales; frame-homomorphisms-preserve-complements; complementation-is-symmetric; is-complement-of) open import Locales.Compactness.Definition pt fe open import Locales.ContinuousMap.Definition pt fe open import Locales.ContinuousMap.FrameHomomorphism-Definition pt fe open import Locales.Frame pt fe renaming (β¨_β© to β¨_β©β) hiding (β ) open import Locales.PosetalAdjunction pt fe open import Locales.InitialFrame pt fe open import Locales.PerfectMaps pt fe open import Locales.Spectrality.SpectralityOfOmega pt fe sr open import Locales.TerminalLocale.Properties pt fe sr open import Notation.UnderlyingType open import Slice.Family open import UF.Logic open AllCombinators pt fe open ContinuousMaps open FrameHomomorphisms open Locale open PropositionalTruncation pt instance underlying-type-of-frame : Underlying-Type (Frame π€ π₯ π¦) (π€ Μ ) β¨_β© {{underlying-type-of-frame}} (A , _) = A\section{Preliminaries} The universal property of the inital frame gives that there is a unique frame homomorphism `Ξ© β πͺ(X)`, for every locale `X`. We denote this by `!`. We also define the shorthand notation `!κ³` for the underlying function of the frame homomorphism in consideration.!_ : (X : Locale (π€ βΊ) π€ π€) β X βcβ πLoc pe ! X = center (π-π½π£π-initial pe (πͺ X)) !κ³[_]_ : (X : Locale (π€ βΊ) π€ π€) β Ξ© π€ β β¨ πͺ X β© !κ³[_]_ X = fun (π-π½π£π pe) (πͺ X) (! X)Note here that the notation `_κ³` is intended to mimic a superscript asterisk. Sadly, there is no proper superscript asterisk in Unicode so we use the Slavonic asterisk. We also define some shorthand notation for the right adjoint of this map, which we know to exist since the initial frame has a small base. We denote by `!β[ X ]_` the underlying function of the right adjoint of `!κ³[ X ]_`.!β[_]_ : (X : Locale (π€ βΊ) π€ π€) β β¨ πͺ X β© β Ξ© π€ !β[_]_ {π€} X = ! X βΒ·_ where open Spectrality-of-π π€ pe open AdjointFunctorTheorem pt fe X (πLoc pe) β£ β¬πβ , β¬πβ-is-basis β£Thinking of a frame as a system of finitely verifiable properties, the above map can be thought of as the **universal quantifier** for these properties: it takes some open `U : β¨ πͺ X β©` and tells if `U οΌ π[ πͺ X ]`.!β-is-universal-quantifier : (X : Locale (π€ βΊ) π€ π€) β (U : β¨ πͺ X β©) β (!β[ X ] U) holds β U οΌ π[ πͺ X ] !β-is-universal-quantifier {π€} X U = β , β‘ where open Spectrality-of-π π€ pe open AdjointFunctorTheorem pt fe X (πLoc pe) β£ β¬πβ , β¬πβ-is-basis β£ open PosetReasoning (poset-of (πͺ X)) β : (!β[ X ] U) holds β U οΌ π[ πͺ X ] β p = only-π-is-above-π (πͺ X) U Ξ³ where β ‘ : (!κ³[ X ] β€ β€[ poset-of (πͺ X) ] U) holds β ‘ = adjunction-inequality-backward (! X) U β€ Ξ» { β β p } β : π[ πͺ X ] οΌ !κ³[ X ] β€ β = frame-homomorphisms-preserve-top (π-π½π£π pe) (πͺ X) (! X) β»ΒΉ Ξ³ : (π[ πͺ X ] β€[ poset-of (πͺ X) ] U) holds Ξ³ = π[ πͺ X ] οΌβ¨ β β©β (!κ³[ X ] β€) β€β¨ β ‘ β© U β β‘ : U οΌ π[ πͺ X ] β (!β[ X ] U) holds β‘ p = Ξ³ β where β : π[ πͺ X ] οΌ !κ³[ X ] β€ β = frame-homomorphisms-preserve-top (π-π½π£π pe) (πͺ X) (! X) β»ΒΉ q : (!κ³[ X ] β€ β€[ poset-of (πͺ X) ] U) holds q = !κ³[ X ] β€ οΌβ¨ β β»ΒΉ β©β π[ πͺ X ] οΌβ¨ p β»ΒΉ β©β U β Ξ³ : (β€ β !β[ X ] U) holds Ξ³ = adjunction-inequality-forward (! X) U β€ qAccordingly, we define some suggestive notation, which we use when we want to highlight this attitude on the right adjoint.locale-forall-syntax : (X : Locale (π€ βΊ) π€ π€) β β¨ πͺ X β© β Ξ© π€ locale-forall-syntax X U = !β[ X ] U syntax locale-forall-syntax X U = β±―[ X ] U infix 7 locale-forall-syntax\section{Characterization of compactness} This result was added on 2025-04-29. We work in a module parameterized by a locale `X`, being the locale whose compactness we are interested in.module CharacterizationOfCompactLocales (X : Locale (π€ βΊ) π€ π€) where open Spectrality-of-π π€ pe open AdjointFunctorTheorem pt fe X (πLoc pe) β£ β¬πβ , β¬πβ-is-basis β£ open PerfectMaps X (πLoc pe) β£ β¬πβ , β¬πβ-is-basis β£ open SpectralMaps X (πLoc pe)An alternative way to express that a locale `X` is compact is by asserting that the map `! X` is perfect, which is to say that the universal quantifier `β±―[ X ]_` is Scott continuous. Because a map into a spectral locale is perfect if and only if it reflects compact opens (i.e. is βspectralβ), this is the same thing as saying `! X` is spectral.perfection-of-!-implies-the-spectrality-of-! : (is-perfect-map (! X) β is-spectral-map (! X)) holds perfection-of-!-implies-the-spectrality-of-! = perfect-maps-are-spectral (! X) spectrality-of-!-implies-the-perfection-of-! : (is-spectral-map (! X) β is-perfect-map (! X)) holds spectrality-of-!-implies-the-perfection-of-! Ο = spectral-maps-are-perfect (π-π½π£π-is-spectral π€ pe) (! X) ΟWe now prove that this alternative formulation of compactness implies the standard one. The proof is quite simple: - We have to show that the top `π[ πͺ X ]` is compact. - Because `!κ³[ X ]` is a frame homomorphism, we have that `π = !κ³[ X ] β€`, so it suffices to show that `!κ³[ X ] β€` is compact. - Since we are given that `!κ³[ X ] β€` preserves compact opens, we just have to show that `β€` is compact, which we know since the terminal locale is compact.perfection-of-!-gives-compactness : (is-perfect-map (! X) β is-compact X) holds perfection-of-!-gives-compactness ΞΊ = transport (Ξ» - β is-compact-open X - holds) (q β»ΒΉ) β where open Spectrality-of-π π€ pe q : π[ πͺ X ] οΌ !κ³[ X ] β€ q = frame-homomorphisms-preserve-top (π-π½π£π pe) (πͺ X) (! X) β»ΒΉ π€ : SpectralMaps.is-spectral-map X (πLoc pe) (! X) holds π€ = perfect-maps-are-spectral (! X) ΞΊ β : is-compact-open X (!κ³[ X ] β€) holds β = π€ π[ π-π½π£π pe ] (πFrm-is-compact π€ pe)We now tackle the other direction. - Suppose `X` is compact in the standard sense. - Let `K : Ξ©` be a compact open of the terminal locale. - We need to show that `!κ³[ X ] K` is compact. - Since `X` is a compact locale, and clopens are compact in compact frames, we simply have to show that `!κ³[ X ] K` is a clopen. - This is easy since we already know that `K` is a clopen in `Ξ©` (since `Ξ©` is a Stone locale, in which the clopens and the compact opens coincide) and frame homomorphisms preserve complements.compactness-gives-perfection-of-! : (is-compact X β is-perfect-map (! X)) holds compactness-gives-perfection-of-! ΞΊ = spectrality-of-!-implies-the-perfection-of-! β where β : is-spectral-map (! X) holds β P π = clopens-are-compact-in-compact-frames (πͺ X) ΞΊ (!κ³[ X ] P) β‘ where ΞΎ : is-clopen (π-π½π£π pe) P holds ΞΎ = compact-implies-clopen pe P π Pβ² : Ξ© π€ Pβ² = prβ ΞΎ ΞΆ : is-complement-of (πͺ X) (!κ³[ X ] Pβ²) (!κ³[ X ] P) ΞΆ = frame-homomorphisms-preserve-complements (π-π½π£π pe) (πͺ X) (! X)(complementation-is-symmetric (π-π½π£π pe) _ _ (prβ ΞΎ)) β‘ : is-clopen (πͺ X) (!κ³[ X ] P) holds β‘ = !κ³[ X ] Pβ² , ΞΆ\section{Acknowledgements} I have benefited from Graham Manuell's notes on constructive locale theory [1], where this characterization of compactness is discussed. The proof here is different, however, as it uses the machinery of spectral and perfect maps. [1]: Manuell, Graham. "Pointfree topology and constructive mathematics." arXiv preprint arXiv:2304.06000 (2023).