representation_theory.ActionMathlib.RepresentationTheory.Action.Basic

This file has been ported!

Changes since the initial port

The following section lists changes to this file in mathlib3 and mathlib4 that occured after the initial port. Most recent changes are shown first. Hovering over a commit will show all commits associated with the same mathlib3 commit.

Changes in mathlib3

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(last sync)

Changes in mathlib3port

mathlib3
mathlib3port
Diff
@@ -318,7 +318,8 @@ def forget : Action V G ⥤ V where
 #align Action.forget Action.forget
 -/
 
-instance : Faithful (forget V G) where map_injective' X Y f g w := Hom.ext _ _ w
+instance : CategoryTheory.Functor.Faithful (forget V G)
+    where map_injective' X Y f g w := Hom.ext _ _ w
 
 instance [ConcreteCategory V] : ConcreteCategory (Action V G)
     where forget := forget V G ⋙ ConcreteCategory.forget V
@@ -628,8 +629,8 @@ def forgetMonoidal : MonoidalFunctor (Action V G) V :=
 -/
 
 #print Action.forgetMonoidal_faithful /-
-instance forgetMonoidal_faithful : Faithful (forgetMonoidal V G).toFunctor := by
-  change faithful (forget V G); infer_instance
+instance forgetMonoidal_faithful : CategoryTheory.Functor.Faithful (forgetMonoidal V G).toFunctor :=
+  by change faithful (forget V G); infer_instance
 #align Action.forget_monoidal_faithful Action.forgetMonoidal_faithful
 -/
 
@@ -649,8 +650,8 @@ def forgetBraided : BraidedFunctor (Action V G) V :=
 -/
 
 #print Action.forgetBraided_faithful /-
-instance forgetBraided_faithful : Faithful (forgetBraided V G).toFunctor := by
-  change faithful (forget V G); infer_instance
+instance forgetBraided_faithful : CategoryTheory.Functor.Faithful (forgetBraided V G).toFunctor :=
+  by change faithful (forget V G); infer_instance
 #align Action.forget_braided_faithful Action.forgetBraided_faithful
 -/
 
