---
title: Morphism of formal topologies
author: Ayberk Tosun
date-started: 2026-08-25
date-completed: 2026-08-27
---
This module defines morphisms between formal topologies as well as quasi formal
topologies, following [1] as a reference.
\begin{code}
{-# OPTIONS --safe --without-K #-}
open import UF.FunExt
open import UF.PropTrunc
open import UF.Subsingletons
module Locales.FormalTopology.Morphism
(pt : propositional-truncations-exist)
(fe : Fun-Ext)
(pe : Prop-Ext)
where
open import Locales.FormalTopology.Definition pt fe
open import Locales.Frame pt fe hiding (β¨_β©)
open import MLTT.Spartan
open import Notation.CanonicalMap
open import Notation.UnderlyingType
open import UF.Logic
open import UF.Powerset
open import UF.Sets
open import UF.Sets-Properties
open import UF.SubtypeClassifier
open AllCombinators pt fe
open PropositionalTruncation pt
\end{code}
\section{Preliminaries}
Given a subset `U : π A` and a function `f : A β π B`, the type
`relational-image f U` denotes the union `β_{u β U} f u`.
\begin{code}
relational-image : {A B : π€ Μ} β (A β π B) β π A β π B
relational-image {π€} {A} {B} f U = β {π U} Ξ» { (a , _) β f a }
where
open unions-of-small-families pt π€ π€ B
\end{code}
We define the syntax `f β¦
U β¦` for the image of a relation over a subset `U`.
\begin{code}
relational-image-syntax : {A B : π€ Μ} β (A β π B) β π A β π B
relational-image-syntax f U = relational-image f U
infix 25 relational-image-syntax
syntax relational-image-syntax f U = f β¦
U β¦
\end{code}
\section{Morphisms of quasi formal topologies}
\begin{code}
module Quasi-Formal-Topology-Morphism
{π€ : Universe}
(π : Quasi-Formal-Topology π€)
(β¬ : Quasi-Formal-Topology π€)
where
private
A = β¨ π β©
B = β¨ β¬ β©
\end{code}
Negri [1] defines a quasi formal topology morphism as a relation (1) preserving
the top subset, and (2) preserving the covering relation.
\begin{code}
preserves-top : (A β π B) β Ξ© π€
preserves-top f = full βQβΊ[ β¬ ] f β¦
full β¦
preserves-covering : (A β π B) β Ξ© (π€ βΊ)
preserves-covering f =
β±― a κ A , β±― U κ π A , a βQ[ π ] U β f a βQβΊ[ β¬ ] f β¦
U β¦
is-quasi-formal-topology-morphism : (A β π B) β Ξ© (π€ βΊ)
is-quasi-formal-topology-morphism f = preserves-top f β§ preserves-covering f
\end{code}
Using this, we write down the type of quasi formal topology morphisms between
quasi formal topologies `π` and `β¬`.
\begin{code}
_βqftβ_ : π€ βΊ Μ
_βqftβ_ = Ξ£ f κ (A β π B) , is-quasi-formal-topology-morphism f holds
infix 0 _βqftβ_
\end{code}
We denote by `fun π»` the underlying function of a quasi formal topology
morphism `π»`.
\begin{code}
fun : _βqftβ_ β A β π B
fun (f , _) = f
instance
canonical-map-quasi-formal-topology-morphism-function
: Canonical-Map _βqftβ_ (A β π B)
ΞΉ {{canonical-map-quasi-formal-topology-morphism-function}} = fun
\end{code}
We now define named projections for the `_βqftβ_` type.
\begin{code}
fun-is-quasi-formal-topology-morphism
: (π» : _βqftβ_)
β is-quasi-formal-topology-morphism [ π» ] holds
fun-is-quasi-formal-topology-morphism (_ , Ο) = Ο
fun-preserves-top : (π» : _βqftβ_) β preserves-top [ π» ] holds
fun-preserves-top (_ , Ο , _) = Ο
fun-preserves-covering : (π» : _βqftβ_) β preserves-covering [ π» ] holds
fun-preserves-covering (_ , _ , Ο) = Ο
fun-preserves-covering-plus
: (π» : _βqftβ_)
β (β±― U V κ π β¨ π β© , U βQβΊ[ π ] V β [ π» ] β¦
U β¦ βQβΊ[ β¬ ] [ π» ] β¦
V β¦) holds
fun-preserves-covering-plus π» U V p b h =
β₯β₯-rec (holds-is-prop (b ββ (Ξ» - β - βQ[ β¬ ] ([ π» ] β¦
V β¦)))) β h
where
f = [ π» ]
β : Ξ£ (a , _) κ π U , b β f a β b β (Ξ» - β - βQ[ β¬ ] f β¦
V β¦)
β ((a , ΞΌ) , q) = b ββ¨ β
β©
f a ββΊβ¨ β
‘ β©
f β¦
V β¦ β
where
open Quasi-Cover-Reasoning β¬
β
‘ : (f a βQβΊ[ β¬ ] f β¦
V β¦) holds
β
‘ = fun-preserves-covering π» a V (p a ΞΌ)
β
: (b βQ[ β¬ ] f a) holds
β
= reflexivity-of-quasi-cover β¬ b (f a) q
\end{code}
The lemma below states that the extensional equality of the underlying function
is sufficient to establish the equality of two quasi formal topology morphisms.
\begin{code}
to-quasi-formal-topology-morphism-οΌ
: (π» β : _βqftβ_)
β [ π» ] βΌ [ β ]
β π» οΌ β
to-quasi-formal-topology-morphism-οΌ π» β = to-subtype-οΌ β β dfunext fe
where
β : (f : A β π B)
β is-prop (is-quasi-formal-topology-morphism f holds)
β f = holds-is-prop (is-quasi-formal-topology-morphism f)
\end{code}
The type of quasi formal topology morphisms is a set.
\begin{code}
_βqftβ_-is-set : is-set _βqftβ_
_βqftβ_-is-set =
subsets-of-sets-are-sets
(A β π B)
(_holds β is-quasi-formal-topology-morphism)
(Ξ -is-set fe (Ξ» _ β π-is-set' fe pe))
(Ξ» {f} β holds-is-prop (is-quasi-formal-topology-morphism f))
\end{code}
\section{Morphisms of formal topologies}
We now define the notion of formal topology morphism, following Definition 2.4
of [1]. A formal topology morphism is a quasi formal topology morphism that
additionally preserves binary meets in the sense of Condition 2 from [1].
\begin{code}
module Formal-Topology-Morphism
(π : Formal-Topology π€)
(β¬ : Formal-Topology π€)
where
private
A = β¨ π β©
B = β¨ β¬ β©
πβ : Quasi-Formal-Topology π€
πβ = underlying-quasi-formal-topology π
β¬β : Quasi-Formal-Topology π€
β¬β = underlying-quasi-formal-topology β¬
open Downward-Closure-Intersection-Syntax (Ξ» a b β a β[ β¬ ] b)
renaming (_β_ to _ββ¬_)
open Quasi-Formal-Topology-Morphism πβ β¬β
\end{code}
We denote by `lower-bounds a b` the set of lower bounds for `a` and `b`.
\begin{code}
lower-bounds : β¨ π β© β β¨ π β© β π β¨ π β©
lower-bounds a b = Ξ» c β (c β[ π ] a) β§ (c β[ π ] b)
\end{code}
A function `f : β¨ π β© β π β¨ β¬ β©` is said to _preserve binary meets_
if `f β¦
lower-bounds aβ aβ β¦` covers `f aβ β f aβ` for every pair of elements
`aβ aβ : β¨ π β©`.
\begin{code}
preserves-binary-meets : (β¨ π β© β π β¨ β¬ β©) β Ξ© π€
preserves-binary-meets f =
β±― aβ aβ κ β¨ π β© , (f aβ ββ¬ f aβ) ββΊ[ β¬ ] f β¦
lower-bounds aβ aβ β¦
\end{code}
A formal topology morphism is a function `f : β¨ π β© β π β¨ β¬ β©` that
1. preserves the top subset,
2. preserves binary meets, and
3. preserves the covering relation.
\begin{code}
is-formal-topology-morphism : (A β π B) β Ξ© (π€ βΊ)
is-formal-topology-morphism f =
preserves-top f β§ preserves-binary-meets f β§ preserves-covering f
\end{code}
Using this, we write down the type of formal topology morphisms between the
formal topologies `π` and `β¬` and then define the named projections.
\begin{code}
_βftβ_ : π€ βΊ Μ
_βftβ_ = Ξ£ f κ (A β π B) , is-formal-topology-morphism f holds
infix 0 _βftβ_
ft-fun : _βftβ_ β A β π B
ft-fun (f , _) = f
instance
canonical-map-formal-topology-morphism-function
: Canonical-Map _βftβ_ (A β π B)
ΞΉ {{canonical-map-formal-topology-morphism-function}} = ft-fun
fun-is-formal-topology-morphism
: (π» : _βftβ_)
β is-formal-topology-morphism [ π» ] holds
fun-is-formal-topology-morphism (_ , Ο) = Ο
ft-fun-preserves-top : (π» : _βftβ_) β preserves-top [ π» ] holds
ft-fun-preserves-top (_ , Ο , _) = Ο
ft-fun-preserves-binary-meets : (π» : _βftβ_) β preserves-binary-meets [ π» ] holds
ft-fun-preserves-binary-meets (_ , _ , Ο , _) = Ο
ft-fun-preserves-covering : (π» : _βftβ_) β preserves-covering [ π» ] holds
ft-fun-preserves-covering (_ , _ , _ , Ο) = Ο
\end{code}
Every formal topology morphism is a quasi formal topology morphism when
Condition (2) is dropped.
\begin{code}
to-qft-morphism : _βftβ_ β _βqftβ_
to-qft-morphism (f , Ο , _ , Ο) = f , Ο , Ο
from-qft-morphism : (π» : _βqftβ_) β preserves-binary-meets [ π» ] holds β _βftβ_
from-qft-morphism π»@(f , Ξ² , Ξ΄) Ξ³ = f , Ξ² , Ξ³ , Ξ΄
\end{code}
We now prove the analogue of `to-quasi-formal-topology-morphism-οΌ` for formal
topologies.
\begin{code}
to-formal-topology-morphism-οΌ
: (π» β : _βftβ_)
β [ π» ] βΌ [ β ]
β π» οΌ β
to-formal-topology-morphism-οΌ π» β = to-subtype-οΌ β β dfunext fe
where
β : (f : A β π B) β is-prop (is-formal-topology-morphism f holds)
β f = holds-is-prop (is-formal-topology-morphism f)
\end{code}
The type of formal topology morphisms is a set.
\begin{code}
_βftβ_-is-set : is-set _βftβ_
_βftβ_-is-set =
subsets-of-sets-are-sets
(A β π B)
(_holds β is-formal-topology-morphism)
(Ξ -is-set fe (Ξ» _ β π-is-set' fe pe))
(Ξ» {f} β holds-is-prop (is-formal-topology-morphism f))
\end{code}
\section{Identity morphisms}
In this section, we define the identity morphisms on formal and quasi formal
topologies.
\begin{code}
open Quasi-Formal-Topology-Morphism hiding (preserves-top; preserves-covering)
identity-morphism-qft : (π : Quasi-Formal-Topology π€) β π βqftβ π
identity-morphism-qft π = (Ξ» a β β΄ a β΅) , Ξ² , Ξ³
where
open singleton-subsets (carrier-of-quasi-formal-topology-is-set π)
open Quasi-Formal-Topology-Morphism π π
Ξ² : preserves-top (Ξ» - β β΄ - β΅) holds
Ξ² a β = reflexivity-of-quasi-cover π a (β΄_β΅ β¦
full β¦) β£ (a , β) , refl β£
singleton-image-lemma : (U : π β¨ π β©) β ((Ξ» - β β΄ - β΅) β¦
U β¦) οΌ U
singleton-image-lemma U = subset-extensionality pe fe β
β
‘
where
β
: (β΄_β΅ β¦
U β¦) β U
β
a p = β₯β₯-rec (holds-is-prop (a ββ U)) β p
where
β : _
β ((b , h) , q) = transport (Ξ» - β - β U) q h
β
‘ : U β (β΄_β΅ β¦
U β¦)
β
‘ a p = β£ (a , p) , refl β£
Ξ³ : preserves-covering (Ξ» - β β΄ - β΅) holds
Ξ³ a U p =
transport (Ξ» V β (β΄ a β΅ βQβΊ[ π ] V) holds) (singleton-image-lemma U β»ΒΉ) β
where
β : (β΄ a β΅ βQβΊ[ π ] U) holds
β b q = transport (Ξ» - β cover-of-quasi-formal-topology π - U holds) q p
open Formal-Topology-Morphism
identity-morphism-ft : (π : Formal-Topology π€) β π βftβ π
identity-morphism-ft π = from-qft-morphism π π (identity-morphism-qft πβ) Ξ²
where
πβ = underlying-quasi-formal-topology π
P = underlying-poset-of-formal-topology π
open singleton-subsets (carrier-of-quasi-formal-topology-is-set πβ)
Ξ² : preserves-binary-meets π π (fun πβ πβ (identity-morphism-qft πβ)) holds
Ξ² aβ aβ a (pβ , pβ) = β₯β₯-recβ (holds-is-prop (a βQ[ πβ ] _)) Ξ³ pβ pβ
where
Ξ³ : Ξ£ aββ² κ β¨ π β© , (aβ οΌ aββ²) Γ (a β€[ P ] aββ²) holds
β Ξ£ aββ² κ β¨ π β© , (aβ οΌ aββ²) Γ (a β€[ P ] aββ²) holds
β (a β[ π ] β΄_β΅ β¦
lower-bounds π π aβ aβ β¦) holds
Ξ³ (aββ² , rβ , qβ) (aββ² , rβ , qβ) =
reflexivity-of-quasi-cover πβ a _ β£ (a , β
, β
‘) , refl β£
where
open PosetReasoning P
β
: (a β€[ P ] aβ) holds
β
= a β€β¨ qβ β© aββ² οΌβ¨ rβ β»ΒΉ β©β aβ β
β
‘ : (a β€[ P ] aβ) holds
β
‘ = a β€β¨ qβ β© aββ² οΌβ¨ rβ β»ΒΉ β©β aβ β
\end{code}
\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