l3lab/ntp-mathlib huggingface dataset:
lemma ext {F G : ComposableArrows C n} (h : ∀ i, F.obj i = G.obj i)
    (w : ∀ (i : ℕ) (hi : i < n), F.map' i (i + 1) =
      eqToHom (h _) ≫ G.map' i (i + 1) ≫ eqToHom (h _).symm) : F = G :=
  Functor.ext_of_iso
    (isoMk (fun i => eqToIso (h i)) (fun i hi => by 

Proof state:
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ F G : ComposableArrows C n
h : ∀ (i : Fin (n + 1)), F.obj i = G.obj i
w :
  ∀ (i : ℕ) (hi : i < n),
    map' F i (i + 1) =
      eqToHom (_ : F.obj { val := i, isLt := (_ : i < n + 1) } = G.obj { val := i, isLt := (_ : i < n + 1) }) ≫
        map' G i (i + 1) ≫
          eqToHom
            (_ :
              G.obj { val := i + 1, isLt := (_ : i + 1 < n + 1) } = F.obj { val := i + 1, isLt := (_ : i + 1 < n + 1) })
i : ℕ
hi : i < n
⊢ map' F i (i + 1) ≫ ((fun i => eqToIso (_ : F.obj i = G.obj i)) { val := i + 1, isLt := (_ : i + 1 < n + 1) }).hom =
    ((fun i => eqToIso (_ : F.obj i = G.obj i)) { val := i, isLt := (_ : i < n + 1) }).hom ≫ map' G i (i + 1)

Next tactic:
simp [w i hi]
/-- Constructor for morphisms in `ComposableArrows C 0`. -/
@[simps!]
def homMk₀ {F G : ComposableArrows C 0} (f : F.obj' 0 ⟶ G.obj' 0) : F ⟶ G :=
  homMk (fun i => match i with
    | ⟨0, _⟩ => f) (fun i hi => by 

Proof state:
C : Type u_1
inst✝ : Category.{?u.327743, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 0
f : obj' F 0 ⟶ obj' G 0
i : ℕ
hi : i < 0
⊢ map' F i (i + 1) ≫
      (fun i =>
          match i with
          | { val := 0, isLt := isLt } => f)
        { val := i + 1, isLt := (_ : i + 1 < 0 + 1) } =
    (fun i =>
          match i with
          | { val := 0, isLt := isLt } => f)
        { val := i, isLt := (_ : i < 0 + 1) } ≫
      map' G i (i + 1)

Next tactic:
simp at hi
@[ext]
lemma hom_ext₀ {F G : ComposableArrows C 0} {φ φ' : F ⟶ G}
    (h : app' φ 0 = app' φ' 0) :
    φ = φ' := by
  

Proof state:
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 0
φ φ' : F ⟶ G
h : app' φ 0 = app' φ' 0
⊢ φ = φ'

Next tactic:
ext i
@[ext]
lemma hom_ext₀ {F G : ComposableArrows C 0} {φ φ' : F ⟶ G}
    (h : app' φ 0 = app' φ' 0) :
    φ = φ' := by
  ext i
  

Proof state:
case w.h
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 0
φ φ' : F ⟶ G
h : app' φ 0 = app' φ' 0
i : Fin (0 + 1)
⊢ φ.app i = φ'.app i

Next tactic:
fin_cases i
@[ext]
lemma hom_ext₀ {F G : ComposableArrows C 0} {φ φ' : F ⟶ G}
    (h : app' φ 0 = app' φ' 0) :
    φ = φ' := by
  ext i
  fin_cases i
  

Proof state:
case w.h.head
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 0
φ φ' : F ⟶ G
h : app' φ 0 = app' φ' 0
⊢ φ.app { val := 0, isLt := (_ : 0 < 0 + 1) } = φ'.app { val := 0, isLt := (_ : 0 < 0 + 1) }

Next tactic:
exact h
lemma ext₀ {F G : ComposableArrows C 0} (h : F.obj' 0 = G.obj 0) : F = G :=
  ext (fun i => match i with
    | ⟨0, _⟩ => h) (fun i hi => by 

Proof state:
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 0
h : obj' F 0 = G.obj 0
i : ℕ
hi : i < 0
⊢ map' F i (i + 1) =
    eqToHom (_ : F.obj { val := i, isLt := (_ : i < 0 + 1) } = G.obj { val := i, isLt := (_ : i < 0 + 1) }) ≫
      map' G i (i + 1) ≫
        eqToHom
          (_ :
            G.obj { val := i + 1, isLt := (_ : i + 1 < 0 + 1) } = F.obj { val := i + 1, isLt := (_ : i + 1 < 0 + 1) })

Next tactic:
simp at hi
/-- Constructor for morphisms in `ComposableArrows C 1`. -/
@[simps!]
def homMk₁ {F G : ComposableArrows C 1}
    (left : F.obj' 0 ⟶ G.obj' 0) (right : F.obj' 1 ⟶ G.obj' 1)
    (w : F.map' 0 1 ≫ right = left ≫ G.map' 0 1 := by aesop_cat) :
    F ⟶ G :=
  homMk (fun i => match i with
      | ⟨0, _⟩ => left
      | ⟨1, _⟩ => right) (by
          

Proof state:
C : Type u_1
inst✝ : Category.{?u.345943, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
left : obj' F 0 ⟶ obj' G 0
right : obj' F 1 ⟶ obj' G 1
w : autoParam (map' F 0 1 ≫ right = left ≫ map' G 0 1) _auto✝
⊢ ∀ (i : ℕ) (hi : i < 1),
    map' F i (i + 1) ≫
        (fun i =>
            match i with
            | { val := 0, isLt := isLt } => left
            | { val := 1, isLt := isLt } => right)
          { val := i + 1, isLt := (_ : i + 1 < 1 + 1) } =
      (fun i =>
            match i with
            | { val := 0, isLt := isLt } => left
            | { val := 1, isLt := isLt } => right)
          { val := i, isLt := (_ : i < 1 + 1) } ≫
        map' G i (i + 1)

Next tactic:
intro i hi
/-- Constructor for morphisms in `ComposableArrows C 1`. -/
@[simps!]
def homMk₁ {F G : ComposableArrows C 1}
    (left : F.obj' 0 ⟶ G.obj' 0) (right : F.obj' 1 ⟶ G.obj' 1)
    (w : F.map' 0 1 ≫ right = left ≫ G.map' 0 1 := by aesop_cat) :
    F ⟶ G :=
  homMk (fun i => match i with
      | ⟨0, _⟩ => left
      | ⟨1, _⟩ => right) (by
          intro i hi
          

Proof state:
C : Type u_1
inst✝ : Category.{?u.345943, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
left : obj' F 0 ⟶ obj' G 0
right : obj' F 1 ⟶ obj' G 1
w : autoParam (map' F 0 1 ≫ right = left ≫ map' G 0 1) _auto✝
i : ℕ
hi : i < 1
⊢ map' F i (i + 1) ≫
      (fun i =>
          match i with
          | { val := 0, isLt := isLt } => left
          | { val := 1, isLt := isLt } => right)
        { val := i + 1, isLt := (_ : i + 1 < 1 + 1) } =
    (fun i =>
          match i with
          | { val := 0, isLt := isLt } => left
          | { val := 1, isLt := isLt } => right)
        { val := i, isLt := (_ : i < 1 + 1) } ≫
      map' G i (i + 1)

Next tactic:
obtain rfl : i = 0 := by simpa using hi
/-- Constructor for morphisms in `ComposableArrows C 1`. -/
@[simps!]
def homMk₁ {F G : ComposableArrows C 1}
    (left : F.obj' 0 ⟶ G.obj' 0) (right : F.obj' 1 ⟶ G.obj' 1)
    (w : F.map' 0 1 ≫ right = left ≫ G.map' 0 1 := by aesop_cat) :
    F ⟶ G :=
  homMk (fun i => match i with
      | ⟨0, _⟩ => left
      | ⟨1, _⟩ => right) (by
          intro i hi
          obtain rfl : i = 0 := by 

Proof state:
C : Type u_1
inst✝ : Category.{?u.345943, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
left : obj' F 0 ⟶ obj' G 0
right : obj' F 1 ⟶ obj' G 1
w : autoParam (map' F 0 1 ≫ right = left ≫ map' G 0 1) _auto✝
i : ℕ
hi : i < 1
⊢ i = 0

Next tactic:
simpa using hi
/-- Constructor for morphisms in `ComposableArrows C 1`. -/
@[simps!]
def homMk₁ {F G : ComposableArrows C 1}
    (left : F.obj' 0 ⟶ G.obj' 0) (right : F.obj' 1 ⟶ G.obj' 1)
    (w : F.map' 0 1 ≫ right = left ≫ G.map' 0 1 := by aesop_cat) :
    F ⟶ G :=
  homMk (fun i => match i with
      | ⟨0, _⟩ => left
      | ⟨1, _⟩ => right) (by
          intro i hi
          obtain rfl : i = 0 := by simpa using hi
          

Proof state:
C : Type u_1
inst✝ : Category.{?u.345943, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
left : obj' F 0 ⟶ obj' G 0
right : obj' F 1 ⟶ obj' G 1
w : autoParam (map' F 0 1 ≫ right = left ≫ map' G 0 1) _auto✝
hi : 0 < 1
⊢ map' F 0 (0 + 1) ≫
      (fun i =>
          match i with
          | { val := 0, isLt := isLt } => left
          | { val := 1, isLt := isLt } => right)
        { val := 0 + 1, isLt := (_ : 0 + 1 < 1 + 1) } =
    (fun i =>
          match i with
          | { val := 0, isLt := isLt } => left
          | { val := 1, isLt := isLt } => right)
        { val := 0, isLt := (_ : 0 < 1 + 1) } ≫
      map' G 0 (0 + 1)

Next tactic:
exact w
@[ext]
lemma hom_ext₁ {F G : ComposableArrows C 1} {φ φ' : F ⟶ G}
    (h₀ : app' φ 0 = app' φ' 0) (h₁ : app' φ 1 = app' φ' 1) :
    φ = φ' := by
  

Proof state:
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
φ φ' : F ⟶ G
h₀ : app' φ 0 = app' φ' 0
h₁ : app' φ 1 = app' φ' 1
⊢ φ = φ'

Next tactic:
ext i
@[ext]
lemma hom_ext₁ {F G : ComposableArrows C 1} {φ φ' : F ⟶ G}
    (h₀ : app' φ 0 = app' φ' 0) (h₁ : app' φ 1 = app' φ' 1) :
    φ = φ' := by
  ext i
  

Proof state:
case w.h
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
φ φ' : F ⟶ G
h₀ : app' φ 0 = app' φ' 0
h₁ : app' φ 1 = app' φ' 1
i : Fin (1 + 1)
⊢ φ.app i = φ'.app i

Next tactic:
match i with
    | 0 => exact h₀
    | 1 => exact h₁
@[ext]
lemma hom_ext₁ {F G : ComposableArrows C 1} {φ φ' : F ⟶ G}
    (h₀ : app' φ 0 = app' φ' 0) (h₁ : app' φ 1 = app' φ' 1) :
    φ = φ' := by
  ext i
  match i with
    | 0 => 

Proof state:
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
φ φ' : F ⟶ G
h₀ : app' φ 0 = app' φ' 0
h₁ : app' φ 1 = app' φ' 1
i : Fin (1 + 1)
⊢ φ.app 0 = φ'.app 0

Next tactic:
exact h₀
@[ext]
lemma hom_ext₁ {F G : ComposableArrows C 1} {φ φ' : F ⟶ G}
    (h₀ : app' φ 0 = app' φ' 0) (h₁ : app' φ 1 = app' φ' 1) :
    φ = φ' := by
  ext i
  match i with
    | 0 => exact h₀
    | 1 => 

Proof state:
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
φ φ' : F ⟶ G
h₀ : app' φ 0 = app' φ' 0
h₁ : app' φ 1 = app' φ' 1
i : Fin (1 + 1)
⊢ φ.app 1 = φ'.app 1

Next tactic:
exact h₁
/-- Constructor for isomorphisms in `ComposableArrows C 1`. -/
@[simps!]
def isoMk₁ {F G : ComposableArrows C 1}
    (left : F.obj' 0 ≅ G.obj' 0) (right : F.obj' 1 ≅ G.obj' 1)
    (w : F.map' 0 1 ≫ right.hom = left.hom ≫ G.map' 0 1 := by aesop_cat) :
    F ≅ G where
  hom := homMk₁ left.hom right.hom w
  inv := homMk₁ left.inv right.inv (by
    

Proof state:
C : Type u_1
inst✝ : Category.{?u.364494, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
left : obj' F 0 ≅ obj' G 0
right : obj' F 1 ≅ obj' G 1
w : autoParam (map' F 0 1 ≫ right.hom = left.hom ≫ map' G 0 1) _auto✝
⊢ map' G 0 1 ≫ right.inv = left.inv ≫ map' F 0 1

Next tactic:
rw [← cancel_mono right.hom, assoc, assoc, w, right.inv_hom_id, left.inv_hom_id_assoc]
/-- Constructor for isomorphisms in `ComposableArrows C 1`. -/
@[simps!]
def isoMk₁ {F G : ComposableArrows C 1}
    (left : F.obj' 0 ≅ G.obj' 0) (right : F.obj' 1 ≅ G.obj' 1)
    (w : F.map' 0 1 ≫ right.hom = left.hom ≫ G.map' 0 1 := by aesop_cat) :
    F ≅ G where
  hom := homMk₁ left.hom right.hom w
  inv := homMk₁ left.inv right.inv (by
    rw [← cancel_mono right.hom, assoc, assoc, w, right.inv_hom_id, left.inv_hom_id_assoc]
    

Proof state:
C : Type u_1
inst✝ : Category.{?u.364494, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
left : obj' F 0 ≅ obj' G 0
right : obj' F 1 ≅ obj' G 1
w : autoParam (map' F 0 1 ≫ right.hom = left.hom ≫ map' G 0 1) _auto✝
⊢ map' G 0 1 ≫ 𝟙 (obj' G 1) = map' G 0 1

Next tactic:
apply comp_id
lemma ext₁ {F G : ComposableArrows C 1}
    (left : F.left = G.left) (right : F.right = G.right)
    (w : F.hom = eqToHom left ≫ G.hom ≫ eqToHom right.symm) : F = G :=
  Functor.ext_of_iso (isoMk₁ (eqToIso left) (eqToIso right) (by 

Proof state:
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
left : CategoryTheory.ComposableArrows.left F = CategoryTheory.ComposableArrows.left G
right : CategoryTheory.ComposableArrows.right F = CategoryTheory.ComposableArrows.right G
w :
  hom F =
    eqToHom left ≫
      hom G ≫ eqToHom (_ : CategoryTheory.ComposableArrows.right G = CategoryTheory.ComposableArrows.right F)
⊢ map' F 0 1 ≫ (eqToIso right).hom = (eqToIso left).hom ≫ map' G 0 1

Next tactic:
simp [map'_eq_hom₁, w]
lemma ext₁ {F G : ComposableArrows C 1}
    (left : F.left = G.left) (right : F.right = G.right)
    (w : F.hom = eqToHom left ≫ G.hom ≫ eqToHom right.symm) : F = G :=
  Functor.ext_of_iso (isoMk₁ (eqToIso left) (eqToIso right) (by simp [map'_eq_hom₁, w]))
    (fun i => by 

Proof state:
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
left : CategoryTheory.ComposableArrows.left F = CategoryTheory.ComposableArrows.left G
right : CategoryTheory.ComposableArrows.right F = CategoryTheory.ComposableArrows.right G
w :
  hom F =
    eqToHom left ≫
      hom G ≫ eqToHom (_ : CategoryTheory.ComposableArrows.right G = CategoryTheory.ComposableArrows.right F)
i : Fin (1 + 1)
⊢ F.obj i = G.obj i

Next tactic:
fin_cases i
lemma ext₁ {F G : ComposableArrows C 1}
    (left : F.left = G.left) (right : F.right = G.right)
    (w : F.hom = eqToHom left ≫ G.hom ≫ eqToHom right.symm) : F = G :=
  Functor.ext_of_iso (isoMk₁ (eqToIso left) (eqToIso right) (by simp [map'_eq_hom₁, w]))
    (fun i => by fin_cases i <;> 

Proof state:
case head
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
left : CategoryTheory.ComposableArrows.left F = CategoryTheory.ComposableArrows.left G
right : CategoryTheory.ComposableArrows.right F = CategoryTheory.ComposableArrows.right G
w :
  hom F =
    eqToHom left ≫
      hom G ≫ eqToHom (_ : CategoryTheory.ComposableArrows.right G = CategoryTheory.ComposableArrows.right F)
⊢ F.obj { val := 0, isLt := (_ : 0 < 1 + 1) } = G.obj { val := 0, isLt := (_ : 0 < 1 + 1) }

Next tactic:
assumption
lemma ext₁ {F G : ComposableArrows C 1}
    (left : F.left = G.left) (right : F.right = G.right)
    (w : F.hom = eqToHom left ≫ G.hom ≫ eqToHom right.symm) : F = G :=
  Functor.ext_of_iso (isoMk₁ (eqToIso left) (eqToIso right) (by simp [map'_eq_hom₁, w]))
    (fun i => by fin_cases i <;> 

Proof state:
case tail.head
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
left : CategoryTheory.ComposableArrows.left F = CategoryTheory.ComposableArrows.left G
right : CategoryTheory.ComposableArrows.right F = CategoryTheory.ComposableArrows.right G
w :
  hom F =
    eqToHom left ≫
      hom G ≫ eqToHom (_ : CategoryTheory.ComposableArrows.right G = CategoryTheory.ComposableArrows.right F)
⊢ F.obj { val := 1, isLt := (_ : (fun a => a < 1 + 1) 1) } = G.obj { val := 1, isLt := (_ : (fun a => a < 1 + 1) 1) }

Next tactic:
assumption
lemma ext₁ {F G : ComposableArrows C 1}
    (left : F.left = G.left) (right : F.right = G.right)
    (w : F.hom = eqToHom left ≫ G.hom ≫ eqToHom right.symm) : F = G :=
  Functor.ext_of_iso (isoMk₁ (eqToIso left) (eqToIso right) (by simp [map'_eq_hom₁, w]))
    (fun i => by fin_cases i <;> assumption)
    (fun i => by 

Proof state:
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
left : CategoryTheory.ComposableArrows.left F = CategoryTheory.ComposableArrows.left G
right : CategoryTheory.ComposableArrows.right F = CategoryTheory.ComposableArrows.right G
w :
  hom F =
    eqToHom left ≫
      hom G ≫ eqToHom (_ : CategoryTheory.ComposableArrows.right G = CategoryTheory.ComposableArrows.right F)
i : Fin (1 + 1)
⊢ (isoMk₁ (eqToIso left) (eqToIso right)).hom.app i = eqToHom (_ : F.obj i = G.obj i)

Next tactic:
fin_cases i
lemma ext₁ {F G : ComposableArrows C 1}
    (left : F.left = G.left) (right : F.right = G.right)
    (w : F.hom = eqToHom left ≫ G.hom ≫ eqToHom right.symm) : F = G :=
  Functor.ext_of_iso (isoMk₁ (eqToIso left) (eqToIso right) (by simp [map'_eq_hom₁, w]))
    (fun i => by fin_cases i <;> assumption)
    (fun i => by fin_cases i <;> 

Proof state:
case head
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
left : CategoryTheory.ComposableArrows.left F = CategoryTheory.ComposableArrows.left G
right : CategoryTheory.ComposableArrows.right F = CategoryTheory.ComposableArrows.right G
w :
  hom F =
    eqToHom left ≫
      hom G ≫ eqToHom (_ : CategoryTheory.ComposableArrows.right G = CategoryTheory.ComposableArrows.right F)
⊢ (isoMk₁ (eqToIso left) (eqToIso right)).hom.app { val := 0, isLt := (_ : 0 < 1 + 1) } =
    eqToHom (_ : F.obj { val := 0, isLt := (_ : 0 < 1 + 1) } = G.obj { val := 0, isLt := (_ : 0 < 1 + 1) })

Next tactic:
rfl
lemma ext₁ {F G : ComposableArrows C 1}
    (left : F.left = G.left) (right : F.right = G.right)
    (w : F.hom = eqToHom left ≫ G.hom ≫ eqToHom right.symm) : F = G :=
  Functor.ext_of_iso (isoMk₁ (eqToIso left) (eqToIso right) (by simp [map'_eq_hom₁, w]))
    (fun i => by fin_cases i <;> assumption)
    (fun i => by fin_cases i <;> 

Proof state:
case tail.head
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F✝ G✝ : ComposableArrows C n
F G : ComposableArrows C 1
left : CategoryTheory.ComposableArrows.left F = CategoryTheory.ComposableArrows.left G
right : CategoryTheory.ComposableArrows.right F = CategoryTheory.ComposableArrows.right G
w :
  hom F =
    eqToHom left ≫
      hom G ≫ eqToHom (_ : CategoryTheory.ComposableArrows.right G = CategoryTheory.ComposableArrows.right F)
⊢ (isoMk₁ (eqToIso left) (eqToIso right)).hom.app { val := 1, isLt := (_ : (fun a => a < 1 + 1) 1) } =
    eqToHom
      (_ :
        F.obj { val := 1, isLt := (_ : (fun a => a < 1 + 1) 1) } =
          G.obj { val := 1, isLt := (_ : (fun a => a < 1 + 1) 1) })

Next tactic:
rfl
lemma mk₁_surjective (X : ComposableArrows C 1) : ∃ (X₀ X₁ : C) (f : X₀ ⟶ X₁), X = mk₁ f :=
  ⟨_, _, X.map' 0 1, ext₁ rfl rfl (by 

Proof state:
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : ComposableArrows C 1
⊢ hom X = eqToHom (_ : left X = left X) ≫ hom (mk₁ (map' X 0 1)) ≫ eqToHom (_ : right (mk₁ (map' X 0 1)) = right X)

Next tactic:
simp
/-- Auxiliary definition for the action on maps of the functor `F.precomp f`.
It sends `0 ≤ 1` to `f` and `i + 1 ≤ j + 1` to `F.map' i j`. -/
def map : ∀ (i j : Fin (n + 1 + 1)) (_ : i ≤ j), obj F X i ⟶ obj F X j
  | ⟨0, _⟩, ⟨0, _⟩, _ => 𝟙 X
  | ⟨0, _⟩, ⟨1, _⟩, _ => f
  | ⟨0, _⟩, ⟨j + 2, hj⟩, _ => f ≫ F.map' 0 (j + 1)
  | ⟨i + 1, hi⟩, ⟨j + 1, hj⟩, hij => F.map' i j (by 

Proof state:
C : Type u_1
inst✝ : Category.{?u.417236, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
i : ℕ
hi : i + 1 < n + 1 + 1
j : ℕ
hj : j + 1 < n + 1 + 1
hij : { val := i + 1, isLt := hi } ≤ { val := j + 1, isLt := hj }
⊢ i ≤ j

Next tactic:
simpa using hij
@[simp]
lemma map_zero_zero : map F f 0 0 (by 

Proof state:
C : Type u_1
inst✝ : Category.{?u.433335, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
⊢ 0 ≤ 0

Next tactic:
simp
@[simp]
lemma map_one_one : map F f 1 1 (by 

Proof state:
C : Type u_1
inst✝ : Category.{?u.433703, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
⊢ 1 ≤ 1

Next tactic:
simp
@[simp]
lemma map_zero_one : map F f 0 1 (by 

Proof state:
C : Type u_1
inst✝ : Category.{?u.437716, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
⊢ 0 ≤ 1

Next tactic:
simp
@[simp]
lemma map_zero_one' : map F f 0 ⟨0 + 1, by 

Proof state:
C : Type u_1
inst✝ : Category.{?u.438798, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
⊢ 0 + 1 < n + 1 + 1

Next tactic:
simp
@[simp]
lemma map_zero_one' : map F f 0 ⟨0 + 1, by simp⟩ (by 

Proof state:
C : Type u_1
inst✝ : Category.{?u.438798, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
⊢ 0 ≤ { val := 0 + 1, isLt := (_ : 0 + 1 < n + 1 + 1) }

Next tactic:
simp
@[simp]
lemma map_zero_succ_succ (j : ℕ) (hj : j + 2 < n + 1 + 1) :
    map F f 0 ⟨j + 2, hj⟩ (by 

Proof state:
C : Type u_1
inst✝ : Category.{?u.440867, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
j : ℕ
hj : j + 2 < n + 1 + 1
⊢ 0 ≤ { val := j + 2, isLt := hj }

Next tactic:
simp
@[simp]
lemma map_one_succ (j : ℕ) (hj : j + 1 < n + 1 + 1) :
    map F f 1 ⟨j + 1, hj⟩ (by 

Proof state:
C : Type u_1
inst✝ : Category.{?u.452823, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
j : ℕ
hj : j + 1 < n + 1 + 1
⊢ 1 ≤ { val := j + 1, isLt := hj }

Next tactic:
simp [Fin.le_def]
lemma map_id (i : Fin (n + 1 + 1)) : map F f i i (by 

Proof state:
C : Type u_1
inst✝ : Category.{?u.458612, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
i : Fin (n + 1 + 1)
⊢ i ≤ i

Next tactic:
simp
lemma map_id (i : Fin (n + 1 + 1)) : map F f i i (by simp) = 𝟙 _ := by
  

Proof state:
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
i : Fin (n + 1 + 1)
⊢ map F f i i (_ : i ≤ i) = 𝟙 (obj F X i)

Next tactic:
obtain ⟨i, hi⟩ := i
lemma map_id (i : Fin (n + 1 + 1)) : map F f i i (by simp) = 𝟙 _ := by
  obtain ⟨i, hi⟩ := i
  

Proof state:
case mk
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
i : ℕ
hi : i < n + 1 + 1
⊢ map F f { val := i, isLt := hi } { val := i, isLt := hi } (_ : { val := i, isLt := hi } ≤ { val := i, isLt := hi }) =
    𝟙 (obj F X { val := i, isLt := hi })

Next tactic:
cases i
lemma map_id (i : Fin (n + 1 + 1)) : map F f i i (by simp) = 𝟙 _ := by
  obtain ⟨i, hi⟩ := i
  cases i
  · 

Proof state:
case mk.zero
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
hi : Nat.zero < n + 1 + 1
⊢ map F f { val := Nat.zero, isLt := hi } { val := Nat.zero, isLt := hi }
      (_ : { val := Nat.zero, isLt := hi } ≤ { val := Nat.zero, isLt := hi }) =
    𝟙 (obj F X { val := Nat.zero, isLt := hi })

Next tactic:
rfl
lemma map_id (i : Fin (n + 1 + 1)) : map F f i i (by simp) = 𝟙 _ := by
  obtain ⟨i, hi⟩ := i
  cases i
  · rfl
  · 

Proof state:
case mk.succ
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
n✝ : ℕ
hi : Nat.succ n✝ < n + 1 + 1
⊢ map F f { val := Nat.succ n✝, isLt := hi } { val := Nat.succ n✝, isLt := hi }
      (_ : { val := Nat.succ n✝, isLt := hi } ≤ { val := Nat.succ n✝, isLt := hi }) =
    𝟙 (obj F X { val := Nat.succ n✝, isLt := hi })

Next tactic:
apply F.map_id
lemma map_comp {i j k : Fin (n + 1 + 1)} (hij : i ≤ j) (hjk : j ≤ k) :
    map F f i k (hij.trans hjk) = map F f i j hij ≫ map F f j k hjk := by
  

Proof state:
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
i j k : Fin (n + 1 + 1)
hij : i ≤ j
hjk : j ≤ k
⊢ map F f i k (_ : i ≤ k) = map F f i j hij ≫ map F f j k hjk

Next tactic:
obtain ⟨i, hi⟩ := i
lemma map_comp {i j k : Fin (n + 1 + 1)} (hij : i ≤ j) (hjk : j ≤ k) :
    map F f i k (hij.trans hjk) = map F f i j hij ≫ map F f j k hjk := by
  obtain ⟨i, hi⟩ := i
  

Proof state:
case mk
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
j k : Fin (n + 1 + 1)
hjk : j ≤ k
i : ℕ
hi : i < n + 1 + 1
hij : { val := i, isLt := hi } ≤ j
⊢ map F f { val := i, isLt := hi } k (_ : { val := i, isLt := hi } ≤ k) =
    map F f { val := i, isLt := hi } j hij ≫ map F f j k hjk

Next tactic:
obtain ⟨j, hj⟩ := j
lemma map_comp {i j k : Fin (n + 1 + 1)} (hij : i ≤ j) (hjk : j ≤ k) :
    map F f i k (hij.trans hjk) = map F f i j hij ≫ map F f j k hjk := by
  obtain ⟨i, hi⟩ := i
  obtain ⟨j, hj⟩ := j
  

Proof state:
case mk.mk
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
k : Fin (n + 1 + 1)
i : ℕ
hi : i < n + 1 + 1
j : ℕ
hj : j < n + 1 + 1
hjk : { val := j, isLt := hj } ≤ k
hij : { val := i, isLt := hi } ≤ { val := j, isLt := hj }
⊢ map F f { val := i, isLt := hi } k (_ : { val := i, isLt := hi } ≤ k) =
    map F f { val := i, isLt := hi } { val := j, isLt := hj } hij ≫ map F f { val := j, isLt := hj } k hjk

Next tactic:
obtain ⟨k, hk⟩ := k
lemma map_comp {i j k : Fin (n + 1 + 1)} (hij : i ≤ j) (hjk : j ≤ k) :
    map F f i k (hij.trans hjk) = map F f i j hij ≫ map F f j k hjk := by
  obtain ⟨i, hi⟩ := i
  obtain ⟨j, hj⟩ := j
  obtain ⟨k, hk⟩ := k
  

Proof state:
case mk.mk.mk
C : Type u_1
inst✝ : Category.{u_2, u_1} C
n m : ℕ
F G : ComposableArrows C n
X : C
f : X ⟶ left F
i : ℕ
hi : i < n + 1 + 1
j : ℕ
hj : j < n + 1 + 1
hij : { val := i, isLt := hi } ≤ { val := j, isLt := hj }
k : ℕ
hk : k < n + 1 + 1
hjk : { val := j, isLt := hj } ≤ { val := k, isLt := hk }
⊢ map F f { val := i, isLt := hi } { val := k, isLt := hk } (_ : { val := i, isLt := hi } ≤ { val := k, isLt := hk }) =
    map F f { val := i, isLt := hi } { val := j, isLt := hj } hij ≫
      map F f { val := j, isLt := hj } { val := k, isLt := hk } hjk

Next tactic:
cases i