Theorem: CategoryTheory.isPullback_of_cofan_isVanKampen
File: Mathlib/CategoryTheory/Limits/VanKampen.lean

tactic: refine (hc (Cofan.mk (X i) (f := fun k ↦ if k = i then X i else ⊥_ C)
  (fun k ↦ if h : k = i then (eqToHom <| if_pos h) else (eqToHom <| if_neg h) ≫ initial.to _))
  (Discrete.natTrans (fun k ↦ if h : k.1 = i then (eqToHom <| (if_pos h).trans
    (congr_arg X h.symm)) else (eqToHom <| if_neg h) ≫ initial.to _))
  (c.inj i) ?_ (NatTrans.equifibered_of_discrete _)).mp ⟨?_⟩ ⟨j⟩
state_before: J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
⊢ IsPullback (if h : j = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i))
    (if h : j = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X j)) (c.inj i) (c.inj j)
state_after: case refine_1
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
⊢ (Discrete.natTrans fun k => if h : k.as = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to ((Discrete.functor X).obj k)) ≫
      c.ι =
    (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).ι ≫
      (Functor.const (Discrete ι)).map (c.inj i)

case refine_2
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
⊢ IsColimit (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i))

tactic: ext ⟨k⟩
state_before: case refine_1
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
⊢ (Discrete.natTrans fun k => if h : k.as = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to ((Discrete.functor X).obj k)) ≫
      c.ι =
    (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).ι ≫
      (Functor.const (Discrete ι)).map (c.inj i)
state_after: case refine_1.w.h.mk
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
k : ι
⊢ ((Discrete.natTrans fun k =>
            if h : k.as = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to ((Discrete.functor X).obj k)) ≫
          c.ι).app
      { as := k } =
    ((Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).ι ≫
          (Functor.const (Discrete ι)).map (c.inj i)).app
      { as := k }

tactic: simp only [Discrete.functor_obj, Functor.const_obj_obj, NatTrans.comp_app,
  Discrete.natTrans_app, Cofan.mk_pt, Cofan.mk_ι_app, Functor.const_map_app]
state_before: case refine_1.w.h.mk
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
k : ι
⊢ ((Discrete.natTrans fun k =>
            if h : k.as = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to ((Discrete.functor X).obj k)) ≫
          c.ι).app
      { as := k } =
    ((Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).ι ≫
          (Functor.const (Discrete ι)).map (c.inj i)).app
      { as := k }
state_after: case refine_1.w.h.mk
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
k : ι
⊢ (if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X k)) ≫ c.ι.app { as := k } =
    (if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)) ≫ c.inj i

tactic: split
state_before: case refine_1.w.h.mk
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
k : ι
⊢ (if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X k)) ≫ c.ι.app { as := k } =
    (if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)) ≫ c.inj i
state_after: case refine_1.w.h.mk.isTrue
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
k : ι
h✝ : k = i
⊢ eqToHom ⋯ ≫ c.ι.app { as := k } = eqToHom ⋯ ≫ c.inj i

case refine_1.w.h.mk.isFalse
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
k : ι
h✝ : ¬k = i
⊢ (eqToHom ⋯ ≫ initial.to (X k)) ≫ c.ι.app { as := k } = (eqToHom ⋯ ≫ initial.to (X i)) ≫ c.inj i

tactic: subst ‹k = i›
state_before: case refine_1.w.h.mk.isTrue
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
k : ι
h✝ : k = i
⊢ eqToHom ⋯ ≫ c.ι.app { as := k } = eqToHom ⋯ ≫ c.inj i
state_after: case refine_1.w.h.mk.isTrue
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
j : ι
inst✝ : DecidableEq ι
k : ι
⊢ eqToHom ⋯ ≫ c.ι.app { as := k } = eqToHom ⋯ ≫ c.inj k

tactic: rfl
state_before: case refine_1.w.h.mk.isTrue
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
j : ι
inst✝ : DecidableEq ι
k : ι
⊢ eqToHom ⋯ ≫ c.ι.app { as := k } = eqToHom ⋯ ≫ c.inj k
state_after: no goals

tactic: simp
state_before: case refine_1.w.h.mk.isFalse
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
k : ι
h✝ : ¬k = i
⊢ (eqToHom ⋯ ≫ initial.to (X k)) ≫ c.ι.app { as := k } = (eqToHom ⋯ ≫ initial.to (X i)) ≫ c.inj i
state_after: no goals

tactic: refine mkCofanColimit _ (fun t ↦ (eqToHom (if_pos rfl).symm) ≫ t.inj i) ?_ ?_
state_before: case refine_2
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
⊢ IsColimit (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i))
state_after: case refine_2.refine_1
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
⊢ ∀ (t : Cofan fun k => if k = i then X i else ⊥_ C) (j : ι),
    (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).inj j ≫
        (fun t => eqToHom ⋯ ≫ t.inj i) t =
      t.inj j

case refine_2.refine_2
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
⊢ ∀ (t : Cofan fun k => if k = i then X i else ⊥_ C)
    (m : (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).pt ⟶ t.pt),
    (∀ (j : ι),
        (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).inj j ≫ m = t.inj j) →
      m = (fun t => eqToHom ⋯ ≫ t.inj i) t

tactic: intro t j
state_before: case refine_2.refine_1
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
⊢ ∀ (t : Cofan fun k => if k = i then X i else ⊥_ C) (j : ι),
    (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).inj j ≫
        (fun t => eqToHom ⋯ ≫ t.inj i) t =
      t.inj j
state_after: case refine_2.refine_1
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j✝ : ι
inst✝ : DecidableEq ι
t : Cofan fun k => if k = i then X i else ⊥_ C
j : ι
⊢ (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).inj j ≫
      (fun t => eqToHom ⋯ ≫ t.inj i) t =
    t.inj j

