File: Mathlib/CategoryTheory/Limits/Shapes/DisjointCoproduct.lean

full_name: CategoryTheory.Limits.CoproductDisjoint
code: /-- Given any pullback diagram of the form

```
Z  ⟶ X₁
↓    ↓
X₂ ⟶ X
```

where `X₁ ⟶ X ← X₂` is a coproduct diagram, then `Z` is initial, and both `X₁ ⟶ X` and `X₂ ⟶ X`
are mono.
-/
class CoproductDisjoint (X₁ X₂ : C) where
  isInitialOfIsPullbackOfIsCoproduct :
    ∀ {X Z} {pX₁ : X₁ ⟶ X} {pX₂ : X₂ ⟶ X} {f : Z ⟶ X₁} {g : Z ⟶ X₂}
      (_cX : IsColimit (BinaryCofan.mk pX₁ pX₂)) {comm : f ≫ pX₁ = g ≫ pX₂},
      IsLimit (PullbackCone.mk _ _ comm) → IsInitial Z
  mono_inl : ∀ (X) (X₁ : X₁ ⟶ X) (X₂ : X₂ ⟶ X) (_cX : IsColimit (BinaryCofan.mk X₁ X₂)), Mono X₁
  mono_inr : ∀ (X) (X₁ : X₁ ⟶ X) (X₂ : X₂ ⟶ X) (_cX : IsColimit (BinaryCofan.mk X₁ X₂)), Mono X₂
goal: Type (max u v)

full_name: CategoryTheory.Limits.CoproductDisjoint.isInitialOfIsPullbackOfIsCoproduct
code: /-- Given any pullback diagram of the form

```
Z  ⟶ X₁
↓    ↓
X₂ ⟶ X
```

where `X₁ ⟶ X ← X₂` is a coproduct diagram, then `Z` is initial, and both `X₁ ⟶ X` and `X₂ ⟶ X`
are mono.
-/
class CoproductDisjoint (X₁ X₂ : C) where
  isInitialOfIsPullbackOfIsCoproduct :
    ∀ {X Z} {pX₁ : X₁ ⟶ X} {pX₂ : X₂ ⟶ X} {f : Z ⟶ X₁} {g : Z ⟶ X₂}
      (_cX : IsColimit (BinaryCofan.mk pX₁ pX₂)) {comm : f ≫ pX₁ = g ≫ pX₂},
      IsLimit (PullbackCone.mk _ _ comm) → IsInitial Z
  mono_inl : ∀ (X) (X₁ : X₁ ⟶ X) (X₂ : X₂ ⟶ X) (_cX : IsColimit (BinaryCofan.mk X₁ X₂)), Mono X₁
  mono_inr : ∀ (X) (X₁ : X₁ ⟶ X) (X₂ : X₂ ⟶ X) (_cX : IsColimit (BinaryCofan.mk X₁ X₂)), Mono X₂
goal: CategoryTheory.Limits.IsLimit (CategoryTheory.Limits.PullbackCone.mk f g comm) → CategoryTheory.Limits.IsInitial Z

full_name: CategoryTheory.Limits.CoproductDisjoint.mono_inr
code: /-- Given any pullback diagram of the form

```
Z  ⟶ X₁
↓    ↓
X₂ ⟶ X
```

where `X₁ ⟶ X ← X₂` is a coproduct diagram, then `Z` is initial, and both `X₁ ⟶ X` and `X₂ ⟶ X`
are mono.
-/
class CoproductDisjoint (X₁ X₂ : C) where
  isInitialOfIsPullbackOfIsCoproduct :
    ∀ {X Z} {pX₁ : X₁ ⟶ X} {pX₂ : X₂ ⟶ X} {f : Z ⟶ X₁} {g : Z ⟶ X₂}
      (_cX : IsColimit (BinaryCofan.mk pX₁ pX₂)) {comm : f ≫ pX₁ = g ≫ pX₂},
      IsLimit (PullbackCone.mk _ _ comm) → IsInitial Z
  mono_inl : ∀ (X) (X₁ : X₁ ⟶ X) (X₂ : X₂ ⟶ X) (_cX : IsColimit (BinaryCofan.mk X₁ X₂)), Mono X₁
  mono_inr : ∀ (X) (X₁ : X₁ ⟶ X) (X₂ : X₂ ⟶ X) (_cX : IsColimit (BinaryCofan.mk X₁ X₂)), Mono X₂
