File: Mathlib/Algebra/Homology/HomotopyCategory/Shift.lean

full_name: CochainComplex.shiftFunctor_obj_d
code: /-- The shift functor by `n : ℤ` on `CochainComplex C ℤ` which sends a cochain
complex `K` to the complex which is `K.X (i + n)` in degree `i`, and which
multiplies the differentials by `(-1)^n`. -/
@[simps]
def shiftFunctor (n : ℤ) : CochainComplex C ℤ ⥤ CochainComplex C ℤ 
goal: ((CochainComplex.shiftFunctor C n).obj K).d i j = n.negOnePow • K.d (i + n) (j + n)

full_name: CochainComplex.shiftFunctor_obj_X
code: /-- The shift functor by `n : ℤ` on `CochainComplex C ℤ` which sends a cochain
complex `K` to the complex which is `K.X (i + n)` in degree `i`, and which
multiplies the differentials by `(-1)^n`. -/
@[simps]
def shiftFunctor (n : ℤ) : CochainComplex C ℤ ⥤ CochainComplex C ℤ 
goal: ((CochainComplex.shiftFunctor C n).obj K).X i = K.X (i + n)

full_name: CochainComplex.shiftFunctor
code: /-- The shift functor by `n : ℤ` on `CochainComplex C ℤ` which sends a cochain
complex `K` to the complex which is `K.X (i + n)` in degree `i`, and which
multiplies the differentials by `(-1)^n`. -/
@[simps]
def shiftFunctor (n : ℤ) : CochainComplex C ℤ ⥤ CochainComplex C ℤ 
goal: CochainComplex C ℤ ⥤ CochainComplex C ℤ

full_name: CochainComplex.shiftFunctor_map_f
code: /-- The shift functor by `n : ℤ` on `CochainComplex C ℤ` which sends a cochain
complex `K` to the complex which is `K.X (i + n)` in degree `i`, and which
multiplies the differentials by `(-1)^n`. -/
@[simps]
def shiftFunctor (n : ℤ) : CochainComplex C ℤ ⥤ CochainComplex C ℤ 
goal: ∀ {X Y : CochainComplex C ℤ} (φ : X ⟶ Y) (i : ℤ), ((CochainComplex.shiftFunctor C n).map φ).f i = φ.f (i + n)

full_name: CochainComplex.instAdditiveIntShiftFunctor
code: instance (n : ℤ) : (shiftFunctor C n).Additive 
goal: (CochainComplex.shiftFunctor C n).Additive

full_name: CochainComplex.shiftFunctorObjXIso
code: /-- The canonical isomorphism `((shiftFunctor C n).obj K).X i ≅ K.X m` when `m = i + n`. -/
@[simp]
def shiftFunctorObjXIso (K : CochainComplex C ℤ) (n i m : ℤ) (hm : m = i + n) :
    ((shiftFunctor C n).obj K).X i ≅ K.X m 
goal: ((CochainComplex.shiftFunctor C n).obj K).X i ≅ K.X m

full_name: CochainComplex.shiftFunctorZero'_hom_app_f
code: /-- The shift functor by `n` on `CochainComplex C ℤ` identifies to the identity
functor when `n = 0`. -/
@[simps!]
def shiftFunctorZero' (n : ℤ) (h : n = 0) :
    shiftFunctor C n ≅ 𝟭 _ 
