File: Mathlib/CategoryTheory/Subobject/Comma.lean

full_name: CategoryTheory.StructuredArrow.projectSubobject
code: /-- Every subobject of a structured arrow can be projected to a subobject of the underlying
    object. -/
def projectSubobject [HasLimits C] [PreservesLimits T] {A : StructuredArrow S T} :
    Subobject A → Subobject A.right 
goal: CategoryTheory.Subobject A → CategoryTheory.Subobject A.right

full_name: CategoryTheory.StructuredArrow.projectSubobject_mk
code: @[simp]
theorem projectSubobject_mk [HasLimits C] [PreservesLimits T] {A P : StructuredArrow S T}
    (f : P ⟶ A) [Mono f] : projectSubobject (Subobject.mk f) = Subobject.mk f.right 
goal: CategoryTheory.StructuredArrow.projectSubobject (CategoryTheory.Subobject.mk f) = CategoryTheory.Subobject.mk f.right

full_name: CategoryTheory.StructuredArrow.projectSubobject_factors
code: theorem projectSubobject_factors [HasLimits C] [PreservesLimits T] {A : StructuredArrow S T} :
    ∀ P : Subobject A, ∃ q, q ≫ T.map (projectSubobject P).arrow = A.hom 
goal: ∃ q, CategoryTheory.CategoryStruct.comp q (T.map (CategoryTheory.StructuredArrow.projectSubobject P).arrow) = A.hom

full_name: CategoryTheory.StructuredArrow.liftSubobject
code: /-- A subobject of the underlying object of a structured arrow can be lifted to a subobject of
    the structured arrow, provided that there is a morphism making the subobject into a structured
    arrow. -/
@[simp]
def liftSubobject {A : StructuredArrow S T} (P : Subobject A.right) {q}
    (hq : q ≫ T.map P.arrow = A.hom) : Subobject A 
goal: CategoryTheory.Subobject A

full_name: CategoryTheory.StructuredArrow.lift_projectSubobject
code: /-- Projecting and then lifting a subobject recovers the original subobject, because there is at
    most one morphism making the projected subobject into a structured arrow. -/
theorem lift_projectSubobject [HasLimits C] [PreservesLimits T] {A : StructuredArrow S T} :
    ∀ (P : Subobject A) {q} (hq : q ≫ T.map (projectSubobject P).arrow = A.hom),
      liftSubobject (projectSubobject P) hq = P 
goal: CategoryTheory.StructuredArrow.liftSubobject (CategoryTheory.StructuredArrow.projectSubobject P) hq = P

full_name: CategoryTheory.StructuredArrow.subobjectEquiv
code: /-- If `A : S → T.obj B` is a structured arrow for `S : D` and `T : C ⥤ D`, then we can explicitly
    describe the subobjects of `A` as the subobjects `P` of `B` in `C` for which `A.hom` factors
    through the image of `P` under `T`. -/
