l3lab/ntp-mathlib huggingface dataset:
/-- The canonical isomorphism
`Triangle.shiftFunctor C n ≅ Triangle.shiftFunctor C a ⋙ Triangle.shiftFunctor C b`
when `a + b = n`. -/
@[simps!]
noncomputable def Triangle.shiftFunctorAdd' (a b n : ℤ) (h : a + b = n) :
    Triangle.shiftFunctor C n ≅ Triangle.shiftFunctor C a ⋙ Triangle.shiftFunctor C b :=
  NatIso.ofComponents
    (fun T => Triangle.isoMk _ _
      ((CategoryTheory.shiftFunctorAdd' C a b n h).app _)
      ((CategoryTheory.shiftFunctorAdd' C a b n h).app _)
      ((CategoryTheory.shiftFunctorAdd' C a b n h).app _)
      (by
        subst h
        dsimp
        rw [Linear.units_smul_comp, NatTrans.naturality, Linear.comp_units_smul, Functor.comp_map,
          Functor.map_units_smul, Linear.comp_units_smul, smul_smul, Int.negOnePow_add, mul_comm])
      (by
        subst h
        dsimp
        rw [Linear.units_smul_comp, NatTrans.naturality, Linear.comp_units_smul, Functor.comp_map,
          Functor.map_units_smul, Linear.comp_units_smul, smul_smul, Int.negOnePow_add, mul_comm])
      (by
        subst h
        dsimp
        rw [Linear.units_smul_comp, Linear.comp_units_smul, Functor.map_units_smul,
          Linear.units_smul_comp, Linear.comp_units_smul, smul_smul, assoc,
          Functor.map_comp, assoc]
        erw [← NatTrans.naturality_assoc]
        simp only [shiftFunctorAdd'_eq_shiftFunctorAdd, Int.negOnePow_add,
          shiftFunctorComm_hom_app_comp_shift_shiftFunctorAdd_hom_app, add_comm a]))
    (by 

Proof state:
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (CategoryTheory.shiftFunctor C n)
a b n : ℤ
h : a + b = n
⊢ ∀ {X Y : Triangle C} (f : X ⟶ Y),
    (shiftFunctor C n).map f ≫
        ((fun T =>
              isoMk ((shiftFunctor C n).obj T) ((shiftFunctor C a ⋙ shiftFunctor C b).obj T)
                ((CategoryTheory.shiftFunctorAdd' C a b n h).app T.obj₁)
                ((CategoryTheory.shiftFunctorAdd' C a b n h).app T.obj₂)
                ((CategoryTheory.shiftFunctorAdd' C a b n h).app T.obj₃))
            Y).hom =
      ((fun T =>
              isoMk ((shiftFunctor C n).obj T) ((shiftFunctor C a ⋙ shiftFunctor C b).obj T)
                ((CategoryTheory.shiftFunctorAdd' C a b n h).app T.obj₁)
                ((CategoryTheory.shiftFunctorAdd' C a b n h).app T.obj₂)
                ((CategoryTheory.shiftFunctorAdd' C a b n h).app T.obj₃))
            X).hom ≫
        (shiftFunctor C a ⋙ shiftFunctor C b).map f

Next tactic:
aesop_cat
/-- Rotating triangles three times identifies with the shift by `1`. -/
noncomputable def rotateRotateRotateIso :
    rotate C ⋙ rotate C ⋙ rotate C ≅ Triangle.shiftFunctor C 1 :=
  NatIso.ofComponents
    (fun T => Triangle.isoMk _ _ (Iso.refl _) (Iso.refl _) (Iso.refl _)
      (by 

Proof state:
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
T : Triangle C
⊢ ((rotate C ⋙ rotate C ⋙ rotate C).obj T).mor₁ ≫ (Iso.refl ((rotate C ⋙ rotate C ⋙ rotate C).obj T).obj₂).hom =
    (Iso.refl ((rotate C ⋙ rotate C ⋙ rotate C).obj T).obj₁).hom ≫ ((Triangle.shiftFunctor C 1).obj T).mor₁

Next tactic:
aesop_cat
/-- Rotating triangles three times identifies with the shift by `1`. -/
noncomputable def rotateRotateRotateIso :
    rotate C ⋙ rotate C ⋙ rotate C ≅ Triangle.shiftFunctor C 1 :=
  NatIso.ofComponents
    (fun T => Triangle.isoMk _ _ (Iso.refl _) (Iso.refl _) (Iso.refl _)
      (by aesop_cat) (by 

Proof state:
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
T : Triangle C
⊢ ((rotate C ⋙ rotate C ⋙ rotate C).obj T).mor₂ ≫ (Iso.refl ((rotate C ⋙ rotate C ⋙ rotate C).obj T).obj₃).hom =
    (Iso.refl ((rotate C ⋙ rotate C ⋙ rotate C).obj T).obj₂).hom ≫ ((Triangle.shiftFunctor C 1).obj T).mor₂

Next tactic:
aesop_cat
/-- Rotating triangles three times identifies with the shift by `1`. -/
noncomputable def rotateRotateRotateIso :
    rotate C ⋙ rotate C ⋙ rotate C ≅ Triangle.shiftFunctor C 1 :=
  NatIso.ofComponents
    (fun T => Triangle.isoMk _ _ (Iso.refl _) (Iso.refl _) (Iso.refl _)
      (by aesop_cat) (by aesop_cat) (by 

Proof state:
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
T : Triangle C
⊢ ((rotate C ⋙ rotate C ⋙ rotate C).obj T).mor₃ ≫
      (shiftFunctor C 1).map (Iso.refl ((rotate C ⋙ rotate C ⋙ rotate C).obj T).obj₁).hom =
    (Iso.refl ((rotate C ⋙ rotate C ⋙ rotate C).obj T).obj₃).hom ≫ ((Triangle.shiftFunctor C 1).obj T).mor₃

Next tactic:
aesop_cat
/-- Rotating triangles three times identifies with the shift by `1`. -/
noncomputable def rotateRotateRotateIso :
    rotate C ⋙ rotate C ⋙ rotate C ≅ Triangle.shiftFunctor C 1 :=
  NatIso.ofComponents
    (fun T => Triangle.isoMk _ _ (Iso.refl _) (Iso.refl _) (Iso.refl _)
      (by aesop_cat) (by aesop_cat) (by aesop_cat))
    (by 

Proof state:
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
⊢ ∀ {X Y : Triangle C} (f : X ⟶ Y),
    (rotate C ⋙ rotate C ⋙ rotate C).map f ≫
        ((fun T =>
              Triangle.isoMk ((rotate C ⋙ rotate C ⋙ rotate C).obj T) ((Triangle.shiftFunctor C 1).obj T)
                (Iso.refl ((rotate C ⋙ rotate C ⋙ rotate C).obj T).obj₁)
                (Iso.refl ((rotate C ⋙ rotate C ⋙ rotate C).obj T).obj₂)
                (Iso.refl ((rotate C ⋙ rotate C ⋙ rotate C).obj T).obj₃))
            Y).hom =
      ((fun T =>
              Triangle.isoMk ((rotate C ⋙ rotate C ⋙ rotate C).obj T) ((Triangle.shiftFunctor C 1).obj T)
                (Iso.refl ((rotate C ⋙ rotate C ⋙ rotate C).obj T).obj₁)
                (Iso.refl ((rotate C ⋙ rotate C ⋙ rotate C).obj T).obj₂)
                (Iso.refl ((rotate C ⋙ rotate C ⋙ rotate C).obj T).obj₃))
            X).hom ≫
        (Triangle.shiftFunctor C 1).map f

Next tactic:
aesop_cat
/-- Rotating triangles three times backwards identifies with the shift by `-1`. -/
noncomputable def invRotateInvRotateInvRotateIso :
    invRotate C ⋙ invRotate C ⋙ invRotate C ≅ Triangle.shiftFunctor C (-1) :=
  NatIso.ofComponents
    (fun T => Triangle.isoMk _ _ (Iso.refl _) (Iso.refl _) (Iso.refl _)
      (by 

Proof state:
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
T : Triangle C
⊢ ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).mor₁ ≫
      (Iso.refl ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).obj₂).hom =
    (Iso.refl ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).obj₁).hom ≫ ((Triangle.shiftFunctor C (-1)).obj T).mor₁

Next tactic:
aesop_cat
/-- Rotating triangles three times backwards identifies with the shift by `-1`. -/
noncomputable def invRotateInvRotateInvRotateIso :
    invRotate C ⋙ invRotate C ⋙ invRotate C ≅ Triangle.shiftFunctor C (-1) :=
  NatIso.ofComponents
    (fun T => Triangle.isoMk _ _ (Iso.refl _) (Iso.refl _) (Iso.refl _)
      (by aesop_cat)
      (by 

Proof state:
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
T : Triangle C
⊢ ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).mor₂ ≫
      (Iso.refl ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).obj₃).hom =
    (Iso.refl ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).obj₂).hom ≫ ((Triangle.shiftFunctor C (-1)).obj T).mor₂

Next tactic:
aesop_cat
/-- Rotating triangles three times backwards identifies with the shift by `-1`. -/
noncomputable def invRotateInvRotateInvRotateIso :
    invRotate C ⋙ invRotate C ⋙ invRotate C ≅ Triangle.shiftFunctor C (-1) :=
  NatIso.ofComponents
    (fun T => Triangle.isoMk _ _ (Iso.refl _) (Iso.refl _) (Iso.refl _)
      (by aesop_cat)
      (by aesop_cat)
      (by
        

Proof state:
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
T : Triangle C
⊢ ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).mor₃ ≫
      (shiftFunctor C 1).map (Iso.refl ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).obj₁).hom =
    (Iso.refl ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).obj₃).hom ≫ ((Triangle.shiftFunctor C (-1)).obj T).mor₃

Next tactic:
dsimp [shiftFunctorCompIsoId]
/-- Rotating triangles three times backwards identifies with the shift by `-1`. -/
noncomputable def invRotateInvRotateInvRotateIso :
    invRotate C ⋙ invRotate C ⋙ invRotate C ≅ Triangle.shiftFunctor C (-1) :=
  NatIso.ofComponents
    (fun T => Triangle.isoMk _ _ (Iso.refl _) (Iso.refl _) (Iso.refl _)
      (by aesop_cat)
      (by aesop_cat)
      (by
        dsimp [shiftFunctorCompIsoId]
        

Proof state:
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
T : Triangle C
⊢ ((-(shiftFunctor C (-1)).map T.mor₃ ≫
            (shiftFunctorAdd' C 1 (-1) 0 (_ : 1 + -1 = 0)).inv.app T.obj₁ ≫ (shiftFunctorZero C ℤ).hom.app T.obj₁) ≫
        (shiftFunctorZero C ℤ).inv.app T.obj₁ ≫ (shiftFunctorAdd' C (-1) 1 0 (_ : -1 + 1 = 0)).hom.app T.obj₁) ≫
      (shiftFunctor C 1).map (𝟙 ((shiftFunctor C (-1)).obj T.obj₁)) =
    𝟙 ((shiftFunctor C (-1)).obj T.obj₃) ≫
      ((-1).negOnePow • (shiftFunctor C (-1)).map T.mor₃ ≫ (shiftFunctorComm C 1 (-1)).hom.app T.obj₁)

Next tactic:
simp [shiftFunctorComm_eq C _ _ _ (add_neg_self (1 : ℤ))]
/-- Rotating triangles three times backwards identifies with the shift by `-1`. -/
noncomputable def invRotateInvRotateInvRotateIso :
    invRotate C ⋙ invRotate C ⋙ invRotate C ≅ Triangle.shiftFunctor C (-1) :=
  NatIso.ofComponents
    (fun T => Triangle.isoMk _ _ (Iso.refl _) (Iso.refl _) (Iso.refl _)
      (by aesop_cat)
      (by aesop_cat)
      (by
        dsimp [shiftFunctorCompIsoId]
        simp [shiftFunctorComm_eq C _ _ _ (add_neg_self (1 : ℤ))]))
    (by 

Proof state:
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
⊢ ∀ {X Y : Triangle C} (f : X ⟶ Y),
    (invRotate C ⋙ invRotate C ⋙ invRotate C).map f ≫
        ((fun T =>
              Triangle.isoMk ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T) ((Triangle.shiftFunctor C (-1)).obj T)
                (Iso.refl ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).obj₁)
                (Iso.refl ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).obj₂)
                (Iso.refl ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).obj₃))
            Y).hom =
      ((fun T =>
              Triangle.isoMk ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T) ((Triangle.shiftFunctor C (-1)).obj T)
                (Iso.refl ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).obj₁)
                (Iso.refl ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).obj₂)
                (Iso.refl ((invRotate C ⋙ invRotate C ⋙ invRotate C).obj T).obj₃))
            X).hom ≫
        (Triangle.shiftFunctor C (-1)).map f

Next tactic:
aesop_cat
noncomputable instance : HasShift (Triangle C) ℤ :=
  hasShiftMk (Triangle C) ℤ
    { F := Triangle.shiftFunctor C
      zero := Triangle.shiftFunctorZero C
      add := fun a b => Triangle.shiftFunctorAdd' C a b _ rfl
      assoc_hom_app := fun a b c T => by
        

Proof state:
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
a b c : ℤ
T : Triangle C
⊢ ((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) (a + b) c).hom.app T ≫
      (Triangle.shiftFunctor C c).map
        (((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) a b).hom.app T) =
    eqToHom (_ : (Triangle.shiftFunctor C (a + b + c)).obj T = (Triangle.shiftFunctor C (a + (b + c))).obj T) ≫
      ((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) a (b + c)).hom.app T ≫
        ((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) b c).hom.app
          ((Triangle.shiftFunctor C a).obj T)

Next tactic:
ext
noncomputable instance : HasShift (Triangle C) ℤ :=
  hasShiftMk (Triangle C) ℤ
    { F := Triangle.shiftFunctor C
      zero := Triangle.shiftFunctorZero C
      add := fun a b => Triangle.shiftFunctorAdd' C a b _ rfl
      assoc_hom_app := fun a b c T => by
        ext
        

Proof state:
case h₁
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
a b c : ℤ
T : Triangle C
⊢ (((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) (a + b) c).hom.app T ≫
        (Triangle.shiftFunctor C c).map
          (((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) a b).hom.app T)).hom₁ =
    (eqToHom (_ : (Triangle.shiftFunctor C (a + b + c)).obj T = (Triangle.shiftFunctor C (a + (b + c))).obj T) ≫
        ((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) a (b + c)).hom.app T ≫
          ((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) b c).hom.app
            ((Triangle.shiftFunctor C a).obj T)).hom₁
case h₂
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
a b c : ℤ
T : Triangle C
⊢ (((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) (a + b) c).hom.app T ≫
        (Triangle.shiftFunctor C c).map
          (((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) a b).hom.app T)).hom₂ =
    (eqToHom (_ : (Triangle.shiftFunctor C (a + b + c)).obj T = (Triangle.shiftFunctor C (a + (b + c))).obj T) ≫
        ((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) a (b + c)).hom.app T ≫
          ((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) b c).hom.app
            ((Triangle.shiftFunctor C a).obj T)).hom₂
case h₃
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
a b c : ℤ
T : Triangle C
⊢ (((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) (a + b) c).hom.app T ≫
        (Triangle.shiftFunctor C c).map
          (((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) a b).hom.app T)).hom₃ =
    (eqToHom (_ : (Triangle.shiftFunctor C (a + b + c)).obj T = (Triangle.shiftFunctor C (a + (b + c))).obj T) ≫
        ((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) a (b + c)).hom.app T ≫
          ((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) b c).hom.app
            ((Triangle.shiftFunctor C a).obj T)).hom₃

Next tactic:
all_goals
          dsimp
          rw [← shiftFunctorAdd'_assoc_hom_app a b c _ _ _ rfl rfl (add_assoc a b c)]
          dsimp only [CategoryTheory.shiftFunctorAdd']
          simp
noncomputable instance : HasShift (Triangle C) ℤ :=
  hasShiftMk (Triangle C) ℤ
    { F := Triangle.shiftFunctor C
      zero := Triangle.shiftFunctorZero C
      add := fun a b => Triangle.shiftFunctorAdd' C a b _ rfl
      assoc_hom_app := fun a b c T => by
        ext
        all_goals
          

Proof state:
case h₁
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
a b c : ℤ
T : Triangle C
⊢ (((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) (a + b) c).hom.app T ≫
        (Triangle.shiftFunctor C c).map
          (((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) a b).hom.app T)).hom₁ =
    (eqToHom (_ : (Triangle.shiftFunctor C (a + b + c)).obj T = (Triangle.shiftFunctor C (a + (b + c))).obj T) ≫
        ((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) a (b + c)).hom.app T ≫
          ((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) b c).hom.app
            ((Triangle.shiftFunctor C a).obj T)).hom₁

Next tactic:
dsimp
noncomputable instance : HasShift (Triangle C) ℤ :=
  hasShiftMk (Triangle C) ℤ
    { F := Triangle.shiftFunctor C
      zero := Triangle.shiftFunctorZero C
      add := fun a b => Triangle.shiftFunctorAdd' C a b _ rfl
      assoc_hom_app := fun a b c T => by
        ext
        all_goals
          dsimp
          

Proof state:
case h₁
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
a b c : ℤ
T : Triangle C
⊢ (shiftFunctorAdd' C (a + b) c (a + b + c) (_ : a + b + c = a + b + c)).hom.app T.obj₁ ≫
      (shiftFunctor C c).map ((shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)).hom.app T.obj₁) =
    (eqToHom
          (_ :
            Triangle.mk ((a + b + c).negOnePow • (shiftFunctor C (a + b + c)).map T.mor₁)
                ((a + b + c).negOnePow • (shiftFunctor C (a + b + c)).map T.mor₂)
                ((a + b + c).negOnePow •
                  (shiftFunctor C (a + b + c)).map T.mor₃ ≫ (shiftFunctorComm C 1 (a + b + c)).hom.app T.obj₁) =
              Triangle.mk ((a + (b + c)).negOnePow • (shiftFunctor C (a + (b + c))).map T.mor₁)
                ((a + (b + c)).negOnePow • (shiftFunctor C (a + (b + c))).map T.mor₂)
                ((a + (b + c)).negOnePow •
                  (shiftFunctor C (a + (b + c))).map T.mor₃ ≫
                    (shiftFunctorComm C 1 (a + (b + c))).hom.app T.obj₁))).hom₁ ≫
      (shiftFunctorAdd' C a (b + c) (a + (b + c)) (_ : a + (b + c) = a + (b + c))).hom.app T.obj₁ ≫
        (shiftFunctorAdd' C b c (b + c) (_ : b + c = b + c)).hom.app ((shiftFunctor C a).obj T.obj₁)

Next tactic:
rw [← shiftFunctorAdd'_assoc_hom_app a b c _ _ _ rfl rfl (add_assoc a b c)]
noncomputable instance : HasShift (Triangle C) ℤ :=
  hasShiftMk (Triangle C) ℤ
    { F := Triangle.shiftFunctor C
      zero := Triangle.shiftFunctorZero C
      add := fun a b => Triangle.shiftFunctorAdd' C a b _ rfl
      assoc_hom_app := fun a b c T => by
        ext
        all_goals
          dsimp
          rw [← shiftFunctorAdd'_assoc_hom_app a b c _ _ _ rfl rfl (add_assoc a b c)]
          

Proof state:
case h₁
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
a b c : ℤ
T : Triangle C
⊢ (shiftFunctorAdd' C (a + b) c (a + b + c) (_ : a + b + c = a + b + c)).hom.app T.obj₁ ≫
      (shiftFunctor C c).map ((shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)).hom.app T.obj₁) =
    (eqToHom
          (_ :
            Triangle.mk ((a + b + c).negOnePow • (shiftFunctor C (a + b + c)).map T.mor₁)
                ((a + b + c).negOnePow • (shiftFunctor C (a + b + c)).map T.mor₂)
                ((a + b + c).negOnePow •
                  (shiftFunctor C (a + b + c)).map T.mor₃ ≫ (shiftFunctorComm C 1 (a + b + c)).hom.app T.obj₁) =
              Triangle.mk ((a + (b + c)).negOnePow • (shiftFunctor C (a + (b + c))).map T.mor₁)
                ((a + (b + c)).negOnePow • (shiftFunctor C (a + (b + c))).map T.mor₂)
                ((a + (b + c)).negOnePow •
                  (shiftFunctor C (a + (b + c))).map T.mor₃ ≫
                    (shiftFunctorComm C 1 (a + (b + c))).hom.app T.obj₁))).hom₁ ≫
      (shiftFunctorAdd' C (a + b) c (a + (b + c)) (_ : a + b + c = a + (b + c))).hom.app T.obj₁ ≫
        (shiftFunctor C c).map ((shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)).hom.app T.obj₁)

Next tactic:
dsimp only [CategoryTheory.shiftFunctorAdd']
noncomputable instance : HasShift (Triangle C) ℤ :=
  hasShiftMk (Triangle C) ℤ
    { F := Triangle.shiftFunctor C
      zero := Triangle.shiftFunctorZero C
      add := fun a b => Triangle.shiftFunctorAdd' C a b _ rfl
      assoc_hom_app := fun a b c T => by
        ext
        all_goals
          dsimp
          rw [← shiftFunctorAdd'_assoc_hom_app a b c _ _ _ rfl rfl (add_assoc a b c)]
          dsimp only [CategoryTheory.shiftFunctorAdd']
          

Proof state:
case h₁
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
a b c : ℤ
T : Triangle C
⊢ (eqToIso (_ : shiftFunctor C (a + b + c) = shiftFunctor C (a + b + c)) ≪≫ shiftFunctorAdd C (a + b) c).hom.app
        T.obj₁ ≫
      (shiftFunctor C c).map
        ((eqToIso (_ : shiftFunctor C (a + b) = shiftFunctor C (a + b)) ≪≫ shiftFunctorAdd C a b).hom.app T.obj₁) =
    (eqToHom
          (_ :
            Triangle.mk ((a + b + c).negOnePow • (shiftFunctor C (a + b + c)).map T.mor₁)
                ((a + b + c).negOnePow • (shiftFunctor C (a + b + c)).map T.mor₂)
                ((a + b + c).negOnePow •
                  (shiftFunctor C (a + b + c)).map T.mor₃ ≫ (shiftFunctorComm C 1 (a + b + c)).hom.app T.obj₁) =
              Triangle.mk ((a + (b + c)).negOnePow • (shiftFunctor C (a + (b + c))).map T.mor₁)
                ((a + (b + c)).negOnePow • (shiftFunctor C (a + (b + c))).map T.mor₂)
                ((a + (b + c)).negOnePow •
                  (shiftFunctor C (a + (b + c))).map T.mor₃ ≫
                    (shiftFunctorComm C 1 (a + (b + c))).hom.app T.obj₁))).hom₁ ≫
      (eqToIso (_ : shiftFunctor C (a + (b + c)) = shiftFunctor C (a + b + c)) ≪≫ shiftFunctorAdd C (a + b) c).hom.app
          T.obj₁ ≫
        (shiftFunctor C c).map
          ((eqToIso (_ : shiftFunctor C (a + b) = shiftFunctor C (a + b)) ≪≫ shiftFunctorAdd C a b).hom.app T.obj₁)

Next tactic:
simp
noncomputable instance : HasShift (Triangle C) ℤ :=
  hasShiftMk (Triangle C) ℤ
    { F := Triangle.shiftFunctor C
      zero := Triangle.shiftFunctorZero C
      add := fun a b => Triangle.shiftFunctorAdd' C a b _ rfl
      assoc_hom_app := fun a b c T => by
        ext
        all_goals
          

Proof state:
case h₂
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
a b c : ℤ
T : Triangle C
⊢ (((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) (a + b) c).hom.app T ≫
        (Triangle.shiftFunctor C c).map
          (((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) a b).hom.app T)).hom₂ =
    (eqToHom (_ : (Triangle.shiftFunctor C (a + b + c)).obj T = (Triangle.shiftFunctor C (a + (b + c))).obj T) ≫
        ((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) a (b + c)).hom.app T ≫
          ((fun a b => Triangle.shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)) b c).hom.app
            ((Triangle.shiftFunctor C a).obj T)).hom₂

Next tactic:
dsimp
noncomputable instance : HasShift (Triangle C) ℤ :=
  hasShiftMk (Triangle C) ℤ
    { F := Triangle.shiftFunctor C
      zero := Triangle.shiftFunctorZero C
      add := fun a b => Triangle.shiftFunctorAdd' C a b _ rfl
      assoc_hom_app := fun a b c T => by
        ext
        all_goals
          dsimp
          

Proof state:
case h₂
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : Preadditive C
inst✝¹ : HasShift C ℤ
inst✝ : ∀ (n : ℤ), Functor.Additive (shiftFunctor C n)
a b c : ℤ
T : Triangle C
⊢ (shiftFunctorAdd' C (a + b) c (a + b + c) (_ : a + b + c = a + b + c)).hom.app T.obj₂ ≫
      (shiftFunctor C c).map ((shiftFunctorAdd' C a b (a + b) (_ : a + b = a + b)).hom.app T.obj₂) =
    (eqToHom
          (_ :
            Triangle.mk ((a + b + c).negOnePow • (shiftFunctor C (a + b + c)).map T.mor₁)
                ((a + b + c).negOnePow • (shiftFunctor C (a + b + c)).map T.mor₂)
                ((a + b + c).negOnePow •
                  (shiftFunctor C (a + b + c)).map T.mor₃ ≫ (shiftFunctorComm C 1 (a + b + c)).hom.app T.obj₁) =
              Triangle.mk ((a + (b + c)).negOnePow • (shiftFunctor C (a + (b + c))).map T.mor₁)
                ((a + (b + c)).negOnePow • (shiftFunctor C (a + (b + c))).map T.mor₂)
                ((a + (b + c)).negOnePow •
                  (shiftFunctor C (a + (b + c))).map T.mor₃ ≫
                    (shiftFunctorComm C 1 (a + (b + c))).hom.app T.obj₁))).hom₂ ≫
      (shiftFunctorAdd' C a (b + c) (a + (b + c)) (_ : a + (b + c) = a + (b + c))).hom.app T.obj₂ ≫
        (shiftFunctorAdd' C b c (b + c) (_ : b + c = b + c)).hom.app ((shiftFunctor C a).obj T.obj₂)

Next tactic:
rw [← shiftFunctorAdd'_assoc_hom_app a b c _ _ _ rfl rfl (add_assoc a b c)]