Theorem: CategoryTheory.leftDistributor_rightDistributor_assoc
File: Mathlib/CategoryTheory/Monoidal/Preadditive.lean

tactic: ext
state_before: C : Type u_2
inst✝⁵ : Category C
inst✝⁴ : Preadditive C
inst✝³ : MonoidalCategory C
inst✝² : MonoidalPreadditive C
inst✝¹ : HasFiniteBiproducts C
J : Type
inst✝ : Fintype J
X Y : C
f : J → C
⊢ ((leftDistributor X f ⊗ asIso (𝟙 Y)) ≪≫ rightDistributor Y fun j => X ⊗ f j) =
    α_ X (⨁ f) Y ≪≫
      (asIso (𝟙 X) ⊗ rightDistributor Y f) ≪≫
        (leftDistributor X fun j => f j ⊗ Y) ≪≫ biproduct.mapIso fun j => (α_ X (f j) Y).symm

tactic: simp only [Category.comp_id, Category.assoc, eqToHom_refl, Iso.symm_hom, Iso.trans_hom,
  asIso_hom, comp_zero, comp_dite, Preadditive.sum_comp, Preadditive.comp_sum, sum_tensor,
  tensor_sum, comp_tensor_id, tensorIso_hom, leftDistributor_hom, rightDistributor_hom,
  biproduct.mapIso_hom, biproduct.ι_map, biproduct.ι_π, Finset.sum_dite_irrel,
  Finset.sum_dite_eq', Finset.sum_const_zero, Finset.mem_univ, if_true]
state_before: case w.w
C : Type u_2
inst✝⁵ : Category C
inst✝⁴ : Preadditive C
inst✝³ : MonoidalCategory C
inst✝² : MonoidalPreadditive C
inst✝¹ : HasFiniteBiproducts C
J : Type
inst✝ : Fintype J
X Y : C
f : J → C
j✝ : J
⊢ ((leftDistributor X f ⊗ asIso (𝟙 Y)) ≪≫ rightDistributor Y fun j => X ⊗ f j).hom ≫
      biproduct.π (fun j => (X ⊗ f j) ⊗ Y) j✝ =
    (α_ X (⨁ f) Y ≪≫
          (asIso (𝟙 X) ⊗ rightDistributor Y f) ≪≫
            (leftDistributor X fun j => f j ⊗ Y) ≪≫ biproduct.mapIso fun j => (α_ X (f j) Y).symm).hom ≫
      biproduct.π (fun j => (X ⊗ f j) ⊗ Y) j✝

tactic: simp only [← comp_tensor_id, ← id_tensor_comp_assoc, Category.assoc, biproduct.ι_π, comp_dite,
  dite_comp, tensor_dite, dite_tensor]
state_before: case w.w
C : Type u_2
inst✝⁵ : Category C
inst✝⁴ : Preadditive C
inst✝³ : MonoidalCategory C
inst✝² : MonoidalPreadditive C
inst✝¹ : HasFiniteBiproducts C
J : Type
inst✝ : Fintype J
X Y : C
f : J → C
j✝ : J
⊢ ∑ x : J,
      ((𝟙 X ⊗ biproduct.π f x) ⊗ 𝟙 Y) ≫
        (biproduct.ι (fun j => X ⊗ f j) x ⊗ 𝟙 Y) ≫ (biproduct.π (fun j => X ⊗ f j) j✝ ⊗ 𝟙 Y) =
    ∑ x : J,
      (α_ X (⨁ f) Y).hom ≫
        (𝟙 X ⊗ (biproduct.π f x ⊗ 𝟙 Y) ≫ biproduct.ι (fun j => f j ⊗ Y) x) ≫
          (𝟙 X ⊗ biproduct.π (fun j => f j ⊗ Y) j✝) ≫ (α_ X (f j✝) Y).inv

tactic: simp only [Category.comp_id, Category.id_comp, Category.assoc, id_tensor_comp, comp_zero,
  zero_comp, MonoidalPreadditive.tensor_zero, MonoidalPreadditive.zero_tensor, comp_tensor_id,
  eqToHom_refl, tensor_id, if_true, dif_ctx_congr, Finset.sum_congr, Finset.mem_univ,
  Finset.sum_dite_eq']
state_before: case w.w
C : Type u_2
inst✝⁵ : Category C
inst✝⁴ : Preadditive C
inst✝³ : MonoidalCategory C
inst✝² : MonoidalPreadditive C
inst✝¹ : HasFiniteBiproducts C
J : Type
inst✝ : Fintype J
X Y : C
f : J → C
j✝ : J
⊢ (∑ x : J,
      if h : x = j✝ then (𝟙 X ⊗ biproduct.π f x) ≫ eqToHom (_ : X ⊗ f x = X ⊗ f j✝) ⊗ 𝟙 Y
      else (𝟙 X ⊗ biproduct.π f x) ≫ 0 ⊗ 𝟙 Y) =
    ∑ x : J,
      if h : x = j✝ then
        (α_ X (⨁ f) Y).hom ≫ (𝟙 X ⊗ (biproduct.π f x ⊗ 𝟙 Y) ≫ eqToHom (_ : f x ⊗ Y = f j✝ ⊗ Y)) ≫ (α_ X (f j✝) Y).inv
      else (α_ X (⨁ f) Y).hom ≫ (𝟙 X ⊗ (biproduct.π f x ⊗ 𝟙 Y) ≫ 0) ≫ (α_ X (f j✝) Y).inv

tactic: simp only [associator_inv_naturality, Iso.hom_inv_id_assoc]
state_before: case w.w
C : Type u_2
inst✝⁵ : Category C
inst✝⁴ : Preadditive C
inst✝³ : MonoidalCategory C
inst✝² : MonoidalPreadditive C
inst✝¹ : HasFiniteBiproducts C
J : Type
inst✝ : Fintype J
X Y : C
f : J → C
j✝ : J
⊢ (𝟙 X ⊗ biproduct.π f j✝) ⊗ 𝟙 Y = (α_ X (⨁ f) Y).hom ≫ (𝟙 X ⊗ biproduct.π f j✝ ⊗ 𝟙 Y) ≫ (α_ X (f j✝) Y).inv