2-algebraic geometry

+-- {: .rightHandSide}
+-- {: .toc .clickDown tabindex="0"}
###Context###
#### Higher geometry
+--{: .hide}
[[!include higher geometry - contents]]
=--
#### Monoidal categories
+--{: .hide}
[[!include monoidal categories - contents]]
=--
=--
=--

#Contents#
* table of contents
{:toc}

## Idea

Where in [[algebraic geometry]] one considers [[spaces]] which are [[Isbell duality|formally dual]] to [[commutative rings]], in "2-algebraic geometry" one considers spaces formally dual to _[[2-rigs]]_, namely to certain [[tensor categories]] or more generally to [[tensor (∞,1)-categories]].

Curiously, the more general idea of regarding certain [[abelian categories]] and certain linear [[A-∞ categories]] ([[stable (∞,1)-categories]]) as analogs of categories of [[quasicoherent sheaves]] on some space (i.e. ignoring the monoidal structure) is much older, this is the program of [[derived noncommutative geometry]], see also at [derived algebraic geometry -- Relation to noncommutative geometry](derived+algebraic+geometry#RelationToDerivedNoncommutativeGeometry).

The systematic use of the tensor product structure here goes back to ([Balmer 02](#Balmer02)) and the concept of the [[spectrum of a tensor triangulated category]]. In ([Lurie](#Lurie)) the concept of "2-[[affine scheme]]" is studied more systematically. Then ([CJF 11](#CJF11)) introduce the terminology of "2-algebraic geometry".

## Related concepts

* [[spectrum of a tensor triangulated category]]

* [[spectrum of a symmetric monoidal (∞,1)-category]]

## References

* {#Balmer02} [[Paul Balmer]], _Presheaves of triangulated categories and reconstruction of schemes_, Mathematische Annalen __324__:3 (2002), 557-580 [dvi](http://www.math.ucla.edu/~balmer/Pubfile/Reconstr.dvi), [pdf](http://www.math.ucla.edu/~balmer/Pubfile/Reconstr.pdf) [ps](http://www.math.ucla.edu/~balmer/Pubfile/Reconstr.ps); _The spectrum of prime ideals in tensor triangulated categories_, J. Reine Angew. Math. __588__:149–168, 2005 [dvi](http://www.math.ucla.edu/~balmer/Pubfile/Spectrum.dvi) [pdf](http://www.math.ucla.edu/~balmer/Pubfile/Spectrum.pdf) [ps](http://www.math.ucla.edu/~balmer/Pubfile/Spectrum.ps); _Spectra, spectra, spectra - Tensor triangular spectra versus Zariski spectra of endomorphism rings_, Alg. and Geom. Topology __10__:3 (2010) 1521-1563 [dvi](http://www.math.ucla.edu/~balmer/Pubfile/SSS.dvi) [pdf](http://www.math.ucla.edu/~balmer/Pubfile/SSS.pdf) [ps](http://www.math.ucla.edu/~balmer/Pubfile/SSS.ps)

* {#Lurie} [[Jacob Lurie]], _[[Tannaka duality for geometric stacks]]_.

* {#CJF11} [[Alexandru Chirvasitu]], [[Theo Johnson-Freyd]], _The fundamental pro-groupoid of an affine 2-scheme_, Applied Categorical Structures, Vol 21, Issue 5 (2013), pp. 469–522. ([DOI](http://dx.doi.org/10.1007/s10485-011-9275-y), [arXiv:1105.3104](http://arxiv.org/abs/1105.3104))

* {#Brandenburg14} [[Martin Brandenburg]], _Tensor categorical foundations of algebraic geometry_ ([arXiv:1410.1716](http://arxiv.org/abs/1410.1716))


2-categorical limit > history

< [[2-categorical limit]]
[[!redirects 2-categorical limit -- history]]


2-category

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

# Contents
* table of contents
{:toc}

## Idea

The notion of a _2-category_ generalizes that of [[category]]: a 2-category is a [[higher category theory|higher category]], where on top of the objects and morphisms, there are also 2-morphisms. In old texts, strict 2-categories are occasionally called _hypercategories_.

A 2-category consists of

* [[objects]];

* 1-[[morphisms]] between objects;

* [[2-morphisms]] between morphisms.

The morphisms can be [[composition|composed]] along the objects, while the 2-morphisms can be composed in two different directions: along objects -- called [[horizontal composition]] -- and along morphisms -- called [[vertical composition]].  The composition of morphisms is allowed to be associative only up to [[coherent]] [[associator]] 2-morphisms.

2-categories are also a [[horizontal categorification]] of [[monoidal categories]]: they are like monoidal categories with many objects.

2-categories provide the context for discussing

* [[adjunction]]s;

* [[monad]]s.

The concept of 2-category generalizes further in [[higher category theory]] to [[n-categories]], which have [[k-morphism]]s for all $k\le n$.

2-categories form a [[3-category]], [[2Cat]].

## Definitions

### Strict 2-categories

The easiest definition of 2-category is that it is a category [[enriched category|enriched]] over the [[cartesian monoidal category]] [[Cat]].  Thus it has a collection of objects,. and for each pair of objects a category $hom(x,y)$.  The objects of these hom-categories are the morphisms, and the morphisms of these hom-categories are the 2-morphisms.  This produces the classical notion of [[strict 2-category]].

### General 2-categories
 {#Weak}

For some purposes, strict 2-categories are too strict: one would like to allow composition of morphisms to be associative and unital only up to coherent invertible 2-morphisms.  A direct generalization of the above "enriched" definition produces the classical notion of [[bicategory]].

One can also obtain notions of 2-category by specialization from the case of higher categories.  Specifically, if we fix a meaning of $\infty$-[[infinity-category|category]], however weak or strict we wish, then we can define a __$2$-category__ to be an $\infty$-category such that every 3-morphism is an [[equivalence]], and all parallel pairs of $j$-morphisms are equivalent for $j \geq 3$.  It follows that, up to equivalence, there is no point in mentioning anything beyond $2$-morphisms, except whether two given parallel $2$-morphisms are equivalent.  In some models of $\infty$-categories, it is possible to make this precise by demanding that all parallel pairs of $j$-morphisms are actually *equal* for $j\geq 3$, producing a simpler notion of 2-category in which we can speak about [[equality]] of 2-morphisms instead of equivalence.  (This is the case for both strict $2$-categories and bicategories.)

All of the above definitions produce "equivalent" theories of 2-category, although in some cases (such as the fact that every bicategory is equivalent to a strict 2-category) this requires some work to prove.  On the nLab, we often use the word "2-category" in the general sense of referring to whatever model one may prefer, but usually one in which composition is weak; a [[bicategory]] is an adequate definition.  One should beware, however, that in the literature it is common for "2-category" to refer only to *strict* 2-categories.

A 2-category in which all 1-morphisms and 2-morphisms are invertible is a [[2-groupoid]].

## Examples

* The archetypical 2-category is [[Cat]], the 2-category whose

  * objects are [[categories]];

  * morphisms are [[functor]]s;

  * 2-morphisms are [[natural transformation]];

    horizontal composition of 2-morphisms is the [[Godement product]].

  This happens to be a [[strict 2-category]].

* More generally, for $V$ any enriching category (such as a Benabou [[cosmos]]), there is a 2-category $V Cat$ whose

  * objects are $V$-[[enriched categories]];
  * morphisms are $V$-enriched functors; and
  * 2-morphisms are $V$-natural transformations.

* On the other hand, for any such $V$ we also have a [[bicategory]] $V$-[[Prof]] whose

  * objects are $V$-[[enriched categories]];
  * morphisms are $V$-[[profunctor]]s; and
  * 2-morphisms are natural transformations between these.

* If $C$ is a category with [[pullbacks]], then there is a bicategory [[Span]]$(C)$ whose

  * objects are the objects of $C$;
  * morphisms are [[spans]] in $C$; and
  * 2-morphisms are morphisms of spans.

* Every [[monoidal category]] $C$ may be thought of as a [[bicategory]] $\mathbf{B}C$ (its [[delooping]]). This has

  * a single object $\bullet$;

  * morphisms are the objects of $C$: $(\mathbf{B}C)_1 = C_0$;

  * 2-morphisms are the morphisms of $C$ : $(\mathbf{B}C)_2 = C_1$;

  [[horizontal composition]] in $\mathbf{B}C$ is the [[tensor product]] in $C$ and [[vertical composition]] in $\mathbf{B}C$ is composition in $C$.

  Conversely, every 2-category with a single object comes from a monoidal category this way, so the concepts are effectively equivalent. (Precisely: the 2-category of  _pointed_ 2-categories with a single object is equivalent to that of monoidal categories).  For more on this relation see [[delooping hypothesis]], [[k-tuply monoidal n-category]], and [[periodic table]].

* Every [[2-groupoid]] is a 2-category. For instance

  * for $A$ any [[abelian group]], the double [[delooping]] $\mathbf{B}^2 A$ is the strict 2-category with a single object, a single 1-morphisms, set of 2-moprhisms being $A$ and both horizontal composition as well as [[vertical composition]] being the product in $A$.

  * for $G$ any [[2-group]], its single [[delooping]] is a 2-groupoid with a single object.

* Every [[topological space]] has a [[path 2-groupoid]].

* Every [[(∞,2)-category]] has a **homotopy 2-category**, obtained by dividing out all 3-morphisms and higher.

## Properties

### Double nerve

An ordinary  [[category]] has a [[nerve]] which is a [[simplicial set]]. For 2-categories one may consider their [[double nerve]] which is a [[bisimplicial set]].

There is also a 2-nerve. ([LackPaoli](#LackPaoli))

(...)

### Model category structure {#ModelCategoryStructure}

There is a [[model category]] structure on 2-categories -- sometimes known as the [[folk model structure]] -- that models the [[(2,1)-category]] underlying [[2Cat]] ([Lack](#LackFolkModel)).

For strict 2-categories this is the restriction of the corresponding [[folk model structure]] on [[strict omega-categories]].

* The weak equivalences are the [[2-functor]]s that are equivalences of 2-categories.

* The acyclic fibrations are the [[k-surjective functor]]s for all $k$.

#### Free resolutions {#FreeResolution}

**Theorem** A strict 2-category $C$ is cofibrant precisely if the underlying 1-category $C_1$ is a [[free category]].

This is theorem 4.8 in ([LackStrict](#LackStrict)). This is a special case of the more general statement that free strict $\omega$-categories are given by [[computad]]s.

**Example (free resolution of a 1-category).** Let $C$ be an ordinary category (a 1-category) regarded as a strict 2-category. Then the cofibrant resolution $\hat C \stackrel{\simeq}{\to} C$ is the strict 2-category given as follows:

* the objects of $\hat C$ are those of $C$;

* the morphisms of $\hat C$ are finite sequences of composable morphisms of $C$, and composition is concatenation of such sequences

  (hence $(\hat C)_1$ is the [[free category]] on the [[quiver]] underlying $C$);

* the 2-morphisms of $\hat C$ are _generated_ from 2-morphisms $c_{f,g}$ of the form

  $$
    \array{
       && y
       \\
       & {}^{\mathllap{f}}\nearrow &\Downarrow^{c_{f,g}}& \searrow^{\mathrlap{g}}
       \\
       x && \underset{g \circ_C f }{\to} && z
    }
  $$

  and their formal inverses

  $$
    \array{
       && y
       \\
       & {}^{\mathllap{f}}\nearrow &\Uparrow^{c_{f,g}^{-1}}& \searrow^{\mathrlap{g}}
       \\
       x && \underset{g \circ_C f }{\to} && z
    }
  $$

  for all composable $f,g \in Mor(C)$ with composite (in $C$!) $g \circ_C f$;

  subject to the _relation_ that for all composable triples $f,g,h \in Mor(C)$
  the following equation of 2-morphisms holds

  $$
    \array{
       y &\to& &\stackrel{g}{\to}& &\to& && z
       \\
       \uparrow &\seArrow^{c_{f,g}}& && & \nearrow & && \downarrow
       \\
       {}^{\mathllap{f}}\uparrow &&  & \nearrow & &&&& \downarrow^{\mathrlap{h}}
       \\
       \uparrow & \nearrow & && &\Downarrow^{c_{h,(g\circ_C f)}}& && \downarrow
       \\
       x &\to& &\underset{h \circ (g \circ_C f)}{\to}& &\to& &\to& w
    }
    \;\;\;
    =
    \;\;\;
        \array{
       y &\to& &\stackrel{g}{\to}& &\to& && z
       \\
       \uparrow &\searrow& && & & &\swArrow_{c_{g,h}}& \downarrow
       \\
       {}^{\mathllap{f}}\uparrow &&  & \searrow & &&&& \downarrow^{\mathrlap{h}}
       \\
       \uparrow &\Downarrow_{c_{f,(g \circ_C h)}}& && &\searrow& && \downarrow
       \\
       x &\to& &\underset{( h \circ_C g) \circ f}{\to}& &\to& &\to& w
    }
  $$

**Observation** Let $D$ be any strict 2-catgeory. Then a [[pseudofunctor]] $C \to D$ is the same as a strict 2-functor $\hat C \to D$.

## 2-categorical concepts

**constructions**

* [[opposite 2-category]]

**extra properties**

* [[regular 2-category]]
* [[exact 2-category]]
* [[coherent 2-category]]
* [[extensive 2-category]]
* [[2-pretopos]]
* [[2-topos]]

**types of morphisms**

* [[subcategory]]
* [[faithful morphism]]
* [[fully faithful morphism]]
* [[conservative morphism]]
* [[pseudomonic morphism]]
* [[discrete morphism]]

**specific versions**

* globular [[strict 2-category]]
* [[bicategory]]

**limit notions**

* [[2-limit]]
* [[strict 2-limit]]
* [[flexible limit]]
* [[PIE limit]]

**model structures**

* [[canonical model structure]]
* [[2-trivial model structure]]

## Related concepts

* [[0-category]], [[(0,1)-category]]

* [[category]]

* **2-category**

  [[equivalence in a 2-category]]

  [[localization of a 2-category]]

  [[2-type theory]], [[directed type theory]]

* [[3-category]]

* [[n-category]]

* [[(∞,0)-category]]

* [[(∞,1)-category]]

* [[(∞,2)-category]]

* [[(∞,n)-category]]

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

* [[double category]]

## References
 {#References}

Despite its being frequently attributed to Ehresmann, the notion of [[strict 2-categories]] is due to:

* {#Bénabou65} [[Jean Bénabou]], Example (5) of: *Catégories relatives*, C. R. Acad. Sci. Paris **260** (1965) 3824-3827 [[gallica](https://gallica.bnf.fr/ark:/12148/bpt6k4019v/f37.item)]

  > (conceived as [[Cat]]-[[enriched categories]] and called *2-categories*)

* {#Maranda65} [[Jean-Marie Maranda]], Def. 1 in: *Formal categories*, Canadian Journal of Mathematics **17** (1965) 758-801 [[doi:10.4153/CJM-1965-076-0](https://doi.org/10.4153/CJM-1965-076-0), [pdf](https://www.cambridge.org/core/services/aop-cambridge-core/content/view/A7C463460EB8CAC64C2CA340F870CF80/S0008414X00039729a.pdf/formal-categories.pdf)]

  > (conceived as [[Cat]]-[[enriched categories]] and called *categories of the second type*)

both apparently following or inspired by the earlier definition of *[[double categories]]* due to

* [[Charles Ehresmann]], *Catégories double et catégories structurées*, C.R. Acad. Paris 256 (1963) 1198-1201 [[[Ehresmann-CategoriesDoubles.pdf:file]], [gallica](https://gallica.bnf.fr/ark:/12148/bpt6k3208j/f1246)]

An early definition also appears in the following, where it is mistakenly attributed to [[Charles Ehresmann]]:

* {#EK65} [[Samuel Eilenberg]], [[G. Max Kelly]], *Closed Categories*, p. 425  in:  [[Samuel Eilenberg|S. Eilenberg]], [[D. K. Harrison]], [[S. MacLane]], [[H. Röhrl]] (eds.): *[[Proceedings of the Conference on Categorical Algebra - La Jolla 1965]]*, Springer (1966) [[doi:10.1007/978-3-642-99902-4](https://doi.org/10.1007/978-3-642-99902-4)]

  > (expressed entirely in components, under the name *hypercategories*)

The fundamental structure of the [[2-category of categories]] (namely the [[vertical composition]], [[horizontal composition]] and the [[whiskering]] of [[natural transformations]]) was first described in:

* {#Godement58} [[Roger Godement]], Appendix (pp. 269) of: *Topologie algébrique et theorie des faisceaux*, Actualités Sci. Ind. **1252**, Hermann, Paris (1958) [[webpage](https://www.editions-hermann.fr/livre/topologie-algebrique-et-theorie-des-faisceaux-roger-godement), [[Godement-TopologieAlgebrique.pdf:file]]]

Early discussion of the general notion of bicategories:

* {#Bénabou1967} [[Jean Bénabou]], *Introduction to Bicategories*, Lecture Notes in Mathematics **47** Springer (1967) 1-77 [[doi:10.1007/BFb0074299](http://dx.doi.org/10.1007/BFb0074299)]

Exposition and review:

* {#KellyStreet74} [[Max Kelly]], [[Ross Street]], *Review of the elements of 2-categories*, Sydney Category Seminar 1972/1973, in [[G. Max Kelly]] (ed.) Lecture Notes in Mathematics **420**, Springer (1974) [[doi:10.1007/BFb0063101](https://doi.org/10.1007/BFb0063101)]

* {#Street96}  [[Ross Street]], *Categorical Structures*, in Handbook of Algebra Vol. 1 (ed. M. Hazewinkel), Elsevier Science, Amsterdam (1996) [doi:10.1016/S1570-7954(96)80019-2, [pdf](http://maths.mq.edu.au/~street/45.pdf), [[Street-CategoricalStructures.pdf:file]], [ISBN:978-0-444-82212-3](https://shop.elsevier.com/books/handbook-of-algebra/hazewinkel/978-0-444-82212-3)]

* [[Ross Street]], _Encyclopedia article on 2-categories and bicategories_ ([pdf](http://www.maths.mq.edu.au/~street/Encyclopedia.pdf))

* [[Tom Leinster]], _Basic bicategories_ ([arXiv:9810017](http://arxiv.org/abs/math/9810017))

* {#Lack10} [[Steve Lack]], _A 2-categories companion_,  In: Baez J., May J. (eds.) *[[Towards Higher Categories]]*. The IMA Volumes in Mathematics and its Applications, vol 152. Springer 2010 ([arXiv:math.CT/0702535](http://arxiv.org/abs/math.CT/0702535), [doi:10.1007/978-1-4419-1524-5_4](https://doi.org/10.1007/978-1-4419-1524-5_4))

  > (including discussion of ([[strict 2-limits|strict]]) [[2-limits]])

* [[John Power]], _2-Categories_, BRICS Notes Series 1998 ([pdf](http://www.brics.dk/NS/98/7/BRICS-NS-98-7.pdf))

Comprehensive textbook accounts:

* [[Ofer Gabber]], [[Lorenzo Ramero]], Chapter 2 of: *Foundations for almost ring theory* ([arXiv:math/0409584](https://arxiv.org/abs/math/0409584))

* {#JohnsonYau20} [[Niles Johnson]], [[Donald Yau]], *2-Dimensional Categories*, Oxford University Press (2021) [[arXiv:2002.06055](http://arxiv.org/abs/2002.06055), [doi:10.1093/oso/9780198871378.001.0001](https://oxford.universitypressscholarship.com/view/10.1093/oso/9780198871378.001.0001/oso-9780198871378)]

On [[coherence theorems]]:

* {#Power89} [[A. John Power]],  _A general coherence result._ J. Pure Appl. Algebra 57 (1989), no. 2, 165–173. [doi:10.1016/0022-4049(89)90113-8](http://dx.doi.org/10.1016/0022-4049%2889%2990113-8) [MR0985657](http://www.ams.org/mathscinet-getitem?mr=985657)

Relation between bicategories and Tamsamani weak 2-categories:

* {#LackPaoli} [[Steve Lack]], [[Simona Paoli]], _2-nerves for bicategories_ ([arXiv](http://arxiv.org/abs/math/0607271))

* [[Simona Paoli]], _From Tamsamani weak 2-categories to bicategories_ ([arXiv](http://www.maths.mq.edu.au/~simonap/Bicategories_Rev_4.pdf))

There is a [[model category]] structure on 2-categories -- the [[canonical model structure]] -- that models the [[(2,1)-category]] underlying [[2Cat]]:

* {#LackStrict} [[Steve Lack]],  _A Quillen Model Structure for 2-Categories_, K-Theory 26: 171–205, 2002. ([website](http://www.maths.usyd.edu.au/u/stevel/papers/qmc2cat.html))

* {#LackFolkModel} [[Steve Lack]],  _A Quillen Model Structure for Biategories_, K-Theory 33: 185-197, 2004. ([website](http://www.maths.usyd.edu.au/u/stevel/papers/qmcbicat.html))

Discussion of weak 2-categories in the style of [[A-infinity categories]] is (using [[dendroidal sets]] to model the higher [[operads]]) in

* Andor Lucacs, _Dendroidal weak 2-categories_ ([arXiv:1304.4278](http://de.arxiv.org/abs/1304.4278))

* Jonathan Chiche, _La théorie de l'homotopie des 2-catégories_, thesis, [arXiv](http://arxiv.org/abs/1411.6936).

[[!redirects 2-category]]
[[!redirects 2-categories]]
[[!redirects weak 2-category]]
[[!redirects weak 2-categories]]
[[!redirects hypercategory]]
[[!redirects hypercategories]]
[[!redirects 2-categorical]]


2-category equipped with proarrows

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

# Contents
* automatic table of contents goes here
{: toc}

## Idea

A **2-category equipped with proarrows**, also called a *proarrow equipment* or simply an *equipment*, is a [[2-category]] together with extra "proarrows" which enable one to reproduce more category theory inside it than is possible in a general 2-category.  The ur-example is [[Cat]] equipped with [[profunctors]].

See also [[framed bicategory]].

## Motivation

Just as ordinary [[category theory]] provides a framework in which one can do "formal mathematics," one of the (many) purposes of [[higher category theory]] is to provide a framework in which one can do [[formal category theory]]. In particular, many concepts in ordinary category theory can be interpreted internally in a [[2-category]], in a way which specializes to the original concept in [[Cat]].  Examples of such concepts include [[adjunctions]], [[monads]], [[Grothendieck fibrations]], [[Kan extensions]], and [[fully faithful morphisms]].

However, these internalizations are not always "correct" in every 2-category.  For instance, in the 2-category $V Cat$ of [[enriched categories|categories enriched]] in a [[monoidal category]] $V$, internal adjunctions and monads give the correct notion of $V$-adjunction and $V$-monad, but internal fully-faithfulness for a $V$-functor is weaker than the "correct" notion of $V$-fully-faithfulness.  More technically, in many cases the naive notion of Kan extension is not sufficient and one needs "pointwise" Kan extensions; with some more work these can also be defined in a 2-category, but the resulting notion (though correct in $Cat$) is not always correct in $V Cat$.

Furthermore, some concepts of category theory are difficult to interpret at all in a 2-category.  The notion of [[limit]] in ordinary category theory can be interpreted in a 2-category by identifying the limit of a functor $D\to C$ as its Kan extension along the unique functor $D\to *$.  However, in enriched category theory the more important notion is that of [[weighted limit]], and there is no straightforward way to interpret this in $V Cat$.

What is missing is that the 2-category $V Cat$ doesn't natively supply any information about the $V$-valued hom-functors in a 2-category.  (In $Cat$ these hom-functors can be recovered by looking at [[comma categories]], which can be interpreted internally as [[comma objects]]---in some sense this is what all the above internalizations are secretly doing.)  Thus, all of these problems can be remedied by equipping a 2-category with extra structure which describes these hom-functors, or more generally describes a notion of [[profunctor]].

There are several not-quite-equivalent ways to describe this extra structure.  One due to Street and Walters, called a [[Yoneda structure]], involves assigning to each object $A$ a "presheaf object" $P A$ and a "Yoneda arrow" $A\to P A$; a profunctor $A\to B$ is then identified with an arrow $B \to P A$.  The notion of *proarrow equipment*, due to Wood, instead postulates an additional bicategory of "proarrows" and specifies their relationship to the ordinary arrows.  One can then define fully faithful morphisms, pointwise Kan extensions, weighted limits, etc. relative to this structure, in a way which specializes to the correct notions in $V Cat$.

## Definitions {#Definitions}

There are several equivalent ways to define proarrow equipments on a 2-category.

### Definition as a 2-functor {#DefinitionAsA2Functor}

Let $K$ be a [[2-category]].  The following structure is said to **equip $K$ with proarrows**.

* A 2-category $M$, whose arrows are called *proarrows*.
* A functor $K\to M$ which is [[bijective-on-objects functor|bijective on objects]] and [[locally fully faithful 2-functor|locally fully faithful]].  If $f\colon A\to B$ is a 1-morphism in $K$, we write its image in $M$ as $B(1,f)\colon A\nrightarrow B$.
* For each arrow $f\colon A\to B$ in $K$, the proarrow $B(1,f)\colon A\to B$ has a [[right adjoint]] in $M$, which we write as $B(f,1)$.

As usual on the nLab, here by [[2-category]] we mean a weak 2-category (aka [[bicategory]]) and by [[functor]] we mean a weak 2-functor (aka [[pseudofunctor]]).  However, in many or most examples, $K$ is in fact a [[strict 2-category]].

For a proarrow $H\colon B\to D$ and ordinary arrows $f\colon A\to B$ and $g\colon C\to D$, we write $H(g,f)$ for the composite $D(g,1) \circ  H \circ B(1,f)$; it is a proarrow from $A$ to $C$.  We also write $U_A$, $A(1,1)$, or simply $A$ for the identity proarrow $A\nrightarrow A$.

Note that in the case where proarrows are profunctors, $H(g, f)$ is not the action on a set of [[heteromorphisms]] by pre- and post- composing with morphisms; instead it is the functor $f$, followed by the profunctor $H$, followed by taking the preimage under the functor $g$, resulting in a profunctor from $A$ to $C$.

#### Terminology

We refer to the entire structure defined above as a **2-category equipped with proarrows** or a **2-category proarrow equipment**.  Those working in the field often use the term **proarrow equipment** or simply **equipment** for the entire structure.  We prefer "2-category equipped with proarrows" (or, equivalently, "pro-morphisms") for the following reasons:

* It conveys that we are talking about extra stuff added to a 2-category.  (Actually, it is "eka-stuff" or "2-stuff" in the sense of [stuff, structure, property](http://ncatlab.org/nlab/show/stuff,+structure,+property).)
* It includes the word "proarrow" which tells people what the extra stuff consists of, namely a generalization of [[profunctors]].
* It includes the word "equipment" which signals what is meant to readers who are familiar with that term.

We do sometimes avail ourselves of the shorter terminology "proarrow equipment," however, once we are clear what is under discussion.

#### Examples

For example, if $V$ is a (Benabou) [[cosmos]], the 2-category $K= V Cat$ of $V$-enriched categories is equipped with proarrows by the 2-category $M=V Mod$ of $V$-enriched profunctors, where $B(1,f)$ and $B(f,1)$ are the two ways of regarding a $V$-functor $f:A\to B$ as a profunctor, namely $B(-,f-)$ and $B(f-,-)$ (hence the notation in the general case).  Composition of $V$-profunctors is by [[tensor product]], i.e. [[coends]]; note that we require $V$ to be [[cocomplete category|cocomplete]] with colimits preserved by $\otimes$ on both sides in order to form such associative tensor products.  In $V Cat$, $H(g,f)$ is the result of precomposing the profunctor $H:D^{op}\otimes B \to V$ with $g^{op}\otimes f$.

The other most common sorts of generalized category, such as [[internal categories]] in some category with pullbacks, and [[fibered categories]] over some base, are also naturally equipped with proarrows.  For internal categories in $S$, we require $S$ to have finite limits and coequalizers preserved by pullback in order for the bicategory of internal profunctors to have associative compositions.  (See "virtual equipments," below, for a context which avoids some of these restrictions on $V$ and $S$.)

### Definition as a double category {#DefinitionAsDoubleCategory}

We discuss now how a 2-category with proarrow equipment is equivalently a [[double category]] with extra structure.

Given a 2-category $K$ equipped with proarrows, we can construct a [[double category]] having the same objects as $K$, whose vertical 1-cells are the arrows, whose horizontal 1-cells are the proarrows, and whose squares
$$\array{A & \overset{H}{\to} & C \\
  ^f\downarrow & \Downarrow & \downarrow^g\\
  B& \underset{J}{\to} & D}
$$
are the 2-cells $H \to J(g,f)$.  Note that if $K$ is a strict 2-category, then this is a [[pseudo double category]] (vertically strict and horizontally weak) while if $K$ and $M$ are both weak 2-categories, this double category is weak in both directions (like a [[double bicategory]]).

In $V Cat$, for example, the squares of the above form are transformations $H(b,a) \to J(g b,f a)$ natural in $a$ and $b$.  Arguably, this double category is a more fundamental and natural object than the 2-functor $V Cat \to V Prof$.  More generally, if $K$ is any 2-category equipped with proarrows, we can reconstruct $K$ and its proarrow equipment from the double category defined above, and we can characterize the double categories that arise in this way.

One way to state this characterization is that they are those in which every vertical 1-cell $f\colon A\to B$ has both a [[companion]] (namely $B(1,f)$) and a [[conjoint]] (namely $B(f,1)$).  One can then recover $K$ and $M$ as the
[[vertical 2-category|vertical and horizontal 2-categories]], respectively, and the 2-functor $K\to M$ as the functor taking every vertical arrow to its companion.  Whenever a vertical arrow has both a companion $B(1,f)$ and a conjoint $B(f,1)$, we automatically have an adjunction $B(1,f)\dashv B(f,1)$, so this defines a proarrow equipment in the first sense.

Another, perhaps even more natural, way to characterize these double categories is as those with the following property: given any "niche"

$$\array{A & & B\\
  ^f\downarrow & & \downarrow^g\\
  C& \underset{J}{\nrightarrow} & D}
$$
there exists a "universal" or "cartesian" filler square
$$
\array{A & \overset{J(g,f)}{\to} & B\\
  ^f\downarrow & \Downarrow & \downarrow^g\\
  C& \underset{J}{\nrightarrow} & D}
$$
with the property that any other square
$$
  \array{X & \nrightarrow & Y\\
  ^{f h}\downarrow & \Downarrow & \downarrow^{g k}\\
  C& \underset{J}{\nrightarrow} & D}
$$
factors through the universal one uniquely:
$$
 \array{X & \nrightarrow & Y\\
  ^{h}\downarrow & \exists! \Downarrow  & \downarrow^{k}\\
  A & \overset{J(g,f)}{\to} & B\\
  ^f\downarrow & \Downarrow & \downarrow^g\\
  C& \underset{J}{\nrightarrow} & D}
$$
The profunctor $J(g,f)$ will, of course, turn out to be the same one we gave that name to earlier.  The proarrows $B(1,f)=U_B(id_B,f)$ and $B(f,1) = U_B(f,id_B)$ are then a special case of this construction.  We show that they are a companion and conjoint of $f$, respectively, as follows.

By factoring the identity square
$$\array{A & \overset{U_A}{\to} & A\\
  ^f\downarrow & ^{U_f}\Downarrow & \downarrow^f\\
  B  & \underset{U_B}{\to} & B}$$
through the universal fillers
$$\array{A & \overset{B(1,f)}{\to} & B\\
  ^f\downarrow &\Downarrow & \downarrow^{id}\\
  B & \underset{U_B}{\to} & B} \qquad\text{and}\qquad
\array{B & \overset{B(f,1)}{\to} & A\\
  ^{id}\downarrow &\Downarrow & \downarrow^{f}\\
  B & \underset{U_B}{\to} & B}
  $$
that define $B(1,f)$ and $B(f,1)$, we obtain additional squares
$$\array{A & \overset{U_A}{\to} & A\\
  ^f\downarrow &\Downarrow & \downarrow^{id}\\
  B & \underset{B(f,1)}{\to} & A} \qquad\text{and}\qquad
\array{A & \overset{U_A}{\to} & A\\
  ^{id}\downarrow &\Downarrow & \downarrow^{f}\\
  A & \underset{B(1,f)}{\to} & B}
  $$
such that the composites
$$\array{A & \overset{U_A}{\to} & A\\
  ^{f}\downarrow &\Downarrow & \downarrow^{id}\\
  B & \overset{B(f,1)}{\to} & A\\
  ^{id}\downarrow &\Downarrow & \downarrow^{f}\\
  B & \underset{U_B}{\to} & B} \qquad\text{and}\quad
\array{A & \overset{U_A}{\to} & A\\
  ^{id}\downarrow &\Downarrow & \downarrow^{f}\\
  A & \underset{B(1,f)}{\to} & B\\
  ^f\downarrow &\Downarrow & \downarrow^{id}\\
  B & \underset{U_B}{\to} & B}
$$
are both equal to $U_f$.  And using the uniqueness of factorization through the universal squares, we can conclude moreover that the composites
$$\array{A & \overset{U_A}{\to} & A & \overset{B(1,f)}{\to} & A\\
  ^{id}\downarrow &\Downarrow & \downarrow^{f} & \Downarrow & \downarrow^{id}\\
  A & \underset{B(1,f)}{\to} & B & \underset{U_B}{\to} & B}
\qquad\text{and}\qquad
\array{B & \overset{B(f,1)}{\to} & A & \overset{U_A}{\to} & A\\
  ^{id}\downarrow &\Downarrow & \downarrow^{f} & \Downarrow & \downarrow^{id}\\
  B & \underset{U_B}{\to} & B & \underset{B(f,1)}{\to} & A}
$$
are equal to the identity squares of $B(1,f)$ and $B(f,1)$ respectively.  These are the defining equations of a companion and a conjoint.

Finally, we record the following.

+-- {: .num_lemma}
###### Central Lemma
There is a natural bijection between squares of the form
$$\array{A_0 & \overset{H}{\to} & B_0\\
  ^{f_1}\downarrow && \downarrow^{g_1}\\
  A_1 && B_1\\
  ^{f_2}\downarrow & \Downarrow & \downarrow^{g_2}\\
  A_2 && B_2\\
  ^{f_3}\downarrow && \downarrow^{g_3}\\
  A_3 & \underset{J}{\to} & B_3 }
$$
and squares of the form
$$\array{A_1 & \overset{A_1(f_1 ,1)}{\to} & A_0 & \overset{H}{\to} & B_0 & \overset{B_1(1,g_1)}{\to} & B_1\\
  ^{f_2}\downarrow && &\Downarrow & && \downarrow^{g_2}\\
  A_2 & \underset{A_3(1,f_3)}{\to} & A_3 & \underset{J}{\to} & B_3 & \underset{B_3(g_3 ,1)}{\to} & B_2.}
$$

=--

One way to think of this is as saying that vertical arrows can be "slid around corners" to become horizontal arrows, turning them into the "representable proarrows" $B(1,f)$ or $B(f,1)$ (depending on whether you slid them "backwards" or "forwards" to get around the corner).  The bijection is just given by composing with the four special squares in the definition of companions and conjoints.  In particular, by a Yoneda argument, for any $f\colon A\to C$, $g\colon B\to D$, and $J\colon C\nrightarrow D$ we have
\[J(g,f) \cong C(1,f) \odot J \odot D(g,1) \label{coyon} \]
which was what we took as the the definition of $J(g,f)$ with the original definition of proarrow equipment.  Thus, the companions and conjoints determine the rest of the cartesian squares.  Note that this is an equipment-version of [Yoneda reduction](http://ncatlab.org/nlab/show/Yoneda+reduction).

In conclusion, we have three definitions of proarrow equipment:

* A 2-functor which is bijective on objects, locally fully faithful, and maps every 1-morphism to one having a right adjoint.
* A double category in which every vertical arrow has a companion and a conjoint.
* A double category in which every niche has a cartesian filler.

While the first definition is perhaps simpler, for some purposes the second and third definitions are preferable.  For instance, the definition of the 3-category of "2-categories equipped with proarrows" is much more naturally defined by viewing them as double categories.  (See Dominic Verity's thesis and Mike Shulman's paper on framed bicategories.)  It also generalizes better to situations in which not all proarrows have composites; see "virtual equipments," below.

### As a category internal to $Cat$

We discuss how a 2-category with proarrow equipment is an [[internal category]] in the [[(2,1)-category]] [[Cat]] in the sense of the theory of _[[internal (∞,1)-categories]]_.

(...)

For the moment see at _[Segal space - Examples - In 1Grpd](http://ncatlab.org/nlab/show/Segal%20space#ExamplesInIGrpd)_.

### Related notions

There are a number of variations on the notion.

* [[virtual proarrow equipment]]
* [[1-category proarrow equipment]]
* [[(1,2)-category proarrow equipment]]

Some related concepts include:

* [[cartesian bicategory]]
* [[bicategory of relations]]
* [[allegory]]

See also at [[Segal space]], the section _[Examples -- In 1Grpd](Segal+space#ExamplesInIGrpd)_.

## Category theory in a proarrow equipment

We now give a few examples of how to do category theory internal to a proarrow equipment.

### Homset definition of adjunctions {#HomsetAdjn}

We start with this: two (vertical) arrows $f\colon A\to B$ and $g\colon B\to A$ are adjoint (in $\mathcal{V}(\underline{X})$) if and only if we have an isomorphism $B(f,1)\cong A(1,g)$.  Why?  Well, an adjunction $f\dashv g$ comes with a unit and a counit, which (expressed in $\underline{X}$) are of the form
$$\array{A & \overset{U_A}{\to} & A\\
  ^f\downarrow && \downarrow\\
  B & \overset{\eta}{\Leftarrow} & \downarrow^{id} \\
  ^g\downarrow && \downarrow\\
  A& \underset{U_A}{\to} & A} \qquad\text{and}\qquad
\array{B & \overset{U_B}{\to} & B\\
  \downarrow && \downarrow^g\\
  ^{id}\downarrow & \overset{\varepsilon}{\Leftarrow} & A \\
  \downarrow && \downarrow^f\\
  B& \underset{U_B}{\to} & B.}
$$
Applying the bijection of the Central Lemma, we see that $\eta$ corresponds to a map $B(f,1) \to A(1,g)$, and likewise $\varepsilon$ corresponds to a map $A(1,g)\to B(f,1)$.  The triangle identities for $\eta$ and $\varepsilon$ are then equivalent to saying that these two maps are inverse isomorphisms.  So we've recovered the classical equivalence between the "diagrammatic" and isomorphism-of-hom-sets definitions of an adjunction, in a purely formal way.

### Fully faithful arrows

An arrow $f:A\to B$ in a 2-category equipped with proarrows is said to be **fully faithful** if the canonical morphism $U_A\to B(f,f)$ is an isomorphism of proarrows $A\to A$.  In $V Cat$ this recaptures the correct notion of $V$-fully-faithful $V$-functor.

It is not hard to see, using the fact that $K\to M$ is locally fully faithful, that any fully-faithful arrow $f\colon A\to B$ is, in fact, internally fully-faithful in $K$ in the sense that $K(X,A)\to K(X,B)$ is fully faithful for all $X\in K$.  However, the converse fails in general.  But it is not hard to show that the two are equivalent if $f\colon A\to B$ has a left or right adjoint, using the above characterization of adjunctions.

### Limits

The notion of limit we end up in a 2-category equipped with proarrows with is actually more general than what you're probably used to, but this extra generality turns out to be useful.  Let $d\colon D\to C$ be an arrow and let $J\colon D\nrightarrow A$ be a proarrow; we're going to define what it means for an arrow $\ell\colon A\to C$ to be the *$J$-weighted limit* of $d$.  In the proarrow-equipped 2-category $V Cat$ of $V$-enriched categories, if $A$ is the [unit](http://ncatlab.org/nlab/show/unit+enriched+category) $V$-category $I$, then this will recover the usual notion of [weighted limit](http://ncatlab.org/nlab/show/weighted+limit).  Of course, in a general proarrow equipment we may not have a "unit object," so that extra generality is unavoidable; it's like using generalized elements in ordinary category theory.

To make things easier, let's assume that our proarrow equipment is *closed*, in the sense that composition of proarrows has adjoints in each variable
$$ \mathcal{H}(\underline{X})(H\odot K,L) \cong \mathcal{H}(\underline{X})(H,K\rhd L) \cong \mathcal{H}(\underline{X})(K,L\lhd H).$$
The Central Lemma implies that analogously to \eqref{coyon}, we have
\[K(g,f) \cong D(1,g)\rhd K \lhd C(f,1). \label{yon} \]
In $V\text{-}Prof$, the adjoints are given by the [ends](http://ncatlab.org/nlab/show/end)
$$ (K\rhd L)(b,a) = \int_{c\in C} [K(c,b), L(c,a)] $$
and
$$ (L \lhd H)(c,b) = \int_{a\in A} [H(b,a), L(c,a)]. $$
Therefore, \eqref{yon} is an abstract form of the Yoneda lemma, just as \eqref{coyon} is an abstract form of Yoneda reduction.

Now recall that for $V$-categories $D$ and $C$, an object $\ell\in C$ is a $J$-weighted limit of $d\colon D\to C$ if we have a natural isomorphism
$$
\begin{aligned}
C(c,\ell) &\cong [D,V](J, C(c,d(-)))\\
&= \int_{x\in D} [J(x), C(c,d(x))].
\end{aligned}
$$
Thus it makes sense to define, in a closed proarrow equipment, an arrow $\ell\colon A\to C$ to be the $J$-weighted limit of $d$ if we have an isomorphism
$$ C(1,\ell) \cong C(1,d) \lhd J. $$
(If our proarrow equipment is not closed, we simply assert that $C(1,\ell)$ has the universal property that $C(1,d) \lhd J$ would have if it existed.  In other terminology, we assert that $C(1,\ell)$ is a *right lifting* of $C(1,d)$ along $J$ in the 2-category of proarrows.)  In particular, when $A$ is the unit $V$-category, this recovers the classical notion.  But even in $V Cat$ there are interesting examples for other values of $A$.  If we take $J = D(j,1)$ for some functor $j\colon A\to D$, then \eqref{coyon} and \eqref{yon} imply that
$$
\begin{aligned}
C(1,d) \lhd J &= C(1,d) \lhd D(j,1)\\
& \cong j^* C(1,d)\\
& \cong D(1,j) \odot C(1,d)\\
& \cong C(1,d j)
\end{aligned}
$$
so that $\ell = d j$ is the $J$-weighted limit of $d$.  That is, $D(j,1)$-weighted limits are just given by composition with $j$.

More interestingly, one can show that if $J = D(1,k)$ for some $k\colon D\to A$, then $J$-weighted limits specialize to *pointwise* right Kan extensions along $k$.  That is, the extra data of a proarrow equipment lets us define the good notion of Kan extension (even in the enriched case) as a special case of a general notion of limit.  Thus, in a general 2-category equipped with proarrows, we *define* a "pointwise right Kan extension" along an arrow $k\colon D\to A$ to be a $D(1,k)$-weighted limit.  It is easy to show that any pointwise Kan extension is, in particular, an internal Kan extension in $K$, but as we have seen the converse fails in $V Cat$.

### Right adjoints preserve limits

Suppose that $\ell\colon A\to C$ is a $J$-weighted limit of $d\colon D\to C$ in the above sense, and let $g\colon C\to B$ be an arrow with a left adjoint $f\colon B\to C$.  We want to show that $g\ell$ is a $J$-weighted limit of $g d$.  But we have
$$
\begin{aligned}
B(1,g\ell) &\cong C(1,\ell) \odot B(1,g)\\
&\cong \big(C(1,d) \lhd J\big) \odot C(f,1)\\
&\cong C(1,f) \rhd \big(C(1,d) \lhd J\big)\\
&\cong \big(C(1,f) \rhd C(1,d)\big) \lhd J\\
&\cong \big(C(1,d) \odot C(f,1)\big) \lhd J\\
&\cong \big(C(1,d) \odot B(1,g)\big) \lhd J\\
&\cong B(1,g d) \lhd J.
\end{aligned}
$$
which is what we want.

## Graphs and cographs

As noted above, in the case of ordinary categories, the profunctors can in fact be recovered from the 2-category $Cat$.  Specifically, profunctors $A\to B$ can be identified with two-sided discrete fibrations from $B$ to $A$ (that is, spans $B \leftarrow C \to A$ such that $C \to B$ is a [[Grothendieck fibration|(Grothendieck) fibration]], $C\to A$ is an opfibration, the two structures are compatible, and each fiber of $C\to B\times A$ is discrete).  The two-sided fibration corresponding to a profunctor is also called its [[graph of a profunctor|graph]].  The same is true for internal categories, but not for enriched categories.

However the $V$-profunctors $A\to B$ *can* be recovered from the 2-category $V Cat$ in a different, and in fact dual, way: they are the two-sided [[codiscrete cofibrations]] from $B$ to $A$, i.e. two-sided discrete fibrations in $(V Cat)^{op}$.  The two-sided cofibration corresponding to a profunctor is, unsurprisingly, its [[cograph of a profunctor|cograph]], and also its [[collage]].  This was first noticed by Street and subsequently expanded on by other authors.  In particular, one can write down axioms on a 2-category guaranteeing that its codiscrete cofibrations can be used to equip it with proarrows, and axioms on a proarrow equipment guaranteeing that it arises from codiscrete cofibrations.

## Virtual equipments

One can formulate a generalized notion of equipment which includes $V Cat$ for _any_ monoidal category $V$ (and in fact, any [[multicategory]]), and $Cat(S)$ for any category $S$ with pullbacks.  The precise definition is complicated, but the basic idea is not: we start from the double-category definition, and instead of composites of the horizontal (pro)arrows, we allow the squares to have domains that are arbitrary composable strings, like so:
$$\array{ & \to \to \dots \to &\\
  \downarrow & \Downarrow & \downarrow\\
  & \underset{}{\to}& .}$$
So far this is analogous to the generalization from monoidal categories to multicategories, and gives the notion of [[virtual double category]].  We then impose a condition analogous to the existence of companions and conjoints to obtain the notion of [[virtual equipment]].  Most of category theory can be done in a virtual equipment just as well as in an equipment.

## Categories enriched in an equipment {#CategoriesEnrichedInAnEquipment}

For any equipment $W$ one can define a notion of **$W$-enriched category**.  (See also at _[[category enriched in a bicategory]]_.) This consists of

* a collection $ob(C)$ of objects,
* for each object $x$ an *extent* $e(x)$ which is an object of $W$,
* for each pair of objects $x,y$ a proarrow $hom_C(x,y):e(x)\to e(y)$,
* composition and identity-assigning 2-cells obeying associativity and unit axioms.

So far we have not used the ordinary arrows, so many authors have studied only the notion of "category enriched in a bicategory."  (Note that any 2-category $M$ can be regarded as the proarrow 2-category of an equipment in which the only ordinary arrows are identites.)  However, we need the extra structure when we define a *functor* $f:C\to D$ between $W$-enriched categories, which consists of:

* a function $f:ob(C)\to ob(D)$,
* for each object $x$ of $C$ an arrow $f_x:e(x)\to e(f(x))$ in $W$,
* for each pair of objects $x$ and $y$, a square
$$\array{e(y) & \overset{hom_C(x,y)}{\to} & e(x)\\
  ^{f_y}\downarrow & \Downarrow & \downarrow^{f_x}\\
  e(f(y))& \underset{hom_D(f(x),f(y))}{\to} & e(f(x))}$$
* satisfying functoriality axioms.

Finally, we define a *natural transformation* between such functors $f,g:C\to D$ to consist of

* squares
$$\array{e(x) & \overset{U_{e(x)}}{\to} & e(x)\\
  ^{g_x}\downarrow & \Downarrow & \downarrow^{f_x}\\
  e(g(x))& \underset{hom_D(f(x),f(y))}{\to} & e(f(x))}$$
* satisfying a naturality axiom.

By choosing $W$ appropriately, categories enriched in an equipment include most types of generalized category:

* If $W$ is a monoidal category $V$, regarded as a one-object bicategory and thence as an equipment with only one ordinary arrow (so the objects of $V$ are the proarrows of $W$), then $W$-enriched categories, functors, and natural transformations are the same as $V$-enriched ones.

* If $S$ has pullbacks, there is an equipment $Span(S)$ whose objects  and arrows are those of $S$ and whose proarrows are spans.  A category enriched in $Span(S)$ which has one object is the same as an internal category in $S$, and likewise for functors and transformations.  (Here it is essential to use an equipment, rather than merely a bicategory, to get the right notion of functor.)

* Arbitrary $Span(S)$-enriched categories can be identified with "locally small fibrations" over $S$, aka "locally internal categories" over $S$.

Other choices of $W$ give "categories which are both enriched and internal," for example:

* For a suitably nice category $S$ (such as a [[Grothendieck topos]]) there is an equipment $Ab(S)$ whose objects and arrows are those of $S$, and whose proarrows $A\to B$ are internal abelian group objects in $S/(B\times A)$.  An $Ab(S)$-enriched category with one object can be regarded as an "internal [[Ab-enriched category]]" in $S$.

## References

* {#Wood82} [[Richard J. Wood]], *Abstract Proarrows I*, Cahiers de topologie et géométrie différentielle **23** 3 (1982)  279-290 [[numdam:CTGDC_1982__23_3_279_0](http://www.numdam.org/item/CTGDC_1982__23_3_279_0)]

* {#Wood85} [[Richard J. Wood]], *Proarrows II*, Cahiers de Topologie et Géométrie Différentielle Catégoriques **26** 2 (1985) 135-168 [[numdam:CTGDC_1985__26_2_135_0](http://www.numdam.org/item/CTGDC_1985__26_2_135_0)]

and "Proarrows II" (the original definitions), and a number of following papers.

* [[Ross Street]], "Fibrations in bicategories" (Construction of $V Mod$ from $V Cat$.)

* [[Aurelio Carboni]], Scott Johnson, [[Ross Street]], and [[Dominic Verity]], "Modulated bicategories" (Improved construction of $V Mod$ from $V Cat$.)

* [[Dominic Verity]], "Enriched categories, internal categories, and change of base", Ph.D. Thesis.  (The connection with double categories.)

* {#Shulman} [[Michael Shulman]], "Framed bicategories and monoidal fibrations".  (The equivalence with certain double categories, there called *framed bicategories*, and a general way to construct equipments such as $Ab(S)$.)

* [[Geoff Cruttwell]], [[Michael Shulman]], "A unified framework for generalized multicategories" (currently the only reference for virtual equipments).

* Renato Betti, [[Aurelio Carboni]], [[Ross Street]], and Robert Walters, "Variation through enrichment."  (Locally small fibrations as $Span$-enriched categories.)

A blog post surveying ideas of proarrow equipments, much of which has been copied over to this page:

* [[Mike Shulman]], _Equipments_ ([blog](http://golem.ph.utexas.edu/category/2009/11/equipments.html))

On a [[string diagram]]-calculus for ([[virtual double category|virtual]]) [[double categories]] with ([[virtual equipment|virtual]]) [[2-category equipped with proarrows|pro-arrow equipments]]:

* {#Myers16} [[David Jaz Myers]], _String Diagrams For Double Categories and (Virtual) Equipments_ [[arXiv:1612.02762](https://arxiv.org/abs/1612.02762)]

* [[David Jaz Myers]], *String Diagrams for (Virtual) Proarrow Equipments* (2017) [slides: [pdf](http://www.mat.uc.pt/~ct2017/slides/myers_d.pdf), [[Myers-StringDiagrams2017.pdf:file]]]

An [[(∞,1)-category theory|(∞,1)-category theoretic]] version of proarrow equipments is in

* Jaco Ruit, _Formal category theory in ∞-equipments I_ ([arXiv:2308.03583](https://arxiv.org/abs/2308.03583))

[[!redirects 2-category equipped with proarrows]]
[[!redirects 2-categories equipped with proarrows]]
[[!redirects 2-category equipped with pro-arrows]]
[[!redirects 2-categories equipped with pro-arrows]]
[[!redirects 2-category with proarrow equipment]]
[[!redirects 2-categories with proarrow equipment]]
[[!redirects 2-category with pro-arrow equipment]]
[[!redirects 2-categories with pro-arrow equipment]]
[[!redirects 2-category equipment]]
[[!redirects 2-category equipments]]
[[!redirects equipment]]
[[!redirects equipments]]
[[!redirects proarrow equipment]]
[[!redirects proarrow equipments]]
[[!redirects pro-arrow equipment]]
[[!redirects pro-arrow equipments]]

[[!redirects proarrow]]
[[!redirects proarrows]]


2-category of 2-dimensional cobordisms

This is a special case of the $(\infty,n)$-[[(infinity,n)-category of cobordisms|category of cobordisms]].

##References#

A complete [[generators and relations]] presentation of the 2-dimensional extended unoriented oriented bordism [[bicategory]] as a [[symmetric monoidal bicategory]] is given in

* Chris Schommer-Pries, _The classification of two-dimensional extended topological field theories_ PhD thesis, UC Berkeley (2009) ([pdf](http://4167562941749007073-a-1802744773732722657-s-sites.googlegroups.com/site/chrisschommerpriesmath/Home/Schommer-Pries-Thesis.pdf?attredirects=0&auth=ANoY7cq2K1zI1CuKhtNciHgk1yh4N_4acDXRydHRgR4No5aXp6TvsR6mR5IkV0Wsr4HhC4qMlLXrD67XtC26RYTPcCml2RTVYNYzpBnPgmNZECcxZNdBJbdjOE2UfdM_ya5ohr8UvugsHcbFqr3gVJg12WQqizOYcUQMkUNM7kgcL5uBU7GImLsPWJ7XWQq0IIodpv7By5Fh4ZrobR4DNWk74o0fQ9o9eamxKmczHCEDr1U8CH8Sj6E%3D))

The 2-category theory in Schommer-Pries' thesis relies on a thesis by a student of Ross Street:

* Paddy McCrudden, _Balanced coalgebroids_ , Theory and Applications of Categories 7 (2000), 71-147. ([tac](http://www.tac.mta.ca/tac/volumes/7/n6/7-06abs.html))


2-category of adjunctions

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

#Contents#
* table of contents
{:toc}

##Idea

For any [[2-category]] $K$, there are two 2-categories (each with several variants) that could be called "the 2-category of adjunctions in $K$".

* The 2-category which here we call $Adj(K)$ has the same objects as $K$, its morphisms are the [[adjunctions]] in $K$ (pointing in the direction of, say, the [[left adjoint]]), and its [[2-morphisms]] are [[mate]]-pairs of 2-morphisms between adjunctions in $K$.

* The 2-category $[Adj,K]$ is the [[functor 2-category]] from the [[walking adjunction]] $Adj$ to $K$.  Thus its *objects* are the adjunctions in $K$ --- or more precisely, triples $(x,y,(f,g,\eta,\epsilon))$ where $x,y$ are objects of $K$ and $(f,g,\eta,\epsilon)$ is an adjunction between $x$ and $y$.  Its morphisms are pairs of morphisms $x\to x'$ and $y\to y'$ such that certain squares commute (perhaps up to a transformation or isomorphism), and its 2-cells are similarly composed of cylinders.

Note that the *[[1-morphisms]]* of $Adj(K)$ are the *[[objects]]* of $[Adj,K]$.

## Properties

* The morphisms in $Adj\big(Adj(K)\big)$ are the [[adjoint triples]] in $K$.

* The inclusion of $Mnd$, the [[free monad]], in $Adj$ induces a [[2-functor]] from $[Adj,K]$ to $[Mnd,K]$, the [2-category of monads](monad#the_bicategory_of_monads) in $K$. The adjoints to this 2-functor are the [[Kleisli category|Kleisli]] and [[Eilenberg-Moore category|Eilenberg-Moore]] constructions on monads in $K$.

## Related concepts

* [[CatAdj|$Cat_{Adj}$]]

## References

* [[Stephen Schanuel]] and [[Ross Street]], *The free adjunction*, Cahiers de topologie et géométrie différentielle catégoriques, tome 27, no 1 (1986), p. 81-83


2-category theory

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

#Contents#
* table of contents
{:toc}

## Idea

**2-category theory** is the study of [[2-categories]].  It is the "first new level" in [[higher category theory]].

## Related concepts

[[!include table of category theories]]

## References

See the references at *[[2-category]]*.

[[!redirects (2,1)-category theory]]


2-category theory - contents

**[[2-category theory]]**

**Definitions**

* [[2-category]]

* [[strict 2-category]]

* [[bicategory]]

* [[enriched bicategory]]

**Transfors between 2-categories**

* [[2-functor]]

  * [[pseudofunctor]]

  * [[lax functor]]

  * [[equivalence of 2-categories]]

* [[2-natural transformation]]

  * [[lax natural transformation]]

  * [[icon]]

* [[modification]]

* [[Yoneda lemma for bicategories]]

**Morphisms in 2-categories**

* [[fully faithful morphism]]

* [[faithful morphism]]

* [[conservative morphism]]

* [[pseudomonic morphism]]

* [[discrete morphism]]

* [[eso morphism]]

**Structures in 2-categories**

* [[adjunction]]

* [[mate]]

* [[monad]]

* [[cartesian object]]

* [[fibration in a 2-category]]

* [[codiscrete cofibration]]

**Limits in 2-categories**

* [[2-limit]]

* [[2-pullback]]

* [[comma object]]

* [[inserter]]

* [[inverter]]

* [[equifier]]

**Structures on 2-categories**

* [[2-monad]]

  * [[lax-idempotent 2-monad]]

  * [[pseudomonad]]

  * [[pseudoalgebra for a 2-monad]]

* [[monoidal 2-category]]

  * [[cartesian bicategory]]

* [[Gray tensor product]]

* [[proarrow equipment]]


2-category with contravariance

# 2-categories with contravariance

* table of contents
{:toc}

## Idea

A *2-category with contravariance* is a [[2-category]]-like structure that contains a basic notion of [[contravariant functor|contravariant morphism]].  There are multiple ways to make this precise, depending on what sort of natural transformations we include.

## No mixed-variance transformations

The simplest case is when we include only natural transformations between functors of the same variance.  In this case, for any two objects $x$ and $y$ we will have two disjoint hom-categories $hom^+(x,y)$ and $hom^-(x,y)$ whose objects are called "covariant" and "contravariant" respectively, and composition functors

$$ \begin{aligned}
hom^+(y,z) \times hom^+(x,y) &\to hom^+(x,z)\\
hom^+(y,z) \times hom^-(x,y) &\to hom^-(x,z)\\
hom^-(y,z) \times hom^+(x,y)^{op} &\to hom^-(x,z)\\
hom^-(y,z) \times hom^-(x,y)^{op} &\to hom^+(x,z)
\end{aligned} $$

Note that the variances behave like a $\mathbb{Z}/2$-[[graded category|grading]], with covariant functors considered "even" and contravariant functors "odd".  Moreover, postcomposing with a contravariant functor is a contravariant operation.

This sort of 2-category with contravariance can be described more abstractly in two ways:

* It is a [[generalized multicategory]] relative to the [[2-monad]] on [[2-Cat]] defined by $ob(T A) = ob(A)$ and $T A(x,y) = A(x,y) + A(x,y)^{op}$.

* It is an [[enriched category]] over the category $V = Cat \times Cat$ with the non-standard (and non-[[symmetric monoidal category|symmetric]]) monoidal structure
  $$(A^+,A^-)\otimes (B^+,B^-) = (A^+\times B^+ + A^-\times (B^-)^{op}, A^+\times B^- + A^- \times (B^+)^{op}). $$

The operation "$op$" can then be characterized by a [[universal property]], using the [[representable multicategory|representability]] property of a generalized multicategory or the notion of [[copowers]] in an enriched category.  See [Shulman 2016](#Shulman2016) for more details.

### Examples

* Of course, [[Cat]] with its usual notion of [[contravariant functor]].

* If $V$ is any [[symmetric monoidal category]], then $V$-categories have opposites and so we can define contravariant $V$-functors in the usual way.

* 2-categories of [[indexed categories]] and [[fibrations]] have "fiberwise" opposites and hence fiberwise contravariant morphisms.

* More generally, any 2-category with a [[duality involution]] has an underlying 2-category with contravariance, and conversely a 2-category with contravariance that has all "opposites" (characterized by a universal property as above) has a duality involution.

* For instance, if $B$ is a [[compact closed bicategory]], then its sub-bicategory of "maps" ([[left adjoint]] morphisms) has a duality involution given by the duals in $B$, and hence is a "bicategory with contravariance".

## With mixed-variance transformations

It is also possible to define natural transformations from a covariant functor to a contravariant functor or vice versa, as a special case of [[dinatural transformations]]; thus we might ask for a sort of 2-category with contravariance that includes these as well.  (This will include many of the examples above, but not $V$-enriched categories unless $V$ is cartesian monoidal, and thus also not the bicategory of maps in $B$ unless $B$ is not just compact closed but a [[cartesian bicategory]].)

Now our hom-objects will not decompose into two disjoint categories $hom^+$ and $hom^-$.  Instead we have only one hom-category, but with gradings of "even" (covariant) or "odd" (contravariant) assigned to its objects (the morphisms of our 2-category-like structure).  In the example of [[Cat]], the objects of these hom-categories will be all functors, covariant and contravariant alike, with covariant ones considered even and contravariant ones odd.

The $2$-morphisms $F\stackrel{\alpha}{\Rightarrow}G\colon C\to D$ in $Cat$ are as usual $\ob(C)$-indexed families of morphisms $FX\stackrel{\alpha_X}{\to} GX$, but the commutative diagram they will have to satisfy for each $X\stackrel{f}{\to} Y$ in $C$ depends on the combination of variances of $F$ and $G$:
$$
\array{
FX&\stackrel{Ff}{\rightarrow}&FY&&FX&\stackrel{Ff}{\rightarrow}&FY&&FX&\stackrel{Ff}{\leftarrow}&FY&&FX&\stackrel{Ff}{\leftarrow}&FY
\\\alpha_X\downarrow&&\alpha_Y\downarrow&&
\alpha_X\downarrow&&\alpha_Y\downarrow&&
\alpha_X\downarrow&&\alpha_Y\downarrow&&
\alpha_X\downarrow&&\alpha_Y\downarrow
\\GX&\stackrel{Gf}{\rightarrow}&GY&&GX&\stackrel{Gf}{\leftarrow}&GY&&GX&\stackrel{Gf}{\rightarrow}&GY&&GX&\stackrel{Gf}{\leftarrow}&GY
}$$
Note that these are the special cases of [[dinatural transformations]] between functors $C^{op}\times C\to D$ when both functors depend only on one of $C$ or $C^{op}$.  It is clear that "vertical" composition of $2$-morphisms makes sense, so we do have hom-categories whose objects are functors of both variances.  Note that if we consider transformations between functors of different variance to be graded odd and natural transformation between functors of the same variance to be graded even, then vertical composition is appropriately additive on the grading (the composition of two even morphisms, or two odd ones, is even; while the composition of an even and an odd morphism is odd).

Horizontal composition is trickier to describe.  Of course, we can compose functors of both sorts, and this is also additive on the grading.  Moreover, we can [[whisker]] a transformation of any sort by a functor of either sort on either side, and postwhiskering by an odd functor reverses the direction of a transformation.  There is an appropriate [[interchange law]] (it is just the "naturality square" for the second transformation involved), so we have something that looks sort of like a 2-category.

+--{:.standout}
**Conjecture:** Let $W$ be the category whose objects are categories with $\mathbb{Z}/2$-gradings assigned to their objects, and whose morphisms are functors preserving grading.  Then there is a [[closed monoidal category|biclosed]] (non-[[symmetric monoidal category|symmetric]]) [[monoidal category|monoidal structure]] on $W$ (or at least a [[closed category]] or [[multicategory]] structure) such that the above structure on categories, functors of both variances, and transformations assembles into a $W$-enriched category.
=--

## References

* [[Mike Shulman]], *Contravariance through enrichment*, [arXiv](https://arxiv.org/abs/1606.05058), 2016
 {#Shulman2016}

[[!redirects 2-categories with contravariance]]


2-congruence

+-- {: .rightHandSide}
+-- {: .toc .clickDown tabindex="0"}
###Context###
#### Relations
+-- {: .hide}
[[!include relations - contents]]
=--
#### 2-Category theory
+--{: .hide}
[[!include 2-category theory - contents]]
=--
#### Internal $(\infty,1)$-Categories
+--{: .hide}
[[!include internal infinity-categories contents]]
=--
=--
=--

#Contents#
* table of contents
{:toc}

## Idea

The notion of _[[2-congruence]]_ is the generalization of the notion of _[[congruence]]_ from [[category theory]] to [[2-category theory]].

The correct notions of _[[regular 2-category|regularity]] and [[exact 2-category|exactness]]_ for [[2-categories]] is one of the subtler parts of the theory of first-order structure.  In particular, we need a suitable replacement for the 1-categorical notion of _[[equivalence relation]]_.  The (almost) correct definition was probably first written down in [[StreetCBS]].

One way to express the idea is that in an [[n-category]], every [[object]] is [[internal logic|internally]] a $(n-1)$-category; exactness says that conversely every "internal $(n-1)$-category" is represented by an object.  When $n=1$, an "internal 0-category" means an internal _equivalence relation_; thus exactness for 1-categories says that every equivalence relation is a kernel (i.e. is represented by some object).  Thus, we need to find a good notion of "[[internal category|internal 1-category]]" in a 2-category.

Of course, there is an obvious notion of an internal category in a 2-category, as a straightforward generalization of [[internal category|internal categories]] in a 1-category.  But internal categories in [[Cat]] are [[double categories]], so we need to somehow cut down the [[double categories]] to those that really represent honest [[1-categories]].  These are the _2-congruences_.

## Definition

Before we define 2-congruences below in def. \ref{2Congruence}, we need some preliminaries.

### 2-Congruences

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

If $K$ is a finitely complete 2-category, a **homwise-discrete category** in $K$ consists of

* a [[discrete morphism]] $D_1\to D_0\times D_0$, together

* with composition and identity maps $D_0\to D_1$ and $D_1\times_{D_0} D_1\to D_1$ in $K/(D_0\times D_0)$,

which satisfy the usual axioms of an [[internal category]] up to [[isomorphism]].

Together with the evident notions of **[[internal functor]]** and **internal [[natural transformation]]** there is a [[2-category]] $HDC(K)$ of hom-wise discrete 2-categories in $K$.

=--

+--{: .num_remark}
###### Remark

Since $D_1\to D_0\times D_0$ is discrete, the structural isomorphisms will automatically satisfy any [[coherence]] axioms one might care to impose.

=--

+--{: .num_remark}
###### Remark

The transformations between functors $D\to E$ are a version of the notion for internal categories, thus given by a morphism $D_0\to E_1$ in $K$. The 2-cells in $K(D_0,E_0)$ play no explicit role, but we will recapture them below.

=--

+--{: .num_remark}
###### Remark

By homwise-discreteness, any "[[modification]]" between transformations is necessarily a unique isomorphism, so (after performing some quotienting, if we want to be pedantic) we really have a 2-category $HDC(K)$ rather than a [[3-category]].

=--

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

If $f:A\to B$ is any morphism in $K$, there is a canonical homwise-discrete category $(f/f) \to A\times A$, where $(f/f)$ is the [[comma object]] of $f$ with itself.  We call this the **kernel** $ker(f)$ of $f$ (the "comma [[kernel pair]]" or "comma [[Cech nerve]]" of $f$).

In particular, if $f=1_A$ then $(1_A/1_A) = A^{\mathbf{2}}$, so we have a canonical homwise-discrete category $A^{\mathbf{2}} \to A\times A$ called the **kernel** $ker(A)$ of $A$.

=--

+--{: .num_remark}
###### Remark

It is easy to check that taking kernels of objects defines a functor $\Phi:K \to HDC(K)$; this might first have been noticed by [Street](http://www.springerlink.com/content/407n62422140864p/). See prop. \ref{InclusionOfKernelsInCongruences} below.

=--

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

If $D_1\,\rightrightarrows\, D_0$ is a homwise-discrete category in $K$, the following are equivalent.

1. $D_0 \leftarrow D_1 \to D_0$ is a [[two-sided fibration]] in $K$.

1. There is a functor $\ker(D_0)\to D$ whose object-map $D_0\to D_0$ is the identity.

=--

Actually, homwise-discreteness is not necessary for this result, but we include it to avoid worrying about [[coherence]] isomorphisms, and since that is the case we are most interested in here.

+--{: .proof}
###### Proof
We consider the case $K=Cat$; the general case follows because all the notions are defined representably.   A homwise-discrete category in $Cat$ is, essentially, a [[double category]] whose horizontal 2-category is homwise-discrete (hence equivalent to a [[1-category]]).  We say "essentially" because the pullbacks and diagrams only commute up to isomorphism, but up to equivalence we may replace $D_1\to D_0\times D_0$ by an [[isofibration]], obtaining a (pseudo) double category in the usual sense.  Now the key is to compare both properties to a third: the existence of a [[companion pair|companion]] for any vertical arrow.

Suppose first that $D_0 \leftarrow D_1 \to D_0$ is a two-sided fibration.  Then for any (vertical) arrow $f:x\to y$ in $D_0$ we have [[cartesian morphism|cartesian]] and [[opcartesian morphisms]] (squares) in $D_1$:

\[
  \array{
     x & \overset{id}{\to} & x
       & \qquad  &
     x & \overset{f_1}{\to} & y'
     \\
      {}^{\mathllap{\cong}}\downarrow & opcart &  \downarrow^{\mathrlap{f}}
       & \qquad  &
     {}^{\mathllap{f}}\downarrow & cart &  \downarrow^{\mathrlap{\cong}}
     \\
     x' & \overset{f_2}{\to} & y
      & \qquad &
    y & \overset{id}{\to} & y
  }
\]

The vertical arrows marked as isomorphisms are so by one of the axioms for a two-sided fibration.  Moreover, the final compatibility axiom for a 2-sided fibration says that the square
\[
\array{ x & \overset{f_1}{\to} & y'\\
  \cong \downarrow & & \downarrow\cong \\
  x' & \overset{f_2}{\to} & y,}
\]
induced by factoring the horizontal identity square of $f$ through these cartesian and opcartesian squares, must be an isomorphism.  We can then show that $f_1$ (or equivalently $f_2$) is a [[companion pair|companion]] for $f$ just as in ([Shulman 07, theorem 4.1](#Shulman07)).  Conversely, from a [[companion pair]] we can show that $D_0 \leftarrow D_1 \to D_0$ is a two-sided fibration just as as in [loc cit](#Shulman07).

The equivalence between the existence of companions and the existence of a functor from the kernel of $D_0$ is essentially found in ([Fiore 06](#Fiore06)), although stated only for the "edge-symmetric" case.  In their language, a kernel $ker(A)$ is the double category $\Box A$ of commutative squares in $A$, and a functor $ker(D_0)\to D$ which is the identity on $D_0$ is a _thin structure_ on $D$.  In one direction, clearly $ker(D_0)$ has companions, and this property is preserved by any functor $ker(D_0)\to D$.  In the other direction, sending any vertical arrow to its horizontal companion is easily checked to define a functor $ker(D_0)\to D$.

=--

In particular, we conclude that up to isomorphism, there can be at most one functor $ker(D_0)\to D$ which is the identity on objects.

+--{: .num_defn #2Congruence}
###### Definition
A **2-congruence** in a finitely complete [[2-category]] $K$ is a homwise-discrete category, def. \ref{HomWiseDiscreteInternalCategory} in $K$ satisfying the equivalent conditions of Theorem \ref{Folding}.
=--

+--{: .num_example}
###### Example

The kernel $ker(A)$, def. \ref{Kernel} of any object is a 2-congruence.

More generally, the kernel $ker(f)$ of any morphism is also a 2-congruence.

=--

### 2-Forks and Quotients

The idea of a 2-fork is to characterize the structure that relates a morphism $f$ to its kernel $ker(f)$.  The kernel then becomes the universal 2-fork on $f$, while the _quotient_ of a 2-congruence is the couniversal 2-fork constructed from it.

+--{: .num_defn}
###### Definition
A **2-fork** in a 2-category consists of a 2-congruence $s,t:D_1\;\rightrightarrows\; D_0$, $i:D_0\to D_1$, $c:D_1\times_{D_0} D_1\to D_1$, and a morphism $f:D_0\to X$, together with a 2-cell $\phi:f s \to f t$ such that $\phi i = f$ and such that
$$\array{
  D_1\times_{D_0} D_1 & \to & D_1 & = & D_1\\
  \downarrow && \downarrow & \Downarrow_\phi & \downarrow\\
  D_1 & \to & D_0 && D_0\\
  || &\Downarrow_\phi && \searrow^f & \downarrow f\\
  D_1 & \to & D_0 & \overset{f}{\to} & X
} \qquad = \qquad
\array{ D_1\times_{D_0} D_1 \\
  & \searrow^c\\
  && D_1 & \to & D_0\\
  && \downarrow & \Downarrow_\phi & \downarrow f\\
  && D_1 & \overset{f}{\to} & X.
}$$
=--

The comma square in the definition of the kernel of a morphism $f:A\to B$ gives a canonical 2-fork
$$(f/f) \;\rightrightarrows\; A \overset{f}{\to} B.$$
It is easy to see that any other 2-fork
$$D_1 \;\rightrightarrows\; D_0 = A \overset{f}{\to} B$$
factors through the kernel by an essentially unique functor $D \to ker(f)$ that is the identity on $A$.

If $D_1 \;\rightrightarrows\; D_0 \overset{f}{\to} X$ is a 2-fork, we say that it equips $f$ with an **action** by the 2-congruence $D$.  If $g:D_0\to X$ also has an action by $D$, say $\psi:g s \to g t$, a 2-cell $\alpha:f\to g$ is called an **action 2-cell** if $(\alpha t).\phi= \psi . (\alpha s)$.  There is an evident category $Act(D,X)$ of morphisms $D_0\to X$ equipped with actions.

+--{: .num_defn}
###### Definition
A **quotient** for a 2-congruence $D_1\;\rightrightarrows\; D_0$ in a 2-category $K$ is a 2-fork $D_1 \;\rightrightarrows\; D_0 \overset{q}{\to} Q$ such that for any object $X$, composition with $q$ defines an equivalence of categories
$$K(Q,X) \simeq Act(D,X).$$
=--

A quotient can also, of course, be defined as a suitable [[nLab:2-categorical limit|2-categorical limit]].

+-- {: .num_lem}
###### Lemma
The quotient $q$ in any 2-congruence is [[nlab:eso morphism|eso]].
=--
+-- {: .proof}
###### Proof
If $m\colon A\to B$ is ff, then the square we must show to be a pullback is
$$\array{Act(D,A) & \overset{}{\to} & Act(D,B)\\
  \downarrow && \downarrow\\
  K(D_0,A)& \underset{}{\to} & K(D_0,B)}$$
But this just says that an action of $D$ on $A$ is the same as an action of $D$ on $B$ which happens to factor through $m$, and this follows directly from the assumption that $m$ is ff.
=--

+--{: .num_defn}
###### Definition
A 2-fork $D_1 \;\rightrightarrows\; D_0 \overset{f}{\to} X$ is called **exact** if $f$ is a quotient of $D$ _and_ $D$ is a kernel of $f$.
=--

This is the 2-categorical analogue of the notion of exact fork in a 1-category, and plays an analogous role in the definition of a [[regular 2-category]] and an [[exact 2-category]].

### The 2-category of 2-conguences
 {#2CategoryOf2Congruences}

There is an evident but naive [[2-category]] of 2-congruences in
any 2-category. And there is a refined version where internal [[functors]]
are replaced by internal [[anafunctors]].

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

For $K$ a [[2-category]], write $2Cong_s(K)$ for the [[full sub-2-category]]
of that of hom-wise discrete internal categories, def. \ref{HomWiseDiscreteInternalCategory} on the 2-congruences, def. \ref{2Congruence}

$$
  2 Cong_s(K) \hookrightarrow HDC(K)
  \,.
$$

=--

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

There is a [[2-functor]]

$$
   \Phi : K\to 2Cong_s(K)
$$

sending each object to its kernel, def. \ref{Kernel}.

=--

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

Let the 2-category $K$ be equipped with the structure of a [[2-site]].
With this understood, write

$$
  2 Cong(K)
$$

for the [[2-category]] of 2-congruences with morphisms the [[anafunctors]] between them.

=--

+--{: .num_remark }
###### Remark

The evident inclusion

$$
  2 Cong_s(K) \hookrightarrow 2 Cong(K)
$$

is a homwise-full sub-2-category closed under finite limits.

=--

## Properties

### Opposites

The opposite of a homwise-discrete category is again a homwise-discrete category.  However, the opposite of a 2-congruence in $K$ is a 2-congruence in $K^{co}$, since [[nLab:opposite 2-category|2-cell duals]] interchange fibrations and opfibrations.  Likewise, passage to opposites takes 2-forks in $K$ to 2-forks in $K^{co}$, and preserves and reflects kernels, quotients, and exactness.

### Regularity
 {#Regularity}

We discuss that when the ambient 2-category $K$ has finite [[2-limits]],
then its 2-category $2 Cong_s(K)$ of 2-congruences, def. \ref{2CongWithOrdinaryFunctors} is a _[[regular 2-category]]_. This is theorem \ref{regex} below. A sub-2-category of $Cong_s(K)$ is the _regular completion_ of $K$.

In the following and throughout, "$n$" denotes either of (see [[(n,r)-category]])

$$
  n = (0,1), (1,1), (2,1), (2,2)
  \,.
$$

+--{: .num_lemma}
###### Lemma
Suppose that $K$ has finite [[2-limits]].  Then:

1. $HDC(K)$ (def. \ref{HomWiseDiscreteInternalCategory}) has finite limits.

1. $n Cong_s(K)$ is closed under finite limits in $HDC(K)$.

1. The 2-functor $\Phi : K \to 2 Cong_s(K)$, prop. \ref{InclusionOfKernelsInCongruences}, is [[full and faithful 2-functor|2-fully-faithful]] (that is, an equivalence on hom-categories) and preserves finite limits.

=--
+--{: .proof}
###### Proof
It suffices to deal with finite products, inserters, and equifiers.  Evidently $\Phi(1)$ is a terminal object.  If $D$ and $E$ are homwise-discrete categories, define $P_0 = D_0\times E_0$ and $P_1 = D_1\times E_1$; it is easy to check that then $P_1 \;\rightrightarrows\; P_0$ is a homwise-discrete category that is the product $D\times E$ in $HDC(K)$.  Since $(D_0\times E_0) ^{\mathbf{2}} \simeq (D_0) ^{\mathbf{2}} \times (E_0) ^{\mathbf{2}}$, and products preserve ffs, we see that $P$ is an $n$-congruence if $D$ and $E$ are and that $\Phi$ preserves products.

For inserters, let $f,g:C \;\rightrightarrows\; D$ be functors in $HDC(K)$, define $i_0:I_0\to C_0$ by the pullback
$$\array{I_0 & \to & D_1\\ i_0 \downarrow && \downarrow \\
  C_0 & \overset{(f_0,g_0)}{\to} & D_0\times D_0,}$$
and define $i_1:I_1 \to C_1$ by the pullback
$$\array{I_1 & \to & X\\
  i_1\downarrow && \downarrow\\
  C_1 & \overset{(f_1,g_1)}{\to} & D_1\times D_1}$$
where $X$ is the "object of commutative squares in $D$."  Then $I_1 \;\rightrightarrows\; I_0$ is a homwise-discrete category and $i:I\to C$ is an inserter of $f,g$.  Also, $I$ is an $n$-congruence if $C$ is, and $\Phi$ preserves inserters.

Finally, for equifiers, suppose we have functors $f,g:C \;\rightrightarrows\; D$ and 2-cells $\alpha,\beta:f \;\rightrightarrows\; g$ in $HDC(K)$, represented by morphisms $a,b:C_0 \;\rightrightarrows\; D_1$ such that $(s,t) a \cong (f_0,g_0)\cong (s,t) b$.  Let $e_0:E_0\to C_0$ be the universal morphism equipped with an isomorphism $\phi:a e_0 \cong b e_0$ such that $(s,t)\phi$ is the given isomorphism $(s,t) a\cong (s,t) b$ (this is a finite limit in $K$.)  Note that since $(s,t):D_1\to D_0\times D_0$ is discrete, $e_0$ is ff.  Now let $E_1 = (e_0\times e_0)^*C_1$; then $E_1 \;\rightrightarrows\; E_0$ is a homwise-discrete category and $e:E\to C$ is an equifier of $\alpha$ and $\beta$ in $HDC(K)$. Also $E$ is an $n$-congruence if $C$ is, and $\Phi$ preserves equifiers.

For any morphism $f:A\to B$ in $K$, $\Phi(f)$ is the functor $ker(A)\to ker(B)$ that consists of $f:A\to B$ and $f^{\mathbf{2}}: A^{\mathbf{2}} \to B^{\mathbf{2}}$.  A transformation between $\Phi(f)$ and $\Phi(g)$ is a morphism $A\to B ^{\mathbf{2}}$ whose composites $A\to B ^{\mathbf{2}} \;\rightrightarrows\; B$  are $f$ and $g$; but this is just a transformation $f\to g$ in $K$.  Thus, $\Phi$ is homwise fully faithful.  And homwise essential-surjectivity follows from the essential uniqueness of thin structures, or equivalently a version of Prop 6.4 in [FBMF][].
=--

Moreover, we have:

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

If $K$ is an $n$-category with finite limits, then $n Cong_s(K)$ is [[regular 2-category|regular]].

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

It is easy to see that a functor $f:C\to D$ between $n$-congruences is ff in $n Cong_s(K)$ iff the square
$$\array{C_1 & \to & D_1\\ \downarrow && \downarrow\\
  C_0\times C_0 & \to & D_0\times D_0}$$
is a pullback in $K$.

We claim that if $e:E\to D$ is a functor such that $e_0:E_0\to D_0$ is split (that is, $e_0 s\cong 1_{D_0}$ for some $s:D_0\to E_0$), then $e$ is eso in $n Cong_s(K)$.  For if $e\cong f g$ for some ff $f:C\to D$ as above, then we have $g_0 s:D_0 \to C_0$ with $f_0 g_0 s \cong e_0 s \cong 1_{D_0}$, and so the fact that $C_1$ is a pullback induces a functor $h:D\to C$ with $h_0=g_0 s$ and $f h\cong 1_D$.  But this implies $f$ is an equivalence; thus $e$ is eso.

Moreover, if $e_0:E_0\to D_0$ is split, then the same is true for any pullback of $e$.  For the pullback of $e:E\to D$ along some $k:C\to D$ is given by a $P$ where $P_0 = E_0 \times_{D_0} D_{iso} \times_{D_0} C_0$; here $D_{iso}\hookrightarrow D_1$ is the "object of isomorphisms" in $D$.  What matters is that the projection $P_0\to C_0$ has a splitting given by combining the splitting of $e_0$ with the "identities" morphism $D_0\to D_{iso}$.

Now suppose that $f:D\to E$ is any functor in $n Cong_s(K)$.  It is easy to see that if we define $Q_0=D_0$ and let $Q_1$ be the pullback
$$\array{ Q_1 & \to & E_1 \\ \downarrow && \downarrow\\
  Q_0 \times Q_0 & \overset{f_0\times f_0}{\to} & E_0\times E_0}$$
then $f \cong m e$ where $e:D \to Q$ and $m:Q\to E$ are the obvious functors.  Moreover, clearly $m$ is ff, and $e$ satisfies the condition above, so any pullback of it is eso.  It follows that if $f$ itself were eso, then it would be equivalent to $e$, and thus any pullback of it would also be eso; hence esos are stable under pullback.

Since $m$ is ff, the kernel of $f$ is the same as the kernel of $e$, so to prove $K$ regular it remains only to show that $e$ is a quotient of that kernel.  If $C \;\rightrightarrows\; D$ denotes $ker(f)$, then $C$ is the comma object $(f/f)$ and thus we can calculate
$$C_0 = D_0\times_{E_0} E_1 \times_{E_0} D_0 \cong Q_1.$$
Therefore, if $g:D\to X$ is equipped with an action by $ker(f)$, then the action 2-cell is given by a morphism $Q_1=C_0\to X_1$, and the action axioms evidently make this into a functor $Q\to X$.  Thus, $Q$ is a quotient of $ker(f)$, as desired.
=--

+--{: .num_remark }
###### Remark

There are three "problems" with the 2-category $n Cong_s(K)$.

1. It is too big.  It is not necessary to include every $n$-congruence in order to get a regular category containing $K$, only those that occur as kernels of morphisms in $K$.
1. It is too small.  While it is regular, it is not [[exact 2-category|exact]].
1. It doesn't remember information about $K$.  If $K$ is already regular, then passing to $n Cong_s(K)$ destroys most of the esos and quotients already present in $K$.

=--

The solution to the first problem is straightforward.

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

If $K$ is a 2-category with finite limits, define

$$
  K_{reg/lex} \hookrightarrow 2 Cong_s(K)
$$

to be the sub-2-category of $2 Cong_s(K)$ spanned by the 2-congruences which occur as kernels of morphisms in $K$.

=--

+--{: .num_remark }
###### Remark

If $K$ is an $n$-category then any such kernel is an $n$-congruence, so in this case $K_{reg/lex}$ is contained in $n Cong_s(K)$ and is an $n$-category.  Also, clearly $\Phi$ factors through $K_{reg/lex}$.

=--

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

For any finitely complete 2-category $K$, the 2-category $K_{reg/lex}$ is [[refular 2-category|regular]], and the functor $\Phi:K\to K_{reg/lex}$ induces an equivalence
$$Reg(K_{reg/lex},L) \simeq Lex(K,L)$$
for any regular 2-category $K$.

=--

Here $Reg(-,-)$ denotes the 2-category of regular functors, transformations, and modifications between two regular 2-categories, and likewise $Lex(-,-)$ denotes the 2-category of finite-limit-preserving functors, transformations, and modifications between two finitely complete 2-categories.

+--{: .proof}
###### Proof
It is easy to verify that $K_{reg/lex}$ is closed under finite limits in $2 Cong_s(K)$, and also under the eso-ff factorization constructed in Theorem \ref{regex}; thus it is regular.  If $F:K\to L$ is a lex functor where $L$ is regular, we extend it to $K_{reg/lex}$ by sending $ker(f)$ to the quotient in $L$ of $ker(F f)$, which exists since $L$ is regular.  It is easy to verify that this is regular and is the unique regular extension of $F$.
=--

In particular, if $K$ is a [[nlab:regular category|regular 1-category]], $K_{reg/lex}$ is the ordinary regular completion of $K$.  In this case our construction reduces to one of the usual constructions (see, for example, the [[nlab:Elephant|Elephant]]).

To solve the second and third problems with $n Cong_s(K)$, we need to modify its morphisms.

### Exactness
 {#Exactness}

Let now the ambient [[2-category]] $K$ be equipped with the  structure of a [[2-site]]. Recall from def. \ref{2CongWithAnafunctors} the 2-category $2Cong(K)$ whose objects are 2-congruences in $K$, and whose morpisms are internal [[anafunctors]] between these, with respect to the given 2-site structure.

Notice that when $K$ is a [[regular 2-category]] it comes with a canonical structure of a 2-site: its [[regular coverage]].

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

For any [[subcanonical topology|subcanonical]] and finitely complete [[2-site]] $K$ (such as a [[regular coverage]]), the 2-category $2Cong(K)$ from
def. \ref{2CongWithAnafunctors}

* is finitely complete;

* contains $2Cong_s(K)$, def. \ref{2CongWithOrdinaryFunctors} as a homwise-full sub-2-category (that is, $2Cong_s(K)(D,E)\hookrightarrow 2Cong(K)(D,E)$ is ff) closed under finite limits.

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

It is easy to see that products in $2 Cong_S(K)$ remain [[products]] in $n Cong(K)$.  Before dealing with [[inserters]] and [[equifiers]], we observe that if $A\leftarrow F \to B$ is an anafunctor in $2 Cong(K)$ and $e:X_0\to F_0$ is any eso, then pulling back $F_1$ to $X_0\times X_0$ defines a new congruence $X$ and an anafunctor $A \leftarrow X \to B$ which is isomorphic to the original in $2 Cong(K)(A,B)$.  Thus, if $A\leftarrow F\to B$ and $A\leftarrow G\to B$ are parallel anafunctors in $2 Cong(K)$, by pulling them both back to $F\times_A G$ we may assume that they are defined by spans with the same first leg, i.e. we have $A\leftarrow X \;\rightrightarrows\; B$.

Now, for the inserter of $F$ and $G$ as above, let $E\to X$ be the inserter of $X \;\rightrightarrows\; B$ in $2 Cong_s(K)$.  It is easy to check that the composite $E\to X \to A$ is an inserter of $F,G$ in $2 Cong(K)$.  Likewise, given $\alpha,\beta: F \;\rightrightarrows\; G$ with $F$ and $G$ as above, we have transformations between the two functors $X \;\rightrightarrows\; B$ in $2 Cong_s(K)$, and it is again easy to check that their equifier in $2 Cong_s(K)$ is again the equifier in $2 Cong(K)$ of the original 2-cells $\alpha,\beta$.  Thus, $2 Cong(K)$ has finite limits.  Finally, by construction clearly the inclusion of $2 Cong_s(K)$ preserves finite limits.
=--

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

If $K$ is a [[subcanonical coverage|subcanonical]] finitely complete $n$-site, then the functor $\Phi:K\to n Cong(K)$, prop. \ref{InclusionOfKernelsInCongruences},
is [[full and faithful 2-functor|2-fully-faithful]].
If $K$ is an $n$-[[exact 2-category|exact]] $n$-category equipped with its [[regular coverage]], then

$$
  \Phi : K \to n Cong(K)
$$

is an [[equivalence of 2-categories]].

=--
+--{: .proof}
###### Proof
Since $\Phi:K \to n Cong_s(K)$ is 2-fully-faithful and $n Cong_s(K)\to n Cong(K)$ is homwise fully faithful, $\Phi:K \to n Cong(K)$ is homwise fully faithful.  For homwise essential-surjectivity, suppose that $ker(A) \leftarrow F \to ker(B)$ is an anafunctor. Then $h:F_0 \to A$ is a cover and $F_1$ is the pullback of $A ^{\mathbf{2}}$ along it; but this just says that $F_1 = (h/h)$.  The functor $F\to B$ consists of morphisms $g:F_0\to B$ and $F_1 = (h/h) \to B ^{\mathbf{2}}$, and functoriality says precisely that the resulting 2-cell equips $g$ with an action by the congruence $F$.  But since $F$ is precisely the kernel of $h:F_0\to A$, which is a cover in a subcanonical 2-site and hence the quotient of this kernel, we have an induced morphism $f:A\to B$ in $K$.  It is then easy to check that $f$ is isomorphic, as an anafunctor, to $F$.  Thus, $\Phi$ is homwise an equivalence.

Now suppose that $K$ is an $n$-exact $n$-category and that $D$ is an $n$-congruence.  Since $K$ is $n$-exact, $D$ has a quotient $q:D_0\to Q$, and since $D$ is the kernel of $q$, we have a functor $D \to ker(Q)$ which is a weak equivalence.  Thus, we can regard it either as an anafunctor $D\to ker(Q)$ or $ker(Q)\to D$, and it is easy to see that these are inverse equivalences in $n Cong(K)$.  Thus, $\Phi$ is essentially surjective, and hence an equivalence.
=--

Note that by working in the generality of 2-sites, this construction includes the previous one.

+--{: .num_remark}
###### Remark

If $K$ is a finitely complete 2-category equipped with its minimal coverage, in which the covering families are those that contain a [[split epimorphism]], then

$$
  n Cong(K) \simeq n Cong_s(K)
  \,.
$$

=--

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

 This is immediate from the proof of Theorem \ref{regex}, which implies that the first leg of any anafunctor relative to this coverage is both eso and ff in $n Cong_s(K)$, and hence an equivalence.

=--

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

If $K$ is a 2-exact 2-category with [[core in a 2-category|enough groupoids]], then

$$
  K\simeq 2 Cong(gpd(K))
  \,.
$$

Likewise, if $K$ is 2-exact and has enough discretes, then

$$
  K\simeq 2 Cong(disc(K))
  \,.
$$

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

Define a functor $K\to 2Cong(gpd(K))$ by taking each object $A$ to the kernel of $j:J\to A$ where $j$ is eso and $J$ is groupoidal (for example, it might be the [[core]] of $A$).  Note that this kernel lives in $2Cong(gpd(K))$ since $(j/j)\to J\times J$ is discrete, hence $(j/j)$ is also groupoidal.  The same argument as in Theorem \ref{nCongExidempotent} shows that this functor is 2-fully-faithful for any regular 2-category $K$ with enough groupoids, and essentially-surjective when $K$ is 2-exact; thus it is an equivalence.  The same argument works for discrete objects.
=--

In particular, the 2-exact 2-categories having enough discretes are precisely the 2-categories of internal categories and anafunctors in 1-exact 1-categories.

Our final goal is to construct the $n$-exact completion of a regular $n$-category, and a first step towards that is the following.

+--{: .num_theorem #almostExreg}
###### Theorem
If $K$ is a regular $n$-category, so is $n Cong(K)$.  The functor $\Phi:K\to n Cong(K)$ is regular, and moreover for any $n$-exact 2-category $L$ it induces an equivalence
$$Reg(n Cong(K), L) \to Reg(K,L).$$
=--
+--{: .proof}
###### Proof

We already know that $n Cong(K)$ has finite limits and $\Phi$ preserves finite limits.  The rest is very similar to Theorem \ref{regex}.  We first observe that an anafunctor $A \leftarrow F \to B$ is an equivalence as soon as $F\to B$ is also a weak equivalence (its reverse span $B\leftarrow F \to A$ then provides an inverse.)  Also, $A \leftarrow F \to B$ is ff if and only if
$$\array{F_1 & \to & B_1\\ \downarrow && \downarrow \\
  F_0\times F_0 & \to & B_0\times B_0}$$
is a pullback.

Now we claim that if $A\leftarrow F \to B$ is an anafunctor such that $F_0\to B_0$ is eso, then $F$ is eso.  For if we have a composition
$$\array{ &&&& F \\
  &&& \swarrow && \searrow\\
  && G &&&& M\\
  & \swarrow && \searrow && \swarrow && \searrow\\
  A &&&& C &&&& B}$$
such that $M$ is ff, then $F_0\to B_0$ being eso implies that $M_0\to B_0$ is also eso; thus $M\to B$ is a weak equivalence and so $M$ is an equivalence.  Moreover, by the construction of pullbacks in $n Cong(K)$, anafunctors with this property are stable under pullback.

Now suppose that $A \leftarrow F \to B$ is any anafunctor, and define $C_0=F_0$ and let $C_1$ be the pullback of $B_1$ to $C_0\times C_0$ along $C_0 = F_0 to B_0$.  Then $C$ is an $n$-congruence, $C\to B$ is ff in $n Cong_s(K)$ and thus also in $n Cong(K)$, and $A \leftarrow F \to B$ factors through $C$.  (In fact, $C$ is the image of $F\to B$ in $n Cong_s(K)$.)  The kernel of $A\leftarrow F\to B$ can equally well be calculated as the kernel of $F\to B$, which is the same as the kernel of $F\to C$.

Finally, given any $A\leftarrow G \to D$ with an action by this kernel, we may as well assume (by pullbacks) that $F=G$ (which leaves $C$ unchanged up to equivalence).  Then since the kernel acting is the same as the kernel of $F\to C$, regularity of $n Cong_s(K)$ gives a descended functor $C\to D$.  Thus, $A\leftarrow F \to C$ is the quotient of its kernel; so $n Cong(K)$ is regular.

Finally, if $L$ is $n$-exact, then any functor $K\to L$ induces one $n Cong(K) \to n Cong(L)$, but $n Cong(L)\simeq L$, so we have our extension, which it can be shown is unique up to equivalence.

=--

When $K$ is a regular 1-category, it is well-known that $1 Cong(K)$ (which, in that case, is the category of internal equivalence relations and functional relations) is the 1-exact completion of $K$ (the reflection of $K$ from regular 1-categories into 1-exact 1-categories).  Theorem \ref{almostExreg} shows that in general, $n Cong(K)$ will be the $n$-exact completion of $K$ whenver it is $n$-exact.  However, in general for $n\gt 1$ we need to "build up exactness" in stages by iterating this construction.

It is possible that the iteration will converge at some finite stage, but for now, define $n Cong^r(K) = n Cong(n Cong^{r-1}(K))$ and let $K_{n ex/reg} = colim_r n Cong^r(K)$.

+--{: .num_theorem}
###### Theorem
For any regular $n$-category $K$, $K_{n ex/reg}$ is an $n$-exact $n$-category and there is a 2-fully-faithful regular functor $\Phi:K\to K_{n ex/reg}$ that induces an equivalence
$$Reg(K_{n ex/reg},L) \simeq Reg(K,L)$$
for any $n$-exact 2-category $L$.
=--
+--{: .proof}
###### Proof
Sequential colimits preserve 2-fully-faithful functors as well as functors that preserve finite limits and quotients, and the final statement follows easily from Theorem \ref{almostExreg}.  Thus it remains only to show that $K_{n ex/reg}$ is $n$-exact.  But for any $n$-congruence $D_1 \;\rightrightarrows\; D_0$ in $K_{n ex/reg}$, there is some $r$ such that $D_0$ and $D_1$  both live in $n Cong^r(K)$, and thus so does the congruence since $n Cong^r(K)$ sits 2-fully-faithfully in $K_{n ex/reg}$ preserving finite limits.  This congruence in $n Cong^r(K)$ is then an object of $n Cong^{r+1}(K)$ which supplies a quotient there, and thus also in $K_{n ex/reg}$.
=--

## Examples
 {#Examples}

### In $Grpd$
 {#ExamplesInGrpd}

> Under construction.

Let $K :=$ [[Grpd]] be the 2-category of [[groupoids]].

We would like to see that the following statement is true:

The [[2-category]] of 2-congruences in $Grpd$ is [[equivalence of 2-categories|equivalent]] to the 2-category [[Cat]] of [[small categories]].

$$
  2Cong(Grpd)
  \simeq
  Cat
  \,.
$$

Let's check:

For $C$ a [[small category]], construct a 2-congruence $\mathbb{C}$ in $Grpd$ as follows.

* let $\mathbb{C}_0 := Core(C) \in Grpd$ be the [[core]] of $C$;

* let $\mathbb{C}_1 := Core(C^{\Delta[1]}) \in Grpd$ be the core of the [[arrow category]] of $C$;

* let $(s,t) : \mathbb{C}_1 \to \mathbb{C}_0$ be image under $Core : Cat \to Grpd$ of the endpoint evaluation [[functor]]

$$
  C^{\Delta[0] \coprod \Delta[0] \to \Delta[1]}
  :
  C^{\Delta[1]} \to C^{\Delta[0] \coprod \Delta[0]}
  =
  C \times C
  \,.
$$

(Here we are using the canonical embedding $\Delta \hookrightarrow Cat$ of the [[simplex category]].)

This is clearly a [[faithful functor]]. Moreover, every morphism in [[Grpd]] is trivially a [[conservative morphism]]. So $\mathbb{C}_1 \to \mathbb{C}_0 \times \mathbb{C}_0$ is a [[discrete morphism]] in [[Grpd]].

Since [[Grpd]] is a [[(2,1)-category]], the [[2-pullbacks]] in [[Grpd]] are [[homotopy pullbacks]]. Using that $(s,t)$ is (under the [[right adjoint]] [[nerve]] embedding $N : Grpd \hookrightarrow sSet$) a [[Kan fibration]] (by direct inspection, but also as a special case of standard facts about the [[model structure on simplicial sets]]), the object of composable morphisms is found to be

$$
  \mathbb{C}_1 \times_{\mathbb{C}_0} \mathbb{C}_1
  \simeq
  Core(C^{\Delta[2]})
  \,.
$$

Accordingly, let the internal composition in $\mathbb{C}$ be induced by the given composition in $C$:

$$
  \mathbb{C}_1 \times_{\mathbb{C}_0} \mathbb{C}_1
  \simeq
  Core(C^{\Delta[2]})
  \stackrel{}{\to}
  Core(C^{\Delta[1]})
  \simeq
  \mathbb{C}_1
  \,.
$$

This is clearly [[associativity|associative]] and [[unitality|unital]] and hence makes $\mathbb{C}$ a hom-wise discrete category, def. \ref{HomWiseDiscreteInternalCategory}, internal to $Grpd$.

Observe next (for instance using the discussion and examples at [[homotopy pullback]], see also _[[path object]]_) that

$$
  ker(\mathbb{C}_0) =
  ( \mathbb{C}_0^{\Delta[1]} \stackrel{\to}{\to} \mathbb{C}_0)
  \,.
$$

Notice that up to [[equivalence of categories|equivalence of groupoids]], this is just the [[diagonal]] $\Delta : \mathbb{C}_0 \to \mathbb{C}_0 \times \mathbb{C}_0$.

Therefore there is an evident [[internal functor]] $ker(\mathbb{C}_0) \to \mathbb{C}$, which on the first equivalent incarnation of $ker(\mathbb{C}_0)$ given by the inclusion

$$
  ker(\mathbb{C}_0)
  \simeq
  \mathbb{C}_0^{\Delta[1]}
  \simeq
  Core(C)^{\Delta[1]}
  \hookrightarrow
  Core(C^{\Delta[1]})
  \,,
$$

but which in the second version above simply reproduces the [[identity-assigning morphism]] of the internal category $\mathbb{C}$.

It follows that $\mathbb{C}$ is indeed a 2-congruence, def. \ref{2Congruence}.

Conversely, given a 2-congruence $\mathbb{C}$ in $Grpd$, define a category $C$ as follows:

(...)

+--{: .num_remark}
###### Remark

In the notation of the above proof, we can also form _internally_ the [[core]] of $\mathbb{C}$. This is evidently the internally discrete category $\mathbb{C}_0 \stackrel{\overset{id}{\to}}{\underset{id}{\to}} \mathbb{C}_0$.

This means that the 2-congruences $\mathbb{C}$ in the above proof are [[complete Segal spaces]]

$$
  \mathbb{C} : [n] \mapsto Core(C^{\Delta[n]})
  \,,
$$

hence are [[internal categories in an (∞,1)-category]] in the [[(2,1)-category]] [[Grpd]].

=--

### In a general $(2,1)$-category
 {#ExamplesInA2Comma1Category}

(...)

## Related concepts

* [[congruence]]

* [[n-congruence]]

## References

The above material is taken from

* [[Mike Shulman]], _[[michaelshulman:2-congruence]]_

and

* [[Mike Shulman]], _[[michaelshulman:exact completion of a 2-category]]_

Some lemmas are taken from

* [[Mike Shulman]], _Framed bicategories and monoidal fibrations_ ([arXiv:0706.1286](http://arxiv.org/abs/0706.1286))
 {#Shulman07}

and

* [[Thomas Fiore]], _Pseudo Algebras and Pseudo Double Categories_ ([arXiv:0608760](http://arxiv.org/abs/math/0608760))
 {#Fiore06}

[[!redirects 2-congruences]]

[[!redirects 2-fork]]
[[!redirects 2-forks]]