Theorem: SimplicialObject.Splitting.toKaroubiNondegComplexIsoN₁_inv_f_f
File: Mathlib/AlgebraicTopology/DoldKan/SplitSimplicialObject.lean

Proof steps:
state_before: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
i j : ℕ
x✝ : (ComplexShape.down ℕ).Rel i j
⊢ (fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n) i ≫ (N₁.obj X).X.d i j =
    ((toKaroubi (ChainComplex C ℕ)).obj s.nondegComplex).X.d i j ≫
      (fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n) j
state_after: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
i j : ℕ
x✝ : (ComplexShape.down ℕ).Rel i j
⊢ ((s.cofan (op [i])).inj (IndexSet.id (op [i])) ≫ PInfty.f i) ≫ K[X].d i j =
    ((s.cofan (op [i])).inj (IndexSet.id (op [i])) ≫ K[X].d i j ≫ s.πSummand (IndexSet.id (op [j]))) ≫
      (s.cofan (op [j])).inj (IndexSet.id (op [j])) ≫ PInfty.f j
tactic: dsimp
state_before: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
i j : ℕ
x✝ : (ComplexShape.down ℕ).Rel i j
⊢ ((s.cofan (op [i])).inj (IndexSet.id (op [i])) ≫ PInfty.f i) ≫ K[X].d i j =
    ((s.cofan (op [i])).inj (IndexSet.id (op [i])) ≫ K[X].d i j ≫ s.πSummand (IndexSet.id (op [j]))) ≫
      (s.cofan (op [j])).inj (IndexSet.id (op [j])) ≫ PInfty.f j
state_after: no goals
tactic: rw [assoc, assoc, assoc, πSummand_comp_cofan_inj_id_comp_PInfty_eq_PInfty,
              HomologicalComplex.Hom.comm]
