Theorem: CategoryTheory.Functor.map_exact
File: Mathlib/CategoryTheory/Abelian/Exact.lean

tactic: let hcoker := isColimitOfHasCokernelOfPreservesColimit L f
state_before: C : Type u₁
inst✝⁷ : Category C
inst✝⁶ : Abelian C
A : Type u₁
B : Type u₂
inst✝⁵ : Category A
inst✝⁴ : Category B
inst✝³ : Abelian A
inst✝² : Abelian B
L : A ⥤ B
inst✝¹ : PreservesFiniteLimits L
inst✝ : PreservesFiniteColimits L
X Y Z : A
f : X ⟶ Y
g : Y ⟶ Z
e1 : Exact f g
⊢ Exact (L.map f) (L.map g)

tactic: let hker := isLimitOfHasKernelOfPreservesLimit L g
state_before: C : Type u₁
inst✝⁷ : Category C
inst✝⁶ : Abelian C
A : Type u₁
B : Type u₂
inst✝⁵ : Category A
inst✝⁴ : Category B
inst✝³ : Abelian A
inst✝² : Abelian B
L : A ⥤ B
inst✝¹ : PreservesFiniteLimits L
inst✝ : PreservesFiniteColimits L
X Y Z : A
f : X ⟶ Y
g : Y ⟶ Z
e1 : Exact f g
hcoker : IsColimit
  (Cofork.ofπ (L.map (cokernel.π f)) (_ : L.map f ≫ L.map (cokernel.π f) = 0 ≫ L.map (cokernel.π f))) :=
  isColimitOfHasCokernelOfPreservesColimit L f
⊢ Exact (L.map f) (L.map g)

tactic: refine' (exact_iff' _ _ hker hcoker).2 ⟨by simp [← L.map_comp, e1.1], _⟩
state_before: C : Type u₁
inst✝⁷ : Category C
inst✝⁶ : Abelian C
A : Type u₁
B : Type u₂
inst✝⁵ : Category A
inst✝⁴ : Category B
inst✝³ : Abelian A
inst✝² : Abelian B
L : A ⥤ B
inst✝¹ : PreservesFiniteLimits L
inst✝ : PreservesFiniteColimits L
X Y Z : A
f : X ⟶ Y
g : Y ⟶ Z
e1 : Exact f g
hcoker : IsColimit
  (Cofork.ofπ (L.map (cokernel.π f)) (_ : L.map f ≫ L.map (cokernel.π f) = 0 ≫ L.map (cokernel.π f))) :=
  isColimitOfHasCokernelOfPreservesColimit L f
hker : IsLimit (Fork.ofι (L.map (kernel.ι g)) (_ : L.map (kernel.ι g) ≫ L.map g = L.map (kernel.ι g) ≫ 0)) :=
  isLimitOfHasKernelOfPreservesLimit L g
⊢ Exact (L.map f) (L.map g)

tactic: simp only [Fork.ι_ofι, Cofork.π_ofπ, ← L.map_comp, kernel_comp_cokernel _ _ e1, L.map_zero]
state_before: C : Type u₁
inst✝⁷ : Category C
inst✝⁶ : Abelian C
A : Type u₁
B : Type u₂
inst✝⁵ : Category A
inst✝⁴ : Category B
inst✝³ : Abelian A
inst✝² : Abelian B
L : A ⥤ B
inst✝¹ : PreservesFiniteLimits L
inst✝ : PreservesFiniteColimits L
X Y Z : A
f : X ⟶ Y
g : Y ⟶ Z
e1 : Exact f g
hcoker : IsColimit
  (Cofork.ofπ (L.map (cokernel.π f)) (_ : L.map f ≫ L.map (cokernel.π f) = 0 ≫ L.map (cokernel.π f))) :=
  isColimitOfHasCokernelOfPreservesColimit L f
hker : IsLimit (Fork.ofι (L.map (kernel.ι g)) (_ : L.map (kernel.ι g) ≫ L.map g = L.map (kernel.ι g) ≫ 0)) :=
  isLimitOfHasKernelOfPreservesLimit L g
⊢ Fork.ι (Fork.ofι (L.map (kernel.ι g)) (_ : L.map (kernel.ι g) ≫ L.map g = L.map (kernel.ι g) ≫ 0)) ≫
      Cofork.π (Cofork.ofπ (L.map (cokernel.π f)) (_ : L.map f ≫ L.map (cokernel.π f) = 0 ≫ L.map (cokernel.π f))) =
    0

tactic: simp [← L.map_comp, e1.1]
state_before: C : Type u₁
inst✝⁷ : Category C
inst✝⁶ : Abelian C
A : Type u₁
B : Type u₂
inst✝⁵ : Category A
inst✝⁴ : Category B
inst✝³ : Abelian A
inst✝² : Abelian B
L : A ⥤ B
inst✝¹ : PreservesFiniteLimits L
inst✝ : PreservesFiniteColimits L
X Y Z : A
f : X ⟶ Y
g : Y ⟶ Z
e1 : Exact f g
hcoker : IsColimit
  (Cofork.ofπ (L.map (cokernel.π f)) (_ : L.map f ≫ L.map (cokernel.π f) = 0 ≫ L.map (cokernel.π f))) :=
  isColimitOfHasCokernelOfPreservesColimit L f
hker : IsLimit (Fork.ofι (L.map (kernel.ι g)) (_ : L.map (kernel.ι g) ≫ L.map g = L.map (kernel.ι g) ≫ 0)) :=
  isLimitOfHasKernelOfPreservesLimit L g
⊢ L.map f ≫ L.map g = 0