@[simps!]
def subobjectEquiv [HasLimits C] [PreservesLimits T] (A : StructuredArrow S T) :
    Subobject A ≃o { P : Subobject A.right // ∃ q, q ≫ T.map P.arrow = A.hom } 
goal: CategoryTheory.Subobject A ≃o { P // ∃ q, CategoryTheory.CategoryStruct.comp q (T.map P.arrow) = A.hom }

full_name: CategoryTheory.StructuredArrow.subobjectEquiv_apply_coe
code: /-- If `A : S → T.obj B` is a structured arrow for `S : D` and `T : C ⥤ D`, then we can explicitly
    describe the subobjects of `A` as the subobjects `P` of `B` in `C` for which `A.hom` factors
    through the image of `P` under `T`. -/
@[simps!]
def subobjectEquiv [HasLimits C] [PreservesLimits T] (A : StructuredArrow S T) :
    Subobject A ≃o { P : Subobject A.right // ∃ q, q ≫ T.map P.arrow = A.hom } 
goal: ↑(A.subobjectEquiv P) = CategoryTheory.StructuredArrow.projectSubobject P

full_name: CategoryTheory.StructuredArrow.subobjectEquiv_symm_apply
code: /-- If `A : S → T.obj B` is a structured arrow for `S : D` and `T : C ⥤ D`, then we can explicitly
    describe the subobjects of `A` as the subobjects `P` of `B` in `C` for which `A.hom` factors
    through the image of `P` under `T`. -/
@[simps!]
def subobjectEquiv [HasLimits C] [PreservesLimits T] (A : StructuredArrow S T) :
    Subobject A ≃o { P : Subobject A.right // ∃ q, q ≫ T.map P.arrow = A.hom } 
goal: (RelIso.symm A.subobjectEquiv) P = CategoryTheory.Subobject.mk (CategoryTheory.StructuredArrow.homMk (↑P).arrow ⋯)

full_name: CategoryTheory.StructuredArrow.wellPowered_structuredArrow
code: /-- If `C` is well-powered and complete and `T` preserves limits, then `StructuredArrow S T` is
    well-powered. -/
instance wellPowered_structuredArrow [WellPowered C] [HasLimits C] [PreservesLimits T] :
    WellPowered (StructuredArrow S T) 
goal: CategoryTheory.WellPowered (CategoryTheory.StructuredArrow S T)

full_name: CategoryTheory.CostructuredArrow.projectQuotient
code: /-- Every quotient of a costructured arrow can be projected to a quotient of the underlying
    object. -/
def projectQuotient [HasColimits C] [PreservesColimits S] {A : CostructuredArrow S T} :
    Subobject (op A) → Subobject (op A.left) 
goal: CategoryTheory.Subobject (Opposite.op A) → CategoryTheory.Subobject (Opposite.op A.left)

full_name: CategoryTheory.CostructuredArrow.projectQuotient_mk
code: @[simp]
theorem projectQuotient_mk [HasColimits C] [PreservesColimits S] {A : CostructuredArrow S T}
    {P : (CostructuredArrow S T)ᵒᵖ} (f : P ⟶ op A) [Mono f] :
    projectQuotient (Subobject.mk f) = Subobject.mk f.unop.left.op 
goal: CategoryTheory.CostructuredArrow.projectQuotient (CategoryTheory.Subobject.mk f) =
  CategoryTheory.Subobject.mk f.unop.left.op

full_name: CategoryTheory.CostructuredArrow.projectQuotient_factors
code: theorem projectQuotient_factors [HasColimits C] [PreservesColimits S] {A : CostructuredArrow S T} :
    ∀ P : Subobject (op A), ∃ q, S.map (projectQuotient P).arrow.unop ≫ q = A.hom 
goal: ∃ q,
  CategoryTheory.CategoryStruct.comp (S.map (CategoryTheory.CostructuredArrow.projectQuotient P).arrow.unop) q = A.hom

full_name: CategoryTheory.CostructuredArrow.liftQuotient
code: /-- A quotient of the underlying object of a costructured arrow can be lifted to a quotient of
    the costructured arrow, provided that there is a morphism making the quotient into a
    costructured arrow. -/
@[simp]
def liftQuotient {A : CostructuredArrow S T} (P : Subobject (op A.left)) {q}
    (hq : S.map P.arrow.unop ≫ q = A.hom) : Subobject (op A) 
goal: CategoryTheory.Subobject (Opposite.op A)

full_name: CategoryTheory.CostructuredArrow.unop_left_comp_underlyingIso_hom_unop
code: /-- Technical lemma for `lift_projectQuotient`. -/
@[simp]
theorem unop_left_comp_underlyingIso_hom_unop {A : CostructuredArrow S T}
    {P : (CostructuredArrow S T)ᵒᵖ} (f : P ⟶ op A) [Mono f.unop.left.op] :
    f.unop.left ≫ (Subobject.underlyingIso f.unop.left.op).hom.unop =
      (Subobject.mk f.unop.left.op).arrow.unop 
goal: CategoryTheory.CategoryStruct.comp f.unop.left (CategoryTheory.Subobject.underlyingIso f.unop.left.op).hom.unop =
  (CategoryTheory.Subobject.mk f.unop.left.op).arrow.unop

full_name: CategoryTheory.CostructuredArrow.lift_projectQuotient
code: /-- Projecting and then lifting a quotient recovers the original quotient, because there is at most
    one morphism making the projected quotient into a costructured arrow. -/
theorem lift_projectQuotient [HasColimits C] [PreservesColimits S] {A : CostructuredArrow S T} :
    ∀ (P : Subobject (op A)) {q} (hq : S.map (projectQuotient P).arrow.unop ≫ q = A.hom),
      liftQuotient (projectQuotient P) hq = P 
goal: CategoryTheory.CostructuredArrow.liftQuotient (CategoryTheory.CostructuredArrow.projectQuotient P) hq = P

full_name: CategoryTheory.CostructuredArrow.unop_left_comp_ofMkLEMk_unop
code: /-- Technical lemma for `quotientEquiv`. -/
theorem unop_left_comp_ofMkLEMk_unop {A : CostructuredArrow S T} {P Q : (CostructuredArrow S T)ᵒᵖ}
    {f : P ⟶ op A} {g : Q ⟶ op A} [Mono f.unop.left.op] [Mono g.unop.left.op]
    (h : Subobject.mk f.unop.left.op ≤ Subobject.mk g.unop.left.op) :
    g.unop.left ≫ (Subobject.ofMkLEMk f.unop.left.op g.unop.left.op h).unop = f.unop.left 
goal: CategoryTheory.CategoryStruct.comp g.unop.left
    (CategoryTheory.Subobject.ofMkLEMk f.unop.left.op g.unop.left.op h).unop =
  f.unop.left

full_name: CategoryTheory.CostructuredArrow.quotientEquiv
code: /-- If `A : S.obj B ⟶ T` is a costructured arrow for `S : C ⥤ D` and `T : D`, then we can
    explicitly describe the quotients of `A` as the quotients `P` of `B` in `C` for which `A.hom`
    factors through the image of `P` under `S`. -/
def quotientEquiv [HasColimits C] [PreservesColimits S] (A : CostructuredArrow S T) :
    Subobject (op A) ≃o { P : Subobject (op A.left) // ∃ q, S.map P.arrow.unop ≫ q = A.hom } 
goal: CategoryTheory.Subobject (Opposite.op A) ≃o
  { P // ∃ q, CategoryTheory.CategoryStruct.comp (S.map P.arrow.unop) q = A.hom }

full_name: CategoryTheory.CostructuredArrow.well_copowered_costructuredArrow
code: /-- If `C` is well-copowered and cocomplete and `S` preserves colimits, then
    `CostructuredArrow S T` is well-copowered. -/
instance well_copowered_costructuredArrow [WellPowered Cᵒᵖ] [HasColimits C] [PreservesColimits S] :
    WellPowered (CostructuredArrow S T)ᵒᵖ 
goal: CategoryTheory.WellPowered (CategoryTheory.CostructuredArrow S T)ᵒᵖ