l3lab/ntp-mathlib huggingface dataset:
theorem hom_ext (f g : X ⟶ Y) (h : ∀ n : ℕ, s.φ f n = s.φ g n) : f = g := by
  ext Δ
  apply s.hom_ext'
  intro A
  induction' Δ using Opposite.rec with Δ
  induction' Δ using SimplexCategory.rec with n
  dsimp
  

Proof state:
case h.h.mk.h
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
X Y : SimplicialObject C
s : Splitting X
f g : X ⟶ Y
h : ∀ (n : ℕ), φ s f n = φ s g n
n : ℕ
A : IndexSet { unop := [n] }
⊢ ιSummand s A ≫ f.app { unop := [n] } = ιSummand s A ≫ g.app { unop := [n] }

Next tactic:
simp only [s.ιSummand_comp_app, h]
@[reassoc (attr := simp)]
theorem ι_desc {Z : C} (Δ : SimplexCategoryᵒᵖ) (F : ∀ A : IndexSet Δ, s.N A.1.unop.len ⟶ Z)
    (A : IndexSet Δ) : s.ιSummand A ≫ s.desc Δ F = F A := by
  

Proof state:
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
X Y : SimplicialObject C
s : Splitting X
Z : C
Δ : SimplexCategoryᵒᵖ
F : (A : IndexSet Δ) → N s (len A.fst.unop) ⟶ Z
A : IndexSet Δ
⊢ ιSummand s A ≫ desc s Δ F = F A

Next tactic:
dsimp only [ιSummand, desc]
@[reassoc (attr := simp)]
theorem ι_desc {Z : C} (Δ : SimplexCategoryᵒᵖ) (F : ∀ A : IndexSet Δ, s.N A.1.unop.len ⟶ Z)
    (A : IndexSet Δ) : s.ιSummand A ≫ s.desc Δ F = F A := by
  dsimp only [ιSummand, desc]
  

Proof state:
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
X Y : SimplicialObject C
s : Splitting X
Z : C
Δ : SimplexCategoryᵒᵖ
F : (A : IndexSet Δ) → N s (len A.fst.unop) ⟶ Z
A : IndexSet Δ
⊢ (ιCoprod s.N A ≫ (iso s Δ).hom) ≫ (iso s Δ).inv ≫ Sigma.desc F = F A

Next tactic:
simp only [assoc, Iso.hom_inv_id_assoc, ιCoprod]
@[reassoc (attr := simp)]
theorem ι_desc {Z : C} (Δ : SimplexCategoryᵒᵖ) (F : ∀ A : IndexSet Δ, s.N A.1.unop.len ⟶ Z)
    (A : IndexSet Δ) : s.ιSummand A ≫ s.desc Δ F = F A := by
  dsimp only [ιSummand, desc]
  simp only [assoc, Iso.hom_inv_id_assoc, ιCoprod]
  

Proof state:
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
X Y : SimplicialObject C
s : Splitting X
Z : C
Δ : SimplexCategoryᵒᵖ
F : (A : IndexSet Δ) → N s (len A.fst.unop) ⟶ Z
A : IndexSet Δ
⊢ Sigma.ι (summand s.N Δ) A ≫ Sigma.desc F = F A

Next tactic:
erw [colimit.ι_desc, Cofan.mk_ι_app]
/-- A simplicial object that is isomorphic to a split simplicial object is split. -/
@[simps]
def ofIso (e : X ≅ Y) : Splitting Y where
  N := s.N
  ι n := s.ι n ≫ e.hom.app (op [n])
  map_isIso Δ := by
    

Proof state:
C : Type u_1
inst✝¹ : Category.{?u.155289, u_1} C
inst✝ : HasFiniteCoproducts C
X Y : SimplicialObject C
s : Splitting X
e : X ≅ Y
Δ : SimplexCategoryᵒᵖ
⊢ IsIso (map Y (fun n => ι s n ≫ e.hom.app (op [n])) Δ)

Next tactic:
convert (inferInstance : IsIso ((s.iso Δ).hom ≫ e.hom.app Δ))
/-- A simplicial object that is isomorphic to a split simplicial object is split. -/
@[simps]
def ofIso (e : X ≅ Y) : Splitting Y where
  N := s.N
  ι n := s.ι n ≫ e.hom.app (op [n])
  map_isIso Δ := by
    convert (inferInstance : IsIso ((s.iso Δ).hom ≫ e.hom.app Δ))
    

Proof state:
case h.e'_5
C : Type u_1
inst✝¹ : Category.{?u.155289, u_1} C
inst✝ : HasFiniteCoproducts C
X Y : SimplicialObject C
s : Splitting X
e : X ≅ Y
Δ : SimplexCategoryᵒᵖ
⊢ map Y (fun n => ι s n ≫ e.hom.app (op [n])) Δ = (iso s Δ).hom ≫ e.hom.app Δ