@@ -684,7 +685,8 @@ def functorCategoryMonoidalEquivalence : MonoidalFunctor (Action V G) (SingleObj
 #align Action.functor_category_monoidal_equivalence Action.functorCategoryMonoidalEquivalence
 -/
 
-instance : IsEquivalence (functorCategoryMonoidalEquivalence V G).toFunctor := by
+instance :
+    CategoryTheory.Functor.IsEquivalence (functorCategoryMonoidalEquivalence V G).toFunctor := by
   change is_equivalence (Action.functorCategoryEquivalence _ _).Functor; infer_instance
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
Diff
@@ -3,7 +3,7 @@ Copyright (c) 2020 Scott Morrison. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Scott Morrison
 -/
-import Algebra.Category.Group.Basic
+import Algebra.Category.GroupCat.Basic
 import CategoryTheory.SingleObj
 import CategoryTheory.Limits.FunctorCategory
 import CategoryTheory.Limits.Preserves.Basic
@@ -13,7 +13,7 @@ import CategoryTheory.Monoidal.Transport
 import CategoryTheory.Monoidal.Rigid.OfEquivalence
 import CategoryTheory.Monoidal.Rigid.FunctorCategory
 import CategoryTheory.Monoidal.Linear
-import CategoryTheory.Monoidal.Braided
+import CategoryTheory.Monoidal.Braided.Basic
 import CategoryTheory.Monoidal.Types.Symmetric
 import CategoryTheory.Abelian.FunctorCategory
 import CategoryTheory.Abelian.Transfer
Diff
@@ -181,7 +181,7 @@ def mkIso {M N : Action V G} (f : M.V ≅ N.V) (comm : ∀ g : G, M.ρ g ≫ f.H
       comm' := comm }
   inv :=
     { Hom := f.inv
-      comm' := fun g => by have w := comm g =≫ f.inv; simp at w ; simp [w] }
+      comm' := fun g => by have w := comm g =≫ f.inv; simp at w; simp [w] }
 #align Action.mk_iso Action.mkIso
 -/
 
Diff
@@ -1035,7 +1035,7 @@ each factor. -/
 @[simps]
 def diagonalSucc (G : Type u) [Monoid G] (n : ℕ) :
     diagonal G (n + 1) ≅ leftRegular G ⊗ diagonal G n :=
-  mkIso (Equiv.piFinSuccAboveEquiv _ 0).toIso fun g => rfl
+  mkIso (Equiv.piFinSuccAbove _ 0).toIso fun g => rfl
 #align Action.diagonal_succ Action.diagonalSucc
 -/
 
Diff
@@ -544,11 +544,11 @@ theorem tensor_rho {X Y : Action V G} {g : G} : (X ⊗ Y).ρ g = X.ρ g ⊗ Y.ρ
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
-#print Action.tensorHom /-
+#print Action.tensor_hom /-
 @[simp]
-theorem tensorHom {W X Y Z : Action V G} (f : W ⟶ X) (g : Y ⟶ Z) : (f ⊗ g).Hom = f.Hom ⊗ g.Hom :=
+theorem tensor_hom {W X Y Z : Action V G} (f : W ⟶ X) (g : Y ⟶ Z) : (f ⊗ g).Hom = f.Hom ⊗ g.Hom :=
   rfl
-#align Action.tensor_hom Action.tensorHom
+#align Action.tensor_hom Action.tensor_hom
 -/
 
 #print Action.associator_hom_hom /-
Diff
@@ -3,22 +3,22 @@ Copyright (c) 2020 Scott Morrison. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Scott Morrison
 -/
-import Mathbin.Algebra.Category.Group.Basic
-import Mathbin.CategoryTheory.SingleObj
-import Mathbin.CategoryTheory.Limits.FunctorCategory
-import Mathbin.CategoryTheory.Limits.Preserves.Basic
-import Mathbin.CategoryTheory.Adjunction.Limits
-import Mathbin.CategoryTheory.Monoidal.FunctorCategory
-import Mathbin.CategoryTheory.Monoidal.Transport
-import Mathbin.CategoryTheory.Monoidal.Rigid.OfEquivalence
-import Mathbin.CategoryTheory.Monoidal.Rigid.FunctorCategory
-import Mathbin.CategoryTheory.Monoidal.Linear
-import Mathbin.CategoryTheory.Monoidal.Braided
-import Mathbin.CategoryTheory.Monoidal.Types.Symmetric
-import Mathbin.CategoryTheory.Abelian.FunctorCategory
-import Mathbin.CategoryTheory.Abelian.Transfer
-import Mathbin.CategoryTheory.Conj
-import Mathbin.CategoryTheory.Linear.FunctorCategory
+import Algebra.Category.Group.Basic
+import CategoryTheory.SingleObj
+import CategoryTheory.Limits.FunctorCategory
+import CategoryTheory.Limits.Preserves.Basic
+import CategoryTheory.Adjunction.Limits
+import CategoryTheory.Monoidal.FunctorCategory
+import CategoryTheory.Monoidal.Transport
+import CategoryTheory.Monoidal.Rigid.OfEquivalence
+import CategoryTheory.Monoidal.Rigid.FunctorCategory
+import CategoryTheory.Monoidal.Linear
+import CategoryTheory.Monoidal.Braided
+import CategoryTheory.Monoidal.Types.Symmetric
+import CategoryTheory.Abelian.FunctorCategory
+import CategoryTheory.Abelian.Transfer
+import CategoryTheory.Conj
+import CategoryTheory.Linear.FunctorCategory
 
 #align_import representation_theory.Action from "leanprover-community/mathlib"@"c20927220ef87bb4962ba08bf6da2ce3cf50a6dd"
 
Diff
@@ -124,8 +124,6 @@ structure Hom (M N : Action V G) where
 #align Action.hom Action.Hom
 -/
 
-restate_axiom hom.comm'
-
 namespace Hom
 
 #print Action.Hom.id /-
Diff
@@ -80,8 +80,8 @@ def ρAut {G : GroupCat.{u}} (A : Action V (MonCat.of G)) : G ⟶ GroupCat.of (A
   toFun g :=
     { Hom := A.ρ g
       inv := A.ρ (g⁻¹ : G)
-      hom_inv_id' := (A.ρ.map_mul (g⁻¹ : G) g).symm.trans (by rw [inv_mul_self, ρ_one])
-      inv_hom_id' := (A.ρ.map_mul g (g⁻¹ : G)).symm.trans (by rw [mul_inv_self, ρ_one]) }
+      hom_inv_id' := (A.ρ.map_hMul (g⁻¹ : G) g).symm.trans (by rw [inv_mul_self, ρ_one])
+      inv_hom_id' := (A.ρ.map_hMul g (g⁻¹ : G)).symm.trans (by rw [mul_inv_self, ρ_one]) }
   map_one' := by ext; exact A.ρ.map_one
   map_mul' x y := by ext; exact A.ρ.map_mul x y
 #align Action.ρ_Aut Action.ρAut
@@ -210,7 +210,7 @@ def functor : Action V G ⥤ SingleObj G ⥤ V
     { obj := fun _ => M.V
       map := fun _ _ g => M.ρ g
       map_id' := fun _ => M.ρ.map_one
-      map_comp' := fun _ _ _ g h => M.ρ.map_mul h g }
+      map_comp' := fun _ _ _ g h => M.ρ.map_hMul h g }
   map M N f :=
     { app := fun _ => f.Hom
       naturality' := fun _ _ g => f.comm g }
@@ -462,7 +462,7 @@ instance : Linear R (Action V G)
       zero_smul := by intros; ext; exact zero_smul _ _
       add_smul := by intros; ext; exact add_smul _ _ _
       smul_add := by intros; ext; exact smul_add _ _ _
-      mul_smul := by intros; ext; exact mul_smul _ _ _ }
+      hMul_smul := by intros; ext; exact mul_smul _ _ _ }
   smul_comp' := by intros; ext; exact linear.smul_comp _ _ _ _ _ _
   comp_smul' := by intros; ext; exact linear.comp_smul _ _ _ _ _ _
 
Diff
@@ -2,11 +2,6 @@
 Copyright (c) 2020 Scott Morrison. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Scott Morrison
-
-! This file was ported from Lean 3 source module representation_theory.Action
-! leanprover-community/mathlib commit c20927220ef87bb4962ba08bf6da2ce3cf50a6dd
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathbin.Algebra.Category.Group.Basic
 import Mathbin.CategoryTheory.SingleObj
@@ -25,6 +20,8 @@ import Mathbin.CategoryTheory.Abelian.Transfer
 import Mathbin.CategoryTheory.Conj
 import Mathbin.CategoryTheory.Linear.FunctorCategory
 
+#align_import representation_theory.Action from "leanprover-community/mathlib"@"c20927220ef87bb4962ba08bf6da2ce3cf50a6dd"
+
 /-!
 # `Action V G`, the category of actions of a monoid `G` inside some category `V`.
 
Diff
@@ -955,7 +955,7 @@ def ofMulActionLimitCone {ι : Type v} (G : Type max v u) [Monoid G] (F : ι →
     { lift := fun s =>
         { Hom := fun x i => (s.π.app ⟨i⟩).Hom x
           comm' := fun g => by
-            ext (x j)
+            ext x j
             dsimp
             exact congr_fun ((s.π.app ⟨j⟩).comm g) x }
       fac := fun s j => by
@@ -964,7 +964,7 @@ def ofMulActionLimitCone {ι : Type v} (G : Type max v u) [Monoid G] (F : ι →
         congr
         rw [discrete.mk_as]
       uniq := fun s f h => by
-        ext (x j)
+        ext x j
         dsimp at *
         rw [← h ⟨j⟩]
         congr }
Diff
@@ -69,10 +69,13 @@ namespace Action
 
 variable {V}
 
+#print Action.ρ_one /-
 @[simp]
 theorem ρ_one {G : MonCat.{u}} (A : Action V G) : A.ρ 1 = 𝟙 A.V := by rw [MonoidHom.map_one]; rfl
 #align Action.ρ_one Action.ρ_one
+-/
 
+#print Action.ρAut /-
 /-- When a group acts, we can lift the action to the group of automorphisms. -/
 @[simps]
 def ρAut {G : GroupCat.{u}} (A : Action V (MonCat.of G)) : G ⟶ GroupCat.of (Aut A.V)
@@ -85,6 +88,7 @@ def ρAut {G : GroupCat.{u}} (A : Action V (MonCat.of G)) : G ⟶ GroupCat.of (A
   map_one' := by ext; exact A.ρ.map_one
   map_mul' x y := by ext; exact A.ρ.map_mul x y
 #align Action.ρ_Aut Action.ρAut
+-/
 
 variable (G : MonCat.{u})
 
@@ -170,6 +174,7 @@ theorem comp_hom {M N K : Action V G} (f : M ⟶ N) (g : N ⟶ K) :
 #align Action.comp_hom Action.comp_hom
 -/
 
+#print Action.mkIso /-
 /-- Construct an isomorphism of `G` actions/representations
 from an isomorphism of the the underlying objects,
 where the forward direction commutes with the group action. -/
@@ -183,6 +188,7 @@ def mkIso {M N : Action V G} (f : M.V ≅ N.V) (comm : ∀ g : G, M.ρ g ≫ f.H
     { Hom := f.inv
       comm' := fun g => by have w := comm g =≫ f.inv; simp at w ; simp [w] }
 #align Action.mk_iso Action.mkIso
+-/
 
 #print Action.isIso_of_hom_isIso /-
 instance (priority := 100) isIso_of_hom_isIso {M N : Action V G} (f : M ⟶ N) [IsIso f.Hom] :
@@ -190,9 +196,11 @@ instance (priority := 100) isIso_of_hom_isIso {M N : Action V G} (f : M ⟶ N) [
 #align Action.is_iso_of_hom_is_iso Action.isIso_of_hom_isIso
 -/
 
+#print Action.isIso_hom_mk /-
 instance isIso_hom_mk {M N : Action V G} (f : M.V ⟶ N.V) [IsIso f] (w) : @IsIso _ _ M N ⟨f, w⟩ :=
   IsIso.of_iso (mkIso (asIso f) w)
 #align Action.is_iso_hom_mk Action.isIso_hom_mk
+-/
 
 namespace FunctorCategoryEquivalence
 
@@ -253,6 +261,7 @@ open FunctorCategoryEquivalence
 
 variable (V G)
 
+#print Action.functorCategoryEquivalence /-
 /-- The category of actions of `G` in the category `V`
 is equivalent to the functor category `single_obj G ⥤ V`.
 -/
@@ -263,6 +272,7 @@ def functorCategoryEquivalence : Action V G ≌ SingleObj G ⥤ V
   unitIso := unitIso
   counitIso := counitIso
 #align Action.functor_category_equivalence Action.functorCategoryEquivalence
+-/
 
 attribute [simps] functor_category_equivalence
 
@@ -318,15 +328,19 @@ instance : Faithful (forget V G) where map_injective' X Y f g w := Hom.ext _ _ w
 instance [ConcreteCategory V] : ConcreteCategory (Action V G)
     where forget := forget V G ⋙ ConcreteCategory.forget V
 
+#print Action.hasForgetToV /-
 instance hasForgetToV [ConcreteCategory V] : HasForget₂ (Action V G) V where forget₂ := forget V G
 #align Action.has_forget_to_V Action.hasForgetToV
+-/
 
+#print Action.functorCategoryEquivalenceCompEvaluation /-
 /-- The forgetful functor is intertwined by `functor_category_equivalence` with
 evaluation at `punit.star`. -/
 def functorCategoryEquivalenceCompEvaluation :
     (functorCategoryEquivalence V G).Functor ⋙ (evaluation _ _).obj PUnit.unit ≅ forget V G :=
   Iso.refl _
 #align Action.functor_category_equivalence_comp_evaluation Action.functorCategoryEquivalenceCompEvaluation
+-/
 
 noncomputable instance [HasLimits V] : Limits.PreservesLimits (forget V G) :=
   Limits.preservesLimitsOfNatIso (Action.functorCategoryEquivalenceCompEvaluation V G)
@@ -337,10 +351,12 @@ noncomputable instance [HasColimits V] : PreservesColimits (forget V G) :=
 -- TODO construct categorical images?
 end Forget
 
+#print Action.Iso.conj_ρ /-
 theorem Iso.conj_ρ {M N : Action V G} (f : M ≅ N) (g : G) :
     N.ρ g = ((forget V G).mapIso f).conj (M.ρ g) := by rw [iso.conj_apply, iso.eq_inv_comp];
   simp [f.hom.comm']
 #align Action.iso.conj_ρ Action.Iso.conj_ρ
+-/
 
 section HasZeroMorphisms
 
@@ -352,16 +368,22 @@ instance : HasZeroMorphisms (Action V G)
   comp_zero P Q f R := by ext1; simp
   zero_comp P Q R f := by ext1; simp
 
+#print Action.forget_preservesZeroMorphisms /-
 instance forget_preservesZeroMorphisms : Functor.PreservesZeroMorphisms (forget V G) where
 #align Action.forget_preserves_zero_morphisms Action.forget_preservesZeroMorphisms
+-/
 
+#print Action.forget₂_preservesZeroMorphisms /-
 instance forget₂_preservesZeroMorphisms [ConcreteCategory V] :
     Functor.PreservesZeroMorphisms (forget₂ (Action V G) V) where
 #align Action.forget₂_preserves_zero_morphisms Action.forget₂_preservesZeroMorphisms
+-/
 
+#print Action.functorCategoryEquivalence_preservesZeroMorphisms /-
 instance functorCategoryEquivalence_preservesZeroMorphisms :
     Functor.PreservesZeroMorphisms (functorCategoryEquivalence V G).Functor where
 #align Action.functor_category_equivalence_preserves_zero_morphisms Action.functorCategoryEquivalence_preservesZeroMorphisms
+-/
 
 end HasZeroMorphisms
 
@@ -383,36 +405,50 @@ instance : Preadditive (Action V G)
   add_comp := by intros; ext; exact preadditive.add_comp _ _ _ _ _ _
   comp_add := by intros; ext; exact preadditive.comp_add _ _ _ _ _ _
 
+#print Action.forget_additive /-
 instance forget_additive : Functor.Additive (forget V G) where
 #align Action.forget_additive Action.forget_additive
+-/
 
+#print Action.forget₂_additive /-
 instance forget₂_additive [ConcreteCategory V] : Functor.Additive (forget₂ (Action V G) V) where
 #align Action.forget₂_additive Action.forget₂_additive
+-/
 
+#print Action.functorCategoryEquivalence_additive /-
 instance functorCategoryEquivalence_additive :
     Functor.Additive (functorCategoryEquivalence V G).Functor where
 #align Action.functor_category_equivalence_additive Action.functorCategoryEquivalence_additive
+-/
 
+#print Action.zero_hom /-
 @[simp]
 theorem zero_hom {X Y : Action V G} : (0 : X ⟶ Y).Hom = 0 :=
   rfl
 #align Action.zero_hom Action.zero_hom
+-/
 
+#print Action.neg_hom /-
 @[simp]
 theorem neg_hom {X Y : Action V G} (f : X ⟶ Y) : (-f).Hom = -f.Hom :=
   rfl
 #align Action.neg_hom Action.neg_hom
+-/
 
+#print Action.add_hom /-
 @[simp]
 theorem add_hom {X Y : Action V G} (f g : X ⟶ Y) : (f + g).Hom = f.Hom + g.Hom :=
   rfl
 #align Action.add_hom Action.add_hom
+-/
 
+#print Action.sum_hom /-
 @[simp]
 theorem sum_hom {X Y : Action V G} {ι : Type _} (f : ι → (X ⟶ Y)) (s : Finset ι) :
     (s.Sum f).Hom = s.Sum fun i => (f i).Hom :=
   (forget V G).map_sum f s
 #align Action.sum_hom Action.sum_hom
+-/
 
 end Preadditive
 
@@ -433,29 +469,39 @@ instance : Linear R (Action V G)
   smul_comp' := by intros; ext; exact linear.smul_comp _ _ _ _ _ _
   comp_smul' := by intros; ext; exact linear.comp_smul _ _ _ _ _ _
 
+#print Action.forget_linear /-
 instance forget_linear : Functor.Linear R (forget V G) where
 #align Action.forget_linear Action.forget_linear
+-/
 
+#print Action.forget₂_linear /-
 instance forget₂_linear [ConcreteCategory V] : Functor.Linear R (forget₂ (Action V G) V) where
 #align Action.forget₂_linear Action.forget₂_linear
+-/
 
+#print Action.functorCategoryEquivalence_linear /-
 instance functorCategoryEquivalence_linear :
     Functor.Linear R (functorCategoryEquivalence V G).Functor where
 #align Action.functor_category_equivalence_linear Action.functorCategoryEquivalence_linear
+-/
 
+#print Action.smul_hom /-
 @[simp]
 theorem smul_hom {X Y : Action V G} (r : R) (f : X ⟶ Y) : (r • f).Hom = r • f.Hom :=
   rfl
 #align Action.smul_hom Action.smul_hom
+-/
 
 end Linear
 
 section Abelian
 
+#print Action.abelianAux /-
 /-- Auxilliary construction for the `abelian (Action V G)` instance. -/
 def abelianAux : Action V G ≌ ULift.{u} (SingleObj G) ⥤ V :=
   (functorCategoryEquivalence V G).trans (Equivalence.congrLeft ULift.equivalence)
 #align Action.abelian_aux Action.abelianAux
+-/
 
 noncomputable instance [Abelian V] : Abelian (Action V G) :=
   abelianOfEquivalence abelianAux.Functor
@@ -476,10 +522,12 @@ theorem tensorUnit_v : (𝟙_ (Action V G)).V = 𝟙_ V :=
 #align Action.tensor_unit_V Action.tensorUnit_v
 -/
 
+#print Action.tensorUnit_rho /-
 @[simp]
 theorem tensorUnit_rho {g : G} : (𝟙_ (Action V G)).ρ g = 𝟙 (𝟙_ V) :=
   rfl
 #align Action.tensor_unit_rho Action.tensorUnit_rho
+-/
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
@@ -492,10 +540,12 @@ theorem tensor_v {X Y : Action V G} : (X ⊗ Y).V = X.V ⊗ Y.V :=
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+#print Action.tensor_rho /-
 @[simp]
 theorem tensor_rho {X Y : Action V G} {g : G} : (X ⊗ Y).ρ g = X.ρ g ⊗ Y.ρ g :=
   rfl
 #align Action.tensor_rho Action.tensor_rho
+-/
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
@@ -560,6 +610,7 @@ theorem rightUnitor_inv_hom {X : Action V G} : Hom.hom (ρ_ X).inv = (ρ_ X.V).i
 #align Action.right_unitor_inv_hom Action.rightUnitor_inv_hom
 -/
 
+#print Action.tensorUnitIso /-
 /-- Given an object `X` isomorphic to the tensor unit of `V`, `X` equipped with the trivial action
 is isomorphic to the tensor unit of `Action V G`. -/
 def tensorUnitIso {X : V} (f : 𝟙_ V ≅ X) : 𝟙_ (Action V G) ≅ Action.mk X 1 :=
@@ -567,6 +618,7 @@ def tensorUnitIso {X : V} (f : 𝟙_ V ≅ X) : 𝟙_ (Action V G) ≅ Action.mk
     simp only [MonoidHom.one_apply, End.one_def, category.id_comp f.hom, tensor_unit_rho,
       category.comp_id]
 #align Action.tensor_unit_iso Action.tensorUnitIso
+-/
 
 variable (V G)
 
@@ -593,11 +645,13 @@ variable [BraidedCategory V]
 instance : BraidedCategory (Action V G) :=
   braidedCategoryOfFaithful (forgetMonoidal V G) (fun X Y => mkIso (β_ _ _) (by tidy)) (by tidy)
 
+#print Action.forgetBraided /-
 /-- When `V` is braided the forgetful functor `Action V G` to `V` is braided. -/
 @[simps]
 def forgetBraided : BraidedFunctor (Action V G) V :=
   { forgetMonoidal _ _ with }
 #align Action.forget_braided Action.forgetBraided
+-/
 
 #print Action.forgetBraided_faithful /-
 instance forgetBraided_faithful : Faithful (forgetBraided V G).toFunctor := by
@@ -642,6 +696,7 @@ instance : IsEquivalence (functorCategoryMonoidalEquivalence V G).toFunctor := b
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+#print Action.functorCategoryMonoidalEquivalence.μ_app /-
 @[simp]
 theorem functorCategoryMonoidalEquivalence.μ_app (A B : Action V G) :
     ((functorCategoryMonoidalEquivalence V G).μ A B).app PUnit.unit = 𝟙 _ :=
@@ -651,7 +706,9 @@ theorem functorCategoryMonoidalEquivalence.μ_app (A B : Action V G) :
   show (𝟙 A.V ⊗ 𝟙 B.V) ≫ 𝟙 (A.V ⊗ B.V) ≫ (𝟙 A.V ⊗ 𝟙 B.V) = 𝟙 (A.V ⊗ B.V)
   simp only [monoidal_category.tensor_id, category.comp_id]
 #align Action.functor_category_monoidal_equivalence.μ_app Action.functorCategoryMonoidalEquivalence.μ_app
+-/
 
+#print Action.functorCategoryMonoidalEquivalence.μIso_inv_app /-
 @[simp]
 theorem functorCategoryMonoidalEquivalence.μIso_inv_app (A B : Action V G) :
     ((functorCategoryMonoidalEquivalence V G).μIso A B).inv.app PUnit.unit = 𝟙 _ :=
@@ -661,7 +718,9 @@ theorem functorCategoryMonoidalEquivalence.μIso_inv_app (A B : Action V G) :
   rw [category.comp_id, nat_iso.app_hom, monoidal_functor.μ_iso_hom,
     functor_category_monoidal_equivalence.μ_app]
 #align Action.functor_category_monoidal_equivalence.μ_iso_inv_app Action.functorCategoryMonoidalEquivalence.μIso_inv_app
+-/
 
+#print Action.functorCategoryMonoidalEquivalence.ε_app /-
 @[simp]
 theorem functorCategoryMonoidalEquivalence.ε_app :
     (functorCategoryMonoidalEquivalence V G).ε.app PUnit.unit = 𝟙 _ :=
@@ -672,42 +731,55 @@ theorem functorCategoryMonoidalEquivalence.ε_app :
   rw [nat_iso.is_iso_inv_app, category.id_comp]
   exact is_iso.inv_id
 #align Action.functor_category_monoidal_equivalence.ε_app Action.functorCategoryMonoidalEquivalence.ε_app
+-/
 
+#print Action.functorCategoryMonoidalEquivalence.inv_counit_app_hom /-
 @[simp]
 theorem functorCategoryMonoidalEquivalence.inv_counit_app_hom (A : Action V G) :
     ((functorCategoryMonoidalEquivalence _ _).inv.Adjunction.counit.app A).Hom = 𝟙 _ :=
   rfl
 #align Action.functor_category_monoidal_equivalence.inv_counit_app_hom Action.functorCategoryMonoidalEquivalence.inv_counit_app_hom
+-/
 
+#print Action.functorCategoryMonoidalEquivalence.counit_app /-
 @[simp]
 theorem functorCategoryMonoidalEquivalence.counit_app (A : SingleObj G ⥤ V) :
     ((functorCategoryMonoidalEquivalence _ _).Adjunction.counit.app A).app PUnit.unit = 𝟙 _ :=
   rfl
 #align Action.functor_category_monoidal_equivalence.counit_app Action.functorCategoryMonoidalEquivalence.counit_app
+-/
 
+#print Action.functorCategoryMonoidalEquivalence.inv_unit_app_app /-
 @[simp]
 theorem functorCategoryMonoidalEquivalence.inv_unit_app_app (A : SingleObj G ⥤ V) :
     ((functorCategoryMonoidalEquivalence _ _).inv.Adjunction.Unit.app A).app PUnit.unit = 𝟙 _ :=
   rfl
 #align Action.functor_category_monoidal_equivalence.inv_unit_app_app Action.functorCategoryMonoidalEquivalence.inv_unit_app_app
+-/
 
+#print Action.functorCategoryMonoidalEquivalence.unit_app_hom /-
 @[simp]
 theorem functorCategoryMonoidalEquivalence.unit_app_hom (A : Action V G) :
     ((functorCategoryMonoidalEquivalence _ _).Adjunction.Unit.app A).Hom = 𝟙 _ :=
   rfl
 #align Action.functor_category_monoidal_equivalence.unit_app_hom Action.functorCategoryMonoidalEquivalence.unit_app_hom
+-/
 
+#print Action.functorCategoryMonoidalEquivalence.functor_map /-
 @[simp]
 theorem functorCategoryMonoidalEquivalence.functor_map {A B : Action V G} (f : A ⟶ B) :
     (functorCategoryMonoidalEquivalence _ _).map f = FunctorCategoryEquivalence.functor.map f :=
   rfl
 #align Action.functor_category_monoidal_equivalence.functor_map Action.functorCategoryMonoidalEquivalence.functor_map
+-/
 
+#print Action.functorCategoryMonoidalEquivalence.inverse_map /-
 @[simp]
 theorem functorCategoryMonoidalEquivalence.inverse_map {A B : SingleObj G ⥤ V} (f : A ⟶ B) :
     (functorCategoryMonoidalEquivalence _ _).inv.map f = FunctorCategoryEquivalence.inverse.map f :=
   rfl
 #align Action.functor_category_monoidal_equivalence.inverse_map Action.functorCategoryMonoidalEquivalence.inverse_map
+-/
 
 variable (H : GroupCat.{u})
 
@@ -736,34 +808,43 @@ variable {V H} (X : Action V H)
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+#print Action.rightDual_v /-
 @[simp]
 theorem rightDual_v [RightRigidCategory V] : Xᘁ.V = X.Vᘁ :=
   rfl
 #align Action.right_dual_V Action.rightDual_v
+-/
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+#print Action.leftDual_v /-
 @[simp]
 theorem leftDual_v [LeftRigidCategory V] : (ᘁX).V = ᘁX.V :=
   rfl
 #align Action.left_dual_V Action.leftDual_v
+-/
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+#print Action.rightDual_ρ /-
 @[simp]
 theorem rightDual_ρ [RightRigidCategory V] (h : H) : Xᘁ.ρ h = X.ρ (h⁻¹ : H)ᘁ := by
   rw [← single_obj.inv_as_inv]; rfl
 #align Action.right_dual_ρ Action.rightDual_ρ
+-/
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+#print Action.leftDual_ρ /-
 @[simp]
 theorem leftDual_ρ [LeftRigidCategory V] (h : H) : (ᘁX).ρ h = ᘁX.ρ (h⁻¹ : H) := by
   rw [← single_obj.inv_as_inv]; rfl
 #align Action.left_dual_ρ Action.leftDual_ρ
+-/
 
 end Monoidal
 
+#print Action.actionPunitEquivalence /-
 /-- Actions/representations of the trivial group are just objects in the ambient category. -/
 def actionPunitEquivalence : Action V (MonCat.of PUnit) ≌ V
     where
@@ -775,6 +856,7 @@ def actionPunitEquivalence : Action V (MonCat.of PUnit) ≌ V
     NatIso.ofComponents (fun X => mkIso (Iso.refl _) fun ⟨⟩ => by simpa using ρ_one X) (by tidy)
   counitIso := NatIso.ofComponents (fun X => Iso.refl _) (by tidy)
 #align Action.Action_punit_equivalence Action.actionPunitEquivalence
+-/
 
 variable (V)
 
@@ -822,13 +904,17 @@ attribute [simps] res_comp
 -- the locally discrete bicategory constructed from `Monᵒᵖ` to `Cat`, sending `G` to `Action V G`.
 variable {G} {H : MonCat.{u}} (f : G ⟶ H)
 
+#print Action.res_additive /-
 instance res_additive [Preadditive V] : (res V f).Additive where
 #align Action.res_additive Action.res_additive
+-/
 
 variable {R : Type _} [Semiring R]
 
+#print Action.res_linear /-
 instance res_linear [Preadditive V] [Linear R V] : (res V f).Linear R where
 #align Action.res_linear Action.res_linear
+-/
 
 #print Action.ofMulAction /-
 /-- Bundles a type `H` with a multiplicative action of `G` as an `Action`. -/
@@ -839,11 +925,13 @@ def ofMulAction (G H : Type u) [Monoid G] [MulAction G H] : Action (Type u) (Mon
 #align Action.of_mul_action Action.ofMulAction
 -/
 
+#print Action.ofMulAction_apply /-
 @[simp]
 theorem ofMulAction_apply {G H : Type u} [Monoid G] [MulAction G H] (g : G) (x : H) :
     (ofMulAction G H).ρ g x = (g • x : H) :=
   rfl
 #align Action.of_mul_action_apply Action.ofMulAction_apply
+-/
 
 /- ./././Mathport/Syntax/Translate/Tactic/Builtin.lean:73:14: unsupported tactic `discrete_cases #[] -/
 #print Action.ofMulActionLimitCone /-
@@ -908,6 +996,7 @@ def diagonalOneIsoLeftRegular (G : Type u) [Monoid G] : diagonal G 1 ≅ leftReg
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+#print Action.leftRegularTensorIso /-
 /-- Given `X : Action (Type u) (Mon.of G)` for `G` a group, then `G × X` (with `G` acting as left
 multiplication on the first factor and by `X.ρ` on the second) is isomorphic as a `G`-set to
 `G × X` (with `G` acting as left multiplication on the first factor and trivially on the second).
@@ -942,6 +1031,7 @@ def leftRegularTensorIso (G : Type u) [Group G] (X : Action (Type u) (MonCat.of
           show (X.ρ (x.1⁻¹ : G) * X.ρ x.1) _ = _ by
             simpa only [← X.ρ.map_mul, inv_mul_self, X.ρ.map_one])
 #align Action.left_regular_tensor_iso Action.leftRegularTensorIso
+-/
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 #print Action.diagonalSucc /-
@@ -982,13 +1072,17 @@ def mapAction (F : V ⥤ W) (G : MonCat.{u}) : Action V G ⥤ Action W G
 
 variable (F : V ⥤ W) (G : MonCat.{u}) [Preadditive V] [Preadditive W]
 
+#print CategoryTheory.Functor.mapAction_preadditive /-
 instance mapAction_preadditive [F.Additive] : (F.mapAction G).Additive where
 #align category_theory.functor.map_Action_preadditive CategoryTheory.Functor.mapAction_preadditive
+-/
 
 variable {R : Type _} [Semiring R] [CategoryTheory.Linear R V] [CategoryTheory.Linear R W]
 
+#print CategoryTheory.Functor.mapAction_linear /-
 instance mapAction_linear [F.Additive] [F.Linear R] : (F.mapAction G).Linear R where
 #align category_theory.functor.map_Action_linear CategoryTheory.Functor.mapAction_linear
+-/
 
 end CategoryTheory.Functor
 
@@ -1023,6 +1117,7 @@ def mapAction : MonoidalFunctor (Action V G) (Action W G) :=
 #align category_theory.monoidal_functor.map_Action CategoryTheory.MonoidalFunctor.mapAction
 -/
 
+#print CategoryTheory.MonoidalFunctor.mapAction_ε_inv_hom /-
 @[simp]
 theorem mapAction_ε_inv_hom : (inv (F.mapAction G).ε).Hom = inv F.ε :=
   by
@@ -1030,7 +1125,9 @@ theorem mapAction_ε_inv_hom : (inv (F.mapAction G).ε).Hom = inv F.ε :=
   simp only [← F.map_Action_to_lax_monoidal_functor_ε_hom G, ← Action.comp_hom, is_iso.hom_inv_id,
     id_hom]
 #align category_theory.monoidal_functor.map_Action_ε_inv_hom CategoryTheory.MonoidalFunctor.mapAction_ε_inv_hom
+-/
 
+#print CategoryTheory.MonoidalFunctor.mapAction_μ_inv_hom /-
 @[simp]
 theorem mapAction_μ_inv_hom (X Y : Action V G) :
     (inv ((F.mapAction G).μ X Y)).Hom = inv (F.μ X.V Y.V) :=
@@ -1039,6 +1136,7 @@ theorem mapAction_μ_inv_hom (X Y : Action V G) :
   simpa only [← F.map_Action_to_lax_monoidal_functor_μ_hom G, ← Action.comp_hom, is_iso.hom_inv_id,
     id_hom]
 #align category_theory.monoidal_functor.map_Action_μ_inv_hom CategoryTheory.MonoidalFunctor.mapAction_μ_inv_hom
+-/
 
 end CategoryTheory.MonoidalFunctor
 
Diff
@@ -318,10 +318,8 @@ instance : Faithful (forget V G) where map_injective' X Y f g w := Hom.ext _ _ w
 instance [ConcreteCategory V] : ConcreteCategory (Action V G)
     where forget := forget V G ⋙ ConcreteCategory.forget V
 
-#print Action.hasForgetToV /-
 instance hasForgetToV [ConcreteCategory V] : HasForget₂ (Action V G) V where forget₂ := forget V G
 #align Action.has_forget_to_V Action.hasForgetToV
--/
 
 /-- The forgetful functor is intertwined by `functor_category_equivalence` with
 evaluation at `punit.star`. -/
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Scott Morrison
 
 ! This file was ported from Lean 3 source module representation_theory.Action
-! leanprover-community/mathlib commit 95a87616d63b3cb49d3fe678d416fbe9c4217bf4
+! leanprover-community/mathlib commit c20927220ef87bb4962ba08bf6da2ce3cf50a6dd
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
@@ -28,6 +28,9 @@ import Mathbin.CategoryTheory.Linear.FunctorCategory
 /-!
 # `Action V G`, the category of actions of a monoid `G` inside some category `V`.
 
+> THIS FILE IS SYNCHRONIZED WITH MATHLIB4.
+> Any changes to this file require a corresponding PR to mathlib4.
+
 The prototypical example is `V = Module R`,
 where `Action (Module R) G` is the category of `R`-linear representations of `G`.
 
Diff
@@ -48,6 +48,7 @@ open CategoryTheory.Limits
 
 variable (V : Type (u + 1)) [LargeCategory V]
 
+#print Action /-
 -- Note: this is _not_ a categorical action of `G` on `V`.
 /-- An `Action V G` represents a bundled action of
 the monoid `G` on an object of some category `V`.
@@ -59,6 +60,7 @@ structure Action (G : MonCat.{u}) where
   V : V
   ρ : G ⟶ MonCat.of (End V)
 #align Action Action
+-/
 
 namespace Action
 
@@ -85,16 +87,20 @@ variable (G : MonCat.{u})
 
 section
 
+#print Action.inhabited' /-
 instance inhabited' : Inhabited (Action (Type u) G) :=
   ⟨⟨PUnit, 1⟩⟩
 #align Action.inhabited' Action.inhabited'
+-/
 
+#print Action.trivial /-
 /-- The trivial representation of a group. -/
 def trivial : Action AddCommGroupCat G
     where
   V := AddCommGroupCat.of PUnit
   ρ := 1
 #align Action.trivial Action.trivial
+-/
 
 instance : Inhabited (Action AddCommGroupCat G) :=
   ⟨trivial G⟩
@@ -103,6 +109,7 @@ end
 
 variable {G V}
 
+#print Action.Hom /-
 /-- A homomorphism of `Action V G`s is a morphism between the underlying objects,
 commuting with the action of `G`.
 -/
@@ -111,19 +118,23 @@ structure Hom (M N : Action V G) where
   Hom : M.V ⟶ N.V
   comm' : ∀ g : G, M.ρ g ≫ hom = hom ≫ N.ρ g := by obviously
 #align Action.hom Action.Hom
+-/
 
 restate_axiom hom.comm'
 
 namespace Hom
 
+#print Action.Hom.id /-
 /-- The identity morphism on a `Action V G`. -/
 @[simps]
 def id (M : Action V G) : Action.Hom M M where Hom := 𝟙 M.V
 #align Action.hom.id Action.Hom.id
+-/
 
 instance (M : Action V G) : Inhabited (Action.Hom M M) :=
   ⟨id M⟩
 
+#print Action.Hom.comp /-
 /-- The composition of two `Action V G` homomorphisms is the composition of the underlying maps.
 -/
 @[simps]
@@ -132,6 +143,7 @@ def comp {M N K : Action V G} (p : Action.Hom M N) (q : Action.Hom N K) : Action
   Hom := p.Hom ≫ q.Hom
   comm' g := by rw [← category.assoc, p.comm, category.assoc, q.comm, ← category.assoc]
 #align Action.hom.comp Action.Hom.comp
+-/
 
 end Hom
 
@@ -140,16 +152,20 @@ instance : Category (Action V G) where
   id M := Hom.id M
   comp M N K f g := Hom.comp f g
 
+#print Action.id_hom /-
 @[simp]
 theorem id_hom (M : Action V G) : (𝟙 M : Hom M M).Hom = 𝟙 M.V :=
   rfl
 #align Action.id_hom Action.id_hom
+-/
 
+#print Action.comp_hom /-
 @[simp]
 theorem comp_hom {M N K : Action V G} (f : M ⟶ N) (g : N ⟶ K) :
     (f ≫ g : Hom M K).Hom = f.Hom ≫ g.Hom :=
   rfl
 #align Action.comp_hom Action.comp_hom
+-/
 
 /-- Construct an isomorphism of `G` actions/representations
 from an isomorphism of the the underlying objects,
@@ -165,9 +181,11 @@ def mkIso {M N : Action V G} (f : M.V ≅ N.V) (comm : ∀ g : G, M.ρ g ≫ f.H
       comm' := fun g => by have w := comm g =≫ f.inv; simp at w ; simp [w] }
 #align Action.mk_iso Action.mkIso
 
+#print Action.isIso_of_hom_isIso /-
 instance (priority := 100) isIso_of_hom_isIso {M N : Action V G} (f : M ⟶ N) [IsIso f.Hom] :
     IsIso f := by convert is_iso.of_iso (mk_iso (as_iso f.hom) f.comm); ext; rfl
 #align Action.is_iso_of_hom_is_iso Action.isIso_of_hom_isIso
+-/
 
 instance isIso_hom_mk {M N : Action V G} (f : M.V ⟶ N.V) [IsIso f] (w) : @IsIso _ _ M N ⟨f, w⟩ :=
   IsIso.of_iso (mkIso (asIso f) w)
@@ -175,6 +193,7 @@ instance isIso_hom_mk {M N : Action V G} (f : M.V ⟶ N.V) [IsIso f] (w) : @IsIs
 
 namespace FunctorCategoryEquivalence
 
+#print Action.FunctorCategoryEquivalence.functor /-
 /-- Auxilliary definition for `functor_category_equivalence`. -/
 @[simps]
 def functor : Action V G ⥤ SingleObj G ⥤ V
@@ -188,7 +207,9 @@ def functor : Action V G ⥤ SingleObj G ⥤ V
     { app := fun _ => f.Hom
       naturality' := fun _ _ g => f.comm g }
 #align Action.functor_category_equivalence.functor Action.FunctorCategoryEquivalence.functor
+-/
 
+#print Action.FunctorCategoryEquivalence.inverse /-
 /-- Auxilliary definition for `functor_category_equivalence`. -/
 @[simps]
 def inverse : (SingleObj G ⥤ V) ⥤ Action V G
@@ -203,18 +224,23 @@ def inverse : (SingleObj G ⥤ V) ⥤ Action V G
     { Hom := f.app PUnit.unit
       comm' := fun g => f.naturality g }
 #align Action.functor_category_equivalence.inverse Action.FunctorCategoryEquivalence.inverse
+-/
 
+#print Action.FunctorCategoryEquivalence.unitIso /-
 /-- Auxilliary definition for `functor_category_equivalence`. -/
 @[simps]
 def unitIso : 𝟭 (Action V G) ≅ functor ⋙ inverse :=
   NatIso.ofComponents (fun M => mkIso (Iso.refl _) (by tidy)) (by tidy)
 #align Action.functor_category_equivalence.unit_iso Action.FunctorCategoryEquivalence.unitIso
+-/
 
+#print Action.FunctorCategoryEquivalence.counitIso /-
 /-- Auxilliary definition for `functor_category_equivalence`. -/
 @[simps]
 def counitIso : inverse ⋙ functor ≅ 𝟭 (SingleObj G ⥤ V) :=
   NatIso.ofComponents (fun M => NatIso.ofComponents (by tidy) (by tidy)) (by tidy)
 #align Action.functor_category_equivalence.counit_iso Action.FunctorCategoryEquivalence.counitIso
+-/
 
 end FunctorCategoryEquivalence
 
@@ -237,15 +263,19 @@ def functorCategoryEquivalence : Action V G ≌ SingleObj G ⥤ V
 
 attribute [simps] functor_category_equivalence
 
-theorem functorCategoryEquivalence.functor_def :
+#print Action.functorCategoryEquivalence_functor /-
+theorem Action.functorCategoryEquivalence_functor :
     (functorCategoryEquivalence V G).Functor = FunctorCategoryEquivalence.functor :=
   rfl
-#align Action.functor_category_equivalence.functor_def Action.functorCategoryEquivalence.functor_def
+#align Action.functor_category_equivalence.functor_def Action.functorCategoryEquivalence_functor
+-/
 
-theorem functorCategoryEquivalence.inverse_def :
+#print Action.functorCategoryEquivalence_inverse /-
+theorem Action.functorCategoryEquivalence_inverse :
     (functorCategoryEquivalence V G).inverse = FunctorCategoryEquivalence.inverse :=
   rfl
-#align Action.functor_category_equivalence.inverse_def Action.functorCategoryEquivalence.inverse_def
+#align Action.functor_category_equivalence.inverse_def Action.functorCategoryEquivalence_inverse
+-/
 
 instance [HasFiniteProducts V] : HasFiniteProducts (Action V G)
     where out n :=
@@ -267,6 +297,7 @@ section Forget
 
 variable (V G)
 
+#print Action.forget /-
 /-- (implementation) The forgetful functor from bundled actions to the underlying objects.
 
 Use the `category_theory.forget` API provided by the `concrete_category` instance below,
@@ -277,14 +308,17 @@ def forget : Action V G ⥤ V where
   obj M := M.V
   map M N f := f.Hom
 #align Action.forget Action.forget
+-/
 
 instance : Faithful (forget V G) where map_injective' X Y f g w := Hom.ext _ _ w
 
 instance [ConcreteCategory V] : ConcreteCategory (Action V G)
     where forget := forget V G ⋙ ConcreteCategory.forget V
 
+#print Action.hasForgetToV /-
 instance hasForgetToV [ConcreteCategory V] : HasForget₂ (Action V G) V where forget₂ := forget V G
 #align Action.has_forget_to_V Action.hasForgetToV
+-/
 
 /-- The forgetful functor is intertwined by `functor_category_equivalence` with
 evaluation at `punit.star`. -/
@@ -434,10 +468,12 @@ variable [MonoidalCategory V]
 instance : MonoidalCategory (Action V G) :=
   Monoidal.transport (Action.functorCategoryEquivalence _ _).symm
 
+#print Action.tensorUnit_v /-
 @[simp]
 theorem tensorUnit_v : (𝟙_ (Action V G)).V = 𝟙_ V :=
   rfl
 #align Action.tensor_unit_V Action.tensorUnit_v
+-/
 
 @[simp]
 theorem tensorUnit_rho {g : G} : (𝟙_ (Action V G)).ρ g = 𝟙 (𝟙_ V) :=
@@ -446,10 +482,12 @@ theorem tensorUnit_rho {g : G} : (𝟙_ (Action V G)).ρ g = 𝟙 (𝟙_ V) :=
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+#print Action.tensor_v /-
 @[simp]
 theorem tensor_v {X Y : Action V G} : (X ⊗ Y).V = X.V ⊗ Y.V :=
   rfl
 #align Action.tensor_V Action.tensor_v
+-/
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
@@ -460,52 +498,66 @@ theorem tensor_rho {X Y : Action V G} {g : G} : (X ⊗ Y).ρ g = X.ρ g ⊗ Y.ρ
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+#print Action.tensorHom /-
 @[simp]
 theorem tensorHom {W X Y Z : Action V G} (f : W ⟶ X) (g : Y ⟶ Z) : (f ⊗ g).Hom = f.Hom ⊗ g.Hom :=
   rfl
 #align Action.tensor_hom Action.tensorHom
+-/
 
+#print Action.associator_hom_hom /-
 @[simp]
 theorem associator_hom_hom {X Y Z : Action V G} : Hom.hom (α_ X Y Z).Hom = (α_ X.V Y.V Z.V).Hom :=
   by
   dsimp [monoidal.transport_associator]
   simp
 #align Action.associator_hom_hom Action.associator_hom_hom
+-/
 
+#print Action.associator_inv_hom /-
 @[simp]
 theorem associator_inv_hom {X Y Z : Action V G} : Hom.hom (α_ X Y Z).inv = (α_ X.V Y.V Z.V).inv :=
   by
   dsimp [monoidal.transport_associator]
   simp
 #align Action.associator_inv_hom Action.associator_inv_hom
+-/
 
+#print Action.leftUnitor_hom_hom /-
 @[simp]
 theorem leftUnitor_hom_hom {X : Action V G} : Hom.hom (λ_ X).Hom = (λ_ X.V).Hom :=
   by
   dsimp [monoidal.transport_left_unitor]
   simp
 #align Action.left_unitor_hom_hom Action.leftUnitor_hom_hom
+-/
 
+#print Action.leftUnitor_inv_hom /-
 @[simp]
 theorem leftUnitor_inv_hom {X : Action V G} : Hom.hom (λ_ X).inv = (λ_ X.V).inv :=
   by
   dsimp [monoidal.transport_left_unitor]
   simp
 #align Action.left_unitor_inv_hom Action.leftUnitor_inv_hom
+-/
 
+#print Action.rightUnitor_hom_hom /-
 @[simp]
 theorem rightUnitor_hom_hom {X : Action V G} : Hom.hom (ρ_ X).Hom = (ρ_ X.V).Hom :=
   by
   dsimp [monoidal.transport_right_unitor]
   simp
 #align Action.right_unitor_hom_hom Action.rightUnitor_hom_hom
+-/
 
+#print Action.rightUnitor_inv_hom /-
 @[simp]
 theorem rightUnitor_inv_hom {X : Action V G} : Hom.hom (ρ_ X).inv = (ρ_ X.V).inv :=
   by
   dsimp [monoidal.transport_right_unitor]
   simp
 #align Action.right_unitor_inv_hom Action.rightUnitor_inv_hom
+-/
 
 /-- Given an object `X` isomorphic to the tensor unit of `V`, `X` equipped with the trivial action
 is isomorphic to the tensor unit of `Action V G`. -/
@@ -517,6 +569,7 @@ def tensorUnitIso {X : V} (f : 𝟙_ V ≅ X) : 𝟙_ (Action V G) ≅ Action.mk
 
 variable (V G)
 
+#print Action.forgetMonoidal /-
 /-- When `V` is monoidal the forgetful functor `Action V G` to `V` is monoidal. -/
 @[simps]
 def forgetMonoidal : MonoidalFunctor (Action V G) V :=
@@ -524,10 +577,13 @@ def forgetMonoidal : MonoidalFunctor (Action V G) V :=
     ε := 𝟙 _
     μ := fun X Y => 𝟙 _ }
 #align Action.forget_monoidal Action.forgetMonoidal
+-/
 
+#print Action.forgetMonoidal_faithful /-
 instance forgetMonoidal_faithful : Faithful (forgetMonoidal V G).toFunctor := by
   change faithful (forget V G); infer_instance
 #align Action.forget_monoidal_faithful Action.forgetMonoidal_faithful
+-/
 
 section
 
@@ -542,9 +598,11 @@ def forgetBraided : BraidedFunctor (Action V G) V :=
   { forgetMonoidal _ _ with }
 #align Action.forget_braided Action.forgetBraided
 
+#print Action.forgetBraided_faithful /-
 instance forgetBraided_faithful : Faithful (forgetBraided V G).toFunctor := by
   change faithful (forget V G); infer_instance
 #align Action.forget_braided_faithful Action.forgetBraided_faithful
+-/
 
 end
 
@@ -569,10 +627,12 @@ variable (V G)
 
 noncomputable section
 
+#print Action.functorCategoryMonoidalEquivalence /-
 /-- Upgrading the functor `Action V G ⥤ (single_obj G ⥤ V)` to a monoidal functor. -/
 def functorCategoryMonoidalEquivalence : MonoidalFunctor (Action V G) (SingleObj G ⥤ V) :=
   Monoidal.fromTransported (Action.functorCategoryEquivalence _ _).symm
 #align Action.functor_category_monoidal_equivalence Action.functorCategoryMonoidalEquivalence
+-/
 
 instance : IsEquivalence (functorCategoryMonoidalEquivalence V G).toFunctor := by
   change is_equivalence (Action.functorCategoryEquivalence _ _).Functor; infer_instance
@@ -717,6 +777,7 @@ def actionPunitEquivalence : Action V (MonCat.of PUnit) ≌ V
 
 variable (V)
 
+#print Action.res /-
 /-- The "restriction" functor along a monoid homomorphism `f : G ⟶ H`,
 taking actions of `H` to actions of `G`.
 
@@ -732,22 +793,27 @@ def res {G H : MonCat} (f : G ⟶ H) : Action V H ⥤ Action V G
     { Hom := p.Hom
       comm' := fun g => p.comm (f g) }
 #align Action.res Action.res
+-/
 
+#print Action.resId /-
 /-- The natural isomorphism from restriction along the identity homomorphism to
 the identity functor on `Action V G`.
 -/
 def resId {G : MonCat} : res V (𝟙 G) ≅ 𝟭 (Action V G) :=
   NatIso.ofComponents (fun M => mkIso (Iso.refl _) (by tidy)) (by tidy)
 #align Action.res_id Action.resId
+-/
 
 attribute [simps] res_id
 
+#print Action.resComp /-
 /-- The natural isomorphism from the composition of restrictions along homomorphisms
 to the restriction along the composition of homomorphism.
 -/
 def resComp {G H K : MonCat} (f : G ⟶ H) (g : H ⟶ K) : res V g ⋙ res V f ≅ res V (f ≫ g) :=
   NatIso.ofComponents (fun M => mkIso (Iso.refl _) (by tidy)) (by tidy)
 #align Action.res_comp Action.resComp
+-/
 
 attribute [simps] res_comp
 
@@ -763,12 +829,14 @@ variable {R : Type _} [Semiring R]
 instance res_linear [Preadditive V] [Linear R V] : (res V f).Linear R where
 #align Action.res_linear Action.res_linear
 
+#print Action.ofMulAction /-
 /-- Bundles a type `H` with a multiplicative action of `G` as an `Action`. -/
 def ofMulAction (G H : Type u) [Monoid G] [MulAction G H] : Action (Type u) (MonCat.of G)
     where
   V := H
   ρ := @MulAction.toEndHom _ _ _ (by assumption)
 #align Action.of_mul_action Action.ofMulAction
+-/
 
 @[simp]
 theorem ofMulAction_apply {G H : Type u} [Monoid G] [MulAction G H] (g : G) (x : H) :
@@ -777,6 +845,7 @@ theorem ofMulAction_apply {G H : Type u} [Monoid G] [MulAction G H] (g : G) (x :
 #align Action.of_mul_action_apply Action.ofMulAction_apply
 
 /- ./././Mathport/Syntax/Translate/Tactic/Builtin.lean:73:14: unsupported tactic `discrete_cases #[] -/
+#print Action.ofMulActionLimitCone /-
 /-- Given a family `F` of types with `G`-actions, this is the limit cone demonstrating that the
 product of `F` as types is a product in the category of `G`-sets. -/
 def ofMulActionLimitCone {ι : Type v} (G : Type max v u) [Monoid G] (F : ι → Type max v u)
@@ -811,23 +880,30 @@ def ofMulActionLimitCone {ι : Type v} (G : Type max v u) [Monoid G] (F : ι →
         rw [← h ⟨j⟩]
         congr }
 #align Action.of_mul_action_limit_cone Action.ofMulActionLimitCone
+-/
 
+#print Action.leftRegular /-
 /-- The `G`-set `G`, acting on itself by left multiplication. -/
 @[simps]
 def leftRegular (G : Type u) [Monoid G] : Action (Type u) (MonCat.of G) :=
   Action.ofMulAction G G
 #align Action.left_regular Action.leftRegular
+-/
 
+#print Action.diagonal /-
 /-- The `G`-set `Gⁿ`, acting on itself by left multiplication. -/
 @[simps]
 def diagonal (G : Type u) [Monoid G] (n : ℕ) : Action (Type u) (MonCat.of G) :=
   Action.ofMulAction G (Fin n → G)
 #align Action.diagonal Action.diagonal
+-/
 
+#print Action.diagonalOneIsoLeftRegular /-
 /-- We have `fin 1 → G ≅ G` as `G`-sets, with `G` acting by left multiplication. -/
 def diagonalOneIsoLeftRegular (G : Type u) [Monoid G] : diagonal G 1 ≅ leftRegular G :=
   Action.mkIso (Equiv.funUnique _ _).toIso fun g => rfl
 #align Action.diagonal_one_iso_left_regular Action.diagonalOneIsoLeftRegular
+-/
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
@@ -867,6 +943,7 @@ def leftRegularTensorIso (G : Type u) [Group G] (X : Action (Type u) (MonCat.of
 #align Action.left_regular_tensor_iso Action.leftRegularTensorIso
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+#print Action.diagonalSucc /-
 /-- The natural isomorphism of `G`-sets `Gⁿ⁺¹ ≅ G × Gⁿ`, where `G` acts by left multiplication on
 each factor. -/
 @[simps]
@@ -874,6 +951,7 @@ def diagonalSucc (G : Type u) [Monoid G] (n : ℕ) :
     diagonal G (n + 1) ≅ leftRegular G ⊗ diagonal G n :=
   mkIso (Equiv.piFinSuccAboveEquiv _ 0).toIso fun g => rfl
 #align Action.diagonal_succ Action.diagonalSucc
+-/
 
 end Action
 
@@ -881,6 +959,7 @@ namespace CategoryTheory.Functor
 
 variable {V} {W : Type (u + 1)} [LargeCategory W]
 
+#print CategoryTheory.Functor.mapAction /-
 /-- A functor between categories induces a functor between
 the categories of `G`-actions within those categories. -/
 @[simps]
@@ -898,6 +977,7 @@ def mapAction (F : V ⥤ W) (G : MonCat.{u}) : Action V G ⥤ Action W G
   map_id' M := by ext; simp only [Action.id_hom, F.map_id]
   map_comp' M N P f g := by ext; simp only [Action.comp_hom, F.map_comp]
 #align category_theory.functor.map_Action CategoryTheory.Functor.mapAction
+-/
 
 variable (F : V ⥤ W) (G : MonCat.{u}) [Preadditive V] [Preadditive W]
 
@@ -918,6 +998,7 @@ open Action
 variable {V} {W : Type (u + 1)} [LargeCategory W] [MonoidalCategory V] [MonoidalCategory W]
   (F : MonoidalFunctor V W) (G : MonCat.{u})
 
+#print CategoryTheory.MonoidalFunctor.mapAction /-
 /-- A monoidal functor induces a monoidal functor between
 the categories of `G`-actions within those categories. -/
 @[simps]
@@ -939,6 +1020,7 @@ def mapAction : MonoidalFunctor (Action V G) (Action W G) :=
     left_unitality' := by intros; ext; dsimp; simp; dsimp; simp
     right_unitality' := by intros; ext; dsimp; simp; dsimp; simp }
 #align category_theory.monoidal_functor.map_Action CategoryTheory.MonoidalFunctor.mapAction
+-/
 
 @[simp]
 theorem mapAction_ε_inv_hom : (inv (F.mapAction G).ε).Hom = inv F.ε :=
Diff
@@ -162,7 +162,7 @@ def mkIso {M N : Action V G} (f : M.V ≅ N.V) (comm : ∀ g : G, M.ρ g ≫ f.H
       comm' := comm }
   inv :=
     { Hom := f.inv
-      comm' := fun g => by have w := comm g =≫ f.inv; simp at w; simp [w] }
+      comm' := fun g => by have w := comm g =≫ f.inv; simp at w ; simp [w] }
 #align Action.mk_iso Action.mkIso
 
 instance (priority := 100) isIso_of_hom_isIso {M N : Action V G} (f : M ⟶ N) [IsIso f.Hom] :
@@ -340,13 +340,13 @@ instance : Preadditive (Action V G)
     { zero := ⟨0, by simp⟩
       add := fun f g => ⟨f.Hom + g.Hom, by simp [f.comm, g.comm]⟩
       neg := fun f => ⟨-f.Hom, by simp [f.comm]⟩
-      zero_add := by intros ; ext; exact zero_add _
-      add_zero := by intros ; ext; exact add_zero _
-      add_assoc := by intros ; ext; exact add_assoc _ _ _
-      add_left_neg := by intros ; ext; exact add_left_neg _
-      add_comm := by intros ; ext; exact add_comm _ _ }
-  add_comp := by intros ; ext; exact preadditive.add_comp _ _ _ _ _ _
-  comp_add := by intros ; ext; exact preadditive.comp_add _ _ _ _ _ _
+      zero_add := by intros; ext; exact zero_add _
+      add_zero := by intros; ext; exact add_zero _
+      add_assoc := by intros; ext; exact add_assoc _ _ _
+      add_left_neg := by intros; ext; exact add_left_neg _
+      add_comm := by intros; ext; exact add_comm _ _ }
+  add_comp := by intros; ext; exact preadditive.add_comp _ _ _ _ _ _
+  comp_add := by intros; ext; exact preadditive.comp_add _ _ _ _ _ _
 
 instance forget_additive : Functor.Additive (forget V G) where
 #align Action.forget_additive Action.forget_additive
@@ -389,14 +389,14 @@ instance : Linear R (Action V G)
     where
   homModule X Y :=
     { smul := fun r f => ⟨r • f.Hom, by simp [f.comm]⟩
-      one_smul := by intros ; ext; exact one_smul _ _
-      smul_zero := by intros ; ext; exact smul_zero _
-      zero_smul := by intros ; ext; exact zero_smul _ _
-      add_smul := by intros ; ext; exact add_smul _ _ _
-      smul_add := by intros ; ext; exact smul_add _ _ _
-      mul_smul := by intros ; ext; exact mul_smul _ _ _ }
-  smul_comp' := by intros ; ext; exact linear.smul_comp _ _ _ _ _ _
-  comp_smul' := by intros ; ext; exact linear.comp_smul _ _ _ _ _ _
+      one_smul := by intros; ext; exact one_smul _ _
+      smul_zero := by intros; ext; exact smul_zero _
+      zero_smul := by intros; ext; exact zero_smul _ _
+      add_smul := by intros; ext; exact add_smul _ _ _
+      smul_add := by intros; ext; exact smul_add _ _ _
+      mul_smul := by intros; ext; exact mul_smul _ _ _ }
+  smul_comp' := by intros; ext; exact linear.smul_comp _ _ _ _ _ _
+  comp_smul' := by intros; ext; exact linear.comp_smul _ _ _ _ _ _
 
 instance forget_linear : Functor.Linear R (forget V G) where
 #align Action.forget_linear Action.forget_linear
@@ -857,13 +857,13 @@ def leftRegularTensorIso (G : Type u) [Group G] (X : Action (Type u) (MonCat.of
       (funext fun x =>
         Prod.ext rfl <|
           show (X.ρ x.1 * X.ρ (x.1⁻¹ : G)) x.2 = _ by
-            simpa only [← X.ρ.map_mul, mul_inv_self, X.ρ.map_one] )
+            simpa only [← X.ρ.map_mul, mul_inv_self, X.ρ.map_one])
   inv_hom_id' :=
     Hom.ext _ _
       (funext fun x =>
         Prod.ext rfl <|
           show (X.ρ (x.1⁻¹ : G) * X.ρ x.1) _ = _ by
-            simpa only [← X.ρ.map_mul, inv_mul_self, X.ρ.map_one] )
+            simpa only [← X.ρ.map_mul, inv_mul_self, X.ρ.map_one])
 #align Action.left_regular_tensor_iso Action.leftRegularTensorIso
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
@@ -934,10 +934,10 @@ def mapAction : MonoidalFunctor (Action V G) (Action W G) :=
         comm' := fun g => F.toLaxMonoidalFunctor.μ_natural (X.ρ g) (Y.ρ g) }
     ε_isIso := by infer_instance
     μ_isIso := by infer_instance
-    μ_natural' := by intros ; ext; dsimp; simp
-    associativity' := by intros ; ext; dsimp; simp; dsimp; simp
-    left_unitality' := by intros ; ext; dsimp; simp; dsimp; simp
-    right_unitality' := by intros ; ext; dsimp; simp; dsimp; simp }
+    μ_natural' := by intros; ext; dsimp; simp
+    associativity' := by intros; ext; dsimp; simp; dsimp; simp
+    left_unitality' := by intros; ext; dsimp; simp; dsimp; simp
+    right_unitality' := by intros; ext; dsimp; simp; dsimp; simp }
 #align category_theory.monoidal_functor.map_Action CategoryTheory.MonoidalFunctor.mapAction
 
 @[simp]
Diff
@@ -65,10 +65,7 @@ namespace Action
 variable {V}
 
 @[simp]
-theorem ρ_one {G : MonCat.{u}} (A : Action V G) : A.ρ 1 = 𝟙 A.V :=
-  by
-  rw [MonoidHom.map_one]
-  rfl
+theorem ρ_one {G : MonCat.{u}} (A : Action V G) : A.ρ 1 = 𝟙 A.V := by rw [MonoidHom.map_one]; rfl
 #align Action.ρ_one Action.ρ_one
 
 /-- When a group acts, we can lift the action to the group of automorphisms. -/
@@ -80,12 +77,8 @@ def ρAut {G : GroupCat.{u}} (A : Action V (MonCat.of G)) : G ⟶ GroupCat.of (A
       inv := A.ρ (g⁻¹ : G)
       hom_inv_id' := (A.ρ.map_mul (g⁻¹ : G) g).symm.trans (by rw [inv_mul_self, ρ_one])
       inv_hom_id' := (A.ρ.map_mul g (g⁻¹ : G)).symm.trans (by rw [mul_inv_self, ρ_one]) }
-  map_one' := by
-    ext
-    exact A.ρ.map_one
-  map_mul' x y := by
-    ext
-    exact A.ρ.map_mul x y
+  map_one' := by ext; exact A.ρ.map_one
+  map_mul' x y := by ext; exact A.ρ.map_mul x y
 #align Action.ρ_Aut Action.ρAut
 
 variable (G : MonCat.{u})
@@ -169,17 +162,11 @@ def mkIso {M N : Action V G} (f : M.V ≅ N.V) (comm : ∀ g : G, M.ρ g ≫ f.H
       comm' := comm }
   inv :=
     { Hom := f.inv
-      comm' := fun g => by
-        have w := comm g =≫ f.inv
-        simp at w
-        simp [w] }
+      comm' := fun g => by have w := comm g =≫ f.inv; simp at w; simp [w] }
 #align Action.mk_iso Action.mkIso
 
 instance (priority := 100) isIso_of_hom_isIso {M N : Action V G} (f : M ⟶ N) [IsIso f.Hom] :
-    IsIso f := by
-  convert is_iso.of_iso (mk_iso (as_iso f.hom) f.comm)
-  ext
-  rfl
+    IsIso f := by convert is_iso.of_iso (mk_iso (as_iso f.hom) f.comm); ext; rfl
 #align Action.is_iso_of_hom_is_iso Action.isIso_of_hom_isIso
 
 instance isIso_hom_mk {M N : Action V G} (f : M.V ⟶ N.V) [IsIso f] (w) : @IsIso _ _ M N ⟨f, w⟩ :=
@@ -316,9 +303,7 @@ noncomputable instance [HasColimits V] : PreservesColimits (forget V G) :=
 end Forget
 
 theorem Iso.conj_ρ {M N : Action V G} (f : M ≅ N) (g : G) :
-    N.ρ g = ((forget V G).mapIso f).conj (M.ρ g) :=
-  by
-  rw [iso.conj_apply, iso.eq_inv_comp]
+    N.ρ g = ((forget V G).mapIso f).conj (M.ρ g) := by rw [iso.conj_apply, iso.eq_inv_comp];
   simp [f.hom.comm']
 #align Action.iso.conj_ρ Action.Iso.conj_ρ
 
@@ -328,16 +313,9 @@ variable [HasZeroMorphisms V]
 
 instance : HasZeroMorphisms (Action V G)
     where
-  Zero X Y :=
-    ⟨⟨0, by
-        intro g
-        simp⟩⟩
-  comp_zero P Q f R := by
-    ext1
-    simp
-  zero_comp P Q R f := by
-    ext1
-    simp
+  Zero X Y := ⟨⟨0, by intro g; simp⟩⟩
+  comp_zero P Q f R := by ext1; simp
+  zero_comp P Q R f := by ext1; simp
 
 instance forget_preservesZeroMorphisms : Functor.PreservesZeroMorphisms (forget V G) where
 #align Action.forget_preserves_zero_morphisms Action.forget_preservesZeroMorphisms
@@ -362,34 +340,13 @@ instance : Preadditive (Action V G)
     { zero := ⟨0, by simp⟩
       add := fun f g => ⟨f.Hom + g.Hom, by simp [f.comm, g.comm]⟩
       neg := fun f => ⟨-f.Hom, by simp [f.comm]⟩
-      zero_add := by
-        intros
-        ext
-        exact zero_add _
-      add_zero := by
-        intros
-        ext
-        exact add_zero _
-      add_assoc := by
-        intros
-        ext
-        exact add_assoc _ _ _
-      add_left_neg := by
-        intros
-        ext
-        exact add_left_neg _
-      add_comm := by
-        intros
-        ext
-        exact add_comm _ _ }
-  add_comp := by
-    intros
-    ext
-    exact preadditive.add_comp _ _ _ _ _ _
-  comp_add := by
-    intros
-    ext
-    exact preadditive.comp_add _ _ _ _ _ _
+      zero_add := by intros ; ext; exact zero_add _
+      add_zero := by intros ; ext; exact add_zero _
+      add_assoc := by intros ; ext; exact add_assoc _ _ _
+      add_left_neg := by intros ; ext; exact add_left_neg _
+      add_comm := by intros ; ext; exact add_comm _ _ }
+  add_comp := by intros ; ext; exact preadditive.add_comp _ _ _ _ _ _
+  comp_add := by intros ; ext; exact preadditive.comp_add _ _ _ _ _ _
 
 instance forget_additive : Functor.Additive (forget V G) where
 #align Action.forget_additive Action.forget_additive
@@ -432,38 +389,14 @@ instance : Linear R (Action V G)
     where
   homModule X Y :=
     { smul := fun r f => ⟨r • f.Hom, by simp [f.comm]⟩
-      one_smul := by
-        intros
-        ext
-        exact one_smul _ _
-      smul_zero := by
-        intros
-        ext
-        exact smul_zero _
-      zero_smul := by
-        intros
-        ext
-        exact zero_smul _ _
-      add_smul := by
-        intros
-        ext
-        exact add_smul _ _ _
-      smul_add := by
-        intros
-        ext
-        exact smul_add _ _ _
-      mul_smul := by
-        intros
-        ext
-        exact mul_smul _ _ _ }
-  smul_comp' := by
-    intros
-    ext
-    exact linear.smul_comp _ _ _ _ _ _
-  comp_smul' := by
-    intros
-    ext
-    exact linear.comp_smul _ _ _ _ _ _
+      one_smul := by intros ; ext; exact one_smul _ _
+      smul_zero := by intros ; ext; exact smul_zero _
+      zero_smul := by intros ; ext; exact zero_smul _ _
+      add_smul := by intros ; ext; exact add_smul _ _ _
+      smul_add := by intros ; ext; exact smul_add _ _ _
+      mul_smul := by intros ; ext; exact mul_smul _ _ _ }
+  smul_comp' := by intros ; ext; exact linear.smul_comp _ _ _ _ _ _
+  comp_smul' := by intros ; ext; exact linear.comp_smul _ _ _ _ _ _
 
 instance forget_linear : Functor.Linear R (forget V G) where
 #align Action.forget_linear Action.forget_linear
@@ -592,10 +525,8 @@ def forgetMonoidal : MonoidalFunctor (Action V G) V :=
     μ := fun X Y => 𝟙 _ }
 #align Action.forget_monoidal Action.forgetMonoidal
 
-instance forgetMonoidal_faithful : Faithful (forgetMonoidal V G).toFunctor :=
-  by
-  change faithful (forget V G)
-  infer_instance
+instance forgetMonoidal_faithful : Faithful (forgetMonoidal V G).toFunctor := by
+  change faithful (forget V G); infer_instance
 #align Action.forget_monoidal_faithful Action.forgetMonoidal_faithful
 
 section
@@ -611,10 +542,8 @@ def forgetBraided : BraidedFunctor (Action V G) V :=
   { forgetMonoidal _ _ with }
 #align Action.forget_braided Action.forgetBraided
 
-instance forgetBraided_faithful : Faithful (forgetBraided V G).toFunctor :=
-  by
-  change faithful (forget V G)
-  infer_instance
+instance forgetBraided_faithful : Faithful (forgetBraided V G).toFunctor := by
+  change faithful (forget V G); infer_instance
 #align Action.forget_braided_faithful Action.forgetBraided_faithful
 
 end
@@ -645,10 +574,8 @@ def functorCategoryMonoidalEquivalence : MonoidalFunctor (Action V G) (SingleObj
   Monoidal.fromTransported (Action.functorCategoryEquivalence _ _).symm
 #align Action.functor_category_monoidal_equivalence Action.functorCategoryMonoidalEquivalence
 
-instance : IsEquivalence (functorCategoryMonoidalEquivalence V G).toFunctor :=
-  by
-  change is_equivalence (Action.functorCategoryEquivalence _ _).Functor
-  infer_instance
+instance : IsEquivalence (functorCategoryMonoidalEquivalence V G).toFunctor := by
+  change is_equivalence (Action.functorCategoryEquivalence _ _).Functor; infer_instance
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
@@ -723,28 +650,22 @@ theorem functorCategoryMonoidalEquivalence.inverse_map {A B : SingleObj G ⥤ V}
 
 variable (H : GroupCat.{u})
 
-instance [RightRigidCategory V] : RightRigidCategory (SingleObj (H : MonCat.{u}) ⥤ V) :=
-  by
-  change right_rigid_category (single_obj H ⥤ V)
-  infer_instance
+instance [RightRigidCategory V] : RightRigidCategory (SingleObj (H : MonCat.{u}) ⥤ V) := by
+  change right_rigid_category (single_obj H ⥤ V); infer_instance
 
 /-- If `V` is right rigid, so is `Action V G`. -/
 instance [RightRigidCategory V] : RightRigidCategory (Action V H) :=
   rightRigidCategoryOfEquivalence (functorCategoryMonoidalEquivalence V _)
 
-instance [LeftRigidCategory V] : LeftRigidCategory (SingleObj (H : MonCat.{u}) ⥤ V) :=
-  by
-  change left_rigid_category (single_obj H ⥤ V)
-  infer_instance
+instance [LeftRigidCategory V] : LeftRigidCategory (SingleObj (H : MonCat.{u}) ⥤ V) := by
+  change left_rigid_category (single_obj H ⥤ V); infer_instance
 
 /-- If `V` is left rigid, so is `Action V G`. -/
 instance [LeftRigidCategory V] : LeftRigidCategory (Action V H) :=
   leftRigidCategoryOfEquivalence (functorCategoryMonoidalEquivalence V _)
 
-instance [RigidCategory V] : RigidCategory (SingleObj (H : MonCat.{u}) ⥤ V) :=
-  by
-  change rigid_category (single_obj H ⥤ V)
-  infer_instance
+instance [RigidCategory V] : RigidCategory (SingleObj (H : MonCat.{u}) ⥤ V) := by
+  change rigid_category (single_obj H ⥤ V); infer_instance
 
 /-- If `V` is rigid, so is `Action V G`. -/
 instance [RigidCategory V] : RigidCategory (Action V H) :=
@@ -769,19 +690,15 @@ theorem leftDual_v [LeftRigidCategory V] : (ᘁX).V = ᘁX.V :=
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 @[simp]
-theorem rightDual_ρ [RightRigidCategory V] (h : H) : Xᘁ.ρ h = X.ρ (h⁻¹ : H)ᘁ :=
-  by
-  rw [← single_obj.inv_as_inv]
-  rfl
+theorem rightDual_ρ [RightRigidCategory V] (h : H) : Xᘁ.ρ h = X.ρ (h⁻¹ : H)ᘁ := by
+  rw [← single_obj.inv_as_inv]; rfl
 #align Action.right_dual_ρ Action.rightDual_ρ
 
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 @[simp]
-theorem leftDual_ρ [LeftRigidCategory V] (h : H) : (ᘁX).ρ h = ᘁX.ρ (h⁻¹ : H) :=
-  by
-  rw [← single_obj.inv_as_inv]
-  rfl
+theorem leftDual_ρ [LeftRigidCategory V] (h : H) : (ᘁX).ρ h = ᘁX.ρ (h⁻¹ : H) := by
+  rw [← single_obj.inv_as_inv]; rfl
 #align Action.left_dual_ρ Action.leftDual_ρ
 
 end Monoidal
@@ -977,15 +894,9 @@ def mapAction (F : V ⥤ W) (G : MonCat.{u}) : Action V G ⥤ Action W G
           map_mul' := fun g h => by simp only [End.mul_def, F.map_comp, map_mul] } }
   map M N f :=
     { Hom := F.map f.Hom
-      comm' := fun g => by
-        dsimp
-        rw [← F.map_comp, f.comm, F.map_comp] }
-  map_id' M := by
-    ext
-    simp only [Action.id_hom, F.map_id]
-  map_comp' M N P f g := by
-    ext
-    simp only [Action.comp_hom, F.map_comp]
+      comm' := fun g => by dsimp; rw [← F.map_comp, f.comm, F.map_comp] }
+  map_id' M := by ext; simp only [Action.id_hom, F.map_id]
+  map_comp' M N P f g := by ext; simp only [Action.comp_hom, F.map_comp]
 #align category_theory.functor.map_Action CategoryTheory.Functor.mapAction
 
 variable (F : V ⥤ W) (G : MonCat.{u}) [Preadditive V] [Preadditive W]
@@ -1016,40 +927,17 @@ def mapAction : MonoidalFunctor (Action V G) (Action W G) :=
       G with
     ε :=
       { Hom := F.ε
-        comm' := fun g => by
-          dsimp
+        comm' := fun g => by dsimp;
           erw [category.id_comp, CategoryTheory.Functor.map_id, category.comp_id] }
     μ := fun X Y =>
       { Hom := F.μ X.V Y.V
         comm' := fun g => F.toLaxMonoidalFunctor.μ_natural (X.ρ g) (Y.ρ g) }
     ε_isIso := by infer_instance
     μ_isIso := by infer_instance
-    μ_natural' := by
-      intros
-      ext
-      dsimp
-      simp
-    associativity' := by
-      intros
-      ext
-      dsimp
-      simp
-      dsimp
-      simp
-    left_unitality' := by
-      intros
-      ext
-      dsimp
-      simp
-      dsimp
-      simp
-    right_unitality' := by
-      intros
-      ext
-      dsimp
-      simp
-      dsimp
-      simp }
+    μ_natural' := by intros ; ext; dsimp; simp
+    associativity' := by intros ; ext; dsimp; simp; dsimp; simp
+    left_unitality' := by intros ; ext; dsimp; simp; dsimp; simp
+    right_unitality' := by intros ; ext; dsimp; simp; dsimp; simp }
 #align category_theory.monoidal_functor.map_Action CategoryTheory.MonoidalFunctor.mapAction
 
 @[simp]
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Scott Morrison
 
 ! This file was ported from Lean 3 source module representation_theory.Action
-! leanprover-community/mathlib commit c04bc6e93e23aa0182aba53661a2211e80b6feac
+! leanprover-community/mathlib commit 95a87616d63b3cb49d3fe678d416fbe9c4217bf4
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
@@ -19,7 +19,7 @@ import Mathbin.CategoryTheory.Monoidal.Rigid.OfEquivalence
 import Mathbin.CategoryTheory.Monoidal.Rigid.FunctorCategory
 import Mathbin.CategoryTheory.Monoidal.Linear
 import Mathbin.CategoryTheory.Monoidal.Braided
-import Mathbin.CategoryTheory.Monoidal.Types
+import Mathbin.CategoryTheory.Monoidal.Types.Symmetric
 import Mathbin.CategoryTheory.Abelian.FunctorCategory
 import Mathbin.CategoryTheory.Abelian.Transfer
 import Mathbin.CategoryTheory.Conj
Diff
@@ -294,7 +294,7 @@ def forget : Action V G ⥤ V where
 instance : Faithful (forget V G) where map_injective' X Y f g w := Hom.ext _ _ w
 
 instance [ConcreteCategory V] : ConcreteCategory (Action V G)
-    where forget := forget V G ⋙ ConcreteCategory.Forget V
+    where forget := forget V G ⋙ ConcreteCategory.forget V
 
 instance hasForgetToV [ConcreteCategory V] : HasForget₂ (Action V G) V where forget₂ := forget V G
 #align Action.has_forget_to_V Action.hasForgetToV
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Scott Morrison
 
 ! This file was ported from Lean 3 source module representation_theory.Action
-! leanprover-community/mathlib commit 3dec44d0b621a174c56e994da4aae15ba60110a2
+! leanprover-community/mathlib commit c04bc6e93e23aa0182aba53661a2211e80b6feac
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
@@ -19,6 +19,7 @@ import Mathbin.CategoryTheory.Monoidal.Rigid.OfEquivalence
 import Mathbin.CategoryTheory.Monoidal.Rigid.FunctorCategory
 import Mathbin.CategoryTheory.Monoidal.Linear
 import Mathbin.CategoryTheory.Monoidal.Braided
+import Mathbin.CategoryTheory.Monoidal.Types
 import Mathbin.CategoryTheory.Abelian.FunctorCategory
 import Mathbin.CategoryTheory.Abelian.Transfer
 import Mathbin.CategoryTheory.Conj
@@ -573,6 +574,14 @@ theorem rightUnitor_inv_hom {X : Action V G} : Hom.hom (ρ_ X).inv = (ρ_ X.V).i
   simp
 #align Action.right_unitor_inv_hom Action.rightUnitor_inv_hom
 
+/-- Given an object `X` isomorphic to the tensor unit of `V`, `X` equipped with the trivial action
+is isomorphic to the tensor unit of `Action V G`. -/
+def tensorUnitIso {X : V} (f : 𝟙_ V ≅ X) : 𝟙_ (Action V G) ≅ Action.mk X 1 :=
+  Action.mkIso f fun g => by
+    simp only [MonoidHom.one_apply, End.one_def, category.id_comp f.hom, tensor_unit_rho,
+      category.comp_id]
+#align Action.tensor_unit_iso Action.tensorUnitIso
+
 variable (V G)
 
 /-- When `V` is monoidal the forgetful functor `Action V G` to `V` is monoidal. -/
@@ -886,6 +895,69 @@ def ofMulActionLimitCone {ι : Type v} (G : Type max v u) [Monoid G] (F : ι →
         congr }
 #align Action.of_mul_action_limit_cone Action.ofMulActionLimitCone
 
+/-- The `G`-set `G`, acting on itself by left multiplication. -/
+@[simps]
+def leftRegular (G : Type u) [Monoid G] : Action (Type u) (MonCat.of G) :=
+  Action.ofMulAction G G
+#align Action.left_regular Action.leftRegular
+
+/-- The `G`-set `Gⁿ`, acting on itself by left multiplication. -/
+@[simps]
+def diagonal (G : Type u) [Monoid G] (n : ℕ) : Action (Type u) (MonCat.of G) :=
+  Action.ofMulAction G (Fin n → G)
+#align Action.diagonal Action.diagonal
+
+/-- We have `fin 1 → G ≅ G` as `G`-sets, with `G` acting by left multiplication. -/
+def diagonalOneIsoLeftRegular (G : Type u) [Monoid G] : diagonal G 1 ≅ leftRegular G :=
+  Action.mkIso (Equiv.funUnique _ _).toIso fun g => rfl
+#align Action.diagonal_one_iso_left_regular Action.diagonalOneIsoLeftRegular
+
+/- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+/- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+/-- Given `X : Action (Type u) (Mon.of G)` for `G` a group, then `G × X` (with `G` acting as left
+multiplication on the first factor and by `X.ρ` on the second) is isomorphic as a `G`-set to
+`G × X` (with `G` acting as left multiplication on the first factor and trivially on the second).
+The isomorphism is given by `(g, x) ↦ (g, g⁻¹ • x)`. -/
+@[simps]
+def leftRegularTensorIso (G : Type u) [Group G] (X : Action (Type u) (MonCat.of G)) :
+    leftRegular G ⊗ X ≅ leftRegular G ⊗ Action.mk X.V 1
+    where
+  Hom :=
+    { Hom := fun g => ⟨g.1, (X.ρ (g.1⁻¹ : G) g.2 : X.V)⟩
+      comm' := fun g =>
+        funext fun x =>
+          Prod.ext rfl <|
+            show (X.ρ ((g * x.1)⁻¹ : G) * X.ρ g) x.2 = _ by
+              simpa only [mul_inv_rev, ← X.ρ.map_mul, inv_mul_cancel_right] }
+  inv :=
+    { Hom := fun g => ⟨g.1, X.ρ g.1 g.2⟩
+      comm' := fun g =>
+        funext fun x =>
+          Prod.ext rfl <| by
+            simpa only [tensor_rho, types_comp_apply, tensor_apply, left_regular_ρ_apply, map_mul] }
+  hom_inv_id' :=
+    Hom.ext _ _
+      (funext fun x =>
+        Prod.ext rfl <|
+          show (X.ρ x.1 * X.ρ (x.1⁻¹ : G)) x.2 = _ by
+            simpa only [← X.ρ.map_mul, mul_inv_self, X.ρ.map_one] )
+  inv_hom_id' :=
+    Hom.ext _ _
+      (funext fun x =>
+        Prod.ext rfl <|
+          show (X.ρ (x.1⁻¹ : G) * X.ρ x.1) _ = _ by
+            simpa only [← X.ρ.map_mul, inv_mul_self, X.ρ.map_one] )
+#align Action.left_regular_tensor_iso Action.leftRegularTensorIso
+
+/- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+/-- The natural isomorphism of `G`-sets `Gⁿ⁺¹ ≅ G × Gⁿ`, where `G` acts by left multiplication on
+each factor. -/
+@[simps]
+def diagonalSucc (G : Type u) [Monoid G] (n : ℕ) :
+    diagonal G (n + 1) ≅ leftRegular G ⊗ diagonal G n :=
+  mkIso (Equiv.piFinSuccAboveEquiv _ 0).toIso fun g => rfl
+#align Action.diagonal_succ Action.diagonalSucc
+
 end Action
 
 namespace CategoryTheory.Functor
@@ -933,12 +1005,12 @@ namespace CategoryTheory.MonoidalFunctor
 open Action
 
 variable {V} {W : Type (u + 1)} [LargeCategory W] [MonoidalCategory V] [MonoidalCategory W]
+  (F : MonoidalFunctor V W) (G : MonCat.{u})
 
 /-- A monoidal functor induces a monoidal functor between
 the categories of `G`-actions within those categories. -/
 @[simps]
-def mapAction (F : MonoidalFunctor V W) (G : MonCat.{u}) :
-    MonoidalFunctor (Action V G) (Action W G) :=
+def mapAction : MonoidalFunctor (Action V G) (Action W G) :=
   {-- See note [dsimp, simp].
           F.toFunctor.mapAction
       G with
@@ -980,5 +1052,22 @@ def mapAction (F : MonoidalFunctor V W) (G : MonCat.{u}) :
       simp }
 #align category_theory.monoidal_functor.map_Action CategoryTheory.MonoidalFunctor.mapAction
 
+@[simp]
+theorem mapAction_ε_inv_hom : (inv (F.mapAction G).ε).Hom = inv F.ε :=
+  by
+  ext
+  simp only [← F.map_Action_to_lax_monoidal_functor_ε_hom G, ← Action.comp_hom, is_iso.hom_inv_id,
+    id_hom]
+#align category_theory.monoidal_functor.map_Action_ε_inv_hom CategoryTheory.MonoidalFunctor.mapAction_ε_inv_hom
+
+@[simp]
+theorem mapAction_μ_inv_hom (X Y : Action V G) :
+    (inv ((F.mapAction G).μ X Y)).Hom = inv (F.μ X.V Y.V) :=
+  by
+  ext
+  simpa only [← F.map_Action_to_lax_monoidal_functor_μ_hom G, ← Action.comp_hom, is_iso.hom_inv_id,
+    id_hom]
+#align category_theory.monoidal_functor.map_Action_μ_inv_hom CategoryTheory.MonoidalFunctor.mapAction_μ_inv_hom
+
 end CategoryTheory.MonoidalFunctor
 
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Scott Morrison
 
 ! This file was ported from Lean 3 source module representation_theory.Action
-! leanprover-community/mathlib commit 0caf3701139ef2e69c215717665361cda205a90b
+! leanprover-community/mathlib commit 3dec44d0b621a174c56e994da4aae15ba60110a2
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
@@ -702,14 +702,13 @@ theorem functorCategoryMonoidalEquivalence.unit_app_hom (A : Action V G) :
 
 @[simp]
 theorem functorCategoryMonoidalEquivalence.functor_map {A B : Action V G} (f : A ⟶ B) :
-    (functorCategoryMonoidalEquivalence _ _).1.1.map f = FunctorCategoryEquivalence.functor.map f :=
+    (functorCategoryMonoidalEquivalence _ _).map f = FunctorCategoryEquivalence.functor.map f :=
   rfl
 #align Action.functor_category_monoidal_equivalence.functor_map Action.functorCategoryMonoidalEquivalence.functor_map
 
 @[simp]
 theorem functorCategoryMonoidalEquivalence.inverse_map {A B : SingleObj G ⥤ V} (f : A ⟶ B) :
-    (functorCategoryMonoidalEquivalence _ _).1.inv.map f =
-      FunctorCategoryEquivalence.inverse.map f :=
+    (functorCategoryMonoidalEquivalence _ _).inv.map f = FunctorCategoryEquivalence.inverse.map f :=
   rfl
 #align Action.functor_category_monoidal_equivalence.inverse_map Action.functorCategoryMonoidalEquivalence.inverse_map
 
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Scott Morrison
 
 ! This file was ported from Lean 3 source module representation_theory.Action
-! leanprover-community/mathlib commit ac3ae212f394f508df43e37aa093722fa9b65d31
+! leanprover-community/mathlib commit 0caf3701139ef2e69c215717665361cda205a90b
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
@@ -249,6 +249,16 @@ def functorCategoryEquivalence : Action V G ≌ SingleObj G ⥤ V
 
 attribute [simps] functor_category_equivalence
 
+theorem functorCategoryEquivalence.functor_def :
+    (functorCategoryEquivalence V G).Functor = FunctorCategoryEquivalence.functor :=
+  rfl
+#align Action.functor_category_equivalence.functor_def Action.functorCategoryEquivalence.functor_def
+
+theorem functorCategoryEquivalence.inverse_def :
+    (functorCategoryEquivalence V G).inverse = FunctorCategoryEquivalence.inverse :=
+  rfl
+#align Action.functor_category_equivalence.inverse_def Action.functorCategoryEquivalence.inverse_def
+
 instance [HasFiniteProducts V] : HasFiniteProducts (Action V G)
     where out n :=
     Adjunction.hasLimitsOfShape_of_equivalence (Action.functorCategoryEquivalence _ _).Functor
@@ -631,6 +641,78 @@ instance : IsEquivalence (functorCategoryMonoidalEquivalence V G).toFunctor :=
   change is_equivalence (Action.functorCategoryEquivalence _ _).Functor
   infer_instance
 
+/- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+/- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+/- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+/- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+@[simp]
+theorem functorCategoryMonoidalEquivalence.μ_app (A B : Action V G) :
+    ((functorCategoryMonoidalEquivalence V G).μ A B).app PUnit.unit = 𝟙 _ :=
+  by
+  dsimp only [functor_category_monoidal_equivalence]
+  simp only [monoidal.from_transported_to_lax_monoidal_functor_μ]
+  show (𝟙 A.V ⊗ 𝟙 B.V) ≫ 𝟙 (A.V ⊗ B.V) ≫ (𝟙 A.V ⊗ 𝟙 B.V) = 𝟙 (A.V ⊗ B.V)
+  simp only [monoidal_category.tensor_id, category.comp_id]
+#align Action.functor_category_monoidal_equivalence.μ_app Action.functorCategoryMonoidalEquivalence.μ_app
+
+@[simp]
+theorem functorCategoryMonoidalEquivalence.μIso_inv_app (A B : Action V G) :
+    ((functorCategoryMonoidalEquivalence V G).μIso A B).inv.app PUnit.unit = 𝟙 _ :=
+  by
+  rw [← nat_iso.app_inv, ← is_iso.iso.inv_hom]
+  refine' is_iso.inv_eq_of_hom_inv_id _
+  rw [category.comp_id, nat_iso.app_hom, monoidal_functor.μ_iso_hom,
+    functor_category_monoidal_equivalence.μ_app]
+#align Action.functor_category_monoidal_equivalence.μ_iso_inv_app Action.functorCategoryMonoidalEquivalence.μIso_inv_app
+
+@[simp]
+theorem functorCategoryMonoidalEquivalence.ε_app :
+    (functorCategoryMonoidalEquivalence V G).ε.app PUnit.unit = 𝟙 _ :=
+  by
+  dsimp only [functor_category_monoidal_equivalence]
+  simp only [monoidal.from_transported_to_lax_monoidal_functor_ε]
+  show 𝟙 (monoidal_category.tensor_unit V) ≫ _ = 𝟙 (monoidal_category.tensor_unit V)
+  rw [nat_iso.is_iso_inv_app, category.id_comp]
+  exact is_iso.inv_id
+#align Action.functor_category_monoidal_equivalence.ε_app Action.functorCategoryMonoidalEquivalence.ε_app
+
+@[simp]
+theorem functorCategoryMonoidalEquivalence.inv_counit_app_hom (A : Action V G) :
+    ((functorCategoryMonoidalEquivalence _ _).inv.Adjunction.counit.app A).Hom = 𝟙 _ :=
+  rfl
+#align Action.functor_category_monoidal_equivalence.inv_counit_app_hom Action.functorCategoryMonoidalEquivalence.inv_counit_app_hom
+
+@[simp]
+theorem functorCategoryMonoidalEquivalence.counit_app (A : SingleObj G ⥤ V) :
+    ((functorCategoryMonoidalEquivalence _ _).Adjunction.counit.app A).app PUnit.unit = 𝟙 _ :=
+  rfl
+#align Action.functor_category_monoidal_equivalence.counit_app Action.functorCategoryMonoidalEquivalence.counit_app
+
+@[simp]
+theorem functorCategoryMonoidalEquivalence.inv_unit_app_app (A : SingleObj G ⥤ V) :
+    ((functorCategoryMonoidalEquivalence _ _).inv.Adjunction.Unit.app A).app PUnit.unit = 𝟙 _ :=
+  rfl
+#align Action.functor_category_monoidal_equivalence.inv_unit_app_app Action.functorCategoryMonoidalEquivalence.inv_unit_app_app
+
+@[simp]
+theorem functorCategoryMonoidalEquivalence.unit_app_hom (A : Action V G) :
+    ((functorCategoryMonoidalEquivalence _ _).Adjunction.Unit.app A).Hom = 𝟙 _ :=
+  rfl
+#align Action.functor_category_monoidal_equivalence.unit_app_hom Action.functorCategoryMonoidalEquivalence.unit_app_hom
+
+@[simp]
+theorem functorCategoryMonoidalEquivalence.functor_map {A B : Action V G} (f : A ⟶ B) :
+    (functorCategoryMonoidalEquivalence _ _).1.1.map f = FunctorCategoryEquivalence.functor.map f :=
+  rfl
+#align Action.functor_category_monoidal_equivalence.functor_map Action.functorCategoryMonoidalEquivalence.functor_map
+
+@[simp]
+theorem functorCategoryMonoidalEquivalence.inverse_map {A B : SingleObj G ⥤ V} (f : A ⟶ B) :
+    (functorCategoryMonoidalEquivalence _ _).1.inv.map f =
+      FunctorCategoryEquivalence.inverse.map f :=
+  rfl
+#align Action.functor_category_monoidal_equivalence.inverse_map Action.functorCategoryMonoidalEquivalence.inverse_map
+
 variable (H : GroupCat.{u})
 
 instance [RightRigidCategory V] : RightRigidCategory (SingleObj (H : MonCat.{u}) ⥤ V) :=
Diff
@@ -54,9 +54,9 @@ the monoid `G` on an object of some category `V`.
 As an example, when `V = Module R`, this is an `R`-linear representation of `G`,
 while when `V = Type` this is a `G`-action.
 -/
-structure Action (G : Mon.{u}) where
+structure Action (G : MonCat.{u}) where
   V : V
-  ρ : G ⟶ Mon.of (End V)
+  ρ : G ⟶ MonCat.of (End V)
 #align Action Action
 
 namespace Action
@@ -64,7 +64,7 @@ namespace Action
 variable {V}
 
 @[simp]
-theorem ρ_one {G : Mon.{u}} (A : Action V G) : A.ρ 1 = 𝟙 A.V :=
+theorem ρ_one {G : MonCat.{u}} (A : Action V G) : A.ρ 1 = 𝟙 A.V :=
   by
   rw [MonoidHom.map_one]
   rfl
@@ -72,7 +72,7 @@ theorem ρ_one {G : Mon.{u}} (A : Action V G) : A.ρ 1 = 𝟙 A.V :=
 
 /-- When a group acts, we can lift the action to the group of automorphisms. -/
 @[simps]
-def ρAut {G : GroupCat.{u}} (A : Action V (Mon.of G)) : G ⟶ GroupCat.of (Aut A.V)
+def ρAut {G : GroupCat.{u}} (A : Action V (MonCat.of G)) : G ⟶ GroupCat.of (Aut A.V)
     where
   toFun g :=
     { Hom := A.ρ g
@@ -87,7 +87,7 @@ def ρAut {G : GroupCat.{u}} (A : Action V (Mon.of G)) : G ⟶ GroupCat.of (Aut
     exact A.ρ.map_mul x y
 #align Action.ρ_Aut Action.ρAut
 
-variable (G : Mon.{u})
+variable (G : MonCat.{u})
 
 section
 
@@ -633,7 +633,7 @@ instance : IsEquivalence (functorCategoryMonoidalEquivalence V G).toFunctor :=
 
 variable (H : GroupCat.{u})
 
-instance [RightRigidCategory V] : RightRigidCategory (SingleObj (H : Mon.{u}) ⥤ V) :=
+instance [RightRigidCategory V] : RightRigidCategory (SingleObj (H : MonCat.{u}) ⥤ V) :=
   by
   change right_rigid_category (single_obj H ⥤ V)
   infer_instance
@@ -642,7 +642,7 @@ instance [RightRigidCategory V] : RightRigidCategory (SingleObj (H : Mon.{u}) 
 instance [RightRigidCategory V] : RightRigidCategory (Action V H) :=
   rightRigidCategoryOfEquivalence (functorCategoryMonoidalEquivalence V _)
 
-instance [LeftRigidCategory V] : LeftRigidCategory (SingleObj (H : Mon.{u}) ⥤ V) :=
+instance [LeftRigidCategory V] : LeftRigidCategory (SingleObj (H : MonCat.{u}) ⥤ V) :=
   by
   change left_rigid_category (single_obj H ⥤ V)
   infer_instance
@@ -651,7 +651,7 @@ instance [LeftRigidCategory V] : LeftRigidCategory (SingleObj (H : Mon.{u}) ⥤
 instance [LeftRigidCategory V] : LeftRigidCategory (Action V H) :=
   leftRigidCategoryOfEquivalence (functorCategoryMonoidalEquivalence V _)
 
-instance [RigidCategory V] : RigidCategory (SingleObj (H : Mon.{u}) ⥤ V) :=
+instance [RigidCategory V] : RigidCategory (SingleObj (H : MonCat.{u}) ⥤ V) :=
   by
   change rigid_category (single_obj H ⥤ V)
   infer_instance
@@ -697,7 +697,7 @@ theorem leftDual_ρ [LeftRigidCategory V] (h : H) : (ᘁX).ρ h = ᘁX.ρ (h⁻
 end Monoidal
 
 /-- Actions/representations of the trivial group are just objects in the ambient category. -/
-def actionPunitEquivalence : Action V (Mon.of PUnit) ≌ V
+def actionPunitEquivalence : Action V (MonCat.of PUnit) ≌ V
     where
   Functor := forget V _
   inverse :=
@@ -716,7 +716,7 @@ taking actions of `H` to actions of `G`.
 (This makes sense for any homomorphism, but the name is natural when `f` is a monomorphism.)
 -/
 @[simps]
-def res {G H : Mon} (f : G ⟶ H) : Action V H ⥤ Action V G
+def res {G H : MonCat} (f : G ⟶ H) : Action V H ⥤ Action V G
     where
   obj M :=
     { V := M.V
@@ -729,7 +729,7 @@ def res {G H : Mon} (f : G ⟶ H) : Action V H ⥤ Action V G
 /-- The natural isomorphism from restriction along the identity homomorphism to
 the identity functor on `Action V G`.
 -/
-def resId {G : Mon} : res V (𝟙 G) ≅ 𝟭 (Action V G) :=
+def resId {G : MonCat} : res V (𝟙 G) ≅ 𝟭 (Action V G) :=
   NatIso.ofComponents (fun M => mkIso (Iso.refl _) (by tidy)) (by tidy)
 #align Action.res_id Action.resId
 
@@ -738,7 +738,7 @@ attribute [simps] res_id
 /-- The natural isomorphism from the composition of restrictions along homomorphisms
 to the restriction along the composition of homomorphism.
 -/
-def resComp {G H K : Mon} (f : G ⟶ H) (g : H ⟶ K) : res V g ⋙ res V f ≅ res V (f ≫ g) :=
+def resComp {G H K : MonCat} (f : G ⟶ H) (g : H ⟶ K) : res V g ⋙ res V f ≅ res V (f ≫ g) :=
   NatIso.ofComponents (fun M => mkIso (Iso.refl _) (by tidy)) (by tidy)
 #align Action.res_comp Action.resComp
 
@@ -746,7 +746,7 @@ attribute [simps] res_comp
 
 -- TODO promote `res` to a pseudofunctor from
 -- the locally discrete bicategory constructed from `Monᵒᵖ` to `Cat`, sending `G` to `Action V G`.
-variable {G} {H : Mon.{u}} (f : G ⟶ H)
+variable {G} {H : MonCat.{u}} (f : G ⟶ H)
 
 instance res_additive [Preadditive V] : (res V f).Additive where
 #align Action.res_additive Action.res_additive
@@ -757,7 +757,7 @@ instance res_linear [Preadditive V] [Linear R V] : (res V f).Linear R where
 #align Action.res_linear Action.res_linear
 
 /-- Bundles a type `H` with a multiplicative action of `G` as an `Action`. -/
-def ofMulAction (G H : Type u) [Monoid G] [MulAction G H] : Action (Type u) (Mon.of G)
+def ofMulAction (G H : Type u) [Monoid G] [MulAction G H] : Action (Type u) (MonCat.of G)
     where
   V := H
   ρ := @MulAction.toEndHom _ _ _ (by assumption)
@@ -814,7 +814,7 @@ variable {V} {W : Type (u + 1)} [LargeCategory W]
 /-- A functor between categories induces a functor between
 the categories of `G`-actions within those categories. -/
 @[simps]
-def mapAction (F : V ⥤ W) (G : Mon.{u}) : Action V G ⥤ Action W G
+def mapAction (F : V ⥤ W) (G : MonCat.{u}) : Action V G ⥤ Action W G
     where
   obj M :=
     { V := F.obj M.V
@@ -835,7 +835,7 @@ def mapAction (F : V ⥤ W) (G : Mon.{u}) : Action V G ⥤ Action W G
     simp only [Action.comp_hom, F.map_comp]
 #align category_theory.functor.map_Action CategoryTheory.Functor.mapAction
 
-variable (F : V ⥤ W) (G : Mon.{u}) [Preadditive V] [Preadditive W]
+variable (F : V ⥤ W) (G : MonCat.{u}) [Preadditive V] [Preadditive W]
 
 instance mapAction_preadditive [F.Additive] : (F.mapAction G).Additive where
 #align category_theory.functor.map_Action_preadditive CategoryTheory.Functor.mapAction_preadditive
@@ -856,7 +856,8 @@ variable {V} {W : Type (u + 1)} [LargeCategory W] [MonoidalCategory V] [Monoidal
 /-- A monoidal functor induces a monoidal functor between
 the categories of `G`-actions within those categories. -/
 @[simps]
-def mapAction (F : MonoidalFunctor V W) (G : Mon.{u}) : MonoidalFunctor (Action V G) (Action W G) :=
+def mapAction (F : MonoidalFunctor V W) (G : MonCat.{u}) :
+    MonoidalFunctor (Action V G) (Action W G) :=
   {-- See note [dsimp, simp].
           F.toFunctor.mapAction
       G with
Diff
@@ -454,15 +454,15 @@ instance : Linear R (Action V G)
     ext
     exact linear.comp_smul _ _ _ _ _ _
 
-instance forgetLinear : Functor.Linear R (forget V G) where
-#align Action.forget_linear Action.forgetLinear
+instance forget_linear : Functor.Linear R (forget V G) where
+#align Action.forget_linear Action.forget_linear
 
-instance forget₂Linear [ConcreteCategory V] : Functor.Linear R (forget₂ (Action V G) V) where
-#align Action.forget₂_linear Action.forget₂Linear
+instance forget₂_linear [ConcreteCategory V] : Functor.Linear R (forget₂ (Action V G) V) where
+#align Action.forget₂_linear Action.forget₂_linear
 
-instance functorCategoryEquivalenceLinear :
+instance functorCategoryEquivalence_linear :
     Functor.Linear R (functorCategoryEquivalence V G).Functor where
-#align Action.functor_category_equivalence_linear Action.functorCategoryEquivalenceLinear
+#align Action.functor_category_equivalence_linear Action.functorCategoryEquivalence_linear
 
 @[simp]
 theorem smul_hom {X Y : Action V G} (r : R) (f : X ⟶ Y) : (r • f).Hom = r • f.Hom :=
@@ -753,8 +753,8 @@ instance res_additive [Preadditive V] : (res V f).Additive where
 
 variable {R : Type _} [Semiring R]
 
-instance resLinear [Preadditive V] [Linear R V] : (res V f).Linear R where
-#align Action.res_linear Action.resLinear
+instance res_linear [Preadditive V] [Linear R V] : (res V f).Linear R where
+#align Action.res_linear Action.res_linear
 
 /-- Bundles a type `H` with a multiplicative action of `G` as an `Action`. -/
 def ofMulAction (G H : Type u) [Monoid G] [MulAction G H] : Action (Type u) (Mon.of G)
@@ -842,8 +842,8 @@ instance mapAction_preadditive [F.Additive] : (F.mapAction G).Additive where
 
 variable {R : Type _} [Semiring R] [CategoryTheory.Linear R V] [CategoryTheory.Linear R W]
 
-instance mapActionLinear [F.Additive] [F.Linear R] : (F.mapAction G).Linear R where
-#align category_theory.functor.map_Action_linear CategoryTheory.Functor.mapActionLinear
+instance mapAction_linear [F.Additive] [F.Linear R] : (F.mapAction G).Linear R where
+#align category_theory.functor.map_Action_linear CategoryTheory.Functor.mapAction_linear
 
 end CategoryTheory.Functor
 
Diff
@@ -371,11 +371,11 @@ instance : Preadditive (Action V G)
         intros
         ext
         exact add_comm _ _ }
-  add_comp' := by
+  add_comp := by
     intros
     ext
     exact preadditive.add_comp _ _ _ _ _ _
-  comp_add' := by
+  comp_add := by
     intros
     ext
     exact preadditive.comp_add _ _ _ _ _ _
Diff
@@ -321,10 +321,10 @@ instance : HasZeroMorphisms (Action V G)
     ⟨⟨0, by
         intro g
         simp⟩⟩
-  comp_zero' P Q f R := by
+  comp_zero P Q f R := by
     ext1
     simp
-  zero_comp' P Q R f := by
+  zero_comp P Q R f := by
     ext1
     simp
 
Diff
@@ -283,7 +283,7 @@ def forget : Action V G ⥤ V where
 instance : Faithful (forget V G) where map_injective' X Y f g w := Hom.ext _ _ w
 
 instance [ConcreteCategory V] : ConcreteCategory (Action V G)
-    where forget := forget V G ⋙ ConcreteCategory.forget V
+    where forget := forget V G ⋙ ConcreteCategory.Forget V
 
 instance hasForgetToV [ConcreteCategory V] : HasForget₂ (Action V G) V where forget₂ := forget V G
 #align Action.has_forget_to_V Action.hasForgetToV
Diff
@@ -769,7 +769,7 @@ theorem ofMulAction_apply {G H : Type u} [Monoid G] [MulAction G H] (g : G) (x :
   rfl
 #align Action.of_mul_action_apply Action.ofMulAction_apply
 
-/- ./././Mathport/Syntax/Translate/Tactic/Builtin.lean:76:14: unsupported tactic `discrete_cases #[] -/
+/- ./././Mathport/Syntax/Translate/Tactic/Builtin.lean:73:14: unsupported tactic `discrete_cases #[] -/
 /-- Given a family `F` of types with `G`-actions, this is the limit cone demonstrating that the
 product of `F` as types is a product in the category of `G`-sets. -/
 def ofMulActionLimitCone {ι : Type v} (G : Type max v u) [Monoid G] (F : ι → Type max v u)
@@ -783,7 +783,7 @@ def ofMulActionLimitCone {ι : Type v} (G : Type max v u) [Monoid G] (F : ι →
           naturality' := fun i j x => by
             ext
             trace
-              "./././Mathport/Syntax/Translate/Tactic/Builtin.lean:76:14: unsupported tactic `discrete_cases #[]"
+              "./././Mathport/Syntax/Translate/Tactic/Builtin.lean:73:14: unsupported tactic `discrete_cases #[]"
             cases x
             congr } }
   IsLimit :=
Diff
@@ -777,7 +777,7 @@ def ofMulActionLimitCone {ι : Type v} (G : Type max v u) [Monoid G] (F : ι →
     LimitCone (Discrete.functor fun i : ι => Action.ofMulAction G (F i))
     where
   Cone :=
-    { x := Action.ofMulAction G (∀ i : ι, F i)
+    { pt := Action.ofMulAction G (∀ i : ι, F i)
       π :=
         { app := fun i => ⟨fun x => x i.as, fun g => by ext <;> rfl⟩
           naturality' := fun i j x => by
Diff
@@ -251,17 +251,17 @@ attribute [simps] functor_category_equivalence
 
 instance [HasFiniteProducts V] : HasFiniteProducts (Action V G)
     where out n :=
-    Adjunction.hasLimitsOfShapeOfEquivalence (Action.functorCategoryEquivalence _ _).Functor
+    Adjunction.hasLimitsOfShape_of_equivalence (Action.functorCategoryEquivalence _ _).Functor
 
 instance [HasFiniteLimits V] : HasFiniteLimits (Action V G)
     where out J _ _ :=
     adjunction.has_limits_of_shape_of_equivalence (Action.functorCategoryEquivalence _ _).Functor
 
 instance [HasLimits V] : HasLimits (Action V G) :=
-  Adjunction.hasLimitsOfEquivalence (Action.functorCategoryEquivalence _ _).Functor
+  Adjunction.has_limits_of_equivalence (Action.functorCategoryEquivalence _ _).Functor
 
 instance [HasColimits V] : HasColimits (Action V G) :=
-  Adjunction.hasColimitsOfEquivalence (Action.functorCategoryEquivalence _ _).Functor
+  Adjunction.has_colimits_of_equivalence (Action.functorCategoryEquivalence _ _).Functor
 
 end
 
@@ -793,12 +793,12 @@ def ofMulActionLimitCone {ι : Type v} (G : Type max v u) [Monoid G] (F : ι →
             ext (x j)
             dsimp
             exact congr_fun ((s.π.app ⟨j⟩).comm g) x }
-      fac' := fun s j => by
+      fac := fun s j => by
         ext
         dsimp
         congr
         rw [discrete.mk_as]
-      uniq' := fun s f h => by
+      uniq := fun s f h => by
         ext (x j)
         dsimp at *
         rw [← h ⟨j⟩]

Changes in mathlib4

mathlib3
mathlib4
chore(CategoryTheory): move Full, Faithful, EssSurj, IsEquivalence and ReflectsIsomorphisms to the Functor namespace (#11985)

These notions on functors are now Functor.Full, Functor.Faithful, Functor.EssSurj, Functor.IsEquivalence, Functor.ReflectsIsomorphisms. Deprecated aliases are introduced for the previous names.

Diff
@@ -273,7 +273,7 @@ def forget : Action V G ⥤ V where
 set_option linter.uppercaseLean3 false in
 #align Action.forget Action.forget
 
-instance : Faithful (forget V G) where map_injective w := Hom.ext _ _ w
+instance : (forget V G).Faithful where map_injective w := Hom.ext _ _ w
 
 instance [ConcreteCategory V] : ConcreteCategory (Action V G) where
   forget := forget V G ⋙ ConcreteCategory.forget
style: homogenise porting notes (#11145)

Homogenises porting notes via capitalisation and addition of whitespace.

It makes the following changes:

  • converts "--porting note" into "-- Porting note";
  • converts "porting note" into "Porting note".
Diff
@@ -129,7 +129,7 @@ instance : Category (Action V G) where
   id M := Hom.id M
   comp f g := Hom.comp f g
 
--- porting note: added because `Hom.ext` is not triggered automatically
+-- Porting note: added because `Hom.ext` is not triggered automatically
 @[ext]
 lemma hom_ext {M N : Action V G} (φ₁ φ₂ : M ⟶ N) (h : φ₁.hom = φ₂.hom) : φ₁ = φ₂ :=
   Hom.ext _ _ h
feat: add lake exe shake to CI (#9751)

This checks files for unused imports. The output here is piped through gh-problem-matcher-wrap so that it will show up as annotations.

Co-authored-by: Mario Carneiro <di.gama@gmail.com>

Diff
@@ -9,7 +9,6 @@ import Mathlib.CategoryTheory.Limits.FunctorCategory
 import Mathlib.CategoryTheory.Limits.Preserves.Basic
 import Mathlib.CategoryTheory.Adjunction.Limits
 import Mathlib.CategoryTheory.Conj
-import Mathlib.Data.Fin.Basic
 
 #align_import representation_theory.Action from "leanprover-community/mathlib"@"95a87616d63b3cb49d3fe678d416fbe9c4217bf4"
 
doc: fix typos (#10171)

Fix minor typos in the following files:

  • GroupTheory/Nilpotent.lean
  • GroupTheory/PushoutI.lean
  • SetTheory/Cardinal/ENat.lean
  • SetTheory/Cardinal/Subfield.lean
  • RepresentationTheory/Action/Basic.lean
  • RepresentationTheory/Action/Limits.lean
  • Logic/Function/OfArity.lean
Diff
@@ -176,7 +176,7 @@ set_option linter.uppercaseLean3 false in
 
 namespace FunctorCategoryEquivalence
 
-/-- Auxilliary definition for `functorCategoryEquivalence`. -/
+/-- Auxiliary definition for `functorCategoryEquivalence`. -/
 @[simps]
 def functor : Action V G ⥤ SingleObj G ⥤ V where
   obj M :=
@@ -190,7 +190,7 @@ def functor : Action V G ⥤ SingleObj G ⥤ V where
 set_option linter.uppercaseLean3 false in
 #align Action.functor_category_equivalence.functor Action.FunctorCategoryEquivalence.functor
 
-/-- Auxilliary definition for `functorCategoryEquivalence`. -/
+/-- Auxiliary definition for `functorCategoryEquivalence`. -/
 @[simps]
 def inverse : (SingleObj G ⥤ V) ⥤ Action V G where
   obj F :=
@@ -205,14 +205,14 @@ def inverse : (SingleObj G ⥤ V) ⥤ Action V G where
 set_option linter.uppercaseLean3 false in
 #align Action.functor_category_equivalence.inverse Action.FunctorCategoryEquivalence.inverse
 
-/-- Auxilliary definition for `functorCategoryEquivalence`. -/
+/-- Auxiliary definition for `functorCategoryEquivalence`. -/
 @[simps!]
 def unitIso : 𝟭 (Action V G) ≅ functor ⋙ inverse :=
   NatIso.ofComponents fun M => mkIso (Iso.refl _)
 set_option linter.uppercaseLean3 false in
 #align Action.functor_category_equivalence.unit_iso Action.FunctorCategoryEquivalence.unitIso
 
-/-- Auxilliary definition for `functorCategoryEquivalence`. -/
+/-- Auxiliary definition for `functorCategoryEquivalence`. -/
 @[simps!]
 def counitIso : inverse ⋙ functor ≅ 𝟭 (SingleObj G ⥤ V) :=
   NatIso.ofComponents fun M => NatIso.ofComponents fun X => Iso.refl _
chore(RepresentationTheory/Action): Factor out constructors for Action V G from MulAction G X (#9662)

Further splits Mathlib.RepresentationTheory.Action.Basic and factors out the construction of objects of Action V G from a MulAction G X instance.

Diff
@@ -362,65 +362,6 @@ set_option linter.uppercaseLean3 false in
 -- TODO promote `res` to a pseudofunctor from
 -- the locally discrete bicategory constructed from `Monᵒᵖ` to `Cat`, sending `G` to `Action V G`.
 
-/-- Bundles a type `H` with a multiplicative action of `G` as an `Action`. -/
-def ofMulAction (G H : Type u) [Monoid G] [MulAction G H] : Action (Type u) (MonCat.of G) where
-  V := H
-  ρ := @MulAction.toEndHom _ _ _ (by assumption)
-set_option linter.uppercaseLean3 false in
-#align Action.of_mul_action Action.ofMulAction
-
-@[simp]
-theorem ofMulAction_apply {G H : Type u} [Monoid G] [MulAction G H] (g : G) (x : H) :
-    (ofMulAction G H).ρ g x = (g • x : H) :=
-  rfl
-set_option linter.uppercaseLean3 false in
-#align Action.of_mul_action_apply Action.ofMulAction_apply
-
-/-- Given a family `F` of types with `G`-actions, this is the limit cone demonstrating that the
-product of `F` as types is a product in the category of `G`-sets. -/
-def ofMulActionLimitCone {ι : Type v} (G : Type max v u) [Monoid G] (F : ι → Type max v u)
-    [∀ i : ι, MulAction G (F i)] :
-    LimitCone (Discrete.functor fun i : ι => Action.ofMulAction G (F i)) where
-  cone :=
-    { pt := Action.ofMulAction G (∀ i : ι, F i)
-      π := Discrete.natTrans (fun i => ⟨fun x => x i.as, fun g => rfl⟩) }
-  isLimit :=
-    { lift := fun s =>
-        { hom := fun x i => (s.π.app ⟨i⟩).hom x
-          comm := fun g => by
-            ext x
-            funext j
-            exact congr_fun ((s.π.app ⟨j⟩).comm g) x }
-      fac := fun s j => rfl
-      uniq := fun s f h => by
-        ext x
-        funext j
-        dsimp at *
-        rw [← h ⟨j⟩]
-        rfl }
-set_option linter.uppercaseLean3 false in
-#align Action.of_mul_action_limit_cone Action.ofMulActionLimitCone
-
-/-- The `G`-set `G`, acting on itself by left multiplication. -/
-@[simps!]
-def leftRegular (G : Type u) [Monoid G] : Action (Type u) (MonCat.of G) :=
-  Action.ofMulAction G G
-set_option linter.uppercaseLean3 false in
-#align Action.left_regular Action.leftRegular
-
-/-- The `G`-set `Gⁿ`, acting on itself by left multiplication. -/
-@[simps!]
-def diagonal (G : Type u) [Monoid G] (n : ℕ) : Action (Type u) (MonCat.of G) :=
-  Action.ofMulAction G (Fin n → G)
-set_option linter.uppercaseLean3 false in
-#align Action.diagonal Action.diagonal
-
-/-- We have `fin 1 → G ≅ G` as `G`-sets, with `G` acting by left multiplication. -/
-def diagonalOneIsoLeftRegular (G : Type u) [Monoid G] : diagonal G 1 ≅ leftRegular G :=
-  Action.mkIso (Equiv.funUnique _ _).toIso fun _ => rfl
-set_option linter.uppercaseLean3 false in
-#align Action.diagonal_one_iso_left_regular Action.diagonalOneIsoLeftRegular
-
 end Action
 
 namespace CategoryTheory.Functor
chore: reduce imports (#9830)

This uses the improved shake script from #9772 to reduce imports across mathlib. The corresponding noshake.json file has been added to #9772.

Co-authored-by: Mario Carneiro <di.gama@gmail.com>

Diff
@@ -9,7 +9,7 @@ import Mathlib.CategoryTheory.Limits.FunctorCategory
 import Mathlib.CategoryTheory.Limits.Preserves.Basic
 import Mathlib.CategoryTheory.Adjunction.Limits
 import Mathlib.CategoryTheory.Conj
-import Mathlib.Algebra.Algebra.Basic
+import Mathlib.Data.Fin.Basic
 
 #align_import representation_theory.Action from "leanprover-community/mathlib"@"95a87616d63b3cb49d3fe678d416fbe9c4217bf4"
 
chore: split RepresentationTheory.Action in multiple files (#8660)

Splits Mathlib.RepresentationTheory.Action in multiple files.

chore: make sure all #align's are on a single line (#8215)

We'll need to do this step anyway when it is time to remove them all.

(See #8214 where I'm benchmarking the removal.)

Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -263,14 +263,11 @@ attribute above
 theorem functorCategoryEquivalence.functor_def :
     (functorCategoryEquivalence V G).functor = FunctorCategoryEquivalence.functor :=
   rfl
-set_option linter.uppercaseLean3 false in
-#align Action.functor_category_equivalence.functor_def Action.functorCategoryEquivalence.functor_def
 
 theorem functorCategoryEquivalence.inverse_def :
     (functorCategoryEquivalence V G).inverse = FunctorCategoryEquivalence.inverse :=
   rfl
-set_option linter.uppercaseLean3 false in
-#align Action.functor_category_equivalence.inverse_def Action.functorCategoryEquivalence.inverse_def-/
+-/
 
 instance [HasFiniteProducts V] : HasFiniteProducts (Action V G) where
   out _ :=
feat(CategoryTheory/Monoidal): add lemmas for whiskering operators (#8191)

Extracted from #6307 as suggested in https://github.com/leanprover-community/mathlib4/pull/6307#discussion_r1371849810 .


Open in Gitpod

Diff
@@ -504,10 +504,20 @@ set_option linter.uppercaseLean3 false in
 #align Action.tensor_rho Action.tensor_rho
 
 @[simp]
-theorem tensorHom {W X Y Z : Action V G} (f : W ⟶ X) (g : Y ⟶ Z) : (f ⊗ g).hom = f.hom ⊗ g.hom :=
+theorem tensor_hom {W X Y Z : Action V G} (f : W ⟶ X) (g : Y ⟶ Z) : (f ⊗ g).hom = f.hom ⊗ g.hom :=
   rfl
 set_option linter.uppercaseLean3 false in
-#align Action.tensor_hom Action.tensorHom
+#align Action.tensor_hom Action.tensor_hom
+
+@[simp]
+theorem whiskerLeft_hom (X : Action V G) {Y Z : Action V G} (f : Y ⟶ Z) :
+    (X ◁ f).hom = X.V ◁ f.hom :=
+  rfl
+
+@[simp]
+theorem whiskerRight_hom {X Y : Action V G} (f : X ⟶ Y) (Z : Action V G) :
+    (f ▷ Z).hom = f.hom ▷ Z.V :=
+  rfl
 
 -- porting note: removed @[simp] as the simpNF linter complains
 theorem associator_hom_hom {X Y Z : Action V G} :
refactor: Move the data fields of MonoidalCategory into a Struct class (#7279)

This matches the approach for CategoryStruct, and allows us to use the notation within MonoidalCategory.

It also makes it easier to induce the lawful structure along a faithful functor, as again it means by the time we are providing the proof fields, the notation is already available.

This also eliminates tensorUnit vs tensorUnit', adding a custom pretty-printer to provide the unprimed version with appropriate notation.

Diff
@@ -512,7 +512,7 @@ set_option linter.uppercaseLean3 false in
 -- porting note: removed @[simp] as the simpNF linter complains
 theorem associator_hom_hom {X Y Z : Action V G} :
     Hom.hom (α_ X Y Z).hom = (α_ X.V Y.V Z.V).hom := by
-  dsimp [Monoidal.induced_associator]
+  dsimp
   simp
 set_option linter.uppercaseLean3 false in
 #align Action.associator_hom_hom Action.associator_hom_hom
@@ -520,35 +520,35 @@ set_option linter.uppercaseLean3 false in
 -- porting note: removed @[simp] as the simpNF linter complains
 theorem associator_inv_hom {X Y Z : Action V G} :
     Hom.hom (α_ X Y Z).inv = (α_ X.V Y.V Z.V).inv := by
-  dsimp [Monoidal.induced_associator]
+  dsimp
   simp
 set_option linter.uppercaseLean3 false in
 #align Action.associator_inv_hom Action.associator_inv_hom
 
 -- porting note: removed @[simp] as the simpNF linter complains
 theorem leftUnitor_hom_hom {X : Action V G} : Hom.hom (λ_ X).hom = (λ_ X.V).hom := by
-  dsimp [Monoidal.induced_leftUnitor]
+  dsimp
   simp
 set_option linter.uppercaseLean3 false in
 #align Action.left_unitor_hom_hom Action.leftUnitor_hom_hom
 
 -- porting note: removed @[simp] as the simpNF linter complains
 theorem leftUnitor_inv_hom {X : Action V G} : Hom.hom (λ_ X).inv = (λ_ X.V).inv := by
-  dsimp [Monoidal.induced_leftUnitor]
+  dsimp
   simp
 set_option linter.uppercaseLean3 false in
 #align Action.left_unitor_inv_hom Action.leftUnitor_inv_hom
 
 -- porting note: removed @[simp] as the simpNF linter complains
 theorem rightUnitor_hom_hom {X : Action V G} : Hom.hom (ρ_ X).hom = (ρ_ X.V).hom := by
-  dsimp [Monoidal.induced_rightUnitor]
+  dsimp
   simp
 set_option linter.uppercaseLean3 false in
 #align Action.right_unitor_hom_hom Action.rightUnitor_hom_hom
 
 -- porting note: removed @[simp] as the simpNF linter complains
 theorem rightUnitor_inv_hom {X : Action V G} : Hom.hom (ρ_ X).inv = (ρ_ X.V).inv := by
-  dsimp [Monoidal.induced_rightUnitor]
+  dsimp
   simp
 set_option linter.uppercaseLean3 false in
 #align Action.right_unitor_inv_hom Action.rightUnitor_inv_hom
chore: removing unneeded maxHeartbeats (#7761)

Due to recent changes in core we can reduce or remove many set_option maxHeartbeats statements.

I have tried to be careful to not leave anything too close to the line, so don't be surprised if some of these can still be reduced further.

This reduces us from 96 maxHeartbeats statements to 44. (There are 10 false positives in meta or testing code.)

Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -564,7 +564,6 @@ set_option linter.uppercaseLean3 false in
 
 variable (V G)
 
-set_option maxHeartbeats 400000 in
 /-- When `V` is monoidal the forgetful functor `Action V G` to `V` is monoidal. -/
 @[simps]
 def forgetMonoidal : MonoidalFunctor (Action V G) V :=
@@ -583,7 +582,6 @@ section
 
 variable [BraidedCategory V]
 
-set_option maxHeartbeats 400000 in
 instance : BraidedCategory (Action V G) :=
   braidedCategoryOfFaithful (forgetMonoidal V G) (fun X Y => mkIso (β_ _ _)
     (fun g => by simp [FunctorCategoryEquivalence.inverse])) (by aesop_cat)
Revert "chore: revert #7703 (#7710)"

This reverts commit f3695eb2.

Diff
@@ -78,6 +78,9 @@ def ρAut {G : GroupCat.{u}} (A : Action V (MonCat.of G)) : G ⟶ GroupCat.of (A
 set_option linter.uppercaseLean3 false in
 #align Action.ρ_Aut Action.ρAut
 
+-- These lemmas have always been bad (#7657), but lean4#2644 made `simp` start noticing
+attribute [nolint simpNF] Action.ρAut_apply_inv Action.ρAut_apply_hom
+
 variable (G : MonCat.{u})
 
 section
@@ -738,13 +741,15 @@ theorem leftDual_v [LeftRigidCategory V] : (ᘁX).V = ᘁX.V :=
 set_option linter.uppercaseLean3 false in
 #align Action.left_dual_V Action.leftDual_v
 
-@[simp]
+-- This lemma was always bad, but the linter only noticed after lean4#2644
+@[simp, nolint simpNF]
 theorem rightDual_ρ [RightRigidCategory V] (h : H) : Xᘁ.ρ h = (X.ρ (h⁻¹ : H))ᘁ := by
   rw [← SingleObj.inv_as_inv]; rfl
 set_option linter.uppercaseLean3 false in
 #align Action.right_dual_ρ Action.rightDual_ρ
 
-@[simp]
+-- This lemma was always bad, but the linter only noticed after lean4#2644
+@[simp, nolint simpNF]
 theorem leftDual_ρ [LeftRigidCategory V] (h : H) : (ᘁX).ρ h = ᘁX.ρ (h⁻¹ : H) := by
   rw [← SingleObj.inv_as_inv]; rfl
 set_option linter.uppercaseLean3 false in
@@ -901,7 +906,8 @@ noncomputable def leftRegularTensorIso (G : Type u) [Group G] (X : Action (Type
         refine' Prod.ext rfl _
         erw [tensor_rho, tensor_rho]
         dsimp
-        rw [leftRegular_ρ_apply]
+        -- This used to be `rw`, but we need `erw` after leanprover/lean4#2644
+        erw [leftRegular_ρ_apply]
         erw [map_mul]
         rfl }
   hom_inv_id := by
chore: revert #7703 (#7710)

This reverts commit 26eb2b0a.

Diff
@@ -78,9 +78,6 @@ def ρAut {G : GroupCat.{u}} (A : Action V (MonCat.of G)) : G ⟶ GroupCat.of (A
 set_option linter.uppercaseLean3 false in
 #align Action.ρ_Aut Action.ρAut
 
--- These lemmas have always been bad (#7657), but lean4#2644 made `simp` start noticing
-attribute [nolint simpNF] Action.ρAut_apply_inv Action.ρAut_apply_hom
-
 variable (G : MonCat.{u})
 
 section
@@ -741,15 +738,13 @@ theorem leftDual_v [LeftRigidCategory V] : (ᘁX).V = ᘁX.V :=
 set_option linter.uppercaseLean3 false in
 #align Action.left_dual_V Action.leftDual_v
 
--- This lemma was always bad, but the linter only noticed after lean4#2644
-@[simp, nolint simpNF]
+@[simp]
 theorem rightDual_ρ [RightRigidCategory V] (h : H) : Xᘁ.ρ h = (X.ρ (h⁻¹ : H))ᘁ := by
   rw [← SingleObj.inv_as_inv]; rfl
 set_option linter.uppercaseLean3 false in
 #align Action.right_dual_ρ Action.rightDual_ρ
 
--- This lemma was always bad, but the linter only noticed after lean4#2644
-@[simp, nolint simpNF]
+@[simp]
 theorem leftDual_ρ [LeftRigidCategory V] (h : H) : (ᘁX).ρ h = ᘁX.ρ (h⁻¹ : H) := by
   rw [← SingleObj.inv_as_inv]; rfl
 set_option linter.uppercaseLean3 false in
@@ -906,8 +901,7 @@ noncomputable def leftRegularTensorIso (G : Type u) [Group G] (X : Action (Type
         refine' Prod.ext rfl _
         erw [tensor_rho, tensor_rho]
         dsimp
-        -- This used to be `rw`, but we need `erw` after leanprover/lean4#2644
-        erw [leftRegular_ρ_apply]
+        rw [leftRegular_ρ_apply]
         erw [map_mul]
         rfl }
   hom_inv_id := by
chore: bump toolchain to v4.2.0-rc2 (#7703)

This includes all the changes from #7606.

Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -78,6 +78,9 @@ def ρAut {G : GroupCat.{u}} (A : Action V (MonCat.of G)) : G ⟶ GroupCat.of (A
 set_option linter.uppercaseLean3 false in
 #align Action.ρ_Aut Action.ρAut
 
+-- These lemmas have always been bad (#7657), but lean4#2644 made `simp` start noticing
+attribute [nolint simpNF] Action.ρAut_apply_inv Action.ρAut_apply_hom
+
 variable (G : MonCat.{u})
 
 section
@@ -738,13 +741,15 @@ theorem leftDual_v [LeftRigidCategory V] : (ᘁX).V = ᘁX.V :=
 set_option linter.uppercaseLean3 false in
 #align Action.left_dual_V Action.leftDual_v
 
-@[simp]
+-- This lemma was always bad, but the linter only noticed after lean4#2644
+@[simp, nolint simpNF]
 theorem rightDual_ρ [RightRigidCategory V] (h : H) : Xᘁ.ρ h = (X.ρ (h⁻¹ : H))ᘁ := by
   rw [← SingleObj.inv_as_inv]; rfl
 set_option linter.uppercaseLean3 false in
 #align Action.right_dual_ρ Action.rightDual_ρ
 
-@[simp]
+-- This lemma was always bad, but the linter only noticed after lean4#2644
+@[simp, nolint simpNF]
 theorem leftDual_ρ [LeftRigidCategory V] (h : H) : (ᘁX).ρ h = ᘁX.ρ (h⁻¹ : H) := by
   rw [← SingleObj.inv_as_inv]; rfl
 set_option linter.uppercaseLean3 false in
@@ -901,7 +906,8 @@ noncomputable def leftRegularTensorIso (G : Type u) [Group G] (X : Action (Type
         refine' Prod.ext rfl _
         erw [tensor_rho, tensor_rho]
         dsimp
-        rw [leftRegular_ρ_apply]
+        -- This used to be `rw`, but we need `erw` after leanprover/lean4#2644
+        erw [leftRegular_ρ_apply]
         erw [map_mul]
         rfl }
   hom_inv_id := by
feat(CategoryTheory/Monoidal/Transport): generalize to a faithful functor (#7237)

I needed this to transfer the monoidal structure from ModuleCat to QuadraticModuleCat, but would also work for transferring the same structure from ModuleCat to AlgebraCat.

The changes are:

  • A new CategoryTheory.Monoidal.induced definition, proven from scratch with slightly uglier proofs than what transport used. The new proofs use simp rather more than targeted slice commands, mainly due to lack of patience on my part.
  • CategoryTheory.Monoidal.transport now has a trivial implementation in terms of induced, as does CategoryTheory.MonoidalCategory.fullMonoidalSubcategory (though this was already fairly trivial)
  • CategoryTheory.Monoidal.laxToTransported has been removed, as it's just a less useful version of CategoryTheory.Monoidal.toTransported
  • CategoryTheory.Monoidal.toTransported has been golfed to oblivion, as it now falls out trivially by showing fromTransported first.
Diff
@@ -473,7 +473,7 @@ open MonoidalCategory
 
 variable [MonoidalCategory V]
 
-instance : MonoidalCategory (Action V G) :=
+instance instMonoidalCategory : MonoidalCategory (Action V G) :=
   Monoidal.transport (Action.functorCategoryEquivalence _ _).symm
 
 @[simp]
@@ -509,7 +509,7 @@ set_option linter.uppercaseLean3 false in
 -- porting note: removed @[simp] as the simpNF linter complains
 theorem associator_hom_hom {X Y Z : Action V G} :
     Hom.hom (α_ X Y Z).hom = (α_ X.V Y.V Z.V).hom := by
-  dsimp [Monoidal.transport_associator]
+  dsimp [Monoidal.induced_associator]
   simp
 set_option linter.uppercaseLean3 false in
 #align Action.associator_hom_hom Action.associator_hom_hom
@@ -517,35 +517,35 @@ set_option linter.uppercaseLean3 false in
 -- porting note: removed @[simp] as the simpNF linter complains
 theorem associator_inv_hom {X Y Z : Action V G} :
     Hom.hom (α_ X Y Z).inv = (α_ X.V Y.V Z.V).inv := by
-  dsimp [Monoidal.transport_associator]
+  dsimp [Monoidal.induced_associator]
   simp
 set_option linter.uppercaseLean3 false in
 #align Action.associator_inv_hom Action.associator_inv_hom
 
 -- porting note: removed @[simp] as the simpNF linter complains
 theorem leftUnitor_hom_hom {X : Action V G} : Hom.hom (λ_ X).hom = (λ_ X.V).hom := by
-  dsimp [Monoidal.transport_leftUnitor]
+  dsimp [Monoidal.induced_leftUnitor]
   simp
 set_option linter.uppercaseLean3 false in
 #align Action.left_unitor_hom_hom Action.leftUnitor_hom_hom
 
 -- porting note: removed @[simp] as the simpNF linter complains
 theorem leftUnitor_inv_hom {X : Action V G} : Hom.hom (λ_ X).inv = (λ_ X.V).inv := by
-  dsimp [Monoidal.transport_leftUnitor]
+  dsimp [Monoidal.induced_leftUnitor]
   simp
 set_option linter.uppercaseLean3 false in
 #align Action.left_unitor_inv_hom Action.leftUnitor_inv_hom
 
 -- porting note: removed @[simp] as the simpNF linter complains
 theorem rightUnitor_hom_hom {X : Action V G} : Hom.hom (ρ_ X).hom = (ρ_ X.V).hom := by
-  dsimp [Monoidal.transport_rightUnitor]
+  dsimp [Monoidal.induced_rightUnitor]
   simp
 set_option linter.uppercaseLean3 false in
 #align Action.right_unitor_hom_hom Action.rightUnitor_hom_hom
 
 -- porting note: removed @[simp] as the simpNF linter complains
 theorem rightUnitor_inv_hom {X : Action V G} : Hom.hom (ρ_ X).inv = (ρ_ X.V).inv := by
-  dsimp [Monoidal.transport_rightUnitor]
+  dsimp [Monoidal.induced_rightUnitor]
   simp
 set_option linter.uppercaseLean3 false in
 #align Action.right_unitor_inv_hom Action.rightUnitor_inv_hom
@@ -561,10 +561,11 @@ set_option linter.uppercaseLean3 false in
 
 variable (V G)
 
+set_option maxHeartbeats 400000 in
 /-- When `V` is monoidal the forgetful functor `Action V G` to `V` is monoidal. -/
 @[simps]
 def forgetMonoidal : MonoidalFunctor (Action V G) V :=
-  { Action.forget _ _ with
+  { toFunctor := Action.forget _ _
     ε := 𝟙 _
     μ := fun X Y => 𝟙 _ }
 set_option linter.uppercaseLean3 false in
@@ -579,6 +580,7 @@ section
 
 variable [BraidedCategory V]
 
+set_option maxHeartbeats 400000 in
 instance : BraidedCategory (Action V G) :=
   braidedCategoryOfFaithful (forgetMonoidal V G) (fun X Y => mkIso (β_ _ _)
     (fun g => by simp [FunctorCategoryEquivalence.inverse])) (by aesop_cat)
@@ -633,12 +635,6 @@ theorem functorCategoryMonoidalEquivalence.μ_app (A B : Action V G) :
   -- porting note: Lean3 was able to see through some defeq, as the mathlib3 proof was
   --   show (𝟙 A.V ⊗ 𝟙 B.V) ≫ 𝟙 (A.V ⊗ B.V) ≫ (𝟙 A.V ⊗ 𝟙 B.V) = 𝟙 (A.V ⊗ B.V)
   --   simp only [monoidal_category.tensor_id, category.comp_id]
-  dsimp [Equivalence.unit]
-  erw [Category.id_comp]
-  rw [NatIso.isIso_inv_app, IsIso.inv_comp_eq]
-  erw [MonoidalCategory.tensor_id]
-  erw [(functorCategoryEquivalence V G).inverse.map_id,
-    (functorCategoryEquivalence V G).functor.map_id, Category.id_comp]
   rfl
 set_option linter.uppercaseLean3 false in
 #align Action.functor_category_monoidal_equivalence.μ_app Action.functorCategoryMonoidalEquivalence.μ_app
@@ -983,29 +979,27 @@ variable {W : Type (u + 1)} [LargeCategory W] [MonoidalCategory V] [MonoidalCate
 /-- A monoidal functor induces a monoidal functor between
 the categories of `G`-actions within those categories. -/
 @[simps]
-def mapAction : MonoidalFunctor (Action V G) (Action W G) :=
-  { F.toFunctor.mapAction G with
-    ε :=
-      { hom := F.ε
-        comm := fun g => by
-          dsimp [FunctorCategoryEquivalence.inverse, Functor.mapAction]
-          rw [Category.id_comp, F.map_id, Category.comp_id] }
-    μ := fun X Y =>
-      { hom := F.μ X.V Y.V
-        comm := fun g => F.toLaxMonoidalFunctor.μ_natural (X.ρ g) (Y.ρ g) }
-    ε_isIso := by infer_instance
-    μ_isIso := by infer_instance
-    μ_natural := by intros; ext; simp
-    associativity := by intros; ext; simp
-    left_unitality := by intros; ext; simp
-    right_unitality := by
-      intros
-      ext
-      dsimp
-      simp only [MonoidalCategory.rightUnitor_conjugation,
-        LaxMonoidalFunctor.right_unitality, Category.id_comp, Category.assoc,
-        LaxMonoidalFunctor.right_unitality_inv_assoc, Category.comp_id, Iso.hom_inv_id]
-      rw [← F.map_comp, Iso.inv_hom_id, F.map_id, Category.comp_id] }
+def mapAction : MonoidalFunctor (Action V G) (Action W G) where
+  toFunctor := F.toFunctor.mapAction G
+  ε :=
+    { hom := F.ε
+      comm := fun g => by
+        dsimp [FunctorCategoryEquivalence.inverse, Functor.mapAction]
+        rw [Category.id_comp, F.map_id, Category.comp_id] }
+  μ := fun X Y =>
+    { hom := F.μ X.V Y.V
+      comm := fun g => F.toLaxMonoidalFunctor.μ_natural (X.ρ g) (Y.ρ g) }
+  -- using `dsimp` before `simp` speeds these up
+  μ_natural {X Y X' Y'} f g := by ext; dsimp; simp
+  associativity X Y Z := by ext; dsimp; simp
+  left_unitality X := by ext; dsimp; simp
+  right_unitality X := by
+    ext
+    dsimp
+    simp only [MonoidalCategory.rightUnitor_conjugation,
+      LaxMonoidalFunctor.right_unitality, Category.id_comp, Category.assoc,
+      LaxMonoidalFunctor.right_unitality_inv_assoc, Category.comp_id, Iso.hom_inv_id]
+    rw [← F.map_comp, Iso.inv_hom_id, F.map_id, Category.comp_id]
 set_option linter.uppercaseLean3 false in
 #align category_theory.monoidal_functor.map_Action CategoryTheory.MonoidalFunctor.mapAction
 
chore: banish Type _ and Sort _ (#6499)

We remove all possible occurences of Type _ and Sort _ in favor of Type* and Sort*.

This has nice performance benefits.

Diff
@@ -409,7 +409,7 @@ set_option linter.uppercaseLean3 false in
 #align Action.add_hom Action.add_hom
 
 @[simp]
-theorem sum_hom {X Y : Action V G} {ι : Type _} (f : ι → (X ⟶ Y)) (s : Finset ι) :
+theorem sum_hom {X Y : Action V G} {ι : Type*} (f : ι → (X ⟶ Y)) (s : Finset ι) :
     (s.sum f).hom = s.sum fun i => (f i).hom :=
   (forget V G).map_sum f s
 set_option linter.uppercaseLean3 false in
@@ -419,7 +419,7 @@ end Preadditive
 
 section Linear
 
-variable [Preadditive V] {R : Type _} [Semiring R] [Linear R V]
+variable [Preadditive V] {R : Type*} [Semiring R] [Linear R V]
 
 instance : Linear R (Action V G) where
   homModule X Y :=
@@ -608,7 +608,7 @@ attribute [local simp] MonoidalPreadditive.tensor_add MonoidalPreadditive.add_te
 
 instance : MonoidalPreadditive (Action V G) where
 
-variable {R : Type _} [Semiring R] [Linear R V] [MonoidalLinear R V]
+variable {R : Type*} [Semiring R] [Linear R V] [MonoidalLinear R V]
 
 instance : MonoidalLinear R (Action V G) where
 
@@ -817,7 +817,7 @@ instance res_additive [Preadditive V] : (res V f).Additive where
 set_option linter.uppercaseLean3 false in
 #align Action.res_additive Action.res_additive
 
-variable {R : Type _} [Semiring R]
+variable {R : Type*} [Semiring R]
 
 instance res_linear [Preadditive V] [Linear R V] : (res V f).Linear R where
 set_option linter.uppercaseLean3 false in
@@ -964,7 +964,7 @@ instance mapAction_preadditive [F.Additive] : (F.mapAction G).Additive where
 set_option linter.uppercaseLean3 false in
 #align category_theory.functor.map_Action_preadditive CategoryTheory.Functor.mapAction_preadditive
 
-variable {R : Type _} [Semiring R] [CategoryTheory.Linear R V] [CategoryTheory.Linear R W]
+variable {R : Type*} [Semiring R] [CategoryTheory.Linear R V] [CategoryTheory.Linear R W]
 
 instance mapAction_linear [F.Additive] [F.Linear R] : (F.mapAction G).Linear R where
 set_option linter.uppercaseLean3 false in
chore: fix grammar mistakes (#6121)
Diff
@@ -159,7 +159,7 @@ set_option linter.uppercaseLean3 false in
 #align Action.comp_hom Action.comp_hom
 
 /-- Construct an isomorphism of `G` actions/representations
-from an isomorphism of the the underlying objects,
+from an isomorphism of the underlying objects,
 where the forward direction commutes with the group action. -/
 @[simps]
 def mkIso {M N : Action V G} (f : M.V ≅ N.V)
chore: script to replace headers with #align_import statements (#5979)

Open in Gitpod

Co-authored-by: Eric Wieser <wieser.eric@gmail.com> Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -2,11 +2,6 @@
 Copyright (c) 2020 Scott Morrison. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Scott Morrison
-
-! This file was ported from Lean 3 source module representation_theory.Action
-! leanprover-community/mathlib commit 95a87616d63b3cb49d3fe678d416fbe9c4217bf4
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathlib.Algebra.Category.GroupCat.Basic
 import Mathlib.CategoryTheory.SingleObj
@@ -25,6 +20,8 @@ import Mathlib.CategoryTheory.Abelian.Transfer
 import Mathlib.CategoryTheory.Conj
 import Mathlib.CategoryTheory.Linear.FunctorCategory
 
+#align_import representation_theory.Action from "leanprover-community/mathlib"@"95a87616d63b3cb49d3fe678d416fbe9c4217bf4"
+
 /-!
 # `Action V G`, the category of actions of a monoid `G` inside some category `V`.
 
chore: remove occurrences of semicolon after space (#5713)

This is the second half of the changes originally in #5699, removing all occurrences of ; after a space and implementing a linter rule to enforce it.

In most cases this 2-character substring has a space after it, so the following command was run first:

find . -type f -name "*.lean" -exec sed -i -E 's/ ; /; /g' {} \;

The remaining cases were few enough in number that they were done manually.

Diff
@@ -172,7 +172,7 @@ def mkIso {M N : Action V G} (f : M.V ≅ N.V)
       comm := comm }
   inv :=
     { hom := f.inv
-      comm := fun g => by have w := comm g =≫ f.inv; simp at w ; simp [w] }
+      comm := fun g => by have w := comm g =≫ f.inv; simp at w; simp [w] }
 set_option linter.uppercaseLean3 false in
 #align Action.mk_iso Action.mkIso
 
feat: port RepresentationTheory.Rep (#5041)

Co-authored-by: Jeremy Tan Jie Rui <reddeloostw@gmail.com>

Diff
@@ -321,10 +321,12 @@ def functorCategoryEquivalenceCompEvaluation :
 set_option linter.uppercaseLean3 false in
 #align Action.functor_category_equivalence_comp_evaluation Action.functorCategoryEquivalenceCompEvaluation
 
-noncomputable instance [HasLimits V] : Limits.PreservesLimits (forget V G) :=
+noncomputable instance instPreservesLimitsForget [HasLimits V] :
+    Limits.PreservesLimits (forget V G) :=
   Limits.preservesLimitsOfNatIso (Action.functorCategoryEquivalenceCompEvaluation V G)
 
-noncomputable instance [HasColimits V] : PreservesColimits (forget V G) :=
+noncomputable instance instPreservesColimitsForget [HasColimits V] :
+    PreservesColimits (forget V G) :=
   preservesColimitsOfNatIso (Action.functorCategoryEquivalenceCompEvaluation V G)
 
 -- TODO construct categorical images?
chore: fix grammar 3/3 (#5003)

Part 3 of #5001

Diff
@@ -119,7 +119,7 @@ namespace Hom
 attribute [reassoc] comm
 attribute [local simp] comm comm_assoc
 
-/-- The identity morphism on a `Action V G`. -/
+/-- The identity morphism on an `Action V G`. -/
 @[simps]
 def id (M : Action V G) : Action.Hom M M where hom := 𝟙 M.V
 set_option linter.uppercaseLean3 false in
chore: review of automation in category theory (#4793)

Clean up of automation in the category theory library. Leaving out unnecessary proof steps, or fields done by aesop_cat, and making more use of available autoparameters.

Co-authored-by: Scott Morrison <scott.morrison@anu.edu.au>

Diff
@@ -165,8 +165,8 @@ set_option linter.uppercaseLean3 false in
 from an isomorphism of the the underlying objects,
 where the forward direction commutes with the group action. -/
 @[simps]
-def mkIso {M N : Action V G} (f : M.V ≅ N.V) (comm : ∀ g : G, M.ρ g ≫ f.hom = f.hom ≫ N.ρ g) :
-    M ≅ N where
+def mkIso {M N : Action V G} (f : M.V ≅ N.V)
+    (comm : ∀ g : G, M.ρ g ≫ f.hom = f.hom ≫ N.ρ g := by aesop_cat) : M ≅ N where
   hom :=
     { hom := f.hom
       comm := comm }
@@ -221,15 +221,14 @@ set_option linter.uppercaseLean3 false in
 /-- Auxilliary definition for `functorCategoryEquivalence`. -/
 @[simps!]
 def unitIso : 𝟭 (Action V G) ≅ functor ⋙ inverse :=
-  NatIso.ofComponents (fun M => mkIso (Iso.refl _) (by aesop_cat)) (by aesop_cat)
+  NatIso.ofComponents fun M => mkIso (Iso.refl _)
 set_option linter.uppercaseLean3 false in
 #align Action.functor_category_equivalence.unit_iso Action.FunctorCategoryEquivalence.unitIso
 
 /-- Auxilliary definition for `functorCategoryEquivalence`. -/
 @[simps!]
 def counitIso : inverse ⋙ functor ≅ 𝟭 (SingleObj G ⥤ V) :=
-  NatIso.ofComponents (fun M => NatIso.ofComponents (fun X => Iso.refl _) (by aesop_cat))
-    (by aesop_cat)
+  NatIso.ofComponents fun M => NatIso.ofComponents fun X => Iso.refl _
 set_option linter.uppercaseLean3 false in
 #align Action.functor_category_equivalence.counit_iso Action.FunctorCategoryEquivalence.counitIso
 
@@ -767,11 +766,11 @@ def actionPunitEquivalence : Action V (MonCat.of PUnit) ≌ V where
     { obj := fun X => ⟨X, 1⟩
       map := fun f => ⟨f, fun ⟨⟩ => by simp⟩ }
   unitIso :=
-    NatIso.ofComponents (fun X => mkIso (Iso.refl _) fun ⟨⟩ => by
+    NatIso.ofComponents fun X => mkIso (Iso.refl _) fun ⟨⟩ => by
       simp only [MonCat.oneHom_apply, MonCat.one_of, End.one_def, id_eq, Functor.comp_obj,
         forget_obj, Iso.refl_hom, Category.comp_id]
-      exact ρ_one X) (by aesop_cat)
-  counitIso := NatIso.ofComponents (fun X => Iso.refl _) (by aesop_cat)
+      exact ρ_one X
+  counitIso := NatIso.ofComponents fun X => Iso.refl _
 set_option linter.uppercaseLean3 false in
 #align Action.Action_punit_equivalence Action.actionPunitEquivalence
 
@@ -798,7 +797,7 @@ the identity functor on `Action V G`.
 -/
 @[simps!]
 def resId {G : MonCat} : res V (𝟙 G) ≅ 𝟭 (Action V G) :=
-  NatIso.ofComponents (fun M => mkIso (Iso.refl _) (by aesop_cat)) (by aesop_cat)
+  NatIso.ofComponents fun M => mkIso (Iso.refl _)
 set_option linter.uppercaseLean3 false in
 #align Action.res_id Action.resId
 
@@ -807,7 +806,7 @@ to the restriction along the composition of homomorphism.
 -/
 @[simps!]
 def resComp {G H K : MonCat} (f : G ⟶ H) (g : H ⟶ K) : res V g ⋙ res V f ≅ res V (f ≫ g) :=
-  NatIso.ofComponents (fun M => mkIso (Iso.refl _) (by aesop_cat)) (by aesop_cat)
+  NatIso.ofComponents fun M => mkIso (Iso.refl _)
 set_option linter.uppercaseLean3 false in
 #align Action.res_comp Action.resComp
 
feat: port CategoryTheory.Bicategory.CoherenceTactic (#4610)

Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Scott Morrison <scott.morrison@anu.edu.au>

Diff
@@ -471,6 +471,8 @@ end Abelian
 
 section Monoidal
 
+open MonoidalCategory
+
 variable [MonoidalCategory V]
 
 instance : MonoidalCategory (Action V G) :=
@@ -882,8 +884,8 @@ def diagonalOneIsoLeftRegular (G : Type u) [Monoid G] : diagonal G 1 ≅ leftReg
 set_option linter.uppercaseLean3 false in
 #align Action.diagonal_one_iso_left_regular Action.diagonalOneIsoLeftRegular
 
-/- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
-/- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
+open MonoidalCategory
+
 /-- Given `X : Action (Type u) (Mon.of G)` for `G` a group, then `G × X` (with `G` acting as left
 multiplication on the first factor and by `X.ρ` on the second) is isomorphic as a `G`-set to
 `G × X` (with `G` acting as left multiplication on the first factor and trivially on the second).
@@ -923,7 +925,6 @@ noncomputable def leftRegularTensorIso (G : Type u) [Group G] (X : Action (Type
 set_option linter.uppercaseLean3 false in
 #align Action.left_regular_tensor_iso Action.leftRegularTensorIso
 
-/- ./././Mathport/Syntax/Translate/Expr.lean:177:8: unsupported: ambiguous notation -/
 /-- The natural isomorphism of `G`-sets `Gⁿ⁺¹ ≅ G × Gⁿ`, where `G` acts by left multiplication on
 each factor. -/
 @[simps!]
feat: port RepresentationTheory.Action (#4700)

Co-authored-by: Joël Riou <37772949+joelriou@users.noreply.github.com> Co-authored-by: Jeremy Tan Jie Rui <reddeloostw@gmail.com> Co-authored-by: Parcly Taxel <reddeloostw@gmail.com>

Dependencies 9 + 500

501 files ported (98.2%)
193022 lines ported (98.4%)
Show graph

The unported dependencies are