Module docstring
{"# Preserving products
Constructions to relate the notions of preserving products and reflecting products to concrete fans.
In particular, we show that piComparison G f is an isomorphism iff G preserves
the limit of f.
"}
{"# Preserving products
Constructions to relate the notions of preserving products and reflecting products to concrete fans.
In particular, we show that piComparison G f is an isomorphism iff G preserves
the limit of f.
"}
CategoryTheory.Limits.isLimitMapConeFanMkEquiv
definition
{P : C} (g : ∀ j, P ⟶ f j) :
IsLimit (Functor.mapCone G (Fan.mk P g)) ≃ IsLimit (Fan.mk _ fun j => G.map (g j) : Fan fun j => G.obj (f j))
/-- The map of a fan is a limit iff the fan consisting of the mapped morphisms is a limit. This
essentially lets us commute `Fan.mk` with `Functor.mapCone`.
-/
def isLimitMapConeFanMkEquiv {P : C} (g : ∀ j, P ⟶ f j) :
IsLimitIsLimit (Functor.mapCone G (Fan.mk P g)) ≃
IsLimit (Fan.mk _ fun j => G.map (g j) : Fan fun j => G.obj (f j)) := by
refine (IsLimit.postcomposeHomEquiv ?_ _).symm.trans (IsLimit.equivIsoLimit ?_)
· refine Discrete.natIso fun j => Iso.refl (G.obj (f j.as))
refine Cones.ext (Iso.refl _) fun j =>
by dsimp; cases j; simp
CategoryTheory.Limits.isLimitFanMkObjOfIsLimit
definition
[PreservesLimit (Discrete.functor f) G] {P : C} (g : ∀ j, P ⟶ f j) (t : IsLimit (Fan.mk _ g)) :
IsLimit (Fan.mk (G.obj P) fun j => G.map (g j) : Fan fun j => G.obj (f j))
/-- The property of preserving products expressed in terms of fans. -/
def isLimitFanMkObjOfIsLimit [PreservesLimit (Discrete.functor f) G] {P : C} (g : ∀ j, P ⟶ f j)
(t : IsLimit (Fan.mk _ g)) :
IsLimit (Fan.mk (G.obj P) fun j => G.map (g j) : Fan fun j => G.obj (f j)) :=
isLimitMapConeFanMkEquiv _ _ _ (isLimitOfPreserves G t)
CategoryTheory.Limits.isLimitOfIsLimitFanMkObj
definition
[ReflectsLimit (Discrete.functor f) G] {P : C} (g : ∀ j, P ⟶ f j)
(t : IsLimit (Fan.mk _ fun j => G.map (g j) : Fan fun j => G.obj (f j))) : IsLimit (Fan.mk P g)
/-- The property of reflecting products expressed in terms of fans. -/
def isLimitOfIsLimitFanMkObj [ReflectsLimit (Discrete.functor f) G] {P : C} (g : ∀ j, P ⟶ f j)
(t : IsLimit (Fan.mk _ fun j => G.map (g j) : Fan fun j => G.obj (f j))) :
IsLimit (Fan.mk P g) :=
isLimitOfReflects G ((isLimitMapConeFanMkEquiv _ _ _).symm t)
CategoryTheory.Limits.isLimitOfHasProductOfPreservesLimit
definition
[PreservesLimit (Discrete.functor f) G] : IsLimit (Fan.mk _ fun j : J => G.map (Pi.π f j) : Fan fun j => G.obj (f j))
/--
If `G` preserves products and `C` has them, then the fan constructed of the mapped projection of a
product is a limit.
-/
def isLimitOfHasProductOfPreservesLimit [PreservesLimit (Discrete.functor f) G] :
IsLimit (Fan.mk _ fun j : J => G.map (Pi.π f j) : Fan fun j => G.obj (f j)) :=
isLimitFanMkObjOfIsLimit G f _ (productIsProduct _)
CategoryTheory.Limits.PreservesProduct.of_iso_comparison
theorem
[i : IsIso (piComparison G f)] : PreservesLimit (Discrete.functor f) G
/-- If `pi_comparison G f` is an isomorphism, then `G` preserves the limit of `f`. -/
lemma PreservesProduct.of_iso_comparison [i : IsIso (piComparison G f)] :
PreservesLimit (Discrete.functor f) G := by
apply preservesLimit_of_preserves_limit_cone (productIsProduct f)
apply (isLimitMapConeFanMkEquiv _ _ _).symm _
exact @IsLimit.ofPointIso _ _ _ _ _ _ _
(limit.isLimit (Discrete.functor fun j : J => G.obj (f j))) i
CategoryTheory.Limits.PreservesProduct.iso
definition
: G.obj (∏ᶜ f) ≅ ∏ᶜ fun j => G.obj (f j)
/--
If `G` preserves limits, we have an isomorphism from the image of a product to the product of the
images.
-/
def PreservesProduct.iso : G.obj (∏ᶜ f) ≅ ∏ᶜ fun j => G.obj (f j) :=
IsLimit.conePointUniqueUpToIso (isLimitOfHasProductOfPreservesLimit G f) (limit.isLimit _)
CategoryTheory.Limits.PreservesProduct.iso_hom
theorem
: (PreservesProduct.iso G f).hom = piComparison G f
@[simp]
theorem PreservesProduct.iso_hom : (PreservesProduct.iso G f).hom = piComparison G f :=
rfl
CategoryTheory.Limits.instIsIsoPiComparison
instance
: IsIso (piComparison G f)
instance : IsIso (piComparison G f) := by
rw [← PreservesProduct.iso_hom]
infer_instance
CategoryTheory.Limits.isColimitMapCoconeCofanMkEquiv
definition
{P : C} (g : ∀ j, f j ⟶ P) :
IsColimit (Functor.mapCocone G (Cofan.mk P g)) ≃
IsColimit (Cofan.mk _ fun j => G.map (g j) : Cofan fun j => G.obj (f j))
/-- The map of a cofan is a colimit iff the cofan consisting of the mapped morphisms is a colimit.
This essentially lets us commute `Cofan.mk` with `Functor.mapCocone`.
-/
def isColimitMapCoconeCofanMkEquiv {P : C} (g : ∀ j, f j ⟶ P) :
IsColimitIsColimit (Functor.mapCocone G (Cofan.mk P g)) ≃
IsColimit (Cofan.mk _ fun j => G.map (g j) : Cofan fun j => G.obj (f j)) := by
refine (IsColimit.precomposeHomEquiv ?_ _).symm.trans (IsColimit.equivIsoColimit ?_)
· refine Discrete.natIso fun j => Iso.refl (G.obj (f j.as))
refine Cocones.ext (Iso.refl _) fun j => by dsimp; cases j; simp
CategoryTheory.Limits.isColimitCofanMkObjOfIsColimit
definition
[PreservesColimit (Discrete.functor f) G] {P : C} (g : ∀ j, f j ⟶ P) (t : IsColimit (Cofan.mk _ g)) :
IsColimit (Cofan.mk (G.obj P) fun j => G.map (g j) : Cofan fun j => G.obj (f j))
/-- The property of preserving coproducts expressed in terms of cofans. -/
def isColimitCofanMkObjOfIsColimit [PreservesColimit (Discrete.functor f) G] {P : C}
(g : ∀ j, f j ⟶ P) (t : IsColimit (Cofan.mk _ g)) :
IsColimit (Cofan.mk (G.obj P) fun j => G.map (g j) : Cofan fun j => G.obj (f j)) :=
isColimitMapCoconeCofanMkEquiv _ _ _ (isColimitOfPreserves G t)
CategoryTheory.Limits.isColimitOfIsColimitCofanMkObj
definition
[ReflectsColimit (Discrete.functor f) G] {P : C} (g : ∀ j, f j ⟶ P)
(t : IsColimit (Cofan.mk _ fun j => G.map (g j) : Cofan fun j => G.obj (f j))) : IsColimit (Cofan.mk P g)
/-- The property of reflecting coproducts expressed in terms of cofans. -/
def isColimitOfIsColimitCofanMkObj [ReflectsColimit (Discrete.functor f) G] {P : C}
(g : ∀ j, f j ⟶ P)
(t : IsColimit (Cofan.mk _ fun j => G.map (g j) : Cofan fun j => G.obj (f j))) :
IsColimit (Cofan.mk P g) :=
isColimitOfReflects G ((isColimitMapCoconeCofanMkEquiv _ _ _).symm t)
CategoryTheory.Limits.isColimitOfHasCoproductOfPreservesColimit
definition
[PreservesColimit (Discrete.functor f) G] :
IsColimit (Cofan.mk _ fun j : J => G.map (Sigma.ι f j) : Cofan fun j => G.obj (f j))
/-- If `G` preserves coproducts and `C` has them,
then the cofan constructed of the mapped inclusion of a coproduct is a colimit.
-/
def isColimitOfHasCoproductOfPreservesColimit [PreservesColimit (Discrete.functor f) G] :
IsColimit (Cofan.mk _ fun j : J => G.map (Sigma.ι f j) : Cofan fun j => G.obj (f j)) :=
isColimitCofanMkObjOfIsColimit G f _ (coproductIsCoproduct _)
CategoryTheory.Limits.PreservesCoproduct.of_iso_comparison
theorem
[i : IsIso (sigmaComparison G f)] : PreservesColimit (Discrete.functor f) G
/-- If `sigma_comparison G f` is an isomorphism, then `G` preserves the colimit of `f`. -/
lemma PreservesCoproduct.of_iso_comparison [i : IsIso (sigmaComparison G f)] :
PreservesColimit (Discrete.functor f) G := by
apply preservesColimit_of_preserves_colimit_cocone (coproductIsCoproduct f)
apply (isColimitMapCoconeCofanMkEquiv _ _ _).symm _
exact @IsColimit.ofPointIso _ _ _ _ _ _ _
(colimit.isColimit (Discrete.functor fun j : J => G.obj (f j))) i
CategoryTheory.Limits.PreservesCoproduct.iso
definition
: G.obj (∐ f) ≅ ∐ fun j => G.obj (f j)
/-- If `G` preserves colimits,
we have an isomorphism from the image of a coproduct to the coproduct of the images.
-/
def PreservesCoproduct.iso : G.obj (∐ f) ≅ ∐ fun j => G.obj (f j) :=
IsColimit.coconePointUniqueUpToIso (isColimitOfHasCoproductOfPreservesColimit G f)
(colimit.isColimit _)
CategoryTheory.Limits.PreservesCoproduct.inv_hom
theorem
: (PreservesCoproduct.iso G f).inv = sigmaComparison G f
@[simp]
theorem PreservesCoproduct.inv_hom : (PreservesCoproduct.iso G f).inv = sigmaComparison G f := rfl
CategoryTheory.Limits.instIsIsoSigmaComparison
instance
: IsIso (sigmaComparison G f)
instance : IsIso (sigmaComparison G f) := by
rw [← PreservesCoproduct.inv_hom]
infer_instance
CategoryTheory.Limits.preservesLimitsOfShape_of_discrete
theorem
(F : C ⥤ D) [∀ (f : J → C), PreservesLimit (Discrete.functor f) F] : PreservesLimitsOfShape (Discrete J) F
/-- If `F` preserves the limit of every `Discrete.functor f`, it preserves all limits of shape
`Discrete J`. -/
lemma preservesLimitsOfShape_of_discrete (F : C ⥤ D)
[∀ (f : J → C), PreservesLimit (Discrete.functor f) F] :
PreservesLimitsOfShape (Discrete J) F where
preservesLimit := preservesLimit_of_iso_diagram F (Discrete.natIsoFunctor).symm
CategoryTheory.Limits.preservesColimitsOfShape_of_discrete
theorem
(F : C ⥤ D) [∀ (f : J → C), PreservesColimit (Discrete.functor f) F] : PreservesColimitsOfShape (Discrete J) F
/-- If `F` preserves the colimit of every `Discrete.functor f`, it preserves all colimits of shape
`Discrete J`. -/
lemma preservesColimitsOfShape_of_discrete (F : C ⥤ D)
[∀ (f : J → C), PreservesColimit (Discrete.functor f) F] :
PreservesColimitsOfShape (Discrete J) F where
preservesColimit := preservesColimit_of_iso_diagram F (Discrete.natIsoFunctor).symm