@@ -6,9 +6,11 @@ Authors: Bhavik Mehta, Kim Morrison
66import Mathlib.CategoryTheory.Comma.Over.Pullback
77import Mathlib.CategoryTheory.Adjunction.Reflective
88import Mathlib.CategoryTheory.Adjunction.Restrict
9+ import Mathlib.CategoryTheory.Limits.FullSubcategory
910import Mathlib.CategoryTheory.Limits.Shapes.Images
1011import Mathlib.CategoryTheory.Limits.Shapes.Pullback.CommSq
1112import Mathlib.CategoryTheory.Functor.ReflectsIso.Basic
13+ import Mathlib.CategoryTheory.WithTerminal.Cone
1214
1315/-!
1416# Monomorphisms over a fixed object
@@ -36,7 +38,7 @@ and was ported to mathlib by Kim Morrison.
3638-/
3739
3840
39- universe v₁ v₂ u₁ u₂
41+ universe w' w v₁ v₂ v₃ u₁ u₂ u₃
4042
4143noncomputable section
4244
@@ -47,13 +49,17 @@ open CategoryTheory CategoryTheory.Category CategoryTheory.Limits CategoryTheory
4749variable {C : Type u₁} [Category.{v₁} C] {X Y Z : C}
4850variable {D : Type u₂} [Category.{v₂} D]
4951
52+ /-- The object property in `Over X` of the structure morphism being a monomorphism. -/
53+ abbrev Over.isMono (X : C) : ObjectProperty (Over X) :=
54+ fun f : Over X => Mono f.hom
55+
5056/-- The category of monomorphisms into `X` as a full subcategory of the over category.
5157This isn't skeletal, so it's not a partial order.
5258
5359Later we define `Subobject X` as the quotient of this by isomorphisms.
5460-/
5561def MonoOver (X : C) :=
56- ObjectProperty.FullSubcategory fun f : Over X => Mono f.hom
62+ ObjectProperty.FullSubcategory ( Over.isMono X)
5763
5864instance (X : C) : Category (MonoOver X) :=
5965 ObjectProperty.FullSubcategory.category _
@@ -202,6 +208,35 @@ def slice {A : C} {f : Over A}
202208 MonoOver.liftComp _ _ _ _ ≪≫
203209 MonoOver.liftIso _ _ f.iteratedSliceEquiv.counitIso ≪≫ MonoOver.liftId
204210
211+ section Limits
212+
213+ variable {J : Type u₃} [Category.{v₃} J] (X : C)
214+
215+ lemma closedUnderLimitsOfShape_isMono :
216+ ClosedUnderLimitsOfShape J (Over.isMono X) := by
217+ refine fun F _ hc p ↦ ⟨fun g h e ↦ ?_⟩
218+ apply IsLimit.hom_ext <| WithTerminal.isLimitEquiv.invFun hc
219+ intro j; cases j with
220+ | of j => have := p j; rw [← cancel_mono ((F.obj j).hom)]; simpa
221+ | star => exact e
222+
223+ instance hasLimit (F : J ⥤ MonoOver X) [HasLimit (F ⋙ (Over.isMono X).ι)] :
224+ HasLimit F := by
225+ apply hasLimit_of_closedUnderLimits (closedUnderLimitsOfShape_isMono X)
226+
227+ instance hasLimitsOfShape [HasLimitsOfShape J (Over X)] :
228+ HasLimitsOfShape J (MonoOver X) := by
229+ apply hasLimitsOfShape_of_closedUnderLimits (closedUnderLimitsOfShape_isMono X)
230+
231+ instance hasFiniteLimits [HasFiniteLimits (Over X)] : HasFiniteLimits (MonoOver X) where
232+ out _ _ _ := by apply hasLimitsOfShape X
233+
234+ instance hasLimitsOfSize [HasLimitsOfSize.{w, w'} (Over X)] :
235+ HasLimitsOfSize.{w, w'} (MonoOver X) where
236+ has_limits_of_shape _ _ := by apply hasLimitsOfShape X
237+
238+ end Limits
239+
205240section Pullback
206241
207242variable [HasPullbacks C]
0 commit comments