+-- {: .rightHandSide}
+-- {: .toc .clickDown tabindex="0"}
###Context###
#### $(\infty,1)$-Category theory
+--{: .hide}
[[!include quasi-category theory contents]]
=--
#### Enriched category theory
+--{: .hide}
[[!include enriched category theory contents]]
=--
=--
=--

\tableofcontents

## Idea

As a model for an [[(∞,1)-categories]], [[sSet-enriched categories]] ("[[simplicial categories]]") may be thought of as a [[semi-strict infinity-category|semi-strictification]] of a [[quasi-category]], where [[composition]] along [[objects]] is strictly [[associativity|associative]] and [[unitality|unital]].

The equivalence between [[quasi-categories]] and [[sSet-enriched categories]] as models for [[(∞,1)-categories]] is exhibited by the operation of sending an $sSet$-category $\mathbf{C}$ to the [[simplicial set]] $N(\mathcal{C})$ called its *[[homotopy-coherent nerve]]* (in generalization of the [[simplicial nerve]] of an ordinary [[category]]). Together with its [[left adjoint]] operation $\mathfrak{C}$ ("[[rigidification of quasi-categories]]") this constitutes a [[Quillen equivalence]] between the two models.

## The Quillen equivalence

Our notation partly follows [Bergner (2018)](#Bergner18).

\begin{proposition}
\label{TheQuillenEquivalence}
There is a [[Quillen equivalence]]:

$$
 sSet\text{-}Cat
 \underoverset
   {\underset{\tilde N}{\longrightarrow}}
   {\overset{\mathfrak{C}}{\longleftarrow}}
   {\;\;\; \bot \;\;\;}
 sSet.
$$

where:

* $SC$ denotes the category of [[sSet-enriched categories]]
equipped with the [[Dwyer–Kan–Bergner model structure]],

* $sSet$ denotes the [[Joyal model structure]] on [[simplicial sets]],

* $\tilde N$ denotes the [[homotopy coherent nerve]] functor,

* $\mathfrak{C}$ denotes [[rigidification of quasi-categories]].

In particular, for $C$ a fibrant [[SSet]]-[[enriched category]], the canonical morphism

$$
  \mathfrak{C}\big(\tilde N(C)\big)
  \longrightarrow
  C
$$

given by the [[adjunction counit|counit]] of the above adjunction is [[derived functor|derived]], hence a [[Dwyer–Kan weak equivalence]] of [[simplicial categories]].

For $S$ any [[simplicial set]], the canonical morphism

$$
  S
  \longrightarrow
  \tilde N\Big(
    R\big(
      \mathfrak{C}(S)
    \big)
  \Big)
$$

is a [[model structure for quasi-categories|categorical equivalence]] of simplicial sets,
where $R$ denotes a [[fibrant replacement]] functor in the [[Dwyer–Kan–Bergner model structure]].
\end{proposition}
This was claimed and credited to [[André Joyal|Joyal]] in [Bergner (2007), Thm. 7.8](#Bergner07); detailed proof was produced in [Lurie (2009), Thm. 2.2.5.1 & p. 91](#Lurie09).

For more details on the [[rigidification of quasi-categories]] see also [Dugger & Spivak (2009a)](#DuggerSpivak.Rigidification), [(2009b)](#DuggerSpivak.Mapping).

## Relations

### Via $\bar W$-construction

We have an evident inclusion
$$sSet Cat \hookrightarrow Cat^{\Delta}$$
of [[simplicially enriched categories]]
into [[simplicial objects in Cat]].

On the latter the $\bar W$-functor is defined as the composite
$$
  \bar W
   \colon
  Cat^\Delta
   \stackrel{N^\Delta}{\to}
  sSet^\Delta
   \stackrel{}{\to}
  sSet
$$
where first we degreewise form the ordinary [[nerve]] of categories and then take the total simplicial set of [[bisimplicial sets]] (the [[right adjoint]] of pullback along the [[diagonal]] $\Delta^n \to \Delta^n \times \Delta^n$).

+-- {: .num_prop}
###### Proposition

For $C$ a [[simplicial groupoid]] there is a [[weak homotopy equivalence]]
$$\mathcal{N}(C) \to \bar W(C)$$
from the [[homotopy coherent nerve]]

=--

([Hinich](#Hinich))

## Related concepts

* [[straightening and unstraightening]]

* [[simplicial category]]

  * [[simplicially enriched category]]

  * [[simplicial object in Cat]]

* [[simplicial groupoid]]

There is an [[operad|operadic]] analog of the relation between quasi-categories and simplicial categories, involving, correspondingly, [[dendroidal sets]] and [[simplicial operads]].

## References

The notion of the [[homotopy coherent nerve]] (see there for more) goes back to [Cordier (1982)](homotopy+coherent+nerve#Cordier82); [Cordier & Porter(1986)](homotopy+coherent+nerve#CordierPorter86).

The [[Quillen equivalence]] between the [[model structure for quasi-categories]] and the [[model structure on sSet-categories]] is described in

* {#Lurie09} [[Jacob Lurie]], §1.1.5 and §2.2 of: _[[Higher Topos Theory]]_, Annals of Mathematics Studies **170**, Princeton University Press (2009) [[pup:8957](https://press.princeton.edu/titles/8957.html), [pdf](https://www.math.ias.edu/~lurie/papers/HTT.pdf)]

after an unpublished proof by [[André Joyal]] was announced in:

* {#Bergner07} [[Julie Bergner]], Theorem 7.8 in: *A survey of $(\infty,1)$-categories*, in: [[John Baez]], [[Peter May]] (eds.),  _[[Towards Higher Categories]]_ The IMA Volumes in Mathematics and its Applications **152**, Springer (2007) [[arXiv:math/0610239](http://arxiv.org/abs/math/0610239), [doi:10.1007/978-1-4419-1524-5_2](https://doi.org/10.1007/978-1-4419-1524-5_2)]

Further discussion of [[rigidification of quasi-categories]] $\mathfrak{C}$:

* {#DuggerSpivak.Rigidification} [[Dan Dugger]], [[David Spivak]], *Rigidification of quasi-categories*, Algebr. Geom. Topol. **11** (2011) 225-261 [[arXiv:0910.0814](http://arxiv.org/abs/0910.0814), [doi:10.2140/agt.2011.11.225](http://dx.doi.org/10.2140/agt.2011.11.225)]

* {#DuggerSpivak.Mapping} [[Dan Dugger]], [[David Spivak]], *Mapping spaces in quasi-categories*, Algebr. Geom. Topol. **11** (2011) 263-325 [[arXiv:0911.0469](http://arxiv.org/abs/0911.0469), [doi:10.2140/agt.2011.11.263](http://dx.doi.org/10.2140/agt.2011.11.263)]

More along these lines is in

* [[Emily Riehl]], *On the structure of simplicial categories associated to quasi-categories*, Math. Proc. Camb. Phil. Soc. **150** (2011) 489-504 [[arXiv:0912.4809](https://arxiv.org/abs/0912.4809), [doi:10.1017/S0305004111000053](https://doi.org/10.1017/S0305004111000053)]

An expository account is in Section 7.8

* {#Bergner18} [[Julie Bergner]], _The homotopy theory of (∞,1)-categories_, London Mathematical Society Student Texts 90, 2018.

See also

* {#Hinich} [[Vladimir Hinich]], _Simplicial nerve in Deformation theory_ ([arXiv:0704.2503](http://arxiv.org/abs/0704.2503))

[[!redirects relation between quasi-categories and sSet-enriched categories]]

[[!redirects relation between sSet-enriched categories and quasi-categories]]


+-- {: .rightHandSide}
+-- {: .toc .clickDown tabindex="0"}
### Context
#### Type theory
+-- {: .hide}
[[!include type theory - contents]]
=--
#### Category theory
+-- {: .hide}
[[!include category theory - contents]]
=--
#### Categorical algebra
+-- {: .hide}
[[!include categorical algebra -- contents]]
=--
=--
=--

# Contents
* table of contents
{: toc}

## Idea

[[type theory|Type theory]] and certain kinds of [[category theory]] are closely related.  By a [[syntax-semantics duality]] one may view type theory as a formal [[syntax|syntactic]] language or _calculus_ for category theory, and conversely one may think of category theory as providing [[categorical semantics|semantics]] for type theory.  The flavor of category theory used depends on the flavor of type theory; this also extends to [[homotopy type theory]] and certain kinds of [[(∞,1)-category theory]].

## Overview
 {#Overview}

| internal logic/type theory (syntax) | $\;$equivalent to$\;$ | category of contexts (semantics) | |
|--|--|--|--|
| [[propositional logic]] | | [[Lindenbaum-Tarski algebra]] | |
| [[intuitionistic logic|intuitionistic]] [[propositional logic]] | | [[Heyting algebra]] | |
| [[classical logic|classical]] [[propositional logic]] | | [[Boolean algebra]] | |
| [[dual intuitionistic logic|dual intuitionistic]] [[propositional logic]] | | [[co-Heyting algebra]] | |
| [[first-order logic]] |  | [[hyperdoctrine]] | [Seely 1984a](#SeelyA) |
| [[regular logic]] |  | [[regular hyperdoctrine]]/[[regular category]] | |
| [[coherent logic]] |  | [[coherent hyperdoctrine]]/[[coherent category]] | |
| [[intuitionistic logic|intuitionistic]] [[predicate logic]] |  | [[first-order hyperdoctrine]]/[[Heyting category]] | |
| [[classical logic|classical]] [[predicate logic]] |  | [[Boolean hyperdoctrine]]/[[Boolean category]] | |
| [[modal logic]] |  | [[modal hyperdoctrine]] | |
| [[linear logic]] |  | [[linear hyperdoctrine]] | |
| [[simply-typed lambda calculus]] | | [[cartesian closed category]] | [Lambek & Scott 1986, Part I](#LambekScott86) |
| extensional [[dependent type theory]]|  | [[locally cartesian closed category]] | [Seely 1984b](#Seely84b) |
| [[bunched logic]] | | [[doubly closed monoidal category]] |  [O'Hearn & Pym 1999](bunched+logic#O'HearnPym99) |
| [[homotopy type theory]] without [[univalence]] (intensional M-L dependent type theory) |  | [[locally cartesian closed (∞,1)-category]] | [Cisinski 2012](locally+cartesian+closed+%28infinity%2C1%29-category#Presentations) & [Shulman 2012](#Shulman12) |
| [[homotopy type theory]] with [[higher inductive types]] and [[univalence]] |  | [[elementary (∞,1)-topos]] | see [[homotopytypetheory:model of type theory in an (infinity,1)-topos|here]] |
| [[multiplicative intuitionistic linear logic]] | | [[symmetric monoidal category|symmetric]] [[closed monoidal category]] | [various authors since ~68](linear%20type%20theory#HistoryCategoricalSemantics) |
| [[classical linear logic]] | | [[star-autonomous category ]] | [Seely 1989](#Seely89) |
| [[dependent linear type theory]] |   | [[indexed monoidal category]] (with comprehension)  | [Riley 2022](#Riley22Thesis) |

[[!include types and logic - table]]

## Theorems
 {#Theorems}

We discuss here formalizations and proofs of the relation/equivalence between various flavors of type theories and the corresponding flavors of categories.

* [First order logic and hyperdoctrines](#FirstOrderLogic)

* [Dependent type theory and locally cartesian closed categories](#DependentTypeTheory)

* [Homotopy type theory and locally cartesian closed (∞,1)-categories](#HomotopyTypeTheory)

* [Univalent homotopy type theory and elementary (∞,1)-toposes](#HomotopyWithUnivalence)

### First-order logic and hyperdoctrines
 {#FirstOrderLogic}

+-- {: .num_theorem}
###### Theorem

The [[functors]]

* $Cont$, that form a [[category of contexts]] of a [[first-order logic|first-order theory]];

* $Lang$, that forms the [[internal language]] of a [[hyperdoctrine]]

constitute an [[equivalence of categories]]

$$
  FirstOrderTheories
    \stackrel{\overset{Lang}{\leftarrow}}{\underset{Cont}{\to}}
  Hyperdoctrines
  \,.
$$

=--

([Seely, 1984a](#SeelyA))

### Dependent type theory and locally cartesian closed categories
 {#DependentTypeTheory}

We discuss here how [[dependent type theory]] is the syntax of which [[locally cartesian closed categories]] provide the [[semantics]]. For a dedicated discussion of this (and the subtle [[coherence]] issues involved) see also at _[[categorical model of dependent types]]_.

+-- {: .num_theorem #SeelyEquivalence}
###### Theorem

There are [[2-functors]]

* $Cont$, that forms a [[category of contexts]] of a [[Martin-Löf dependent type theory]];

* $Lang$ that forms the [[internal language]] of a [[locally cartesian closed category]]

that constitute an [[equivalence of 2-categories]]

$$
  MLDependentTypeTheories
    \underoverset
     {\underset{Cont}{\longrightarrow}}
     {\overset{Lang}{\longleftarrow}}
     {\simeq}
  LocallyCartesianClosedCategories
  \,.
$$

=--

This was originally claimed as an [[equivalence of categories]] ([Seely, theorem 6.3](#Seely)). However, that argument did not properly treat a subtlety central to the whole subject: that [[substitution]] of [[terms]] for [[variables]] composes strictly, while its [[categorical semantics]] by [[pullback]] is by the [[universal construction|very nature]] of pullbacks only defined up to [[isomorphism]]. This problem was pointed out and ways to fix it were given in ([Curien](#Curien)) and ([Hofmann](#Hofmann)); see _[[categorical model of dependent types]]_ for the latter.  However, the full equivalence of categories was not recovered until ([Clairambault-Dybjer](#ClairambaultDybjer)) solved both problems by promoting the statement to an [[equivalence of 2-categories]], see also ([Curien-Garner-Hofmann](#CurienGarnerHofmann)). Another approach to this which also works with [[intensional identity types]] and hence with [[homotopy type theory]] is in ([Lumsdaine-Warren 13](#LumsdaineWarren13)).

We now indicate some of the details.

#### Type theories
 {#TypeTheories}

For definiteness, self-containedness and for references below, we say what a [[dependent type theory]] is, following ([Seely, def. 1.1](#Seely)).

+-- {: .num_defn}
###### Definition

A **Martin-Löf [[dependent type theory]]** $T$ is a _[[theory]]_ with some [[signature (in logic)|signature]] of dependent function symbols with values in types and in terms (...) subject to the following rules

1. **type formation rules**

   1. $1$ is a type (the [[unit type]]);

   1. if $a, b$ are terms of type $A$, then $(a = b)$ is a type (the [[equality type]]);

   1. if $A$ and $B[x]$ are types, $B$ depending on a [[free variable]] of type $A$, then the following symbols are types

      1. $\prod_{a : A} B[a]$ ([[dependent product]]), written also $(A \to B)$ if $B[x]$ in fact does not depend on $x$;

      1. $\sum_{a : A} B[a]$ ([[dependent sum]]), written also $A \times B$ if $B[x]$ in fact does not depend on $x$;

1. **term formation rules**

   1. $* \in 1$ is a term of the [[unit type]];

   1. (...)

1. **equality rules**

   1. (...)

=--

#### Category of contexts

+-- {: .num_defn}
###### Definition

Given a [[dependent type theory]] $T$, its **[[category of contexts]]** $Con(T)$ is the category whose

* [[objects]] are the [[types]] of $T$;

* [[morphisms]] $f : A \to B$ are the [[terms]] $f$ of [[function type]] $A \to B$.

Composition is given in the evident way.

=--

+-- {: .num_prop}
###### Proposition

$Con(T)$ has [[finite limits]] and is a [[cartesian closed category]].

=--

([Seely, prop. 3.1](#Seely))

+-- {: .proof}
###### Proof

Constructions are straightforward. We indicated some of them.

Notice that all [[finite limits]] (as discussed there) are induced as soon as there are all [[pullbacks]] and [[equalizers]]. A [[pullback]] in $Con(T)$

$$
  \array{
    P &\to& A
    \\
    \downarrow && \downarrow^{\mathrlap{f}}
    \\
    B &\stackrel{g}{\to}& C
  }
$$

is given by

$$
  P \simeq \sum_{a : A} \sum_{b \in B} (f(a) = g(b))
  \,.
$$

The [[equalizer]]

$$
  P \to A \stackrel{\overset{f}{\to}}{\underset{g}{\to}} B
$$

is given by

$$
  P = \sum_{a : A} (f(a) = g(a))
  \,.
$$

Next, the [[internal hom]]/[[exponential object]] is given by [[function type]]

$$
  [A,B] \simeq (A \to B)
  \,.
$$

=--

+-- {: .num_prop}
###### Proposition

$Con(T)$ is a [[locally cartesian closed category]].

=--

([Seely, theorem 3.2](#Seely))

+-- {: .proof}
###### Proof

Define the $Con(T)$-[[indexed category|indexed]] [[hyperdoctrine]] $P(T)$
by taking for $A \in Con(T)$ the category $P(T)(A)$ to have as objects the $A$-[[dependent types]] and as morphisms $(a : A \vdash X(a) : type) \to (a : A \vdash Y(a) : type)$ the terms of dependent function type $(a : A \vdash t : (X(a) \to Y(a)))$.

This is cartesian closed by the same kind of argument as in the previous proof. It is now sufficient to exhibit a compatible [[equivalence of categories]] with the [[slice category]] $Con(T)_{/A}$.

$$
  Con(T)_{/A}
   \simeq
  P(T)(A)
  \,.
$$

In one direction, send a morphism $f : X \to A$ to the dependent type

$$
  a : A \vdash f^{-1}(a) \coloneqq \sum_{x : X} (a = f(x))
  \,.
$$

Conversely, for $a : A \vdash X(a)$ a dependent type, send it to the projection
$\sum_{a : A} X(a) \to A$.

One shows that this indeed gives an equivalence of categories which is compatible with base change ([Seely, prop. 3.2.4](#Seely)).

=--

+-- {: .num_defn}
###### Definition

For $T$ a dependent type theory and $C$ a locally cartesian closed category, an **[[categorical semantics|interpretation]]** of $T$ in $C$ is a morphism of locally cartesian closed categories

$$
  Con(T) \to C
  \,.
$$

An interpretation of $T$ in another dependent type theory $T'$ is a morphism of locally cartesian closed categories

$$
  Con(T) \to Con(T')
  \,.
$$

=--

#### Internal language

+-- {: .num_prop}
###### Proposition

Given a [[locally cartesian closed category]] $C$, define the corresponding [[dependent type theory]] $Lang(C)$ as follows

* the non-dependent types of $Lang(C)$ are the [[objects]] of $C$;

* the $A$-dependent types are the morphisms $B \to A$;

* a context $x_1 : X_1 , x_2 : X_2, \cdots , x_n : X_n$ is a tower of morphisms

  $$
    \array{
      X_n
      \\
      \downarrow
      \\
      \cdots
      \\
      \downarrow
      \\
      X_2
      \\
      \downarrow
      \\
      X_1
    }
  $$

* the terms $t[x_A] : B[x_A]$ are the [[sections]] $A \to B$ in $C_{/A}$

* the [[equality type]] $(x_A = y_A)$ is the [[diagonal]] $A \to A \times A$

* ...

=--

### Homotopy type theory and locally cartesian closed $(\infty,1)$-categories
 {#HomotopyTypeTheory}

All of the above has an analog in [[(∞,1)-category theory]] and [[homotopy type theory]].

+-- {: .num_prop }
###### Proposition

Every [[presentable (∞,1)-category|presentable]] and [[locally cartesian closed (∞,1)-category]] has a presentation by a [[type-theoretic model category]]. This provides the [[categorical semantics]] for [[homotopy type theory]] (without, possibly, the [[univalence]] [[axiom]]).

This includes in particular all ([[∞-stack]]-) [[(∞,1)-toposes]] (which should in addition satisfy [[univalence]]). See also at _[[internal logic of an (∞,1)-topos]]_.

=--

Some form of this statement was originally formally conjectured in ([Joyal 11](Joyal11)), following ([Awodey 10](#Awodey10)). For more details see at _[locally cartesian closed (∞,1)-category](locally+cartesian+closed+%28infinity%2C1%29-category#InternalLogic)_.

### Univalent homotopy type theory and elementary $(\infty,1)$-toposes
 {#HomotopyWithUnivalence}

> More precise information can be found on the [homotopytypetheory wiki](http://ncatlab.org/homotopytypetheory/show/model+of+type+theory+in+an+%28infinity%2C1%29-topos).

A ([[locally presentable (∞,1)-category|locally presentable]]) [[locally Cartesian closed (∞,1)-category]] (as [above](#HomotopyTypeTheory)) which in addition has a system of [[object classifiers]] is an ([[(∞,1)-category of (∞,1)-sheaves|(∞,1)-sheaf]]-)[[(∞,1)-topos]].

It has been conjectured in ([Awodey 10](#Awodey10)) that this [[object classifier]] is the categorical semantics of a [[univalence|univalent]] [[type universe]] ([[type of types]]), hence that [[homotopy type theory]] with [[univalence]] has categorical semantics in [[(∞,1)-toposes]].  This statement was proven for the canonical $(\infty,1)$-topos [[∞Grpd]] in ([Kapulkin-Lumsdaine-Voevodsky 12](#KapulkinLumsdaineVoevodsky12)), and more generally for [[(∞,1)-presheaf]] $(\infty,1)$-toposes over [[elegant Reedy categories]] in ([Shulman 13](#Shulman13)). The general case is proven in [Shulman 19](#Shulman19).

In these proofs the [[type-theoretic model categories]] which interpret the homotopy type theory syntax are required to provide type universes that behave strictly under pullback.  This matches the usual syntactically convenient universes in type theory (either a la Russell or a la Tarski), but more difficult to implement in the categorical semantics.  More flexibly, one may consider syntactic [type universes weakly à la Tarski](type+of+types#TarskiStyle) ([Luo 12](Luo12), [Gallozzi 14](#Gallozzi14)).  These are more complicated to work with syntactically, but should have interpretations in a ([[type-theoretic model categories]] presenting) any [[(∞,1)-topos]].  Discussion of [[univalence]] in this general flexible sense is in ([Gepner-Kock 12](#GepnerKock12)). For the general syntactic issue see at

* [[homotopytypetheory:model of type theory in an (infinity,1)-topos]]

While [[(∞,1)-sheaf]] [[(∞,1)-toposes]] are those currently understood, the basic type theory with univalent universes does not see or care about their [[locally presentable (∞,1)-category|local presentability]] as such (although it is used in other places, such as the construction of [[higher inductive types]]).  It is to be expected that there is a decent concept of [[elementary (∞,1)-topos]] such that [[homotopy type theory]] with [[univalence|univalent]] [[type universes]] and some supply of [[higher inductive types]] has categorical semantics precisely in [[elementary (∞,1)-toposes]] (as conjectured in [Awodey 10](#Awodey10)). But the fine-tuning of this statement is currently still under investigation.

Notice that this statement, once realized, makes (or would make) Univalent HoTT+HITs a sort of [[homotopy theory|homotopy theoretic]] refinement of [[foundations of mathematics]] in [[topos theory]] as proposed by [[William Lawvere]].  It could be compared to his [[elementary theory of the category of sets]], although being a type theory rather than a theory in first-order logic, it is more analogous to the internal type theory of an elementary topos.

## Related concepts

* [[initiality conjecture]]

* [[categorical model of dependent types]]

* [[syntax-semantics duality]]

* [[computational trinitarianism]]

* [[Awodey's conjecture]]

## References
 {#References}

An elementary exposition of in terms of the [[Haskell]] [[programming language]] is in

* WikiBooks, _[Haskell/The Curry–Howard isomorphism](https://en.wikibooks.org/wiki/Haskell/The_Curry%E2%80%93Howard_isomorphism)_

The [[equivalence of categories]] between [[first order logic|first order theories]] and [[hyperdoctrines]] is discussed in

* {#SeelyA} [[R. A. G. Seely]], _Hyperdoctrines, natural deduction, and the Beck condition_, Zeitschrift für Math. Logik und Grundlagen der Math. (1984) ([pdf](http://www.math.mcgill.ca/rags/ZML/ZML.PDF))

The [[categorical model of dependent types]] and initiality is discussed in

* Simon Castellan, _Dependent type theory as the initial category with families_, 2014 ([pdf](http://iso.mor.phis.me/archives/2011-2012/stage-2012-goteburg/report.pdf))

which was formalized inside type theory with set quotients of [[higher inductive types]] in:

* {#AltKap2015} [[Thorsten Altenkirch]], Ambrus Kaposi, _Type Theory in Type Theory using Quotient Inductive Types_, (2015) ([pdf](http://www.cs.nott.ac.uk/~txa/publ/tt-in-tt.pdf)), ([formalisation in Agda](https://bitbucket.org/akaposi/tt-in-tt)).

Surveys inclue

* [[Tom Hirschowitz]], _Introduction to categorical logic_ (2010) ([pdf](http://www.lama.univ-savoie.fr/~hirschowitz/talks/cours.pdf))

  (see the discussion building up to the theorem on  [slide 96](http://www.lama.univ-savoie.fr/~hirschowitz/talks/cours.pdf#page=96))

* Roy Crole, _Deriving category theory from type theory_, Theory and Formal Methods 1993 Workshops in Computing 1993, pp 15-26

* {#Maietti05} [[Maria Maietti]], _Modular correspondence between dependent type theories and categories including pretopoi and topoi_, Mathematical Structures in Computer Science archive Volume 15 Issue 6, December 2005  Pages 1089 - 1149 ([pdf](https://www.math.unipd.it/~maietti/papers/tumscs.pdf))

The [[categorical semantics]] of [[linear logic]] in [[star-autonomous categories]] is due to

* {#Seely89} [[R. A. G. Seely]],  *Linear logic, $\ast$-autonomous categories and cofree coalgebras*, in *Categories in Computer Science and Logic*, Contemporary Mathematics **92** (1989)  [[[SeelyLinearLogic.pdf:file]], [ps.gz](http://www.math.mcgill.ca/rags/nets/llsac.ps.gz), [ISBN:978-0-8218-5100-5](https://bookstore.ams.org/conm-92)]

and reviews/further developments are in

* G. M. Bierman, _What is a Categorical Model of Intuitionistic Linear Logic?_ ([web](http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.31.8687))

* Andrew Graham Barber, _Linear Type Theories, Semantics and Action Calculi_, 1997 ([web](http://www.lfcs.inf.ed.ac.uk/reports/97/ECS-LFCS-97-371/), [pdf](http://www.lfcs.inf.ed.ac.uk/reports/97/ECS-LFCS-97-371/ECS-LFCS-97-371.pdf))

* [[Paul-André Melliès]] , _Categorial Semantics of Linear Logic_, in _Interactive models of computation and program behaviour_, Panoramas et synthèses 27, 2009 ([pdf](http://www.pps.univ-paris-diderot.fr/~mellies/papers/panorama.pdf))

For [[dependent linear type theory]] see:

* {#Vakar14} [[Matthijs Vákár]], _Syntax and Semantics of Linear Dependent Types_ [[arXiv:1405.0033](http://arxiv.org/abs/1405.0033)]

* {#RileyFinsterLicata21} [[Mitchell Riley]], [[Eric Finster]], [[Daniel Licata]], *Synthetic Spectra via a Monadic and Comonadic Modality* [[arXiv:2102.04099](https://arxiv.org/abs/2102.04099)]

* [[Mitchell Riley]], *Extending Homotopy Type Theory with Linear Type Formers*, talk at *The ForML Lab* (2021)  [[web](https://the-au-forml-lab.github.io/colloquium_talks/Riley.html), [video](https://www.youtube.com/watch?v=sPxtdCtjSDc)]

* {#Riley22Thesis} [[Mitchell Riley]], *A Bunched Homotopy Type Theory for Synthetic Stable Homotopy Theory*, PhD Thesis (2022) [[doi:10.14418/wes01.3.139](https://doi.org/10.14418/wes01.3.139), [ir:3269](https://digitalcollections.wesleyan.edu/object/ir%3A3269), [pdf](https://mvr.hosting.nyu.edu/pubs/thesis.pdf)]

  > (using ideas from [[bunched logic]])

* {#Riley22} [[Mitchell Riley]], *Linear Homotopy Type Theory*, talk at: [HoTTEST Event for Junior Researchers 2022](https://www.uwo.ca/math/faculty/kapulkin/seminars/hottest_junior_2022.html)  (Jan 2022) [slides: [pdf](https://www.uwo.ca/math/faculty/kapulkin/seminars/hottestfiles/Riley-2022-01-20-HoTTEST.pdf), video: [YT](https://www.youtube.com/watch?v=o2oWhHabjdM)]

The relation between [[typed lambda-calculus]] and [[cartesian closed categories]] is discussed in part I, and the [[adjunction]] between the category of [[type theory|type theories]] with [[product types]] and [[toposes]] is discussed in chapter II of:

* {#LambekScott86} [[Joachim Lambek]], [[Philip J. Scott]], *Introduction to higher order categorical logic*, Cambridge Studies in Advanced Mathematics **7** (1986) [[ISBN: 0-521-24665-2](https://www.cambridge.org/ae/academic/subjects/mathematics/logic-categories-and-sets/introduction-higher-order-categorical-logic?format=PB&isbn=9780521356534), [pdf](https://raw.githubusercontent.com/Mzk-Levi/texts/master/Lambek%20J.%2C%20Scott%20P.J.%20Introduction%20to%20Higher%20Order%20Categorical%20Logic.pdf)]

The [[equivalence of categories]] between [[locally cartesian closed categories]] and [[dependent type theories]] was originally claimed in

* {#Seely84b} [[R. A. G. Seely]], _Locally cartesian closed categories and type theory_, Math. Proc. Camb. Phil. Soc. **95** (1984) 33-48  [[doi:10.1017/S0305004100061284](https://doi.org/10.1017/S0305004100061284), [pdf](http://www.math.mcgill.ca/rags/LCCC/LCCC.pdf)]

following a statement earlier conjectured in

* [[Per Martin-Löf]], _An intuitionistic theory of types: predicative part_, In Logic Colloquium (1973), ed. H. E. Rose and J. C. Shepherdson (North-Holland, 1974), 73-118. ([web](http://citeseerx.ist.psu.edu/viewdoc/summary?doi=10.1.1.131.926))

The problem with strict substitution compared to weak pullback in this argument was discussed and fixed in

* {#Curien} [[Pierre-Louis Curien]], *Substitution up to isomorphism*, Fundamenta Informaticae, **19** 1-2 (1993) 51-86 [[doi:10.5555/175469.175471](https://dl.acm.org/doi/10.5555/175469.175471)] and: Diagrammes **23** (1990) 43-66 [[numdam:DIA_1990__23__43_0](http://www.numdam.org/item/DIA_1990__23__43_0)]

* {#Hofmann} [[Martin Hofmann]], *On the interpretation of type theory in locally cartesian closed categories*, in *Computer Science Logic. CSL 1994*, Lecture Notes in Computer Science **933** (1994) 427–441 [[doi:10.1007/BFb0022273](https://doi.org/10.1007/BFb0022273)]

but in the process the equivalence of categories was lost. This was finally all rectified in

* {#ClairambaultDybjer} [[Pierre Clairambault]], [[Peter Dybjer]], *The Biequivalence of Locally Cartesian Closed Categories and Martin-Löf Type Theories*, in *Typed lambda calculi and applications*, Lecture Notes in Comput. Sci. **6690** Springer (2011) [[arXiv:1112.3456](http://arxiv.org/abs/1112.3456), [doi:10.1007/978-3-642-21691-6_10](https://doi.org/10.1007/978-3-642-21691-6_10)]

and

* {#CurienGarnerHofmann} [[Pierre-Louis Curien]], [[Richard Garner]], [[Martin Hofmann]], *Revisiting the categorical interpretation of dependent type theory*, Theoretical Computer Science **546** 21 (2014) 99-119 [[doi:10.1016/j.tcs.2014.03.003](https://doi.org/10.1016/j.tcs.2014.03.003), [[CurienGarnerHofmann.pdf:file]]]

Another version of this which also applies to [[intensional identity types]] and hence to [[homotopy type theory]] is in

* {#LumsdaineWarren13} [[Peter LeFanu Lumsdaine]], [[Michael Warren]], _An overlooked coherence construction for dependent type theory_, CT2013 ([[LumsdaineWarren2013.pdf:file]])

* [[Peter LeFanu Lumsdaine]], [[Michael Warren]], _The local universes model: an overlooked coherence construction for dependent type theories_ ([arXiv:1411.1736](http://arxiv.org/abs/1411.1736))

The analogous statement relating [[homotopy type theory]] and [[locally cartesian closed (infinity,1)-categories]] was formally conjectured around

* {#Joyal} [[André Joyal]], _Remarks on homotopical logic_, Oberwolfach (2011) ([pdf](http://hottheory.files.wordpress.com/2011/06/report-11_2011.pdf#page=19))

following earlier suggestions by [[Steve Awodey]]. Explicitly, the suggestion that with the [[univalence]] axiom added this is refined to [[(∞,1)-topos theory]] appears around

* {#Awodey} [[Steve Awodey]], _Type theory and homotopy_ ([pdf](http://www.andrew.cmu.edu/user/awodey/preprints/TTH.pdf))

Details on this higher categorical semantics of [[homotopy type theory]] are in

* {#Shulman12} [[Michael Shulman]], _Univalence for inverse diagrams and homotopy canonicity_, Mathematical Structures in Computer Science, Volume 25, Issue 5 ( _From type theory and homotopy theory to Univalent Foundations of Mathematics_ ) June 2015 ([arXiv:1203.3253](https://arxiv.org/abs/1203.3253), [doi:/10.1017/S0960129514000565](https://doi.org/10.1017/S0960129514000565))

with lecture notes in

* [[Mike Shulman]], _Categorical models of homotopy type theory_, April 13, 2012 ([pdf](https://home.sandiego.edu/~shulman/hottminicourse2012/03models.pdf))

* {#Joyal11} [[André Joyal]], _Remarks on homotopical logic_, Oberwolfach (2011) ([pdf](http://hottheory.files.wordpress.com/2011/06/report-11_2011.pdf#page=19))

* {#Joyal14} [[André Joyal]], _Categorical homotopy type theory_, March 17, 2014 ([pdf](http://ncatlab.org/homotopytypetheory/files/Joyal.pdf))

See also

* {#Kapulkin14} [[Chris Kapulkin]], _Type theory and locally cartesian closed quasicategories_, Oxford 2014 ([video](https://www.youtube.com/watch?v=g87bZJ2bvYk))

* [[Chris Kapulkin]], [[Peter LeFanu Lumsdaine]], _The homotopy theory of type theories_, Advances in Mathematics **337** (2018) 1-38 ([arXiv:1610.00037](https://arxiv.org/abs/1610.00037), [doi:10.1016/j.aim.2018.08.003](https://doi.org/10.1016/j.aim.2018.08.003))

* {#KapulkinSzumilo17} [[Chris Kapulkin]], [[Karol Szumilo]], _Internal Language of Finitely Complete $(\infty,1)$-categories_ ([arXiv:1709.09519](https://arxiv.org/abs/1709.09519))

* {#Isaev16} [[Valery Isaev]], _Algebraic Presentations of Dependent Type Theories_ ([arXiv:1602.08504](https://arxiv.org/abs/1602.08504))

* {#Isaev18} [[Valery Isaev]], _Morita equivalences between algebraic dependent type theories_ ([arXiv:1804.05045](https://arxiv.org/abs/1804.05045))

Models specifically in ([[constructive set theory|constructive]]) [[cubical sets]] are discussed in

* {#BezemCoquandHuber13} Marc Bezem, [[Thierry Coquand]], Simon Huber, _A model of type theory in cubical sets_, 2013  ([web](http://drops.dagstuhl.de/opus/volltexte/2014/4628/), [pdf](http://drops.dagstuhl.de/opus/volltexte/2014/4628/pdf/7.pdf))

* {#KaposiAltenkirch14} Ambrus Kaposi, [[Thorsten Altenkirch]], _A syntax for cubical type theory_ ([pdf](http://mazzo.li/dump/aim-kaposi-pres.pdf))

* {#Docherty14} Simon Docherty, _A model of type theory in cubical sets with connection_, 2014 ([pdf](http://www.illc.uva.nl/Research/Publications/Reports/MoL-2014-12.text.pdf))

A precise definition of [[elementary (infinity,1)-topos]] inspired by giving a natural equivalence to [[homotopy type theory]] with [[univalence]] was then proposed in

* [[Mike Shulman]], _Inductive and higher inductive types_ (2012) ([pdf](http://www.sandiego.edu/~shulman/hottminicourse2012/04induction.pdf))

Categorical semantics of [[univalence|univalent]] [[type universes]] is discussed in

* {#Awodey10} [[Steve Awodey]], _Type theory and homotopy_ (2010) ([pdf](http://www.andrew.cmu.edu/user/awodey/preprints/TTH.pdf))

* {#KapulkinLumsdaineVoevodsky12} [[Chris Kapulkin]], [[Peter LeFanu Lumsdaine]], [[Vladimir Voevodsky]], _The Simplicial Model of Univalent Foundations_ ([arXiv:1211.2851](http://arxiv.org/abs/1211.2851))

* {#Shulman13} [[Michael Shulman]], _The univalence axiom for elegant Reedy presheaves_ ([arXiv:1307.6248](http://arxiv.org/abs/1307.6248))

* {#GepnerKock12} [[David Gepner]], [[Joachim Kock]], _Univalence in locally cartesian closed ∞-categories_ ([arXiv:1208.1749](http://arxiv.org/abs/1208.1749))

* {#Cisinski14} [[Denis-Charles Cisinski]], _Univalent universes for elegant models of homotopy types_ ([arXiv:1406.0058](http://arxiv.org/abs/1406.0058))

Proof of [[Awodey's conjecture]], that all [[∞-stack]] [[(∞,1)-topos]] have [[presentable (∞,1)-category|presentations]] by [[model categories]] which interpret (provide [[categorical semantics]]) for [[homotopy type theory]] with [[univalence|univalent]] [[type universes]]:

* {#Shulman19} [[Michael Shulman]], _All $(\infty,1)$-toposes have strict univalent universes_ ([arXiv:1904.07004](https://arxiv.org/abs/1904.07004)).

Introduction and review in:

* {#Riehl22} [[Emily Riehl]], *On the $\infty$-topos semantics of homotopy type theory*, lecture at *[Logic and higher structures](https://conferences.cirm-math.fr/2689.html)* CIRM (Feb. 2022) [[pdf](https://emilyriehl.github.io/files/semantics.pdf), [[Riehl-InfinityToposSemantics.pdf:file]]]

Discussion of weak Tarskian homotopy type universes is in

* {#Luo12} [[Zhaohui Luo]], _Notes on Universes in Type Theory_, 2012 ([pdf](http://www.cs.rhul.ac.uk/home/zhaohui/universes.pdf))

* {#Gallozzi14} [[Cesare Gallozzi]], _Constructive Set Theory from a Weak Tarski Universe_, MSc thesis (2014) ([[GalloziCSTTarski.pdf:file]])

A discussion of the correspondence between type theories and categories of various sorts, from lex categories to toposes is in

* Maria Emilia Maietti, _Modular correspondence between dependent type
theories and categories including pretopoi and topoi_, Math. Struct. in Comp. Science (2005), vol. 15, pp. 1089–1149 ([gzipped ps](http://www.math.unipd.it/~maietti/papers/tumscs.ps.gz)) ([doi](http://dx.doi.org/10.1017/S0960129505004962))

[[!redirects relation between category theory and type theory]]
[[!redirects the relation between type theory and category theory]]
[[!redirects the relation between category theory and type theory]]


relation theory > history

< [[relation theory]]


relational beta-module

+-- {: .rightHandSide}
+-- {: .toc .clickDown tabindex="0"}
### Context
#### Topology
+-- {: .hide}
[[!include topology - contents]]
=--
=--
=--

# Relational $\beta$-modules
* table of contents
{: toc}

## Idea

>One of my early Honours students at [[Macquarie University]] baffled his proposed Queensland graduate studies supervisor who asked whether the student knew the definition of a [[topological space]]. The aspiring researcher on [[dynamical system|dynamical systems]] answered positively: "Yes, it is a relational $\beta$-module!"  I received quite a bit of flak from colleagues concerning that one; but the student [[Peter Kloeden]] went on to become a full professor of mathematics in Australia then Germany.
---[[Ross Street]], in _[[An Australian conspectus of higher categories]]_

In [1970](#Barr), [[Michael Barr]] gave an abstract definition of [[topological space]] based on a notion of [[convergence]] of [[ultrafilters]] (building on work by [[Ernest Manes]] on [[compact Hausdorff spaces]]).  Succinctly, Barr defined topological spaces as 'relational $\beta$-modules'.  It was subsequently realized that this was a special case of the notion of [[generalized multicategory]].  Here we unpack this definition and examine its properties.

The correctness of this definition (in the sense of matching [[Bourbaki]]\'s definition) is equivalent to the [[ultrafilter principle]] ($UP$).  However, the definition can be treated on its own, even in a context without $UP$.  So we also consider the properties of relational $\beta$-modules when these might not match Bourbaki's [[open set]] definition of [[topological spaces]].

## Definitions

### Abstract description {#abstract}

If $S$ is a [[set]], let $\beta{S}$ be the set of [[ultrafilters]] on $S$. This set is canonically identified with the set of Boolean algebra homomorphisms

$$P(S) \to \mathbf{2},$$

from the power set of $S$ to $\mathbf{2}$, the unique Boolean algebra with two elements. The 2-element set carries a [[dualizing object]] structure that induces an evident [[adjoint pair]]

$$(Set \stackrel{P}{\to} Bool^{op}) \; \dashv \;  (Bool^{op} \stackrel{\hom(-, \mathbf{2})}{\to} Set)$$

so that the composite [[functor]] $\beta = \hom(P-, \mathbf{2}): Set \to Set$ carries a [[monad]] structure.

The functor $\beta : Set \to Set$ extends to [[Rel]] as follows: given a [[binary relation]] $r\colon X \to Y$, written as a subobject in $Set$

$$R \stackrel{\langle \pi_1, \pi_2 \rangle}{\to} X \times Y,$$

we define $\beta(r): \beta(X) \to \beta(Y)$ to be the relation obtained by taking the image of $\langle \beta(\pi_1), \beta(\pi_2) \rangle: \beta(R) \to \beta(X) \times \beta(Y)$. It turns out, although it is by no means obvious, that $\beta$ is according to this definition a _strict_ functor on $Rel$.

The monad structure on $\beta: Set \to Set$, given by a unit $u: 1 \to \beta$ and multiplication $m: \beta \beta \to \beta$, extends not to a strict monad on $Rel$, but rather one where the transformations $u, m$ are [[lax natural transformation|op-lax]] in the sense of there being inequalities

$$\array{
X & \stackrel{u_X}{\to} & \beta X & & & & & & \beta \beta X & \stackrel{m_X}{\to} & \beta X \\
\mathllap{r} \downarrow & \leq & \downarrow \mathrlap{\beta(r)} & & & & & & \mathllap{\beta \beta (r)} \downarrow & \leq & \downarrow \mathrlap{\beta(r)} \\
Y & \underset{u_Y}{\to} & \beta Y & & & & & & \beta \beta Y & \underset{m_Y}{\to} & \beta Y
}$$

(while of course the monad associativity and unit conditions remain as equations: hold on the nose).

Then a __relational $\beta$-module__ is a [[lax algebra]] (module) of $\beta$ on the [[2-poset]] $Rel$. In other words, a set $S$ equipped with a relation $\xi: \beta S \to S$ such that the following inequalities hold:

$$\label{rel1} \array{
S & \stackrel{u_S}{\to} & \beta S & & & & & & \beta \beta S & \stackrel{m_S}{\to} & \beta S \\
 & \mathllap{1_S} \searrow \; \leq & \downarrow \mathrlap{\xi} & & & & & & \mathllap{\beta(\xi)} \downarrow & \leq & \downarrow \mathrlap{\xi} \\
 & & S & & & & & & \beta S & \underset{\xi}{\to} & S
}$$

Arguably, it is better to consider $Rel$ as a [[proarrow equipment]] in this construction, in order to accommodate [[continuous functions]] between topological spaces (not continuous relations!) as the appropriate abstract notion of morphism between relational $\beta$-modules.  We touch on this below, but for a much wider context, see [[generalized multicategory]].

### Bridge to a concrete description

A __relational $\beta$-module__ is a [[set]] $S$ and a [[binary relation]] $\xi: \beta S \to S$ between [[ultrafilters]] on $S$ and [[elements]] of $S$ that satisfy the conditions (eq:rel1) . For $F \in \beta S$ and $x \in S$, we write $F \rightsquigarrow_\xi x$ if $(F, x)$ satisfies the relation $\xi$, or often just $F \rightsquigarrow x$ if the relation is clear. We pronounce this by saying "the ultrafilter $F$ _converges_ to the point $x$", so that $\xi$ plays the role of "notion of convergence".

Preliminary to explaining the conditions (eq:rel1), we first set up a [[Galois connection]] between $\xi \in Rel(\beta S, S)$ and subsets $\mathcal{C} \in P P(S)$, so that fixed points on the $P P(S)$ side are exactly topologies on $S$, and fixed points on the other side are (as we show below) lax $\beta$-module structures on $S$. The Galois connection would then of course restrict to a Galois correspondence between topologies and lax module structures.

Recall that each topology $\mathcal{O} \subseteq P(S)$ induces a notion of convergence where $F \rightsquigarrow x$ means $N_x \subseteq F$ ($F$ contains the filter of neighborhoods of $x$). Accordingly, for general $\mathcal{C} \subseteq P(S)$, define the relation $conv(\mathcal{C}) = \xi: \beta S \to S$ by

$$F \rightsquigarrow_\xi x \;\;\; \Leftrightarrow \;\;\; (\forall_{U: P(S)})\; U \in \mathcal{C} \; \wedge \; x \in U \; \Rightarrow \; U \in F.$$

Conversely, a topology $\mathcal{O}$ can be retrieved from its notion of convergence: under the ultrafilter principle, the neighborhood filter of a point $x$ is just the intersection of all ultrafilters containing it (hence all $F$ such that $F \rightsquigarrow x$), and then a set is open if it is a neighborhood of all of its elements. Accordingly, for general "notions of convergence" $\xi \in Rel(\beta S, S)$, we define a collection $\tau(\xi) \subseteq P(S)$ by

$$\tau(\xi) \coloneqq \{U \subseteq S: \; (\forall_{F: \beta S, x: S})\; (x \in U \; \wedge\; F \rightsquigarrow_\xi x) \Rightarrow U \in F\}.$$

+-- {: .num_prop #topo}
###### Proposition
$\tau(\xi)$ is a topology on $S$, for any $\xi: Rel(\beta S, S)$.
=--

+-- {: .proof}
###### Proof
It is trivial that $S \in \tau(\xi)$. If $U, V \in \tau(\xi)$, and if $x \in U \cap V$ and $F \rightsquigarrow x$, then also $x \in U$ and $x \in V$ and we conclude $U, V \in F$, whence $U \cap V \in F$ since $F$ is an ultrafilter, so that $U \cap V$ satisfies the condition of belonging to $\tau(\xi)$. Given a collection of elements $U_i \in \tau(\xi)$, if $x \in \cup_i U_i$ and $F \rightsquigarrow x$, then $x \in U_i$ for some $i$ and we conclude $U_i \in F$, whence $\cup_i U_i \in F$ since $F$ is upward closed. Therefore $\cup_i U_i$ satisfies the condition of belonging to $\tau(\xi)$ (vacuously so if the collection is empty).
=--

+-- {: .num_prop #galois}
###### Proposition
There is a Galois connection between notions of convergence on $S$ and subsets of $P(S)$, according to the bi-implication

$$\mathcal{C} \subseteq \tau(\xi) \; \Leftrightarrow \; \xi \subseteq conv(\mathcal{C}).$$

=--

+-- {: .proof}
###### Proof
To establish the bi-implication, it suffices to observe that both containments $\mathcal{C} \subseteq \tau(\xi)$ and $\xi \subseteq conv(\mathcal{C})$ are equivalent to the condition

$$\forall_{F: \beta S} \forall_{U: P S} \forall_{x: S} (F \rightsquigarrow_\xi x) \; \wedge \; (U \in \mathcal{C}) \; \wedge \; (x \in U) \; \; \Rightarrow \; \; (U \in F).$$
=--

+-- {: .num_prop #fix}
###### Proposition
If $\mathcal{O}$ is a topology on $S$, then $\mathcal{O} = \tau(conv(\mathcal{O}))$ (i.e., topologies are fixed points of the [[closure operator]] $\tau \circ \conv$).
=--

+-- {: .proof}
###### Proof
We already have $\mathcal{O} \subseteq \tau(conv(\mathcal{O}))$ from Proposition \ref{galois}. For the other direction, we must show that any $V$ belonging to $\tau(conv(\mathcal{O}))$ is an $\mathcal{O}$-neighborhood of each of its points. Suppose the contrary: that $x \in V$ but $V$ is not an $\mathcal{O}$-neighborhood of $x$. Holding $V$ fixed, for every $\mathcal{O}$-neighborhood $U \in N_x$ we have $U \cap \neg V \neq \emptyset$, so that sets of the form $U \cap \neg V$ with $U$ ranging over $N_x$ generate a filter. By the ultrafilter principle, we may extend this filter to an ultrafilter $F$; clearly we have $F \rightsquigarrow x$ and $\neg V \in F$, but since $F \rightsquigarrow x$ and $V \in \tau(conv(\mathcal{O}))$ and $x \in V$, we also have $V \in F$, which is inconsistent with $\neg V \in F$.
=--

Propositions \ref{topo}, \ref{galois}, and \ref{fix} more or less show that a topological space $(S, \mathcal{O})$ is a particular type of [[pseudotopological space]]:

+-- {: .num_defn}
###### Definition
A pseudotopological space is set $S$ equipped with a relation $\xi: \beta S \to S$ such that $1_S \leq \xi \circ u_S$.
=--

All that remains is to check is:

+-- {: .num_prop #pseudo}
###### Proposition
The lax unit condition $1_S \leq \xi \circ u_S$ holds if $\xi = conv(\mathcal{O})$, for a topology $\mathcal{O}$.
=--

The unit $u_S: S \to \beta S$ may also be denoted $prin_S$, as it takes an element $x \in S$ to the principal ultrafilter

$$prin_S(x) = \{U \subseteq S: x \in U\}$$

and now the unit condition says $prin_S(x) \rightsquigarrow_\xi x$ for all $x$. For $\xi = conv(\mathcal{O})$, this says $N_x \subseteq prin_S(x)$, or that $x \in V$ for all neighborhoods $V \in N_x$, which is a tautology.

One of our goals is to prove the following theorem:

+-- {: .num_theorem #conc}
###### Theorem
**(Main Theorem)**
An arrow $\xi: \beta(S) \to S$ in $Rel$ is of the form $conv(\tau(\xi))$ if and only if the following inequalities are satisfied:

$$1_S \leq \xi \circ prin_S, \qquad \xi \circ \beta(\xi) \leq \xi \circ m_S$$

where $m_S: \beta \beta(S) \to \beta(S)$ is the multiplication on the ultrafilter monad.
=--

## Ultrafilter monad on $Rel$ {#functor}

Before rolling up our sleeves and proving the main theorem, we pause to consider some more abstract contexts in which to place the concept of lax $\beta$-module, leading up to the context of generalized multicategories.

### Extending the ultrafilter functor to $Rel$

First we examine more closely the extension of the ultrafilter functor $\beta: Set \to Set$ to $Rel$, showing in particular that the extension is a strict functor. First we slightly rephrase our earlier definition:

+-- {: .num_defn}
###### Definition
For a relation $r: X \to Y$ between sets, given by a subobject $R \hookrightarrow X \times Y$ in $Set$ with projections $f: R \to X$ and $g: R \to Y$, define $\bar{\beta}(r)$ to be the composite

$$\beta(X) \stackrel{\beta(f)^{o}}{\to} \beta(R) \stackrel{\beta(g)}{\to} \beta(Y)$$

in the bicategory of relations.
=--

Any span of functions $(h: S \to X, k: S \to Y)$ that represents $r$ (in the sense that $r = k h^{o}$ in the bicategory of relations) would serve in place of $(f, g)$, since for any such span there is an epi $s: S \to R$ with $h = f s$, $k = g s$, whence $\beta(s)$ is epi (because the epi $s$ splits in $Set$) and we have

$$\array{
\beta(g)\beta(f)^{o} & = & \beta(g)\beta(s)\beta(s)^{o}\beta(f)^{o} \\
 & = & \beta(g)\beta(s)(\beta(f)\beta(s))^{o} \\
 & = & \beta(g s)\beta(f s)^{o} \\
 & = & \beta(k)\beta(h)^{o}.
}$$

In particular, $\bar{\beta}$ is well-defined. Since $\bar{\beta}$ extends $\beta: Set \to Set$, there is no harm in writing $\beta(r)$ in place of $\bar{\beta}(r)$. If $r \leq r': X \to Y$, then $\beta(r) \leq \beta(r')$ (as can be seen from the calculation displayed above, but replacing the epi $s$ by a general map $t$, and the first equation by an inequality $\geq$).

+-- {: .num_remark #oplax}
###### Remark
The same recipe works to extend any functor $T: Set \to Set$ to $Rel$, and the extension $\bar{T}: Rel \to Rel$ is always an _op-lax_ functor in the sense that

$$\bar{T}(r s) \leq \bar{T}(r) \bar{T}(s)$$

as is easily seen by contemplating a pullback diagram (where $r = g f^{o}$ and $s = k h^{o}$):

$$\array{
 & & & & Q & & & & \\
 & & & \mathllap{p} \swarrow & & \searrow \mathrlap{q} & & & \\
 & & R & & & & S & & \\
 & \mathllap{f} \swarrow & & \searrow \mathrlap{g} & & \mathllap{h} \swarrow & & \searrow \mathrlap{k} & \\
X & & & & Y & & & & Z
}$$

whereupon one calculates

$$\array{
\bar{T}(r s) & = & T(k q) T(f p)^{o} \\
 & = & T(k) T(q) T(p)^{o} T(f)^{o} \\
 & \leq & T(k) T(h)^{o} T(g) T(f)^{o} \\
 & = & \bar{T}(r) \bar{T}(s)
}$$

where the inequality comes from $T(q) T(p)^{o} \leq T(h)^{o} T(g)$, which is equivalent to $T(h) T(q) \leq T(g) T(p)$ (where even equality holds). This calculation shows that $\bar{T}$ is an actual (not just an op-lax) functor on $Rel$ iff $T$ satisfies the **Beck-Chevalley** condition: if $(p, q)$ is a pullback of $(g, h)$, then

$$T(q) T(p)^{o} = T(h)^{o} T(g).$$

This in turn amounts to $T$ preserving weak pullbacks. (It actually says $T$ takes pullbacks to weak pullbacks, but this implies $T$ takes weak pullbacks to weak pullbacks because any endofunctor $T$ on $Set$ preserves epis, using the axiom of choice.)
=--

+-- {: .num_prop #BC}
###### Proposition
The functor $\beta: Set \to Set$ satisfies the Beck-Chevalley condition (and therefore the extension $\beta: Rel \to Rel$ is a strict functor).
=--

+-- {: .proof}
###### Proof
Referring to the pullback diagram in Remark \ref{oplax}, let $Q = R \times_Y S$ be the pullback. We must show that the canonical map

$$\beta(R \times_Y S) \to \beta(R) \times_{\beta(Y)} \beta(S)$$

is epic. Viewing this as a continuous map between compact Hausdorff spaces (see [this section](http://ncatlab.org/nlab/show/compactum#ultrafilters_form_a_compactum_23) of the article on [[compacta]]), it suffices to show that the canonical map

$$R \times_Y S \to \beta(R) \times_{\beta(Y)} \beta(S)$$

has a dense image. Let $(G, H) \in \beta(R) \times_{\beta(Y)} \beta(S)$, so that $\beta(g)(G) = \beta(h)(H)$ are the same ultrafilter $J \in \beta(Y)$. Let $\hat{A}$ and $\hat{B}$ be [basic open neighborhoods](http://ncatlab.org/nlab/show/compactum#the_space_of_ultrafilters_19) of $G$ and $H$ in $\beta(R)$ and $\beta(S)$ respectively; we must show that there is $(r, s) \in R \times_Y S$ such that

$$(prin(r), prin(s)) \in \hat{A} \times \hat{B}$$

or in other words such that $r \in A$ and $s \in B$. We have $g^{-1}(g(A)) \in G$ since $A \in G$ and $A \subseteq g^{-1}(g(A))$, so that $g(A)$ belongs to

$$J = \beta(g)(G) \coloneqq \{C \subseteq Y: g^{-1}(C) \in G\}$$

and similarly $h(B) \in J$. It follows that $g(A) \cap h(B) \in J$ so that $g(A) \cap h(B) \neq \emptyset$. Any element $y \in g(A) \cap h(B)$ can be written as $y = g(r)$ and $y = h(s)$ for some $r \in A$ and $s \in B$, and this completes the proof.
=--

### Ultrafilter monad on the equipment $\mathbf{Rel}$

As mentioned in an [earlier section](/nlab/show/relational+beta-module#abstract), the natural transformations $u = prin: 1_{Set} \to \beta$, $m: \beta\beta \to \beta$ **do not** extend to (strict) natural transformations on the locally posetal bicategory $Rel$, but only to transformations that are op-lax in the sense of inequalities

$$prin_Y \circ r \leq \beta(r) \circ prin_X, \qquad m_Y \circ \beta\beta(r) \leq \beta(r) \circ m_X$$

for every relation $r: X \to Y$. These are equivalent to inequalities

$$r \leq prin_Y^o \circ \beta(r) \circ prin_X, \qquad \beta\beta(r) \leq m_Y^o \circ \beta(r) \circ m_X$$

and they may be deduced simply by staring at naturality diagrams in $Set$, in which we represent or [[bicategory of relations|tabulate]] $r$ by $\pi_2 \circ \pi_1^o$:

$$\array{
 & & R & &  & & & & & &   & & \beta\beta (R) & & \\
 & \mathllap{\pi_1} \swarrow & \downarrow_\mathrlap{prin_R} & \searrow \mathrlap{\pi_2} &  & & & & & &  & _\mathllap{\beta\beta\pi_1} \swarrow & \downarrow_\mathrlap{m_R} & \searrow_\mathrlap{\beta\beta\pi_2} & \\
X & & \beta (R) & & Y   & & & & & &  \beta \beta (X) & & \beta (R) & & \beta \beta (Y) \\
 _\mathllap{prin_X} \downarrow & \swarrow_\mathrlap{\beta \pi_1} & &  _\mathllap{\beta \pi_2} \searrow & \downarrow_\mathrlap{prin_Y}  & & & & & & \mathllap{m_X} \downarrow & \swarrow_\mathrlap{\beta \pi_1} & &  _\mathllap{\beta \pi_2} \searrow & \downarrow \mathrlap{m_Y} \\
\beta (X) & & & & \beta (Y) & & & & & & \beta (X) & & & & \beta (Y)
}$$

**To get an actual monad**, it is more satisfactory in this context to consider not the bicategory $Rel$, but rather the [[equipment]] or [[framed bicategory]] $\mathbf{Rel}$. That is, there is a 2-category $Equip$ of equipments (as a sub-2-category of a 2-category of double categories), so that the notion of monad makes sense therein, and it turns out the data to hand induces such a monad $\bar{\beta}: \mathbf{Rel} \to \mathbf{Rel}$.

In more detail: the 0-cells of $\mathbf{Rel}$ are sets, and the horizontal arrows are relations between sets. Vertical arrows are functions between sets, and a 2-cell of shape

$$\array{
A & \stackrel{r}{\to} & B \\
\mathllap{f} \downarrow & \Downarrow & \downarrow \mathrlap{g} \\
C & \stackrel{s}{\to} & D;
}$$

is an inequality $g \circ r \leq s \circ f$. We straightforwardly get a [[double category]] $\mathbf{Rel}$, and the ultrafilter functor on $Set$ extends to a functor $\bar{\beta}: \mathbf{Rel} \to \mathbf{Rel}$ between double categories (or in this case, equipments), preserving all structure in sight.

Some attention must be paid to the notion of transformation between functors $F, G: \mathbf{B} \to \mathbf{C}$ between equipments. A _transformation_ $\eta: F \to G$ assigns to each 0-cell $b$ of $\mathbf{B}$ a _vertical_ arrow $\eta b: F b \to G b$, and to each horizontal arrow $r: b \to b'$ a 2-cell $\eta r$ of the form

$$\array{
F b & \stackrel{F r}{\to} & F b' \\
\mathllap{\eta b} \downarrow & \Downarrow \mathrlap{\eta r} & \downarrow \mathrlap{\eta b'} \\
G b & \stackrel{G r}{\to} & G b';
}$$

suitably compatible with the double category structures.

We thus find that the op-lax structures of the transformations $prin: 1 \to \bar{\beta}$, $m: \bar{\beta} \bar{\beta} \to \bar{\beta}$ on $Rel$ qua _bicategory_ are exactly what we need to produce honest transformations $u: 1 \to \bar{\beta}$, $m: \bar{\beta} \bar{\beta} \to \bar{\beta}$ on $\mathbf{Rel}$ qua _equipment_, and the result is an ultrafunctor monad on the equipment $\mathbf{Rel}$.

Given a monad $T$ on an equipment $\mathbf{B}$, one may proceed to construct a _horizontal Kleisli equipment_ $HKl(\mathbf{B}, T)$ with the same 0-cells and vertical arrows as $\mathbf{B}$, but whose horizontal arrows are of the form $r: b \to T b'$. A 2-cell in $HKl(\mathbf{B}, T)$ (with vertical source $f$ and vertical target $g$) is a 2-cell in $\mathbf{B}$ of the form

$$\array{
b & \stackrel{r}{\to} & T b' \\
\mathllap{f} \downarrow & \Downarrow \mathrlap{\alpha} & \downarrow \mathrlap{T g} \\
c & \stackrel{s}{\to} & T c';
}$$

with horizontal compositions being performed in familiar Kleisli fashion. (When we say "familiar Kleisli fashion", we are using the fact that an equipment allows one to "translate" vertical arrows, in particular the map $m_b: T T b \to T b$, into horizontal arrows, which are then composed horizontally. Similarly, the unit of the monad is translated into a horizontal arrow, where it plays the role of an identity in the Kleisli construction.)

In an equipment, there is a notion of monoid and monoid homomorphism. A _monoid_ consists of a horizontal arrow $\xi: b \to b$ together with unit and multiplication 2-cells

$$\array{
b & \stackrel{1_b}{\to} & b & & & & & & b & \stackrel{\xi}{\to}\;\;\; b \;\;\; \stackrel{\xi}{\to} & b\\
\mathllap{1} \downarrow & \Downarrow \mathrlap{\eta} & \downarrow \mathrlap{1} & & & & & & \mathllap{1} \downarrow & \Downarrow \mathrlap{\mu} & \downarrow \mathrlap{1}\\
b & \stackrel{\xi}{\to} & b & & & & & & b & \stackrel{\xi}{\to} & b
}$$

satisfying evident identities. A _monoid homomorphism_ from $(b, \xi)$ to $(c, \theta)$ consists of a vertical arrow and 2-cell $(f, \phi)$ of the form

$$\array{
b & \stackrel{\xi}{\to} & b \\
\mathllap{f} \downarrow & \Downarrow \mathrlap{\phi} & \downarrow \mathrlap{f} \\
c & \underset{\theta}{\to} & c
}$$

that is suitably compatible with the unit and multiplication cells.

The following notion gives an _interim_ notion of generalized multicategory that applies in particular to relational $\beta$-modules.

+-- {: .num_defn}
###### Definition
Given a monad $T$ on an equipment $\mathbf{B}$, a $T$-*monoid* is a monoid in the horizontal Kleisli equipment $HKl(\mathbf{B}, T)$. A _map_ of $T$-monoids is a homomorphism between monoids in $HKl(\mathbf{B}, T)$.
=--

+-- {: .num_prop}
###### Proposition
For the ultrafilter monad $\beta$ on the equipment $\mathbf{Rel}$, a structure of $\beta$-monoid is equivalent to a structure of relational $\beta$-module, and a homomorphism of $\beta$-monoids is the same as a lax map of relational $\beta$-modules in the bicategory $Rel$.
=--

+-- {: .proof}
###### Proof
This is really just a matter of unwinding definitions. The data of a $\beta$-monoid in the equipment $\mathbf{Rel}$ amounts to a set $X$ together with a horizontal arrow in the Kleisli construction, that is to say a relation $c: X \to \beta X$ (opposite to our conventional direction, i.e., $c = \xi^o$). The unit and multiplication cells for $c$ are inequalities $1_X \leq c$ and $c \circ_{Kl} c \leq c$ (the vertical source and target being identity maps), where the identity $1_X$ in the Kleisli construction uses the unit for $\beta$ and the Kleisli composition uses the multiplication. Back in the bicategory $Rel$ these translate to relational inequalities

$$prin_X \leq c, \qquad m_X \circ \beta c \circ c \leq c$$

or, with $c = \xi^o$,

$$prin_X \leq \xi^o, \qquad m_X \circ (\beta (\xi))^o \circ \xi^o \leq \xi^o.$$

These boil down to relational inequalities

$$1_X \leq prin_X^o \circ \xi^o, \qquad (\beta (\xi))^o \circ \xi^o \leq m_X^o \circ \xi^o$$

or to

$$1_X \leq \xi \circ prin_X, \qquad \xi \circ \beta (\xi) \leq \xi \circ m_X,$$

as in the axioms on relational beta-modules. Similarly, a $\beta$-monoid homomorphism $(X, c) \to (Y, d)$ is a vertical arrow $f: X \to Y$ in $HKl(\mathbf{Rel}, \beta)$ together with a suitable 2-cell, which after some unraveling comes down to a relational inequality

$$\beta (f) \circ c \leq d \circ f$$

or to an inequality $\beta (f) \circ \xi_X^o \leq \xi_Y^o \circ f$, which may be further massaged into the form $\xi_X^o \circ f^o \leq (\beta (f))^o \circ \xi_Y^o$, or simply to

$$f \circ \xi_X \leq \xi_Y \circ \beta (f)$$

as advertised in the notion of lax morphism of relational $\beta$-modules (cf. theorem \ref{contmap} below).
=--

+-- {: .num_remark}
###### Remark
In some sense, relational $\beta$-modules as presented here are a toy example of generalized multicategory theory as set out by Cruttwell and Shulman, where they argue that in order to get a fully satisfying theory that unifies all the relevant constructions and examples, one should really work in the context of monads $T$ acting on _virtual_ equipments and study _normalized_ $T$-monoids. Explaining all this requires a lengthy build-up. Even in the relatively restricted packet of unifications that come under the rubric of $(T, V)$-algebras, as studied by [Clementino, Hofmann, Tholen](#CHT2), [Seal](#Seal) and others as a way of bringing [[topological space|topological spaces]], [[uniform space|uniform spaces]], [[metric space|metric spaces]], [[approach space|approach spaces]], [[Moore closure|closure spaces]], and related notions under one conceptual umbrella, the relevant constructions (e.g. of canonical and op-canonical extensions of [[taut monads]] to lax monads on $V$-matrices) can be somewhat elaborate, and mildly daunting.

The example of the ultrafilter monad acting on $Rel$ has just enough niceness to it (e.g., the Beck-Chevalley condition) that we are able to elide over most of the complications, while still giving a taste of the generality that goes beyond the "classical" examples of generalized multicategories involving cartesian monads and Kleisli constructions on bicategories of spans. Thus, relational beta-modules can serve as a useful key of entry into this subject.
=--

## Proof of Main Theorem

We now return to the task of proving theorem \ref{conc}.

+-- {: .num_remark #open}
###### Remark
For a topological space $(S, \mathcal{O})$ and a point $x \in S$, let $\xi = conv(\mathcal{O})$, and let $\mathcal{O}_x$ be the collection of _open_ neighborhoods of $x$. Then $F \rightsquigarrow_\xi x$, i.e., $N_x \subseteq F$, is equivalent to $\mathcal{O}_x \subseteq F$. This is because $N_x$ is the filter generated by $\mathcal{O}_x$.
=--

+-- {: .num_remark}
###### Remark
The following conditions are equivalent:

* $\xi = conv(\mathcal{C})$ for some $\mathcal{C} \subseteq P(S)$;

* $\xi = conv(\mathcal{O})$ for some topology $\mathcal{O} \subseteq P(S)$;

* $\xi = conv(\tau(\xi))$.

Indeed, $conv \circ \tau \circ conv = conv$ by general properties of Galois connections. Applying $conv \circ \tau$ to both sides of the first equation, we have

$$conv(\tau(\xi)) = (conv \circ \tau \circ conv)(\mathcal{C}) =  conv(\mathcal{C}) = \xi$$

so the first equation implies the third. Which in turn implies the second, since we know by proposition \ref{topo} that collections $\mathcal{O}$ of the form $\tau(\xi)$ are topologies. The second equation trivially implies the first.
=--

We now break up our Main Theorem \ref{conc} into the following two theorems.

+-- {: .num_theorem}
###### Theorem
If $\xi = conv(\mathcal{O})$ for a topology $\mathcal{O}$, then the two inequalities of (eq:rel1) are satisfied.
=--

+-- {: .proof}
###### Proof
The first inequality (lax unit condition) was already verified in proposition \ref{pseudo}. For the second (lax associativity), let us represent the relation $\xi$ by a span $\beta S \stackrel{\pi_1}{\leftarrow} R \stackrel{\pi_2}{\to} S$, so that $\beta(\xi) = \beta(\pi_2) \beta(\pi_1)^o$. The lax associativity condition becomes

$$\pi_2 \pi_1^o \beta(\pi_2) \beta(\pi_1)^o \leq \pi_2 \pi_1^o m_S$$

which (using $\beta(\pi_1) \dashv \beta(\pi_1)^o$) is equivalent to

$$\label{assoc} \pi_2 \pi_1^o \beta(\pi_2) \leq \pi_2 \pi_1^o m_S \beta(\pi_1)$$

or in other words that for all $\mathcal{G}: \beta(R)$, $x: S$

$$\label{conv1} \beta(\pi_2)(\mathcal{G}) \rightsquigarrow_\xi x \;\; \vdash \;\; m_S \beta(\pi_1)(\mathcal{G}) \rightsquigarrow_\xi x.$$

Here $\beta(\pi_2)(\mathcal{G})$ is, by definition,

$$\{U \subseteq S: \pi_2^{-1}(U) \in \mathcal{G}\},$$

with $\beta(\pi_1)(\mathcal{G})$ defined similarly. The monad multiplication $m_S: \beta \beta S \to \beta S$ is by definition

$$(\mathcal{U}: \beta\beta S) \;\; m_S(\mathcal{U}) \coloneqq \{A \subseteq S: \hat{A} \in \mathcal{U}\}$$

where $\hat{A} = \{F \in \beta S: A \in F\}$ (see also the [previous section](/nlab/show/relational+beta-module#functor)).

Thus, (eq:conv1) translates into the following entailment (using remark \ref{open}):

$$\array{
 & & \mathcal{O}_x \subseteq \{A \subseteq S: \pi_2^{-1}(A) \in \mathcal{G}\} \\
 & \vdash & \forall_{U: P S} U \in \mathcal{O}_x \Rightarrow \pi_1^{-1}(\hat{U}) \in \mathcal{G}.
}$$

This would naturally follow if

$$\forall_{U \in \mathcal{O}_x} \pi_2^{-1}(U) \subseteq \pi_1^{-1}(\hat{U}).$$

But a pair $(F, y)$ belongs to $\pi_2^{-1}(U)$ if $F \rightsquigarrow_\xi y$ and $y \in U$; we want to show this implies $F = \pi_1(F, y)$ belongs to $\hat{U}$, or in other words that $U \in F$. But this is tautological, given how $conv(\mathcal{O})$ is defined in terms of a topology $\mathcal{O}$.
=--

The next theorem establishes the converse of the preceding theorem; the two theorems together establish the Main Theorem. First we need a remark and a lemma.

+-- {: .num_remark #closed0}
###### Remark
Given any relation $\xi: Rel(\beta S, S)$ and $A \subseteq S$, then $A$ is closed wrt the topology $\tau(\xi)$ if and only if for all $x \in S$,

$$(\exists_{F: \beta S} A \in F \; \wedge \; F \rightsquigarrow_\xi x) \implies x \in A$$

This follows by inverting the definition of the open sets in $\tau(\xi)$.
=--

+-- {: .num_lemma #closed}
###### Lemma
If a relation $\xi: Rel(\beta S, S)$ satisfies the inequalities of (eq:rel1) and $x: S$, $A \subseteq S$, we have that $x$ belongs to the closure $\bar{A}$ wrt the topology $\tau(\xi)$ if and only if $\exists_{F: \beta S} A \in F \; \wedge \; F \rightsquigarrow_\xi x$.
=--

+-- {: .proof}
###### Proof
For any $A \subseteq S$, denote $A^+ = \{x \mid \exists_{F: \beta S} A \in F \; \wedge \; F \rightsquigarrow_\xi x\}$; we want to show that $A^+ = \bar{A}$. It suffices to show that $A \subseteq A^+ \subseteq \bar{A}$ and that $A^+$ is closed.

That $A^+ \subseteq \bar{A}$ is clear from the characterization of closed sets given in Remark \ref{closed0}; $A^+$ is in some sense the "one-step closure" of $A$. That $A \subseteq A^+$ follows from the lax unit condition for relational $\beta$-modules: if $x \in A$, then $prin(x) \rightsquigarrow_\xi x$ and $A \in prin(x)$.

It's clear from the characterization of closed sets given in Remark \ref{closed0} that a set $A$ is closed if and only if $A = A^+$. We will establish that $A^+$ is closed by showing that $(A^+)^+ = A^+$. By the previous paragraph we know that $A^+ \subseteq (A^+)^+$ so we just need the reverse containment. So suppose that $x \in (A^+)^+$, and pick an ultrafilter $F \in \beta S$ with $A^+ \in F$ and $F \rightsquigarrow_\xi x$. In order to show that $x \in A^+$, we need to produce an ultrafilter $F' \in \beta S$ with $A \in F'$ such that $F' \rightsquigarrow_\xi x$. We will do this by applying the lax associativity condition, using an appropriate ultrafilter $\mathcal{G} \in \beta R$.  In fact, we claim that any $\mathcal{G}$ extending the following [filterbase](http://ncatlab.org/nlab/show/filter#filterbases) on $R$:

$$\mathcal{G}_0 = \{\pi_1^{-1}(\hat{A}) \cap \pi_2^{-1}(U) \mid U \in F\}$$

will fit the bill. First let us verify that such an ultrafilter $\mathcal{G}$ exists. By the ultrafilter principle, it suffices to verify that $\mathcal{G}_0$ generates a proper filter. It's clear that $\mathcal{G}_0$ is closed under finite intersection. So the filter it generates is proper iff $\mathcal{G}_0$ is proper, i.e. doesn't contain the empty set. Now, a typical element of $\mathcal{G}_0$ is of the form $\pi_1^{-1}(\hat{A}) \cap \pi_2^{-1}(U) = \{(G \in \beta S, \; y \in U) \mid A \in G, G \rightsquigarrow_\xi y\}$ for some $U \in F$. Since $U \in F$ and $A^+ \in F$, we can pick $y \in U \cap A^+$. Since $y \in A^+$, there is $G \in \beta S$ with $A \in G$ such that $G \rightsquigarrow_\xi y$ as desired.

So we can pick a $\mathcal{G} \in \beta R$ extending $\mathcal{G}_0$. We want to establish that

1. $\beta \pi_2(\mathcal{G}) \rightsquigarrow_\xi x$
2. $A \in F':= m_S(\beta \pi_1(\mathcal{G}))$

This will complete the proof: From (1) it follows that $F' \rightsquigarrow_\xi x$ by lax associativity. Then (2), along with the fact that $F' \rightsquigarrow_\xi x$, implies that $x \in A^+$, as desired.

To show (1) we show that $\beta \pi_2(\mathcal{G}) = F$; this suffices since $F \rightsquigarrow_\xi x$ by hypothesis. Since both sides of the equations are ultrafilters, It further suffices to show that $F \subseteq \beta \pi_2(\mathcal{G})$. So suppose that $U \in F$. We want to show that $U \in \beta \pi_2(\mathcal{G})$ i.e. that $\pi_2^{-1}(U) \in \mathcal{G}$. This is true because $\pi_1^{-1}(\hat{A}) \cap \pi_2^{-1}(U) \in \mathcal{G}$ and the fact that $\mathcal{G}$ is upward closed.

For (2) we want to show that $A \in m_S(\beta \pi_1(\mathcal{G}))$ i.e. that $\hat{A} \in \beta \pi_1(\mathcal{G})$, i.e. that $\pi_1^{-1}(\hat{A}) \in \mathcal{G}$. This is true because $\pi_1^{-1}(\hat{A}) \cap \pi_2^{-1}(U) \in \mathcal{G}$ and the fact that $\mathcal{G}$ is upward closed.
=--

+-- {: .num_theorem}
###### Theorem
If $\xi: \beta S \to S$ in $Rel$ satisfies the inequalities of (eq:rel1), then $\xi = conv(\tau(\xi))$.
=--

+-- {: .proof}
###### Proof
We have $\xi \leq conv(\tau(\xi))$ from the Galois connection (proposition \ref{galois}), so we just need to prove $conv(\tau(\xi)) \leq \xi$, or that $F \rightsquigarrow_{conv(\tau(\xi))} x$ (henceforth abbreviated as $F \rightsquigarrow_{\tau(\xi)} x$) implies $F \rightsquigarrow_\xi x$ under the conditions (eq:rel1).

If $F \rightsquigarrow_{\tau(\xi)} x$, then every neighborhood $V$ of $x$ belongs to $F$, so that for every $U \in F$, every neighborhood $V$ of $x$ intersects $U$ in a nonempty set. But this just means $x \in \bar{U}$ for every $U \in F$, or in other words (using lemma \ref{closed}) that

$$U \in F \; \; \vdash \; \; \exists_{G: \beta S} U \in G \; \wedge \; G \rightsquigarrow_\xi x.$$

Representing the relation $\xi$ as usual by a subset $\langle \pi_1, \pi_2 \rangle: R \hookrightarrow \beta S \times S$, another way of expressing the existential formula on the right of this entailment is:

$$\exists_{(G, x): \beta S \times S} \; (G, x) \in R \; \wedge \; G \in \hat{U}$$

or

$$\exists_{\gamma: R} \pi_1(\gamma) \in \hat{U} \wedge \pi_2(\gamma) = x$$

or even just

$$\label{ult} \pi_1^{-1}(\hat{U}) \wedge \pi_2^{-1}(\{x\}) \neq \emptyset$$

as subsets of $R$, as $U$ ranges over all elements of $F$. We therefore have that subsets of the form (eq:ult) generate a proper filter of $R$. By the ultrafilter principle, we may extend this filter to an ultrafilter $\mathcal{G} \in \beta R$.

By construction, we have

$$F \subseteq \{B \subseteq X: \pi_1^{-1}(\hat{B})) \in \mathcal{G}\} \qquad prin_S(x) \subseteq \{A \subseteq X: \pi_2^{-1}(A) \in \mathcal{G}\}$$

but in fact these inclusions are equalities since the left sides and right sides are ultrafilters. Put differently, we have established

$$F = (m_S \circ \beta(\pi_1))(\mathcal{G}), \qquad prin_S(x) = \beta(\pi_2)(\mathcal{G}).$$

Notice that the lax unit condition of (eq:rel1) implies that $prin_S(x) = \beta(\pi_2)(\mathcal{G}) \rightsquigarrow_\xi x$, or that $(\mathcal{G}, x)$ belongs to the relation $\xi \circ \beta(\pi_2)$. Recall also that the lax associativity condition is equivalent to (eq:assoc), which says

$$\xi \circ \beta(\pi_2) \leq \xi \circ m_S \circ \beta(\pi_1);$$

in other words $(\mathcal{G}, x)$ belongs to $\xi \circ m_S \circ \beta(\pi_1)$, i.e., $F = (m_S \circ \beta(\pi_1))(\mathcal{G}) \rightsquigarrow_\xi x$, as was to be shown.
=--

This completes the proof of the Main Theorem (theorem \ref{conc}).

## Continuous maps

+-- {: .num_theorem #contmap}
###### Theorem
A function between two topological spaces $f: X \to Y$ is continuous if and only if $f \circ \xi \leq \theta \circ \beta(f)$ for their respective topological notions of convergence $\xi, \theta$.
=--

+-- {: .proof}
###### Proof
Suppose first that $f$ is continuous, and that $(F, y) \in \beta(X) \times Y$ belongs to $f \circ \xi$, i.e., there is $x$ such that $F \rightsquigarrow x$ and $f(x) = y$. We want to show $\beta(f)(F) \rightsquigarrow y = f(x)$, or that any open set $V$ containing $f(x)$ belongs to $\beta(f)(F)$. The latter means $f^{-1}(V) \in F$, which is true since $f^{-1}(V)$ is an open set containing $x$ and $F \rightsquigarrow x$.

Now suppose $f \circ \xi \leq \theta \circ \beta(f)$. To show $f$ is continuous, it suffices to show that

$$f(\bar{A}) \subseteq \widebar{f(A)}$$

for any $A \subseteq X$ (easy exercise). For $x \in \bar{A}$, lemma \ref{closed} shows there is $F: \beta(X)$ with $A \in F$ and $F \rightsquigarrow x$. Under the supposition we have $\beta(f)(F) \rightsquigarrow f(x)$, and we also have $f(A) \in \beta(f)(F)$, because $A \subseteq f^{-1}(f(A))$ and $F$ is upward closed and $A \in F$ implies $f^{-1}(f(A)) \in F$. Then again by lemma \ref{closed}, $f(A) \in \beta(f)(F)$ and $\beta(f)(F) \rightsquigarrow f(x)$ implies $f(x) \in \widebar{f(A)}$, as desired.
=--

+-- {: .num_cor #equivalence}
###### Corollary
**(Barr)**
The category of topological spaces is equivalent (even isomorphic to) the category of lax $\beta$-modules and lax morphisms between them.
=--

## Properties

As above, a [[subset]] $A$ of $S$ is __[[open subset|open]]__ if $A \in \mathcal{U}$ whenever $\mathcal{U} \to x \in A$.  On the other hand, by lemma \ref{closed}, $A$ is __[[closed subset|closed]]__ if $x \in A$ whenever $A \in \mathcal{U} \to x$.

A relational $\beta$-module is __[[compact space|compact]]__ if every ultrafilter converges to at least one point.  It is __[[Hausdorff space|Hausdorff]]__ if every ultrafilter converges to at most one point.  Thus, a __[[compactum]]__ is (assuming $UF$) precisely a relational $\beta$-module in which every ultrafilter converges to exactly one point, that is in which the action of the monad $\beta$ lives in $Set$ rather than in $Rel$. Full proofs may be found at [[compactum]]; see also [[ultrafilter monad]].

A continuous map $f$ from $(X, \xi: \beta X \to X)$ to $(Y, \theta: \beta Y \to Y)$ is [[proper map|proper]] if the square

$$\array{
\beta X & \stackrel{\xi}{\to} & X \\
\mathllap{\beta (f)} \downarrow & & \downarrow \mathrlap{f} \\
\beta Y & \underset{\theta}{\to} & Y
}$$

commutes (strictly) in $Rel$, and $f$ is [[open map|open]] if the square

$$\array{
\beta X & \stackrel{\xi}{\to} & X \\
\mathllap{\beta (f)^o} \uparrow & & \uparrow \mathrlap{f^o} \\
\beta Y & \underset{\theta}{\to} & Y
}$$

commutes in $Rel$. From this point of view, a space $X$ is Hausdorff if the diagonal map $\delta: X \to X \times X$ is open, and compact if $\epsilon: X \to 1$ is proper (and these facts remain true even for pseudotopological spaces). See [Clementino, Hofmann, and Janelidze](#CHJ), _infra_ corollary 2.5.

The following _ultrafilter interpolation_ result is due to [Pisani](#Pis):

+-- {: .un_theorem}
###### Theorem
A topological space $(X, \xi)$ is exponentiable if, whenever $m_X(\mathcal{U}) \rightsquigarrow_\xi x$ for $\mathcal{U} \in \beta\beta X$ and $x \in X$, there exists $F \in \beta X$ with $\mathcal{U} \rightsquigarrow_{\beta(\xi)} F$ and $F \rightsquigarrow_\xi x$.
=--

For an convergence-approach extension of this result to exponentiable _maps_ in $Top$, see [Clementino, Hofmann, and Tholen](#CHT).

+-- {: .num_defn}
###### Definition
A continuous map $f: X \to Y$ is a _discrete fibration_ if, whenever $G \rightsquigarrow y$ in $Y$ and $f(x) = y$, there exists a unique $F \in \beta(X)$ such that $\beta(f)(F) = G$ and $F \rightsquigarrow x$ in $X$.
=--

+-- {: .num_prop}
###### Proposition
A continuous map $f: X \to Y$ is étale (a local homeomorphism) if $f$ and $\delta_f: X \to X \times_Y X$ are both discrete fibrations.
=--

For more on this, see [Clementino, Hofmann, and Janelidze](#CHJ).

## Relation to nonstandard analysis

In [[nonstandard analysis]] (which implicitly relies throughout on $UF$), one may define a topological space using a relation between hyperpoints (elements of $S^*$) and standard points (elements of $S$).  If $u$ is a hyperpoint and $x$ is a standard point, then we write $u \approx x$ and say that $x$ is a __[[standard part]]__ of $u$ or that $u$ belongs to the __[[halo]]__ (or _monad_, but *not* the category-theoretic kind) of $x$.  This relation must satisfy a condition analogous to the condition in the definition of a relational $\beta$-module.  The nonstandard defintions of open set, compact space, etc are also analogous.  (Accordingly, one can speak of *the* standard part of $u$ only for Hausdorff spaces.)

So ultrafilters behave very much like hyperpoints.  This is not to say that ultrafilters *are* (or even can be) hyperpoints, as they don\'t obey the [[transfer principle]].  Nevertheless, one does use ultrafilters to construct the [[model]]s of nonstandard analysis in which hyperpoints actually live.  Intuitions developed for nonstandard analysis can profitably be applied to ultrafilters, but the transfer principle is not valid in proofs.

## Relation to other topological concepts

If $\beta$ is treated as a monad on $Set$ instead of on $Rel$, then its algebras are the [[compacta]] (the compact Hausdorff spaces), again assuming $UP$; see [[ultrafilter monad]], and more especially [[compactum]].

One might hope that there would be an analogous treatment of [[uniform spaces]] based on an [[equivalence relation]] between ultrafilters.  (In nonstandard analysis, this becomes a relation $\approx$ of infinite closeness between arbitrary hyperpoints, instead of only a relation between hyperpoints and standard points.)  The description in terms of generalized multicategories is known to generalize to a description of uniform spaces, but rather than using relations between ultrafilters, this description uses pro-relations between points.

For more on relations between Barr's approach to topological spaces, Lawvere's approach to [[metric spaces]], as well as [[uniform space|uniform structures]], [[prometric spaces]], and [[approach space|approach structures]], see [Clementino, Hofmann, and Tholen](#CHT2).

## References

* Michael Barr, _Relational algebras_, Springer Lecture Notes in Math. 137 (1970), 39-55.
([pdf](https://www.math.mcgill.ca/barr/papers/relalgs.pdf))
{#Barr}

* Maria Manuel Clementino, Dirk Hofmann, and George Janelidze, _On exponentiability of étale algebraic homomorphisms_, Preprint 11-35, University of Coimbra. ([pdf](http://www.mat.uc.pt/preprints/ps/p1135.pdf))
{#CHJ}

* Maria Manuel Clementino, Dirk Hofmann, and Walter Tholen, _The convergence approach to exponentiable maps_, Portugaliae Mathematica (Nova Series), Vol. 60 Issue 2 (2003), 139-160. ([web](https://eudml.org/doc/51942)) ([pdf](https://cmuc.mat.uc.pt/rdonweb/publications/publication22.pdf))
{#CHT}

* Maria Manuel Clementino, Dirk Hofmann, and Walter Tholen, _One Setting for All: Metric, Topology, Uniformity, Approach Structure._ ([Springer Link](https://link.springer.com/article/10.1023/B:APCS.0000018144.87456.10), doi: 10.1023/B:APCS.0000018144.87456.10)
{#CHT2}

* Gavin J. Seal, _Canonical and op-canonical lax algebras_, Theory and
Applications of Categories, 14 (2005), 221–243. ([web](http://www.tac.mta.ca/tac/volumes/14/10/14-10abs.html))
{#Seal}

* Claudio Pisani, Convergence in exponentiable spaces, Theory Appl. Categories 5 (1999), 148-162. ([web](http://www.tac.mta.ca/tac/volumes/1999/n6/5-06abs.html))
{#Pis}

* [[Geoff Cruttwell]] and [[Mike Shulman]], _A unified framework for generalized multicategories_, [arxiv/0907.2460](http://arxiv.org/abs/0907.2460)

[[!redirects relational beta-module]]
[[!redirects relational beta-modules]]
[[!redirects relational ∞-module]]
[[!redirects relational ∞-modules]]


relational calculus

+-- {: .rightHandSide}
+-- {: .toc .clickDown tabindex="0"}
### Context
#### Relations
+-- {: .hide}
[[!include relations - contents]]
=--
=--
=--

#Contents#
* table of contents
{:toc}

## Idea

_Relational calculus_ deals with [[relations]]...

## Related concepts

* [[allegory]]


relational set theory

+-- {: .rightHandSide}
+-- {: .toc .clickDown tabindex="0"}
### Context
#### Foundations
+-- {: .hide}
[[!include foundations - contents]]
=--
=--
=--

#Contents#
* table of contents
{:toc}

## Idea

(...) based on [[Rel]] instead of [[Set]] (...)

## Related concepts

* [[SEAR]]

* [[meros]]

## References

Discussion in terms of [[meroi]]:

* {#Kawahara95} [[Kawahara Yasuo]], _Relational Set Theory_, in Proceedings of the 6th International Conference on Category Theory and Computer Science, 1995 ([doi:10.1007/3-540-60164-3_19](http://dx.doi.org/10.1007/3-540-60164-3_19), [pdf](https://www.researchgate.net/profile/Yasuo-Kawahara/publication/226561376_Relational_set_theory/links/569f960908ae21a564270542/Relational-set-theory.pdf))

[[!redirects relational set theories]]


relational structure

# Relational structures
* table of contents
{:toc}

## Idea

Relational structures are [[models]] for a [[relational theory]], that is, a [[logical theory]] whose [[signature (in logic)|signature]] is **relational**.

+-- {: .un_defn}
###### Definition

A __relational structure__ is a tuple $\mathfrak{F}$ whose first component $W$, is a non-empty set, and whose remaining components are relations on $W$. (We assume that there is at least one relation given.)
=--

In their use in the Kripke semantics of [[modal logics]], the set $W$ is sometimes called the _universe_ (perhaps better the _domain_) and the  elements of $W$ are called 'worlds', amongst a host of other names! This leads to the terminology 'possible world semantics' which is sometimes used.

## Examples

1. [[partial order|poset]], $(W;\leq)$ or more generally a set, $W$, with a family of partial orders, $\{\leq_i\}$, on it;

2. [[transition system]], $(S; \{R_e\mid e\in E\})$, (see discussion on the transition system's page);

3. a rooted [[tree]] can be considered as a relational structure on its set of nodes, by specifying properties of a successor relation;

4. an [[arrow structure]] is a relational structure proposed in [[modal logic]] to handle relational versions of [[groupoids]];

5. a set $W$ with, on it, an equivalence relation, $\sim$, or, more generally, a family of equivalence relations, $\sim_i$, for $i$ in some indexing set.

## References

See also

* Wikipedia, _[Relational theory](https://en.m.wikipedia.org/wiki/Relational_theory)_

* [[Michael Barr]], *Note on a theorem of Putnam's*, Theory Appl. Categories, **3** 3 (1997) 45–49 [[tac:3-03](http://www.tac.mta.ca/tac/volumes/1997/n3/3-03abs.html)]

[[!redirects relational structures]]

[[!redirects relational theory]]
[[!redirects relational theories]]


relations - contents

**[[relation]]**, [[internal relation]]

**[[Rel]]**, [[bicategory of relations]], [[allegory]]

## Types of Binary relation

* [[reflexive relation|reflexive]], [[irreflexive relation|irreflexive]]
* [[symmetric relation|symmetric]], [[antisymmetric relation|antisymmetric]] [[asymmetric relation|asymmetric]]
* [[transitive relation|transitive]], [[comparison]];
* left and right [[euclidean relation|euclidean]];
* [[total relation|total]], [[connected relation|connected]]
* [[extensional relation|extensional]], [[well-founded relation|well-founded]] relations.

* [[functional relations]],
* [[entire relations]],
* [[equivalence relations]], [[congruence]]
* [[apartness relations]]

* [[simple graph]]

## In higher category theory

* [[2-congruence]]

* [[(n,r)-congruence]]

[Edit this sidebar](/nlab/edit/relations+-+contents)


relations of certain classes of group schemes

We describe the relation of certain classes of group schemes.

The page numbering refers to the text:

* Michel Demazure, lectures on p-divisible groups [web](http://sites.google.com/site/mtnpdivisblegroupsworkshop/lecture-notes-on-p-divisible-groups)

## Summary (Constructing examples of group schemes from basic examples)

(...)

## Decomposition of k-groups
 One way the characterize certain classes of $k$-groups is via exact sequences

$$0\to G^{ex}\to G\to G_{ex}\to 0$$

|$k$-group | $G^{ex}$ | $G_{ex}$ | | |
|-------|-------|-------|-------|--------|
| [[formal group scheme|formal k-group]] | [[connected group scheme|connected]] | [[étale group scheme|étale]] | | p.34 |
| [[finite k-group]] | [[infinitesimal group scheme|infinitesimal]] | étale | splits if $k$ is perfect |p.35 |
| [[affine group scheme|affine k-group]] | [[multiplicative group scheme|multiplicative]] | [[unipotent group scheme|unipotent]] | splits if $k$ is perfect | p.39 |
| connected formal $k$-group | $G_{red}$ is [[smooth group scheme|smooth]] | $G/G_{red}$ is infinitesimal | | p.43 |

+-- {: .num_defn}
###### Definition
(p. 39)

If  $k$ is perfect any finite affine $k$-group $G$ is in a unique way the product of four subgroups

$$G=a\times b\times c\times d$$

where

1.  $a\in Fem_k$ is a formal étale multiplicative $k$ group.

1.  $b\in Feu_k$ is a formal étale unipotent $k$ group.

1.  $c\in Fim_k$ is a formal infinitesimal multiplicative $k$ group.

1.  $d\in Fem_k$ is a infinitesimal unipotent $k$ group.
=--

## Duality of k-groups

| $D$ |  $D(G)$ | |
|--|--|--|
| affine commutative $k$-group | $\hat D(G)$ is affine commutative formal $k$-group | p.27 |
| finite commutative $k$-group | finite commutative $k$-group | p.27 |
| [[constant group scheme|constant k-group]] | diagonalizable $k$-group | p.36|
|étale k-group|multiplicative k-group|p.37|
|multiplicative k-group |$\hat D(G)$ is étale formal $k$-group|p.37|
|unipotent k-group|$\hat D(G)$ connected formal group|p.38|
|$Fim_k$|$Feu_k$| |

## Skalar extension and skalar restriction

Let $K\in M_k$ be a field, let $k_s$ be the separable clusure of $k$, let $\overline k$ denote the algebraic closure of $k$.

| | | | | |
|--|--|--|--|--|
|$G$|$G\otimes_k K$|$G\otimes_k k_s$|$G\otimes_k \overline k$| |
|multiplicative|diagonalizable|diagonalizable|diagonalizable| p.38|
|étale | |constant|constant|p.17|
## Examples of $k$-groups

| | | | | | | | |
|--|--|--|--|--|--|--|--|
| | unipotent | multiplicative | étale | connected | infinitesimal | diagonalizable |p-divisible|
|unipotent| | | | | | | |
| [[multiplicative group scheme|multiplicative]] | | | | | | | |
| [[étale scheme|étale]] | | | | | | | |
| connected | | | | | | | |
| infinitesimal | | | | | | | |
| [[diagonalizable group scheme|diagonalizable]] | | | | | | | |
|p-divisible | | | | | | |$(\mathbb{Q}_p/\mathbb{Z}_p)_k$ and [[the p-divisible group A(p)|A(p)]] |


relative (infinity,1)-adjunction

[[!redirects relative (∞,1)-adjunction]]

+-- {: .rightHandSide}
+-- {: .toc .clickDown tabindex="0"}
###Context###
#### $(\infty,1)$-Category theory
+--{: .hide}
[[!include quasi-category theory contents]]
=--
=--
=--

#Contents#
* table of contents
{:toc}

## Idea

A relative version of the notion of [[adjoint (∞,1)-functor]]s.

## References

Section 1.2 of

* [[Jacob Lurie]], _[[Deformation Theory]]_
 {#Lurie}


relative (infinity,1)-limit

+-- {: .rightHandSide}
+-- {: .toc .clickDown tabindex="0"}
###Context###
#### $(\infty,1)$-Category theory
+--{: .hide}
[[!include quasi-category theory contents]]
=--
#### Limits and colimits
+--{: .hide}
[[!include infinity-limits - contents]]
=--
=--
=--

#Contents#
* table of contents
{:toc}

## Idea

The relative version of the notion of [[(∞,1)-limit]].

## Definition

+-- {: .num_defn}
###### Definition

For $f \colon \mathcal{C} \to \mathcal{D}$ an [[(∞,1)-functor]] between [[(∞,1)-categories]] which is presented by an [[inner fibration]] of [[quasi-categories]] (which we denote by the same symbols), and for

$$
  \overline{p} \colon K^{\triangleright} \to \mathcal{C}
$$

a [[cocone]] [[diagram]] in $\mathcal{C}$ over the $K$-shaped [[diagram]]

$$
  p \coloneqq \overline{p}|K
  \,,
$$

then $\overline{p}$ is an **$(\infty,1)$-colimiting** cocone if the canonical map

$$
  \mathcal{C}_{\overline{p}/}
  \to
  \mathcal{C}_{p/}
  \underset{\mathcal{D}_{f p /}}{\times}
  \mathcal{D}_{f\overline{p}/}
$$

(from the [[slice (∞,1)-category|co-slice quasi-category]])
is an [[acyclic Kan fibration]] of [[simplicial sets]].

=--

([Lurie, def. 4.3.1.1](#Lurie))

## Examples

 - If $\mathcal{D} = \Delta[0]$ is the terminal category and $f: \mathcal{C} \to \Delta[0]$ is the unique functor, then an $f$-colimit is the same thing as a colimit in the usual sense.

 - If $K = \Delta[0]$ is the terminal category so that $p: \Delta[0] \to \mathcal{C}$ picks out an object and $f\overline{p}: K^{\triangleright} = \Delta[1] \to \mathcal{D}$ picks out an edge, an $f$-colimit is precisely an $f$-cocartesian lift.

 - If $f: \mathcal{C} \to \mathcal{D}$ is a cocartesian fibration such that the fibers $\mathcal{C}_s$ have all $K$-shaped colimits and the reindexing functors $\mathcal{C}_s \to \mathcal{C}_{s'}$ preserve $K$-shaped colimits for each morphism $s \to s'$ in $\mathcal{D}$, then for any extension $g: K^\triangleright \to \mathcal{D}$ of $fp$, the relative colimit is given by the functor $\bar{p}: K^\triangleright \to \mathcal{C}$ which extends $p$ to the fiber $\mathcal{C}_{g(\infty)}$ (where $\infty \in K^\triangleright$ is the cocone point) in a cocartesian way, and carries the cocone point of $K^\triangleright$ to the colimit of the induced diagram $K \to \mathcal{C}_{g(\infty)}$. (See [Lurie, Cor 4.3.1.11](#Lurie) and its proof.)

## References

* [[Jacob Lurie]], _[[Higher Topos Theory]]_
 {#Lurie}

[[!redirects relative (infinity,1)-limits]]

[[!redirects relative (∞,1)-limit]]
[[!redirects relative (∞,1)-limits]]

[[!redirects relative (infinity,1)-colimit]]
[[!redirects relative (infinity,1)-colimits]]

[[!redirects relative (∞,1)-colimit]]
[[!redirects relative (∞,1)-colimits]]


relative (∞,1)-limit

[[!redirects relative (∞,1)-limit]]

+-- {: .rightHandSide}
+-- {: .toc .clickDown tabindex="0"}
###Context###
#### $(\infty,1)$-Category theory
+--{: .hide}
[[!include quasi-category theory contents]]
=--
#### Limits and colimits
+--{: .hide}
[[!include infinity-limits - contents]]
=--
=--
=--

#Contents#
* table of contents
{:toc}

## Idea

The relative version of the notion of [[(∞,1)-limit]].

## Definition

+-- {: .num_defn}
###### Definition

For $f \colon \mathcal{C} \to \mathcal{D}$ an [[(∞,1)-functor]] between [[(∞,1)-categories]] which is presented by an [[inner fibration]] of [[quasi-categories]] (which we denote by the same symbols), and for

$$
  \overline{p} \colon K^{\ast} \to \mathcal{C}
$$

a [[cocone]] [[diagram]] in $\mathcal{C}$ over the $K$-shaped [[diagram]]

$$
  p \coloneqq \overline{p}|K
  \,,
$$

then $\overline{p}$ is an **$(\infty,1)$-colimiting** cocone if the canonical map

$$
  \mathcal{C}_{\overline{p}/}
  \to
  \mathcal{C}_{p/}
  \underset{\mathcal{D}_{f p /}}{\times}
  \mathcal{D}_{f\overline{p}/}
$$

(from the [[slice (∞,1)-category|co-slice quasi-category]])
is an [[acyclic Kan fibration]] of [[simplicial sets]].

=--

([Lurie, def. 4.3.1.1](#Lurie))

## References

* [[Jacob Lurie]], _[[Higher Topos Theory]]_
 {#Lurie}

[[!redirects relative (∞,1)-limits]]


relative adjoint functor

+-- {: .rightHandSide}
+-- {: .toc .clickDown tabindex="0"}
###Context###
#### Category theory
+--{: .hide}
[[!include category theory - contents]]
=--
=--
=--

#Relative adjoint functors#
* table of contents
{:toc}

## Idea ##

The notion of *relative adjoint functors* with respect to a functor $J$ is a generalization of that of [[adjoint functor]] (to which it reduces for $J$ an [[identity functor]]).
In generalization of the [relation between adjunctions and monads](monad#RelationBetweenAdjunctionsAndMonads),
relative adjoint functors are related to [[relative monads]].

## Definition ##

### Via hom-isomorphism  ###

Fix a functor $J\colon B \to D$. Then, for a functor

\[
	R \colon C \longrightarrow D
\]

to have _left $J$-relative adjoint_ (or *$J$-left adjoint*) means that there is a functor

\[
	L \colon B \longrightarrow C
\]

and a [[natural isomorphism]] of the ofrm

\[
  Hom_C\big(L(-),-\big)
  \;\simeq\;
  Hom_D\big(J(-),R(-)\big)
  \,.
\]

[[formal duality|Dually]], for $L \colon C \longrightarrow D$ to have a _$J$-right adjoint_ $R \colon B \longrightarrow C$ means that there is a [[natural isomorphism]] of the form

\[
  Hom_D\big(L(-), J(-)\big)
   \;\simeq\;
  Hom_C\big(-, R(-)\big)
\]

One writes

- $L {\,\,}_J\!\dashv R$ stands for $L$ being the $J$-left adjoint of $R$
- $L \dashv_J R$ stands for $R$ being the $J$-right adjoint of $L$

### Via absolute lifting ###

Just as with regular adjoints, in the unenriched setting, relative adjoints can be defined in a more conceptual way in terms of _absolute [[Kan lift|liftings]]_. We have

1. $L {\,\,}_J\!\dashv R$ if $L = \mathop{Lift}_R J$, and this left lifting is _absolute_
2. $L \dashv_J R$ if $R = \mathop{Rift}_L J$, and this right lifting is _absolute_

However, this is not true for [[enriched functors]].

## Properties ##

### asymmetry ###

The most important difference with regular adjunctions is the asymmetry of the concept. First, for $L {\,\,}_J\!\dashv R$ it makes no sense to ask for $R \dashv_J L$ (domains and comodomains do not typecheck). And secondly, and more importantly:

* **$L$ is $J$-left adjoint to $R$:** $R$ _determines_ $L$
* **$R$ is $J$-right adjoint to $L$:** $L$ _determines_ $R$

(this is obvious from the definition in terms of liftings). Because of this, even if most of the properties of adjunctions have a generalization to the relative setting, they do that in a one-sided way.

### unit, counit ###

Asymmetry manifests itself here:

1. $L {\,\,}_J\!\dashv R$ yields a $J$-relative _unit_ 2-cell $\iota\colon J \to R L$
2. while $L \dashv_J R$ gives a $J$-relative _counit_ $\epsilon\colon L R \to J$

with no naturally available counterpart for them in each case.

These 2-cells are directly provided by the definition in terms of liftings, as the universal 2-cells

- $\iota\colon J \to R L$ given by $L = \mathop{Lift}_R J$
- $\epsilon\colon L R \to J$ given by $R = \mathop{Rift}_L J$

Alternatively, and just as with regular adjunctions, their components can be obtained from the natural hom-isomorphism: in the unit case, evaluating at $Lb$ we get a bijection

\[
	Hom_C(Lb, Lb) \simeq Hom_D(Jb, RLb)
\]

and

\[
	\iota_b \colon J b \to R L b
\]

is given by evaluating at $1_{Lb}$ the aforementioned bijection. A completely analogous procedure yields a description of the counit for $L \dashv_J R$.

### Relative monads and comonads ###

Just as adjunctions give rise to [[monad|monads]] and [[comonad|comonads]], for relative adjoints

1. If $L {\,\,}_J\!\dashv R$, then $RL$ is a [[relative monad]]
2. If $L \dashv_J R$, then $LR$ is a [[relative comonad]]

with relative units and counits as above, respectively.

There are also relative analogues of [[Eilenberg-Moore category|Eilenberg-Moore]] and [[Kleisli category|Kleisli]] categories for these.

### Relative adjointness generalizes adjointness ###

The concept of relative adjoint functors is a generalization of the concept of adjoint functors: if a functor $R\colon C\to D$ has a left adjoint in the usual sense, then it also has a $J$-left adjoint for $J=id_D$.

## Examples ##

**fully faithful functors**
:	A functor $F: A \to B$ is fully faithful iff it is representably fully faithful iff $1_A = \mathop{Lift}_F F$, and this lifting is absolute. Thus, $F$ fully faithful can be expressed as
	\[
		1 {\,\,}_F\!\dashv F
	\]

**partially defined adjoints**
:	As remarked in the [[adjoint functor|local definition of adjoint functor]], given a functor
	\[
		L \colon C \to D
	\]
	it may happen that $Hom_D(L(-),d)$ is [[representable functor|representable]] only for _some_ $d$, but not for all of them. In that case, taking
	\[
		J \colon B \to D
	\]
	be the inclusion of the [[full subcategory|full subcategory]] determined by $Hom_D(L(-),d)$ representable, and defining $R \colon B \to C$ accordingly, we have
	\[
		L \dashv_J R
	\]
	This can be specialized to situations such as a category having _some_ but not all [[limit|limits]] of some kind, partially defined [[Kan extension|Kan extensions]], etc. See also [[free object]].

**nerves**
:	Take $A$ a locally small category, and $F\colon A \to B$ a locally left-small functor (one for which $B(Fa,b)$ is always small). The _$A$-nerve_ induced by $F$ is the functor
	\[
		N_F \colon B \to \mathbf{Set}^{A^{\mathop{op}}}
	\]
	given by $N_F(b)(a) = B(Fa,b)$. It is a fundamental fact that $F = \mathop{Lift}_{N_F} y_A$ and this lifting is _absolute_; or, in relative adjoint notation, $F {\,\,}_{y_A}\!\dashv N_F$. The universal 2-cell $\iota\colon y_A \to N_F F$ is given by the action of $F$ on morphisms:
	\[
		\iota_a \colon y_A a \to (N_F F)(a)
	\]
	at $a' \colon A$ is
	\[
		F_{a,a'}\colon A(a,a') \to B(Fa, Fa')
	\]

	Note that when specialized to $F = 1_A$, this reduces to the [[yoneda lemma|Yoneda lemma]]: first $N_{1_A} \simeq y_A$, and then $1_A = \mathop{Lift}_{y_A} y_A$ absolute in hom-isomorphism terms reads:
	\[
		A(x,y) \simeq \mathbf{Set}^{A^{\mathop{op}}}(y_A x, y_A y)
	\]

	One of the axioms of a [[yoneda structure|Yoneda structure]] on a 2-category abstract over this situation, by requiring the existence of $F$-nerves with respect to yoneda embeddings such that the 1-cell $F$ is an absolute left lifting as above; see [Weber](#Weber2007) or [Street--Walters](#StreetWalters1978)
.

## Related concepts

* [[relative monad]]

## References ##

### General

* [[Friedrich Ulmer]], _Properties of dense and relative adjoint functors_, Journal of Algebra, **8** 1 (1968) 77-95 [doi:10.1016/0021-8693(68)90036-7]

*  {#StreetWalters1978} [[Ross Street]], [[Bob Walters]], *Yoneda structures on 2-categories*, Journal of Algebra, **50** 2 (1978) 350-379 [doi:10.1016/0021-8693(78)90160-6, [mendeley](http://www.mendeley.com/research/yoneda-structures-2categories/)]

* {#ACU14} [[Thorsten Altenkirch]], [[James Chapman]], [[Tarmo Uustalu]], *Monads need not be endofunctors*, Logical Methods in Computer Science **11** 1:3 (2015) 1–40 [[arXiv:1412.7148](https://arxiv.org/abs/1412.7148), [pdf](http://www.cs.nott.ac.uk/~txa/publ/jrelmon.pdf), doi:10.2168/LMCS-11(1:3)2015]

*  {#Weber2007} [[Mark Weber]] - _Yoneda structures from 2-toposes_, Appl Categor Struct. **15** (2007) 259. [doi:10.1007/s10485-007-9079-2, [pdf](https://sites.google.com/site/markwebersmaths/home/yoneda-structures-from-2-toposes)]

### Examples

On the [[categorical semantics]] of [[dependent product types]] as *[[relative adjoint functor|relative]]* [[right adjoints]] to [[context extension]] in [[comprehension categories]]:

* [[Michael Lindgren]], *Dependent products as relative adjoints*, Stockholm (2021) [[[Lindgren-DependentProductsAsRelativeAdjoints.pdf:file]]]

[[!redirects relative adjoint functors]]
[[!redirects relative right adjoint]]
[[!redirects relative left adjoint]]
[[!redirects relative adjoint]]
[[!redirects relative adjoints]]
[[!redirects relative adjunction]]
[[!redirects relative adjunctions]]


relative affine n-space

## Overview

In [[algebraic geometry]], for an algebraic scheme $S$ and positive integer $n$, the __relative affine $n$-space__ $\mathbf{A}^n_S$ (or: [[affine space|affine]] $n$-space over $S$) is the generalization of an affine $n$-space $\mathbf{A}^n_k$ (considered as an algebraic $k$-scheme) from a ground ring $k$ to the category of [[relative scheme]]s over the base scheme $S$.

There are several equivalent definitions.

## Definition using affine covers

In the affine case, if $S = Spec(B)$ this is simply the spectrum $\mathbf{A}^n_S = Spec(B[x_1,\ldots,x_n])$, and the morphism to the base scheme $S$ is induced by the ring inclusion $B\hookrightarrow B[x_1,\ldots,x_n]$.

For general scheme, one takes an open cover of $S$ by affine schemes, and notices that the inclusions of double intersections into single intersection induce morphisms of ringed spaces from the double intersection to the single intersection, satisfying the cocycle condition allowing for gluing of such relative affine $n$-spaces over affines. Finally one checks that this definition does not depend on cover.

## Definition via fiber product

$$
\mathbf{A}^n_S =
\mathbf{A}^n_{\mathbf{Z}}\times_{Spec{Z}} S
$$

## Definition via relative spectrum

There is a general notion of a relative spectrum (sometimes called global spectrum) of a sheaf of $\mathcal{O}_T$-algebras over a scheme $T$. The affine $n$-space over a scheme $S$ may be viewed as the $n$-dimensional vector bundle over $S$, but not viewed
as a locally free sheaf but as a total space. Fiberwise, to make a scheme from a vector space, one needs to take the spectrum of a symmetric algebra.

Affine $n$-space over $S$ is simply the spectrum of the symmetric algebra of the direct sum of $n$-copies of the structure sheaf of $S$:
$$
\mathbf{A}^n_S =
Spec(Sym(\mathcal{O}^n_S))
$$

category: algebraic geometry
[[!redirects relative affine space]]