tactic: simp only [Cofan.mk_pt, cofan_mk_inj]
state_before: case refine_2.refine_1
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j✝ : ι
inst✝ : DecidableEq ι
t : Cofan fun k => if k = i then X i else ⊥_ C
j : ι
⊢ (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).inj j ≫
      (fun t => eqToHom ⋯ ≫ t.inj i) t =
    t.inj j
state_after: case refine_2.refine_1
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j✝ : ι
inst✝ : DecidableEq ι
t : Cofan fun k => if k = i then X i else ⊥_ C
j : ι
⊢ (if h : j = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)) ≫ eqToHom ⋯ ≫ t.inj i = t.inj j

tactic: split
state_before: case refine_2.refine_1
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j✝ : ι
inst✝ : DecidableEq ι
t : Cofan fun k => if k = i then X i else ⊥_ C
j : ι
⊢ (if h : j = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)) ≫ eqToHom ⋯ ≫ t.inj i = t.inj j
state_after: case refine_2.refine_1.isTrue
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j✝ : ι
inst✝ : DecidableEq ι
t : Cofan fun k => if k = i then X i else ⊥_ C
j : ι
h✝ : j = i
⊢ eqToHom ⋯ ≫ eqToHom ⋯ ≫ t.inj i = t.inj j

case refine_2.refine_1.isFalse
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j✝ : ι
inst✝ : DecidableEq ι
t : Cofan fun k => if k = i then X i else ⊥_ C
j : ι
h✝ : ¬j = i
⊢ (eqToHom ⋯ ≫ initial.to (X i)) ≫ eqToHom ⋯ ≫ t.inj i = t.inj j

tactic: subst ‹j = i›
state_before: case refine_2.refine_1.isTrue
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j✝ : ι
inst✝ : DecidableEq ι
t : Cofan fun k => if k = i then X i else ⊥_ C
j : ι
h✝ : j = i
⊢ eqToHom ⋯ ≫ eqToHom ⋯ ≫ t.inj i = t.inj j
state_after: case refine_2.refine_1.isTrue
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
j✝ : ι
inst✝ : DecidableEq ι
j : ι
t : Cofan fun k => if k = j then X j else ⊥_ C
⊢ eqToHom ⋯ ≫ eqToHom ⋯ ≫ t.inj j = t.inj j

tactic: simp
state_before: case refine_2.refine_1.isTrue
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
j✝ : ι
inst✝ : DecidableEq ι
j : ι
t : Cofan fun k => if k = j then X j else ⊥_ C
⊢ eqToHom ⋯ ≫ eqToHom ⋯ ≫ t.inj j = t.inj j
state_after: no goals

tactic: rw [Category.assoc, ← IsIso.eq_inv_comp]
state_before: case refine_2.refine_1.isFalse
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j✝ : ι
inst✝ : DecidableEq ι
t : Cofan fun k => if k = i then X i else ⊥_ C
j : ι
h✝ : ¬j = i
⊢ (eqToHom ⋯ ≫ initial.to (X i)) ≫ eqToHom ⋯ ≫ t.inj i = t.inj j
state_after: case refine_2.refine_1.isFalse
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j✝ : ι
inst✝ : DecidableEq ι
t : Cofan fun k => if k = i then X i else ⊥_ C
j : ι
h✝ : ¬j = i
⊢ initial.to (X i) ≫ eqToHom ⋯ ≫ t.inj i = inv (eqToHom ⋯) ≫ t.inj j

tactic: exact initialIsInitial.hom_ext _ _
state_before: case refine_2.refine_1.isFalse
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j✝ : ι
inst✝ : DecidableEq ι
t : Cofan fun k => if k = i then X i else ⊥_ C
j : ι
h✝ : ¬j = i
⊢ initial.to (X i) ≫ eqToHom ⋯ ≫ t.inj i = inv (eqToHom ⋯) ≫ t.inj j
state_after: no goals

tactic: intro t m hm
state_before: case refine_2.refine_2
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
⊢ ∀ (t : Cofan fun k => if k = i then X i else ⊥_ C)
    (m : (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).pt ⟶ t.pt),
    (∀ (j : ι),
        (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).inj j ≫ m = t.inj j) →
      m = (fun t => eqToHom ⋯ ≫ t.inj i) t
state_after: case refine_2.refine_2
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
t : Cofan fun k => if k = i then X i else ⊥_ C
m : (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).pt ⟶ t.pt
hm :
  ∀ (j : ι), (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).inj j ≫ m = t.inj j
⊢ m = (fun t => eqToHom ⋯ ≫ t.inj i) t

tactic: simp [← hm i]
state_before: case refine_2.refine_2
J : Type v'
inst✝⁵ : Category.{u', v'} J
C : Type u
inst✝⁴ : Category.{v, u} C
K : Type u_1
inst✝³ : Category.{?u.324390, u_1} K
D : Type u_2
inst✝² : Category.{?u.324397, u_2} D
inst✝¹ : HasInitial C
ι : Type u_3
X : ι → C
c : Cofan X
hc : IsVanKampenColimit c
i j : ι
inst✝ : DecidableEq ι
t : Cofan fun k => if k = i then X i else ⊥_ C
m : (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).pt ⟶ t.pt
hm :
  ∀ (j : ι), (Cofan.mk (X i) fun k => if h : k = i then eqToHom ⋯ else eqToHom ⋯ ≫ initial.to (X i)).inj j ≫ m = t.inj j
⊢ m = (fun t => eqToHom ⋯ ≫ t.inj i) t
state_after: no goals