[GOAL]
C : Type u
𝒞 : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y₁ Y₂ : C
f : Y₁ ⟶ Y₂
⊢ 𝟙 X ⊗ f = X ◁ f
[PROOFSTEP]
simp [tensorHom_def]
[GOAL]
C : Type u
𝒞 : Category.{v, u} C
inst✝ : MonoidalCategory C
X₁ X₂ : C
f : X₁ ⟶ X₂
Y : C
⊢ f ⊗ 𝟙 Y = f ▷ Y
[PROOFSTEP]
simp [tensorHom_def]
[GOAL]
C : Type u
𝒞 : Category.{v, u} C
inst✝ : MonoidalCategory C
W X Y Z : C
f : W ⟶ X
g : Y ⟶ Z
⊢ W ◁ g ≫ f ▷ Z = f ▷ Y ≫ X ◁ g
[PROOFSTEP]
simp [← id_tensorHom, ← tensorHom_id, ← tensor_comp]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
X Y X' Y' : C
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
f : X ≅ Y
g : X' ≅ Y'
⊢ (f.hom ⊗ g.hom) ≫ (f.inv ⊗ g.inv) = 𝟙 (X ⊗ X')
[PROOFSTEP]
rw [← tensor_comp, Iso.hom_inv_id, Iso.hom_inv_id, ← tensor_id]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
X Y X' Y' : C
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
f : X ≅ Y
g : X' ≅ Y'
⊢ (f.inv ⊗ g.inv) ≫ (f.hom ⊗ g.hom) = 𝟙 (Y ⊗ Y')
[PROOFSTEP]
rw [← tensor_comp, Iso.inv_hom_id, Iso.inv_hom_id, ← tensor_id]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝⁴ : MonoidalCategory C✝
C : Type u
inst✝³ : Category.{v, u} C
inst✝² : MonoidalCategory C
W X Y Z : C
f : W ⟶ X
inst✝¹ : IsIso f
g : Y ⟶ Z
inst✝ : IsIso g
⊢ inv (f ⊗ g) = inv f ⊗ inv g
[PROOFSTEP]
aesop_cat_nonterminal
[GOAL]
case hom_inv_id
C_1 : Type u
𝒞 : Category.{v, u} C_1
inst : MonoidalCategory C_1
C : Type u
inst_1 : Category.{v, u} C
inst_2 : MonoidalCategory C
W X Y Z : C
f : W ⟶ X
inst_3 : IsIso f
g : Y ⟶ Z
inst_4 : IsIso g
⊢ (f ⊗ g) ≫ (inv f ⊗ inv g) = 𝟙 (W ⊗ Y)
[PROOFSTEP]
simp [← tensor_comp]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝³ : MonoidalCategory C✝
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : MonoidalCategory C
U V W✝ X✝ Y✝ Z✝ : C
P : Prop
inst✝ : Decidable P
W X Y Z : C
f : W ⟶ X
g : P → (Y ⟶ Z)
g' : ¬P → (Y ⟶ Z)
⊢ (f ⊗ if h : P then g h else g' h) = if h : P then f ⊗ g h else f ⊗ g' h
[PROOFSTEP]
split_ifs
[GOAL]
case pos
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝³ : MonoidalCategory C✝
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : MonoidalCategory C
U V W✝ X✝ Y✝ Z✝ : C
P : Prop
inst✝ : Decidable P
W X Y Z : C
f : W ⟶ X
g : P → (Y ⟶ Z)
g' : ¬P → (Y ⟶ Z)
h✝ : P
⊢ f ⊗ g h✝ = f ⊗ g h✝
[PROOFSTEP]
rfl
[GOAL]
case neg
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝³ : MonoidalCategory C✝
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : MonoidalCategory C
U V W✝ X✝ Y✝ Z✝ : C
P : Prop
inst✝ : Decidable P
W X Y Z : C
f : W ⟶ X
g : P → (Y ⟶ Z)
g' : ¬P → (Y ⟶ Z)
h✝ : ¬P
⊢ f ⊗ g' h✝ = f ⊗ g' h✝
[PROOFSTEP]
rfl
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝³ : MonoidalCategory C✝
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : MonoidalCategory C
U V W✝ X✝ Y✝ Z✝ : C
P : Prop
inst✝ : Decidable P
W X Y Z : C
f : W ⟶ X
g : P → (Y ⟶ Z)
g' : ¬P → (Y ⟶ Z)
⊢ (if h : P then g h else g' h) ⊗ f = if h : P then g h ⊗ f else g' h ⊗ f
[PROOFSTEP]
split_ifs
[GOAL]
case pos
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝³ : MonoidalCategory C✝
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : MonoidalCategory C
U V W✝ X✝ Y✝ Z✝ : C
P : Prop
inst✝ : Decidable P
W X Y Z : C
f : W ⟶ X
g : P → (Y ⟶ Z)
g' : ¬P → (Y ⟶ Z)
h✝ : P
⊢ g h✝ ⊗ f = g h✝ ⊗ f
[PROOFSTEP]
rfl
[GOAL]
case neg
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝³ : MonoidalCategory C✝
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : MonoidalCategory C
U V W✝ X✝ Y✝ Z✝ : C
P : Prop
inst✝ : Decidable P
W X Y Z : C
f : W ⟶ X
g : P → (Y ⟶ Z)
g' : ¬P → (Y ⟶ Z)
h✝ : ¬P
⊢ g' h✝ ⊗ f = g' h✝ ⊗ f
[PROOFSTEP]
rfl
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
f : W ⟶ X
g : X ⟶ Y
⊢ f ≫ g ⊗ 𝟙 Z = (f ⊗ 𝟙 Z) ≫ (g ⊗ 𝟙 Z)
[PROOFSTEP]
rw [← tensor_comp]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
f : W ⟶ X
g : X ⟶ Y
⊢ f ≫ g ⊗ 𝟙 Z = f ≫ g ⊗ 𝟙 Z ≫ 𝟙 Z
[PROOFSTEP]
simp
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
f : W ⟶ X
g : X ⟶ Y
⊢ 𝟙 Z ⊗ f ≫ g = (𝟙 Z ⊗ f) ≫ (𝟙 Z ⊗ g)
[PROOFSTEP]
rw [← tensor_comp]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
f : W ⟶ X
g : X ⟶ Y
⊢ 𝟙 Z ⊗ f ≫ g = 𝟙 Z ≫ 𝟙 Z ⊗ f ≫ g
[PROOFSTEP]
simp
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
f : W ⟶ X
g : Y ⟶ Z
⊢ (𝟙 Y ⊗ f) ≫ (g ⊗ 𝟙 X) = g ⊗ f
[PROOFSTEP]
rw [← tensor_comp]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
f : W ⟶ X
g : Y ⟶ Z
⊢ 𝟙 Y ≫ g ⊗ f ≫ 𝟙 X = g ⊗ f
[PROOFSTEP]
simp
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
f : W ⟶ X
g : Y ⟶ Z
⊢ (g ⊗ 𝟙 W) ≫ (𝟙 Z ⊗ f) = g ⊗ f
[PROOFSTEP]
rw [← tensor_comp]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
f : W ⟶ X
g : Y ⟶ Z
⊢ g ≫ 𝟙 Z ⊗ 𝟙 W ≫ f = g ⊗ f
[PROOFSTEP]
simp
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z X Y : C
f : X ⟶ Y
⊢ f ⊗ 𝟙 (𝟙_ C) = (ρ_ X).hom ≫ f ≫ (ρ_ Y).inv
[PROOFSTEP]
rw [← rightUnitor_naturality_assoc, Iso.hom_inv_id, Category.comp_id]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z X Y : C
f : X ⟶ Y
⊢ 𝟙 (𝟙_ C) ⊗ f = (λ_ X).hom ≫ f ≫ (λ_ Y).inv
[PROOFSTEP]
rw [← leftUnitor_naturality_assoc, Iso.hom_inv_id, Category.comp_id]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y Z X X' : C
f : X ⟶ X'
⊢ f ≫ (λ_ X').inv = (λ_ X).inv ≫ (𝟙 tensorUnit' ⊗ f)
[PROOFSTEP]
simp
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y Z X X' : C
f : X ⟶ X'
⊢ f ≫ (ρ_ X').inv = (ρ_ X).inv ≫ (f ⊗ 𝟙 tensorUnit')
[PROOFSTEP]
simp
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z X Y : C
f g : X ⟶ Y
⊢ 𝟙 (𝟙_ C) ⊗ f = 𝟙 (𝟙_ C) ⊗ g ↔ f = g
[PROOFSTEP]
simp
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z X Y : C
f g : X ⟶ Y
⊢ f ⊗ 𝟙 (𝟙_ C) = g ⊗ 𝟙 (𝟙_ C) ↔ f = g
[PROOFSTEP]
simp
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W✝ X✝ Y✝ Z✝ W X Y Z : C
⊢ inv ((𝟙 W ⊗ (α_ X Y Z).inv) ≫ (α_ W (X ⊗ Y) Z).inv ≫ ((α_ W X Y).inv ⊗ 𝟙 Z)) =
    inv ((α_ W X (Y ⊗ Z)).inv ≫ (α_ (W ⊗ X) Y Z).inv)
[PROOFSTEP]
simp [pentagon]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z X Y : C
⊢ (ρ_ (X ⊗ Y)).hom = (α_ X Y (𝟙_ C)).hom ≫ (𝟙 X ⊗ (ρ_ Y).hom)
[PROOFSTEP]
rw [← tensor_right_iff, comp_tensor_id, ← cancel_mono (α_ X Y (𝟙_ C)).hom, assoc, associator_naturality, ←
  triangle_assoc, ← triangle, id_tensor_comp, pentagon_assoc, ← associator_naturality, tensor_id]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z X Y : C
⊢ inv (ρ_ (X ⊗ Y)).inv = inv ((𝟙 X ⊗ (ρ_ Y).inv) ≫ (α_ X Y (𝟙_ C)).inv)
[PROOFSTEP]
simp
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z X Y : C
⊢ (α_ X (𝟙_ C) Y).inv ≫ ((ρ_ X).hom ⊗ 𝟙 Y) = 𝟙 X ⊗ (λ_ Y).hom
[PROOFSTEP]
rw [← triangle, Iso.inv_hom_id_assoc]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z X Y : C
⊢ (𝟙 X ⊗ (λ_ Y).inv) ≫ (α_ X (𝟙_ C) Y).inv = (ρ_ X).inv ⊗ 𝟙 Y
[PROOFSTEP]
apply (cancel_mono ((ρ_ X).hom ⊗ 𝟙 Y)).1
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z X Y : C
⊢ ((𝟙 X ⊗ (λ_ Y).inv) ≫ (α_ X (𝟙_ C) Y).inv) ≫ ((ρ_ X).hom ⊗ 𝟙 Y) = ((ρ_ X).inv ⊗ 𝟙 Y) ≫ ((ρ_ X).hom ⊗ 𝟙 Y)
[PROOFSTEP]
simp only [triangle_assoc_comp_right, assoc]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z X Y : C
⊢ (𝟙 X ⊗ (λ_ Y).inv) ≫ (𝟙 X ⊗ (λ_ Y).hom) = ((ρ_ X).inv ⊗ 𝟙 Y) ≫ ((ρ_ X).hom ⊗ 𝟙 Y)
[PROOFSTEP]
rw [← id_tensor_comp, Iso.inv_hom_id, ← comp_tensor_id, Iso.inv_hom_id]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z✝ X Y Z X' Y' Z' : C
f : X ⟶ X'
g : Y ⟶ Y'
h : Z ⟶ Z'
⊢ (f ⊗ g ⊗ h) ≫ (α_ X' Y' Z').inv = (α_ X Y Z).inv ≫ ((f ⊗ g) ⊗ h)
[PROOFSTEP]
rw [comp_inv_eq, assoc, associator_naturality]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z✝ X Y Z X' Y' Z' : C
f : X ⟶ X'
g : Y ⟶ Y'
h : Z ⟶ Z'
⊢ f ⊗ g ⊗ h = (α_ X Y Z).inv ≫ (α_ X Y Z).hom ≫ (f ⊗ g ⊗ h)
[PROOFSTEP]
simp
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z✝ X X' Y Y' Z Z' : C
f : X ⟶ X'
g : Y ⟶ Y'
h : Z ⟶ Z'
⊢ (f ⊗ g) ⊗ h = (α_ X Y Z).hom ≫ (f ⊗ g ⊗ h) ≫ (α_ X' Y' Z').inv
[PROOFSTEP]
rw [associator_inv_naturality, hom_inv_id_assoc]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z✝ X X' Y Y' Z Z' : C
f : X ⟶ X'
g : Y ⟶ Y'
h : Z ⟶ Z'
⊢ f ⊗ g ⊗ h = (α_ X Y Z).inv ≫ ((f ⊗ g) ⊗ h) ≫ (α_ X' Y' Z').hom
[PROOFSTEP]
rw [associator_naturality, inv_hom_id_assoc]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z✝ X Y Z Z' : C
h : Z ⟶ Z'
⊢ (𝟙 (X ⊗ Y) ⊗ h) ≫ (α_ X Y Z').hom = (α_ X Y Z).hom ≫ (𝟙 X ⊗ 𝟙 Y ⊗ h)
[PROOFSTEP]
rw [← tensor_id, associator_naturality]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X✝ Y✝ Z✝ X Y Z X' : C
f : X ⟶ X'
⊢ (f ⊗ 𝟙 (Y ⊗ Z)) ≫ (α_ X' Y Z).inv = (α_ X Y Z).inv ≫ ((f ⊗ 𝟙 Y) ⊗ 𝟙 Z)
[PROOFSTEP]
rw [← tensor_id, associator_inv_naturality]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ≅ W
g : X ⟶ Y
h : Y ⟶ Z
⊢ (f.hom ⊗ g) ≫ (f.inv ⊗ h) = (𝟙 V ⊗ g) ≫ (𝟙 V ⊗ h)
[PROOFSTEP]
rw [← tensor_comp, f.hom_inv_id, id_tensor_comp]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ≅ W
g : X ⟶ Y
h : Y ⟶ Z
⊢ (f.inv ⊗ g) ≫ (f.hom ⊗ h) = (𝟙 W ⊗ g) ≫ (𝟙 W ⊗ h)
[PROOFSTEP]
rw [← tensor_comp, f.inv_hom_id, id_tensor_comp]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ≅ W
g : X ⟶ Y
h : Y ⟶ Z
⊢ (g ⊗ f.hom) ≫ (h ⊗ f.inv) = (g ⊗ 𝟙 V) ≫ (h ⊗ 𝟙 V)
[PROOFSTEP]
rw [← tensor_comp, f.hom_inv_id, comp_tensor_id]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ≅ W
g : X ⟶ Y
h : Y ⟶ Z
⊢ (g ⊗ f.inv) ≫ (h ⊗ f.hom) = (g ⊗ 𝟙 W) ≫ (h ⊗ 𝟙 W)
[PROOFSTEP]
rw [← tensor_comp, f.inv_hom_id, comp_tensor_id]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝³ : MonoidalCategory C✝
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ⟶ W
inst✝ : IsIso f
g : X ⟶ Y
h : Y ⟶ Z
⊢ (f ⊗ g) ≫ (inv f ⊗ h) = (𝟙 V ⊗ g) ≫ (𝟙 V ⊗ h)
[PROOFSTEP]
rw [← tensor_comp, IsIso.hom_inv_id, id_tensor_comp]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝³ : MonoidalCategory C✝
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ⟶ W
inst✝ : IsIso f
g : X ⟶ Y
h : Y ⟶ Z
⊢ (inv f ⊗ g) ≫ (f ⊗ h) = (𝟙 W ⊗ g) ≫ (𝟙 W ⊗ h)
[PROOFSTEP]
rw [← tensor_comp, IsIso.inv_hom_id, id_tensor_comp]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝³ : MonoidalCategory C✝
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ⟶ W
inst✝ : IsIso f
g : X ⟶ Y
h : Y ⟶ Z
⊢ (g ⊗ f) ≫ (h ⊗ inv f) = (g ⊗ 𝟙 V) ≫ (h ⊗ 𝟙 V)
[PROOFSTEP]
rw [← tensor_comp, IsIso.hom_inv_id, comp_tensor_id]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝³ : MonoidalCategory C✝
C : Type u
inst✝² : Category.{v, u} C
inst✝¹ : MonoidalCategory C
U V✝ W✝ X✝ Y✝ Z✝ V W X Y Z : C
f : V ⟶ W
inst✝ : IsIso f
g : X ⟶ Y
h : Y ⟶ Z
⊢ (g ⊗ inv f) ≫ (h ⊗ f) = (g ⊗ 𝟙 W) ≫ (h ⊗ 𝟙 W)
[PROOFSTEP]
rw [← tensor_comp, IsIso.inv_hom_id, comp_tensor_id]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
tensorObj : C → C → C
tensorHom : {X₁ Y₁ X₂ Y₂ : C} → (X₁ ⟶ Y₁) → (X₂ ⟶ Y₂) → (tensorObj X₁ X₂ ⟶ tensorObj Y₁ Y₂)
whiskerLeft :
  optParam ((X : C) → {Y₁ Y₂ : C} → (Y₁ ⟶ Y₂) → (tensorObj X Y₁ ⟶ tensorObj X Y₂)) fun X x x_1 f => tensorHom (𝟙 X) f
whiskerRight :
  optParam ({X₁ X₂ : C} → (X₁ ⟶ X₂) → (Y : C) → tensorObj X₁ Y ⟶ tensorObj X₂ Y) fun {X₁ X₂} f Y => tensorHom f (𝟙 Y)
tensor_id : autoParam (∀ (X₁ X₂ : C), tensorHom (𝟙 X₁) (𝟙 X₂) = 𝟙 (tensorObj X₁ X₂)) _auto✝
id_tensorHom : autoParam (∀ (X : C) {Y₁ Y₂ : C} (f : Y₁ ⟶ Y₂), tensorHom (𝟙 X) f = whiskerLeft X f) _auto✝
tensorHom_id : autoParam (∀ {X₁ X₂ : C} (f : X₁ ⟶ X₂) (Y : C), tensorHom f (𝟙 Y) = whiskerRight f Y) _auto✝
tensor_comp :
  autoParam
    (∀ {X₁ Y₁ Z₁ X₂ Y₂ Z₂ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (g₁ : Y₁ ⟶ Z₁) (g₂ : Y₂ ⟶ Z₂),
      tensorHom (f₁ ≫ g₁) (f₂ ≫ g₂) = tensorHom f₁ f₂ ≫ tensorHom g₁ g₂)
    _auto✝
tensorUnit' : C
associator : (X Y Z : C) → tensorObj (tensorObj X Y) Z ≅ tensorObj X (tensorObj Y Z)
associator_naturality :
  autoParam
    (∀ {X₁ X₂ X₃ Y₁ Y₂ Y₃ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (f₃ : X₃ ⟶ Y₃),
      tensorHom (tensorHom f₁ f₂) f₃ ≫ (associator Y₁ Y₂ Y₃).hom =
        (associator X₁ X₂ X₃).hom ≫ tensorHom f₁ (tensorHom f₂ f₃))
    _auto✝
leftUnitor : (X : C) → tensorObj tensorUnit' X ≅ X
leftUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom (𝟙 tensorUnit') f ≫ (leftUnitor Y).hom = (leftUnitor X).hom ≫ f) _auto✝
rightUnitor : (X : C) → tensorObj X tensorUnit' ≅ X
rightUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom f (𝟙 tensorUnit') ≫ (rightUnitor Y).hom = (rightUnitor X).hom ≫ f)
    _auto✝
pentagon :
  autoParam
    (∀ (W X Y Z : C),
      tensorHom (associator W X Y).hom (𝟙 Z) ≫
          (associator W (tensorObj X Y) Z).hom ≫ tensorHom (𝟙 W) (associator X Y Z).hom =
        (associator (tensorObj W X) Y Z).hom ≫ (associator W X (tensorObj Y Z)).hom)
    _auto✝
triangle :
  autoParam
    (∀ (X Y : C),
      (associator X tensorUnit' Y).hom ≫ tensorHom (𝟙 X) (leftUnitor Y).hom = tensorHom (rightUnitor X).hom (𝟙 Y))
    _auto✝
⊢ ∀ {X₁ Y₁ X₂ Y₂ : C} (f : X₁ ⟶ Y₁) (g : X₂ ⟶ Y₂),
    (fun {X₁ Y₁ X₂ Y₂} => tensorHom) f g =
      (fun {X₁ X₂} f X => whiskerRight f X) f X₂ ≫ (fun X x x_1 f => whiskerLeft X f) Y₁ X₂ Y₂ g
[PROOFSTEP]
intros
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
tensorObj : C → C → C
tensorHom : {X₁ Y₁ X₂ Y₂ : C} → (X₁ ⟶ Y₁) → (X₂ ⟶ Y₂) → (tensorObj X₁ X₂ ⟶ tensorObj Y₁ Y₂)
whiskerLeft :
  optParam ((X : C) → {Y₁ Y₂ : C} → (Y₁ ⟶ Y₂) → (tensorObj X Y₁ ⟶ tensorObj X Y₂)) fun X x x_1 f => tensorHom (𝟙 X) f
whiskerRight :
  optParam ({X₁ X₂ : C} → (X₁ ⟶ X₂) → (Y : C) → tensorObj X₁ Y ⟶ tensorObj X₂ Y) fun {X₁ X₂} f Y => tensorHom f (𝟙 Y)
tensor_id : autoParam (∀ (X₁ X₂ : C), tensorHom (𝟙 X₁) (𝟙 X₂) = 𝟙 (tensorObj X₁ X₂)) _auto✝
id_tensorHom : autoParam (∀ (X : C) {Y₁ Y₂ : C} (f : Y₁ ⟶ Y₂), tensorHom (𝟙 X) f = whiskerLeft X f) _auto✝
tensorHom_id : autoParam (∀ {X₁ X₂ : C} (f : X₁ ⟶ X₂) (Y : C), tensorHom f (𝟙 Y) = whiskerRight f Y) _auto✝
tensor_comp :
  autoParam
    (∀ {X₁ Y₁ Z₁ X₂ Y₂ Z₂ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (g₁ : Y₁ ⟶ Z₁) (g₂ : Y₂ ⟶ Z₂),
      tensorHom (f₁ ≫ g₁) (f₂ ≫ g₂) = tensorHom f₁ f₂ ≫ tensorHom g₁ g₂)
    _auto✝
tensorUnit' : C
associator : (X Y Z : C) → tensorObj (tensorObj X Y) Z ≅ tensorObj X (tensorObj Y Z)
associator_naturality :
  autoParam
    (∀ {X₁ X₂ X₃ Y₁ Y₂ Y₃ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (f₃ : X₃ ⟶ Y₃),
      tensorHom (tensorHom f₁ f₂) f₃ ≫ (associator Y₁ Y₂ Y₃).hom =
        (associator X₁ X₂ X₃).hom ≫ tensorHom f₁ (tensorHom f₂ f₃))
    _auto✝
leftUnitor : (X : C) → tensorObj tensorUnit' X ≅ X
leftUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom (𝟙 tensorUnit') f ≫ (leftUnitor Y).hom = (leftUnitor X).hom ≫ f) _auto✝
rightUnitor : (X : C) → tensorObj X tensorUnit' ≅ X
rightUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom f (𝟙 tensorUnit') ≫ (rightUnitor Y).hom = (rightUnitor X).hom ≫ f)
    _auto✝
pentagon :
  autoParam
    (∀ (W X Y Z : C),
      tensorHom (associator W X Y).hom (𝟙 Z) ≫
          (associator W (tensorObj X Y) Z).hom ≫ tensorHom (𝟙 W) (associator X Y Z).hom =
        (associator (tensorObj W X) Y Z).hom ≫ (associator W X (tensorObj Y Z)).hom)
    _auto✝
triangle :
  autoParam
    (∀ (X Y : C),
      (associator X tensorUnit' Y).hom ≫ tensorHom (𝟙 X) (leftUnitor Y).hom = tensorHom (rightUnitor X).hom (𝟙 Y))
    _auto✝
X₁✝ Y₁✝ X₂✝ Y₂✝ : C
f✝ : X₁✝ ⟶ Y₁✝
g✝ : X₂✝ ⟶ Y₂✝
⊢ (fun {X₁ Y₁ X₂ Y₂} => tensorHom) f✝ g✝ =
    (fun {X₁ X₂} f X => whiskerRight f X) f✝ X₂✝ ≫ (fun X x x_1 f => whiskerLeft X f) Y₁✝ X₂✝ Y₂✝ g✝
[PROOFSTEP]
simp [← id_tensorHom, ← tensorHom_id, ← tensor_comp]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
tensorObj : C → C → C
tensorHom : {X₁ Y₁ X₂ Y₂ : C} → (X₁ ⟶ Y₁) → (X₂ ⟶ Y₂) → (tensorObj X₁ X₂ ⟶ tensorObj Y₁ Y₂)
whiskerLeft :
  optParam ((X : C) → {Y₁ Y₂ : C} → (Y₁ ⟶ Y₂) → (tensorObj X Y₁ ⟶ tensorObj X Y₂)) fun X x x_1 f => tensorHom (𝟙 X) f
whiskerRight :
  optParam ({X₁ X₂ : C} → (X₁ ⟶ X₂) → (Y : C) → tensorObj X₁ Y ⟶ tensorObj X₂ Y) fun {X₁ X₂} f Y => tensorHom f (𝟙 Y)
tensor_id : autoParam (∀ (X₁ X₂ : C), tensorHom (𝟙 X₁) (𝟙 X₂) = 𝟙 (tensorObj X₁ X₂)) _auto✝
id_tensorHom : autoParam (∀ (X : C) {Y₁ Y₂ : C} (f : Y₁ ⟶ Y₂), tensorHom (𝟙 X) f = whiskerLeft X f) _auto✝
tensorHom_id : autoParam (∀ {X₁ X₂ : C} (f : X₁ ⟶ X₂) (Y : C), tensorHom f (𝟙 Y) = whiskerRight f Y) _auto✝
tensor_comp :
  autoParam
    (∀ {X₁ Y₁ Z₁ X₂ Y₂ Z₂ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (g₁ : Y₁ ⟶ Z₁) (g₂ : Y₂ ⟶ Z₂),
      tensorHom (f₁ ≫ g₁) (f₂ ≫ g₂) = tensorHom f₁ f₂ ≫ tensorHom g₁ g₂)
    _auto✝
tensorUnit' : C
associator : (X Y Z : C) → tensorObj (tensorObj X Y) Z ≅ tensorObj X (tensorObj Y Z)
associator_naturality :
  autoParam
    (∀ {X₁ X₂ X₃ Y₁ Y₂ Y₃ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (f₃ : X₃ ⟶ Y₃),
      tensorHom (tensorHom f₁ f₂) f₃ ≫ (associator Y₁ Y₂ Y₃).hom =
        (associator X₁ X₂ X₃).hom ≫ tensorHom f₁ (tensorHom f₂ f₃))
    _auto✝
leftUnitor : (X : C) → tensorObj tensorUnit' X ≅ X
leftUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom (𝟙 tensorUnit') f ≫ (leftUnitor Y).hom = (leftUnitor X).hom ≫ f) _auto✝
rightUnitor : (X : C) → tensorObj X tensorUnit' ≅ X
rightUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom f (𝟙 tensorUnit') ≫ (rightUnitor Y).hom = (rightUnitor X).hom ≫ f)
    _auto✝
pentagon :
  autoParam
    (∀ (W X Y Z : C),
      tensorHom (associator W X Y).hom (𝟙 Z) ≫
          (associator W (tensorObj X Y) Z).hom ≫ tensorHom (𝟙 W) (associator X Y Z).hom =
        (associator (tensorObj W X) Y Z).hom ≫ (associator W X (tensorObj Y Z)).hom)
    _auto✝
triangle :
  autoParam
    (∀ (X Y : C),
      (associator X tensorUnit' Y).hom ≫ tensorHom (𝟙 X) (leftUnitor Y).hom = tensorHom (rightUnitor X).hom (𝟙 Y))
    _auto✝
⊢ ∀ (X Y : C), (fun X x x_1 f => whiskerLeft X f) X Y Y (𝟙 Y) = 𝟙 (tensorObj X Y)
[PROOFSTEP]
intros
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
tensorObj : C → C → C
tensorHom : {X₁ Y₁ X₂ Y₂ : C} → (X₁ ⟶ Y₁) → (X₂ ⟶ Y₂) → (tensorObj X₁ X₂ ⟶ tensorObj Y₁ Y₂)
whiskerLeft :
  optParam ((X : C) → {Y₁ Y₂ : C} → (Y₁ ⟶ Y₂) → (tensorObj X Y₁ ⟶ tensorObj X Y₂)) fun X x x_1 f => tensorHom (𝟙 X) f
whiskerRight :
  optParam ({X₁ X₂ : C} → (X₁ ⟶ X₂) → (Y : C) → tensorObj X₁ Y ⟶ tensorObj X₂ Y) fun {X₁ X₂} f Y => tensorHom f (𝟙 Y)
tensor_id : autoParam (∀ (X₁ X₂ : C), tensorHom (𝟙 X₁) (𝟙 X₂) = 𝟙 (tensorObj X₁ X₂)) _auto✝
id_tensorHom : autoParam (∀ (X : C) {Y₁ Y₂ : C} (f : Y₁ ⟶ Y₂), tensorHom (𝟙 X) f = whiskerLeft X f) _auto✝
tensorHom_id : autoParam (∀ {X₁ X₂ : C} (f : X₁ ⟶ X₂) (Y : C), tensorHom f (𝟙 Y) = whiskerRight f Y) _auto✝
tensor_comp :
  autoParam
    (∀ {X₁ Y₁ Z₁ X₂ Y₂ Z₂ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (g₁ : Y₁ ⟶ Z₁) (g₂ : Y₂ ⟶ Z₂),
      tensorHom (f₁ ≫ g₁) (f₂ ≫ g₂) = tensorHom f₁ f₂ ≫ tensorHom g₁ g₂)
    _auto✝
tensorUnit' : C
associator : (X Y Z : C) → tensorObj (tensorObj X Y) Z ≅ tensorObj X (tensorObj Y Z)
associator_naturality :
  autoParam
    (∀ {X₁ X₂ X₃ Y₁ Y₂ Y₃ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (f₃ : X₃ ⟶ Y₃),
      tensorHom (tensorHom f₁ f₂) f₃ ≫ (associator Y₁ Y₂ Y₃).hom =
        (associator X₁ X₂ X₃).hom ≫ tensorHom f₁ (tensorHom f₂ f₃))
    _auto✝
leftUnitor : (X : C) → tensorObj tensorUnit' X ≅ X
leftUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom (𝟙 tensorUnit') f ≫ (leftUnitor Y).hom = (leftUnitor X).hom ≫ f) _auto✝
rightUnitor : (X : C) → tensorObj X tensorUnit' ≅ X
rightUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom f (𝟙 tensorUnit') ≫ (rightUnitor Y).hom = (rightUnitor X).hom ≫ f)
    _auto✝
pentagon :
  autoParam
    (∀ (W X Y Z : C),
      tensorHom (associator W X Y).hom (𝟙 Z) ≫
          (associator W (tensorObj X Y) Z).hom ≫ tensorHom (𝟙 W) (associator X Y Z).hom =
        (associator (tensorObj W X) Y Z).hom ≫ (associator W X (tensorObj Y Z)).hom)
    _auto✝
triangle :
  autoParam
    (∀ (X Y : C),
      (associator X tensorUnit' Y).hom ≫ tensorHom (𝟙 X) (leftUnitor Y).hom = tensorHom (rightUnitor X).hom (𝟙 Y))
    _auto✝
X✝ Y✝ : C
⊢ (fun X x x_1 f => whiskerLeft X f) X✝ Y✝ Y✝ (𝟙 Y✝) = 𝟙 (tensorObj X✝ Y✝)
[PROOFSTEP]
simp [← id_tensorHom, ← tensor_id]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
tensorObj : C → C → C
tensorHom : {X₁ Y₁ X₂ Y₂ : C} → (X₁ ⟶ Y₁) → (X₂ ⟶ Y₂) → (tensorObj X₁ X₂ ⟶ tensorObj Y₁ Y₂)
whiskerLeft :
  optParam ((X : C) → {Y₁ Y₂ : C} → (Y₁ ⟶ Y₂) → (tensorObj X Y₁ ⟶ tensorObj X Y₂)) fun X x x_1 f => tensorHom (𝟙 X) f
whiskerRight :
  optParam ({X₁ X₂ : C} → (X₁ ⟶ X₂) → (Y : C) → tensorObj X₁ Y ⟶ tensorObj X₂ Y) fun {X₁ X₂} f Y => tensorHom f (𝟙 Y)
tensor_id : autoParam (∀ (X₁ X₂ : C), tensorHom (𝟙 X₁) (𝟙 X₂) = 𝟙 (tensorObj X₁ X₂)) _auto✝
id_tensorHom : autoParam (∀ (X : C) {Y₁ Y₂ : C} (f : Y₁ ⟶ Y₂), tensorHom (𝟙 X) f = whiskerLeft X f) _auto✝
tensorHom_id : autoParam (∀ {X₁ X₂ : C} (f : X₁ ⟶ X₂) (Y : C), tensorHom f (𝟙 Y) = whiskerRight f Y) _auto✝
tensor_comp :
  autoParam
    (∀ {X₁ Y₁ Z₁ X₂ Y₂ Z₂ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (g₁ : Y₁ ⟶ Z₁) (g₂ : Y₂ ⟶ Z₂),
      tensorHom (f₁ ≫ g₁) (f₂ ≫ g₂) = tensorHom f₁ f₂ ≫ tensorHom g₁ g₂)
    _auto✝
tensorUnit' : C
associator : (X Y Z : C) → tensorObj (tensorObj X Y) Z ≅ tensorObj X (tensorObj Y Z)
associator_naturality :
  autoParam
    (∀ {X₁ X₂ X₃ Y₁ Y₂ Y₃ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (f₃ : X₃ ⟶ Y₃),
      tensorHom (tensorHom f₁ f₂) f₃ ≫ (associator Y₁ Y₂ Y₃).hom =
        (associator X₁ X₂ X₃).hom ≫ tensorHom f₁ (tensorHom f₂ f₃))
    _auto✝
leftUnitor : (X : C) → tensorObj tensorUnit' X ≅ X
leftUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom (𝟙 tensorUnit') f ≫ (leftUnitor Y).hom = (leftUnitor X).hom ≫ f) _auto✝
rightUnitor : (X : C) → tensorObj X tensorUnit' ≅ X
rightUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom f (𝟙 tensorUnit') ≫ (rightUnitor Y).hom = (rightUnitor X).hom ≫ f)
    _auto✝
pentagon :
  autoParam
    (∀ (W X Y Z : C),
      tensorHom (associator W X Y).hom (𝟙 Z) ≫
          (associator W (tensorObj X Y) Z).hom ≫ tensorHom (𝟙 W) (associator X Y Z).hom =
        (associator (tensorObj W X) Y Z).hom ≫ (associator W X (tensorObj Y Z)).hom)
    _auto✝
triangle :
  autoParam
    (∀ (X Y : C),
      (associator X tensorUnit' Y).hom ≫ tensorHom (𝟙 X) (leftUnitor Y).hom = tensorHom (rightUnitor X).hom (𝟙 Y))
    _auto✝
⊢ ∀ (X Y : C), (fun {X₁ X₂} f X => whiskerRight f X) (𝟙 X) Y = 𝟙 (tensorObj X Y)
[PROOFSTEP]
intros
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
tensorObj : C → C → C
tensorHom : {X₁ Y₁ X₂ Y₂ : C} → (X₁ ⟶ Y₁) → (X₂ ⟶ Y₂) → (tensorObj X₁ X₂ ⟶ tensorObj Y₁ Y₂)
whiskerLeft :
  optParam ((X : C) → {Y₁ Y₂ : C} → (Y₁ ⟶ Y₂) → (tensorObj X Y₁ ⟶ tensorObj X Y₂)) fun X x x_1 f => tensorHom (𝟙 X) f
whiskerRight :
  optParam ({X₁ X₂ : C} → (X₁ ⟶ X₂) → (Y : C) → tensorObj X₁ Y ⟶ tensorObj X₂ Y) fun {X₁ X₂} f Y => tensorHom f (𝟙 Y)
tensor_id : autoParam (∀ (X₁ X₂ : C), tensorHom (𝟙 X₁) (𝟙 X₂) = 𝟙 (tensorObj X₁ X₂)) _auto✝
id_tensorHom : autoParam (∀ (X : C) {Y₁ Y₂ : C} (f : Y₁ ⟶ Y₂), tensorHom (𝟙 X) f = whiskerLeft X f) _auto✝
tensorHom_id : autoParam (∀ {X₁ X₂ : C} (f : X₁ ⟶ X₂) (Y : C), tensorHom f (𝟙 Y) = whiskerRight f Y) _auto✝
tensor_comp :
  autoParam
    (∀ {X₁ Y₁ Z₁ X₂ Y₂ Z₂ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (g₁ : Y₁ ⟶ Z₁) (g₂ : Y₂ ⟶ Z₂),
      tensorHom (f₁ ≫ g₁) (f₂ ≫ g₂) = tensorHom f₁ f₂ ≫ tensorHom g₁ g₂)
    _auto✝
tensorUnit' : C
associator : (X Y Z : C) → tensorObj (tensorObj X Y) Z ≅ tensorObj X (tensorObj Y Z)
associator_naturality :
  autoParam
    (∀ {X₁ X₂ X₃ Y₁ Y₂ Y₃ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (f₃ : X₃ ⟶ Y₃),
      tensorHom (tensorHom f₁ f₂) f₃ ≫ (associator Y₁ Y₂ Y₃).hom =
        (associator X₁ X₂ X₃).hom ≫ tensorHom f₁ (tensorHom f₂ f₃))
    _auto✝
leftUnitor : (X : C) → tensorObj tensorUnit' X ≅ X
leftUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom (𝟙 tensorUnit') f ≫ (leftUnitor Y).hom = (leftUnitor X).hom ≫ f) _auto✝
rightUnitor : (X : C) → tensorObj X tensorUnit' ≅ X
rightUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom f (𝟙 tensorUnit') ≫ (rightUnitor Y).hom = (rightUnitor X).hom ≫ f)
    _auto✝
pentagon :
  autoParam
    (∀ (W X Y Z : C),
      tensorHom (associator W X Y).hom (𝟙 Z) ≫
          (associator W (tensorObj X Y) Z).hom ≫ tensorHom (𝟙 W) (associator X Y Z).hom =
        (associator (tensorObj W X) Y Z).hom ≫ (associator W X (tensorObj Y Z)).hom)
    _auto✝
triangle :
  autoParam
    (∀ (X Y : C),
      (associator X tensorUnit' Y).hom ≫ tensorHom (𝟙 X) (leftUnitor Y).hom = tensorHom (rightUnitor X).hom (𝟙 Y))
    _auto✝
X✝ Y✝ : C
⊢ (fun {X₁ X₂} f X => whiskerRight f X) (𝟙 X✝) Y✝ = 𝟙 (tensorObj X✝ Y✝)
[PROOFSTEP]
simp [← tensorHom_id, tensor_id]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
tensorObj : C → C → C
tensorHom : {X₁ Y₁ X₂ Y₂ : C} → (X₁ ⟶ Y₁) → (X₂ ⟶ Y₂) → (tensorObj X₁ X₂ ⟶ tensorObj Y₁ Y₂)
whiskerLeft :
  optParam ((X : C) → {Y₁ Y₂ : C} → (Y₁ ⟶ Y₂) → (tensorObj X Y₁ ⟶ tensorObj X Y₂)) fun X x x_1 f => tensorHom (𝟙 X) f
whiskerRight :
  optParam ({X₁ X₂ : C} → (X₁ ⟶ X₂) → (Y : C) → tensorObj X₁ Y ⟶ tensorObj X₂ Y) fun {X₁ X₂} f Y => tensorHom f (𝟙 Y)
tensor_id : autoParam (∀ (X₁ X₂ : C), tensorHom (𝟙 X₁) (𝟙 X₂) = 𝟙 (tensorObj X₁ X₂)) _auto✝
id_tensorHom : autoParam (∀ (X : C) {Y₁ Y₂ : C} (f : Y₁ ⟶ Y₂), tensorHom (𝟙 X) f = whiskerLeft X f) _auto✝
tensorHom_id : autoParam (∀ {X₁ X₂ : C} (f : X₁ ⟶ X₂) (Y : C), tensorHom f (𝟙 Y) = whiskerRight f Y) _auto✝
tensor_comp :
  autoParam
    (∀ {X₁ Y₁ Z₁ X₂ Y₂ Z₂ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (g₁ : Y₁ ⟶ Z₁) (g₂ : Y₂ ⟶ Z₂),
      tensorHom (f₁ ≫ g₁) (f₂ ≫ g₂) = tensorHom f₁ f₂ ≫ tensorHom g₁ g₂)
    _auto✝
tensorUnit' : C
associator : (X Y Z : C) → tensorObj (tensorObj X Y) Z ≅ tensorObj X (tensorObj Y Z)
associator_naturality :
  autoParam
    (∀ {X₁ X₂ X₃ Y₁ Y₂ Y₃ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (f₃ : X₃ ⟶ Y₃),
      tensorHom (tensorHom f₁ f₂) f₃ ≫ (associator Y₁ Y₂ Y₃).hom =
        (associator X₁ X₂ X₃).hom ≫ tensorHom f₁ (tensorHom f₂ f₃))
    _auto✝
leftUnitor : (X : C) → tensorObj tensorUnit' X ≅ X
leftUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom (𝟙 tensorUnit') f ≫ (leftUnitor Y).hom = (leftUnitor X).hom ≫ f) _auto✝
rightUnitor : (X : C) → tensorObj X tensorUnit' ≅ X
rightUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom f (𝟙 tensorUnit') ≫ (rightUnitor Y).hom = (rightUnitor X).hom ≫ f)
    _auto✝
pentagon :
  autoParam
    (∀ (W X Y Z : C),
      tensorHom (associator W X Y).hom (𝟙 Z) ≫
          (associator W (tensorObj X Y) Z).hom ≫ tensorHom (𝟙 W) (associator X Y Z).hom =
        (associator (tensorObj W X) Y Z).hom ≫ (associator W X (tensorObj Y Z)).hom)
    _auto✝
triangle :
  autoParam
    (∀ (X Y : C),
      (associator X tensorUnit' Y).hom ≫ tensorHom (𝟙 X) (leftUnitor Y).hom = tensorHom (rightUnitor X).hom (𝟙 Y))
    _auto✝
⊢ ∀ (W X Y Z : C),
    (fun {X₁ Y₁ X₂ Y₂} => tensorHom) (associator W X Y).hom (𝟙 Z) ≫
        (associator W (tensorObj X Y) Z).hom ≫ (fun {X₁ Y₁ X₂ Y₂} => tensorHom) (𝟙 W) (associator X Y Z).hom =
      (associator (tensorObj W X) Y Z).hom ≫ (associator W X (tensorObj Y Z)).hom
[PROOFSTEP]
intros
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
tensorObj : C → C → C
tensorHom : {X₁ Y₁ X₂ Y₂ : C} → (X₁ ⟶ Y₁) → (X₂ ⟶ Y₂) → (tensorObj X₁ X₂ ⟶ tensorObj Y₁ Y₂)
whiskerLeft :
  optParam ((X : C) → {Y₁ Y₂ : C} → (Y₁ ⟶ Y₂) → (tensorObj X Y₁ ⟶ tensorObj X Y₂)) fun X x x_1 f => tensorHom (𝟙 X) f
whiskerRight :
  optParam ({X₁ X₂ : C} → (X₁ ⟶ X₂) → (Y : C) → tensorObj X₁ Y ⟶ tensorObj X₂ Y) fun {X₁ X₂} f Y => tensorHom f (𝟙 Y)
tensor_id : autoParam (∀ (X₁ X₂ : C), tensorHom (𝟙 X₁) (𝟙 X₂) = 𝟙 (tensorObj X₁ X₂)) _auto✝
id_tensorHom : autoParam (∀ (X : C) {Y₁ Y₂ : C} (f : Y₁ ⟶ Y₂), tensorHom (𝟙 X) f = whiskerLeft X f) _auto✝
tensorHom_id : autoParam (∀ {X₁ X₂ : C} (f : X₁ ⟶ X₂) (Y : C), tensorHom f (𝟙 Y) = whiskerRight f Y) _auto✝
tensor_comp :
  autoParam
    (∀ {X₁ Y₁ Z₁ X₂ Y₂ Z₂ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (g₁ : Y₁ ⟶ Z₁) (g₂ : Y₂ ⟶ Z₂),
      tensorHom (f₁ ≫ g₁) (f₂ ≫ g₂) = tensorHom f₁ f₂ ≫ tensorHom g₁ g₂)
    _auto✝
tensorUnit' : C
associator : (X Y Z : C) → tensorObj (tensorObj X Y) Z ≅ tensorObj X (tensorObj Y Z)
associator_naturality :
  autoParam
    (∀ {X₁ X₂ X₃ Y₁ Y₂ Y₃ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (f₃ : X₃ ⟶ Y₃),
      tensorHom (tensorHom f₁ f₂) f₃ ≫ (associator Y₁ Y₂ Y₃).hom =
        (associator X₁ X₂ X₃).hom ≫ tensorHom f₁ (tensorHom f₂ f₃))
    _auto✝
leftUnitor : (X : C) → tensorObj tensorUnit' X ≅ X
leftUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom (𝟙 tensorUnit') f ≫ (leftUnitor Y).hom = (leftUnitor X).hom ≫ f) _auto✝
rightUnitor : (X : C) → tensorObj X tensorUnit' ≅ X
rightUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom f (𝟙 tensorUnit') ≫ (rightUnitor Y).hom = (rightUnitor X).hom ≫ f)
    _auto✝
pentagon :
  autoParam
    (∀ (W X Y Z : C),
      tensorHom (associator W X Y).hom (𝟙 Z) ≫
          (associator W (tensorObj X Y) Z).hom ≫ tensorHom (𝟙 W) (associator X Y Z).hom =
        (associator (tensorObj W X) Y Z).hom ≫ (associator W X (tensorObj Y Z)).hom)
    _auto✝
triangle :
  autoParam
    (∀ (X Y : C),
      (associator X tensorUnit' Y).hom ≫ tensorHom (𝟙 X) (leftUnitor Y).hom = tensorHom (rightUnitor X).hom (𝟙 Y))
    _auto✝
W✝ X✝ Y✝ Z✝ : C
⊢ (fun {X₁ Y₁ X₂ Y₂} => tensorHom) (associator W✝ X✝ Y✝).hom (𝟙 Z✝) ≫
      (associator W✝ (tensorObj X✝ Y✝) Z✝).hom ≫ (fun {X₁ Y₁ X₂ Y₂} => tensorHom) (𝟙 W✝) (associator X✝ Y✝ Z✝).hom =
    (associator (tensorObj W✝ X✝) Y✝ Z✝).hom ≫ (associator W✝ X✝ (tensorObj Y✝ Z✝)).hom
[PROOFSTEP]
simp [← id_tensorHom, ← tensorHom_id, pentagon]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
tensorObj : C → C → C
tensorHom : {X₁ Y₁ X₂ Y₂ : C} → (X₁ ⟶ Y₁) → (X₂ ⟶ Y₂) → (tensorObj X₁ X₂ ⟶ tensorObj Y₁ Y₂)
whiskerLeft :
  optParam ((X : C) → {Y₁ Y₂ : C} → (Y₁ ⟶ Y₂) → (tensorObj X Y₁ ⟶ tensorObj X Y₂)) fun X x x_1 f => tensorHom (𝟙 X) f
whiskerRight :
  optParam ({X₁ X₂ : C} → (X₁ ⟶ X₂) → (Y : C) → tensorObj X₁ Y ⟶ tensorObj X₂ Y) fun {X₁ X₂} f Y => tensorHom f (𝟙 Y)
tensor_id : autoParam (∀ (X₁ X₂ : C), tensorHom (𝟙 X₁) (𝟙 X₂) = 𝟙 (tensorObj X₁ X₂)) _auto✝
id_tensorHom : autoParam (∀ (X : C) {Y₁ Y₂ : C} (f : Y₁ ⟶ Y₂), tensorHom (𝟙 X) f = whiskerLeft X f) _auto✝
tensorHom_id : autoParam (∀ {X₁ X₂ : C} (f : X₁ ⟶ X₂) (Y : C), tensorHom f (𝟙 Y) = whiskerRight f Y) _auto✝
tensor_comp :
  autoParam
    (∀ {X₁ Y₁ Z₁ X₂ Y₂ Z₂ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (g₁ : Y₁ ⟶ Z₁) (g₂ : Y₂ ⟶ Z₂),
      tensorHom (f₁ ≫ g₁) (f₂ ≫ g₂) = tensorHom f₁ f₂ ≫ tensorHom g₁ g₂)
    _auto✝
tensorUnit' : C
associator : (X Y Z : C) → tensorObj (tensorObj X Y) Z ≅ tensorObj X (tensorObj Y Z)
associator_naturality :
  autoParam
    (∀ {X₁ X₂ X₃ Y₁ Y₂ Y₃ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (f₃ : X₃ ⟶ Y₃),
      tensorHom (tensorHom f₁ f₂) f₃ ≫ (associator Y₁ Y₂ Y₃).hom =
        (associator X₁ X₂ X₃).hom ≫ tensorHom f₁ (tensorHom f₂ f₃))
    _auto✝
leftUnitor : (X : C) → tensorObj tensorUnit' X ≅ X
leftUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom (𝟙 tensorUnit') f ≫ (leftUnitor Y).hom = (leftUnitor X).hom ≫ f) _auto✝
rightUnitor : (X : C) → tensorObj X tensorUnit' ≅ X
rightUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom f (𝟙 tensorUnit') ≫ (rightUnitor Y).hom = (rightUnitor X).hom ≫ f)
    _auto✝
pentagon :
  autoParam
    (∀ (W X Y Z : C),
      tensorHom (associator W X Y).hom (𝟙 Z) ≫
          (associator W (tensorObj X Y) Z).hom ≫ tensorHom (𝟙 W) (associator X Y Z).hom =
        (associator (tensorObj W X) Y Z).hom ≫ (associator W X (tensorObj Y Z)).hom)
    _auto✝
triangle :
  autoParam
    (∀ (X Y : C),
      (associator X tensorUnit' Y).hom ≫ tensorHom (𝟙 X) (leftUnitor Y).hom = tensorHom (rightUnitor X).hom (𝟙 Y))
    _auto✝
⊢ ∀ (X Y : C),
    (associator X tensorUnit' Y).hom ≫ (fun {X₁ Y₁ X₂ Y₂} => tensorHom) (𝟙 X) (leftUnitor Y).hom =
      (fun {X₁ Y₁ X₂ Y₂} => tensorHom) (rightUnitor X).hom (𝟙 Y)
[PROOFSTEP]
intros
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
U V W X Y Z : C
tensorObj : C → C → C
tensorHom : {X₁ Y₁ X₂ Y₂ : C} → (X₁ ⟶ Y₁) → (X₂ ⟶ Y₂) → (tensorObj X₁ X₂ ⟶ tensorObj Y₁ Y₂)
whiskerLeft :
  optParam ((X : C) → {Y₁ Y₂ : C} → (Y₁ ⟶ Y₂) → (tensorObj X Y₁ ⟶ tensorObj X Y₂)) fun X x x_1 f => tensorHom (𝟙 X) f
whiskerRight :
  optParam ({X₁ X₂ : C} → (X₁ ⟶ X₂) → (Y : C) → tensorObj X₁ Y ⟶ tensorObj X₂ Y) fun {X₁ X₂} f Y => tensorHom f (𝟙 Y)
tensor_id : autoParam (∀ (X₁ X₂ : C), tensorHom (𝟙 X₁) (𝟙 X₂) = 𝟙 (tensorObj X₁ X₂)) _auto✝
id_tensorHom : autoParam (∀ (X : C) {Y₁ Y₂ : C} (f : Y₁ ⟶ Y₂), tensorHom (𝟙 X) f = whiskerLeft X f) _auto✝
tensorHom_id : autoParam (∀ {X₁ X₂ : C} (f : X₁ ⟶ X₂) (Y : C), tensorHom f (𝟙 Y) = whiskerRight f Y) _auto✝
tensor_comp :
  autoParam
    (∀ {X₁ Y₁ Z₁ X₂ Y₂ Z₂ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (g₁ : Y₁ ⟶ Z₁) (g₂ : Y₂ ⟶ Z₂),
      tensorHom (f₁ ≫ g₁) (f₂ ≫ g₂) = tensorHom f₁ f₂ ≫ tensorHom g₁ g₂)
    _auto✝
tensorUnit' : C
associator : (X Y Z : C) → tensorObj (tensorObj X Y) Z ≅ tensorObj X (tensorObj Y Z)
associator_naturality :
  autoParam
    (∀ {X₁ X₂ X₃ Y₁ Y₂ Y₃ : C} (f₁ : X₁ ⟶ Y₁) (f₂ : X₂ ⟶ Y₂) (f₃ : X₃ ⟶ Y₃),
      tensorHom (tensorHom f₁ f₂) f₃ ≫ (associator Y₁ Y₂ Y₃).hom =
        (associator X₁ X₂ X₃).hom ≫ tensorHom f₁ (tensorHom f₂ f₃))
    _auto✝
leftUnitor : (X : C) → tensorObj tensorUnit' X ≅ X
leftUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom (𝟙 tensorUnit') f ≫ (leftUnitor Y).hom = (leftUnitor X).hom ≫ f) _auto✝
rightUnitor : (X : C) → tensorObj X tensorUnit' ≅ X
rightUnitor_naturality :
  autoParam (∀ {X Y : C} (f : X ⟶ Y), tensorHom f (𝟙 tensorUnit') ≫ (rightUnitor Y).hom = (rightUnitor X).hom ≫ f)
    _auto✝
pentagon :
  autoParam
    (∀ (W X Y Z : C),
      tensorHom (associator W X Y).hom (𝟙 Z) ≫
          (associator W (tensorObj X Y) Z).hom ≫ tensorHom (𝟙 W) (associator X Y Z).hom =
        (associator (tensorObj W X) Y Z).hom ≫ (associator W X (tensorObj Y Z)).hom)
    _auto✝
triangle :
  autoParam
    (∀ (X Y : C),
      (associator X tensorUnit' Y).hom ≫ tensorHom (𝟙 X) (leftUnitor Y).hom = tensorHom (rightUnitor X).hom (𝟙 Y))
    _auto✝
X✝ Y✝ : C
⊢ (associator X✝ tensorUnit' Y✝).hom ≫ (fun {X₁ Y₁ X₂ Y₂} => tensorHom) (𝟙 X✝) (leftUnitor Y✝).hom =
    (fun {X₁ Y₁ X₂ Y₂} => tensorHom) (rightUnitor X✝).hom (𝟙 Y✝)
[PROOFSTEP]
simp [← id_tensorHom, ← tensorHom_id, triangle]
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
⊢ (X : C × C × C) → (leftAssocTensor C).obj X ≅ (rightAssocTensor C).obj X
[PROOFSTEP]
intros
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X✝ : C × C × C
⊢ (leftAssocTensor C).obj X✝ ≅ (rightAssocTensor C).obj X✝
[PROOFSTEP]
apply MonoidalCategory.associator
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
⊢ ∀ {X Y : C × C × C} (f : X ⟶ Y),
    (leftAssocTensor C).map f ≫ (α_ Y.fst Y.snd.fst Y.snd.snd).hom =
      (α_ X.fst X.snd.fst X.snd.snd).hom ≫ (rightAssocTensor C).map f
[PROOFSTEP]
intros
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X✝ Y✝ : C × C × C
f✝ : X✝ ⟶ Y✝
⊢ (leftAssocTensor C).map f✝ ≫ (α_ Y✝.fst Y✝.snd.fst Y✝.snd.snd).hom =
    (α_ X✝.fst X✝.snd.fst X✝.snd.snd).hom ≫ (rightAssocTensor C).map f✝
[PROOFSTEP]
apply MonoidalCategory.associator_naturality
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
⊢ (X : C) → (tensorUnitLeft C).obj X ≅ (𝟭 C).obj X
[PROOFSTEP]
intros
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X✝ : C
⊢ (tensorUnitLeft C).obj X✝ ≅ (𝟭 C).obj X✝
[PROOFSTEP]
apply MonoidalCategory.leftUnitor
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
⊢ ∀ {X Y : C} (f : X ⟶ Y), (tensorUnitLeft C).map f ≫ (λ_ Y).hom = (λ_ X).hom ≫ (𝟭 C).map f
[PROOFSTEP]
intros
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X✝ Y✝ : C
f✝ : X✝ ⟶ Y✝
⊢ (tensorUnitLeft C).map f✝ ≫ (λ_ Y✝).hom = (λ_ X✝).hom ≫ (𝟭 C).map f✝
[PROOFSTEP]
apply MonoidalCategory.leftUnitor_naturality
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
⊢ (X : C) → (tensorUnitRight C).obj X ≅ (𝟭 C).obj X
[PROOFSTEP]
intros
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X✝ : C
⊢ (tensorUnitRight C).obj X✝ ≅ (𝟭 C).obj X✝
[PROOFSTEP]
apply MonoidalCategory.rightUnitor
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
⊢ ∀ {X Y : C} (f : X ⟶ Y), (tensorUnitRight C).map f ≫ (ρ_ Y).hom = (ρ_ X).hom ≫ (𝟭 C).map f
[PROOFSTEP]
intros
[GOAL]
C✝ : Type u
𝒞 : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X✝ Y✝ : C
f✝ : X✝ ⟶ Y✝
⊢ (tensorUnitRight C).map f✝ ≫ (ρ_ Y✝).hom = (ρ_ X✝).hom ≫ (𝟭 C).map f✝
[PROOFSTEP]
apply MonoidalCategory.rightUnitor_naturality
[GOAL]
C✝¹ : Type u
𝒞 : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y Z Z' : C
f : Z ⟶ Z'
⊢ (tensorLeft (X ⊗ Y)).map f ≫ (α_ X Y Z').hom = (α_ X Y Z).hom ≫ (tensorLeft Y ⋙ tensorLeft X).map f
[PROOFSTEP]
dsimp
[GOAL]
C✝¹ : Type u
𝒞 : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y Z Z' : C
f : Z ⟶ Z'
⊢ (𝟙 (X ⊗ Y) ⊗ f) ≫ (α_ X Y Z').hom = (α_ X Y Z).hom ≫ (𝟙 X ⊗ 𝟙 Y ⊗ f)
[PROOFSTEP]
rw [← tensor_id]
[GOAL]
C✝¹ : Type u
𝒞 : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y Z Z' : C
f : Z ⟶ Z'
⊢ ((𝟙 X ⊗ 𝟙 Y) ⊗ f) ≫ (α_ X Y Z').hom = (α_ X Y Z).hom ≫ (𝟙 X ⊗ 𝟙 Y ⊗ f)
[PROOFSTEP]
apply associator_naturality
[GOAL]
C✝¹ : Type u
𝒞 : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y Z : C
⊢ NatTrans.app (tensorLeftTensor X Y).inv Z = (α_ X Y Z).inv
[PROOFSTEP]
simp [tensorLeftTensor]
[GOAL]
C✝² : Type u
𝒞 : Category.{v, u} C✝²
inst✝⁶ : MonoidalCategory C✝²
C✝¹ : Type u
inst✝⁵ : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y : C
f g : X ⟶ Y
h : (tensoringLeft C).map f = (tensoringLeft C).map g
⊢ f = g
[PROOFSTEP]
injections h
[GOAL]
C✝² : Type u
𝒞 : Category.{v, u} C✝²
inst✝⁶ : MonoidalCategory C✝²
C✝¹ : Type u
inst✝⁵ : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y : C
f g : X ⟶ Y
h : (fun Z => f ⊗ 𝟙 Z) = fun Z => g ⊗ 𝟙 Z
⊢ f = g
[PROOFSTEP]
replace h := congr_fun h (𝟙_ C)
[GOAL]
C✝² : Type u
𝒞 : Category.{v, u} C✝²
inst✝⁶ : MonoidalCategory C✝²
C✝¹ : Type u
inst✝⁵ : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y : C
f g : X ⟶ Y
h : f ⊗ 𝟙 (𝟙_ C) = g ⊗ 𝟙 (𝟙_ C)
⊢ f = g
[PROOFSTEP]
simpa using h
[GOAL]
C✝² : Type u
𝒞 : Category.{v, u} C✝²
inst✝⁶ : MonoidalCategory C✝²
C✝¹ : Type u
inst✝⁵ : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y : C
f g : X ⟶ Y
h : (tensoringRight C).map f = (tensoringRight C).map g
⊢ f = g
[PROOFSTEP]
injections h
[GOAL]
C✝² : Type u
𝒞 : Category.{v, u} C✝²
inst✝⁶ : MonoidalCategory C✝²
C✝¹ : Type u
inst✝⁵ : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y : C
f g : X ⟶ Y
h : (fun Z => 𝟙 Z ⊗ f) = fun Z => 𝟙 Z ⊗ g
⊢ f = g
[PROOFSTEP]
replace h := congr_fun h (𝟙_ C)
[GOAL]
C✝² : Type u
𝒞 : Category.{v, u} C✝²
inst✝⁶ : MonoidalCategory C✝²
C✝¹ : Type u
inst✝⁵ : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y : C
f g : X ⟶ Y
h : 𝟙 (𝟙_ C) ⊗ f = 𝟙 (𝟙_ C) ⊗ g
⊢ f = g
[PROOFSTEP]
simpa using h
[GOAL]
C✝³ : Type u
𝒞 : Category.{v, u} C✝³
inst✝⁸ : MonoidalCategory C✝³
C✝² : Type u
inst✝⁷ : Category.{v, u} C✝²
inst✝⁶ : MonoidalCategory C✝²
C✝¹ : Type u
inst✝⁵ : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y Z Z' : C
f : Z ⟶ Z'
⊢ (tensorRight (X ⊗ Y)).map f ≫ ((fun Z => (α_ Z X Y).symm) Z').hom =
    ((fun Z => (α_ Z X Y).symm) Z).hom ≫ (tensorRight X ⋙ tensorRight Y).map f
[PROOFSTEP]
dsimp
[GOAL]
C✝³ : Type u
𝒞 : Category.{v, u} C✝³
inst✝⁸ : MonoidalCategory C✝³
C✝² : Type u
inst✝⁷ : Category.{v, u} C✝²
inst✝⁶ : MonoidalCategory C✝²
C✝¹ : Type u
inst✝⁵ : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y Z Z' : C
f : Z ⟶ Z'
⊢ (f ⊗ 𝟙 (X ⊗ Y)) ≫ (α_ Z' X Y).inv = (α_ Z X Y).inv ≫ ((f ⊗ 𝟙 X) ⊗ 𝟙 Y)
[PROOFSTEP]
rw [← tensor_id]
[GOAL]
C✝³ : Type u
𝒞 : Category.{v, u} C✝³
inst✝⁸ : MonoidalCategory C✝³
C✝² : Type u
inst✝⁷ : Category.{v, u} C✝²
inst✝⁶ : MonoidalCategory C✝²
C✝¹ : Type u
inst✝⁵ : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y Z Z' : C
f : Z ⟶ Z'
⊢ (f ⊗ 𝟙 X ⊗ 𝟙 Y) ≫ (α_ Z' X Y).inv = (α_ Z X Y).inv ≫ ((f ⊗ 𝟙 X) ⊗ 𝟙 Y)
[PROOFSTEP]
apply associator_inv_naturality
[GOAL]
C✝³ : Type u
𝒞 : Category.{v, u} C✝³
inst✝⁸ : MonoidalCategory C✝³
C✝² : Type u
inst✝⁷ : Category.{v, u} C✝²
inst✝⁶ : MonoidalCategory C✝²
C✝¹ : Type u
inst✝⁵ : Category.{v, u} C✝¹
inst✝⁴ : MonoidalCategory C✝¹
C✝ : Type u
inst✝³ : Category.{v, u} C✝
inst✝² : MonoidalCategory C✝
C : Type u
inst✝¹ : Category.{v, u} C
inst✝ : MonoidalCategory C
X Y Z : C
⊢ NatTrans.app (tensorRightTensor X Y).inv Z = (α_ Z X Y).hom
[PROOFSTEP]
simp [tensorRightTensor]
[GOAL]
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
⊢ ∀ {X₁ Y₁ X₂ Y₂ : C₁ × C₂} (f : X₁ ⟶ Y₁) (g : X₂ ⟶ Y₂),
    (fun {X₁ Y₁ X₂ Y₂} f g => (f.fst ⊗ g.fst, f.snd ⊗ g.snd)) f g =
      (fun {X₁ X₂} f X => (f.fst ▷ X.fst, f.snd ▷ X.snd)) f X₂ ≫
        (fun X x x_1 f => (X.fst ◁ f.fst, X.snd ◁ f.snd)) Y₁ X₂ Y₂ g
[PROOFSTEP]
simp [tensorHom_def]
[GOAL]
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
X : C₁ × C₂
⊢ (λ_ X).hom.fst = (λ_ X.fst).hom
[PROOFSTEP]
cases X
[GOAL]
case mk
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
fst✝ : C₁
snd✝ : C₂
⊢ (λ_ (fst✝, snd✝)).hom.fst = (λ_ (fst✝, snd✝).fst).hom
[PROOFSTEP]
rfl
[GOAL]
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
X : C₁ × C₂
⊢ (λ_ X).hom.snd = (λ_ X.snd).hom
[PROOFSTEP]
cases X
[GOAL]
case mk
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
fst✝ : C₁
snd✝ : C₂
⊢ (λ_ (fst✝, snd✝)).hom.snd = (λ_ (fst✝, snd✝).snd).hom
[PROOFSTEP]
rfl
[GOAL]
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
X : C₁ × C₂
⊢ (λ_ X).inv.fst = (λ_ X.fst).inv
[PROOFSTEP]
cases X
[GOAL]
case mk
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
fst✝ : C₁
snd✝ : C₂
⊢ (λ_ (fst✝, snd✝)).inv.fst = (λ_ (fst✝, snd✝).fst).inv
[PROOFSTEP]
rfl
[GOAL]
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
X : C₁ × C₂
⊢ (λ_ X).inv.snd = (λ_ X.snd).inv
[PROOFSTEP]
cases X
[GOAL]
case mk
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
fst✝ : C₁
snd✝ : C₂
⊢ (λ_ (fst✝, snd✝)).inv.snd = (λ_ (fst✝, snd✝).snd).inv
[PROOFSTEP]
rfl
[GOAL]
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
X : C₁ × C₂
⊢ (ρ_ X).hom.fst = (ρ_ X.fst).hom
[PROOFSTEP]
cases X
[GOAL]
case mk
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
fst✝ : C₁
snd✝ : C₂
⊢ (ρ_ (fst✝, snd✝)).hom.fst = (ρ_ (fst✝, snd✝).fst).hom
[PROOFSTEP]
rfl
[GOAL]
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
X : C₁ × C₂
⊢ (ρ_ X).hom.snd = (ρ_ X.snd).hom
[PROOFSTEP]
cases X
[GOAL]
case mk
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
fst✝ : C₁
snd✝ : C₂
⊢ (ρ_ (fst✝, snd✝)).hom.snd = (ρ_ (fst✝, snd✝).snd).hom
[PROOFSTEP]
rfl
[GOAL]
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
X : C₁ × C₂
⊢ (ρ_ X).inv.fst = (ρ_ X.fst).inv
[PROOFSTEP]
cases X
[GOAL]
case mk
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
fst✝ : C₁
snd✝ : C₂
⊢ (ρ_ (fst✝, snd✝)).inv.fst = (ρ_ (fst✝, snd✝).fst).inv
[PROOFSTEP]
rfl
[GOAL]
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
X : C₁ × C₂
⊢ (ρ_ X).inv.snd = (ρ_ X.snd).inv
[PROOFSTEP]
cases X
[GOAL]
case mk
C : Type u
𝒞 : Category.{v, u} C
inst✝⁴ : MonoidalCategory C
C₁ : Type u₁
inst✝³ : Category.{v₁, u₁} C₁
inst✝² : MonoidalCategory C₁
C₂ : Type u₂
inst✝¹ : Category.{v₂, u₂} C₂
inst✝ : MonoidalCategory C₂
fst✝ : C₁
snd✝ : C₂
⊢ (ρ_ (fst✝, snd✝)).inv.snd = (ρ_ (fst✝, snd✝).snd).inv
[PROOFSTEP]
rfl


[GOAL]
A : Type u_1
α : Type u_2
inst✝² : Monoid A
inst✝¹ : Pow A α
inst✝ : Zero α
H : ∀ {n : α}, n ≠ 0 → Function.Surjective fun a => a ^ n
x✝ : A
⊢ (fun a n => if x : n = 0 then 1 else Exists.choose (_ : ∃ a_1, (fun a => a ^ n) a_1 = a)) x✝ 0 = 1
[PROOFSTEP]
classical exact dif_pos rfl
[GOAL]
A : Type u_1
α : Type u_2
inst✝² : Monoid A
inst✝¹ : Pow A α
inst✝ : Zero α
H : ∀ {n : α}, n ≠ 0 → Function.Surjective fun a => a ^ n
x✝ : A
⊢ (fun a n => if x : n = 0 then 1 else Exists.choose (_ : ∃ a_1, (fun a => a ^ n) a_1 = a)) x✝ 0 = 1
[PROOFSTEP]
exact dif_pos rfl
[GOAL]
A : Type u_1
α : Type u_2
inst✝² : Monoid A
inst✝¹ : Pow A α
inst✝ : Zero α
H : ∀ {n : α}, n ≠ 0 → Function.Surjective fun a => a ^ n
n✝ : α
a : A
hn : n✝ ≠ 0
⊢ (fun a n => if x : n = 0 then 1 else Exists.choose (_ : ∃ a_1, (fun a => a ^ n) a_1 = a)) a n✝ ^ n✝ = a
[PROOFSTEP]
dsimp only
[GOAL]
A : Type u_1
α : Type u_2
inst✝² : Monoid A
inst✝¹ : Pow A α
inst✝ : Zero α
H : ∀ {n : α}, n ≠ 0 → Function.Surjective fun a => a ^ n
n✝ : α
a : A
hn : n✝ ≠ 0
⊢ (if x : n✝ = 0 then 1 else Exists.choose (_ : ∃ a_1, (fun a => a ^ n✝) a_1 = a)) ^ n✝ = a
[PROOFSTEP]
rw [dif_neg hn]
[GOAL]
A : Type u_1
α : Type u_2
inst✝² : Monoid A
inst✝¹ : Pow A α
inst✝ : Zero α
H : ∀ {n : α}, n ≠ 0 → Function.Surjective fun a => a ^ n
n✝ : α
a : A
hn : n✝ ≠ 0
⊢ Exists.choose (_ : ∃ a_1, (fun a => a ^ n✝) a_1 = a) ^ n✝ = a
[PROOFSTEP]
exact (H hn a).choose_spec
[GOAL]
A : Type u_1
inst✝ : AddCommGroup A
H : ∀ {n : ℤ}, n ≠ 0 → n • ⊤ = ⊤
a : A
n : ℤ
hn : ¬n = 0
⊢ a ∈ n • ⊤
[PROOFSTEP]
rw [H hn]
[GOAL]
A : Type u_1
inst✝ : AddCommGroup A
H : ∀ {n : ℤ}, n ≠ 0 → n • ⊤ = ⊤
a : A
n : ℤ
hn : ¬n = 0
⊢ a ∈ ⊤
[PROOFSTEP]
trivial
[GOAL]
A : Type u_1
inst✝ : AddCommGroup A
H : ∀ {n : ℤ}, n ≠ 0 → n • ⊤ = ⊤
n✝ : ℤ
a : A
hn : n✝ ≠ 0
⊢ n✝ • (fun a n => if hn : n = 0 then 0 else Exists.choose (_ : a ∈ n • ⊤)) a n✝ = a
[PROOFSTEP]
simp_rw [dif_neg hn]
[GOAL]
A : Type u_1
inst✝ : AddCommGroup A
H : ∀ {n : ℤ}, n ≠ 0 → n • ⊤ = ⊤
n✝ : ℤ
a : A
hn : n✝ ≠ 0
⊢ n✝ • Exists.choose (_ : a ∈ n✝ • ⊤) = a
[PROOFSTEP]
generalize_proofs h1
[GOAL]
A : Type u_1
inst✝ : AddCommGroup A
H : ∀ {n : ℤ}, n ≠ 0 → n • ⊤ = ⊤
n✝ : ℤ
a : A
hn : n✝ ≠ 0
h1 : a ∈ n✝ • ⊤
⊢ n✝ • Exists.choose h1 = a
[PROOFSTEP]
exact h1.choose_spec.2
[GOAL]
𝕜 : Type ?u.71834
inst✝¹ : DivisionRing 𝕜
inst✝ : CharZero 𝕜
q : 𝕜
⊢ (fun q n => q / ↑n) q 0 = 0
[PROOFSTEP]
norm_num
[GOAL]
𝕜 : Type ?u.71834
inst✝¹ : DivisionRing 𝕜
inst✝ : CharZero 𝕜
n : ℤ
q : 𝕜
hn : n ≠ 0
⊢ n • (fun q n => q / ↑n) q n = q
[PROOFSTEP]
rw [zsmul_eq_mul, (Int.cast_commute n _).eq, div_mul_cancel q (Int.cast_ne_zero.mpr hn)]
[GOAL]
A : Type u_1
inst✝¹ : Group A
inst✝ : RootableBy A ℕ
n : ℤ
a : A
hn : n ≠ 0
⊢ (fun a z =>
          match z with
          | ofNat n => RootableBy.root a n
          | -[n+1] => (RootableBy.root a (n + 1))⁻¹)
        a n ^
      n =
    a
[PROOFSTEP]
induction n
[GOAL]
case ofNat
A : Type u_1
inst✝¹ : Group A
inst✝ : RootableBy A ℕ
a : A
a✝ : ℕ
hn : ofNat a✝ ≠ 0
⊢ (fun a z =>
          match z with
          | ofNat n => RootableBy.root a n
          | -[n+1] => (RootableBy.root a (n + 1))⁻¹)
        a (ofNat a✝) ^
      ofNat a✝ =
    a
[PROOFSTEP]
change RootableBy.root a _ ^ _ = a
[GOAL]
case ofNat
A : Type u_1
inst✝¹ : Group A
inst✝ : RootableBy A ℕ
a : A
a✝ : ℕ
hn : ofNat a✝ ≠ 0
⊢ RootableBy.root a a✝ ^ ofNat a✝ = a
[PROOFSTEP]
norm_num
[GOAL]
case ofNat
A : Type u_1
inst✝¹ : Group A
inst✝ : RootableBy A ℕ
a : A
a✝ : ℕ
hn : ofNat a✝ ≠ 0
⊢ RootableBy.root a a✝ ^ a✝ = a
[PROOFSTEP]
rw [RootableBy.root_cancel]
[GOAL]
case ofNat.a
A : Type u_1
inst✝¹ : Group A
inst✝ : RootableBy A ℕ
a : A
a✝ : ℕ
hn : ofNat a✝ ≠ 0
⊢ a✝ ≠ 0
[PROOFSTEP]
rw [Int.ofNat_eq_coe] at hn
[GOAL]
case ofNat.a
A : Type u_1
inst✝¹ : Group A
inst✝ : RootableBy A ℕ
a : A
a✝ : ℕ
hn : ↑a✝ ≠ 0
⊢ a✝ ≠ 0
[PROOFSTEP]
exact_mod_cast hn
[GOAL]
case negSucc
A : Type u_1
inst✝¹ : Group A
inst✝ : RootableBy A ℕ
a : A
a✝ : ℕ
hn : -[a✝+1] ≠ 0
⊢ (fun a z =>
          match z with
          | ofNat n => RootableBy.root a n
          | -[n+1] => (RootableBy.root a (n + 1))⁻¹)
        a -[a✝+1] ^
      -[a✝+1] =
    a
[PROOFSTEP]
change (RootableBy.root a _)⁻¹ ^ _ = a
[GOAL]
case negSucc
A : Type u_1
inst✝¹ : Group A
inst✝ : RootableBy A ℕ
a : A
a✝ : ℕ
hn : -[a✝+1] ≠ 0
⊢ (RootableBy.root a (a✝ + 1))⁻¹ ^ -[a✝+1] = a
[PROOFSTEP]
norm_num
[GOAL]
case negSucc
A : Type u_1
inst✝¹ : Group A
inst✝ : RootableBy A ℕ
a : A
a✝ : ℕ
hn : -[a✝+1] ≠ 0
⊢ RootableBy.root a (a✝ + 1) ^ (a✝ + 1) = a
[PROOFSTEP]
rw [RootableBy.root_cancel]
[GOAL]
case negSucc.a
A : Type u_1
inst✝¹ : Group A
inst✝ : RootableBy A ℕ
a : A
a✝ : ℕ
hn : -[a✝+1] ≠ 0
⊢ a✝ + 1 ≠ 0
[PROOFSTEP]
norm_num
[GOAL]
A : Type u_1
inst✝¹ : Group A
inst✝ : RootableBy A ℤ
n : ℕ
a : A
hn : n ≠ 0
⊢ (fun a n => RootableBy.root a ↑n) a n ^ n = a
[PROOFSTEP]
simpa only [zpow_coe_nat] using RootableBy.root_cancel a (show (n : ℤ) ≠ 0 by exact_mod_cast hn)
[GOAL]
A : Type u_1
inst✝¹ : Group A
inst✝ : RootableBy A ℤ
n : ℕ
a : A
hn : n ≠ 0
⊢ ↑n ≠ 0
[PROOFSTEP]
exact_mod_cast hn
[GOAL]
A : Type u_1
B : Type u_2
α : Type u_3
inst✝⁵ : Zero α
inst✝⁴ : Monoid A
inst✝³ : Monoid B
inst✝² : Pow A α
inst✝¹ : Pow B α
inst✝ : RootableBy A α
f : A → B
hf : Surjective f
hpow : ∀ (a : A) (n : α), f (a ^ n) = f a ^ n
n : α
hn : n ≠ 0
x : B
y : A
hy : f y = x
⊢ f (RootableBy.root y n) ^ n = x
[PROOFSTEP]
rw [← hpow (RootableBy.root y n) n, RootableBy.root_cancel _ hn, hy]


[GOAL]
⊢ factors 0 = []
[PROOFSTEP]
rw [factors]
[GOAL]
⊢ factors 1 = []
[PROOFSTEP]
rw [factors]
[GOAL]
n : ℕ
⊢ ∀ {p : ℕ}, p ∈ factors n → Prime p
[PROOFSTEP]
match n with
| 0 => simp
| 1 => simp
| k + 2 =>
  intro p h
  let m := minFac (k + 2)
  have : (k + 2) / m < (k + 2) := factors_lemma
  have h₁ : p = m ∨ p ∈ factors ((k + 2) / m) := List.mem_cons.1 (by rwa [factors] at h )
  exact Or.casesOn h₁ (fun h₂ => h₂.symm ▸ minFac_prime (by simp)) prime_of_mem_factors
[GOAL]
n : ℕ
⊢ ∀ {p : ℕ}, p ∈ factors 0 → Prime p
[PROOFSTEP]
simp
[GOAL]
n : ℕ
⊢ ∀ {p : ℕ}, p ∈ factors 1 → Prime p
[PROOFSTEP]
simp
[GOAL]
n k : ℕ
⊢ ∀ {p : ℕ}, p ∈ factors (k + 2) → Prime p
[PROOFSTEP]
intro p h
[GOAL]
n k p : ℕ
h : p ∈ factors (k + 2)
⊢ Prime p
[PROOFSTEP]
let m := minFac (k + 2)
[GOAL]
n k p : ℕ
h : p ∈ factors (k + 2)
m : ℕ := minFac (k + 2)
⊢ Prime p
[PROOFSTEP]
have : (k + 2) / m < (k + 2) := factors_lemma
[GOAL]
n k p : ℕ
h : p ∈ factors (k + 2)
m : ℕ := minFac (k + 2)
this : (k + 2) / m < k + 2
⊢ Prime p
[PROOFSTEP]
have h₁ : p = m ∨ p ∈ factors ((k + 2) / m) := List.mem_cons.1 (by rwa [factors] at h )
[GOAL]
n k p : ℕ
h : p ∈ factors (k + 2)
m : ℕ := minFac (k + 2)
this : (k + 2) / m < k + 2
⊢ p ∈ m :: factors ((k + 2) / m)
[PROOFSTEP]
rwa [factors] at h
[GOAL]
n k p : ℕ
h : p ∈ factors (k + 2)
m : ℕ := minFac (k + 2)
this : (k + 2) / m < k + 2
h₁ : p = m ∨ p ∈ factors ((k + 2) / m)
⊢ Prime p
[PROOFSTEP]
exact Or.casesOn h₁ (fun h₂ => h₂.symm ▸ minFac_prime (by simp)) prime_of_mem_factors
[GOAL]
n k p : ℕ
h : p ∈ factors (k + 2)
m : ℕ := minFac (k + 2)
this : (k + 2) / m < k + 2
h₁ : p = m ∨ p ∈ factors ((k + 2) / m)
h₂ : p = m
⊢ k + 2 ≠ 1
[PROOFSTEP]
simp
[GOAL]
⊢ 0 ≠ 0 → List.prod (factors 0) = 0
[PROOFSTEP]
simp
[GOAL]
⊢ 1 ≠ 0 → List.prod (factors 1) = 1
[PROOFSTEP]
simp
[GOAL]
k : ℕ
x✝ : k + 2 ≠ 0
m : ℕ := minFac (k + 2)
this : (k + 2) / m < k + 2
⊢ List.prod (factors (k + 2)) = k + 2
[PROOFSTEP]
have h₁ : (k + 2) / m ≠ 0 := fun h =>
  by
  have : (k + 2) = 0 * m := (Nat.div_eq_iff_eq_mul_left (minFac_pos _) (minFac_dvd _)).1 h
  rw [zero_mul] at this ; exact (show k + 2 ≠ 0 by simp) this
[GOAL]
k : ℕ
x✝ : k + 2 ≠ 0
m : ℕ := minFac (k + 2)
this : (k + 2) / m < k + 2
h : (k + 2) / m = 0
⊢ False
[PROOFSTEP]
have : (k + 2) = 0 * m := (Nat.div_eq_iff_eq_mul_left (minFac_pos _) (minFac_dvd _)).1 h
[GOAL]
k : ℕ
x✝ : k + 2 ≠ 0
m : ℕ := minFac (k + 2)
this✝ : (k + 2) / m < k + 2
h : (k + 2) / m = 0
this : k + 2 = 0 * m
⊢ False
[PROOFSTEP]
rw [zero_mul] at this
[GOAL]
k : ℕ
x✝ : k + 2 ≠ 0
m : ℕ := minFac (k + 2)
this✝ : (k + 2) / m < k + 2
h : (k + 2) / m = 0
this : k + 2 = 0
⊢ False
[PROOFSTEP]
exact (show k + 2 ≠ 0 by simp) this
[GOAL]
k : ℕ
x✝ : k + 2 ≠ 0
m : ℕ := minFac (k + 2)
this✝ : (k + 2) / m < k + 2
h : (k + 2) / m = 0
this : k + 2 = 0
⊢ k + 2 ≠ 0
[PROOFSTEP]
simp
[GOAL]
k : ℕ
x✝ : k + 2 ≠ 0
m : ℕ := minFac (k + 2)
this : (k + 2) / m < k + 2
h₁ : (k + 2) / m ≠ 0
⊢ List.prod (factors (k + 2)) = k + 2
[PROOFSTEP]
rw [factors, List.prod_cons, prod_factors h₁, Nat.mul_div_cancel' (minFac_dvd _)]
[GOAL]
p : ℕ
hp : Prime p
⊢ factors p = [p]
[PROOFSTEP]
have : p = p - 2 + 2 := (tsub_eq_iff_eq_add_of_le hp.two_le).mp rfl
[GOAL]
p : ℕ
hp : Prime p
this : p = p - 2 + 2
⊢ factors p = [p]
[PROOFSTEP]
rw [this, Nat.factors]
[GOAL]
p : ℕ
hp : Prime p
this : p = p - 2 + 2
⊢ (let m := minFac (p - 2 + 2);
    let_fun this := (_ : (p - 2 + 2) / minFac (p - 2 + 2) < p - 2 + 2);
    m :: factors ((p - 2 + 2) / m)) =
    [p - 2 + 2]
[PROOFSTEP]
simp only [Eq.symm this]
[GOAL]
p : ℕ
hp : Prime p
this : p = p - 2 + 2
⊢ minFac p :: factors (p / minFac p) = [p]
[PROOFSTEP]
have : Nat.minFac p = p := (Nat.prime_def_minFac.mp hp).2
[GOAL]
p : ℕ
hp : Prime p
this✝ : p = p - 2 + 2
this : minFac p = p
⊢ minFac p :: factors (p / minFac p) = [p]
[PROOFSTEP]
simp only [this, Nat.factors, Nat.div_self (Nat.Prime.pos hp)]
[GOAL]
n : ℕ
⊢ ∀ {a : ℕ}, (∀ (p : ℕ), Prime p → p ∣ n → a ≤ p) → List.Chain (fun x x_1 => x ≤ x_1) a (factors n)
[PROOFSTEP]
match n with
| 0 => simp
| 1 => simp
| k + 2 =>
  intro a h
  let m := minFac (k + 2)
  have : (k + 2) / m < (k + 2) := factors_lemma
  rw [factors]
  refine' List.Chain.cons ((le_minFac.2 h).resolve_left (by simp)) (factors_chain _)
  exact fun p pp d => minFac_le_of_dvd pp.two_le (d.trans <| div_dvd_of_dvd <| minFac_dvd _)
[GOAL]
n : ℕ
⊢ ∀ {a : ℕ}, (∀ (p : ℕ), Prime p → p ∣ 0 → a ≤ p) → List.Chain (fun x x_1 => x ≤ x_1) a (factors 0)
[PROOFSTEP]
simp
[GOAL]
n : ℕ
⊢ ∀ {a : ℕ}, (∀ (p : ℕ), Prime p → p ∣ 1 → a ≤ p) → List.Chain (fun x x_1 => x ≤ x_1) a (factors 1)
[PROOFSTEP]
simp
[GOAL]
n k : ℕ
⊢ ∀ {a : ℕ}, (∀ (p : ℕ), Prime p → p ∣ k + 2 → a ≤ p) → List.Chain (fun x x_1 => x ≤ x_1) a (factors (k + 2))
[PROOFSTEP]
intro a h
[GOAL]
n k a : ℕ
h : ∀ (p : ℕ), Prime p → p ∣ k + 2 → a ≤ p
⊢ List.Chain (fun x x_1 => x ≤ x_1) a (factors (k + 2))
[PROOFSTEP]
let m := minFac (k + 2)
[GOAL]
n k a : ℕ
h : ∀ (p : ℕ), Prime p → p ∣ k + 2 → a ≤ p
m : ℕ := minFac (k + 2)
⊢ List.Chain (fun x x_1 => x ≤ x_1) a (factors (k + 2))
[PROOFSTEP]
have : (k + 2) / m < (k + 2) := factors_lemma
[GOAL]
n k a : ℕ
h : ∀ (p : ℕ), Prime p → p ∣ k + 2 → a ≤ p
m : ℕ := minFac (k + 2)
this : (k + 2) / m < k + 2
⊢ List.Chain (fun x x_1 => x ≤ x_1) a (factors (k + 2))
[PROOFSTEP]
rw [factors]
[GOAL]
n k a : ℕ
h : ∀ (p : ℕ), Prime p → p ∣ k + 2 → a ≤ p
m : ℕ := minFac (k + 2)
this : (k + 2) / m < k + 2
⊢ List.Chain (fun x x_1 => x ≤ x_1) a
    (let m := minFac (k + 2);
    let_fun this := (_ : (k + 2) / minFac (k + 2) < k + 2);
    m :: factors ((k + 2) / m))
[PROOFSTEP]
refine' List.Chain.cons ((le_minFac.2 h).resolve_left (by simp)) (factors_chain _)
[GOAL]
n k a : ℕ
h : ∀ (p : ℕ), Prime p → p ∣ k + 2 → a ≤ p
m : ℕ := minFac (k + 2)
this : (k + 2) / m < k + 2
⊢ ¬k + 2 = 1
[PROOFSTEP]
simp
[GOAL]
n k a : ℕ
h : ∀ (p : ℕ), Prime p → p ∣ k + 2 → a ≤ p
m : ℕ := minFac (k + 2)
this : (k + 2) / m < k + 2
⊢ ∀ (p : ℕ), Prime p → p ∣ (k + 2) / minFac (k + 2) → minFac (k + 2) ≤ p
[PROOFSTEP]
exact fun p pp d => minFac_le_of_dvd pp.two_le (d.trans <| div_dvd_of_dvd <| minFac_dvd _)
[GOAL]
n : ℕ
⊢ factors (n + 2) = minFac (n + 2) :: factors ((n + 2) / minFac (n + 2))
[PROOFSTEP]
rw [factors]
[GOAL]
n : ℕ
⊢ factors n = [] ↔ n = 0 ∨ n = 1
[PROOFSTEP]
constructor
[GOAL]
case mp
n : ℕ
⊢ factors n = [] → n = 0 ∨ n = 1
[PROOFSTEP]
intro h
[GOAL]
case mpr
n : ℕ
⊢ n = 0 ∨ n = 1 → factors n = []
[PROOFSTEP]
intro h
[GOAL]
case mp
n : ℕ
h : factors n = []
⊢ n = 0 ∨ n = 1
[PROOFSTEP]
rcases n with (_ | _ | n)
[GOAL]
case mp.zero
h : factors zero = []
⊢ zero = 0 ∨ zero = 1
[PROOFSTEP]
exact Or.inl rfl
[GOAL]
case mp.succ.zero
h : factors (succ zero) = []
⊢ succ zero = 0 ∨ succ zero = 1
[PROOFSTEP]
exact Or.inr rfl
[GOAL]
case mp.succ.succ
n : ℕ
h : factors (succ (succ n)) = []
⊢ succ (succ n) = 0 ∨ succ (succ n) = 1
[PROOFSTEP]
rw [factors] at h
[GOAL]
case mp.succ.succ
n : ℕ
h :
  (let m := minFac (n + 2);
    let_fun this := (_ : (n + 2) / minFac (n + 2) < n + 2);
    m :: factors ((n + 2) / m)) =
    []
⊢ succ (succ n) = 0 ∨ succ (succ n) = 1
[PROOFSTEP]
injection h
[GOAL]
case mpr
n : ℕ
h : n = 0 ∨ n = 1
⊢ factors n = []
[PROOFSTEP]
rcases h with (rfl | rfl)
[GOAL]
case mpr.inl
⊢ factors 0 = []
[PROOFSTEP]
exact factors_zero
[GOAL]
case mpr.inr
⊢ factors 1 = []
[PROOFSTEP]
exact factors_one
[GOAL]
a b : ℕ
ha : a ≠ 0
hb : b ≠ 0
h : factors a ~ factors b
⊢ a = b
[PROOFSTEP]
simpa [prod_factors ha, prod_factors hb] using List.Perm.prod_eq h
[GOAL]
n p : ℕ
h : p ∈ factors n
⊢ p ∣ n
[PROOFSTEP]
rcases n.eq_zero_or_pos with (rfl | hn)
[GOAL]
case inl
p : ℕ
h : p ∈ factors 0
⊢ p ∣ 0
[PROOFSTEP]
exact dvd_zero p
[GOAL]
case inr
n p : ℕ
h : p ∈ factors n
hn : n > 0
⊢ p ∣ n
[PROOFSTEP]
rwa [← mem_factors_iff_dvd hn.ne' (prime_of_mem_factors h)]
[GOAL]
n p : ℕ
h : p ∈ factors n
⊢ p ≤ n
[PROOFSTEP]
rcases n.eq_zero_or_pos with (rfl | hn)
[GOAL]
case inl
p : ℕ
h : p ∈ factors 0
⊢ p ≤ 0
[PROOFSTEP]
rw [factors_zero] at h
[GOAL]
case inl
p : ℕ
h : p ∈ []
⊢ p ≤ 0
[PROOFSTEP]
cases h
[GOAL]
case inr
n p : ℕ
h : p ∈ factors n
hn : n > 0
⊢ p ≤ n
[PROOFSTEP]
exact le_of_dvd hn (dvd_of_mem_factors h)
[GOAL]
n : ℕ
l : List ℕ
h₁ : prod l = n
h₂ : ∀ (p : ℕ), p ∈ l → Prime p
⊢ l ~ factors n
[PROOFSTEP]
refine' perm_of_prod_eq_prod _ _ _
[GOAL]
case refine'_1
n : ℕ
l : List ℕ
h₁ : prod l = n
h₂ : ∀ (p : ℕ), p ∈ l → Prime p
⊢ prod l = prod (factors n)
[PROOFSTEP]
rw [h₁]
[GOAL]
case refine'_1
n : ℕ
l : List ℕ
h₁ : prod l = n
h₂ : ∀ (p : ℕ), p ∈ l → Prime p
⊢ n = prod (factors n)
[PROOFSTEP]
refine' (prod_factors _).symm
[GOAL]
case refine'_1
n : ℕ
l : List ℕ
h₁ : prod l = n
h₂ : ∀ (p : ℕ), p ∈ l → Prime p
⊢ n ≠ 0
[PROOFSTEP]
rintro rfl
[GOAL]
case refine'_1
l : List ℕ
h₂ : ∀ (p : ℕ), p ∈ l → Prime p
h₁ : prod l = 0
⊢ False
[PROOFSTEP]
rw [prod_eq_zero_iff] at h₁
[GOAL]
case refine'_1
l : List ℕ
h₂ : ∀ (p : ℕ), p ∈ l → Prime p
h₁ : 0 ∈ l
⊢ False
[PROOFSTEP]
exact Prime.ne_zero (h₂ 0 h₁) rfl
[GOAL]
case refine'_2
n : ℕ
l : List ℕ
h₁ : prod l = n
h₂ : ∀ (p : ℕ), p ∈ l → Prime p
⊢ ∀ (p : ℕ), p ∈ l → _root_.Prime p
[PROOFSTEP]
simp_rw [← prime_iff]
[GOAL]
case refine'_2
n : ℕ
l : List ℕ
h₁ : prod l = n
h₂ : ∀ (p : ℕ), p ∈ l → Prime p
⊢ ∀ (p : ℕ), p ∈ l → Prime p
[PROOFSTEP]
exact h₂
[GOAL]
case refine'_3
n : ℕ
l : List ℕ
h₁ : prod l = n
h₂ : ∀ (p : ℕ), p ∈ l → Prime p
⊢ ∀ (p : ℕ), p ∈ factors n → _root_.Prime p
[PROOFSTEP]
simp_rw [← prime_iff]
[GOAL]
case refine'_3
n : ℕ
l : List ℕ
h₁ : prod l = n
h₂ : ∀ (p : ℕ), p ∈ l → Prime p
⊢ ∀ (p : ℕ), p ∈ factors n → Prime p
[PROOFSTEP]
exact fun p => prime_of_mem_factors
[GOAL]
p : ℕ
hp : Prime p
n : ℕ
⊢ factors (p ^ n) = replicate n p
[PROOFSTEP]
symm
[GOAL]
p : ℕ
hp : Prime p
n : ℕ
⊢ replicate n p = factors (p ^ n)
[PROOFSTEP]
rw [← List.replicate_perm]
[GOAL]
p : ℕ
hp : Prime p
n : ℕ
⊢ replicate n p ~ factors (p ^ n)
[PROOFSTEP]
apply Nat.factors_unique (List.prod_replicate n p)
[GOAL]
p : ℕ
hp : Prime p
n : ℕ
⊢ ∀ (p_1 : ℕ), p_1 ∈ replicate n p → Prime p_1
[PROOFSTEP]
intro q hq
[GOAL]
p : ℕ
hp : Prime p
n q : ℕ
hq : q ∈ replicate n p
⊢ Prime q
[PROOFSTEP]
rwa [eq_of_mem_replicate hq]
[GOAL]
n p : ℕ
hpos : n ≠ 0
h : ∀ {d : ℕ}, Prime d → d ∣ n → d = p
⊢ n = p ^ length (factors n)
[PROOFSTEP]
set k := n.factors.length
[GOAL]
n p : ℕ
hpos : n ≠ 0
h : ∀ {d : ℕ}, Prime d → d ∣ n → d = p
k : ℕ := length (factors n)
⊢ n = p ^ k
[PROOFSTEP]
rw [← prod_factors hpos, ← prod_replicate k p,
  eq_replicate_of_mem fun d hd => h (prime_of_mem_factors hd) (dvd_of_mem_factors hd)]
[GOAL]
a b : ℕ
ha : a ≠ 0
hb : b ≠ 0
⊢ factors (a * b) ~ factors a ++ factors b
[PROOFSTEP]
refine' (factors_unique _ _).symm
[GOAL]
case refine'_1
a b : ℕ
ha : a ≠ 0
hb : b ≠ 0
⊢ prod (factors a ++ factors b) = a * b
[PROOFSTEP]
rw [List.prod_append, prod_factors ha, prod_factors hb]
[GOAL]
case refine'_2
a b : ℕ
ha : a ≠ 0
hb : b ≠ 0
⊢ ∀ (p : ℕ), p ∈ factors a ++ factors b → Prime p
[PROOFSTEP]
intro p hp
[GOAL]
case refine'_2
a b : ℕ
ha : a ≠ 0
hb : b ≠ 0
p : ℕ
hp : p ∈ factors a ++ factors b
⊢ Prime p
[PROOFSTEP]
rw [List.mem_append] at hp
[GOAL]
case refine'_2
a b : ℕ
ha : a ≠ 0
hb : b ≠ 0
p : ℕ
hp : p ∈ factors a ∨ p ∈ factors b
⊢ Prime p
[PROOFSTEP]
cases' hp with hp' hp'
[GOAL]
case refine'_2.inl
a b : ℕ
ha : a ≠ 0
hb : b ≠ 0
p : ℕ
hp' : p ∈ factors a
⊢ Prime p
[PROOFSTEP]
exact prime_of_mem_factors hp'
[GOAL]
case refine'_2.inr
a b : ℕ
ha : a ≠ 0
hb : b ≠ 0
p : ℕ
hp' : p ∈ factors b
⊢ Prime p
[PROOFSTEP]
exact prime_of_mem_factors hp'
[GOAL]
a b : ℕ
hab : coprime a b
⊢ factors (a * b) ~ factors a ++ factors b
[PROOFSTEP]
rcases a.eq_zero_or_pos with (rfl | ha)
[GOAL]
case inl
b : ℕ
hab : coprime 0 b
⊢ factors (0 * b) ~ factors 0 ++ factors b
[PROOFSTEP]
simp [(coprime_zero_left _).mp hab]
[GOAL]
case inr
a b : ℕ
hab : coprime a b
ha : a > 0
⊢ factors (a * b) ~ factors a ++ factors b
[PROOFSTEP]
rcases b.eq_zero_or_pos with (rfl | hb)
[GOAL]
case inr.inl
a : ℕ
ha : a > 0
hab : coprime a 0
⊢ factors (a * 0) ~ factors a ++ factors 0
[PROOFSTEP]
simp [(coprime_zero_right _).mp hab]
[GOAL]
case inr.inr
a b : ℕ
hab : coprime a b
ha : a > 0
hb : b > 0
⊢ factors (a * b) ~ factors a ++ factors b
[PROOFSTEP]
exact perm_factors_mul ha.ne' hb.ne'
[GOAL]
n k : ℕ
h : k ≠ 0
⊢ factors n <+ factors (n * k)
[PROOFSTEP]
cases' n with hn
[GOAL]
case zero
k : ℕ
h : k ≠ 0
⊢ factors zero <+ factors (zero * k)
[PROOFSTEP]
simp [zero_mul]
[GOAL]
case succ
k : ℕ
h : k ≠ 0
hn : ℕ
⊢ factors (succ hn) <+ factors (succ hn * k)
[PROOFSTEP]
apply sublist_of_subperm_of_sorted _ (factors_sorted _) (factors_sorted _)
[GOAL]
k : ℕ
h : k ≠ 0
hn : ℕ
⊢ factors (succ hn) <+~ factors (succ hn * k)
[PROOFSTEP]
simp [(perm_factors_mul (Nat.succ_ne_zero _) h).subperm_left]
[GOAL]
k : ℕ
h : k ≠ 0
hn : ℕ
⊢ factors (succ hn) <+~ factors (succ hn) ++ factors k
[PROOFSTEP]
exact (sublist_append_left _ _).subperm
[GOAL]
n k : ℕ
h : n ∣ k
h' : k ≠ 0
⊢ factors n <+ factors k
[PROOFSTEP]
obtain ⟨a, rfl⟩ := h
[GOAL]
case intro
n a : ℕ
h' : n * a ≠ 0
⊢ factors n <+ factors (n * a)
[PROOFSTEP]
exact factors_sublist_right (right_ne_zero_of_mul h')
[GOAL]
a b : ℕ
ha : a ≠ 0
h : factors a <+~ factors b
⊢ a ∣ b
[PROOFSTEP]
rcases b.eq_zero_or_pos with (rfl | hb)
[GOAL]
case inl
a : ℕ
ha : a ≠ 0
h : factors a <+~ factors 0
⊢ a ∣ 0
[PROOFSTEP]
exact dvd_zero _
[GOAL]
case inr
a b : ℕ
ha : a ≠ 0
h : factors a <+~ factors b
hb : b > 0
⊢ a ∣ b
[PROOFSTEP]
rcases a with (_ | _ | a)
[GOAL]
case inr.zero
b : ℕ
hb : b > 0
ha : zero ≠ 0
h : factors zero <+~ factors b
⊢ zero ∣ b
[PROOFSTEP]
exact (ha rfl).elim
[GOAL]
case inr.succ.zero
b : ℕ
hb : b > 0
ha : succ zero ≠ 0
h : factors (succ zero) <+~ factors b
⊢ succ zero ∣ b
[PROOFSTEP]
exact
  one_dvd
    _
      --Porting note: previous proof
        --use (b.factors.diff a.succ.succ.factors).prod
[GOAL]
case inr.succ.succ
b : ℕ
hb : b > 0
a : ℕ
ha : succ (succ a) ≠ 0
h : factors (succ (succ a)) <+~ factors b
⊢ succ (succ a) ∣ b
[PROOFSTEP]
use(@List.diff _ instBEq b.factors a.succ.succ.factors).prod
[GOAL]
case h
b : ℕ
hb : b > 0
a : ℕ
ha : succ (succ a) ≠ 0
h : factors (succ (succ a)) <+~ factors b
⊢ b = succ (succ a) * prod (List.diff (factors b) (factors (succ (succ a))))
[PROOFSTEP]
nth_rw 1 [← Nat.prod_factors ha]
[GOAL]
case h
b : ℕ
hb : b > 0
a : ℕ
ha : succ (succ a) ≠ 0
h : factors (succ (succ a)) <+~ factors b
⊢ b = prod (factors (succ (succ a))) * prod (List.diff (factors b) (factors (succ (succ a))))
[PROOFSTEP]
rw [← List.prod_append, List.Perm.prod_eq <| List.subperm_append_diff_self_of_count_le <| List.subperm_ext_iff.mp h,
  Nat.prod_factors hb.ne']
[GOAL]
a b : ℕ
ha : a ≠ 0
hb : b ≠ 0
p : ℕ
⊢ p ∈ factors (a * b) ↔ p ∈ factors a ∨ p ∈ factors b
[PROOFSTEP]
rw [mem_factors (mul_ne_zero ha hb), mem_factors ha, mem_factors hb, ← and_or_left]
[GOAL]
a b : ℕ
ha : a ≠ 0
hb : b ≠ 0
p : ℕ
⊢ Prime p ∧ p ∣ a * b ↔ Prime p ∧ (p ∣ a ∨ p ∣ b)
[PROOFSTEP]
simpa only [and_congr_right_iff] using Prime.dvd_mul
[GOAL]
a b : ℕ
hab : coprime a b
⊢ List.Disjoint (factors a) (factors b)
[PROOFSTEP]
intro q hqa hqb
[GOAL]
a b : ℕ
hab : coprime a b
q : ℕ
hqa : q ∈ factors a
hqb : q ∈ factors b
⊢ False
[PROOFSTEP]
apply not_prime_one
[GOAL]
a b : ℕ
hab : coprime a b
q : ℕ
hqa : q ∈ factors a
hqb : q ∈ factors b
⊢ Prime 1
[PROOFSTEP]
rw [← eq_one_of_dvd_coprimes hab (dvd_of_mem_factors hqa) (dvd_of_mem_factors hqb)]
[GOAL]
a b : ℕ
hab : coprime a b
q : ℕ
hqa : q ∈ factors a
hqb : q ∈ factors b
⊢ Prime q
[PROOFSTEP]
exact prime_of_mem_factors hqa
[GOAL]
a b : ℕ
hab : coprime a b
p : ℕ
⊢ p ∈ factors (a * b) ↔ p ∈ factors a ∪ factors b
[PROOFSTEP]
rcases a.eq_zero_or_pos with (rfl | ha)
[GOAL]
case inl
b p : ℕ
hab : coprime 0 b
⊢ p ∈ factors (0 * b) ↔ p ∈ factors 0 ∪ factors b
[PROOFSTEP]
simp [(coprime_zero_left _).mp hab]
[GOAL]
case inr
a b : ℕ
hab : coprime a b
p : ℕ
ha : a > 0
⊢ p ∈ factors (a * b) ↔ p ∈ factors a ∪ factors b
[PROOFSTEP]
rcases b.eq_zero_or_pos with (rfl | hb)
[GOAL]
case inr.inl
a p : ℕ
ha : a > 0
hab : coprime a 0
⊢ p ∈ factors (a * 0) ↔ p ∈ factors a ∪ factors 0
[PROOFSTEP]
simp [(coprime_zero_right _).mp hab]
[GOAL]
case inr.inr
a b : ℕ
hab : coprime a b
p : ℕ
ha : a > 0
hb : b > 0
⊢ p ∈ factors (a * b) ↔ p ∈ factors a ∪ factors b
[PROOFSTEP]
rw [mem_factors_mul ha.ne' hb.ne', List.mem_union_iff]
[GOAL]
p a b : ℕ
hpa : p ∈ factors a
hb : b ≠ 0
⊢ p ∈ factors (a * b)
[PROOFSTEP]
rcases eq_or_ne a 0 with (rfl | ha)
[GOAL]
case inl
p b : ℕ
hb : b ≠ 0
hpa : p ∈ factors 0
⊢ p ∈ factors (0 * b)
[PROOFSTEP]
simp at hpa
[GOAL]
case inr
p a b : ℕ
hpa : p ∈ factors a
hb : b ≠ 0
ha : a ≠ 0
⊢ p ∈ factors (a * b)
[PROOFSTEP]
apply (mem_factors_mul ha hb).2 (Or.inl hpa)
[GOAL]
p a b : ℕ
hpb : p ∈ factors b
ha : a ≠ 0
⊢ p ∈ factors (a * b)
[PROOFSTEP]
rw [mul_comm]
[GOAL]
p a b : ℕ
hpb : p ∈ factors b
ha : a ≠ 0
⊢ p ∈ factors (b * a)
[PROOFSTEP]
exact mem_factors_mul_left hpb ha