Next tactic:
ext
/-- A simplicial object that is isomorphic to a split simplicial object is split. -/
@[simps]
def ofIso (e : X ≅ Y) : Splitting Y where
  N := s.N
  ι n := s.ι n ≫ e.hom.app (op [n])
  map_isIso Δ := by
    convert (inferInstance : IsIso ((s.iso Δ).hom ≫ e.hom.app Δ))
    ext
    

Proof state:
case h.e'_5.h
C : Type u_1
inst✝¹ : Category.{?u.155289, u_1} C
inst✝ : HasFiniteCoproducts C
X Y : SimplicialObject C
s : Splitting X
e : X ≅ Y
Δ : SimplexCategoryᵒᵖ
b✝ : IndexSet Δ
⊢ Sigma.ι (summand (fun n => N s n) Δ) b✝ ≫ map Y (fun n => ι s n ≫ e.hom.app (op [n])) Δ =
    Sigma.ι (summand (fun n => N s n) Δ) b✝ ≫ (iso s Δ).hom ≫ e.hom.app Δ

Next tactic:
simp [map]
@[reassoc]
theorem ιSummand_epi_naturality {Δ₁ Δ₂ : SimplexCategoryᵒᵖ} (A : IndexSet Δ₁) (p : Δ₁ ⟶ Δ₂)
    [Epi p.unop] : s.ιSummand A ≫ X.map p = s.ιSummand (A.epiComp p) := by
  

Proof state:
C : Type u_1
inst✝² : Category.{u_2, u_1} C
inst✝¹ : HasFiniteCoproducts C
X Y : SimplicialObject C
s : Splitting X
Δ₁ Δ₂ : SimplexCategoryᵒᵖ
A : IndexSet Δ₁
p : Δ₁ ⟶ Δ₂
inst✝ : Epi p.unop
⊢ ιSummand s A ≫ X.map p = ιSummand s (IndexSet.epiComp A p)

Next tactic:
dsimp [ιSummand]
@[reassoc]
theorem ιSummand_epi_naturality {Δ₁ Δ₂ : SimplexCategoryᵒᵖ} (A : IndexSet Δ₁) (p : Δ₁ ⟶ Δ₂)
    [Epi p.unop] : s.ιSummand A ≫ X.map p = s.ιSummand (A.epiComp p) := by
  dsimp [ιSummand]
  

Proof state:
C : Type u_1
inst✝² : Category.{u_2, u_1} C
inst✝¹ : HasFiniteCoproducts C
X Y : SimplicialObject C
s : Splitting X
Δ₁ Δ₂ : SimplexCategoryᵒᵖ
A : IndexSet Δ₁
p : Δ₁ ⟶ Δ₂
inst✝ : Epi p.unop
⊢ (Sigma.ι (summand s.N Δ₁) A ≫ Sigma.desc fun A => ι s (len A.fst.unop) ≫ X.map (IndexSet.e A).op) ≫ X.map p =
    Sigma.ι (summand s.N Δ₂) (IndexSet.epiComp A p) ≫ Sigma.desc fun A => ι s (len A.fst.unop) ≫ X.map (IndexSet.e A).op

Next tactic:
erw [colimit.ι_desc, colimit.ι_desc, Cofan.mk_ι_app, Cofan.mk_ι_app]
@[reassoc]
theorem ιSummand_epi_naturality {Δ₁ Δ₂ : SimplexCategoryᵒᵖ} (A : IndexSet Δ₁) (p : Δ₁ ⟶ Δ₂)
    [Epi p.unop] : s.ιSummand A ≫ X.map p = s.ιSummand (A.epiComp p) := by
  dsimp [ιSummand]
  erw [colimit.ι_desc, colimit.ι_desc, Cofan.mk_ι_app, Cofan.mk_ι_app]
  

Proof state:
C : Type u_1
inst✝² : Category.{u_2, u_1} C
inst✝¹ : HasFiniteCoproducts C
X Y : SimplicialObject C
s : Splitting X
Δ₁ Δ₂ : SimplexCategoryᵒᵖ
A : IndexSet Δ₁
p : Δ₁ ⟶ Δ₂
inst✝ : Epi p.unop
⊢ (ι s (len { as := A }.as.fst.unop) ≫ X.map (IndexSet.e { as := A }.as).op) ≫ X.map p =
    ι s (len { as := IndexSet.epiComp A p }.as.fst.unop) ≫ X.map (IndexSet.e { as := IndexSet.epiComp A p }.as).op

Next tactic:
dsimp only [IndexSet.epiComp, IndexSet.e]
@[reassoc]
theorem ιSummand_epi_naturality {Δ₁ Δ₂ : SimplexCategoryᵒᵖ} (A : IndexSet Δ₁) (p : Δ₁ ⟶ Δ₂)
    [Epi p.unop] : s.ιSummand A ≫ X.map p = s.ιSummand (A.epiComp p) := by
  dsimp [ιSummand]
  erw [colimit.ι_desc, colimit.ι_desc, Cofan.mk_ι_app, Cofan.mk_ι_app]
  dsimp only [IndexSet.epiComp, IndexSet.e]
  

