Documentation

Mathlib.CategoryTheory.Limits.Shapes.Types

Special shapes for limits in Type. #

The general shape (co)limits defined in CategoryTheory.Limits.Types are intended for use through the limits API, and the actual implementation should mostly be considered "sealed".

In this file, we provide definitions of the "standard" special shapes of limits in Type, giving the expected definitional implementation:

We first construct terms of IsLimit and LimitCone, and then provide isomorphisms with the types generated by the HasLimit API.

As an example, when setting up the monoidal category structure on Type we use the Types.terminalLimitCone and Types.binaryProductLimitCone definitions.

@[simp]

A restatement of Types.Limit.lift_π_apply that uses Pi.π and Pi.lift.

A restatement of Types.Limit.lift_π_apply that uses Pi.π and Pi.lift, with specialized universes.

@[simp]

A restatement of Types.Limit.map_π_apply that uses Pi.π and Pi.map.

A restatement of Types.Limit.map_π_apply that uses Pi.π and Pi.map, with specialized universes.

The terminal object in Type u is PUnit.

Instances For

    The terminal object in Type u is PUnit.

    Instances For

      A type is terminal if and only if it contains exactly one element.

      Instances For

        A type is terminal if and only if it is isomorphic to PUnit.

        Instances For

          The initial object in Type u is PEmpty.

          Instances For

            The initial object in Type u is PEmpty.

            Instances For

              The product type X × Y forms a cone for the binary product of X and Y.

              Instances For

                The product type X × Y is a binary product for X and Y.

                Instances For

                  The category of types has X × Y, the usual cartesian product, as the binary product of X and Y.

                  Instances For
                    noncomputable def CategoryTheory.Limits.Types.binaryProductIso (X : Type u) (Y : Type u) :
                    X Y X × Y

                    The categorical binary product in Type u is cartesian product.

                    Instances For

                      The functor which sends X, Y to the product type X × Y.

                      Instances For

                        The product functor given by the instance HasBinaryProducts (Type u) is isomorphic to the explicit binary product functor given by the product type.

                        Instances For
                          @[simp]
                          theorem CategoryTheory.Limits.Types.binaryCoproductCocone_ι_app (X : Type u) (Y : Type u) :
                          ∀ (x : CategoryTheory.Discrete CategoryTheory.Limits.WalkingPair) (a : (CategoryTheory.Limits.pair X Y).obj x), (CategoryTheory.Limits.Types.binaryCoproductCocone X Y).ι.app x a = CategoryTheory.Limits.WalkingPair.rec (motive := fun t => x.as = t → ((CategoryTheory.Limits.pair X Y).obj { as := x.as } X Y)) (fun h => (_ : CategoryTheory.Limits.WalkingPair.left = x.as)Sum.inl) (fun h => (_ : CategoryTheory.Limits.WalkingPair.right = x.as)Sum.inr) x.as (_ : x.as = x.as) a

                          The sum type X ⊕ Y forms a cocone for the binary coproduct of X and Y.

                          Instances For

                            The sum type X ⊕ Y is a binary coproduct for X and Y.

                            Instances For

                              The category of types has X ⊕ Y, as the binary coproduct of X and Y.

                              Instances For
                                noncomputable def CategoryTheory.Limits.Types.binaryCoproductIso (X : Type u) (Y : Type u) :
                                X ⨿ Y X Y

                                The categorical binary coproduct in Type u is the sum X ⊕ Y.

                                Instances For

                                  Any monomorphism in Type is a coproduct injection.

                                  Instances For

                                    The category of types has Π j, f j as the product of a type family f : J → TypeMax.{v, u}.

                                    Instances For
                                      noncomputable def CategoryTheory.Limits.Types.productIso {J : Type v} (F : JTypeMax) :
                                      F (j : J) → F j

                                      The categorical product in TypeMax.{v, u} is the type theoretic product Π j, F j.

                                      Instances For

                                        A variant of productLimitCone using a UnivLE hypothesis rather than a function to TypeMax.

                                        Instances For
                                          noncomputable def CategoryTheory.Limits.Types.UnivLE.productIso {J : Type v} (F : JType u) [UnivLE.{v, u} ] :
                                          F Shrink ((j : J) → F j)

                                          The categorical product in Type u indexed in Type v is the type theoretic product Π j, F j, after shrinking back to Type u.

                                          Instances For

                                            The category of types has Σ j, f j as the coproduct of a type family f : J → Type.

                                            Instances For
                                              noncomputable def CategoryTheory.Limits.Types.coproductIso {J : Type u} (F : JType u) :
                                              F (j : J) × F j

                                              The categorical coproduct in Type u is the type theoretic coproduct Σ j, F j.

                                              Instances For
                                                noncomputable def CategoryTheory.Limits.Types.typeEqualizerOfUnique {X : Type u} {Y : Type u} {Z : Type u} (f : X Y) {g : Y Z} {h : Y Z} (w : CategoryTheory.CategoryStruct.comp f g = CategoryTheory.CategoryStruct.comp f h) (t : ∀ (y : Y), g y = h y∃! x, f x = y) :

                                                Show the given fork in Type u is an equalizer given that any element in the "difference kernel" comes from X. The converse of unique_of_type_equalizer.

                                                Instances For
                                                  theorem CategoryTheory.Limits.Types.unique_of_type_equalizer {X : Type u} {Y : Type u} {Z : Type u} (f : X Y) {g : Y Z} {h : Y Z} (w : CategoryTheory.CategoryStruct.comp f g = CategoryTheory.CategoryStruct.comp f h) (t : CategoryTheory.Limits.IsLimit (CategoryTheory.Limits.Fork.ofι f w)) (y : Y) (hy : g y = h y) :
                                                  ∃! x, f x = y

                                                  The converse of type_equalizer_of_unique.

                                                  Show that the subtype {x : Y // g x = h x} is an equalizer for the pair (g,h).

                                                  Instances For
                                                    noncomputable def CategoryTheory.Limits.Types.equalizerIso {Y : Type u} {Z : Type u} (g : Y Z) (h : Y Z) :

                                                    The categorical equalizer in Type u is {x : Y // g x = h x}.

                                                    Instances For
                                                      inductive CategoryTheory.Limits.Types.CoequalizerRel {X : Type u} {Y : Type u} (f : X Y) (g : X Y) :
                                                      YYProp

                                                      (Implementation) The relation to be quotiented to obtain the coequalizer.

                                                      Instances For

                                                        Show that the quotient by the relation generated by f(x) ~ g(x) is a coequalizer for the pair (f, g).

                                                        Instances For

                                                          If π : Y ⟶ Z is an equalizer for (f, g), and U ⊆ Y such that f ⁻¹' U = g ⁻¹' U, then π ⁻¹' (π '' U) = U.

                                                          The categorical coequalizer in Type u is the quotient by f g ~ g x.

                                                          Instances For
                                                            @[inline, reducible]
                                                            abbrev CategoryTheory.Limits.Types.PullbackObj {X : Type u} {Y : Type u} {Z : Type u} (f : X Z) (g : Y Z) :

                                                            The usual explicit pullback in the category of types, as a subtype of the product. The full LimitCone data is bundled as pullbackLimitCone f g.

                                                            Instances For
                                                              @[inline, reducible]
                                                              abbrev CategoryTheory.Limits.Types.pullbackCone {X : Type u} {Y : Type u} {Z : Type u} (f : X Z) (g : Y Z) :

                                                              The explicit pullback cone on PullbackObj f g. This is bundled with the IsLimit data as pullbackLimitCone f g.

                                                              Instances For
                                                                @[simp]
                                                                theorem CategoryTheory.Limits.Types.pullbackLimitCone_isLimit {X : Type u} {Y : Type u} {Z : Type u} (f : X Z) (g : Y Z) :
                                                                (CategoryTheory.Limits.Types.pullbackLimitCone f g).isLimit = CategoryTheory.Limits.PullbackCone.isLimitAux (CategoryTheory.Limits.Types.pullbackCone f g) (fun s x => { val := (CategoryTheory.Limits.PullbackCone.fst (Type u) CategoryTheory.types X Y Z f g s x, CategoryTheory.Limits.PullbackCone.snd (Type u) CategoryTheory.types X Y Z f g s x), property := (_ : CategoryTheory.CategoryStruct.comp (Type u) CategoryTheory.Category.toCategoryStruct s.pt X Z (CategoryTheory.Limits.PullbackCone.fst s) f x = CategoryTheory.CategoryStruct.comp (Type u) CategoryTheory.Category.toCategoryStruct s.pt Y Z (CategoryTheory.Limits.PullbackCone.snd s) g x) }) (_ : ∀ (s : CategoryTheory.Limits.PullbackCone f g), CategoryTheory.CategoryStruct.comp ((fun s x => { val := (CategoryTheory.Limits.PullbackCone.fst (Type u) CategoryTheory.types X Y Z f g s x, CategoryTheory.Limits.PullbackCone.snd (Type u) CategoryTheory.types X Y Z f g s x), property := (_ : CategoryTheory.CategoryStruct.comp (Type u) CategoryTheory.Category.toCategoryStruct s.pt X Z (CategoryTheory.Limits.PullbackCone.fst s) f x = CategoryTheory.CategoryStruct.comp (Type u) CategoryTheory.Category.toCategoryStruct s.pt Y Z (CategoryTheory.Limits.PullbackCone.snd s) g x) }) s) (CategoryTheory.Limits.PullbackCone.fst (CategoryTheory.Limits.Types.pullbackCone f g)) = CategoryTheory.Limits.PullbackCone.fst s) (_ : ∀ (s : CategoryTheory.Limits.PullbackCone f g), CategoryTheory.CategoryStruct.comp ((fun s x => { val := (CategoryTheory.Limits.PullbackCone.fst (Type u) CategoryTheory.types X Y Z f g s x, CategoryTheory.Limits.PullbackCone.snd (Type u) CategoryTheory.types X Y Z f g s x), property := (_ : CategoryTheory.CategoryStruct.comp (Type u) CategoryTheory.Category.toCategoryStruct s.pt X Z (CategoryTheory.Limits.PullbackCone.fst s) f x = CategoryTheory.CategoryStruct.comp (Type u) CategoryTheory.Category.toCategoryStruct s.pt Y Z (CategoryTheory.Limits.PullbackCone.snd s) g x) }) s) (CategoryTheory.Limits.PullbackCone.snd (CategoryTheory.Limits.Types.pullbackCone f g)) = CategoryTheory.Limits.PullbackCone.snd s) (_ : ∀ (s : CategoryTheory.Limits.PullbackCone f g) (m : s.pt (CategoryTheory.Limits.Types.pullbackCone f g).pt), (∀ (j : CategoryTheory.Limits.WalkingCospan), CategoryTheory.CategoryStruct.comp m ((CategoryTheory.Limits.Types.pullbackCone f g).π.app j) = s.app j) → m = (fun s x => { val := (CategoryTheory.Limits.PullbackCone.fst (Type u) CategoryTheory.types X Y Z f g s x, CategoryTheory.Limits.PullbackCone.snd (Type u) CategoryTheory.types X Y Z f g s x), property := (_ : CategoryTheory.CategoryStruct.comp (Type u) CategoryTheory.Category.toCategoryStruct s.pt X Z (CategoryTheory.Limits.PullbackCone.fst s) f x = CategoryTheory.CategoryStruct.comp (Type u) CategoryTheory.Category.toCategoryStruct s.pt Y Z (CategoryTheory.Limits.PullbackCone.snd s) g x) }) s)

                                                                The explicit pullback in the category of types, bundled up as a LimitCone for given f and g.

                                                                Instances For

                                                                  The pullback cone given by the instance HasPullbacks (Type u) is isomorphic to the explicit pullback cone given by pullbackLimitCone.

                                                                  Instances For

                                                                    The pullback given by the instance HasPullbacks (Type u) is isomorphic to the explicit pullback object given by PullbackObj.

                                                                    Instances For
                                                                      @[simp]
                                                                      theorem CategoryTheory.Limits.Types.pullbackIsoPullback_inv_fst {X : Type u} {Y : Type u} {Z : Type u} (f : X Z) (g : Y Z) :
                                                                      CategoryTheory.CategoryStruct.comp (CategoryTheory.Limits.Types.pullbackIsoPullback f g).inv CategoryTheory.Limits.pullback.fst = fun p => (p).fst
                                                                      @[simp]
                                                                      theorem CategoryTheory.Limits.Types.pullbackIsoPullback_inv_snd {X : Type u} {Y : Type u} {Z : Type u} (f : X Z) (g : Y Z) :
                                                                      CategoryTheory.CategoryStruct.comp (CategoryTheory.Limits.Types.pullbackIsoPullback f g).inv CategoryTheory.Limits.pullback.snd = fun p => (p).snd