goal: ((CochainComplex.shiftFunctorZero' C n h).hom.app X).f i = (HomologicalComplex.XIsoOfEq X ⋯).hom

full_name: CochainComplex.shiftFunctorZero'_inv_app_f
code: /-- The shift functor by `n` on `CochainComplex C ℤ` identifies to the identity
functor when `n = 0`. -/
@[simps!]
def shiftFunctorZero' (n : ℤ) (h : n = 0) :
    shiftFunctor C n ≅ 𝟭 _ 
goal: ((CochainComplex.shiftFunctorZero' C n h).inv.app X).f i = (HomologicalComplex.XIsoOfEq X ⋯).inv

full_name: CochainComplex.shiftFunctorZero'
code: /-- The shift functor by `n` on `CochainComplex C ℤ` identifies to the identity
functor when `n = 0`. -/
@[simps!]
def shiftFunctorZero' (n : ℤ) (h : n = 0) :
    shiftFunctor C n ≅ 𝟭 _ 
goal: CochainComplex.shiftFunctor C n ≅ 𝟭 (CochainComplex C ℤ)

full_name: CochainComplex.shiftFunctorAdd'_hom_app_f
code: /-- The compatibility of the shift functors on `CochainComplex C ℤ` with respect
to the addition of integers. -/
@[simps!]
def shiftFunctorAdd' (n₁ n₂ n₁₂ : ℤ) (h : n₁ + n₂ = n₁₂) :
    shiftFunctor C n₁₂ ≅ shiftFunctor C n₁ ⋙ shiftFunctor C n₂ 
goal: ((CochainComplex.shiftFunctorAdd' C n₁ n₂ n₁₂ h).hom.app X).f i = (HomologicalComplex.XIsoOfEq X ⋯).hom

full_name: CochainComplex.shiftFunctorAdd'
code: /-- The compatibility of the shift functors on `CochainComplex C ℤ` with respect
to the addition of integers. -/
@[simps!]
def shiftFunctorAdd' (n₁ n₂ n₁₂ : ℤ) (h : n₁ + n₂ = n₁₂) :
    shiftFunctor C n₁₂ ≅ shiftFunctor C n₁ ⋙ shiftFunctor C n₂ 
goal: CochainComplex.shiftFunctor C n₁₂ ≅ CochainComplex.shiftFunctor C n₁ ⋙ CochainComplex.shiftFunctor C n₂

full_name: CochainComplex.shiftFunctorAdd'_inv_app_f
code: /-- The compatibility of the shift functors on `CochainComplex C ℤ` with respect
to the addition of integers. -/
@[simps!]
def shiftFunctorAdd' (n₁ n₂ n₁₂ : ℤ) (h : n₁ + n₂ = n₁₂) :
    shiftFunctor C n₁₂ ≅ shiftFunctor C n₁ ⋙ shiftFunctor C n₂ 
goal: ((CochainComplex.shiftFunctorAdd' C n₁ n₂ n₁₂ h).inv.app X).f i = (HomologicalComplex.XIsoOfEq X ⋯).inv

full_name: CochainComplex.instHasShiftInt
code: instance : HasShift (CochainComplex C ℤ) ℤ 
goal: CategoryTheory.HasShift (CochainComplex C ℤ) ℤ

full_name: CochainComplex.instAdditiveHomologicalComplexIntUpShiftFunctor
code: instance (n : ℤ) :
    (CategoryTheory.shiftFunctor (HomologicalComplex C (ComplexShape.up ℤ)) n).Additive 
goal: (CategoryTheory.shiftFunctor (HomologicalComplex C (ComplexShape.up ℤ)) n).Additive

full_name: CochainComplex.shiftFunctor_obj_X'
code: @[simp]
lemma shiftFunctor_obj_X' (K : CochainComplex C ℤ) (n p : ℤ) :
    ((CategoryTheory.shiftFunctor (CochainComplex C ℤ) n).obj K).X p = K.X (p + n) 
goal: ((CategoryTheory.shiftFunctor (CochainComplex C ℤ) n).obj K).X p = K.X (p + n)

full_name: CochainComplex.shiftFunctor_map_f'
code: @[simp]
lemma shiftFunctor_map_f' {K L : CochainComplex C ℤ} (φ : K ⟶ L) (n p : ℤ) :
    ((CategoryTheory.shiftFunctor (CochainComplex C ℤ) n).map φ).f p = φ.f (p + n) 
goal: ((CategoryTheory.shiftFunctor (CochainComplex C ℤ) n).map φ).f p = φ.f (p + n)

full_name: CochainComplex.shiftFunctor_obj_d'
code: @[simp]
lemma shiftFunctor_obj_d' (K : CochainComplex C ℤ) (n i j : ℤ) :
    ((CategoryTheory.shiftFunctor (CochainComplex C ℤ) n).obj K).d i j =
      n.negOnePow • K.d _ _ 
goal: ((CategoryTheory.shiftFunctor (CochainComplex C ℤ) n).obj K).d i j =
  n.negOnePow • K.d (i + { as := n }.as) (j + { as := n }.as)

full_name: CochainComplex.shiftFunctorAdd_inv_app_f
code: lemma shiftFunctorAdd_inv_app_f (K : CochainComplex C ℤ) (a b n : ℤ) :
    ((shiftFunctorAdd (CochainComplex C ℤ) a b).inv.app K).f n =
      (K.XIsoOfEq (by dsimp; rw [add_comm a, add_assoc])).hom 
goal: ((CategoryTheory.shiftFunctorAdd (CochainComplex C ℤ) a b).inv.app K).f n = (HomologicalComplex.XIsoOfEq K ⋯).hom

full_name: CochainComplex.shiftFunctorAdd_hom_app_f
code: lemma shiftFunctorAdd_hom_app_f (K : CochainComplex C ℤ) (a b n : ℤ) :
    ((shiftFunctorAdd (CochainComplex C ℤ) a b).hom.app K).f n =
      (K.XIsoOfEq (by dsimp; rw [add_comm a, add_assoc])).hom 
goal: ((CategoryTheory.shiftFunctorAdd (CochainComplex C ℤ) a b).hom.app K).f n = (HomologicalComplex.XIsoOfEq K ⋯).hom

full_name: CochainComplex.shiftFunctorAdd'_inv_app_f'
code: lemma shiftFunctorAdd'_inv_app_f' (K : CochainComplex C ℤ) (a b ab : ℤ) (h : a + b = ab) (n : ℤ) :
    ((CategoryTheory.shiftFunctorAdd' (CochainComplex C ℤ) a b ab h).inv.app K).f n =
      (K.XIsoOfEq (by dsimp; rw [← h, add_assoc, add_comm a])).hom 
goal: ((CategoryTheory.shiftFunctorAdd' (CochainComplex C ℤ) a b ab h).inv.app K).f n = (HomologicalComplex.XIsoOfEq K ⋯).hom

full_name: CochainComplex.shiftFunctorAdd'_hom_app_f'
code: lemma shiftFunctorAdd'_hom_app_f' (K : CochainComplex C ℤ) (a b ab : ℤ) (h : a + b = ab) (n : ℤ) :
    ((CategoryTheory.shiftFunctorAdd' (CochainComplex C ℤ) a b ab h).hom.app K).f n =
      (K.XIsoOfEq (by dsimp; rw [← h, add_assoc, add_comm a])).hom 
goal: ((CategoryTheory.shiftFunctorAdd' (CochainComplex C ℤ) a b ab h).hom.app K).f n = (HomologicalComplex.XIsoOfEq K ⋯).hom

full_name: CochainComplex.shiftFunctorZero_inv_app_f
code: lemma shiftFunctorZero_inv_app_f (K : CochainComplex C ℤ) (n : ℤ) :
    ((CategoryTheory.shiftFunctorZero (CochainComplex C ℤ) ℤ).inv.app K).f n =
      (K.XIsoOfEq (by dsimp; rw [add_zero])).hom 
goal: ((CategoryTheory.shiftFunctorZero (CochainComplex C ℤ) ℤ).inv.app K).f n = (HomologicalComplex.XIsoOfEq K ⋯).hom

full_name: CochainComplex.shiftFunctorZero_hom_app_f
code: lemma shiftFunctorZero_hom_app_f (K : CochainComplex C ℤ) (n : ℤ) :
    ((CategoryTheory.shiftFunctorZero (CochainComplex C ℤ) ℤ).hom.app K).f n =
      (K.XIsoOfEq (by dsimp; rw [add_zero])).hom 
goal: ((CategoryTheory.shiftFunctorZero (CochainComplex C ℤ) ℤ).hom.app K).f n = (HomologicalComplex.XIsoOfEq K ⋯).hom

full_name: CochainComplex.XIsoOfEq_shift
code: lemma XIsoOfEq_shift (K : CochainComplex C ℤ) (n : ℤ) {p q : ℤ} (hpq : p = q) :
    (K⟦n⟧).XIsoOfEq hpq = K.XIsoOfEq (show p + n = q + n by rw [hpq]) 
goal: HomologicalComplex.XIsoOfEq ((CategoryTheory.shiftFunctor (CochainComplex C ℤ) n).obj K) hpq =
  HomologicalComplex.XIsoOfEq K ⋯

full_name: CochainComplex.shiftFunctorAdd'_eq
code: lemma shiftFunctorAdd'_eq (a b c : ℤ) (h : a + b = c) :
    CategoryTheory.shiftFunctorAdd' (CochainComplex C ℤ) a b c h =
      shiftFunctorAdd' C a b c h 
goal: CategoryTheory.shiftFunctorAdd' (CochainComplex C ℤ) a b c h = CochainComplex.shiftFunctorAdd' C a b c h

full_name: CochainComplex.shiftFunctorAdd_eq
code: lemma shiftFunctorAdd_eq (a b : ℤ) :
    CategoryTheory.shiftFunctorAdd (CochainComplex C ℤ) a b = shiftFunctorAdd' C a b _ rfl 
goal: CategoryTheory.shiftFunctorAdd (CochainComplex C ℤ) a b = CochainComplex.shiftFunctorAdd' C a b (a + b) ⋯

full_name: CochainComplex.shiftFunctorZero_eq
code: lemma shiftFunctorZero_eq :
    CategoryTheory.shiftFunctorZero (CochainComplex C ℤ) ℤ = shiftFunctorZero' C 0 rfl 
goal: CategoryTheory.shiftFunctorZero (CochainComplex C ℤ) ℤ = CochainComplex.shiftFunctorZero' C 0 ⋯

full_name: CochainComplex.shiftFunctorComm_hom_app_f
code: lemma shiftFunctorComm_hom_app_f (K : CochainComplex C ℤ) (a b p : ℤ) :
    ((shiftFunctorComm (CochainComplex C ℤ) a b).hom.app K).f p =
      (K.XIsoOfEq (show p + b + a = p + a + b
        by rw [add_assoc, add_comm b, add_assoc])).hom 
goal: ((CategoryTheory.shiftFunctorComm (CochainComplex C ℤ) a b).hom.app K).f p = (HomologicalComplex.XIsoOfEq K ⋯).hom

full_name: CochainComplex.shiftEval_hom_app
code: /-- Shifting cochain complexes by `n` and evaluating in a degree `i` identifies
to the evaluation in degree `i'` when `n + i = i'`. -/
@[simps!]
def shiftEval (n i i' : ℤ) (hi : n + i = i') :
    (CategoryTheory.shiftFunctor (CochainComplex C ℤ) n) ⋙
      HomologicalComplex.eval C (ComplexShape.up ℤ) i ≅
      HomologicalComplex.eval C (ComplexShape.up ℤ) i' 
goal: (CochainComplex.shiftEval C n i i' hi).hom.app X = (HomologicalComplex.XIsoOfEq X ⋯).hom

full_name: CochainComplex.shiftEval_inv_app
code: /-- Shifting cochain complexes by `n` and evaluating in a degree `i` identifies
to the evaluation in degree `i'` when `n + i = i'`. -/
@[simps!]
def shiftEval (n i i' : ℤ) (hi : n + i = i') :
    (CategoryTheory.shiftFunctor (CochainComplex C ℤ) n) ⋙
      HomologicalComplex.eval C (ComplexShape.up ℤ) i ≅
      HomologicalComplex.eval C (ComplexShape.up ℤ) i' 
goal: (CochainComplex.shiftEval C n i i' hi).inv.app X = (HomologicalComplex.XIsoOfEq X ⋯).inv

full_name: CochainComplex.shiftEval
code: /-- Shifting cochain complexes by `n` and evaluating in a degree `i` identifies
to the evaluation in degree `i'` when `n + i = i'`. -/
@[simps!]
def shiftEval (n i i' : ℤ) (hi : n + i = i') :
    (CategoryTheory.shiftFunctor (CochainComplex C ℤ) n) ⋙
      HomologicalComplex.eval C (ComplexShape.up ℤ) i ≅
      HomologicalComplex.eval C (ComplexShape.up ℤ) i' 
goal: CategoryTheory.shiftFunctor (CochainComplex C ℤ) n ⋙ HomologicalComplex.eval C (ComplexShape.up ℤ) i ≅
  HomologicalComplex.eval C (ComplexShape.up ℤ) i'

full_name: CategoryTheory.Functor.mapCochainComplexShiftIso_hom_app_f
code: /-- The commutation with the shift isomorphism for the functor on cochain complexes
induced by an additive functor between preadditive categories. -/
@[simps!]
def mapCochainComplexShiftIso (n : ℤ) :
    shiftFunctor _ n ⋙ F.mapHomologicalComplex (ComplexShape.up ℤ) ≅
      F.mapHomologicalComplex (ComplexShape.up ℤ) ⋙ shiftFunctor _ n 
goal: ((F.mapCochainComplexShiftIso n).hom.app X).f i = 𝟙 (F.obj (X.X (i + n)))

full_name: CategoryTheory.Functor.mapCochainComplexShiftIso_inv_app_f
code: /-- The commutation with the shift isomorphism for the functor on cochain complexes
induced by an additive functor between preadditive categories. -/
@[simps!]
def mapCochainComplexShiftIso (n : ℤ) :
    shiftFunctor _ n ⋙ F.mapHomologicalComplex (ComplexShape.up ℤ) ≅
      F.mapHomologicalComplex (ComplexShape.up ℤ) ⋙ shiftFunctor _ n 
goal: ((F.mapCochainComplexShiftIso n).inv.app X).f i = 𝟙 (F.obj (X.X (i + n)))

full_name: CategoryTheory.Functor.mapCochainComplexShiftIso
code: /-- The commutation with the shift isomorphism for the functor on cochain complexes
induced by an additive functor between preadditive categories. -/
@[simps!]
def mapCochainComplexShiftIso (n : ℤ) :
    shiftFunctor _ n ⋙ F.mapHomologicalComplex (ComplexShape.up ℤ) ≅
      F.mapHomologicalComplex (ComplexShape.up ℤ) ⋙ shiftFunctor _ n 
goal: CategoryTheory.shiftFunctor (HomologicalComplex C (ComplexShape.up ℤ)) n ⋙ F.mapHomologicalComplex (ComplexShape.up ℤ) ≅
  F.mapHomologicalComplex (ComplexShape.up ℤ) ⋙ CategoryTheory.shiftFunctor (HomologicalComplex D (ComplexShape.up ℤ)) n

full_name: CategoryTheory.Functor.commShiftMapCochainComplex
code: instance commShiftMapCochainComplex :
    (F.mapHomologicalComplex (ComplexShape.up ℤ)).CommShift ℤ 
goal: (F.mapHomologicalComplex (ComplexShape.up ℤ)).CommShift ℤ

full_name: CategoryTheory.Functor.mapHomologicalComplex_commShiftIso_eq
code: lemma mapHomologicalComplex_commShiftIso_eq (n : ℤ) :
    (F.mapHomologicalComplex (ComplexShape.up ℤ)).commShiftIso n =
      F.mapCochainComplexShiftIso n 
goal: (F.mapHomologicalComplex (ComplexShape.up ℤ)).commShiftIso n = F.mapCochainComplexShiftIso n

full_name: CategoryTheory.Functor.mapHomologicalComplex_commShiftIso_hom_app_f
code: @[simp]
lemma mapHomologicalComplex_commShiftIso_hom_app_f (K : CochainComplex C ℤ) (n i : ℤ) :
    (((F.mapHomologicalComplex (ComplexShape.up ℤ)).commShiftIso n).hom.app K).f i = 𝟙 _ 
goal: (((F.mapHomologicalComplex (ComplexShape.up ℤ)).commShiftIso n).hom.app K).f i =
  𝟙
    (((CategoryTheory.shiftFunctor (HomologicalComplex C (ComplexShape.up ℤ)) n ⋙
              F.mapHomologicalComplex (ComplexShape.up ℤ)).obj
          K).X
      i)

full_name: CategoryTheory.Functor.mapHomologicalComplex_commShiftIso_inv_app_f
code: @[simp]
lemma mapHomologicalComplex_commShiftIso_inv_app_f (K : CochainComplex C ℤ) (n i : ℤ) :
    (((F.mapHomologicalComplex (ComplexShape.up ℤ)).commShiftIso n).inv.app K).f i = 𝟙 _ 
goal: (((F.mapHomologicalComplex (ComplexShape.up ℤ)).commShiftIso n).inv.app K).f i =
  𝟙
    (((F.mapHomologicalComplex (ComplexShape.up ℤ) ⋙
              CategoryTheory.shiftFunctor (HomologicalComplex D (ComplexShape.up ℤ)) n).obj
          K).X
      i)

full_name: Homotopy.shift
code: /-- If `h : Homotopy φ₁ φ₂` and `n : ℤ`, this is the induced homotopy
between `φ₁⟦n⟧'` and `φ₂⟦n⟧'`. -/
def shift {K L : CochainComplex C ℤ} {φ₁ φ₂ : K ⟶ L} (h : Homotopy φ₁ φ₂) (n : ℤ) :
    Homotopy (φ₁⟦n⟧') (φ₂⟦n⟧') 
goal: Homotopy ((CategoryTheory.shiftFunctor (HomologicalComplex C (ComplexShape.up ℤ)) n).map φ₁)
  ((CategoryTheory.shiftFunctor (HomologicalComplex C (ComplexShape.up ℤ)) n).map φ₂)

full_name: HomotopyCategory.instIsCompatibleWithShiftHomologicalComplexIntUpHomotopic
code: instance : (homotopic C (ComplexShape.up ℤ)).IsCompatibleWithShift ℤ 
goal: (homotopic C (ComplexShape.up ℤ)).IsCompatibleWithShift ℤ

full_name: HomotopyCategory.hasShift
code: noncomputable instance hasShift :
    HasShift (HomotopyCategory C (ComplexShape.up ℤ)) ℤ 
goal: CategoryTheory.HasShift (HomotopyCategory C (ComplexShape.up ℤ)) ℤ

full_name: HomotopyCategory.commShiftQuotient
code: noncomputable instance commShiftQuotient :
    (HomotopyCategory.quotient C (ComplexShape.up ℤ)).CommShift ℤ 
goal: (HomotopyCategory.quotient C (ComplexShape.up ℤ)).CommShift ℤ

full_name: HomotopyCategory.instAdditiveIntUpShiftFunctor
code: instance (n : ℤ) : (shiftFunctor (HomotopyCategory C (ComplexShape.up ℤ)) n).Additive 
goal: (CategoryTheory.shiftFunctor (HomotopyCategory C (ComplexShape.up ℤ)) n).Additive

full_name: HomotopyCategory.instCommShiftIntUpMapHomotopyCategory
code: noncomputable instance : (F.mapHomotopyCategory (ComplexShape.up ℤ)).CommShift ℤ 
goal: (F.mapHomotopyCategory (ComplexShape.up ℤ)).CommShift ℤ

full_name: HomotopyCategory.instCommShiftHomologicalComplexIntUpHomFunctorMapHomotopyCategoryFactors
code: instance : NatTrans.CommShift (F.mapHomotopyCategoryFactors (ComplexShape.up ℤ)).hom ℤ 
goal: CategoryTheory.NatTrans.CommShift (F.mapHomotopyCategoryFactors (ComplexShape.up ℤ)).hom ℤ