goal: ∀ (X₁_1 : X₁ ⟶ X) (X₂_1 : X₂ ⟶ X),
  CategoryTheory.Limits.IsColimit (CategoryTheory.Limits.BinaryCofan.mk X₁_1 X₂_1) → CategoryTheory.Mono X₂_1

full_name: CategoryTheory.Limits.CoproductDisjoint.mono_inl
code: /-- Given any pullback diagram of the form

```
Z  ⟶ X₁
↓    ↓
X₂ ⟶ X
```

where `X₁ ⟶ X ← X₂` is a coproduct diagram, then `Z` is initial, and both `X₁ ⟶ X` and `X₂ ⟶ X`
are mono.
-/
class CoproductDisjoint (X₁ X₂ : C) where
  isInitialOfIsPullbackOfIsCoproduct :
    ∀ {X Z} {pX₁ : X₁ ⟶ X} {pX₂ : X₂ ⟶ X} {f : Z ⟶ X₁} {g : Z ⟶ X₂}
      (_cX : IsColimit (BinaryCofan.mk pX₁ pX₂)) {comm : f ≫ pX₁ = g ≫ pX₂},
      IsLimit (PullbackCone.mk _ _ comm) → IsInitial Z
  mono_inl : ∀ (X) (X₁ : X₁ ⟶ X) (X₂ : X₂ ⟶ X) (_cX : IsColimit (BinaryCofan.mk X₁ X₂)), Mono X₁
  mono_inr : ∀ (X) (X₁ : X₁ ⟶ X) (X₂ : X₂ ⟶ X) (_cX : IsColimit (BinaryCofan.mk X₁ X₂)), Mono X₂
goal: ∀ (X₁_1 : X₁ ⟶ X) (X₂_1 : X₂ ⟶ X),
  CategoryTheory.Limits.IsColimit (CategoryTheory.Limits.BinaryCofan.mk X₁_1 X₂_1) → CategoryTheory.Mono X₁_1

full_name: CategoryTheory.Limits.isInitialOfIsPullbackOfIsCoproduct
code: /-- If the coproduct of `X₁` and `X₂` is disjoint, then given any pullback square

```
Z  ⟶ X₁
↓    ↓
X₂ ⟶ X
```

where `X₁ ⟶ X ← X₂` is a coproduct, then `Z` is initial.
-/
def isInitialOfIsPullbackOfIsCoproduct {Z X₁ X₂ X : C} [CoproductDisjoint X₁ X₂] {pX₁ : X₁ ⟶ X}
    {pX₂ : X₂ ⟶ X} (cX : IsColimit (BinaryCofan.mk pX₁ pX₂)) {f : Z ⟶ X₁} {g : Z ⟶ X₂}
    {comm : f ≫ pX₁ = g ≫ pX₂} (cZ : IsLimit (PullbackCone.mk _ _ comm)) : IsInitial Z 
goal: CategoryTheory.Limits.IsInitial Z

full_name: CategoryTheory.Limits.isInitialOfIsPullbackOfCoproduct
code: /-- If the coproduct of `X₁` and `X₂` is disjoint, then given any pullback square

```
Z  ⟶    X₁
↓       ↓
X₂ ⟶ X₁ ⨿ X₂
```

`Z` is initial.
-/
noncomputable def isInitialOfIsPullbackOfCoproduct {Z X₁ X₂ : C} [HasBinaryCoproduct X₁ X₂]
    [CoproductDisjoint X₁ X₂] {f : Z ⟶ X₁} {g : Z ⟶ X₂}
    {comm : f ≫ (coprod.inl : X₁ ⟶ _ ⨿ X₂) = g ≫ coprod.inr}
    (cZ : IsLimit (PullbackCone.mk _ _ comm)) : IsInitial Z 