Proof state:
C : Type u_1
inst✝² : Category.{u_2, u_1} C
inst✝¹ : HasFiniteCoproducts C
X Y : SimplicialObject C
s : Splitting X
Δ₁ Δ₂ : SimplexCategoryᵒᵖ
A : IndexSet Δ₁
p : Δ₁ ⟶ Δ₂
inst✝ : Epi p.unop
⊢ (ι s (len A.fst.unop) ≫ X.map (↑A.snd).op) ≫ X.map p = ι s (len A.fst.unop) ≫ X.map (p.unop ≫ ↑A.snd).op

Next tactic:
rw [op_comp, X.map_comp, assoc, Quiver.Hom.op_unop]
@[ext]
theorem Hom.ext {S₁ S₂ : Split C} (Φ₁ Φ₂ : Hom S₁ S₂) (h : ∀ n : ℕ, Φ₁.f n = Φ₂.f n) : Φ₁ = Φ₂ := by
  

Proof state:
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
Φ₁ Φ₂ : Hom S₁ S₂
h : ∀ (n : ℕ), f Φ₁ n = f Φ₂ n
⊢ Φ₁ = Φ₂

Next tactic:
rcases Φ₁ with ⟨F₁, f₁, c₁⟩
@[ext]
theorem Hom.ext {S₁ S₂ : Split C} (Φ₁ Φ₂ : Hom S₁ S₂) (h : ∀ n : ℕ, Φ₁.f n = Φ₂.f n) : Φ₁ = Φ₂ := by
  rcases Φ₁ with ⟨F₁, f₁, c₁⟩
  

Proof state:
case mk
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
Φ₂ : Hom S₁ S₂
F₁ : S₁.X ⟶ S₂.X
f₁ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₁ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₁.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
h : ∀ (n : ℕ), f (mk F₁ f₁) n = f Φ₂ n
⊢ mk F₁ f₁ = Φ₂

Next tactic:
rcases Φ₂ with ⟨F₂, f₂, c₂⟩
@[ext]
theorem Hom.ext {S₁ S₂ : Split C} (Φ₁ Φ₂ : Hom S₁ S₂) (h : ∀ n : ℕ, Φ₁.f n = Φ₂.f n) : Φ₁ = Φ₂ := by
  rcases Φ₁ with ⟨F₁, f₁, c₁⟩
  rcases Φ₂ with ⟨F₂, f₂, c₂⟩
  

Proof state:
case mk.mk
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
F₁ : S₁.X ⟶ S₂.X
f₁ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₁ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₁.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
F₂ : S₁.X ⟶ S₂.X
f₂ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₂ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₂.app (op [n]) = f₂ n ≫ Splitting.ι S₂.s n
h : ∀ (n : ℕ), f (mk F₁ f₁) n = f (mk F₂ f₂) n
⊢ mk F₁ f₁ = mk F₂ f₂

Next tactic:
have h' : f₁ = f₂ := by
    ext
    apply h
@[ext]
theorem Hom.ext {S₁ S₂ : Split C} (Φ₁ Φ₂ : Hom S₁ S₂) (h : ∀ n : ℕ, Φ₁.f n = Φ₂.f n) : Φ₁ = Φ₂ := by
  rcases Φ₁ with ⟨F₁, f₁, c₁⟩
  rcases Φ₂ with ⟨F₂, f₂, c₂⟩
  have h' : f₁ = f₂ := by
    

Proof state:
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
F₁ : S₁.X ⟶ S₂.X
f₁ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₁ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₁.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
F₂ : S₁.X ⟶ S₂.X
f₂ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₂ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₂.app (op [n]) = f₂ n ≫ Splitting.ι S₂.s n
h : ∀ (n : ℕ), f (mk F₁ f₁) n = f (mk F₂ f₂) n
⊢ f₁ = f₂

Next tactic:
ext
@[ext]
theorem Hom.ext {S₁ S₂ : Split C} (Φ₁ Φ₂ : Hom S₁ S₂) (h : ∀ n : ℕ, Φ₁.f n = Φ₂.f n) : Φ₁ = Φ₂ := by
  rcases Φ₁ with ⟨F₁, f₁, c₁⟩
  rcases Φ₂ with ⟨F₂, f₂, c₂⟩
  have h' : f₁ = f₂ := by
    ext
    

Proof state:
case h
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
F₁ : S₁.X ⟶ S₂.X
f₁ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₁ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₁.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
F₂ : S₁.X ⟶ S₂.X
f₂ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₂ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₂.app (op [n]) = f₂ n ≫ Splitting.ι S₂.s n
h : ∀ (n : ℕ), f (mk F₁ f₁) n = f (mk F₂ f₂) n
x✝ : ℕ
⊢ f₁ x✝ = f₂ x✝