state_before: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
⊢ { f := fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n, comm' := ⋯ } =
    ((toKaroubi (ChainComplex C ℕ)).obj s.nondegComplex).p ≫
      { f := fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n, comm' := ⋯ } ≫ (N₁.obj X).p
state_after: case h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ { f := fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n, comm' := ⋯ }.f n =
    (((toKaroubi (ChainComplex C ℕ)).obj s.nondegComplex).p ≫
          { f := fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n, comm' := ⋯ } ≫ (N₁.obj X).p).f
      n
tactic: ext n
state_before: case h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ { f := fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n, comm' := ⋯ }.f n =
    (((toKaroubi (ChainComplex C ℕ)).obj s.nondegComplex).p ≫
          { f := fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n, comm' := ⋯ } ≫ (N₁.obj X).p).f
      n
state_after: case h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n =
    𝟙 (s.N n) ≫ ((s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n) ≫ PInfty.f n
tactic: dsimp
state_before: case h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n =
    𝟙 (s.N n) ≫ ((s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n) ≫ PInfty.f n
state_after: no goals
tactic: rw [id_comp, assoc, PInfty_f_idem]
state_before: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
i j : ℕ
x✝ : (ComplexShape.down ℕ).Rel i j
⊢ (fun n => s.πSummand (IndexSet.id (op [n]))) i ≫ ((toKaroubi (ChainComplex C ℕ)).obj s.nondegComplex).X.d i j =
    (N₁.obj X).X.d i j ≫ (fun n => s.πSummand (IndexSet.id (op [n]))) j
state_after: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
i j : ℕ
x✝ : (ComplexShape.down ℕ).Rel i j
⊢ s.πSummand (IndexSet.id (op [i])) ≫
      (s.cofan (op [i])).inj (IndexSet.id (op [i])) ≫ K[X].d i j ≫ s.πSummand (IndexSet.id (op [j])) =
    K[X].d i j ≫ s.πSummand (IndexSet.id (op [j]))
tactic: dsimp
state_before: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
i j : ℕ
x✝ : (ComplexShape.down ℕ).Rel i j
⊢ s.πSummand (IndexSet.id (op [i])) ≫
      (s.cofan (op [i])).inj (IndexSet.id (op [i])) ≫ K[X].d i j ≫ s.πSummand (IndexSet.id (op [j])) =
    K[X].d i j ≫ s.πSummand (IndexSet.id (op [j]))
state_after: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
i j : ℕ
x✝ : (ComplexShape.down ℕ).Rel i j
⊢ s.πSummand (IndexSet.id (op [i])) ≫
      (s.cofan (op [i])).inj (IndexSet.id (op [i])) ≫ K[X].d i j ≫ s.πSummand (IndexSet.id (op [j])) =
    (𝟙 (K[X].X i) ≫ K[X].d i j) ≫ s.πSummand (IndexSet.id (op [j]))
tactic: slice_rhs 1 1 => rw [← id_comp (K[X].d i j)]
state_before: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
i j : ℕ
x✝ : (ComplexShape.down ℕ).Rel i j
⊢ s.πSummand (IndexSet.id (op [i])) ≫
      (s.cofan (op [i])).inj (IndexSet.id (op [i])) ≫ K[X].d i j ≫ s.πSummand (IndexSet.id (op [j])) =
    (𝟙 (K[X].X i) ≫ K[X].d i j) ≫ s.πSummand (IndexSet.id (op [j]))
state_after: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
i j : ℕ
x✝ : (ComplexShape.down ℕ).Rel i j
⊢ s.πSummand (IndexSet.id (op [i])) ≫
      (s.cofan (op [i])).inj (IndexSet.id (op [i])) ≫ K[X].d i j ≫ s.πSummand (IndexSet.id (op [j])) =
    ((∑ A : IndexSet (op [i]), s.πSummand A ≫ (s.cofan (op [i])).inj A) ≫ K[X].d i j) ≫
      s.πSummand (IndexSet.id (op [j]))
tactic: erw [s.decomposition_id]
state_before: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
i j : ℕ
x✝ : (ComplexShape.down ℕ).Rel i j
⊢ s.πSummand (IndexSet.id (op [i])) ≫
      (s.cofan (op [i])).inj (IndexSet.id (op [i])) ≫ K[X].d i j ≫ s.πSummand (IndexSet.id (op [j])) =
    ((∑ A : IndexSet (op [i]), s.πSummand A ≫ (s.cofan (op [i])).inj A) ≫ K[X].d i j) ≫
      s.πSummand (IndexSet.id (op [j]))
state_after: case h₀
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
i j : ℕ
x✝ : (ComplexShape.down ℕ).Rel i j
⊢ ∀ b ∈ Finset.univ,
    b ≠ IndexSet.id (op [i]) →
      ((s.πSummand b ≫ (s.cofan (op [i])).inj b) ≫ K[X].d i j) ≫ s.πSummand (IndexSet.id (op [j])) = 0

case h₁
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
i j : ℕ
x✝ : (ComplexShape.down ℕ).Rel i j
⊢ IndexSet.id (op [i]) ∉ Finset.univ →
    ((s.πSummand (IndexSet.id (op [i])) ≫ (s.cofan (op [i])).inj (IndexSet.id (op [i]))) ≫ K[X].d i j) ≫
        s.πSummand (IndexSet.id (op [j])) =
      0
tactic: rw [sum_comp, sum_comp, Finset.sum_eq_single (IndexSet.id (op [i])), assoc, assoc]
state_before: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
⊢ { f := fun n => s.πSummand (IndexSet.id (op [n])), comm' := ⋯ } =
    (N₁.obj X).p ≫
      { f := fun n => s.πSummand (IndexSet.id (op [n])), comm' := ⋯ } ≫
        ((toKaroubi (ChainComplex C ℕ)).obj s.nondegComplex).p
state_after: case h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ { f := fun n => s.πSummand (IndexSet.id (op [n])), comm' := ⋯ }.f n =
    ((N₁.obj X).p ≫
          { f := fun n => s.πSummand (IndexSet.id (op [n])), comm' := ⋯ } ≫
            ((toKaroubi (ChainComplex C ℕ)).obj s.nondegComplex).p).f
      n
tactic: ext n
state_before: case h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ { f := fun n => s.πSummand (IndexSet.id (op [n])), comm' := ⋯ }.f n =
    ((N₁.obj X).p ≫
          { f := fun n => s.πSummand (IndexSet.id (op [n])), comm' := ⋯ } ≫
            ((toKaroubi (ChainComplex C ℕ)).obj s.nondegComplex).p).f
      n
state_after: case h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ s.πSummand (IndexSet.id (op [n])) = PInfty.f n ≫ s.πSummand (IndexSet.id (op [n])) ≫ 𝟙 (s.N n)
tactic: dsimp
state_before: case h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ s.πSummand (IndexSet.id (op [n])) = PInfty.f n ≫ s.πSummand (IndexSet.id (op [n])) ≫ 𝟙 (s.N n)
state_after: no goals
tactic: simp only [comp_id, PInfty_comp_πSummand_id]
state_before: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
⊢ { f := { f := fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n, comm' := ⋯ }, comm := ⋯ } ≫
      { f := { f := fun n => s.πSummand (IndexSet.id (op [n])), comm' := ⋯ }, comm := ⋯ } =
    𝟙 ((toKaroubi (ChainComplex C ℕ)).obj s.nondegComplex)
state_after: case h.h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ ({ f := { f := fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n, comm' := ⋯ }, comm := ⋯ } ≫
            { f := { f := fun n => s.πSummand (IndexSet.id (op [n])), comm' := ⋯ }, comm := ⋯ }).f.f
      n =
    (𝟙 ((toKaroubi (ChainComplex C ℕ)).obj s.nondegComplex)).f.f n
tactic: ext n
state_before: case h.h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ ({ f := { f := fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n, comm' := ⋯ }, comm := ⋯ } ≫
            { f := { f := fun n => s.πSummand (IndexSet.id (op [n])), comm' := ⋯ }, comm := ⋯ }).f.f
      n =
    (𝟙 ((toKaroubi (ChainComplex C ℕ)).obj s.nondegComplex)).f.f n
state_after: case h.h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ 𝟙 (summand s.N (op [n]) (IndexSet.id (op [n]))) = (𝟙 ((toKaroubi (ChainComplex C ℕ)).obj s.nondegComplex)).f.f n
tactic: simp only [assoc, PInfty_comp_πSummand_id, Karoubi.comp_f, HomologicalComplex.comp_f,
      cofan_inj_πSummand_eq_id]
state_before: case h.h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ 𝟙 (summand s.N (op [n]) (IndexSet.id (op [n]))) = (𝟙 ((toKaroubi (ChainComplex C ℕ)).obj s.nondegComplex)).f.f n
state_after: no goals
tactic: rfl
state_before: C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
⊢ { f := { f := fun n => s.πSummand (IndexSet.id (op [n])), comm' := ⋯ }, comm := ⋯ } ≫
      { f := { f := fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n, comm' := ⋯ }, comm := ⋯ } =
    𝟙 (N₁.obj X)
state_after: case h.h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ ({ f := { f := fun n => s.πSummand (IndexSet.id (op [n])), comm' := ⋯ }, comm := ⋯ } ≫
            { f := { f := fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n, comm' := ⋯ },
              comm := ⋯ }).f.f
      n =
    (𝟙 (N₁.obj X)).f.f n
tactic: ext n
state_before: case h.h
C : Type u_1
inst✝¹ : Category.{?u.75295, u_1} C
X : SimplicialObject C
s : Splitting X
inst✝ : Preadditive C
n : ℕ
⊢ ({ f := { f := fun n => s.πSummand (IndexSet.id (op [n])), comm' := ⋯ }, comm := ⋯ } ≫
            { f := { f := fun n => (s.cofan (op [n])).inj (IndexSet.id (op [n])) ≫ PInfty.f n, comm' := ⋯ },
              comm := ⋯ }).f.f
      n =
    (𝟙 (N₁.obj X)).f.f n
state_after: no goals
tactic: simp only [πSummand_comp_cofan_inj_id_comp_PInfty_eq_PInfty, Karoubi.comp_f,
      HomologicalComplex.comp_f, N₁_obj_p, Karoubi.id_f]