-- Lean 4 proof step from Mathlib.Algebra.Homology.Homotopy (goal)
Goal:
ι : Type u_1
V : Type u
inst : Category.{v, u} V
inst_1 : Preadditive.{v, u} V
c : ComplexShape ι
C D E : HomologicalComplex.{v, u, u_1} V c
f g : C ⟶ D
h k : D ⟶ E
i_1 : ι
P Q : ChainComplex.{v, u, 0} V ℕ
e : P ⟶ Q
zero : P.X 0 ⟶ Q.X 1
comm_zero : e.f 0 = zero ≫ Q.d 1 0
one : P.X 1 ⟶ Q.X 2
comm_one : e.f 1 = P.d 1 0 ≫ zero + one ≫ Q.d 2 1
succ :
  (n : ℕ) →
    (p :
        (f : P.X n ⟶ Q.X (n + 1)) ×'
          (f' : P.X (n + 1) ⟶ Q.X (n + 2)) ×' e.f (n + 1) = P.d (n + 1) n ≫ f + f' ≫ Q.d (n + 2) (n + 1)) →
      (f'' : P.X (n + 2) ⟶ Q.X (n + 3)) ×'
        e.f (n + 2) =
          P.d (n + 2) (n + 1) ≫
              p.snd (β := fun (f : P.X n ⟶ Q.X (n + 1)) ↦
                    (f' : P.X (n + 1) ⟶ Q.X (n + 2)) ×' e.f (n + 1) = P.d (n + 1) n ≫ f + f' ≫ Q.d (n + 2) (n + 1)).fst
                (β := fun (f' : P.X (n + 1) ⟶ Q.X (n + 2)) ↦
                e.f (n + 1) =
                  P.d (n + 1) n ≫
                      p.fst (β := fun (f : P.X n ⟶ Q.X (n + 1)) ↦
                        (f' : P.X (n + 1) ⟶ Q.X (n + 2)) ×'
                          e.f (n + 1) = P.d (n + 1) n ≫ f + f' ≫ Q.d (n + 2) (n + 1)) +
                    f' ≫ Q.d (n + 2) (n + 1)) +
            f'' ≫ Q.d (n + 3) (n + 2)
i : ℕ
⊢ e.f i =
    HAdd.hAdd (α := P.X i ⟶ Q.X i) (β := P.X i ⟶ Q.X i)
        ((dNext i : (a : (i j : ℕ) → P.X i ⟶ Q.X j) → P.X i ⟶ Q.X i) fun (i j : ℕ) ↦
            if h : i + 1 = j then
              (mkInductiveAux₂ e zero comm_zero one comm_one succ i).snd (β := fun (f : xNext P i ⟶ Q.X i) ↦
                      (f' : P.X i ⟶ xPrev Q i) ×' e.f i = dFrom P i ≫ f + f' ≫ dTo Q i).fst
                  (β := fun (f' : P.X i ⟶ xPrev Q i) ↦
                  e.f i =
                    dFrom P i ≫
                        (mkInductiveAux₂ e zero comm_zero one comm_one succ i).fst (β := fun (f : xNext P i ⟶ Q.X i) ↦
                          (f' : P.X i ⟶ xPrev Q i) ×' e.f i = dFrom P i ≫ f + f' ≫ dTo Q i) +
                      f' ≫ dTo Q i) ≫
                (xPrevIso Q h).hom
            else 0 :
          P.X i ⟶ Q.X i)
        ((prevD i : (a : (i j : ℕ) → P.X i ⟶ Q.X j) → P.X i ⟶ Q.X i) fun (i j : ℕ) ↦
            if h : i + 1 = j then
              (mkInductiveAux₂ e zero comm_zero one comm_one succ i).snd (β := fun (f : xNext P i ⟶ Q.X i) ↦
                      (f' : P.X i ⟶ xPrev Q i) ×' e.f i = dFrom P i ≫ f + f' ≫ dTo Q i).fst
                  (β := fun (f' : P.X i ⟶ xPrev Q i) ↦
                  e.f i =
                    dFrom P i ≫
                        (mkInductiveAux₂ e zero comm_zero one comm_one succ i).fst (β := fun (f : xNext P i ⟶ Q.X i) ↦
                          (f' : P.X i ⟶ xPrev Q i) ×' e.f i = dFrom P i ≫ f + f' ≫ dTo Q i) +
                      f' ≫ dTo Q i) ≫
                (xPrevIso Q h).hom
            else 0 :
          P.X i ⟶ Q.X i) +
      Hom.f 0 i
have dsimp : e.f i =
  HAdd.hAdd (α := P.X i ⟶ Q.X i) (β := P.X i ⟶ Q.X i)
      (dFrom P i ≫
        (fromNext i : (a : (i j : ℕ) → P.X i ⟶ Q.X j) → xNext P i ⟶ Q.X i) fun (i j : ℕ) ↦
          if h : i + 1 = j then
            (mkInductiveAux₂ e zero comm_zero one comm_one succ i).snd (β := fun (f : xNext P i ⟶ Q.X i) ↦
                    (f' : P.X i ⟶ xPrev Q i) ×' e.f i = dFrom P i ≫ f + f' ≫ dTo Q i).fst
                (β := fun (f' : P.X i ⟶ xPrev Q i) ↦
                e.f i =
                  dFrom P i ≫
                      (mkInductiveAux₂ e zero comm_zero one comm_one succ i).fst (β := fun (f : xNext P i ⟶ Q.X i) ↦
                        (f' : P.X i ⟶ xPrev Q i) ×' e.f i = dFrom P i ≫ f + f' ≫ dTo Q i) +
                    f' ≫ dTo Q i) ≫
              (xPrevIso Q h).hom
          else 0)
      (((toPrev i : (a : (i j : ℕ) → P.X i ⟶ Q.X j) → P.X i ⟶ xPrev Q i) fun (i j : ℕ) ↦
            if h : i + 1 = j then
              (mkInductiveAux₂ e zero comm_zero one comm_one succ i).snd (β := fun (f : xNext P i ⟶ Q.X i) ↦
                      (f' : P.X i ⟶ xPrev Q i) ×' e.f i = dFrom P i ≫ f + f' ≫ dTo Q i).fst
                  (β := fun (f' : P.X i ⟶ xPrev Q i) ↦
                  e.f i =
                    dFrom P i ≫
                        (mkInductiveAux₂ e zero comm_zero one comm_one succ i).fst (β := fun (f : xNext P i ⟶ Q.X i) ↦
                          (f' : P.X i ⟶ xPrev Q i) ×' e.f i = dFrom P i ≫ f + f' ≫ dTo Q i) +
                      f' ≫ dTo Q i) ≫
                (xPrevIso Q h).hom
            else 0) ≫
          dTo Q i :
        P.X i ⟶ Q.X i) +
    0
Tactic: dsimp