Next tactic:
apply h
@[ext]
theorem Hom.ext {S₁ S₂ : Split C} (Φ₁ Φ₂ : Hom S₁ S₂) (h : ∀ n : ℕ, Φ₁.f n = Φ₂.f n) : Φ₁ = Φ₂ := by
  rcases Φ₁ with ⟨F₁, f₁, c₁⟩
  rcases Φ₂ with ⟨F₂, f₂, c₂⟩
  have h' : f₁ = f₂ := by
    ext
    apply h
  

Proof state:
case mk.mk
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
F₁ : S₁.X ⟶ S₂.X
f₁ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₁ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₁.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
F₂ : S₁.X ⟶ S₂.X
f₂ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₂ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₂.app (op [n]) = f₂ n ≫ Splitting.ι S₂.s n
h : ∀ (n : ℕ), f (mk F₁ f₁) n = f (mk F₂ f₂) n
h' : f₁ = f₂
⊢ mk F₁ f₁ = mk F₂ f₂

Next tactic:
subst h'
@[ext]
theorem Hom.ext {S₁ S₂ : Split C} (Φ₁ Φ₂ : Hom S₁ S₂) (h : ∀ n : ℕ, Φ₁.f n = Φ₂.f n) : Φ₁ = Φ₂ := by
  rcases Φ₁ with ⟨F₁, f₁, c₁⟩
  rcases Φ₂ with ⟨F₂, f₂, c₂⟩
  have h' : f₁ = f₂ := by
    ext
    apply h
  subst h'
  

Proof state:
case mk.mk
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
F₁ : S₁.X ⟶ S₂.X
f₁ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₁ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₁.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
F₂ : S₁.X ⟶ S₂.X
c₂ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₂.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
h : ∀ (n : ℕ), f (mk F₁ f₁) n = f (mk F₂ f₁) n
⊢ mk F₁ f₁ = mk F₂ f₁

Next tactic:
simp only [mk.injEq, and_true]
@[ext]
theorem Hom.ext {S₁ S₂ : Split C} (Φ₁ Φ₂ : Hom S₁ S₂) (h : ∀ n : ℕ, Φ₁.f n = Φ₂.f n) : Φ₁ = Φ₂ := by
  rcases Φ₁ with ⟨F₁, f₁, c₁⟩
  rcases Φ₂ with ⟨F₂, f₂, c₂⟩
  have h' : f₁ = f₂ := by
    ext
    apply h
  subst h'
  simp only [mk.injEq, and_true]
  

Proof state:
case mk.mk
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
F₁ : S₁.X ⟶ S₂.X
f₁ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₁ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₁.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
F₂ : S₁.X ⟶ S₂.X
c₂ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₂.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
h : ∀ (n : ℕ), f (mk F₁ f₁) n = f (mk F₂ f₁) n
⊢ F₁ = F₂

Next tactic:
apply S₁.s.hom_ext
@[ext]
theorem Hom.ext {S₁ S₂ : Split C} (Φ₁ Φ₂ : Hom S₁ S₂) (h : ∀ n : ℕ, Φ₁.f n = Φ₂.f n) : Φ₁ = Φ₂ := by
  rcases Φ₁ with ⟨F₁, f₁, c₁⟩
  rcases Φ₂ with ⟨F₂, f₂, c₂⟩
  have h' : f₁ = f₂ := by
    ext
    apply h
  subst h'
  simp only [mk.injEq, and_true]
  apply S₁.s.hom_ext
  

Proof state:
case mk.mk.h
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
F₁ : S₁.X ⟶ S₂.X
f₁ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₁ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₁.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
F₂ : S₁.X ⟶ S₂.X
c₂ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₂.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
h : ∀ (n : ℕ), f (mk F₁ f₁) n = f (mk F₂ f₁) n
⊢ ∀ (n : ℕ), Splitting.φ S₁.s F₁ n = Splitting.φ S₁.s F₂ n

Next tactic:
intro n
@[ext]
theorem Hom.ext {S₁ S₂ : Split C} (Φ₁ Φ₂ : Hom S₁ S₂) (h : ∀ n : ℕ, Φ₁.f n = Φ₂.f n) : Φ₁ = Φ₂ := by
  rcases Φ₁ with ⟨F₁, f₁, c₁⟩
  rcases Φ₂ with ⟨F₂, f₂, c₂⟩
  have h' : f₁ = f₂ := by
    ext
    apply h
  subst h'
  simp only [mk.injEq, and_true]
  apply S₁.s.hom_ext
  intro n
  

Proof state:
case mk.mk.h
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
F₁ : S₁.X ⟶ S₂.X
f₁ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₁ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₁.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
F₂ : S₁.X ⟶ S₂.X
c₂ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₂.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
h : ∀ (n : ℕ), f (mk F₁ f₁) n = f (mk F₂ f₁) n
n : ℕ
⊢ Splitting.φ S₁.s F₁ n = Splitting.φ S₁.s F₂ n

