Limits in the category of types. #
We show that the category of types has all (co)limits, by providing the usual concrete models.
We also give a characterisation of filtered colimits in Type
, via
colimit.ι F i xi = colimit.ι F j xj ↔ ∃ k (f : i ⟶ k) (g : j ⟶ k), F.map f xi = F.map g xj
.
Finally, we prove the category of types has categorical images, and that these agree with the range of a function.
We now provide two distinct implementations in the category of types.
The first, in the CategoryTheory.Limits.Types.UnivLE
namespace,
assumes UnivLE.{v, u}
and constructs v
-small limits in Type u
.
The second, in the CategoryTheory.Limits.Types.TypeMax
namespace
constructs limits for functors F : J ⥤ TypeMax.{v, u}
, for J : Type v
.
This construction is slightly nicer, as the limit is definitionally just F.sections
,
rather than Shrink F.sections
, which makes an arbitrary choice of u
-small representative.
Hopefully we might be able to entirely remove the TypeMax
constructions,
but for now they are useful glue for the later parts of the library.
(internal implementation) the limit cone of a functor, implemented as flat sections of a pi type
Instances For
(internal implementation) the fact that the proposed limit cone is the limit
Instances For
(internal implementation) the limit cone of a functor, implemented as flat sections of a pi type
Instances For
(internal implementation) the fact that the proposed limit cone is the limit
Instances For
The results in this section have a UnivLE.{v, u}
hypothesis,
but as they only use the constructions from the CategoryTheory.Limits.Types.UnivLE
namespace
in their definitions (rather than their statements),
we leave them in the main CategoryTheory.Limits.Types
namespace.
The equivalence between a limiting cone of F
in Type u
and the "concrete" definition as the
sections of F
.
Instances For
The category of types has all limits.
More specifically, when UnivLE.{v, u}
, the category Type u
has all v
-small limits.
The equivalence between the abstract limit of F
in TypeMax.{v, u}
and the "concrete" definition as the sections of F
.
Instances For
Construct a term of limit F : Type u
from a family of terms x : Π j, F.obj j
which are "coherent": ∀ (j j') (f : j ⟶ j'), F.map f (x j) = x j'
.
Instances For
In this section we verify that instances are available as expected.
The relation defining the quotient type which implements the colimit of a functor F : J ⥤ Type u
.
See CategoryTheory.Limits.Types.Quot
.
Instances For
A quotient type implementing the colimit of a functor F : J ⥤ Type u
,
as pairs ⟨j, x⟩
where x : F.obj j
, modulo the equivalence relation generated by
⟨j, x⟩ ~ ⟨j', x'⟩
whenever there is a morphism f : j ⟶ j'
so F.map f x = x'
.
Instances For
(internal implementation) the colimit cocone of a functor, implemented as a quotient of a sigma type
Instances For
(internal implementation) the fact that the proposed colimit cocone is the colimit
Instances For
The category of types has all colimits.
The equivalence between the abstract colimit of F
in Type u
and the "concrete" definition as a quotient.
Instances For
A variant of jointly_surjective
for x : colimit F
.
An alternative relation on Σ j, F.obj j
,
which generates the same equivalence relation as we use to define the colimit in Type
above,
but that is more convenient when working with filtered colimits.
Elements in F.obj j
and F.obj j'
are equivalent if there is some k : J
to the right
where their images are equal.
Instances For
Recognizing filtered colimits of types.
Instances For
the inclusion of Image f
into the target
Instances For
the universal property for the image factorisation
Instances For
the factorisation of any morphism in Type through a mono.
Instances For
the factorisation through a mono has the universal property of the image.