Definition
--- title: Definition of Formal Topology author: Ayberk Tosun date-started: 2026-07-06 date-completed: 2026-09-01 --- This module defines the notions of formal topology and quasi formal topology, following [1] as a reference.{-# OPTIONS --safe --without-K #-} open import UF.FunExt open import UF.PropTrunc module Locales.FormalTopology.Definition (pt : propositional-truncations-exist) (fe : Fun-Ext) where open import Locales.Frame pt fe hiding (â¨_âŠ) open import MLTT.Spartan open import Notation.UnderlyingType open import UF.Logic open import UF.Powerset open import UF.Sets open import UF.SubtypeClassifier open AllCombinators pt fe open PropositionalSubsetInclusionNotation fe\section{Quasi formal topology} We define the notion of quasi formal topology as in Definition 2.1 of [1]. The rule that Negri calls _reflexivity_:satisfies-cover-reflexivity : {A : đ¤ Ě } â (A â đ A â Ί đ¤) â Ί (đ¤ âş) satisfies-cover-reflexivity {_} {A} _â_ = ⹯ a ę A , ⹯ U ę đ A , a ââ U â a â UThe rule that Negri calls _transitivity_:satisfies-cover-transitivity : {A : đ¤ Ě } â (A â đ A â Ί đ¤) â Ί (đ¤ âş) satisfies-cover-transitivity {_} {A} _â_ = ⹯ a ę A , ⹯ U V ę đ A , a â U â U ââ (_â V) â a â VWe are now ready to define the notion of _quasi formal topology_, exactly as defined in Definition 2.1 of [1].Quasi-Formal-Topology-Structure : đ¤ Ě â đ¤ âş Ě Quasi-Formal-Topology-Structure {đ¤} A = ÎŁ _â_ ę (A â đ A â Ί đ¤) , is-set A Ă (satisfies-cover-reflexivity _â_ holds) Ă (satisfies-cover-transitivity _â_ holds) Quasi-Formal-Topology : (đ¤ : Universe) â đ¤ âş Ě Quasi-Formal-Topology đ¤ = ÎŁ A ę đ¤ Ě , Quasi-Formal-Topology-Structure A\subsection{Named projections for quasi formal topologies} Named projections for the `Quasi-Formal-Topology` type.carrier-of-quasi-formal-topology : Quasi-Formal-Topology đ¤ â đ¤ Ě carrier-of-quasi-formal-topology (A , _) = A instance Underlying-Type-Quasi-Formal-Topology : Underlying-Type (Quasi-Formal-Topology đ¤) (đ¤ Ě) Underlying-Type-Quasi-Formal-Topology = record { â¨_⊠= carrier-of-quasi-formal-topology } carrier-of-quasi-formal-topology-is-set : (đ : Quasi-Formal-Topology đ¤) â is-set ⨠đ ⊠carrier-of-quasi-formal-topology-is-set {đ¤} (_ , _ , Ď , _) = Ď cover-of-quasi-formal-topology : (đ : Quasi-Formal-Topology đ¤) â ⨠đ ⊠â đ ⨠đ ⊠â Ί đ¤ cover-of-quasi-formal-topology (_ , _â_ , _) = _â_ infix 5 cover-of-quasi-formal-topology syntax cover-of-quasi-formal-topology đ a U = a âQ[ đ ] U reflexivity-of-quasi-cover : (đ : Quasi-Formal-Topology đ¤) â satisfies-cover-reflexivity (Îť a U â a âQ[ đ ] U) holds reflexivity-of-quasi-cover (_ , _ , _ , β , _) = β transitivity-of-quasi-cover : (đ : Quasi-Formal-Topology đ¤) â satisfies-cover-transitivity (Îť a U â a âQ[ đ ] U) holds transitivity-of-quasi-cover (_ , _ , _ , _ , Îł) = Îł\subsection{Basic properties of quasi formal topologies} We previously used the relation `U â (_â V)`. We now define the syntax `U âQâş[ đ ] V` as an abbreviation for this.cover-plus-of-quasi-formal-topology : (đ : Quasi-Formal-Topology đ¤) â đ ⨠đ ⊠â đ ⨠đ ⊠â Ί đ¤ cover-plus-of-quasi-formal-topology đ U V = U ââ (Îť - â - âQ[ đ ] V) infix 5 cover-plus-of-quasi-formal-topology syntax cover-plus-of-quasi-formal-topology đ U V = U âQâş[ đ ] V transitivity-of-quasi-cover-plus : (đ : Quasi-Formal-Topology đ¤) â (⹯ U V W ę đ ⨠đ ⊠, U âQâş[ đ ] V â V âQâş[ đ ] W â U âQâş[ đ ] W) holds transitivity-of-quasi-cover-plus đ U V W p q a h = transitivity-of-quasi-cover đ a V W â q where â : (a âQ[ đ ] V) holds â = p a hThe `_ââş_` relation is reflexive.reflexivity-of-quasi-cover-plus : (đ : Quasi-Formal-Topology đ¤) â (⹯ U ę đ ⨠đ ⊠, U âQâş[ đ ] U) holds reflexivity-of-quasi-cover-plus đ U a = reflexivity-of-quasi-cover đ a UTwo subsets of a quasi formal topology are called _cover equivalent_ if they cover each other. We define the syntax `U ďź[ đ ]ďź V` to denote this.cover-equivalence-of-quasi-formal-topology : (đ : Quasi-Formal-Topology đ¤) â đ ⨠đ ⊠â đ ⨠đ ⊠â Ί đ¤ cover-equivalence-of-quasi-formal-topology đ U V = (U âQâş[ đ ] V) â§ (V âQâş[ đ ] U) infix 5 cover-equivalence-of-quasi-formal-topology syntax cover-equivalence-of-quasi-formal-topology đ U V = U =[ đ ]= V\subsection{Cover reasoning for quasi formal topologies} The `Quasi-Cover-Reasoning` module defines constructs for writing chains of cover transitivity in a pretty way.module Quasi-Cover-Reasoning (đ : Quasi-Formal-Topology đ¤) where _ââ¨_âŠ_ : (a : ⨠đ âŠ) {U V : đ ⨠đ âŠ} â (a âQ[ đ ] U) holds â (U âQâş[ đ ] V) holds â (a âQ[ đ ] V) holds a â⨠p ⊠q = transitivity-of-quasi-cover đ a _ _ p q _ââşâ¨_âŠ_ : (U : đ ⨠đ âŠ) {V W : đ ⨠đ âŠ} â (U âQâş[ đ ] V) holds â (V âQâş[ đ ] W) holds â (U âQâş[ đ ] W) holds U ââşâ¨ p ⊠q = transitivity-of-quasi-cover-plus đ U _ _ p q _ďźâ¨_âŠc_ : (U : đ ⨠đ âŠ) {V W : đ ⨠đ âŠ} â U ďź V â (V âQâş[ đ ] W) holds â (U âQâş[ đ ] W) holds _ ďźâ¨ p âŠc q = transport (Îť - â (- âQâş[ đ ] _) holds) (p âťÂš) q _â : (U : đ ⨠đ âŠ) â (U âQâş[ đ ] U) holds _â = reflexivity-of-quasi-cover-plus đ infixr 0 _ââ¨_âŠ_ infixr 0 _ââşâ¨_âŠ_ infixr 0 _ďźâ¨_âŠc_ infix 1 _â\section{Formal topology} A formal topology is a quasi formal topology equipped with a partial order, satisfying the additional axioms of _left_ and _right_. These are the last two rules given in Definition 2.1 of [1]. We first define the condition that Negri [1] calls _left_:satisfies-cover-left-rule : {A : đ¤ Ě} â (A â A â Ί đ¤) â (A â đ A â Ί đ¤) â Ί (đ¤ âş) satisfies-cover-left-rule {_} {A} _â_ _â_ = ⹯ a b ę A , ⹯ U ę đ A , b â a â a â U â b â USome notation for downward closures of sets as well as the intersection of downward closures.module Downward-Closure-Intersection-Syntax {A : đ¤ Ě} (_â_ : A â A â Ί đ¤) where â_ : đ A â đ A â U = Îť a â Ćâ u ę A , (u ââ U â§ a â u) _â_ : đ A â đ A â đ A U â V = (â U) ⊠(â V) infix 6 _â_ infix 7 â_Now, we define the condition that Negri calls _right_:satisfies-cover-right-rule : {A : đ¤ Ě} â (A â A â Ί đ¤) â (A â đ A â Ί đ¤) â Ί (đ¤ âş) satisfies-cover-right-rule {_} {A} _â_ _â_ = ⹯ a ę A , ⹯ U V ę đ A , a â U â a â V â a â (U â V) where open Downward-Closure-Intersection-Syntax _â_ using (_â_)We are now ready to define the notion of formal topology. Unlike Negri, we also require the order in consideration to be antisymmetric.Formal-Topology-Structure : đ¤ Ě â đ¤ âş Ě Formal-Topology-Structure {đ¤} A = ÎŁ _â_ ę (A â A â Ί đ¤) , ÎŁ _â_ ę (A â đ A â Ί đ¤) , (is-reflexive _â_ holds) Ă (is-transitive _â_ holds) Ă (is-antisymmetric _â_) Ă (satisfies-cover-reflexivity _â_ holds) Ă (satisfies-cover-transitivity _â_ holds) Ă (satisfies-cover-left-rule _â_ _â_ holds) Ă (satisfies-cover-right-rule _â_ _â_ holds) Formal-Topology : (đ¤ : Universe) â đ¤ âş Ě Formal-Topology đ¤ = ÎŁ A ę đ¤ Ě , Formal-Topology-Structure A\subsection{Named projections for formal topologies} We now define some named projections for the `Formal-Topology` type.carrier-of-formal-topology : Formal-Topology đ¤ â đ¤ Ě carrier-of-formal-topology (A , _) = A instance Underlying-Type-Formal-Topology : Underlying-Type (Formal-Topology đ¤) (đ¤ Ě) Underlying-Type-Formal-Topology = record { â¨_⊠= carrier-of-formal-topology } order-of-formal-topology : (đ : Formal-Topology đ¤) â ⨠đ ⊠â ⨠đ ⊠â Ί đ¤ order-of-formal-topology (_ , _â_ , _) = _â_ infix 5 order-of-formal-topology syntax order-of-formal-topology đ a b = a â[ đ ] b cover-of-formal-topology : (đ : Formal-Topology đ¤) â ⨠đ ⊠â đ ⨠đ ⊠â Ί đ¤ cover-of-formal-topology (_ , _ , _â_ , _) = _â_ infix 5 cover-of-formal-topology syntax cover-of-formal-topology đ a U = a â[ đ ] U reflexivity-of-order : (đ : Formal-Topology đ¤) â is-reflexive (order-of-formal-topology đ) holds reflexivity-of-order (_ , _ , _ , β , _) = β transitivity-of-order : (đ : Formal-Topology đ¤) â is-transitive (order-of-formal-topology đ) holds transitivity-of-order (_ , _ , _ , _ , Îł , _) = Îł antisymmetry-of-order : (đ : Formal-Topology đ¤) â is-antisymmetric (order-of-formal-topology đ) antisymmetry-of-order (_ , _ , _ , _ , _ , δ , _) = δ cover-satisfies-left-rule : (đ : Formal-Topology đ¤) â satisfies-cover-left-rule (order-of-formal-topology đ) (cover-of-formal-topology đ) holds cover-satisfies-left-rule (_ , _ , _ , _ , _ , _ , _ , _ , Ρ , _) = Ρ cover-satisfies-right-rule : (đ : Formal-Topology đ¤) â satisfies-cover-right-rule (order-of-formal-topology đ) (cover-of-formal-topology đ) holds cover-satisfies-right-rule (_ , _ , _ , _ , _ , _ , _ , _ , _ , θ) = θThe sethood of the carrier of a formal topology follows from the fact it is equipped with a partial order.carrier-of-formal-topology-is-set : (đ : Formal-Topology đ¤) â is-set ⨠đ ⊠carrier-of-formal-topology-is-set {đ¤} (A , _â_ , _ , β , Îł , δ , _) = carrier-of-[ P ]-is-set where P : Poset đ¤ đ¤ P = A , _â_ , (β , Îł) , δThe underlying poset of a formal topology.underlying-poset-of-formal-topology : (đ : Formal-Topology đ¤) â Poset đ¤ đ¤ underlying-poset-of-formal-topology {đ¤} (A , _â_ , _ , β , Îł , δ , _) = A , _â_ , (β , Îł) , δThe underlying quasi formal topology of a formal topology.underlying-quasi-formal-topology : Formal-Topology đ¤ â Quasi-Formal-Topology đ¤ underlying-quasi-formal-topology đ@(A , _ , _â_ , _ , _ , _ , Ď , Ď , _ , _) = A , _â_ , carrier-of-formal-topology-is-set đ , Ď , ĎThe `_ââş_` operation for formal topologies.cover-plus-of-formal-topology : (đ : Formal-Topology đ¤) â đ ⨠đ ⊠â đ ⨠đ ⊠â Ί đ¤ cover-plus-of-formal-topology = cover-plus-of-quasi-formal-topology â underlying-quasi-formal-topology infix 5 cover-plus-of-formal-topology syntax cover-plus-of-formal-topology đ U V = U ââş[ đ ] V transitivity-of-cover-plus : (đ : Formal-Topology đ¤) â (⹯ U V W ę đ ⨠đ ⊠, U ââş[ đ ] V â V ââş[ đ ] W â U ââş[ đ ] W) holds transitivity-of-cover-plus = transitivity-of-quasi-cover-plus â underlying-quasi-formal-topology\section{Bibliography} [1]: Sara Negri. _Continuous domains as formal spaces_. Mathematical Structures in Computer Science, Volume 12, No. 1, pp. 19â52, 2002. DOI:10.1017/S0960129501003450