Next tactic:
dsimp
@[ext]
theorem Hom.ext {S₁ S₂ : Split C} (Φ₁ Φ₂ : Hom S₁ S₂) (h : ∀ n : ℕ, Φ₁.f n = Φ₂.f n) : Φ₁ = Φ₂ := by
  rcases Φ₁ with ⟨F₁, f₁, c₁⟩
  rcases Φ₂ with ⟨F₂, f₂, c₂⟩
  have h' : f₁ = f₂ := by
    ext
    apply h
  subst h'
  simp only [mk.injEq, and_true]
  apply S₁.s.hom_ext
  intro n
  dsimp
  

Proof state:
case mk.mk.h
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
F₁ : S₁.X ⟶ S₂.X
f₁ : (n : ℕ) → Splitting.N S₁.s n ⟶ Splitting.N S₂.s n
c₁ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₁.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
F₂ : S₁.X ⟶ S₂.X
c₂ : ∀ (n : ℕ), Splitting.ι S₁.s n ≫ F₂.app (op [n]) = f₁ n ≫ Splitting.ι S₂.s n
h : ∀ (n : ℕ), f (mk F₁ f₁) n = f (mk F₂ f₁) n
n : ℕ
⊢ Splitting.ι S₁.s n ≫ F₁.app (op [n]) = Splitting.ι S₁.s n ≫ F₂.app (op [n])