goal: CategoryTheory.Limits.IsInitial Z

full_name: CategoryTheory.Limits.isInitialOfPullbackOfIsCoproduct
code: /-- If the coproduct of `X₁` and `X₂` is disjoint, then provided `X₁ ⟶ X ← X₂` is a coproduct the
pullback is an initial object:

```
     X₁
     ↓
X₂ ⟶ X
```
-/
noncomputable def isInitialOfPullbackOfIsCoproduct {X X₁ X₂ : C} [CoproductDisjoint X₁ X₂]
    {pX₁ : X₁ ⟶ X} {pX₂ : X₂ ⟶ X} [HasPullback pX₁ pX₂] (cX : IsColimit (BinaryCofan.mk pX₁ pX₂)) :
    IsInitial (pullback pX₁ pX₂) 
goal: CategoryTheory.Limits.IsInitial (CategoryTheory.Limits.pullback pX₁ pX₂)

full_name: CategoryTheory.Limits.isInitialOfPullbackOfCoproduct
code: /-- If the coproduct of `X₁` and `X₂` is disjoint, the pullback of `X₁ ⟶ X₁ ⨿ X₂` and `X₂ ⟶ X₁ ⨿ X₂`
is initial.
-/
noncomputable def isInitialOfPullbackOfCoproduct {X₁ X₂ : C} [HasBinaryCoproduct X₁ X₂]
    [CoproductDisjoint X₁ X₂] [HasPullback (coprod.inl : X₁ ⟶ _ ⨿ X₂) coprod.inr] :
    IsInitial (pullback (coprod.inl : X₁ ⟶ _ ⨿ X₂) coprod.inr) 
goal: CategoryTheory.Limits.IsInitial
  (CategoryTheory.Limits.pullback CategoryTheory.Limits.coprod.inl CategoryTheory.Limits.coprod.inr)

full_name: CategoryTheory.Limits.instMonoInlOfCoproductDisjoint
code: instance {X₁ X₂ : C} [HasBinaryCoproduct X₁ X₂] [CoproductDisjoint X₁ X₂] :
    Mono (coprod.inl : X₁ ⟶ X₁ ⨿ X₂) 
goal: CategoryTheory.Mono CategoryTheory.Limits.coprod.inl

full_name: CategoryTheory.Limits.instMonoInrOfCoproductDisjoint
code: instance {X₁ X₂ : C} [HasBinaryCoproduct X₁ X₂] [CoproductDisjoint X₁ X₂] :
    Mono (coprod.inr : X₂ ⟶ X₁ ⨿ X₂) 
goal: CategoryTheory.Mono CategoryTheory.Limits.coprod.inr

full_name: CategoryTheory.Limits.CoproductsDisjoint.CoproductDisjoint
code: /-- `C` has disjoint coproducts if every coproduct is disjoint. -/
class CoproductsDisjoint (C : Type u) [Category.{v} C] where
  CoproductDisjoint : ∀ X Y : C, CoproductDisjoint X Y
goal: CategoryTheory.Limits.CoproductDisjoint X Y

full_name: CategoryTheory.Limits.CoproductsDisjoint
code: /-- `C` has disjoint coproducts if every coproduct is disjoint. -/
class CoproductsDisjoint (C : Type u) [Category.{v} C] where
  CoproductDisjoint : ∀ X Y : C, CoproductDisjoint X Y
goal: Type (max u v)

full_name: CategoryTheory.Limits.initialMonoClass_of_disjoint_coproducts
code: /-- If `C` has disjoint coproducts, any morphism out of initial is mono. Note it isn't true in
general that `C` has strict initial objects, for instance consider the category of types and
partial functions. -/
theorem initialMonoClass_of_disjoint_coproducts [CoproductsDisjoint C] : InitialMonoClass C 
goal: CategoryTheory.Limits.InitialMonoClass C