Next tactic:
rw [c₁, c₂]
instance : Category (Split C) where
  Hom := Split.Hom
  id S :=
    { F := 𝟙 _
      f := fun n => 𝟙 _ }
  comp Φ₁₂ Φ₂₃ :=
    { F := Φ₁₂.F ≫ Φ₂₃.F
      f := fun n => Φ₁₂.f n ≫ Φ₂₃.f n
      comm := fun n => by
        

Proof state:
C : Type u_1
inst✝¹ : Category.{?u.193748, u_1} C
inst✝ : HasFiniteCoproducts C
X✝ Y✝ Z✝ : Split C
Φ₁₂ : X✝ ⟶ Y✝
Φ₂₃ : Y✝ ⟶ Z✝
n : ℕ
⊢ Splitting.ι X✝.s n ≫ (Φ₁₂.F ≫ Φ₂₃.F).app (op [n]) =
    (fun n => Split.Hom.f Φ₁₂ n ≫ Split.Hom.f Φ₂₃ n) n ≫ Splitting.ι Z✝.s n

Next tactic:
dsimp
instance : Category (Split C) where
  Hom := Split.Hom
  id S :=
    { F := 𝟙 _
      f := fun n => 𝟙 _ }
  comp Φ₁₂ Φ₂₃ :=
    { F := Φ₁₂.F ≫ Φ₂₃.F
      f := fun n => Φ₁₂.f n ≫ Φ₂₃.f n
      comm := fun n => by
        dsimp
        

Proof state:
C : Type u_1
inst✝¹ : Category.{?u.193748, u_1} C
inst✝ : HasFiniteCoproducts C
X✝ Y✝ Z✝ : Split C
Φ₁₂ : X✝ ⟶ Y✝
Φ₂₃ : Y✝ ⟶ Z✝
n : ℕ
⊢ Splitting.ι X✝.s n ≫ Φ₁₂.F.app (op [n]) ≫ Φ₂₃.F.app (op [n]) =
    (Split.Hom.f Φ₁₂ n ≫ Split.Hom.f Φ₂₃ n) ≫ Splitting.ι Z✝.s n

Next tactic:
simp only [assoc, Split.Hom.comm_assoc, Split.Hom.comm]
theorem congr_F {S₁ S₂ : Split C} {Φ₁ Φ₂ : S₁ ⟶ S₂} (h : Φ₁ = Φ₂) : Φ₁.f = Φ₂.f := by 

Proof state:
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
Φ₁ Φ₂ : S₁ ⟶ S₂
h : Φ₁ = Φ₂
⊢ Φ₁.f = Φ₂.f

Next tactic:
rw [h]
theorem congr_f {S₁ S₂ : Split C} {Φ₁ Φ₂ : S₁ ⟶ S₂} (h : Φ₁ = Φ₂) (n : ℕ) : Φ₁.f n = Φ₂.f n := by
  

Proof state:
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
Φ₁ Φ₂ : S₁ ⟶ S₂
h : Φ₁ = Φ₂
n : ℕ
⊢ Hom.f Φ₁ n = Hom.f Φ₂ n

Next tactic:
rw [h]
@[reassoc (attr := simp 1100)]
theorem ιSummand_naturality_symm {S₁ S₂ : Split C} (Φ : S₁ ⟶ S₂) {Δ : SimplexCategoryᵒᵖ}
    (A : Splitting.IndexSet Δ) :
    S₁.s.ιSummand A ≫ Φ.F.app Δ = Φ.f A.1.unop.len ≫ S₂.s.ιSummand A := by
  

Proof state:
C : Type u_1
inst✝¹ : Category.{u_2, u_1} C
inst✝ : HasFiniteCoproducts C
S₁ S₂ : Split C
Φ : S₁ ⟶ S₂
Δ : SimplexCategoryᵒᵖ
A : Splitting.IndexSet Δ
⊢ Splitting.ιSummand S₁.s A ≫ Φ.F.app Δ = Hom.f Φ (len A.fst.unop) ≫ Splitting.ιSummand S₂.s A

Next tactic:
erw [S₁.s.ιSummand_eq, S₂.s.ιSummand_eq, assoc, Φ.F.naturality, ← Φ.comm_assoc ]
example {C} [Category C] {X Y : C} (f : X ⟶ Y) : 𝟙 X ≫ f = f := by 

Proof state:
C : Type ?u.30656
inst✝ : Category.{?u.30657, ?u.30656} C
X Y : C
f : X ⟶ Y
⊢ 𝟙 X ≫ f = f

Next tactic:
simp
example {C} [Category C] {X Y : C} (f : X ⟶ Y) : f ≫ 𝟙 Y = f := by 

Proof state:
C : Type ?u.30824
inst✝ : Category.{?u.30825, ?u.30824} C
X Y : C
f : X ⟶ Y
⊢ f ≫ 𝟙 Y = f

Next tactic:
simp
/-- postcompose an equation between morphisms by another morphism -/
theorem eq_whisker {f g : X ⟶ Y} (w : f = g) (h : Y ⟶ Z) : f ≫ h = g ≫ h := by 

Proof state:
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
f g : X ⟶ Y
w : f = g
h : Y ⟶ Z
⊢ f ≫ h = g ≫ h

Next tactic:
rw [w]
/-- precompose an equation between morphisms by another morphism -/
theorem whisker_eq (f : X ⟶ Y) {g h : Y ⟶ Z} (w : g = h) : f ≫ g = f ≫ h := by 

Proof state:
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
f : X ⟶ Y
g h : Y ⟶ Z
w : g = h
⊢ f ≫ g = f ≫ h

Next tactic:
rw [w]
theorem eq_of_comp_left_eq {f g : X ⟶ Y} (w : ∀ {Z : C} (h : Y ⟶ Z), f ≫ h = g ≫ h) :
    f = g := by
  

Proof state:
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
f g : X ⟶ Y
w : ∀ {Z : C} (h : Y ⟶ Z), f ≫ h = g ≫ h
⊢ f = g

Next tactic:
convert w (𝟙 Y)
theorem eq_of_comp_left_eq {f g : X ⟶ Y} (w : ∀ {Z : C} (h : Y ⟶ Z), f ≫ h = g ≫ h) :
    f = g := by
  convert w (𝟙 Y) <;> 

Proof state:
case h.e'_2
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
f g : X ⟶ Y
w : ∀ {Z : C} (h : Y ⟶ Z), f ≫ h = g ≫ h
⊢ f = f ≫ 𝟙 Y

Next tactic:
simp
theorem eq_of_comp_left_eq {f g : X ⟶ Y} (w : ∀ {Z : C} (h : Y ⟶ Z), f ≫ h = g ≫ h) :
    f = g := by
  convert w (𝟙 Y) <;> 

Proof state:
case h.e'_3
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
f g : X ⟶ Y
w : ∀ {Z : C} (h : Y ⟶ Z), f ≫ h = g ≫ h
⊢ g = g ≫ 𝟙 Y

Next tactic:
simp
theorem eq_of_comp_right_eq {f g : Y ⟶ Z} (w : ∀ {X : C} (h : X ⟶ Y), h ≫ f = h ≫ g) :
    f = g := by
  

Proof state:
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
f g : Y ⟶ Z
w : ∀ {X : C} (h : X ⟶ Y), h ≫ f = h ≫ g
⊢ f = g

Next tactic:
convert w (𝟙 Y)
theorem eq_of_comp_right_eq {f g : Y ⟶ Z} (w : ∀ {X : C} (h : X ⟶ Y), h ≫ f = h ≫ g) :
    f = g := by
  convert w (𝟙 Y) <;> 

Proof state:
case h.e'_2
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
f g : Y ⟶ Z
w : ∀ {X : C} (h : X ⟶ Y), h ≫ f = h ≫ g
⊢ f = 𝟙 Y ≫ f

Next tactic:
simp
theorem eq_of_comp_right_eq {f g : Y ⟶ Z} (w : ∀ {X : C} (h : X ⟶ Y), h ≫ f = h ≫ g) :
    f = g := by
  convert w (𝟙 Y) <;> 

Proof state:
case h.e'_3
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
f g : Y ⟶ Z
w : ∀ {X : C} (h : X ⟶ Y), h ≫ f = h ≫ g
⊢ g = 𝟙 Y ≫ g

Next tactic:
simp
theorem eq_of_comp_left_eq' (f g : X ⟶ Y)
    (w : (fun {Z} (h : Y ⟶ Z) => f ≫ h) = fun {Z} (h : Y ⟶ Z) => g ≫ h) : f = g :=
  eq_of_comp_left_eq @fun Z h => by 

Proof state:
C : Type u
inst✝ : Category.{v, u} C
X Y Z✝ : C
f g : X ⟶ Y
w : (fun {Z} h => f ≫ h) = fun {Z} h => g ≫ h
Z : C
h : Y ⟶ Z
⊢ f ≫ h = g ≫ h

Next tactic:
convert congr_fun (congr_fun w Z) h
theorem eq_of_comp_right_eq' (f g : Y ⟶ Z)
    (w : (fun {X} (h : X ⟶ Y) => h ≫ f) = fun {X} (h : X ⟶ Y) => h ≫ g) : f = g :=
  eq_of_comp_right_eq @fun X h => by 

Proof state:
C : Type u
inst✝ : Category.{v, u} C
X✝ Y Z : C
f g : Y ⟶ Z
w : (fun {X} h => h ≫ f) = fun {X} h => h ≫ g
X : C
h : X ⟶ Y
⊢ h ≫ f = h ≫ g

Next tactic:
convert congr_fun (congr_fun w X) h
theorem id_of_comp_left_id (f : X ⟶ X) (w : ∀ {Y : C} (g : X ⟶ Y), f ≫ g = g) : f = 𝟙 X := by
  

Proof state:
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
f : X ⟶ X
w : ∀ {Y : C} (g : X ⟶ Y), f ≫ g = g
⊢ f = 𝟙 X

Next tactic:
convert w (𝟙 X)
theorem id_of_comp_left_id (f : X ⟶ X) (w : ∀ {Y : C} (g : X ⟶ Y), f ≫ g = g) : f = 𝟙 X := by
  convert w (𝟙 X)
  

Proof state:
case h.e'_2
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
f : X ⟶ X
w : ∀ {Y : C} (g : X ⟶ Y), f ≫ g = g
⊢ f = f ≫ 𝟙 X

Next tactic:
simp
theorem id_of_comp_right_id (f : X ⟶ X) (w : ∀ {Y : C} (g : Y ⟶ X), g ≫ f = g) : f = 𝟙 X := by
  

Proof state:
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
f : X ⟶ X
w : ∀ {Y : C} (g : Y ⟶ X), g ≫ f = g
⊢ f = 𝟙 X

Next tactic:
convert w (𝟙 X)
theorem id_of_comp_right_id (f : X ⟶ X) (w : ∀ {Y : C} (g : Y ⟶ X), g ≫ f = g) : f = 𝟙 X := by
  convert w (𝟙 X)
  

Proof state:
case h.e'_2
C : Type u
inst✝ : Category.{v, u} C
X Y Z : C
f : X ⟶ X
w : ∀ {Y : C} (g : Y ⟶ X), g ≫ f = g
⊢ f = 𝟙 X ≫ f

Next tactic:
simp
theorem comp_ite {P : Prop} [Decidable P] {X Y Z : C} (f : X ⟶ Y) (g g' : Y ⟶ Z) :
    (f ≫ if P then g else g') = if P then f ≫ g else f ≫ g' := by 

Proof state:
C : Type u
inst✝¹ : Category.{v, u} C
X✝ Y✝ Z✝ : C
P : Prop
inst✝ : Decidable P
X Y Z : C
f : X ⟶ Y
g g' : Y ⟶ Z
⊢ (f ≫ if P then g else g') = if P then f ≫ g else f ≫ g'

Next tactic:
aesop
theorem ite_comp {P : Prop} [Decidable P] {X Y Z : C} (f f' : X ⟶ Y) (g : Y ⟶ Z) :
    (if P then f else f') ≫ g = if P then f ≫ g else f' ≫ g := by 

Proof state:
C : Type u
inst✝¹ : Category.{v, u} C
X✝ Y✝ Z✝ : C
P : Prop
inst✝ : Decidable P
X Y Z : C
f f' : X ⟶ Y
g : Y ⟶ Z
⊢ (if P then f else f') ≫ g = if P then f ≫ g else f' ≫ g

Next tactic:
aesop
theorem comp_dite {P : Prop} [Decidable P]
    {X Y Z : C} (f : X ⟶ Y) (g : P → (Y ⟶ Z)) (g' : ¬P → (Y ⟶ Z)) :
    (f ≫ if h : P then g h else g' h) = if h : P then f ≫ g h else f ≫ g' h := by 

Proof state:
C : Type u
inst✝¹ : Category.{v, u} C
X✝ Y✝ Z✝ : C
P : Prop
inst✝ : Decidable P
X Y Z : C
f : X ⟶ Y
g : P → (Y ⟶ Z)
g' : ¬P → (Y ⟶ Z)
⊢ (f ≫ if h : P then g h else g' h) = if h : P then f ≫ g h else f ≫ g' h

Next tactic:
aesop
theorem dite_comp {P : Prop} [Decidable P]
    {X Y Z : C} (f : P → (X ⟶ Y)) (f' : ¬P → (X ⟶ Y)) (g : Y ⟶ Z) :
    (if h : P then f h else f' h) ≫ g = if h : P then f h ≫ g else f' h ≫ g := by 

Proof state:
C : Type u
inst✝¹ : Category.{v, u} C
X✝ Y✝ Z✝ : C
P : Prop
inst✝ : Decidable P
X Y Z : C
f : P → (X ⟶ Y)
f' : ¬P → (X ⟶ Y)
g : Y ⟶ Z
⊢ (if h : P then f h else f' h) ≫ g = if h : P then f h ≫ g else f' h ≫ g

Next tactic:
aesop
instance (X : C) : Epi (𝟙 X) :=
  ⟨fun g h w => by 

Proof state:
C : Type u
inst✝ : Category.{v, u} C
X✝ Y Z X Z✝ : C
g h : X ⟶ Z✝
w : 𝟙 X ≫ g = 𝟙 X ≫ h
⊢ g = h

Next tactic:
aesop
instance (X : C) : Mono (𝟙 X) :=
  ⟨fun g h w => by 

Proof state:
C : Type u
inst✝ : Category.{v, u} C
X✝ Y Z X Z✝ : C
g h : Z✝ ⟶ X
w : g ≫ 𝟙 X = h ≫ 𝟙 X
⊢ g = h

Next tactic:
aesop
theorem cancel_epi_id (f : X ⟶ Y) [Epi f] {h : Y ⟶ Y} : f ≫ h = f ↔ h = 𝟙 Y := by
  

Proof state:
C : Type u
inst✝¹ : Category.{v, u} C
X Y Z : C
f : X ⟶ Y
inst✝ : Epi f
h : Y ⟶ Y
⊢ f ≫ h = f ↔ h = 𝟙 Y

Next tactic:
convert cancel_epi f
theorem cancel_epi_id (f : X ⟶ Y) [Epi f] {h : Y ⟶ Y} : f ≫ h = f ↔ h = 𝟙 Y := by
  convert cancel_epi f
  

Proof state:
case h.e'_1.h.e'_3.h
C : Type u
inst✝¹ : Category.{v, u} C
X Y Z : C
f : X ⟶ Y
inst✝ : Epi f
h : Y ⟶ Y
⊢ f = f ≫ 𝟙 Y

Next tactic:
simp
theorem cancel_mono_id (f : X ⟶ Y) [Mono f] {g : X ⟶ X} : g ≫ f = f ↔ g = 𝟙 X := by
  

Proof state:
C : Type u
inst✝¹ : Category.{v, u} C
X Y Z : C
f : X ⟶ Y
inst✝ : Mono f
g : X ⟶ X
⊢ g ≫ f = f ↔ g = 𝟙 X

Next tactic:
convert cancel_mono f
theorem cancel_mono_id (f : X ⟶ Y) [Mono f] {g : X ⟶ X} : g ≫ f = f ↔ g = 𝟙 X := by
  convert cancel_mono f
  

Proof state:
case h.e'_1.h.e'_3.h
C : Type u
inst✝¹ : Category.{v, u} C
X Y Z : C
f : X ⟶ Y
inst✝ : Mono f
g : X ⟶ X
⊢ f = 𝟙 X ≫ f

Next tactic:
simp
theorem epi_comp {X Y Z : C} (f : X ⟶ Y) [Epi f] (g : Y ⟶ Z) [Epi g] : Epi (f ≫ g) := by
  

Proof state:
C : Type u
inst✝² : Category.{v, u} C
X✝ Y✝ Z✝ X Y Z : C
f : X ⟶ Y
inst✝¹ : Epi f
g : Y ⟶ Z
inst✝ : Epi g
⊢ Epi (f ≫ g)

Next tactic:
constructor
theorem epi_comp {X Y Z : C} (f : X ⟶ Y) [Epi f] (g : Y ⟶ Z) [Epi g] : Epi (f ≫ g) := by
  constructor
  

Proof state:
case left_cancellation
C : Type u
inst✝² : Category.{v, u} C
X✝ Y✝ Z✝ X Y Z : C
f : X ⟶ Y
inst✝¹ : Epi f
g : Y ⟶ Z
inst✝ : Epi g
⊢ ∀ {Z_1 : C} (g_1 h : Z ⟶ Z_1), (f ≫ g) ≫ g_1 = (f ≫ g) ≫ h → g_1 = h

Next tactic:
intro Z a b w