data.finset.noncomm_prodMathlib.Data.Finset.NoncommProd

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)

(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)

(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)

(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
@@ -466,7 +466,8 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
       x :=
   by
   ext i
-  apply (univ.noncomm_prod_map (fun i => MonoidHom.single M i (x i)) _ (Pi.evalMonoidHom M i)).trans
+  apply
+    (univ.noncomm_prod_map (fun i => MonoidHom.mulSingle M i (x i)) _ (Pi.evalMonoidHom M i)).trans
   rw [← insert_erase (mem_univ i), noncomm_prod_insert_of_not_mem' _ _ _ _ (not_mem_erase _ _),
     noncomm_prod_eq_pow_card, one_pow]
   · simp
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yakov Pechersky
 -/
 import Data.Fintype.Card
-import Algebra.Hom.Commute
+import Algebra.Group.Commute.Hom
 import Algebra.BigOperators.Basic
 
 #align_import data.finset.noncomm_prod from "leanprover-community/mathlib"@"327c3c0d9232d80e250dc8f65e7835b82b266ea5"
Diff
@@ -187,7 +187,7 @@ theorem noncommProd_cons' (s : Multiset α) (a : α) (comm) :
     · congr 1
       apply comm.of_refl <;> simp
     · intro x hx y hy
-      simp only [quot_mk_to_coe, List.mem_cons, mem_coe, cons_coe] at hx hy 
+      simp only [quot_mk_to_coe, List.mem_cons, mem_coe, cons_coe] at hx hy
       apply comm
       · cases hx <;> simp [hx]
       · cases hy <;> simp [hy]
@@ -300,7 +300,7 @@ theorem noncommProd_congr {s₁ s₂ : Finset α} {f g : α → β} (h₁ : s₁
 theorem noncommProd_toFinset [DecidableEq α] (l : List α) (f : α → β) (comm) (hl : l.Nodup) :
     noncommProd l.toFinset f comm = (l.map f).Prod :=
   by
-  rw [← List.dedup_eq_self] at hl 
+  rw [← List.dedup_eq_self] at hl
   simp [noncomm_prod, hl]
 #align finset.noncomm_prod_to_finset Finset.noncommProd_toFinset
 #align finset.noncomm_sum_to_finset Finset.noncommSum_toFinset
@@ -404,7 +404,7 @@ theorem noncommProd_union_of_disjoint [DecidableEq α] {s t : Finset α} (h : Di
   by
   obtain ⟨sl, sl', rfl⟩ := exists_list_nodup_eq s
   obtain ⟨tl, tl', rfl⟩ := exists_list_nodup_eq t
-  rw [List.disjoint_toFinset_iff_disjoint] at h 
+  rw [List.disjoint_toFinset_iff_disjoint] at h
   simp [sl', tl', noncomm_prod_to_finset, ← List.prod_append, ← List.toFinset_append,
     sl'.append tl' h]
 #align finset.noncomm_prod_union_of_disjoint Finset.noncommProd_union_of_disjoint
@@ -470,7 +470,7 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
   rw [← insert_erase (mem_univ i), noncomm_prod_insert_of_not_mem' _ _ _ _ (not_mem_erase _ _),
     noncomm_prod_eq_pow_card, one_pow]
   · simp
-  · intro i h; simp at h ; simp [h]
+  · intro i h; simp at h; simp [h]
 #align finset.noncomm_prod_mul_single Finset.noncommProd_mul_single
 #align finset.noncomm_sum_single Finset.noncommSum_single
 -/
Diff
@@ -87,7 +87,7 @@ theorem noncommFoldr_eq_foldr (s : Multiset α) (h : LeftCommutative f) (b : β)
 #align multiset.noncomm_foldr_eq_foldr Multiset.noncommFoldr_eq_foldr
 -/
 
-variable [assoc : IsAssociative α op]
+variable [assoc : Std.Associative α op]
 
 #print Multiset.noncommFold /-
 /-- Fold of a `s : multiset α` with an associative `op : α → α → α`, given a proofs that `op`
@@ -121,8 +121,8 @@ theorem noncommFold_cons (s : Multiset α) (a : α) (h h') (x : α) :
 -/
 
 #print Multiset.noncommFold_eq_fold /-
-theorem noncommFold_eq_fold (s : Multiset α) [IsCommutative α op] (a : α) :
-    noncommFold op s (fun x _ y _ _ => IsCommutative.comm x y) a = fold op a s :=
+theorem noncommFold_eq_fold (s : Multiset α) [Std.Commutative α op] (a : α) :
+    noncommFold op s (fun x _ y _ _ => Std.Commutative.comm x y) a = fold op a s :=
   by
   induction s using Quotient.inductionOn
   simp
Diff
@@ -384,7 +384,11 @@ theorem noncommProd_commute (s : Finset α) (f : α → β) (comm) (y : β)
 #print Finset.noncommProd_eq_prod /-
 @[to_additive]
 theorem noncommProd_eq_prod {β : Type _} [CommMonoid β] (s : Finset α) (f : α → β) :
-    (noncommProd s f fun _ _ _ _ _ => Commute.all _ _) = s.Prod f := by classical
+    (noncommProd s f fun _ _ _ _ _ => Commute.all _ _) = s.Prod f := by
+  classical
+  induction' s using Finset.induction_on with a s ha IH
+  · simp
+  · simp [ha, IH]
 #align finset.noncomm_prod_eq_prod Finset.noncommProd_eq_prod
 #align finset.noncomm_sum_eq_sum Finset.noncommSum_eq_sum
 -/
@@ -431,7 +435,21 @@ theorem noncommProd_mul_distrib_aux {s : Finset α} {f : α → β} {g : α →
 theorem noncommProd_mul_distrib {s : Finset α} (f : α → β) (g : α → β) (comm_ff comm_gg comm_gf) :
     noncommProd s (f * g) (noncommProd_mul_distrib_aux comm_ff comm_gg comm_gf) =
       noncommProd s f comm_ff * noncommProd s g comm_gg :=
-  by classical
+  by
+  classical
+  induction' s using Finset.induction_on with x s hnmem ih
+  · simp
+  simp only [Finset.noncommProd_insert_of_not_mem _ _ _ _ hnmem]
+  specialize
+    ih (comm_ff.mono fun _ => mem_insert_of_mem) (comm_gg.mono fun _ => mem_insert_of_mem)
+      (comm_gf.mono fun _ => mem_insert_of_mem)
+  rw [ih, Pi.mul_apply]
+  simp only [mul_assoc]
+  congr 1
+  simp only [← mul_assoc]
+  congr 1
+  refine' noncomm_prod_commute _ _ _ _ fun y hy => _
+  exact comm_gf (mem_insert_self x s) (mem_insert_of_mem hy) (ne_of_mem_of_not_mem hy hnmem).symm
 #align finset.noncomm_prod_mul_distrib Finset.noncommProd_mul_distrib
 #align finset.noncomm_sum_add_distrib Finset.noncommSum_add_distrib
 -/
Diff
@@ -384,11 +384,7 @@ theorem noncommProd_commute (s : Finset α) (f : α → β) (comm) (y : β)
 #print Finset.noncommProd_eq_prod /-
 @[to_additive]
 theorem noncommProd_eq_prod {β : Type _} [CommMonoid β] (s : Finset α) (f : α → β) :
-    (noncommProd s f fun _ _ _ _ _ => Commute.all _ _) = s.Prod f := by
-  classical
-  induction' s using Finset.induction_on with a s ha IH
-  · simp
-  · simp [ha, IH]
+    (noncommProd s f fun _ _ _ _ _ => Commute.all _ _) = s.Prod f := by classical
 #align finset.noncomm_prod_eq_prod Finset.noncommProd_eq_prod
 #align finset.noncomm_sum_eq_sum Finset.noncommSum_eq_sum
 -/
@@ -435,21 +431,7 @@ theorem noncommProd_mul_distrib_aux {s : Finset α} {f : α → β} {g : α →
 theorem noncommProd_mul_distrib {s : Finset α} (f : α → β) (g : α → β) (comm_ff comm_gg comm_gf) :
     noncommProd s (f * g) (noncommProd_mul_distrib_aux comm_ff comm_gg comm_gf) =
       noncommProd s f comm_ff * noncommProd s g comm_gg :=
-  by
-  classical
-  induction' s using Finset.induction_on with x s hnmem ih
-  · simp
-  simp only [Finset.noncommProd_insert_of_not_mem _ _ _ _ hnmem]
-  specialize
-    ih (comm_ff.mono fun _ => mem_insert_of_mem) (comm_gg.mono fun _ => mem_insert_of_mem)
-      (comm_gf.mono fun _ => mem_insert_of_mem)
-  rw [ih, Pi.mul_apply]
-  simp only [mul_assoc]
-  congr 1
-  simp only [← mul_assoc]
-  congr 1
-  refine' noncomm_prod_commute _ _ _ _ fun y hy => _
-  exact comm_gf (mem_insert_self x s) (mem_insert_of_mem hy) (ne_of_mem_of_not_mem hy hnmem).symm
+  by classical
 #align finset.noncomm_prod_mul_distrib Finset.noncommProd_mul_distrib
 #align finset.noncomm_sum_add_distrib Finset.noncommSum_add_distrib
 -/
Diff
@@ -3,9 +3,9 @@ Copyright (c) 2021 Yakov Pechersky. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yakov Pechersky
 -/
-import Mathbin.Data.Fintype.Card
-import Mathbin.Algebra.Hom.Commute
-import Mathbin.Algebra.BigOperators.Basic
+import Data.Fintype.Card
+import Algebra.Hom.Commute
+import Algebra.BigOperators.Basic
 
 #align_import data.finset.noncomm_prod from "leanprover-community/mathlib"@"327c3c0d9232d80e250dc8f65e7835b82b266ea5"
 
Diff
@@ -2,16 +2,13 @@
 Copyright (c) 2021 Yakov Pechersky. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yakov Pechersky
-
-! This file was ported from Lean 3 source module data.finset.noncomm_prod
-! leanprover-community/mathlib commit 327c3c0d9232d80e250dc8f65e7835b82b266ea5
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathbin.Data.Fintype.Card
 import Mathbin.Algebra.Hom.Commute
 import Mathbin.Algebra.BigOperators.Basic
 
+#align_import data.finset.noncomm_prod from "leanprover-community/mathlib"@"327c3c0d9232d80e250dc8f65e7835b82b266ea5"
+
 /-!
 # Products (respectively, sums) over a finset or a multiset.
 
Diff
@@ -54,6 +54,7 @@ def noncommFoldr (s : Multiset α)
 #align multiset.noncomm_foldr Multiset.noncommFoldr
 -/
 
+#print Multiset.noncommFoldr_coe /-
 @[simp]
 theorem noncommFoldr_coe (l : List α) (comm) (b : β) :
     noncommFoldr f (l : Multiset α) comm b = l.foldr f b :=
@@ -62,30 +63,35 @@ theorem noncommFoldr_coe (l : List α) (comm) (b : β) :
   rw [← List.foldr_map]
   simp [List.map_pmap, List.pmap_eq_map]
 #align multiset.noncomm_foldr_coe Multiset.noncommFoldr_coe
+-/
 
+#print Multiset.noncommFoldr_empty /-
 @[simp]
 theorem noncommFoldr_empty (h) (b : β) : noncommFoldr f (0 : Multiset α) h b = b :=
   rfl
 #align multiset.noncomm_foldr_empty Multiset.noncommFoldr_empty
+-/
 
+#print Multiset.noncommFoldr_cons /-
 theorem noncommFoldr_cons (s : Multiset α) (a : α) (h h') (b : β) :
     noncommFoldr f (a ::ₘ s) h b = f a (noncommFoldr f s h' b) :=
   by
   induction s using Quotient.inductionOn
   simp
 #align multiset.noncomm_foldr_cons Multiset.noncommFoldr_cons
+-/
 
+#print Multiset.noncommFoldr_eq_foldr /-
 theorem noncommFoldr_eq_foldr (s : Multiset α) (h : LeftCommutative f) (b : β) :
     noncommFoldr f s (fun x _ y _ _ => h x y) b = foldr f h b s :=
   by
   induction s using Quotient.inductionOn
   simp
 #align multiset.noncomm_foldr_eq_foldr Multiset.noncommFoldr_eq_foldr
+-/
 
 variable [assoc : IsAssociative α op]
 
-include assoc
-
 #print Multiset.noncommFold /-
 /-- Fold of a `s : multiset α` with an associative `op : α → α → α`, given a proofs that `op`
 is commutative on all elements `x ∈ s`. -/
@@ -126,10 +132,9 @@ theorem noncommFold_eq_fold (s : Multiset α) [IsCommutative α op] (a : α) :
 #align multiset.noncomm_fold_eq_fold Multiset.noncommFold_eq_fold
 -/
 
-omit assoc
-
 variable [Monoid α] [Monoid β]
 
+#print Multiset.noncommProd /-
 /-- Product of a `s : multiset α` with `[monoid α]`, given a proof that `*` commutes
 on all elements `x ∈ s`. -/
 @[to_additive
@@ -138,7 +143,9 @@ def noncommProd (s : Multiset α) (comm : {x | x ∈ s}.Pairwise Commute) : α :
   s.noncommFold (· * ·) comm 1
 #align multiset.noncomm_prod Multiset.noncommProd
 #align multiset.noncomm_sum Multiset.noncommSum
+-/
 
+#print Multiset.noncommProd_coe /-
 @[simp, to_additive]
 theorem noncommProd_coe (l : List α) (comm) : noncommProd (l : Multiset α) comm = l.Prod :=
   by
@@ -151,20 +158,26 @@ theorem noncommProd_coe (l : List α) (comm) : noncommProd (l : Multiset α) com
     exact comm (List.mem_cons_of_mem _ hx) (List.mem_cons_of_mem _ hy)
 #align multiset.noncomm_prod_coe Multiset.noncommProd_coe
 #align multiset.noncomm_sum_coe Multiset.noncommSum_coe
+-/
 
+#print Multiset.noncommProd_empty /-
 @[simp, to_additive]
 theorem noncommProd_empty (h) : noncommProd (0 : Multiset α) h = 1 :=
   rfl
 #align multiset.noncomm_prod_empty Multiset.noncommProd_empty
 #align multiset.noncomm_sum_empty Multiset.noncommSum_empty
+-/
 
+#print Multiset.noncommProd_cons /-
 @[simp, to_additive]
 theorem noncommProd_cons (s : Multiset α) (a : α) (comm) :
     noncommProd (a ::ₘ s) comm = a * noncommProd s (comm.mono fun _ => mem_cons_of_mem) := by
   induction s using Quotient.inductionOn; simp
 #align multiset.noncomm_prod_cons Multiset.noncommProd_cons
 #align multiset.noncomm_sum_cons Multiset.noncommSum_cons
+-/
 
+#print Multiset.noncommProd_cons' /-
 @[to_additive]
 theorem noncommProd_cons' (s : Multiset α) (a : α) (comm) :
     noncommProd (a ::ₘ s) comm = noncommProd s (comm.mono fun _ => mem_cons_of_mem) * a :=
@@ -183,7 +196,9 @@ theorem noncommProd_cons' (s : Multiset α) (a : α) (comm) :
       · cases hy <;> simp [hy]
 #align multiset.noncomm_prod_cons' Multiset.noncommProd_cons'
 #align multiset.noncomm_sum_cons' Multiset.noncommSum_cons'
+-/
 
+#print Multiset.noncommProd_add /-
 @[to_additive]
 theorem noncommProd_add (s t : Multiset α) (comm) :
     noncommProd (s + t) comm =
@@ -192,7 +207,9 @@ theorem noncommProd_add (s t : Multiset α) (comm) :
   by rcases s with ⟨⟩; rcases t with ⟨⟩; simp
 #align multiset.noncomm_prod_add Multiset.noncommProd_add
 #align multiset.noncomm_sum_add Multiset.noncommSum_add
+-/
 
+#print Multiset.noncommProd_map_aux /-
 @[protected, to_additive]
 theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
     (comm : {x | x ∈ s}.Pairwise Commute) (f : F) : {x | x ∈ s.map f}.Pairwise Commute :=
@@ -202,7 +219,9 @@ theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
   exact (comm.of_refl hx hy).map f
 #align multiset.noncomm_prod_map_aux Multiset.noncommProd_map_aux
 #align multiset.noncomm_sum_map_aux Multiset.noncommSum_map_aux
+-/
 
+#print Multiset.noncommProd_map /-
 @[to_additive]
 theorem noncommProd_map [MonoidHomClass F α β] (s : Multiset α) (comm) (f : F) :
     f (s.noncommProd comm) = (s.map f).noncommProd (noncommProd_map_aux s comm f) :=
@@ -211,7 +230,9 @@ theorem noncommProd_map [MonoidHomClass F α β] (s : Multiset α) (comm) (f : F
   simpa using map_list_prod f _
 #align multiset.noncomm_prod_map Multiset.noncommProd_map
 #align multiset.noncomm_sum_map Multiset.noncommSum_map
+-/
 
+#print Multiset.noncommProd_eq_pow_card /-
 @[to_additive noncomm_sum_eq_card_nsmul]
 theorem noncommProd_eq_pow_card (s : Multiset α) (comm) (m : α) (h : ∀ x ∈ s, x = m) :
     s.noncommProd comm = m ^ s.card :=
@@ -221,6 +242,7 @@ theorem noncommProd_eq_pow_card (s : Multiset α) (comm) (m : α) (h : ∀ x ∈
   exact List.prod_eq_pow_card _ m h
 #align multiset.noncomm_prod_eq_pow_card Multiset.noncommProd_eq_pow_card
 #align multiset.noncomm_sum_eq_card_nsmul Multiset.noncommSum_eq_card_nsmul
+-/
 
 #print Multiset.noncommProd_eq_prod /-
 @[to_additive]
@@ -233,6 +255,7 @@ theorem noncommProd_eq_prod {α : Type _} [CommMonoid α] (s : Multiset α) :
 #align multiset.noncomm_sum_eq_sum Multiset.noncommSum_eq_sum
 -/
 
+#print Multiset.noncommProd_commute /-
 @[to_additive noncomm_sum_add_commute]
 theorem noncommProd_commute (s : Multiset α) (comm) (y : α) (h : ∀ x ∈ s, Commute y x) :
     Commute y (s.noncommProd comm) :=
@@ -242,6 +265,7 @@ theorem noncommProd_commute (s : Multiset α) (comm) (y : α) (h : ∀ x ∈ s,
   exact Commute.list_prod_right _ _ h
 #align multiset.noncomm_prod_commute Multiset.noncommProd_commute
 #align multiset.noncomm_sum_add_commute Multiset.noncommSum_addCommute
+-/
 
 end Multiset
 
@@ -249,6 +273,7 @@ namespace Finset
 
 variable [Monoid β] [Monoid γ]
 
+#print Finset.noncommProd /-
 /-- Product of a `s : finset α` mapped with `f : α → β` with `[monoid β]`,
 given a proof that `*` commutes on all elements `f x` for `x ∈ s`. -/
 @[to_additive
@@ -259,7 +284,9 @@ def noncommProd (s : Finset α) (f : α → β)
     exact comm.of_refl ha hb
 #align finset.noncomm_prod Finset.noncommProd
 #align finset.noncomm_sum Finset.noncommSum
+-/
 
+#print Finset.noncommProd_congr /-
 @[congr, to_additive]
 theorem noncommProd_congr {s₁ s₂ : Finset α} {f g : α → β} (h₁ : s₁ = s₂) (h₂ : ∀ x ∈ s₂, f x = g x)
     (comm) :
@@ -269,7 +296,9 @@ theorem noncommProd_congr {s₁ s₂ : Finset α} {f g : α → β} (h₁ : s₁
   by simp_rw [noncomm_prod, Multiset.map_congr (congr_arg _ h₁) h₂]
 #align finset.noncomm_prod_congr Finset.noncommProd_congr
 #align finset.noncomm_sum_congr Finset.noncommSum_congr
+-/
 
+#print Finset.noncommProd_toFinset /-
 @[simp, to_additive]
 theorem noncommProd_toFinset [DecidableEq α] (l : List α) (f : α → β) (comm) (hl : l.Nodup) :
     noncommProd l.toFinset f comm = (l.map f).Prod :=
@@ -278,13 +307,17 @@ theorem noncommProd_toFinset [DecidableEq α] (l : List α) (f : α → β) (com
   simp [noncomm_prod, hl]
 #align finset.noncomm_prod_to_finset Finset.noncommProd_toFinset
 #align finset.noncomm_sum_to_finset Finset.noncommSum_toFinset
+-/
 
+#print Finset.noncommProd_empty /-
 @[simp, to_additive]
 theorem noncommProd_empty (f : α → β) (h) : noncommProd (∅ : Finset α) f h = 1 :=
   rfl
 #align finset.noncomm_prod_empty Finset.noncommProd_empty
 #align finset.noncomm_sum_empty Finset.noncommSum_empty
+-/
 
+#print Finset.noncommProd_insert_of_not_mem /-
 @[simp, to_additive]
 theorem noncommProd_insert_of_not_mem [DecidableEq α] (s : Finset α) (a : α) (f : α → β) (comm)
     (ha : a ∉ s) :
@@ -293,7 +326,9 @@ theorem noncommProd_insert_of_not_mem [DecidableEq α] (s : Finset α) (a : α)
   by simp [insert_val_of_not_mem ha, noncomm_prod]
 #align finset.noncomm_prod_insert_of_not_mem Finset.noncommProd_insert_of_not_mem
 #align finset.noncomm_sum_insert_of_not_mem Finset.noncommSum_insert_of_not_mem
+-/
 
+#print Finset.noncommProd_insert_of_not_mem' /-
 @[to_additive]
 theorem noncommProd_insert_of_not_mem' [DecidableEq α] (s : Finset α) (a : α) (f : α → β) (comm)
     (ha : a ∉ s) :
@@ -302,6 +337,7 @@ theorem noncommProd_insert_of_not_mem' [DecidableEq α] (s : Finset α) (a : α)
   by simp [noncomm_prod, insert_val_of_not_mem ha, Multiset.noncommProd_cons']
 #align finset.noncomm_prod_insert_of_not_mem' Finset.noncommProd_insert_of_not_mem'
 #align finset.noncomm_sum_insert_of_not_mem' Finset.noncommSum_insert_of_not_mem'
+-/
 
 #print Finset.noncommProd_singleton /-
 @[simp, to_additive]
@@ -312,6 +348,7 @@ theorem noncommProd_singleton (a : α) (f : α → β) :
 #align finset.noncomm_sum_singleton Finset.noncommSum_singleton
 -/
 
+#print Finset.noncommProd_map /-
 @[to_additive]
 theorem noncommProd_map [MonoidHomClass F β γ] (s : Finset α) (f : α → β) (comm) (g : F) :
     g (s.noncommProd f comm) =
@@ -319,7 +356,9 @@ theorem noncommProd_map [MonoidHomClass F β γ] (s : Finset α) (f : α → β)
   by simp [noncomm_prod, Multiset.noncommProd_map]
 #align finset.noncomm_prod_map Finset.noncommProd_map
 #align finset.noncomm_sum_map Finset.noncommSum_map
+-/
 
+#print Finset.noncommProd_eq_pow_card /-
 @[to_additive noncomm_sum_eq_card_nsmul]
 theorem noncommProd_eq_pow_card (s : Finset α) (f : α → β) (comm) (m : β) (h : ∀ x ∈ s, f x = m) :
     s.noncommProd f comm = m ^ s.card :=
@@ -329,7 +368,9 @@ theorem noncommProd_eq_pow_card (s : Finset α) (f : α → β) (comm) (m : β)
   simpa using h
 #align finset.noncomm_prod_eq_pow_card Finset.noncommProd_eq_pow_card
 #align finset.noncomm_sum_eq_card_nsmul Finset.noncommSum_eq_card_nsmul
+-/
 
+#print Finset.noncommProd_commute /-
 @[to_additive noncomm_sum_add_commute]
 theorem noncommProd_commute (s : Finset α) (f : α → β) (comm) (y : β)
     (h : ∀ x ∈ s, Commute y (f x)) : Commute y (s.noncommProd f comm) :=
@@ -341,6 +382,7 @@ theorem noncommProd_commute (s : Finset α) (f : α → β) (comm) (y : β)
   exact h x hx
 #align finset.noncomm_prod_commute Finset.noncommProd_commute
 #align finset.noncomm_sum_add_commute Finset.noncommSum_addCommute
+-/
 
 #print Finset.noncommProd_eq_prod /-
 @[to_additive]
@@ -354,6 +396,7 @@ theorem noncommProd_eq_prod {β : Type _} [CommMonoid β] (s : Finset α) (f : 
 #align finset.noncomm_sum_eq_sum Finset.noncommSum_eq_sum
 -/
 
+#print Finset.noncommProd_union_of_disjoint /-
 /-- The non-commutative version of `finset.prod_union` -/
 @[to_additive "The non-commutative version of `finset.sum_union`"]
 theorem noncommProd_union_of_disjoint [DecidableEq α] {s t : Finset α} (h : Disjoint s t)
@@ -369,7 +412,9 @@ theorem noncommProd_union_of_disjoint [DecidableEq α] {s t : Finset α} (h : Di
     sl'.append tl' h]
 #align finset.noncomm_prod_union_of_disjoint Finset.noncommProd_union_of_disjoint
 #align finset.noncomm_sum_union_of_disjoint Finset.noncommSum_union_of_disjoint
+-/
 
+#print Finset.noncommProd_mul_distrib_aux /-
 @[protected, to_additive]
 theorem noncommProd_mul_distrib_aux {s : Finset α} {f : α → β} {g : α → β}
     (comm_ff : (s : Set α).Pairwise fun x y => Commute (f x) (f y))
@@ -385,7 +430,9 @@ theorem noncommProd_mul_distrib_aux {s : Finset α} {f : α → β} {g : α →
   · exact comm_gg.of_refl hx hy
 #align finset.noncomm_prod_mul_distrib_aux Finset.noncommProd_mul_distrib_aux
 #align finset.noncomm_sum_add_distrib_aux Finset.noncommSum_add_distrib_aux
+-/
 
+#print Finset.noncommProd_mul_distrib /-
 /-- The non-commutative version of `finset.prod_mul_distrib` -/
 @[to_additive "The non-commutative version of `finset.sum_add_distrib`"]
 theorem noncommProd_mul_distrib {s : Finset α} (f : α → β) (g : α → β) (comm_ff comm_gg comm_gf) :
@@ -408,11 +455,13 @@ theorem noncommProd_mul_distrib {s : Finset α} (f : α → β) (g : α → β)
   exact comm_gf (mem_insert_self x s) (mem_insert_of_mem hy) (ne_of_mem_of_not_mem hy hnmem).symm
 #align finset.noncomm_prod_mul_distrib Finset.noncommProd_mul_distrib
 #align finset.noncomm_sum_add_distrib Finset.noncommSum_add_distrib
+-/
 
 section FinitePi
 
 variable {M : ι → Type _} [∀ i, Monoid (M i)]
 
+#print Finset.noncommProd_mul_single /-
 @[to_additive]
 theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
     (univ.noncommProd (fun i => Pi.mulSingle i (x i)) fun i _ j _ _ =>
@@ -427,7 +476,9 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
   · intro i h; simp at h ; simp [h]
 #align finset.noncomm_prod_mul_single Finset.noncommProd_mul_single
 #align finset.noncomm_sum_single Finset.noncommSum_single
+-/
 
+#print MonoidHom.pi_ext /-
 @[to_additive]
 theorem MonoidHom.pi_ext [Finite ι] [DecidableEq ι] {f g : (∀ i, M i) →* γ}
     (h : ∀ i x, f (Pi.mulSingle i x) = g (Pi.mulSingle i x)) : f = g :=
@@ -438,6 +489,7 @@ theorem MonoidHom.pi_ext [Finite ι] [DecidableEq ι] {f g : (∀ i, M i) →* 
   congr 1 with i; exact h i (x i)
 #align monoid_hom.pi_ext MonoidHom.pi_ext
 #align add_monoid_hom.pi_ext AddMonoidHom.pi_ext
+-/
 
 end FinitePi
 
Diff
@@ -45,7 +45,7 @@ namespace Multiset
 /-- Fold of a `s : multiset α` with `f : α → β → β`, given a proof that `left_commutative f`
 on all elements `x ∈ s`. -/
 def noncommFoldr (s : Multiset α)
-    (comm : { x | x ∈ s }.Pairwise fun x y => ∀ b, f x (f y b) = f y (f x b)) (b : β) : β :=
+    (comm : {x | x ∈ s}.Pairwise fun x y => ∀ b, f x (f y b) = f y (f x b)) (b : β) : β :=
   s.attach.foldr (f ∘ Subtype.val)
     (fun ⟨x, hx⟩ ⟨y, hy⟩ =>
       haveI : IsRefl α fun x y => ∀ b, f x (f y b) = f y (f x b) := ⟨fun x b => rfl⟩
@@ -89,8 +89,7 @@ include assoc
 #print Multiset.noncommFold /-
 /-- Fold of a `s : multiset α` with an associative `op : α → α → α`, given a proofs that `op`
 is commutative on all elements `x ∈ s`. -/
-def noncommFold (s : Multiset α) (comm : { x | x ∈ s }.Pairwise fun x y => op x y = op y x) :
-    α → α :=
+def noncommFold (s : Multiset α) (comm : {x | x ∈ s}.Pairwise fun x y => op x y = op y x) : α → α :=
   noncommFoldr op s fun x hx y hy h b => by rw [← assoc.assoc, comm hx hy h, assoc.assoc]
 #align multiset.noncomm_fold Multiset.noncommFold
 -/
@@ -135,7 +134,7 @@ variable [Monoid α] [Monoid β]
 on all elements `x ∈ s`. -/
 @[to_additive
       "Sum of a `s : multiset α` with `[add_monoid α]`, given a proof that `+` commutes\non all elements `x ∈ s`."]
-def noncommProd (s : Multiset α) (comm : { x | x ∈ s }.Pairwise Commute) : α :=
+def noncommProd (s : Multiset α) (comm : {x | x ∈ s}.Pairwise Commute) : α :=
   s.noncommFold (· * ·) comm 1
 #align multiset.noncomm_prod Multiset.noncommProd
 #align multiset.noncomm_sum Multiset.noncommSum
@@ -196,7 +195,7 @@ theorem noncommProd_add (s t : Multiset α) (comm) :
 
 @[protected, to_additive]
 theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
-    (comm : { x | x ∈ s }.Pairwise Commute) (f : F) : { x | x ∈ s.map f }.Pairwise Commute :=
+    (comm : {x | x ∈ s}.Pairwise Commute) (f : F) : {x | x ∈ s.map f}.Pairwise Commute :=
   by
   simp only [Multiset.mem_map]
   rintro _ ⟨x, hx, rfl⟩ _ ⟨y, hy, rfl⟩ _
@@ -348,9 +347,9 @@ theorem noncommProd_commute (s : Finset α) (f : α → β) (comm) (y : β)
 theorem noncommProd_eq_prod {β : Type _} [CommMonoid β] (s : Finset α) (f : α → β) :
     (noncommProd s f fun _ _ _ _ _ => Commute.all _ _) = s.Prod f := by
   classical
-    induction' s using Finset.induction_on with a s ha IH
-    · simp
-    · simp [ha, IH]
+  induction' s using Finset.induction_on with a s ha IH
+  · simp
+  · simp [ha, IH]
 #align finset.noncomm_prod_eq_prod Finset.noncommProd_eq_prod
 #align finset.noncomm_sum_eq_sum Finset.noncommSum_eq_sum
 -/
@@ -358,7 +357,7 @@ theorem noncommProd_eq_prod {β : Type _} [CommMonoid β] (s : Finset α) (f : 
 /-- The non-commutative version of `finset.prod_union` -/
 @[to_additive "The non-commutative version of `finset.sum_union`"]
 theorem noncommProd_union_of_disjoint [DecidableEq α] {s t : Finset α} (h : Disjoint s t)
-    (f : α → β) (comm : { x | x ∈ s ∪ t }.Pairwise fun a b => Commute (f a) (f b)) :
+    (f : α → β) (comm : {x | x ∈ s ∪ t}.Pairwise fun a b => Commute (f a) (f b)) :
     noncommProd (s ∪ t) f comm =
       noncommProd s f (comm.mono <| coe_subset.2 <| subset_union_left _ _) *
         noncommProd t f (comm.mono <| coe_subset.2 <| subset_union_right _ _) :=
@@ -394,19 +393,19 @@ theorem noncommProd_mul_distrib {s : Finset α} (f : α → β) (g : α → β)
       noncommProd s f comm_ff * noncommProd s g comm_gg :=
   by
   classical
-    induction' s using Finset.induction_on with x s hnmem ih
-    · simp
-    simp only [Finset.noncommProd_insert_of_not_mem _ _ _ _ hnmem]
-    specialize
-      ih (comm_ff.mono fun _ => mem_insert_of_mem) (comm_gg.mono fun _ => mem_insert_of_mem)
-        (comm_gf.mono fun _ => mem_insert_of_mem)
-    rw [ih, Pi.mul_apply]
-    simp only [mul_assoc]
-    congr 1
-    simp only [← mul_assoc]
-    congr 1
-    refine' noncomm_prod_commute _ _ _ _ fun y hy => _
-    exact comm_gf (mem_insert_self x s) (mem_insert_of_mem hy) (ne_of_mem_of_not_mem hy hnmem).symm
+  induction' s using Finset.induction_on with x s hnmem ih
+  · simp
+  simp only [Finset.noncommProd_insert_of_not_mem _ _ _ _ hnmem]
+  specialize
+    ih (comm_ff.mono fun _ => mem_insert_of_mem) (comm_gg.mono fun _ => mem_insert_of_mem)
+      (comm_gf.mono fun _ => mem_insert_of_mem)
+  rw [ih, Pi.mul_apply]
+  simp only [mul_assoc]
+  congr 1
+  simp only [← mul_assoc]
+  congr 1
+  refine' noncomm_prod_commute _ _ _ _ fun y hy => _
+  exact comm_gf (mem_insert_self x s) (mem_insert_of_mem hy) (ne_of_mem_of_not_mem hy hnmem).symm
 #align finset.noncomm_prod_mul_distrib Finset.noncommProd_mul_distrib
 #align finset.noncomm_sum_add_distrib Finset.noncommSum_add_distrib
 
Diff
@@ -178,7 +178,7 @@ theorem noncommProd_cons' (s : Multiset α) (a : α) (comm) :
     · congr 1
       apply comm.of_refl <;> simp
     · intro x hx y hy
-      simp only [quot_mk_to_coe, List.mem_cons, mem_coe, cons_coe] at hx hy
+      simp only [quot_mk_to_coe, List.mem_cons, mem_coe, cons_coe] at hx hy 
       apply comm
       · cases hx <;> simp [hx]
       · cases hy <;> simp [hy]
@@ -275,7 +275,7 @@ theorem noncommProd_congr {s₁ s₂ : Finset α} {f g : α → β} (h₁ : s₁
 theorem noncommProd_toFinset [DecidableEq α] (l : List α) (f : α → β) (comm) (hl : l.Nodup) :
     noncommProd l.toFinset f comm = (l.map f).Prod :=
   by
-  rw [← List.dedup_eq_self] at hl
+  rw [← List.dedup_eq_self] at hl 
   simp [noncomm_prod, hl]
 #align finset.noncomm_prod_to_finset Finset.noncommProd_toFinset
 #align finset.noncomm_sum_to_finset Finset.noncommSum_toFinset
@@ -365,7 +365,7 @@ theorem noncommProd_union_of_disjoint [DecidableEq α] {s t : Finset α} (h : Di
   by
   obtain ⟨sl, sl', rfl⟩ := exists_list_nodup_eq s
   obtain ⟨tl, tl', rfl⟩ := exists_list_nodup_eq t
-  rw [List.disjoint_toFinset_iff_disjoint] at h
+  rw [List.disjoint_toFinset_iff_disjoint] at h 
   simp [sl', tl', noncomm_prod_to_finset, ← List.prod_append, ← List.toFinset_append,
     sl'.append tl' h]
 #align finset.noncomm_prod_union_of_disjoint Finset.noncommProd_union_of_disjoint
@@ -425,7 +425,7 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
   rw [← insert_erase (mem_univ i), noncomm_prod_insert_of_not_mem' _ _ _ _ (not_mem_erase _ _),
     noncomm_prod_eq_pow_card, one_pow]
   · simp
-  · intro i h; simp at h; simp [h]
+  · intro i h; simp at h ; simp [h]
 #align finset.noncomm_prod_mul_single Finset.noncommProd_mul_single
 #align finset.noncomm_sum_single Finset.noncommSum_single
 
Diff
@@ -54,12 +54,6 @@ def noncommFoldr (s : Multiset α)
 #align multiset.noncomm_foldr Multiset.noncommFoldr
 -/
 
-/- warning: multiset.noncomm_foldr_coe -> Multiset.noncommFoldr_coe is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} (f : α -> β -> β) (l : List.{u1} α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (List.{u1} α) (Multiset.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (List.{u1} α) (Multiset.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (List.{u1} α) (Multiset.{u1} α) (coeBase.{succ u1, succ u1} (List.{u1} α) (Multiset.{u1} α) (Multiset.hasCoe.{u1} α)))) l))) (fun (x : α) (y : α) => forall (b : β), Eq.{succ u2} β (f x (f y b)) (f y (f x b)))) (b : β), Eq.{succ u2} β (Multiset.noncommFoldr.{u1, u2} α β f ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (List.{u1} α) (Multiset.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (List.{u1} α) (Multiset.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (List.{u1} α) (Multiset.{u1} α) (coeBase.{succ u1, succ u1} (List.{u1} α) (Multiset.{u1} α) (Multiset.hasCoe.{u1} α)))) l) comm b) (List.foldr.{u1, u2} α β f b l)
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} (f : α -> β -> β) (l : List.{u2} α) (comm : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x (Multiset.ofList.{u2} α l))) (fun (x : α) (y : α) => forall (b : β), Eq.{succ u1} β (f x (f y b)) (f y (f x b)))) (b : β), Eq.{succ u1} β (Multiset.noncommFoldr.{u2, u1} α β f (Multiset.ofList.{u2} α l) comm b) (List.foldr.{u2, u1} α β f b l)
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_foldr_coe Multiset.noncommFoldr_coeₓ'. -/
 @[simp]
 theorem noncommFoldr_coe (l : List α) (comm) (b : β) :
     noncommFoldr f (l : Multiset α) comm b = l.foldr f b :=
@@ -69,23 +63,11 @@ theorem noncommFoldr_coe (l : List α) (comm) (b : β) :
   simp [List.map_pmap, List.pmap_eq_map]
 #align multiset.noncomm_foldr_coe Multiset.noncommFoldr_coe
 
-/- warning: multiset.noncomm_foldr_empty -> Multiset.noncommFoldr_empty is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} (f : α -> β -> β) (h : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x (OfNat.ofNat.{u1} (Multiset.{u1} α) 0 (OfNat.mk.{u1} (Multiset.{u1} α) 0 (Zero.zero.{u1} (Multiset.{u1} α) (Multiset.hasZero.{u1} α)))))) (fun (x : α) (y : α) => forall (b : β), Eq.{succ u2} β (f x (f y b)) (f y (f x b)))) (b : β), Eq.{succ u2} β (Multiset.noncommFoldr.{u1, u2} α β f (OfNat.ofNat.{u1} (Multiset.{u1} α) 0 (OfNat.mk.{u1} (Multiset.{u1} α) 0 (Zero.zero.{u1} (Multiset.{u1} α) (Multiset.hasZero.{u1} α)))) h b) b
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} (f : α -> β -> β) (h : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x (OfNat.ofNat.{u2} (Multiset.{u2} α) 0 (Zero.toOfNat0.{u2} (Multiset.{u2} α) (Multiset.instZeroMultiset.{u2} α))))) (fun (x : α) (y : α) => forall (b : β), Eq.{succ u1} β (f x (f y b)) (f y (f x b)))) (b : β), Eq.{succ u1} β (Multiset.noncommFoldr.{u2, u1} α β f (OfNat.ofNat.{u2} (Multiset.{u2} α) 0 (Zero.toOfNat0.{u2} (Multiset.{u2} α) (Multiset.instZeroMultiset.{u2} α))) h b) b
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_foldr_empty Multiset.noncommFoldr_emptyₓ'. -/
 @[simp]
 theorem noncommFoldr_empty (h) (b : β) : noncommFoldr f (0 : Multiset α) h b = b :=
   rfl
 #align multiset.noncomm_foldr_empty Multiset.noncommFoldr_empty
 
-/- warning: multiset.noncomm_foldr_cons -> Multiset.noncommFoldr_cons is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} (f : α -> β -> β) (s : Multiset.{u1} α) (a : α) (h : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x (Multiset.cons.{u1} α a s))) (fun (x : α) (y : α) => forall (b : β), Eq.{succ u2} β (f x (f y b)) (f y (f x b)))) (h' : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x s)) (fun (x : α) (y : α) => forall (b : β), Eq.{succ u2} β (f x (f y b)) (f y (f x b)))) (b : β), Eq.{succ u2} β (Multiset.noncommFoldr.{u1, u2} α β f (Multiset.cons.{u1} α a s) h b) (f a (Multiset.noncommFoldr.{u1, u2} α β f s h' b))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} (f : α -> β -> β) (s : Multiset.{u2} α) (a : α) (h : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x (Multiset.cons.{u2} α a s))) (fun (x : α) (y : α) => forall (b : β), Eq.{succ u1} β (f x (f y b)) (f y (f x b)))) (h' : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (fun (x : α) (y : α) => forall (b : β), Eq.{succ u1} β (f x (f y b)) (f y (f x b)))) (b : β), Eq.{succ u1} β (Multiset.noncommFoldr.{u2, u1} α β f (Multiset.cons.{u2} α a s) h b) (f a (Multiset.noncommFoldr.{u2, u1} α β f s h' b))
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_foldr_cons Multiset.noncommFoldr_consₓ'. -/
 theorem noncommFoldr_cons (s : Multiset α) (a : α) (h h') (b : β) :
     noncommFoldr f (a ::ₘ s) h b = f a (noncommFoldr f s h' b) :=
   by
@@ -93,12 +75,6 @@ theorem noncommFoldr_cons (s : Multiset α) (a : α) (h h') (b : β) :
   simp
 #align multiset.noncomm_foldr_cons Multiset.noncommFoldr_cons
 
-/- warning: multiset.noncomm_foldr_eq_foldr -> Multiset.noncommFoldr_eq_foldr is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} (f : α -> β -> β) (s : Multiset.{u1} α) (h : LeftCommutative.{u1, u2} α β f) (b : β), Eq.{succ u2} β (Multiset.noncommFoldr.{u1, u2} α β f s (fun (x : α) (_x : Membership.Mem.{u1, u1} α (Set.{u1} α) (Set.hasMem.{u1} α) x (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x s))) (y : α) (_x : Membership.Mem.{u1, u1} α (Set.{u1} α) (Set.hasMem.{u1} α) y (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x s))) (_x : Ne.{succ u1} α x y) => h x y) b) (Multiset.foldr.{u1, u2} α β f h b s)
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} (f : α -> β -> β) (s : Multiset.{u2} α) (h : LeftCommutative.{u2, u1} α β f) (b : β), Eq.{succ u1} β (Multiset.noncommFoldr.{u2, u1} α β f s (fun (x : α) (_x : Membership.mem.{u2, u2} α (Set.{u2} α) (Set.instMembershipSet.{u2} α) x (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s))) (y : α) (_x : Membership.mem.{u2, u2} α (Set.{u2} α) (Set.instMembershipSet.{u2} α) y (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s))) (_x : Ne.{succ u2} α x y) => h x y) b) (Multiset.foldr.{u2, u1} α β f h b s)
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_foldr_eq_foldr Multiset.noncommFoldr_eq_foldrₓ'. -/
 theorem noncommFoldr_eq_foldr (s : Multiset α) (h : LeftCommutative f) (b : β) :
     noncommFoldr f s (fun x _ y _ _ => h x y) b = foldr f h b s :=
   by
@@ -155,12 +131,6 @@ omit assoc
 
 variable [Monoid α] [Monoid β]
 
-/- warning: multiset.noncomm_prod -> Multiset.noncommProd is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α), (Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x s)) (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))) -> α
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α), (Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x s)) (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))) -> α
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod Multiset.noncommProdₓ'. -/
 /-- Product of a `s : multiset α` with `[monoid α]`, given a proof that `*` commutes
 on all elements `x ∈ s`. -/
 @[to_additive
@@ -170,12 +140,6 @@ def noncommProd (s : Multiset α) (comm : { x | x ∈ s }.Pairwise Commute) : α
 #align multiset.noncomm_prod Multiset.noncommProd
 #align multiset.noncomm_sum Multiset.noncommSum
 
-/- warning: multiset.noncomm_prod_coe -> Multiset.noncommProd_coe is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (l : List.{u1} α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (List.{u1} α) (Multiset.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (List.{u1} α) (Multiset.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (List.{u1} α) (Multiset.{u1} α) (coeBase.{succ u1, succ u1} (List.{u1} α) (Multiset.{u1} α) (Multiset.hasCoe.{u1} α)))) l))) (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))), Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (List.{u1} α) (Multiset.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (List.{u1} α) (Multiset.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (List.{u1} α) (Multiset.{u1} α) (coeBase.{succ u1, succ u1} (List.{u1} α) (Multiset.{u1} α) (Multiset.hasCoe.{u1} α)))) l) comm) (List.prod.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)) (MulOneClass.toHasOne.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)) l)
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (l : List.{u1} α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x (Multiset.ofList.{u1} α l))) (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))), Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 (Multiset.ofList.{u1} α l) comm) (List.prod.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)) (Monoid.toOne.{u1} α _inst_1) l)
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_coe Multiset.noncommProd_coeₓ'. -/
 @[simp, to_additive]
 theorem noncommProd_coe (l : List α) (comm) : noncommProd (l : Multiset α) comm = l.Prod :=
   by
@@ -189,24 +153,12 @@ theorem noncommProd_coe (l : List α) (comm) : noncommProd (l : Multiset α) com
 #align multiset.noncomm_prod_coe Multiset.noncommProd_coe
 #align multiset.noncomm_sum_coe Multiset.noncommSum_coe
 
-/- warning: multiset.noncomm_prod_empty -> Multiset.noncommProd_empty is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (h : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x (OfNat.ofNat.{u1} (Multiset.{u1} α) 0 (OfNat.mk.{u1} (Multiset.{u1} α) 0 (Zero.zero.{u1} (Multiset.{u1} α) (Multiset.hasZero.{u1} α)))))) (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))), Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 (OfNat.ofNat.{u1} (Multiset.{u1} α) 0 (OfNat.mk.{u1} (Multiset.{u1} α) 0 (Zero.zero.{u1} (Multiset.{u1} α) (Multiset.hasZero.{u1} α)))) h) (OfNat.ofNat.{u1} α 1 (OfNat.mk.{u1} α 1 (One.one.{u1} α (MulOneClass.toHasOne.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))))
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (h : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x (OfNat.ofNat.{u1} (Multiset.{u1} α) 0 (Zero.toOfNat0.{u1} (Multiset.{u1} α) (Multiset.instZeroMultiset.{u1} α))))) (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))), Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 (OfNat.ofNat.{u1} (Multiset.{u1} α) 0 (Zero.toOfNat0.{u1} (Multiset.{u1} α) (Multiset.instZeroMultiset.{u1} α))) h) (OfNat.ofNat.{u1} α 1 (One.toOfNat1.{u1} α (Monoid.toOne.{u1} α _inst_1)))
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_empty Multiset.noncommProd_emptyₓ'. -/
 @[simp, to_additive]
 theorem noncommProd_empty (h) : noncommProd (0 : Multiset α) h = 1 :=
   rfl
 #align multiset.noncomm_prod_empty Multiset.noncommProd_empty
 #align multiset.noncomm_sum_empty Multiset.noncommSum_empty
 
-/- warning: multiset.noncomm_prod_cons -> Multiset.noncommProd_cons is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α) (a : α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x (Multiset.cons.{u1} α a s))) (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))), Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 (Multiset.cons.{u1} α a s) comm) (HMul.hMul.{u1, u1, u1} α α α (instHMul.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) a (Multiset.noncommProd.{u1} α _inst_1 s (Set.Pairwise.mono.{u1} α (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x (Multiset.cons.{u1} α a s))) (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x s)) (fun (_x : α) => Multiset.mem_cons_of_mem.{u1} α _x a s) comm)))
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α) (a : α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x (Multiset.cons.{u1} α a s))) (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))), Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 (Multiset.cons.{u1} α a s) comm) (HMul.hMul.{u1, u1, u1} α α α (instHMul.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) a (Multiset.noncommProd.{u1} α _inst_1 s (Set.Pairwise.mono.{u1} α (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.1019 : α) => Quot.liftOn.{succ u1, 1} (List.{u1} α) Prop (Setoid.r.{succ u1} (List.{u1} α) (List.isSetoid.{u1} α)) (Multiset.cons.{u1} α a s) (fun (l : List.{u1} α) => Membership.mem.{u1, u1} α (List.{u1} α) (List.instMembershipList.{u1} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.1019 l) (Multiset.Mem.proof_1.{u1} α x._@.Mathlib.Data.Finset.NoncommProd._hyg.1019)) (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x s)) (fun (_x : α) => Multiset.mem_cons_of_mem.{u1} α _x a s) comm)))
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_cons Multiset.noncommProd_consₓ'. -/
 @[simp, to_additive]
 theorem noncommProd_cons (s : Multiset α) (a : α) (comm) :
     noncommProd (a ::ₘ s) comm = a * noncommProd s (comm.mono fun _ => mem_cons_of_mem) := by
@@ -214,12 +166,6 @@ theorem noncommProd_cons (s : Multiset α) (a : α) (comm) :
 #align multiset.noncomm_prod_cons Multiset.noncommProd_cons
 #align multiset.noncomm_sum_cons Multiset.noncommSum_cons
 
-/- warning: multiset.noncomm_prod_cons' -> Multiset.noncommProd_cons' is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α) (a : α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x (Multiset.cons.{u1} α a s))) (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))), Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 (Multiset.cons.{u1} α a s) comm) (HMul.hMul.{u1, u1, u1} α α α (instHMul.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) (Multiset.noncommProd.{u1} α _inst_1 s (Set.Pairwise.mono.{u1} α (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x (Multiset.cons.{u1} α a s))) (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x s)) (fun (_x : α) => Multiset.mem_cons_of_mem.{u1} α _x a s) comm)) a)
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α) (a : α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x (Multiset.cons.{u1} α a s))) (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))), Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 (Multiset.cons.{u1} α a s) comm) (HMul.hMul.{u1, u1, u1} α α α (instHMul.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) (Multiset.noncommProd.{u1} α _inst_1 s (Set.Pairwise.mono.{u1} α (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.1077 : α) => Quot.liftOn.{succ u1, 1} (List.{u1} α) Prop (Setoid.r.{succ u1} (List.{u1} α) (List.isSetoid.{u1} α)) (Multiset.cons.{u1} α a s) (fun (l : List.{u1} α) => Membership.mem.{u1, u1} α (List.{u1} α) (List.instMembershipList.{u1} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.1077 l) (Multiset.Mem.proof_1.{u1} α x._@.Mathlib.Data.Finset.NoncommProd._hyg.1077)) (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x s)) (fun (_x : α) => Multiset.mem_cons_of_mem.{u1} α _x a s) comm)) a)
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_cons' Multiset.noncommProd_cons'ₓ'. -/
 @[to_additive]
 theorem noncommProd_cons' (s : Multiset α) (a : α) (comm) :
     noncommProd (a ::ₘ s) comm = noncommProd s (comm.mono fun _ => mem_cons_of_mem) * a :=
@@ -239,12 +185,6 @@ theorem noncommProd_cons' (s : Multiset α) (a : α) (comm) :
 #align multiset.noncomm_prod_cons' Multiset.noncommProd_cons'
 #align multiset.noncomm_sum_cons' Multiset.noncommSum_cons'
 
-/- warning: multiset.noncomm_prod_add -> Multiset.noncommProd_add is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α) (t : Multiset.{u1} α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x (HAdd.hAdd.{u1, u1, u1} (Multiset.{u1} α) (Multiset.{u1} α) (Multiset.{u1} α) (instHAdd.{u1} (Multiset.{u1} α) (Multiset.hasAdd.{u1} α)) s t))) (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))), Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 (HAdd.hAdd.{u1, u1, u1} (Multiset.{u1} α) (Multiset.{u1} α) (Multiset.{u1} α) (instHAdd.{u1} (Multiset.{u1} α) (Multiset.hasAdd.{u1} α)) s t) comm) (HMul.hMul.{u1, u1, u1} α α α (instHMul.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) (Multiset.noncommProd.{u1} α _inst_1 s (Set.Pairwise.mono.{u1} α (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x (HAdd.hAdd.{u1, u1, u1} (Multiset.{u1} α) (Multiset.{u1} α) (Multiset.{u1} α) (instHAdd.{u1} (Multiset.{u1} α) (Multiset.hasAdd.{u1} α)) s t))) (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x s)) (Multiset.subset_of_le.{u1} α s (HAdd.hAdd.{u1, u1, u1} (Multiset.{u1} α) (Multiset.{u1} α) (Multiset.{u1} α) (instHAdd.{u1} (Multiset.{u1} α) (Multiset.hasAdd.{u1} α)) s t) (Multiset.le_add_right.{u1} α s t)) comm)) (Multiset.noncommProd.{u1} α _inst_1 t (Set.Pairwise.mono.{u1} α (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x (HAdd.hAdd.{u1, u1, u1} (Multiset.{u1} α) (Multiset.{u1} α) (Multiset.{u1} α) (instHAdd.{u1} (Multiset.{u1} α) (Multiset.hasAdd.{u1} α)) s t))) (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x t)) (Multiset.subset_of_le.{u1} α t (HAdd.hAdd.{u1, u1, u1} (Multiset.{u1} α) (Multiset.{u1} α) (Multiset.{u1} α) (instHAdd.{u1} (Multiset.{u1} α) (Multiset.hasAdd.{u1} α)) s t) (Multiset.le_add_left.{u1} α t s)) comm)))
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α) (t : Multiset.{u1} α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x (HAdd.hAdd.{u1, u1, u1} (Multiset.{u1} α) (Multiset.{u1} α) (Multiset.{u1} α) (instHAdd.{u1} (Multiset.{u1} α) (Multiset.instAddMultiset.{u1} α)) s t))) (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))), Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 (HAdd.hAdd.{u1, u1, u1} (Multiset.{u1} α) (Multiset.{u1} α) (Multiset.{u1} α) (instHAdd.{u1} (Multiset.{u1} α) (Multiset.instAddMultiset.{u1} α)) s t) comm) (HMul.hMul.{u1, u1, u1} α α α (instHMul.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) (Multiset.noncommProd.{u1} α _inst_1 s (Set.Pairwise.mono.{u1} α (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) (fun (a : α) => Quot.liftOn.{succ u1, 1} (List.{u1} α) Prop (Setoid.r.{succ u1} (List.{u1} α) (List.isSetoid.{u1} α)) (HAdd.hAdd.{u1, u1, u1} (Multiset.{u1} α) (Multiset.{u1} α) (Multiset.{u1} α) (instHAdd.{u1} (Multiset.{u1} α) (Multiset.instAddMultiset.{u1} α)) s t) (fun (l : List.{u1} α) => Membership.mem.{u1, u1} α (List.{u1} α) (List.instMembershipList.{u1} α) a l) (Multiset.Mem.proof_1.{u1} α a)) (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x s)) (Multiset.subset_of_le.{u1} α s (HAdd.hAdd.{u1, u1, u1} (Multiset.{u1} α) (Multiset.{u1} α) (Multiset.{u1} α) (instHAdd.{u1} (Multiset.{u1} α) (Multiset.instAddMultiset.{u1} α)) s t) (Multiset.le_add_right.{u1} α s t)) comm)) (Multiset.noncommProd.{u1} α _inst_1 t (Set.Pairwise.mono.{u1} α (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1))) (fun (a : α) => Quot.liftOn.{succ u1, 1} (List.{u1} α) Prop (Setoid.r.{succ u1} (List.{u1} α) (List.isSetoid.{u1} α)) (HAdd.hAdd.{u1, u1, u1} (Multiset.{u1} α) (Multiset.{u1} α) (Multiset.{u1} α) (instHAdd.{u1} (Multiset.{u1} α) (Multiset.instAddMultiset.{u1} α)) s t) (fun (l : List.{u1} α) => Membership.mem.{u1, u1} α (List.{u1} α) (List.instMembershipList.{u1} α) a l) (Multiset.Mem.proof_1.{u1} α a)) (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x t)) (Multiset.subset_of_le.{u1} α t (HAdd.hAdd.{u1, u1, u1} (Multiset.{u1} α) (Multiset.{u1} α) (Multiset.{u1} α) (instHAdd.{u1} (Multiset.{u1} α) (Multiset.instAddMultiset.{u1} α)) s t) (Multiset.le_add_left.{u1} α t s)) comm)))
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_add Multiset.noncommProd_addₓ'. -/
 @[to_additive]
 theorem noncommProd_add (s t : Multiset α) (comm) :
     noncommProd (s + t) comm =
@@ -254,12 +194,6 @@ theorem noncommProd_add (s t : Multiset α) (comm) :
 #align multiset.noncomm_prod_add Multiset.noncommProd_add
 #align multiset.noncomm_sum_add Multiset.noncommSum_add
 
-/- warning: multiset.noncomm_prod_map_aux -> Multiset.noncommProd_map_aux is a dubious translation:
-lean 3 declaration is
-  forall {F : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u3} β] [_inst_3 : MonoidHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2)] (s : Multiset.{u2} α), (Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.Mem.{u2, u2} α (Multiset.{u2} α) (Multiset.hasMem.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) -> (forall (f : F), Set.Pairwise.{u3} β (setOf.{u3} β (fun (x : β) => Membership.Mem.{u3, u3} β (Multiset.{u3} β) (Multiset.hasMem.{u3} β) x (Multiset.map.{u2, u3} α β (coeFn.{succ u1, max (succ u2) (succ u3)} F (fun (_x : F) => α -> β) (FunLike.hasCoeToFun.{succ u1, succ u2, succ u3} F α (fun (_x : α) => β) (MulHomClass.toFunLike.{u1, u2, u3} F α β (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2) _inst_3))) f) s))) (Commute.{u3} β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2))))
-but is expected to have type
-  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α), (Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) -> (forall (f : F), Set.Pairwise.{u1} β (setOf.{u1} β (fun (x : β) => Membership.mem.{u1, u1} β (Multiset.{u1} β) (Multiset.instMembershipMultiset.{u1} β) x (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s))) (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2))))
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_map_aux Multiset.noncommProd_map_auxₓ'. -/
 @[protected, to_additive]
 theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
     (comm : { x | x ∈ s }.Pairwise Commute) (f : F) : { x | x ∈ s.map f }.Pairwise Commute :=
@@ -270,12 +204,6 @@ theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
 #align multiset.noncomm_prod_map_aux Multiset.noncommProd_map_aux
 #align multiset.noncomm_sum_map_aux Multiset.noncommSum_map_aux
 
-/- warning: multiset.noncomm_prod_map -> Multiset.noncommProd_map is a dubious translation:
-lean 3 declaration is
-  forall {F : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u3} β] [_inst_3 : MonoidHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2)] (s : Multiset.{u2} α) (comm : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.Mem.{u2, u2} α (Multiset.{u2} α) (Multiset.hasMem.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) (f : F), Eq.{succ u3} β (coeFn.{succ u1, max (succ u2) (succ u3)} F (fun (_x : F) => α -> β) (FunLike.hasCoeToFun.{succ u1, succ u2, succ u3} F α (fun (_x : α) => β) (MulHomClass.toFunLike.{u1, u2, u3} F α β (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2) _inst_3))) f (Multiset.noncommProd.{u2} α _inst_1 s comm)) (Multiset.noncommProd.{u3} β _inst_2 (Multiset.map.{u2, u3} α β (coeFn.{succ u1, max (succ u2) (succ u3)} F (fun (_x : F) => α -> β) (FunLike.hasCoeToFun.{succ u1, succ u2, succ u3} F α (fun (_x : α) => β) (MulHomClass.toFunLike.{u1, u2, u3} F α β (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2) _inst_3))) f) s) (Multiset.noncommProd_map_aux.{u1, u2, u3} F α β _inst_1 _inst_2 _inst_3 s comm f))
-but is expected to have type
-  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α) (comm : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) (f : F), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : α) => β) (Multiset.noncommProd.{u2} α _inst_1 s comm)) (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f (Multiset.noncommProd.{u2} α _inst_1 s comm)) (Multiset.noncommProd.{u1} β _inst_2 (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s) (Multiset.noncommProd_map_aux.{u1, u2, u3} F α β _inst_1 _inst_2 _inst_3 s comm f))
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_map Multiset.noncommProd_mapₓ'. -/
 @[to_additive]
 theorem noncommProd_map [MonoidHomClass F α β] (s : Multiset α) (comm) (f : F) :
     f (s.noncommProd comm) = (s.map f).noncommProd (noncommProd_map_aux s comm f) :=
@@ -285,12 +213,6 @@ theorem noncommProd_map [MonoidHomClass F α β] (s : Multiset α) (comm) (f : F
 #align multiset.noncomm_prod_map Multiset.noncommProd_map
 #align multiset.noncomm_sum_map Multiset.noncommSum_map
 
-/- warning: multiset.noncomm_prod_eq_pow_card -> Multiset.noncommProd_eq_pow_card is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x s)) (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))) (m : α), (forall (x : α), (Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x s) -> (Eq.{succ u1} α x m)) -> (Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 s comm) (HPow.hPow.{u1, 0, u1} α Nat α (instHPow.{u1, 0} α Nat (Monoid.Pow.{u1} α _inst_1)) m (coeFn.{succ u1, succ u1} (AddMonoidHom.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.orderedCancelAddCommMonoid.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (fun (_x : AddMonoidHom.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.orderedCancelAddCommMonoid.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) => (Multiset.{u1} α) -> Nat) (AddMonoidHom.hasCoeToFun.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.orderedCancelAddCommMonoid.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (Multiset.card.{u1} α) s)))
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x s)) (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))) (m : α), (forall (x : α), (Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x s) -> (Eq.{succ u1} α x m)) -> (Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 s comm) (HPow.hPow.{u1, 0, u1} α ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.403 : Multiset.{u1} α) => Nat) s) α (instHPow.{u1, 0} α ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.403 : Multiset.{u1} α) => Nat) s) (Monoid.Pow.{u1} α _inst_1)) m (FunLike.coe.{succ u1, succ u1, 1} (AddMonoidHom.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (Multiset.{u1} α) (fun (_x : Multiset.{u1} α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.403 : Multiset.{u1} α) => Nat) _x) (AddHomClass.toFunLike.{u1, u1, 0} (AddMonoidHom.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (Multiset.{u1} α) Nat (AddZeroClass.toAdd.{u1} (Multiset.{u1} α) (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α))))))) (AddZeroClass.toAdd.{0} Nat (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (AddMonoidHomClass.toAddHomClass.{u1, u1, 0} (AddMonoidHom.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid) (AddMonoidHom.addMonoidHomClass.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)))) (Multiset.card.{u1} α) s)))
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_eq_pow_card Multiset.noncommProd_eq_pow_cardₓ'. -/
 @[to_additive noncomm_sum_eq_card_nsmul]
 theorem noncommProd_eq_pow_card (s : Multiset α) (comm) (m : α) (h : ∀ x ∈ s, x = m) :
     s.noncommProd comm = m ^ s.card :=
@@ -312,12 +234,6 @@ theorem noncommProd_eq_prod {α : Type _} [CommMonoid α] (s : Multiset α) :
 #align multiset.noncomm_sum_eq_sum Multiset.noncommSum_eq_sum
 -/
 
-/- warning: multiset.noncomm_prod_commute -> Multiset.noncommProd_commute is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x s)) (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))) (y : α), (forall (x : α), (Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x s) -> (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)) y x)) -> (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)) y (Multiset.noncommProd.{u1} α _inst_1 s comm))
-but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x s)) (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))) (y : α), (forall (x : α), (Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x s) -> (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)) y x)) -> (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)) y (Multiset.noncommProd.{u1} α _inst_1 s comm))
-Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_commute Multiset.noncommProd_commuteₓ'. -/
 @[to_additive noncomm_sum_add_commute]
 theorem noncommProd_commute (s : Multiset α) (comm) (y : α) (h : ∀ x ∈ s, Commute y x) :
     Commute y (s.noncommProd comm) :=
@@ -334,12 +250,6 @@ namespace Finset
 
 variable [Monoid β] [Monoid γ]
 
-/- warning: finset.noncomm_prod -> Finset.noncommProd is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] (s : Finset.{u1} α) (f : α -> β), (Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))) -> β
-but is expected to have type
-  forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] (s : Finset.{u1} α) (f : α -> β), (Set.Pairwise.{u1} α (Finset.toSet.{u1} α s) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))) -> β
-Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod Finset.noncommProdₓ'. -/
 /-- Product of a `s : finset α` mapped with `f : α → β` with `[monoid β]`,
 given a proof that `*` commutes on all elements `f x` for `x ∈ s`. -/
 @[to_additive
@@ -351,9 +261,6 @@ def noncommProd (s : Finset α) (f : α → β)
 #align finset.noncomm_prod Finset.noncommProd
 #align finset.noncomm_sum Finset.noncommSum
 
-/- warning: finset.noncomm_prod_congr -> Finset.noncommProd_congr is a dubious translation:
-<too large>
-Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_congr Finset.noncommProd_congrₓ'. -/
 @[congr, to_additive]
 theorem noncommProd_congr {s₁ s₂ : Finset α} {f g : α → β} (h₁ : s₁ = s₂) (h₂ : ∀ x ∈ s₂, f x = g x)
     (comm) :
@@ -364,12 +271,6 @@ theorem noncommProd_congr {s₁ s₂ : Finset α} {f g : α → β} (h₁ : s₁
 #align finset.noncomm_prod_congr Finset.noncommProd_congr
 #align finset.noncomm_sum_congr Finset.noncommSum_congr
 
-/- warning: finset.noncomm_prod_to_finset -> Finset.noncommProd_toFinset is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] [_inst_3 : DecidableEq.{succ u1} α] (l : List.{u1} α) (f : α -> β) (comm : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (List.toFinset.{u1} α (fun (a : α) (b : α) => _inst_3 a b) l)) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))), (List.Nodup.{u1} α l) -> (Eq.{succ u2} β (Finset.noncommProd.{u1, u2} α β _inst_1 (List.toFinset.{u1} α (fun (a : α) (b : α) => _inst_3 a b) l) f comm) (List.prod.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (MulOneClass.toHasOne.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (List.map.{u1, u2} α β f l)))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] (l : List.{u2} α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (List.toFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b) l)) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), (List.Nodup.{u2} α l) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (List.toFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b) l) f comm) (List.prod.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (Monoid.toOne.{u1} β _inst_1) (List.map.{u2, u1} α β f l)))
-Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_to_finset Finset.noncommProd_toFinsetₓ'. -/
 @[simp, to_additive]
 theorem noncommProd_toFinset [DecidableEq α] (l : List α) (f : α → β) (comm) (hl : l.Nodup) :
     noncommProd l.toFinset f comm = (l.map f).Prod :=
@@ -379,24 +280,12 @@ theorem noncommProd_toFinset [DecidableEq α] (l : List α) (f : α → β) (com
 #align finset.noncomm_prod_to_finset Finset.noncommProd_toFinset
 #align finset.noncomm_sum_to_finset Finset.noncommSum_toFinset
 
-/- warning: finset.noncomm_prod_empty -> Finset.noncommProd_empty is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] (f : α -> β) (h : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (EmptyCollection.emptyCollection.{u1} (Finset.{u1} α) (Finset.hasEmptyc.{u1} α))) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))), Eq.{succ u2} β (Finset.noncommProd.{u1, u2} α β _inst_1 (EmptyCollection.emptyCollection.{u1} (Finset.{u1} α) (Finset.hasEmptyc.{u1} α)) f h) (OfNat.ofNat.{u2} β 1 (OfNat.mk.{u2} β 1 (One.one.{u2} β (MulOneClass.toHasOne.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)))))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] (f : α -> β) (h : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (EmptyCollection.emptyCollection.{u2} (Finset.{u2} α) (Finset.instEmptyCollectionFinset.{u2} α))) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (EmptyCollection.emptyCollection.{u2} (Finset.{u2} α) (Finset.instEmptyCollectionFinset.{u2} α)) f h) (OfNat.ofNat.{u1} β 1 (One.toOfNat1.{u1} β (Monoid.toOne.{u1} β _inst_1)))
-Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_empty Finset.noncommProd_emptyₓ'. -/
 @[simp, to_additive]
 theorem noncommProd_empty (f : α → β) (h) : noncommProd (∅ : Finset α) f h = 1 :=
   rfl
 #align finset.noncomm_prod_empty Finset.noncommProd_empty
 #align finset.noncomm_sum_empty Finset.noncommSum_empty
 
-/- warning: finset.noncomm_prod_insert_of_not_mem -> Finset.noncommProd_insert_of_not_mem is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] [_inst_3 : DecidableEq.{succ u1} α] (s : Finset.{u1} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))), (Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) -> (Eq.{succ u2} β (Finset.noncommProd.{u1, u2} α β _inst_1 (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u2, u2, u2} β β β (instHMul.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1))) (f a) (Finset.noncommProd.{u1, u2} α β _inst_1 s f (Set.Pairwise.mono.{u1} α (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (_x : α) => Finset.mem_insert_of_mem.{u1} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm))))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] (s : Finset.{u2} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), (Not (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) a s)) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (f a) (Finset.noncommProd.{u2, u1} α β _inst_1 s f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.2117 : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.2117 (Finset.val.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s))) (Finset.toSet.{u2} α s) (fun (_x : α) => Finset.mem_insert_of_mem.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm))))
-Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_insert_of_not_mem Finset.noncommProd_insert_of_not_memₓ'. -/
 @[simp, to_additive]
 theorem noncommProd_insert_of_not_mem [DecidableEq α] (s : Finset α) (a : α) (f : α → β) (comm)
     (ha : a ∉ s) :
@@ -406,12 +295,6 @@ theorem noncommProd_insert_of_not_mem [DecidableEq α] (s : Finset α) (a : α)
 #align finset.noncomm_prod_insert_of_not_mem Finset.noncommProd_insert_of_not_mem
 #align finset.noncomm_sum_insert_of_not_mem Finset.noncommSum_insert_of_not_mem
 
-/- warning: finset.noncomm_prod_insert_of_not_mem' -> Finset.noncommProd_insert_of_not_mem' is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] [_inst_3 : DecidableEq.{succ u1} α] (s : Finset.{u1} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))), (Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) -> (Eq.{succ u2} β (Finset.noncommProd.{u1, u2} α β _inst_1 (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u2, u2, u2} β β β (instHMul.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1))) (Finset.noncommProd.{u1, u2} α β _inst_1 s f (Set.Pairwise.mono.{u1} α (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (_x : α) => Finset.mem_insert_of_mem.{u1} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm)) (f a)))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] (s : Finset.{u2} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), (Not (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) a s)) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (Finset.noncommProd.{u2, u1} α β _inst_1 s f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.2350 : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.2350 (Finset.val.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s))) (Finset.toSet.{u2} α s) (fun (_x : α) => Finset.mem_insert_of_mem.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm)) (f a)))
-Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_insert_of_not_mem' Finset.noncommProd_insert_of_not_mem'ₓ'. -/
 @[to_additive]
 theorem noncommProd_insert_of_not_mem' [DecidableEq α] (s : Finset α) (a : α) (f : α → β) (comm)
     (ha : a ∉ s) :
@@ -430,9 +313,6 @@ theorem noncommProd_singleton (a : α) (f : α → β) :
 #align finset.noncomm_sum_singleton Finset.noncommSum_singleton
 -/
 
-/- warning: finset.noncomm_prod_map -> Finset.noncommProd_map is a dubious translation:
-<too large>
-Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_map Finset.noncommProd_mapₓ'. -/
 @[to_additive]
 theorem noncommProd_map [MonoidHomClass F β γ] (s : Finset α) (f : α → β) (comm) (g : F) :
     g (s.noncommProd f comm) =
@@ -441,12 +321,6 @@ theorem noncommProd_map [MonoidHomClass F β γ] (s : Finset α) (f : α → β)
 #align finset.noncomm_prod_map Finset.noncommProd_map
 #align finset.noncomm_sum_map Finset.noncommSum_map
 
-/- warning: finset.noncomm_prod_eq_pow_card -> Finset.noncommProd_eq_pow_card is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] (s : Finset.{u1} α) (f : α -> β) (comm : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))) (m : β), (forall (x : α), (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) x s) -> (Eq.{succ u2} β (f x) m)) -> (Eq.{succ u2} β (Finset.noncommProd.{u1, u2} α β _inst_1 s f comm) (HPow.hPow.{u2, 0, u2} β Nat β (instHPow.{u2, 0} β Nat (Monoid.Pow.{u2} β _inst_1)) m (Finset.card.{u1} α s)))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] (s : Finset.{u2} α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α s) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))) (m : β), (forall (x : α), (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) x s) -> (Eq.{succ u1} β (f x) m)) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 s f comm) (HPow.hPow.{u1, 0, u1} β Nat β (instHPow.{u1, 0} β Nat (Monoid.Pow.{u1} β _inst_1)) m (Finset.card.{u2} α s)))
-Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_eq_pow_card Finset.noncommProd_eq_pow_cardₓ'. -/
 @[to_additive noncomm_sum_eq_card_nsmul]
 theorem noncommProd_eq_pow_card (s : Finset α) (f : α → β) (comm) (m : β) (h : ∀ x ∈ s, f x = m) :
     s.noncommProd f comm = m ^ s.card :=
@@ -457,12 +331,6 @@ theorem noncommProd_eq_pow_card (s : Finset α) (f : α → β) (comm) (m : β)
 #align finset.noncomm_prod_eq_pow_card Finset.noncommProd_eq_pow_card
 #align finset.noncomm_sum_eq_card_nsmul Finset.noncommSum_eq_card_nsmul
 
-/- warning: finset.noncomm_prod_commute -> Finset.noncommProd_commute is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] (s : Finset.{u1} α) (f : α -> β) (comm : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))) (y : β), (forall (x : α), (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) x s) -> (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) y (f x))) -> (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) y (Finset.noncommProd.{u1, u2} α β _inst_1 s f comm))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] (s : Finset.{u2} α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α s) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))) (y : β), (forall (x : α), (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) x s) -> (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) y (f x))) -> (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) y (Finset.noncommProd.{u2, u1} α β _inst_1 s f comm))
-Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_commute Finset.noncommProd_commuteₓ'. -/
 @[to_additive noncomm_sum_add_commute]
 theorem noncommProd_commute (s : Finset α) (f : α → β) (comm) (y : β)
     (h : ∀ x ∈ s, Commute y (f x)) : Commute y (s.noncommProd f comm) :=
@@ -487,12 +355,6 @@ theorem noncommProd_eq_prod {β : Type _} [CommMonoid β] (s : Finset α) (f : 
 #align finset.noncomm_sum_eq_sum Finset.noncommSum_eq_sum
 -/
 
-/- warning: finset.noncomm_prod_union_of_disjoint -> Finset.noncommProd_union_of_disjoint is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] [_inst_3 : DecidableEq.{succ u1} α] {s : Finset.{u1} α} {t : Finset.{u1} α}, (Disjoint.{u1} (Finset.{u1} α) (Finset.partialOrder.{u1} α) (Finset.orderBot.{u1} α) s t) -> (forall (f : α -> β) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) x (Union.union.{u1} (Finset.{u1} α) (Finset.hasUnion.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) s t))) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))), Eq.{succ u2} β (Finset.noncommProd.{u1, u2} α β _inst_1 (Union.union.{u1} (Finset.{u1} α) (Finset.hasUnion.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) s t) f comm) (HMul.hMul.{u2, u2, u2} β β β (instHMul.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1))) (Finset.noncommProd.{u1, u2} α β _inst_1 s f (Set.Pairwise.mono.{u1} α (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b)) (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) x (Union.union.{u1} (Finset.{u1} α) (Finset.hasUnion.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) s t))) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (Iff.mpr (HasSubset.Subset.{u1} (Set.{u1} α) (Set.hasSubset.{u1} α) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Union.union.{u1} (Finset.{u1} α) (Finset.hasUnion.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) s t))) (HasSubset.Subset.{u1} (Finset.{u1} α) (Finset.hasSubset.{u1} α) s (Union.union.{u1} (Finset.{u1} α) (Finset.hasUnion.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) s t)) (Finset.coe_subset.{u1} α s (Union.union.{u1} (Finset.{u1} α) (Finset.hasUnion.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) s t)) (Finset.subset_union_left.{u1} α (fun (a : α) (b : α) => _inst_3 a b) s t)) comm)) (Finset.noncommProd.{u1, u2} α β _inst_1 t f (Set.Pairwise.mono.{u1} α (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b)) (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) x (Union.union.{u1} (Finset.{u1} α) (Finset.hasUnion.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) s t))) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) t) (Iff.mpr (HasSubset.Subset.{u1} (Set.{u1} α) (Set.hasSubset.{u1} α) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) t) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Union.union.{u1} (Finset.{u1} α) (Finset.hasUnion.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) s t))) (HasSubset.Subset.{u1} (Finset.{u1} α) (Finset.hasSubset.{u1} α) t (Union.union.{u1} (Finset.{u1} α) (Finset.hasUnion.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) s t)) (Finset.coe_subset.{u1} α t (Union.union.{u1} (Finset.{u1} α) (Finset.hasUnion.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) s t)) (Finset.subset_union_right.{u1} α (fun (a : α) (b : α) => _inst_3 a b) s t)) comm))))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] {s : Finset.{u2} α} {t : Finset.{u2} α}, (Disjoint.{u2} (Finset.{u2} α) (Finset.partialOrder.{u2} α) (Finset.instOrderBotFinsetToLEToPreorderPartialOrder.{u2} α) s t) -> (forall (f : α -> β) (comm : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) x (Union.union.{u2} (Finset.{u2} α) (Finset.instUnionFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) s t))) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (Union.union.{u2} (Finset.{u2} α) (Finset.instUnionFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) s t) f comm) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (Finset.noncommProd.{u2, u1} α β _inst_1 s f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (Finset.toSet.{u2} α (Union.union.{u2} (Finset.{u2} α) (Finset.instUnionFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) s t)) (Finset.toSet.{u2} α s) (Iff.mpr (HasSubset.Subset.{u2} (Set.{u2} α) (Set.instHasSubsetSet.{u2} α) (Finset.toSet.{u2} α s) (Finset.toSet.{u2} α (Union.union.{u2} (Finset.{u2} α) (Finset.instUnionFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) s t))) (HasSubset.Subset.{u2} (Finset.{u2} α) (Finset.instHasSubsetFinset.{u2} α) s (Union.union.{u2} (Finset.{u2} α) (Finset.instUnionFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) s t)) (Finset.coe_subset.{u2} α s (Union.union.{u2} (Finset.{u2} α) (Finset.instUnionFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) s t)) (Finset.subset_union_left.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s t)) comm)) (Finset.noncommProd.{u2, u1} α β _inst_1 t f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (Finset.toSet.{u2} α (Union.union.{u2} (Finset.{u2} α) (Finset.instUnionFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) s t)) (Finset.toSet.{u2} α t) (Iff.mpr (HasSubset.Subset.{u2} (Set.{u2} α) (Set.instHasSubsetSet.{u2} α) (Finset.toSet.{u2} α t) (Finset.toSet.{u2} α (Union.union.{u2} (Finset.{u2} α) (Finset.instUnionFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) s t))) (HasSubset.Subset.{u2} (Finset.{u2} α) (Finset.instHasSubsetFinset.{u2} α) t (Union.union.{u2} (Finset.{u2} α) (Finset.instUnionFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) s t)) (Finset.coe_subset.{u2} α t (Union.union.{u2} (Finset.{u2} α) (Finset.instUnionFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) s t)) (Finset.subset_union_right.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s t)) comm))))
-Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_union_of_disjoint Finset.noncommProd_union_of_disjointₓ'. -/
 /-- The non-commutative version of `finset.prod_union` -/
 @[to_additive "The non-commutative version of `finset.sum_union`"]
 theorem noncommProd_union_of_disjoint [DecidableEq α] {s t : Finset α} (h : Disjoint s t)
@@ -509,12 +371,6 @@ theorem noncommProd_union_of_disjoint [DecidableEq α] {s t : Finset α} (h : Di
 #align finset.noncomm_prod_union_of_disjoint Finset.noncommProd_union_of_disjoint
 #align finset.noncomm_sum_union_of_disjoint Finset.noncommSum_union_of_disjoint
 
-/- warning: finset.noncomm_prod_mul_distrib_aux -> Finset.noncommProd_mul_distrib_aux is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] {s : Finset.{u1} α} {f : α -> β} {g : α -> β}, (Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (x : α) (y : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f x) (f y))) -> (Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (x : α) (y : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (g x) (g y))) -> (Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (x : α) (y : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (g x) (f y))) -> (Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (x : α) (y : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (α -> β) (α -> β) (α -> β) (instHMul.{max u1 u2} (α -> β) (Pi.instMul.{u1, u2} α (fun (ᾰ : α) => β) (fun (i : α) => MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)))) f g x) (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (α -> β) (α -> β) (α -> β) (instHMul.{max u1 u2} (α -> β) (Pi.instMul.{u1, u2} α (fun (ᾰ : α) => β) (fun (i : α) => MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)))) f g y)))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] {s : Finset.{u2} α} {f : α -> β} {g : α -> β}, (Set.Pairwise.{u2} α (Finset.toSet.{u2} α s) (fun (x : α) (y : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f x) (f y))) -> (Set.Pairwise.{u2} α (Finset.toSet.{u2} α s) (fun (x : α) (y : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (g x) (g y))) -> (Set.Pairwise.{u2} α (Finset.toSet.{u2} α s) (fun (x : α) (y : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (g x) (f y))) -> (Set.Pairwise.{u2} α (Finset.toSet.{u2} α s) (fun (x : α) (y : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (HMul.hMul.{max u2 u1, max u2 u1, max u2 u1} (α -> β) (α -> β) (α -> β) (instHMul.{max u2 u1} (α -> β) (Pi.instMul.{u2, u1} α (fun (ᾰ : α) => β) (fun (i : α) => MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)))) f g x) (HMul.hMul.{max u2 u1, max u2 u1, max u2 u1} (α -> β) (α -> β) (α -> β) (instHMul.{max u2 u1} (α -> β) (Pi.instMul.{u2, u1} α (fun (ᾰ : α) => β) (fun (i : α) => MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)))) f g y)))
-Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_mul_distrib_aux Finset.noncommProd_mul_distrib_auxₓ'. -/
 @[protected, to_additive]
 theorem noncommProd_mul_distrib_aux {s : Finset α} {f : α → β} {g : α → β}
     (comm_ff : (s : Set α).Pairwise fun x y => Commute (f x) (f y))
@@ -531,12 +387,6 @@ theorem noncommProd_mul_distrib_aux {s : Finset α} {f : α → β} {g : α →
 #align finset.noncomm_prod_mul_distrib_aux Finset.noncommProd_mul_distrib_aux
 #align finset.noncomm_sum_add_distrib_aux Finset.noncommSum_add_distrib_aux
 
-/- warning: finset.noncomm_prod_mul_distrib -> Finset.noncommProd_mul_distrib is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] {s : Finset.{u1} α} (f : α -> β) (g : α -> β) (comm_ff : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (x : α) (y : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f x) (f y))) (comm_gg : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (x : α) (y : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (g x) (g y))) (comm_gf : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (x : α) (y : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (g x) (f y))), Eq.{succ u2} β (Finset.noncommProd.{u1, u2} α β _inst_1 s (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (α -> β) (α -> β) (α -> β) (instHMul.{max u1 u2} (α -> β) (Pi.instMul.{u1, u2} α (fun (ᾰ : α) => β) (fun (i : α) => MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)))) f g) (Finset.noncommProd_mul_distrib_aux.{u1, u2} α β _inst_1 s f g comm_ff comm_gg comm_gf)) (HMul.hMul.{u2, u2, u2} β β β (instHMul.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1))) (Finset.noncommProd.{u1, u2} α β _inst_1 s f comm_ff) (Finset.noncommProd.{u1, u2} α β _inst_1 s g comm_gg))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] {s : Finset.{u2} α} (f : α -> β) (g : α -> β) (comm_ff : Set.Pairwise.{u2} α (Finset.toSet.{u2} α s) (fun (x : α) (y : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f x) (f y))) (comm_gg : Set.Pairwise.{u2} α (Finset.toSet.{u2} α s) (fun (x : α) (y : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (g x) (g y))) (comm_gf : Set.Pairwise.{u2} α (Finset.toSet.{u2} α s) (fun (x : α) (y : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (g x) (f y))), Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 s (HMul.hMul.{max u2 u1, max u2 u1, max u2 u1} (α -> β) (α -> β) (α -> β) (instHMul.{max u2 u1} (α -> β) (Pi.instMul.{u2, u1} α (fun (ᾰ : α) => β) (fun (i : α) => MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)))) f g) (Finset.noncommProd_mul_distrib_aux.{u1, u2} α β _inst_1 s f g comm_ff comm_gg comm_gf)) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (Finset.noncommProd.{u2, u1} α β _inst_1 s f comm_ff) (Finset.noncommProd.{u2, u1} α β _inst_1 s g comm_gg))
-Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_mul_distrib Finset.noncommProd_mul_distribₓ'. -/
 /-- The non-commutative version of `finset.prod_mul_distrib` -/
 @[to_additive "The non-commutative version of `finset.sum_add_distrib`"]
 theorem noncommProd_mul_distrib {s : Finset α} (f : α → β) (g : α → β) (comm_ff comm_gg comm_gf) :
@@ -564,12 +414,6 @@ section FinitePi
 
 variable {M : ι → Type _} [∀ i, Monoid (M i)]
 
-/- warning: finset.noncomm_prod_mul_single -> Finset.noncommProd_mul_single is a dubious translation:
-lean 3 declaration is
-  forall {ι : Type.{u1}} {M : ι -> Type.{u2}} [_inst_3 : forall (i : ι), Monoid.{u2} (M i)] [_inst_4 : Fintype.{u1} ι] [_inst_5 : DecidableEq.{succ u1} ι] (x : forall (i : ι), M i), Eq.{succ (max u1 u2)} (forall (i : ι), M i) (Finset.noncommProd.{u1, max u1 u2} ι (forall (i : ι), M i) (Pi.monoid.{u1, u2} ι (fun (i : ι) => M i) (fun (i : ι) => _inst_3 i)) (Finset.univ.{u1} ι _inst_4) (fun (i : ι) => Pi.mulSingle.{u1, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => MulOneClass.toHasOne.{u2} (M i) (Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) i (x i)) (fun (i : ι) (_x : Membership.Mem.{u1, u1} ι (Set.{u1} ι) (Set.hasMem.{u1} ι) i ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} ι) (Set.{u1} ι) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} ι) (Set.{u1} ι) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} ι) (Set.{u1} ι) (Finset.Set.hasCoeT.{u1} ι))) (Finset.univ.{u1} ι _inst_4))) (j : ι) (_x : Membership.Mem.{u1, u1} ι (Set.{u1} ι) (Set.hasMem.{u1} ι) j ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} ι) (Set.{u1} ι) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} ι) (Set.{u1} ι) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} ι) (Set.{u1} ι) (Finset.Set.hasCoeT.{u1} ι))) (Finset.univ.{u1} ι _inst_4))) (_x : Ne.{succ u1} ι i j) => Pi.mulSingle_apply_commute.{u1, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)) x i j)) x
-but is expected to have type
-  forall {ι : Type.{u2}} {M : ι -> Type.{u1}} [_inst_3 : forall (i : ι), Monoid.{u1} (M i)] [_inst_4 : Fintype.{u2} ι] [_inst_5 : DecidableEq.{succ u2} ι] (x : forall (i : ι), M i), Eq.{max (succ u2) (succ u1)} (forall (i : ι), M i) (Finset.noncommProd.{u2, max u1 u2} ι (forall (i : ι), M i) (Pi.monoid.{u2, u1} ι (fun (i : ι) => M i) (fun (i : ι) => _inst_3 i)) (Finset.univ.{u2} ι _inst_4) (fun (i : ι) => Pi.mulSingle.{u2, u1} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u1} (M i) (_inst_3 i)) i (x i)) (fun (i : ι) (_x : Membership.mem.{u2, u2} ι (Set.{u2} ι) (Set.instMembershipSet.{u2} ι) i (Finset.toSet.{u2} ι (Finset.univ.{u2} ι _inst_4))) (j : ι) (_x : Membership.mem.{u2, u2} ι (Set.{u2} ι) (Set.instMembershipSet.{u2} ι) j (Finset.toSet.{u2} ι (Finset.univ.{u2} ι _inst_4))) (_x : Ne.{succ u2} ι i j) => Pi.mulSingle_apply_commute.{u2, u1} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toMulOneClass.{u1} (M i) (_inst_3 i)) x i j)) x
-Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_mul_single Finset.noncommProd_mul_singleₓ'. -/
 @[to_additive]
 theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
     (univ.noncommProd (fun i => Pi.mulSingle i (x i)) fun i _ j _ _ =>
@@ -585,9 +429,6 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
 #align finset.noncomm_prod_mul_single Finset.noncommProd_mul_single
 #align finset.noncomm_sum_single Finset.noncommSum_single
 
-/- warning: monoid_hom.pi_ext -> MonoidHom.pi_ext is a dubious translation:
-<too large>
-Case conversion may be inaccurate. Consider using '#align monoid_hom.pi_ext MonoidHom.pi_extₓ'. -/
 @[to_additive]
 theorem MonoidHom.pi_ext [Finite ι] [DecidableEq ι] {f g : (∀ i, M i) →* γ}
     (h : ∀ i x, f (Pi.mulSingle i x) = g (Pi.mulSingle i x)) : f = g :=
Diff
@@ -209,10 +209,8 @@ but is expected to have type
 Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_cons Multiset.noncommProd_consₓ'. -/
 @[simp, to_additive]
 theorem noncommProd_cons (s : Multiset α) (a : α) (comm) :
-    noncommProd (a ::ₘ s) comm = a * noncommProd s (comm.mono fun _ => mem_cons_of_mem) :=
-  by
-  induction s using Quotient.inductionOn
-  simp
+    noncommProd (a ::ₘ s) comm = a * noncommProd s (comm.mono fun _ => mem_cons_of_mem) := by
+  induction s using Quotient.inductionOn; simp
 #align multiset.noncomm_prod_cons Multiset.noncommProd_cons
 #align multiset.noncomm_sum_cons Multiset.noncommSum_cons
 
@@ -252,10 +250,7 @@ theorem noncommProd_add (s t : Multiset α) (comm) :
     noncommProd (s + t) comm =
       noncommProd s (comm.mono <| subset_of_le <| s.le_add_right t) *
         noncommProd t (comm.mono <| subset_of_le <| t.le_add_left s) :=
-  by
-  rcases s with ⟨⟩
-  rcases t with ⟨⟩
-  simp
+  by rcases s with ⟨⟩; rcases t with ⟨⟩; simp
 #align multiset.noncomm_prod_add Multiset.noncommProd_add
 #align multiset.noncomm_sum_add Multiset.noncommSum_add
 
@@ -351,9 +346,7 @@ given a proof that `*` commutes on all elements `f x` for `x ∈ s`. -/
       "Sum of a `s : finset α` mapped with `f : α → β` with `[add_monoid β]`,\ngiven a proof that `+` commutes on all elements `f x` for `x ∈ s`."]
 def noncommProd (s : Finset α) (f : α → β)
     (comm : (s : Set α).Pairwise fun a b => Commute (f a) (f b)) : β :=
-  (s.1.map f).noncommProd <| by
-    simp_rw [Multiset.mem_map]
-    rintro _ ⟨a, ha, rfl⟩ _ ⟨b, hb, rfl⟩ _
+  (s.1.map f).noncommProd <| by simp_rw [Multiset.mem_map]; rintro _ ⟨a, ha, rfl⟩ _ ⟨b, hb, rfl⟩ _;
     exact comm.of_refl ha hb
 #align finset.noncomm_prod Finset.noncommProd
 #align finset.noncomm_sum Finset.noncommSum
@@ -365,10 +358,7 @@ Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_co
 theorem noncommProd_congr {s₁ s₂ : Finset α} {f g : α → β} (h₁ : s₁ = s₂) (h₂ : ∀ x ∈ s₂, f x = g x)
     (comm) :
     noncommProd s₁ f comm =
-      noncommProd s₂ g fun x hx y hy h =>
-        by
-        rw [← h₂ _ hx, ← h₂ _ hy]
-        subst h₁
+      noncommProd s₂ g fun x hx y hy h => by rw [← h₂ _ hx, ← h₂ _ hy]; subst h₁;
         exact comm hx hy h :=
   by simp_rw [noncomm_prod, Multiset.map_congr (congr_arg _ h₁) h₂]
 #align finset.noncomm_prod_congr Finset.noncommProd_congr
@@ -434,12 +424,8 @@ theorem noncommProd_insert_of_not_mem' [DecidableEq α] (s : Finset α) (a : α)
 #print Finset.noncommProd_singleton /-
 @[simp, to_additive]
 theorem noncommProd_singleton (a : α) (f : α → β) :
-    noncommProd ({a} : Finset α) f
-        (by
-          norm_cast
-          exact Set.pairwise_singleton _ _) =
-      f a :=
-  by simp [noncomm_prod, ← Multiset.cons_zero]
+    noncommProd ({a} : Finset α) f (by norm_cast; exact Set.pairwise_singleton _ _) = f a := by
+  simp [noncomm_prod, ← Multiset.cons_zero]
 #align finset.noncomm_prod_singleton Finset.noncommProd_singleton
 #align finset.noncomm_sum_singleton Finset.noncommSum_singleton
 -/
@@ -595,9 +581,7 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
   rw [← insert_erase (mem_univ i), noncomm_prod_insert_of_not_mem' _ _ _ _ (not_mem_erase _ _),
     noncomm_prod_eq_pow_card, one_pow]
   · simp
-  · intro i h
-    simp at h
-    simp [h]
+  · intro i h; simp at h; simp [h]
 #align finset.noncomm_prod_mul_single Finset.noncommProd_mul_single
 #align finset.noncomm_sum_single Finset.noncommSum_single
 
Diff
@@ -359,10 +359,7 @@ def noncommProd (s : Finset α) (f : α → β)
 #align finset.noncomm_sum Finset.noncommSum
 
 /- warning: finset.noncomm_prod_congr -> Finset.noncommProd_congr is a dubious translation:
-lean 3 declaration is
-  forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] {s₁ : Finset.{u1} α} {s₂ : Finset.{u1} α} {f : α -> β} {g : α -> β} (h₁ : Eq.{succ u1} (Finset.{u1} α) s₁ s₂) (h₂ : forall (x : α), (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) x s₂) -> (Eq.{succ u2} β (f x) (g x))) (comm : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s₁) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))), Eq.{succ u2} β (Finset.noncommProd.{u1, u2} α β _inst_1 s₁ f comm) (Finset.noncommProd.{u1, u2} α β _inst_1 s₂ g (fun (x : α) (hx : Membership.Mem.{u1, u1} α (Set.{u1} α) (Set.hasMem.{u1} α) x ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s₂)) (y : α) (hy : Membership.Mem.{u1, u1} α (Set.{u1} α) (Set.hasMem.{u1} α) y ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s₂)) (h : Ne.{succ u1} α x y) => Eq.mpr.{0} (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (g x) (g y)) (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f x) (g y)) (id_tag Tactic.IdTag.rw (Eq.{1} Prop (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (g x) (g y)) (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f x) (g y))) (Eq.ndrec.{0, succ u2} β (g x) (fun (_a : β) => Eq.{1} Prop (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (g x) (g y)) (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) _a (g y))) (rfl.{1} Prop (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (g x) (g y))) (f x) (Eq.symm.{succ u2} β (f x) (g x) (h₂ x hx)))) (Eq.mpr.{0} (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f x) (g y)) (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f x) (f y)) (id_tag Tactic.IdTag.rw (Eq.{1} Prop (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f x) (g y)) (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f x) (f y))) (Eq.ndrec.{0, succ u2} β (g y) (fun (_a : β) => Eq.{1} Prop (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f x) (g y)) (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f x) _a)) (rfl.{1} Prop (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f x) (g y))) (f y) (Eq.symm.{succ u2} β (f y) (g y) (h₂ y hy)))) (Eq.ndrec.{0, succ u1} (Finset.{u1} α) s₁ (fun {s₂ : Finset.{u1} α} => (forall (x : α), (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) x s₂) -> (Eq.{succ u2} β (f x) (g x))) -> (Membership.Mem.{u1, u1} α (Set.{u1} α) (Set.hasMem.{u1} α) x ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s₂)) -> (Membership.Mem.{u1, u1} α (Set.{u1} α) (Set.hasMem.{u1} α) y ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s₂)) -> (Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f x) (f y))) (fun (h₂ : forall (x : α), (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) x s₁) -> (Eq.{succ u2} β (f x) (g x))) (hx : Membership.Mem.{u1, u1} α (Set.{u1} α) (Set.hasMem.{u1} α) x ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s₁)) (hy : Membership.Mem.{u1, u1} α (Set.{u1} α) (Set.hasMem.{u1} α) y ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s₁)) => comm x hx y hy h) s₂ h₁ h₂ hx hy))))
-but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] {s₁ : Finset.{u2} α} {s₂ : Finset.{u2} α} {f : α -> β} {g : α -> β} (h₁ : Eq.{succ u2} (Finset.{u2} α) s₁ s₂) (h₂ : forall (x : α), (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) x s₂) -> (Eq.{succ u1} β (f x) (g x))) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α s₁) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 s₁ f comm) (Finset.noncommProd.{u2, u1} α β _inst_1 s₂ g (fun (x : α) (hx : Membership.mem.{u2, u2} α (Set.{u2} α) (Set.instMembershipSet.{u2} α) x (Finset.toSet.{u2} α s₂)) (y : α) (hy : Membership.mem.{u2, u2} α (Set.{u2} α) (Set.instMembershipSet.{u2} α) y (Finset.toSet.{u2} α s₂)) (h : Ne.{succ u2} α x y) => id.{0} ((fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (g a) (g b)) x y) (Eq.mpr.{0} (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (g x) (g y)) (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f x) (g y)) (id.{0} (Eq.{1} Prop (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (g x) (g y)) (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f x) (g y))) (Eq.ndrec.{0, succ u1} β (g x) (fun (_a : β) => Eq.{1} Prop (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (g x) (g y)) (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) _a (g y))) (Eq.refl.{1} Prop (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (g x) (g y))) (f x) (Eq.symm.{succ u1} β (f x) (g x) (h₂ x hx)))) (Eq.mpr.{0} (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f x) (g y)) (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f x) (f y)) (id.{0} (Eq.{1} Prop (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f x) (g y)) (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f x) (f y))) (Eq.ndrec.{0, succ u1} β (g y) (fun (_a : β) => Eq.{1} Prop (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f x) (g y)) (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f x) _a)) (Eq.refl.{1} Prop (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f x) (g y))) (f y) (Eq.symm.{succ u1} β (f y) (g y) (h₂ y hy)))) (Eq.ndrec.{0, succ u2} (Finset.{u2} α) s₁ (fun {s₂ : Finset.{u2} α} => (forall (x : α), (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) x s₂) -> (Eq.{succ u1} β (f x) (g x))) -> (Membership.mem.{u2, u2} α (Set.{u2} α) (Set.instMembershipSet.{u2} α) x (Finset.toSet.{u2} α s₂)) -> (Membership.mem.{u2, u2} α (Set.{u2} α) (Set.instMembershipSet.{u2} α) y (Finset.toSet.{u2} α s₂)) -> (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f x) (f y))) (fun (h₂ : forall (x : α), (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) x s₁) -> (Eq.{succ u1} β (f x) (g x))) (hx : Membership.mem.{u2, u2} α (Set.{u2} α) (Set.instMembershipSet.{u2} α) x (Finset.toSet.{u2} α s₁)) (hy : Membership.mem.{u2, u2} α (Set.{u2} α) (Set.instMembershipSet.{u2} α) y (Finset.toSet.{u2} α s₁)) => comm x hx y hy h) s₂ h₁ h₂ hx hy)))))
+<too large>
 Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_congr Finset.noncommProd_congrₓ'. -/
 @[congr, to_additive]
 theorem noncommProd_congr {s₁ s₂ : Finset α} {f g : α → β} (h₁ : s₁ = s₂) (h₂ : ∀ x ∈ s₂, f x = g x)
@@ -448,10 +445,7 @@ theorem noncommProd_singleton (a : α) (f : α → β) :
 -/
 
 /- warning: finset.noncomm_prod_map -> Finset.noncommProd_map is a dubious translation:
-lean 3 declaration is
-  forall {F : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} {γ : Type.{u4}} [_inst_1 : Monoid.{u3} β] [_inst_2 : Monoid.{u4} γ] [_inst_3 : MonoidHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2)] (s : Finset.{u2} α) (f : α -> β) (comm : Set.Pairwise.{u2} α ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s) (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b))) (g : F), Eq.{succ u4} γ (coeFn.{succ u1, max (succ u3) (succ u4)} F (fun (_x : F) => β -> γ) (FunLike.hasCoeToFun.{succ u1, succ u3, succ u4} F β (fun (_x : β) => γ) (MulHomClass.toFunLike.{u1, u3, u4} F β γ (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toHasMul.{u4} γ (Monoid.toMulOneClass.{u4} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2) _inst_3))) g (Finset.noncommProd.{u2, u3} α β _inst_1 s f comm)) (Finset.noncommProd.{u2, u4} α γ _inst_2 s (fun (i : α) => coeFn.{succ u1, max (succ u3) (succ u4)} F (fun (_x : F) => β -> γ) (FunLike.hasCoeToFun.{succ u1, succ u3, succ u4} F β (fun (_x : β) => γ) (MulHomClass.toFunLike.{u1, u3, u4} F β γ (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toHasMul.{u4} γ (Monoid.toMulOneClass.{u4} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2) _inst_3))) g (f i)) (fun (x : α) (hx : Membership.Mem.{u2, u2} α (Set.{u2} α) (Set.hasMem.{u2} α) x ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s)) (y : α) (hy : Membership.Mem.{u2, u2} α (Set.{u2} α) (Set.hasMem.{u2} α) y ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s)) (h : Ne.{succ u2} α x y) => Commute.map.{u1, u3, u4} F β γ (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toHasMul.{u4} γ (Monoid.toMulOneClass.{u4} γ _inst_2)) (f x) (f y) (MonoidHomClass.toMulHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2) _inst_3) (Set.Pairwise.of_refl.{u2} α (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b)) ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s) (Commute.on_isRefl.{u2, u3} α β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (fun (a : α) => f a)) comm x hx y hy) g))
-but is expected to have type
-  forall {F : Type.{u4}} {α : Type.{u1}} {β : Type.{u3}} {γ : Type.{u2}} [_inst_1 : Monoid.{u3} β] [_inst_2 : Monoid.{u2} γ] [_inst_3 : MonoidHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2)] (s : Finset.{u1} α) (f : α -> β) (comm : Set.Pairwise.{u1} α (Finset.toSet.{u1} α s) (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b))) (g : F), Eq.{succ u2} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : β) => γ) (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (Finset.noncommProd.{u1, u2} α γ _inst_2 s (fun (i : α) => FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (f i)) (fun (x : α) (hx : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) x (Finset.toSet.{u1} α s)) (y : α) (hy : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) y (Finset.toSet.{u1} α s)) (h : Ne.{succ u1} α x y) => Commute.map.{u2, u3, u4} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (f x) (f y) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3) (Set.Pairwise.of_refl.{u1} α (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b)) (Finset.toSet.{u1} α s) (Commute.on_isRefl.{u1, u3} α β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (fun (a : α) => f a)) comm x hx y hy) g))
+<too large>
 Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_map Finset.noncommProd_mapₓ'. -/
 @[to_additive]
 theorem noncommProd_map [MonoidHomClass F β γ] (s : Finset α) (f : α → β) (comm) (g : F) :
@@ -608,10 +602,7 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
 #align finset.noncomm_sum_single Finset.noncommSum_single
 
 /- warning: monoid_hom.pi_ext -> MonoidHom.pi_ext is a dubious translation:
-lean 3 declaration is
-  forall {ι : Type.{u1}} {γ : Type.{u2}} [_inst_2 : Monoid.{u2} γ] {M : ι -> Type.{u3}} [_inst_3 : forall (i : ι), Monoid.{u3} (M i)] [_inst_4 : Finite.{succ u1} ι] [_inst_5 : DecidableEq.{succ u1} ι] {f : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)} {g : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)}, (forall (i : ι) (x : M i), Eq.{succ u2} γ (coeFn.{max (succ u2) (succ (max u1 u3)), max (succ (max u1 u3)) (succ u2)} (MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) (fun (_x : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) => (forall (i : ι), M i) -> γ) (MonoidHom.hasCoeToFun.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) f (Pi.mulSingle.{u1, u3} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => MulOneClass.toHasOne.{u3} (M i) (Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) i x)) (coeFn.{max (succ u2) (succ (max u1 u3)), max (succ (max u1 u3)) (succ u2)} (MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) (fun (_x : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) => (forall (i : ι), M i) -> γ) (MonoidHom.hasCoeToFun.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) g (Pi.mulSingle.{u1, u3} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => MulOneClass.toHasOne.{u3} (M i) (Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) i x))) -> (Eq.{max (succ u2) (succ (max u1 u3))} (MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) f g)
-but is expected to have type
-  forall {ι : Type.{u3}} {γ : Type.{u1}} [_inst_2 : Monoid.{u1} γ] {M : ι -> Type.{u2}} [_inst_3 : forall (i : ι), Monoid.{u2} (M i)] [_inst_4 : Finite.{succ u3} ι] [_inst_5 : DecidableEq.{succ u3} ι] {f : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)} {g : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)}, (forall (i : ι) (x : M i), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : forall (i : ι), M i) => γ) (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) f (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) g (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x))) -> (Eq.{max (max (succ u3) (succ u1)) (succ u2)} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) f g)
+<too large>
 Case conversion may be inaccurate. Consider using '#align monoid_hom.pi_ext MonoidHom.pi_extₓ'. -/
 @[to_additive]
 theorem MonoidHom.pi_ext [Finite ι] [DecidableEq ι] {f g : (∀ i, M i) →* γ}
Diff
@@ -263,7 +263,7 @@ theorem noncommProd_add (s t : Multiset α) (comm) :
 lean 3 declaration is
   forall {F : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u3} β] [_inst_3 : MonoidHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2)] (s : Multiset.{u2} α), (Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.Mem.{u2, u2} α (Multiset.{u2} α) (Multiset.hasMem.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) -> (forall (f : F), Set.Pairwise.{u3} β (setOf.{u3} β (fun (x : β) => Membership.Mem.{u3, u3} β (Multiset.{u3} β) (Multiset.hasMem.{u3} β) x (Multiset.map.{u2, u3} α β (coeFn.{succ u1, max (succ u2) (succ u3)} F (fun (_x : F) => α -> β) (FunLike.hasCoeToFun.{succ u1, succ u2, succ u3} F α (fun (_x : α) => β) (MulHomClass.toFunLike.{u1, u2, u3} F α β (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2) _inst_3))) f) s))) (Commute.{u3} β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2))))
 but is expected to have type
-  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α), (Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) -> (forall (f : F), Set.Pairwise.{u1} β (setOf.{u1} β (fun (x : β) => Membership.mem.{u1, u1} β (Multiset.{u1} β) (Multiset.instMembershipMultiset.{u1} β) x (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s))) (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2))))
+  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α), (Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) -> (forall (f : F), Set.Pairwise.{u1} β (setOf.{u1} β (fun (x : β) => Membership.mem.{u1, u1} β (Multiset.{u1} β) (Multiset.instMembershipMultiset.{u1} β) x (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s))) (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2))))
 Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_map_aux Multiset.noncommProd_map_auxₓ'. -/
 @[protected, to_additive]
 theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
@@ -279,7 +279,7 @@ theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
 lean 3 declaration is
   forall {F : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u3} β] [_inst_3 : MonoidHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2)] (s : Multiset.{u2} α) (comm : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.Mem.{u2, u2} α (Multiset.{u2} α) (Multiset.hasMem.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) (f : F), Eq.{succ u3} β (coeFn.{succ u1, max (succ u2) (succ u3)} F (fun (_x : F) => α -> β) (FunLike.hasCoeToFun.{succ u1, succ u2, succ u3} F α (fun (_x : α) => β) (MulHomClass.toFunLike.{u1, u2, u3} F α β (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2) _inst_3))) f (Multiset.noncommProd.{u2} α _inst_1 s comm)) (Multiset.noncommProd.{u3} β _inst_2 (Multiset.map.{u2, u3} α β (coeFn.{succ u1, max (succ u2) (succ u3)} F (fun (_x : F) => α -> β) (FunLike.hasCoeToFun.{succ u1, succ u2, succ u3} F α (fun (_x : α) => β) (MulHomClass.toFunLike.{u1, u2, u3} F α β (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2) _inst_3))) f) s) (Multiset.noncommProd_map_aux.{u1, u2, u3} F α β _inst_1 _inst_2 _inst_3 s comm f))
 but is expected to have type
-  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α) (comm : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) (f : F), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : α) => β) (Multiset.noncommProd.{u2} α _inst_1 s comm)) (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f (Multiset.noncommProd.{u2} α _inst_1 s comm)) (Multiset.noncommProd.{u1} β _inst_2 (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s) (Multiset.noncommProd_map_aux.{u1, u2, u3} F α β _inst_1 _inst_2 _inst_3 s comm f))
+  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α) (comm : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) (f : F), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : α) => β) (Multiset.noncommProd.{u2} α _inst_1 s comm)) (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f (Multiset.noncommProd.{u2} α _inst_1 s comm)) (Multiset.noncommProd.{u1} β _inst_2 (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s) (Multiset.noncommProd_map_aux.{u1, u2, u3} F α β _inst_1 _inst_2 _inst_3 s comm f))
 Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_map Multiset.noncommProd_mapₓ'. -/
 @[to_additive]
 theorem noncommProd_map [MonoidHomClass F α β] (s : Multiset α) (comm) (f : F) :
@@ -451,7 +451,7 @@ theorem noncommProd_singleton (a : α) (f : α → β) :
 lean 3 declaration is
   forall {F : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} {γ : Type.{u4}} [_inst_1 : Monoid.{u3} β] [_inst_2 : Monoid.{u4} γ] [_inst_3 : MonoidHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2)] (s : Finset.{u2} α) (f : α -> β) (comm : Set.Pairwise.{u2} α ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s) (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b))) (g : F), Eq.{succ u4} γ (coeFn.{succ u1, max (succ u3) (succ u4)} F (fun (_x : F) => β -> γ) (FunLike.hasCoeToFun.{succ u1, succ u3, succ u4} F β (fun (_x : β) => γ) (MulHomClass.toFunLike.{u1, u3, u4} F β γ (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toHasMul.{u4} γ (Monoid.toMulOneClass.{u4} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2) _inst_3))) g (Finset.noncommProd.{u2, u3} α β _inst_1 s f comm)) (Finset.noncommProd.{u2, u4} α γ _inst_2 s (fun (i : α) => coeFn.{succ u1, max (succ u3) (succ u4)} F (fun (_x : F) => β -> γ) (FunLike.hasCoeToFun.{succ u1, succ u3, succ u4} F β (fun (_x : β) => γ) (MulHomClass.toFunLike.{u1, u3, u4} F β γ (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toHasMul.{u4} γ (Monoid.toMulOneClass.{u4} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2) _inst_3))) g (f i)) (fun (x : α) (hx : Membership.Mem.{u2, u2} α (Set.{u2} α) (Set.hasMem.{u2} α) x ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s)) (y : α) (hy : Membership.Mem.{u2, u2} α (Set.{u2} α) (Set.hasMem.{u2} α) y ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s)) (h : Ne.{succ u2} α x y) => Commute.map.{u1, u3, u4} F β γ (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toHasMul.{u4} γ (Monoid.toMulOneClass.{u4} γ _inst_2)) (f x) (f y) (MonoidHomClass.toMulHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2) _inst_3) (Set.Pairwise.of_refl.{u2} α (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b)) ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s) (Commute.on_isRefl.{u2, u3} α β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (fun (a : α) => f a)) comm x hx y hy) g))
 but is expected to have type
-  forall {F : Type.{u4}} {α : Type.{u1}} {β : Type.{u3}} {γ : Type.{u2}} [_inst_1 : Monoid.{u3} β] [_inst_2 : Monoid.{u2} γ] [_inst_3 : MonoidHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2)] (s : Finset.{u1} α) (f : α -> β) (comm : Set.Pairwise.{u1} α (Finset.toSet.{u1} α s) (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b))) (g : F), Eq.{succ u2} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : β) => γ) (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (Finset.noncommProd.{u1, u2} α γ _inst_2 s (fun (i : α) => FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (f i)) (fun (x : α) (hx : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) x (Finset.toSet.{u1} α s)) (y : α) (hy : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) y (Finset.toSet.{u1} α s)) (h : Ne.{succ u1} α x y) => Commute.map.{u2, u3, u4} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (f x) (f y) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3) (Set.Pairwise.of_refl.{u1} α (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b)) (Finset.toSet.{u1} α s) (Commute.on_isRefl.{u1, u3} α β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (fun (a : α) => f a)) comm x hx y hy) g))
+  forall {F : Type.{u4}} {α : Type.{u1}} {β : Type.{u3}} {γ : Type.{u2}} [_inst_1 : Monoid.{u3} β] [_inst_2 : Monoid.{u2} γ] [_inst_3 : MonoidHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2)] (s : Finset.{u1} α) (f : α -> β) (comm : Set.Pairwise.{u1} α (Finset.toSet.{u1} α s) (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b))) (g : F), Eq.{succ u2} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : β) => γ) (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (Finset.noncommProd.{u1, u2} α γ _inst_2 s (fun (i : α) => FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (f i)) (fun (x : α) (hx : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) x (Finset.toSet.{u1} α s)) (y : α) (hy : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) y (Finset.toSet.{u1} α s)) (h : Ne.{succ u1} α x y) => Commute.map.{u2, u3, u4} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (f x) (f y) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3) (Set.Pairwise.of_refl.{u1} α (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b)) (Finset.toSet.{u1} α s) (Commute.on_isRefl.{u1, u3} α β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (fun (a : α) => f a)) comm x hx y hy) g))
 Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_map Finset.noncommProd_mapₓ'. -/
 @[to_additive]
 theorem noncommProd_map [MonoidHomClass F β γ] (s : Finset α) (f : α → β) (comm) (g : F) :
@@ -611,7 +611,7 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
 lean 3 declaration is
   forall {ι : Type.{u1}} {γ : Type.{u2}} [_inst_2 : Monoid.{u2} γ] {M : ι -> Type.{u3}} [_inst_3 : forall (i : ι), Monoid.{u3} (M i)] [_inst_4 : Finite.{succ u1} ι] [_inst_5 : DecidableEq.{succ u1} ι] {f : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)} {g : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)}, (forall (i : ι) (x : M i), Eq.{succ u2} γ (coeFn.{max (succ u2) (succ (max u1 u3)), max (succ (max u1 u3)) (succ u2)} (MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) (fun (_x : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) => (forall (i : ι), M i) -> γ) (MonoidHom.hasCoeToFun.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) f (Pi.mulSingle.{u1, u3} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => MulOneClass.toHasOne.{u3} (M i) (Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) i x)) (coeFn.{max (succ u2) (succ (max u1 u3)), max (succ (max u1 u3)) (succ u2)} (MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) (fun (_x : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) => (forall (i : ι), M i) -> γ) (MonoidHom.hasCoeToFun.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) g (Pi.mulSingle.{u1, u3} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => MulOneClass.toHasOne.{u3} (M i) (Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) i x))) -> (Eq.{max (succ u2) (succ (max u1 u3))} (MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) f g)
 but is expected to have type
-  forall {ι : Type.{u3}} {γ : Type.{u1}} [_inst_2 : Monoid.{u1} γ] {M : ι -> Type.{u2}} [_inst_3 : forall (i : ι), Monoid.{u2} (M i)] [_inst_4 : Finite.{succ u3} ι] [_inst_5 : DecidableEq.{succ u3} ι] {f : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)} {g : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)}, (forall (i : ι) (x : M i), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : forall (i : ι), M i) => γ) (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) f (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) g (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x))) -> (Eq.{max (max (succ u3) (succ u1)) (succ u2)} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) f g)
+  forall {ι : Type.{u3}} {γ : Type.{u1}} [_inst_2 : Monoid.{u1} γ] {M : ι -> Type.{u2}} [_inst_3 : forall (i : ι), Monoid.{u2} (M i)] [_inst_4 : Finite.{succ u3} ι] [_inst_5 : DecidableEq.{succ u3} ι] {f : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)} {g : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)}, (forall (i : ι) (x : M i), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : forall (i : ι), M i) => γ) (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) f (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) g (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x))) -> (Eq.{max (max (succ u3) (succ u1)) (succ u2)} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) f g)
 Case conversion may be inaccurate. Consider using '#align monoid_hom.pi_ext MonoidHom.pi_extₓ'. -/
 @[to_additive]
 theorem MonoidHom.pi_ext [Finite ι] [DecidableEq ι] {f g : (∀ i, M i) →* γ}
Diff
@@ -408,7 +408,7 @@ theorem noncommProd_empty (f : α → β) (h) : noncommProd (∅ : Finset α) f
 lean 3 declaration is
   forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] [_inst_3 : DecidableEq.{succ u1} α] (s : Finset.{u1} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))), (Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) -> (Eq.{succ u2} β (Finset.noncommProd.{u1, u2} α β _inst_1 (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u2, u2, u2} β β β (instHMul.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1))) (f a) (Finset.noncommProd.{u1, u2} α β _inst_1 s f (Set.Pairwise.mono.{u1} α (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (_x : α) => Finset.mem_insert_of_mem.{u1} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm))))
 but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] (s : Finset.{u2} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), (Not (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) a s)) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (f a) (Finset.noncommProd.{u2, u1} α β _inst_1 s f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.2121 : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.2121 (Finset.val.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s))) (Finset.toSet.{u2} α s) (fun (_x : α) => Finset.mem_insert_of_mem.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm))))
+  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] (s : Finset.{u2} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), (Not (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) a s)) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (f a) (Finset.noncommProd.{u2, u1} α β _inst_1 s f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.2117 : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.2117 (Finset.val.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s))) (Finset.toSet.{u2} α s) (fun (_x : α) => Finset.mem_insert_of_mem.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm))))
 Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_insert_of_not_mem Finset.noncommProd_insert_of_not_memₓ'. -/
 @[simp, to_additive]
 theorem noncommProd_insert_of_not_mem [DecidableEq α] (s : Finset α) (a : α) (f : α → β) (comm)
@@ -423,7 +423,7 @@ theorem noncommProd_insert_of_not_mem [DecidableEq α] (s : Finset α) (a : α)
 lean 3 declaration is
   forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] [_inst_3 : DecidableEq.{succ u1} α] (s : Finset.{u1} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))), (Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) -> (Eq.{succ u2} β (Finset.noncommProd.{u1, u2} α β _inst_1 (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u2, u2, u2} β β β (instHMul.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1))) (Finset.noncommProd.{u1, u2} α β _inst_1 s f (Set.Pairwise.mono.{u1} α (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (_x : α) => Finset.mem_insert_of_mem.{u1} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm)) (f a)))
 but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] (s : Finset.{u2} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), (Not (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) a s)) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (Finset.noncommProd.{u2, u1} α β _inst_1 s f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.2354 : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.2354 (Finset.val.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s))) (Finset.toSet.{u2} α s) (fun (_x : α) => Finset.mem_insert_of_mem.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm)) (f a)))
+  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] (s : Finset.{u2} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), (Not (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) a s)) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (Finset.noncommProd.{u2, u1} α β _inst_1 s f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.2350 : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.2350 (Finset.val.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s))) (Finset.toSet.{u2} α s) (fun (_x : α) => Finset.mem_insert_of_mem.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm)) (f a)))
 Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_insert_of_not_mem' Finset.noncommProd_insert_of_not_mem'ₓ'. -/
 @[to_additive]
 theorem noncommProd_insert_of_not_mem' [DecidableEq α] (s : Finset α) (a : α) (f : α → β) (comm)
Diff
@@ -423,7 +423,7 @@ theorem noncommProd_insert_of_not_mem [DecidableEq α] (s : Finset α) (a : α)
 lean 3 declaration is
   forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] [_inst_3 : DecidableEq.{succ u1} α] (s : Finset.{u1} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))), (Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) -> (Eq.{succ u2} β (Finset.noncommProd.{u1, u2} α β _inst_1 (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u2, u2, u2} β β β (instHMul.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1))) (Finset.noncommProd.{u1, u2} α β _inst_1 s f (Set.Pairwise.mono.{u1} α (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (_x : α) => Finset.mem_insert_of_mem.{u1} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm)) (f a)))
 but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] (s : Finset.{u2} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), (Not (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) a s)) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (Finset.noncommProd.{u2, u1} α β _inst_1 s f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.2337 : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.2337 (Finset.val.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s))) (Finset.toSet.{u2} α s) (fun (_x : α) => Finset.mem_insert_of_mem.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm)) (f a)))
+  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] (s : Finset.{u2} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), (Not (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) a s)) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (Finset.noncommProd.{u2, u1} α β _inst_1 s f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.2354 : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.2354 (Finset.val.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s))) (Finset.toSet.{u2} α s) (fun (_x : α) => Finset.mem_insert_of_mem.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm)) (f a)))
 Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_insert_of_not_mem' Finset.noncommProd_insert_of_not_mem'ₓ'. -/
 @[to_additive]
 theorem noncommProd_insert_of_not_mem' [DecidableEq α] (s : Finset α) (a : α) (f : α → β) (comm)
Diff
@@ -263,7 +263,7 @@ theorem noncommProd_add (s t : Multiset α) (comm) :
 lean 3 declaration is
   forall {F : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u3} β] [_inst_3 : MonoidHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2)] (s : Multiset.{u2} α), (Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.Mem.{u2, u2} α (Multiset.{u2} α) (Multiset.hasMem.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) -> (forall (f : F), Set.Pairwise.{u3} β (setOf.{u3} β (fun (x : β) => Membership.Mem.{u3, u3} β (Multiset.{u3} β) (Multiset.hasMem.{u3} β) x (Multiset.map.{u2, u3} α β (coeFn.{succ u1, max (succ u2) (succ u3)} F (fun (_x : F) => α -> β) (FunLike.hasCoeToFun.{succ u1, succ u2, succ u3} F α (fun (_x : α) => β) (MulHomClass.toFunLike.{u1, u2, u3} F α β (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2) _inst_3))) f) s))) (Commute.{u3} β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2))))
 but is expected to have type
-  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α), (Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) -> (forall (f : F), Set.Pairwise.{u1} β (setOf.{u1} β (fun (x : β) => Membership.mem.{u1, u1} β (Multiset.{u1} β) (Multiset.instMembershipMultiset.{u1} β) x (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s))) (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2))))
+  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α), (Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) -> (forall (f : F), Set.Pairwise.{u1} β (setOf.{u1} β (fun (x : β) => Membership.mem.{u1, u1} β (Multiset.{u1} β) (Multiset.instMembershipMultiset.{u1} β) x (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s))) (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2))))
 Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_map_aux Multiset.noncommProd_map_auxₓ'. -/
 @[protected, to_additive]
 theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
@@ -279,7 +279,7 @@ theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
 lean 3 declaration is
   forall {F : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u3} β] [_inst_3 : MonoidHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2)] (s : Multiset.{u2} α) (comm : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.Mem.{u2, u2} α (Multiset.{u2} α) (Multiset.hasMem.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) (f : F), Eq.{succ u3} β (coeFn.{succ u1, max (succ u2) (succ u3)} F (fun (_x : F) => α -> β) (FunLike.hasCoeToFun.{succ u1, succ u2, succ u3} F α (fun (_x : α) => β) (MulHomClass.toFunLike.{u1, u2, u3} F α β (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2) _inst_3))) f (Multiset.noncommProd.{u2} α _inst_1 s comm)) (Multiset.noncommProd.{u3} β _inst_2 (Multiset.map.{u2, u3} α β (coeFn.{succ u1, max (succ u2) (succ u3)} F (fun (_x : F) => α -> β) (FunLike.hasCoeToFun.{succ u1, succ u2, succ u3} F α (fun (_x : α) => β) (MulHomClass.toFunLike.{u1, u2, u3} F α β (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2) _inst_3))) f) s) (Multiset.noncommProd_map_aux.{u1, u2, u3} F α β _inst_1 _inst_2 _inst_3 s comm f))
 but is expected to have type
-  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α) (comm : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) (f : F), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : α) => β) (Multiset.noncommProd.{u2} α _inst_1 s comm)) (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f (Multiset.noncommProd.{u2} α _inst_1 s comm)) (Multiset.noncommProd.{u1} β _inst_2 (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s) (Multiset.noncommProd_map_aux.{u1, u2, u3} F α β _inst_1 _inst_2 _inst_3 s comm f))
+  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α) (comm : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) (f : F), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : α) => β) (Multiset.noncommProd.{u2} α _inst_1 s comm)) (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f (Multiset.noncommProd.{u2} α _inst_1 s comm)) (Multiset.noncommProd.{u1} β _inst_2 (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s) (Multiset.noncommProd_map_aux.{u1, u2, u3} F α β _inst_1 _inst_2 _inst_3 s comm f))
 Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_map Multiset.noncommProd_mapₓ'. -/
 @[to_additive]
 theorem noncommProd_map [MonoidHomClass F α β] (s : Multiset α) (comm) (f : F) :
@@ -294,7 +294,7 @@ theorem noncommProd_map [MonoidHomClass F α β] (s : Multiset α) (comm) (f : F
 lean 3 declaration is
   forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x s)) (Commute.{u1} α (MulOneClass.toHasMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))) (m : α), (forall (x : α), (Membership.Mem.{u1, u1} α (Multiset.{u1} α) (Multiset.hasMem.{u1} α) x s) -> (Eq.{succ u1} α x m)) -> (Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 s comm) (HPow.hPow.{u1, 0, u1} α Nat α (instHPow.{u1, 0} α Nat (Monoid.Pow.{u1} α _inst_1)) m (coeFn.{succ u1, succ u1} (AddMonoidHom.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.orderedCancelAddCommMonoid.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (fun (_x : AddMonoidHom.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.orderedCancelAddCommMonoid.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) => (Multiset.{u1} α) -> Nat) (AddMonoidHom.hasCoeToFun.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.orderedCancelAddCommMonoid.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (Multiset.card.{u1} α) s)))
 but is expected to have type
-  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x s)) (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))) (m : α), (forall (x : α), (Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x s) -> (Eq.{succ u1} α x m)) -> (Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 s comm) (HPow.hPow.{u1, 0, u1} α ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.398 : Multiset.{u1} α) => Nat) s) α (instHPow.{u1, 0} α ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.398 : Multiset.{u1} α) => Nat) s) (Monoid.Pow.{u1} α _inst_1)) m (FunLike.coe.{succ u1, succ u1, 1} (AddMonoidHom.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (Multiset.{u1} α) (fun (_x : Multiset.{u1} α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.398 : Multiset.{u1} α) => Nat) _x) (AddHomClass.toFunLike.{u1, u1, 0} (AddMonoidHom.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (Multiset.{u1} α) Nat (AddZeroClass.toAdd.{u1} (Multiset.{u1} α) (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α))))))) (AddZeroClass.toAdd.{0} Nat (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (AddMonoidHomClass.toAddHomClass.{u1, u1, 0} (AddMonoidHom.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid) (AddMonoidHom.addMonoidHomClass.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)))) (Multiset.card.{u1} α) s)))
+  forall {α : Type.{u1}} [_inst_1 : Monoid.{u1} α] (s : Multiset.{u1} α) (comm : Set.Pairwise.{u1} α (setOf.{u1} α (fun (x : α) => Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x s)) (Commute.{u1} α (MulOneClass.toMul.{u1} α (Monoid.toMulOneClass.{u1} α _inst_1)))) (m : α), (forall (x : α), (Membership.mem.{u1, u1} α (Multiset.{u1} α) (Multiset.instMembershipMultiset.{u1} α) x s) -> (Eq.{succ u1} α x m)) -> (Eq.{succ u1} α (Multiset.noncommProd.{u1} α _inst_1 s comm) (HPow.hPow.{u1, 0, u1} α ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.403 : Multiset.{u1} α) => Nat) s) α (instHPow.{u1, 0} α ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.403 : Multiset.{u1} α) => Nat) s) (Monoid.Pow.{u1} α _inst_1)) m (FunLike.coe.{succ u1, succ u1, 1} (AddMonoidHom.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (Multiset.{u1} α) (fun (_x : Multiset.{u1} α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.403 : Multiset.{u1} α) => Nat) _x) (AddHomClass.toFunLike.{u1, u1, 0} (AddMonoidHom.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (Multiset.{u1} α) Nat (AddZeroClass.toAdd.{u1} (Multiset.{u1} α) (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α))))))) (AddZeroClass.toAdd.{0} Nat (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (AddMonoidHomClass.toAddHomClass.{u1, u1, 0} (AddMonoidHom.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)) (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid) (AddMonoidHom.addMonoidHomClass.{u1, 0} (Multiset.{u1} α) Nat (AddMonoid.toAddZeroClass.{u1} (Multiset.{u1} α) (AddRightCancelMonoid.toAddMonoid.{u1} (Multiset.{u1} α) (AddCancelMonoid.toAddRightCancelMonoid.{u1} (Multiset.{u1} α) (AddCancelCommMonoid.toAddCancelMonoid.{u1} (Multiset.{u1} α) (OrderedCancelAddCommMonoid.toCancelAddCommMonoid.{u1} (Multiset.{u1} α) (Multiset.instOrderedCancelAddCommMonoidMultiset.{u1} α)))))) (AddMonoid.toAddZeroClass.{0} Nat Nat.addMonoid)))) (Multiset.card.{u1} α) s)))
 Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_eq_pow_card Multiset.noncommProd_eq_pow_cardₓ'. -/
 @[to_additive noncomm_sum_eq_card_nsmul]
 theorem noncommProd_eq_pow_card (s : Multiset α) (comm) (m : α) (h : ∀ x ∈ s, x = m) :
@@ -408,7 +408,7 @@ theorem noncommProd_empty (f : α → β) (h) : noncommProd (∅ : Finset α) f
 lean 3 declaration is
   forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] [_inst_3 : DecidableEq.{succ u1} α] (s : Finset.{u1} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))), (Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) -> (Eq.{succ u2} β (Finset.noncommProd.{u1, u2} α β _inst_1 (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u2, u2, u2} β β β (instHMul.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1))) (f a) (Finset.noncommProd.{u1, u2} α β _inst_1 s f (Set.Pairwise.mono.{u1} α (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (_x : α) => Finset.mem_insert_of_mem.{u1} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm))))
 but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] (s : Finset.{u2} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), (Not (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) a s)) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (f a) (Finset.noncommProd.{u2, u1} α β _inst_1 s f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.2117 : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.2117 (Finset.val.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s))) (Finset.toSet.{u2} α s) (fun (_x : α) => Finset.mem_insert_of_mem.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm))))
+  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] (s : Finset.{u2} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), (Not (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) a s)) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (f a) (Finset.noncommProd.{u2, u1} α β _inst_1 s f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.2121 : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.2121 (Finset.val.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s))) (Finset.toSet.{u2} α s) (fun (_x : α) => Finset.mem_insert_of_mem.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm))))
 Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_insert_of_not_mem Finset.noncommProd_insert_of_not_memₓ'. -/
 @[simp, to_additive]
 theorem noncommProd_insert_of_not_mem [DecidableEq α] (s : Finset α) (a : α) (f : α → β) (comm)
@@ -423,7 +423,7 @@ theorem noncommProd_insert_of_not_mem [DecidableEq α] (s : Finset α) (a : α)
 lean 3 declaration is
   forall {α : Type.{u1}} {β : Type.{u2}} [_inst_1 : Monoid.{u2} β] [_inst_3 : DecidableEq.{succ u1} α] (s : Finset.{u1} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u1} α ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b))), (Not (Membership.Mem.{u1, u1} α (Finset.{u1} α) (Finset.hasMem.{u1} α) a s)) -> (Eq.{succ u2} β (Finset.noncommProd.{u1, u2} α β _inst_1 (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u2, u2, u2} β β β (instHMul.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1))) (Finset.noncommProd.{u1, u2} α β _inst_1 s f (Set.Pairwise.mono.{u1} α (fun (a : α) (b : α) => Commute.{u2} β (MulOneClass.toHasMul.{u2} β (Monoid.toMulOneClass.{u2} β _inst_1)) (f a) (f b)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) (Insert.insert.{u1, u1} α (Finset.{u1} α) (Finset.hasInsert.{u1} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Finset.{u1} α) (Set.{u1} α) (HasLiftT.mk.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (CoeTCₓ.coe.{succ u1, succ u1} (Finset.{u1} α) (Set.{u1} α) (Finset.Set.hasCoeT.{u1} α))) s) (fun (_x : α) => Finset.mem_insert_of_mem.{u1} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm)) (f a)))
 but is expected to have type
-  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] (s : Finset.{u2} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), (Not (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) a s)) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (Finset.noncommProd.{u2, u1} α β _inst_1 s f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.2333 : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.2333 (Finset.val.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s))) (Finset.toSet.{u2} α s) (fun (_x : α) => Finset.mem_insert_of_mem.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm)) (f a)))
+  forall {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u1} β] [_inst_3 : DecidableEq.{succ u2} α] (s : Finset.{u2} α) (a : α) (f : α -> β) (comm : Set.Pairwise.{u2} α (Finset.toSet.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s)) (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b))), (Not (Membership.mem.{u2, u2} α (Finset.{u2} α) (Finset.instMembershipFinset.{u2} α) a s)) -> (Eq.{succ u1} β (Finset.noncommProd.{u2, u1} α β _inst_1 (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s) f comm) (HMul.hMul.{u1, u1, u1} β β β (instHMul.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1))) (Finset.noncommProd.{u2, u1} α β _inst_1 s f (Set.Pairwise.mono.{u2} α (fun (a : α) (b : α) => Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_1)) (f a) (f b)) (fun (x._@.Mathlib.Data.Finset.NoncommProd._hyg.2337 : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x._@.Mathlib.Data.Finset.NoncommProd._hyg.2337 (Finset.val.{u2} α (Insert.insert.{u2, u2} α (Finset.{u2} α) (Finset.instInsertFinset.{u2} α (fun (a : α) (b : α) => _inst_3 a b)) a s))) (Finset.toSet.{u2} α s) (fun (_x : α) => Finset.mem_insert_of_mem.{u2} α (fun (a : α) (b : α) => _inst_3 a b) s _x a) comm)) (f a)))
 Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_insert_of_not_mem' Finset.noncommProd_insert_of_not_mem'ₓ'. -/
 @[to_additive]
 theorem noncommProd_insert_of_not_mem' [DecidableEq α] (s : Finset α) (a : α) (f : α → β) (comm)
@@ -451,7 +451,7 @@ theorem noncommProd_singleton (a : α) (f : α → β) :
 lean 3 declaration is
   forall {F : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} {γ : Type.{u4}} [_inst_1 : Monoid.{u3} β] [_inst_2 : Monoid.{u4} γ] [_inst_3 : MonoidHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2)] (s : Finset.{u2} α) (f : α -> β) (comm : Set.Pairwise.{u2} α ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s) (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b))) (g : F), Eq.{succ u4} γ (coeFn.{succ u1, max (succ u3) (succ u4)} F (fun (_x : F) => β -> γ) (FunLike.hasCoeToFun.{succ u1, succ u3, succ u4} F β (fun (_x : β) => γ) (MulHomClass.toFunLike.{u1, u3, u4} F β γ (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toHasMul.{u4} γ (Monoid.toMulOneClass.{u4} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2) _inst_3))) g (Finset.noncommProd.{u2, u3} α β _inst_1 s f comm)) (Finset.noncommProd.{u2, u4} α γ _inst_2 s (fun (i : α) => coeFn.{succ u1, max (succ u3) (succ u4)} F (fun (_x : F) => β -> γ) (FunLike.hasCoeToFun.{succ u1, succ u3, succ u4} F β (fun (_x : β) => γ) (MulHomClass.toFunLike.{u1, u3, u4} F β γ (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toHasMul.{u4} γ (Monoid.toMulOneClass.{u4} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2) _inst_3))) g (f i)) (fun (x : α) (hx : Membership.Mem.{u2, u2} α (Set.{u2} α) (Set.hasMem.{u2} α) x ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s)) (y : α) (hy : Membership.Mem.{u2, u2} α (Set.{u2} α) (Set.hasMem.{u2} α) y ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s)) (h : Ne.{succ u2} α x y) => Commute.map.{u1, u3, u4} F β γ (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toHasMul.{u4} γ (Monoid.toMulOneClass.{u4} γ _inst_2)) (f x) (f y) (MonoidHomClass.toMulHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2) _inst_3) (Set.Pairwise.of_refl.{u2} α (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b)) ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s) (Commute.on_isRefl.{u2, u3} α β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (fun (a : α) => f a)) comm x hx y hy) g))
 but is expected to have type
-  forall {F : Type.{u4}} {α : Type.{u1}} {β : Type.{u3}} {γ : Type.{u2}} [_inst_1 : Monoid.{u3} β] [_inst_2 : Monoid.{u2} γ] [_inst_3 : MonoidHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2)] (s : Finset.{u1} α) (f : α -> β) (comm : Set.Pairwise.{u1} α (Finset.toSet.{u1} α s) (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b))) (g : F), Eq.{succ u2} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : β) => γ) (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (Finset.noncommProd.{u1, u2} α γ _inst_2 s (fun (i : α) => FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (f i)) (fun (x : α) (hx : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) x (Finset.toSet.{u1} α s)) (y : α) (hy : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) y (Finset.toSet.{u1} α s)) (h : Ne.{succ u1} α x y) => Commute.map.{u2, u3, u4} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (f x) (f y) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3) (Set.Pairwise.of_refl.{u1} α (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b)) (Finset.toSet.{u1} α s) (Commute.on_isRefl.{u1, u3} α β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (fun (a : α) => f a)) comm x hx y hy) g))
+  forall {F : Type.{u4}} {α : Type.{u1}} {β : Type.{u3}} {γ : Type.{u2}} [_inst_1 : Monoid.{u3} β] [_inst_2 : Monoid.{u2} γ] [_inst_3 : MonoidHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2)] (s : Finset.{u1} α) (f : α -> β) (comm : Set.Pairwise.{u1} α (Finset.toSet.{u1} α s) (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b))) (g : F), Eq.{succ u2} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : β) => γ) (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (Finset.noncommProd.{u1, u2} α γ _inst_2 s (fun (i : α) => FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (f i)) (fun (x : α) (hx : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) x (Finset.toSet.{u1} α s)) (y : α) (hy : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) y (Finset.toSet.{u1} α s)) (h : Ne.{succ u1} α x y) => Commute.map.{u2, u3, u4} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (f x) (f y) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3) (Set.Pairwise.of_refl.{u1} α (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b)) (Finset.toSet.{u1} α s) (Commute.on_isRefl.{u1, u3} α β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (fun (a : α) => f a)) comm x hx y hy) g))
 Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_map Finset.noncommProd_mapₓ'. -/
 @[to_additive]
 theorem noncommProd_map [MonoidHomClass F β γ] (s : Finset α) (f : α → β) (comm) (g : F) :
@@ -611,7 +611,7 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
 lean 3 declaration is
   forall {ι : Type.{u1}} {γ : Type.{u2}} [_inst_2 : Monoid.{u2} γ] {M : ι -> Type.{u3}} [_inst_3 : forall (i : ι), Monoid.{u3} (M i)] [_inst_4 : Finite.{succ u1} ι] [_inst_5 : DecidableEq.{succ u1} ι] {f : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)} {g : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)}, (forall (i : ι) (x : M i), Eq.{succ u2} γ (coeFn.{max (succ u2) (succ (max u1 u3)), max (succ (max u1 u3)) (succ u2)} (MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) (fun (_x : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) => (forall (i : ι), M i) -> γ) (MonoidHom.hasCoeToFun.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) f (Pi.mulSingle.{u1, u3} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => MulOneClass.toHasOne.{u3} (M i) (Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) i x)) (coeFn.{max (succ u2) (succ (max u1 u3)), max (succ (max u1 u3)) (succ u2)} (MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) (fun (_x : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) => (forall (i : ι), M i) -> γ) (MonoidHom.hasCoeToFun.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) g (Pi.mulSingle.{u1, u3} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => MulOneClass.toHasOne.{u3} (M i) (Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) i x))) -> (Eq.{max (succ u2) (succ (max u1 u3))} (MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) f g)
 but is expected to have type
-  forall {ι : Type.{u3}} {γ : Type.{u1}} [_inst_2 : Monoid.{u1} γ] {M : ι -> Type.{u2}} [_inst_3 : forall (i : ι), Monoid.{u2} (M i)] [_inst_4 : Finite.{succ u3} ι] [_inst_5 : DecidableEq.{succ u3} ι] {f : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)} {g : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)}, (forall (i : ι) (x : M i), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : forall (i : ι), M i) => γ) (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) f (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) g (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x))) -> (Eq.{max (max (succ u3) (succ u1)) (succ u2)} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) f g)
+  forall {ι : Type.{u3}} {γ : Type.{u1}} [_inst_2 : Monoid.{u1} γ] {M : ι -> Type.{u2}} [_inst_3 : forall (i : ι), Monoid.{u2} (M i)] [_inst_4 : Finite.{succ u3} ι] [_inst_5 : DecidableEq.{succ u3} ι] {f : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)} {g : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)}, (forall (i : ι) (x : M i), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : forall (i : ι), M i) => γ) (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) f (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) g (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x))) -> (Eq.{max (max (succ u3) (succ u1)) (succ u2)} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) f g)
 Case conversion may be inaccurate. Consider using '#align monoid_hom.pi_ext MonoidHom.pi_extₓ'. -/
 @[to_additive]
 theorem MonoidHom.pi_ext [Finite ι] [DecidableEq ι] {f g : (∀ i, M i) →* γ}
Diff
@@ -263,7 +263,7 @@ theorem noncommProd_add (s t : Multiset α) (comm) :
 lean 3 declaration is
   forall {F : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u3} β] [_inst_3 : MonoidHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2)] (s : Multiset.{u2} α), (Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.Mem.{u2, u2} α (Multiset.{u2} α) (Multiset.hasMem.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) -> (forall (f : F), Set.Pairwise.{u3} β (setOf.{u3} β (fun (x : β) => Membership.Mem.{u3, u3} β (Multiset.{u3} β) (Multiset.hasMem.{u3} β) x (Multiset.map.{u2, u3} α β (coeFn.{succ u1, max (succ u2) (succ u3)} F (fun (_x : F) => α -> β) (FunLike.hasCoeToFun.{succ u1, succ u2, succ u3} F α (fun (_x : α) => β) (MulHomClass.toFunLike.{u1, u2, u3} F α β (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2) _inst_3))) f) s))) (Commute.{u3} β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2))))
 but is expected to have type
-  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α), (Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) -> (forall (f : F), Set.Pairwise.{u1} β (setOf.{u1} β (fun (x : β) => Membership.mem.{u1, u1} β (Multiset.{u1} β) (Multiset.instMembershipMultiset.{u1} β) x (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s))) (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2))))
+  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α), (Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) -> (forall (f : F), Set.Pairwise.{u1} β (setOf.{u1} β (fun (x : β) => Membership.mem.{u1, u1} β (Multiset.{u1} β) (Multiset.instMembershipMultiset.{u1} β) x (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s))) (Commute.{u1} β (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2))))
 Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_map_aux Multiset.noncommProd_map_auxₓ'. -/
 @[protected, to_additive]
 theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
@@ -279,7 +279,7 @@ theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
 lean 3 declaration is
   forall {F : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u3} β] [_inst_3 : MonoidHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2)] (s : Multiset.{u2} α) (comm : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.Mem.{u2, u2} α (Multiset.{u2} α) (Multiset.hasMem.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) (f : F), Eq.{succ u3} β (coeFn.{succ u1, max (succ u2) (succ u3)} F (fun (_x : F) => α -> β) (FunLike.hasCoeToFun.{succ u1, succ u2, succ u3} F α (fun (_x : α) => β) (MulHomClass.toFunLike.{u1, u2, u3} F α β (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2) _inst_3))) f (Multiset.noncommProd.{u2} α _inst_1 s comm)) (Multiset.noncommProd.{u3} β _inst_2 (Multiset.map.{u2, u3} α β (coeFn.{succ u1, max (succ u2) (succ u3)} F (fun (_x : F) => α -> β) (FunLike.hasCoeToFun.{succ u1, succ u2, succ u3} F α (fun (_x : α) => β) (MulHomClass.toFunLike.{u1, u2, u3} F α β (MulOneClass.toHasMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u2, u3} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u3} β _inst_2) _inst_3))) f) s) (Multiset.noncommProd_map_aux.{u1, u2, u3} F α β _inst_1 _inst_2 _inst_3 s comm f))
 but is expected to have type
-  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α) (comm : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) (f : F), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : α) => β) (Multiset.noncommProd.{u2} α _inst_1 s comm)) (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f (Multiset.noncommProd.{u2} α _inst_1 s comm)) (Multiset.noncommProd.{u1} β _inst_2 (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s) (Multiset.noncommProd_map_aux.{u1, u2, u3} F α β _inst_1 _inst_2 _inst_3 s comm f))
+  forall {F : Type.{u3}} {α : Type.{u2}} {β : Type.{u1}} [_inst_1 : Monoid.{u2} α] [_inst_2 : Monoid.{u1} β] [_inst_3 : MonoidHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2)] (s : Multiset.{u2} α) (comm : Set.Pairwise.{u2} α (setOf.{u2} α (fun (x : α) => Membership.mem.{u2, u2} α (Multiset.{u2} α) (Multiset.instMembershipMultiset.{u2} α) x s)) (Commute.{u2} α (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)))) (f : F), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : α) => β) (Multiset.noncommProd.{u2} α _inst_1 s comm)) (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f (Multiset.noncommProd.{u2} α _inst_1 s comm)) (Multiset.noncommProd.{u1} β _inst_2 (Multiset.map.{u2, u1} α β (FunLike.coe.{succ u3, succ u2, succ u1} F α (fun (_x : α) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : α) => β) _x) (MulHomClass.toFunLike.{u3, u2, u1} F α β (MulOneClass.toMul.{u2} α (Monoid.toMulOneClass.{u2} α _inst_1)) (MulOneClass.toMul.{u1} β (Monoid.toMulOneClass.{u1} β _inst_2)) (MonoidHomClass.toMulHomClass.{u3, u2, u1} F α β (Monoid.toMulOneClass.{u2} α _inst_1) (Monoid.toMulOneClass.{u1} β _inst_2) _inst_3)) f) s) (Multiset.noncommProd_map_aux.{u1, u2, u3} F α β _inst_1 _inst_2 _inst_3 s comm f))
 Case conversion may be inaccurate. Consider using '#align multiset.noncomm_prod_map Multiset.noncommProd_mapₓ'. -/
 @[to_additive]
 theorem noncommProd_map [MonoidHomClass F α β] (s : Multiset α) (comm) (f : F) :
@@ -451,7 +451,7 @@ theorem noncommProd_singleton (a : α) (f : α → β) :
 lean 3 declaration is
   forall {F : Type.{u1}} {α : Type.{u2}} {β : Type.{u3}} {γ : Type.{u4}} [_inst_1 : Monoid.{u3} β] [_inst_2 : Monoid.{u4} γ] [_inst_3 : MonoidHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2)] (s : Finset.{u2} α) (f : α -> β) (comm : Set.Pairwise.{u2} α ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s) (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b))) (g : F), Eq.{succ u4} γ (coeFn.{succ u1, max (succ u3) (succ u4)} F (fun (_x : F) => β -> γ) (FunLike.hasCoeToFun.{succ u1, succ u3, succ u4} F β (fun (_x : β) => γ) (MulHomClass.toFunLike.{u1, u3, u4} F β γ (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toHasMul.{u4} γ (Monoid.toMulOneClass.{u4} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2) _inst_3))) g (Finset.noncommProd.{u2, u3} α β _inst_1 s f comm)) (Finset.noncommProd.{u2, u4} α γ _inst_2 s (fun (i : α) => coeFn.{succ u1, max (succ u3) (succ u4)} F (fun (_x : F) => β -> γ) (FunLike.hasCoeToFun.{succ u1, succ u3, succ u4} F β (fun (_x : β) => γ) (MulHomClass.toFunLike.{u1, u3, u4} F β γ (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toHasMul.{u4} γ (Monoid.toMulOneClass.{u4} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2) _inst_3))) g (f i)) (fun (x : α) (hx : Membership.Mem.{u2, u2} α (Set.{u2} α) (Set.hasMem.{u2} α) x ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s)) (y : α) (hy : Membership.Mem.{u2, u2} α (Set.{u2} α) (Set.hasMem.{u2} α) y ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s)) (h : Ne.{succ u2} α x y) => Commute.map.{u1, u3, u4} F β γ (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toHasMul.{u4} γ (Monoid.toMulOneClass.{u4} γ _inst_2)) (f x) (f y) (MonoidHomClass.toMulHomClass.{u1, u3, u4} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u4} γ _inst_2) _inst_3) (Set.Pairwise.of_refl.{u2} α (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b)) ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Finset.{u2} α) (Set.{u2} α) (HasLiftT.mk.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (CoeTCₓ.coe.{succ u2, succ u2} (Finset.{u2} α) (Set.{u2} α) (Finset.Set.hasCoeT.{u2} α))) s) (Commute.on_isRefl.{u2, u3} α β (MulOneClass.toHasMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (fun (a : α) => f a)) comm x hx y hy) g))
 but is expected to have type
-  forall {F : Type.{u4}} {α : Type.{u1}} {β : Type.{u3}} {γ : Type.{u2}} [_inst_1 : Monoid.{u3} β] [_inst_2 : Monoid.{u2} γ] [_inst_3 : MonoidHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2)] (s : Finset.{u1} α) (f : α -> β) (comm : Set.Pairwise.{u1} α (Finset.toSet.{u1} α s) (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b))) (g : F), Eq.{succ u2} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : β) => γ) (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (Finset.noncommProd.{u1, u2} α γ _inst_2 s (fun (i : α) => FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (f i)) (fun (x : α) (hx : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) x (Finset.toSet.{u1} α s)) (y : α) (hy : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) y (Finset.toSet.{u1} α s)) (h : Ne.{succ u1} α x y) => Commute.map.{u2, u3, u4} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (f x) (f y) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3) (Set.Pairwise.of_refl.{u1} α (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b)) (Finset.toSet.{u1} α s) (Commute.on_isRefl.{u1, u3} α β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (fun (a : α) => f a)) comm x hx y hy) g))
+  forall {F : Type.{u4}} {α : Type.{u1}} {β : Type.{u3}} {γ : Type.{u2}} [_inst_1 : Monoid.{u3} β] [_inst_2 : Monoid.{u2} γ] [_inst_3 : MonoidHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2)] (s : Finset.{u1} α) (f : α -> β) (comm : Set.Pairwise.{u1} α (Finset.toSet.{u1} α s) (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b))) (g : F), Eq.{succ u2} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : β) => γ) (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (Finset.noncommProd.{u1, u3} α β _inst_1 s f comm)) (Finset.noncommProd.{u1, u2} α γ _inst_2 s (fun (i : α) => FunLike.coe.{succ u4, succ u3, succ u2} F β (fun (_x : β) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : β) => γ) _x) (MulHomClass.toFunLike.{u4, u3, u2} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3)) g (f i)) (fun (x : α) (hx : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) x (Finset.toSet.{u1} α s)) (y : α) (hy : Membership.mem.{u1, u1} α (Set.{u1} α) (Set.instMembershipSet.{u1} α) y (Finset.toSet.{u1} α s)) (h : Ne.{succ u1} α x y) => Commute.map.{u2, u3, u4} F β γ (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (MulOneClass.toMul.{u2} γ (Monoid.toMulOneClass.{u2} γ _inst_2)) (f x) (f y) (MonoidHomClass.toMulHomClass.{u4, u3, u2} F β γ (Monoid.toMulOneClass.{u3} β _inst_1) (Monoid.toMulOneClass.{u2} γ _inst_2) _inst_3) (Set.Pairwise.of_refl.{u1} α (fun (a : α) (b : α) => Commute.{u3} β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (f a) (f b)) (Finset.toSet.{u1} α s) (Commute.on_isRefl.{u1, u3} α β (MulOneClass.toMul.{u3} β (Monoid.toMulOneClass.{u3} β _inst_1)) (fun (a : α) => f a)) comm x hx y hy) g))
 Case conversion may be inaccurate. Consider using '#align finset.noncomm_prod_map Finset.noncommProd_mapₓ'. -/
 @[to_additive]
 theorem noncommProd_map [MonoidHomClass F β γ] (s : Finset α) (f : α → β) (comm) (g : F) :
@@ -611,7 +611,7 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
 lean 3 declaration is
   forall {ι : Type.{u1}} {γ : Type.{u2}} [_inst_2 : Monoid.{u2} γ] {M : ι -> Type.{u3}} [_inst_3 : forall (i : ι), Monoid.{u3} (M i)] [_inst_4 : Finite.{succ u1} ι] [_inst_5 : DecidableEq.{succ u1} ι] {f : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)} {g : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)}, (forall (i : ι) (x : M i), Eq.{succ u2} γ (coeFn.{max (succ u2) (succ (max u1 u3)), max (succ (max u1 u3)) (succ u2)} (MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) (fun (_x : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) => (forall (i : ι), M i) -> γ) (MonoidHom.hasCoeToFun.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) f (Pi.mulSingle.{u1, u3} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => MulOneClass.toHasOne.{u3} (M i) (Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) i x)) (coeFn.{max (succ u2) (succ (max u1 u3)), max (succ (max u1 u3)) (succ u2)} (MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) (fun (_x : MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) => (forall (i : ι), M i) -> γ) (MonoidHom.hasCoeToFun.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) g (Pi.mulSingle.{u1, u3} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => MulOneClass.toHasOne.{u3} (M i) (Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) i x))) -> (Eq.{max (succ u2) (succ (max u1 u3))} (MonoidHom.{max u1 u3, u2} (forall (i : ι), M i) γ (Pi.mulOneClass.{u1, u3} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u3} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u2} γ _inst_2)) f g)
 but is expected to have type
-  forall {ι : Type.{u3}} {γ : Type.{u1}} [_inst_2 : Monoid.{u1} γ] {M : ι -> Type.{u2}} [_inst_3 : forall (i : ι), Monoid.{u2} (M i)] [_inst_4 : Finite.{succ u3} ι] [_inst_5 : DecidableEq.{succ u3} ι] {f : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)} {g : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)}, (forall (i : ι) (x : M i), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : forall (i : ι), M i) => γ) (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) f (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) g (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x))) -> (Eq.{max (max (succ u3) (succ u1)) (succ u2)} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) f g)
+  forall {ι : Type.{u3}} {γ : Type.{u1}} [_inst_2 : Monoid.{u1} γ] {M : ι -> Type.{u2}} [_inst_3 : forall (i : ι), Monoid.{u2} (M i)] [_inst_4 : Finite.{succ u3} ι] [_inst_5 : DecidableEq.{succ u3} ι] {f : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)} {g : MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)}, (forall (i : ι) (x : M i), Eq.{succ u1} ((fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : forall (i : ι), M i) => γ) (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) f (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x)) (FunLike.coe.{max (max (succ u3) (succ u1)) (succ u2), max (succ u3) (succ u2), succ u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) (fun (_x : forall (i : ι), M i) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : forall (i : ι), M i) => γ) _x) (MulHomClass.toFunLike.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (MulOneClass.toMul.{max u3 u2} (forall (i : ι), M i) (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i)))) (MulOneClass.toMul.{u1} γ (Monoid.toMulOneClass.{u1} γ _inst_2)) (MonoidHomClass.toMulHomClass.{max (max u3 u1) u2, max u3 u2, u1} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2) (MonoidHom.monoidHomClass.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)))) g (Pi.mulSingle.{u3, u2} ι (fun (i : ι) => M i) (fun (a : ι) (b : ι) => _inst_5 a b) (fun (i : ι) => Monoid.toOne.{u2} (M i) (_inst_3 i)) i x))) -> (Eq.{max (max (succ u3) (succ u1)) (succ u2)} (MonoidHom.{max u3 u2, u1} (forall (i : ι), M i) γ (Pi.mulOneClass.{u3, u2} ι (fun (i : ι) => M i) (fun (i : ι) => Monoid.toMulOneClass.{u2} (M i) (_inst_3 i))) (Monoid.toMulOneClass.{u1} γ _inst_2)) f g)
 Case conversion may be inaccurate. Consider using '#align monoid_hom.pi_ext MonoidHom.pi_extₓ'. -/
 @[to_additive]
 theorem MonoidHom.pi_ext [Finite ι] [DecidableEq ι] {f g : (∀ i, M i) →* γ}

Changes in mathlib4

mathlib3
mathlib4
chore: adapt to multiple goal linter 1 (#12338)

A PR accompanying #12339.

Zulip discussion

Diff
@@ -235,7 +235,8 @@ theorem mul_noncommProd_erase [DecidableEq α] (s : Multiset α) {a : α} (h : a
   simp only [quot_mk_to_coe, mem_coe, coe_erase, noncommProd_coe] at comm h ⊢
   suffices ∀ x ∈ l, ∀ y ∈ l, x * y = y * x by rw [List.prod_erase_of_comm h this]
   intro x hx y hy
-  rcases eq_or_ne x y with rfl | hxy; rfl
+  rcases eq_or_ne x y with rfl | hxy
+  · rfl
   exact comm hx hy hxy
 
 theorem noncommProd_erase_mul [DecidableEq α] (s : Multiset α) {a : α} (h : a ∈ s) (comm)
@@ -244,7 +245,8 @@ theorem noncommProd_erase_mul [DecidableEq α] (s : Multiset α) {a : α} (h : a
   suffices ∀ b ∈ erase s a, Commute a b by
     rw [← (noncommProd_commute (s.erase a) comm' a this).eq, mul_noncommProd_erase s h comm comm']
   intro b hb
-  rcases eq_or_ne a b with rfl | hab; rfl
+  rcases eq_or_ne a b with rfl | hab
+  · rfl
   exact comm h (mem_of_mem_erase hb) hab
 
 end Multiset
@@ -365,8 +367,8 @@ theorem noncommProd_map [MonoidHomClass F β γ] (s : Finset α) (f : α → β)
 theorem noncommProd_eq_pow_card (s : Finset α) (f : α → β) (comm) (m : β) (h : ∀ x ∈ s, f x = m) :
     s.noncommProd f comm = m ^ s.card := by
   rw [noncommProd, Multiset.noncommProd_eq_pow_card _ _ m]
-  simp only [Finset.card_def, Multiset.card_map]
-  simpa using h
+  · simp only [Finset.card_def, Multiset.card_map]
+  · simpa using h
 #align finset.noncomm_prod_eq_pow_card Finset.noncommProd_eq_pow_card
 #align finset.noncomm_sum_eq_card_nsmul Finset.noncommSum_eq_card_nsmul
 
@@ -473,7 +475,7 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
   · intro j _; dsimp
   · rw [noncommProd_insert_of_not_mem _ _ _ _ (not_mem_erase _ _),
       noncommProd_eq_pow_card (univ.erase i), one_pow, mul_one]
-    simp only [MonoidHom.mulSingle_apply, ne_eq, Pi.mulSingle_eq_same]
+    · simp only [MonoidHom.mulSingle_apply, ne_eq, Pi.mulSingle_eq_same]
     · intro j hj
       simp? at hj says simp only [mem_erase, ne_eq, mem_univ, and_true] at hj
       simp only [MonoidHom.mulSingle_apply, Pi.mulSingle, Function.update, Eq.ndrec, Pi.one_apply,
chore: Rename a few lemmas about Pi.mulSingle (#12317)

Before this PR, the MonoidHom version of Pi.mulSingle was called MonoidHom.single for brevity; but this is confusing when contrasted with MulHom.single which is about Pi.single.

After this PR, the name is MonoidHom.mulSingle.

Also fix the name of Pi.single_div since it is about Pi.mulSingle (and we don't have the lemma that would be called Pi.single_div).

Diff
@@ -462,7 +462,8 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
     (univ.noncommProd (fun i => Pi.mulSingle i (x i)) fun i _ j _ _ =>
         Pi.mulSingle_apply_commute x i j) = x := by
   ext i
-  apply (univ.noncommProd_map (fun i => MonoidHom.single M i (x i)) ?a (Pi.evalMonoidHom M i)).trans
+  apply (univ.noncommProd_map (fun i ↦ MonoidHom.mulSingle M i (x i)) ?a
+    (Pi.evalMonoidHom M i)).trans
   case a =>
     intro i _ j _ _
     exact Pi.mulSingle_apply_commute x i j
@@ -472,10 +473,10 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
   · intro j _; dsimp
   · rw [noncommProd_insert_of_not_mem _ _ _ _ (not_mem_erase _ _),
       noncommProd_eq_pow_card (univ.erase i), one_pow, mul_one]
-    simp only [MonoidHom.single_apply, ne_eq, Pi.mulSingle_eq_same]
+    simp only [MonoidHom.mulSingle_apply, ne_eq, Pi.mulSingle_eq_same]
     · intro j hj
       simp? at hj says simp only [mem_erase, ne_eq, mem_univ, and_true] at hj
-      simp only [MonoidHom.single_apply, Pi.mulSingle, Function.update, Eq.ndrec, Pi.one_apply,
+      simp only [MonoidHom.mulSingle_apply, Pi.mulSingle, Function.update, Eq.ndrec, Pi.one_apply,
         ne_eq, dite_eq_right_iff]
       intro h
       simp [*] at *
chore: update Std (#12210)

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

Diff
@@ -51,7 +51,7 @@ def noncommFoldr (s : Multiset α)
 @[simp]
 theorem noncommFoldr_coe (l : List α) (comm) (b : β) :
     noncommFoldr f (l : Multiset α) comm b = l.foldr f b := by
-  simp only [noncommFoldr, coe_foldr, coe_attach, List.attach, Function.comp]
+  simp only [noncommFoldr, coe_foldr, coe_attach, List.attach, List.attachWith, Function.comp]
   rw [← List.foldr_map]
   simp [List.map_pmap, List.pmap_eq_map]
 #align multiset.noncomm_foldr_coe Multiset.noncommFoldr_coe
feat: cons lemmas for Finset.noncommProd (#11194)

These are more general than the insert versions as they do not assume DecidableEq.

This also lets some later proofs be golfed.

Diff
@@ -309,19 +309,26 @@ theorem noncommProd_empty (f : α → β) (h) : noncommProd (∅ : Finset α) f
 #align finset.noncomm_prod_empty Finset.noncommProd_empty
 #align finset.noncomm_sum_empty Finset.noncommSum_empty
 
+@[to_additive (attr := simp)]
+theorem noncommProd_cons (s : Finset α) (a : α) (f : α → β)
+    (ha : a ∉ s) (comm) :
+    noncommProd (cons a s ha) f comm =
+      f a * noncommProd s f (comm.mono fun _ => Finset.mem_cons.2 ∘ .inr) := by
+  simp_rw [noncommProd, Finset.cons_val, Multiset.map_cons, Multiset.noncommProd_cons]
+
+@[to_additive]
+theorem noncommProd_cons' (s : Finset α) (a : α) (f : α → β)
+    (ha : a ∉ s) (comm) :
+    noncommProd (cons a s ha) f comm =
+      noncommProd s f (comm.mono fun _ => Finset.mem_cons.2 ∘ .inr) * f a := by
+  simp_rw [noncommProd, Finset.cons_val, Multiset.map_cons, Multiset.noncommProd_cons']
+
 @[to_additive (attr := simp)]
 theorem noncommProd_insert_of_not_mem [DecidableEq α] (s : Finset α) (a : α) (f : α → β) (comm)
     (ha : a ∉ s) :
     noncommProd (insert a s) f comm =
-      f a * noncommProd s f (comm.mono fun _ => mem_insert_of_mem) :=
-  calc noncommProd (insert a s) f comm
-     = Multiset.noncommProd ((insert a s).val.map f) _ := rfl
-   _ = Multiset.noncommProd (f a ::ₘ s.1.map f)
-     (by convert noncommProd_lemma _ f comm using 3
-         simp [@eq_comm _ (f a)]) := by
-       { congr
-         rw [insert_val_of_not_mem ha, Multiset.map_cons] }
-   _ = _ := by rw [Multiset.noncommProd_cons, noncommProd]
+      f a * noncommProd s f (comm.mono fun _ => mem_insert_of_mem) := by
+  simp only [← cons_eq_insert _ _ ha, noncommProd_cons]
 #align finset.noncomm_prod_insert_of_not_mem Finset.noncommProd_insert_of_not_mem
 #align finset.noncomm_sum_insert_of_not_mem Finset.noncommSum_insert_of_not_mem
 
@@ -329,15 +336,8 @@ theorem noncommProd_insert_of_not_mem [DecidableEq α] (s : Finset α) (a : α)
 theorem noncommProd_insert_of_not_mem' [DecidableEq α] (s : Finset α) (a : α) (f : α → β) (comm)
     (ha : a ∉ s) :
     noncommProd (insert a s) f comm =
-      noncommProd s f (comm.mono fun _ => mem_insert_of_mem) * f a :=
-  calc noncommProd (insert a s) f comm
-     = Multiset.noncommProd ((insert a s).val.map f) _ := rfl
-   _ = Multiset.noncommProd (f a ::ₘ s.1.map f)
-     (by convert noncommProd_lemma _ f comm using 3
-         simp [@eq_comm _ (f a)]) := by
-       { congr
-         rw [insert_val_of_not_mem ha, Multiset.map_cons] }
-   _ = _ := by rw [Multiset.noncommProd_cons', noncommProd]
+      noncommProd s f (comm.mono fun _ => mem_insert_of_mem) * f a := by
+  simp only [← cons_eq_insert _ _ ha, noncommProd_cons']
 #align finset.noncomm_prod_insert_of_not_mem' Finset.noncommProd_insert_of_not_mem'
 #align finset.noncomm_sum_insert_of_not_mem' Finset.noncommSum_insert_of_not_mem'
 
@@ -398,10 +398,9 @@ theorem noncommProd_erase_mul [DecidableEq α] (s : Finset α) {a : α} (h : a 
 @[to_additive]
 theorem noncommProd_eq_prod {β : Type*} [CommMonoid β] (s : Finset α) (f : α → β) :
     (noncommProd s f fun _ _ _ _ _ => Commute.all _ _) = s.prod f := by
-  classical
-    induction' s using Finset.induction_on with a s ha IH
-    · simp
-    · simp [ha, IH]
+  induction' s using Finset.cons_induction_on with a s ha IH
+  · simp
+  · simp [ha, IH]
 #align finset.noncomm_prod_eq_prod Finset.noncommProd_eq_prod
 #align finset.noncomm_sum_eq_sum Finset.noncommSum_eq_sum
 
@@ -444,20 +443,13 @@ theorem noncommProd_mul_distrib_aux {s : Finset α} {f : α → β} {g : α →
 theorem noncommProd_mul_distrib {s : Finset α} (f : α → β) (g : α → β) (comm_ff comm_gg comm_gf) :
     noncommProd s (f * g) (noncommProd_mul_distrib_aux comm_ff comm_gg comm_gf) =
       noncommProd s f comm_ff * noncommProd s g comm_gg := by
-  classical
-    induction' s using Finset.induction_on with x s hnmem ih
-    · simp
-    simp only [Finset.noncommProd_insert_of_not_mem _ _ _ _ hnmem]
-    specialize
-      ih (comm_ff.mono fun _ => mem_insert_of_mem) (comm_gg.mono fun _ => mem_insert_of_mem)
-        (comm_gf.mono fun _ => mem_insert_of_mem)
-    rw [ih, Pi.mul_apply]
-    simp only [mul_assoc]
-    congr 1
-    simp only [← mul_assoc]
-    congr 1
-    refine' noncommProd_commute _ _ _ _ fun y hy => _
-    exact comm_gf (mem_insert_self x s) (mem_insert_of_mem hy) (ne_of_mem_of_not_mem hy hnmem).symm
+  induction' s using Finset.cons_induction_on with x s hnmem ih
+  · simp
+  rw [Finset.noncommProd_cons, Finset.noncommProd_cons, Finset.noncommProd_cons, Pi.mul_apply,
+    ih (comm_ff.mono fun _ => mem_cons_of_mem) (comm_gg.mono fun _ => mem_cons_of_mem)
+      (comm_gf.mono fun _ => mem_cons_of_mem),
+    (noncommProd_commute _ _ _ _ fun y hy => ?_).mul_mul_mul_comm]
+  exact comm_gf (mem_cons_self x s) (mem_cons_of_mem hy) (ne_of_mem_of_not_mem hy hnmem).symm
 #align finset.noncomm_prod_mul_distrib Finset.noncommProd_mul_distrib
 #align finset.noncomm_sum_add_distrib Finset.noncommSum_add_distrib
 
refactor(Data/FunLike): use unbundled inheritance from FunLike (#8386)

The FunLike hierarchy is very big and gets scanned through each time we need a coercion (via the CoeFun instance). It looks like unbundled inheritance suits Lean 4 better here. The only class that still extends FunLike is EquivLike, since that has a custom coe_injective' field that is easier to implement. All other classes should take FunLike or EquivLike as a parameter.

Zulip thread

Important changes

Previously, morphism classes would be Type-valued and extend FunLike:

/-- `MyHomClass F A B` states that `F` is a type of `MyClass.op`-preserving morphisms.
You should extend this class when you extend `MyHom`. -/
class MyHomClass (F : Type*) (A B : outParam <| Type*) [MyClass A] [MyClass B]
  extends FunLike F A B :=
(map_op : ∀ (f : F) (x y : A), f (MyClass.op x y) = MyClass.op (f x) (f y))

After this PR, they should be Prop-valued and take FunLike as a parameter:

/-- `MyHomClass F A B` states that `F` is a type of `MyClass.op`-preserving morphisms.
You should extend this class when you extend `MyHom`. -/
class MyHomClass (F : Type*) (A B : outParam <| Type*) [MyClass A] [MyClass B]
  [FunLike F A B] : Prop :=
(map_op : ∀ (f : F) (x y : A), f (MyClass.op x y) = MyClass.op (f x) (f y))

(Note that A B stay marked as outParam even though they are not purely required to be so due to the FunLike parameter already filling them in. This is required to see through type synonyms, which is important in the category theory library. Also, I think keeping them as outParam is slightly faster.)

Similarly, MyEquivClass should take EquivLike as a parameter.

As a result, every mention of [MyHomClass F A B] should become [FunLike F A B] [MyHomClass F A B].

Remaining issues

Slower (failing) search

While overall this gives some great speedups, there are some cases that are noticeably slower. In particular, a failing application of a lemma such as map_mul is more expensive. This is due to suboptimal processing of arguments. For example:

variable [FunLike F M N] [Mul M] [Mul N] (f : F) (x : M) (y : M)

theorem map_mul [MulHomClass F M N] : f (x * y) = f x * f y

example [AddHomClass F A B] : f (x * y) = f x * f y := map_mul f _ _

Before this PR, applying map_mul f gives the goals [Mul ?M] [Mul ?N] [MulHomClass F ?M ?N]. Since M and N are out_params, [MulHomClass F ?M ?N] is synthesized first, supplies values for ?M and ?N and then the Mul M and Mul N instances can be found.

After this PR, the goals become [FunLike F ?M ?N] [Mul ?M] [Mul ?N] [MulHomClass F ?M ?N]. Now [FunLike F ?M ?N] is synthesized first, supplies values for ?M and ?N and then the Mul M and Mul N instances can be found, before trying MulHomClass F M N which fails. Since the Mul hierarchy is very big, this can be slow to fail, especially when there is no such Mul instance.

A long-term but harder to achieve solution would be to specify the order in which instance goals get solved. For example, we'd like to change the arguments to map_mul to look like [FunLike F M N] [Mul M] [Mul N] [highPriority <| MulHomClass F M N] because MulHomClass fails or succeeds much faster than the others.

As a consequence, the simpNF linter is much slower since by design it tries and fails to apply many map_ lemmas. The same issue occurs a few times in existing calls to simp [map_mul], where map_mul is tried "too soon" and fails. Thanks to the speedup of leanprover/lean4#2478 the impact is very limited, only in files that already were close to the timeout.

simp not firing sometimes

This affects map_smulₛₗ and related definitions. For simp lemmas Lean apparently uses a slightly different mechanism to find instances, so that rw can find every argument to map_smulₛₗ successfully but simp can't: leanprover/lean4#3701.

Missing instances due to unification failing

Especially in the category theory library, we might sometimes have a type A which is also accessible as a synonym (Bundled A hA).1. Instance synthesis doesn't always work if we have f : A →* B but x * y : (Bundled A hA).1 or vice versa. This seems to be mostly fixed by keeping A B as outParams in MulHomClass F A B. (Presumably because Lean will do a definitional check A =?= (Bundled A hA).1 instead of using the syntax in the discrimination tree.)

Workaround for issues

The timeouts can be worked around for now by specifying which map_mul we mean, either as map_mul f for some explicit f, or as e.g. MonoidHomClass.map_mul.

map_smulₛₗ not firing as simp lemma can be worked around by going back to the pre-FunLike situation and making LinearMap.map_smulₛₗ a simp lemma instead of the generic map_smulₛₗ. Writing simp [map_smulₛₗ _] also works.

Co-authored-by: Matthew Ballard <matt@mrb.email> Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Scott Morrison <scott@tqft.net> Co-authored-by: Anne Baanen <Vierkantor@users.noreply.github.com>

Diff
@@ -183,6 +183,8 @@ lemma noncommProd_induction (s : Multiset α) (comm)
   simp only [quot_mk_to_coe, noncommProd_coe, mem_coe] at base ⊢
   exact l.prod_induction p hom unit base
 
+variable [FunLike F α β]
+
 @[to_additive]
 protected theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
     (comm : { x | x ∈ s }.Pairwise Commute) (f : F) : { x | x ∈ s.map f }.Pairwise Commute := by
@@ -349,6 +351,8 @@ theorem noncommProd_singleton (a : α) (f : α → β) :
 #align finset.noncomm_prod_singleton Finset.noncommProd_singleton
 #align finset.noncomm_sum_singleton Finset.noncommSum_singleton
 
+variable [FunLike F β γ]
+
 @[to_additive]
 theorem noncommProd_map [MonoidHomClass F β γ] (s : Finset α) (f : α → β) (comm) (g : F) :
     g (s.noncommProd f comm) =
chore: move to v4.6.0-rc1, merging adaptations from bump/v4.6.0 (#10176)

Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Eric Wieser <wieser.eric@gmail.com> Co-authored-by: Joachim Breitner <mail@joachim-breitner.de>

Diff
@@ -75,7 +75,7 @@ theorem noncommFoldr_eq_foldr (s : Multiset α) (h : LeftCommutative f) (b : β)
 
 section assoc
 
-variable [assoc : IsAssociative α op]
+variable [assoc : Std.Associative op]
 
 /-- Fold of a `s : Multiset α` with an associative `op : α → α → α`, given a proofs that `op`
 is commutative on all elements `x ∈ s`. -/
@@ -100,8 +100,8 @@ theorem noncommFold_cons (s : Multiset α) (a : α) (h h') (x : α) :
   simp
 #align multiset.noncomm_fold_cons Multiset.noncommFold_cons
 
-theorem noncommFold_eq_fold (s : Multiset α) [IsCommutative α op] (a : α) :
-    noncommFold op s (fun x _ y _ _ => IsCommutative.comm x y) a = fold op a s := by
+theorem noncommFold_eq_fold (s : Multiset α) [Std.Commutative op] (a : α) :
+    noncommFold op s (fun x _ y _ _ => Std.Commutative.comm x y) a = fold op a s := by
   induction s using Quotient.inductionOn
   simp
 #align multiset.noncomm_fold_eq_fold Multiset.noncommFold_eq_fold
chore: move to v4.5.0-rc1, and merge changes from bump/v4.5.0 branch. (#9188)

This PR:

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

Diff
@@ -478,7 +478,7 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
       noncommProd_eq_pow_card (univ.erase i), one_pow, mul_one]
     simp only [MonoidHom.single_apply, ne_eq, Pi.mulSingle_eq_same]
     · intro j hj
-      simp? at hj says simp only [mem_univ, not_true_eq_false, mem_erase, ne_eq, and_true] at hj
+      simp? at hj says simp only [mem_erase, ne_eq, mem_univ, and_true] at hj
       simp only [MonoidHom.single_apply, Pi.mulSingle, Function.update, Eq.ndrec, Pi.one_apply,
         ne_eq, dite_eq_right_iff]
       intro h
chore: Remove nonterminal simp at (#7795)

Removes nonterminal uses of simp at. Replaces most of these with instances of simp? ... says.

Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Mario Carneiro <di.gama@gmail.com>

Diff
@@ -478,7 +478,7 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
       noncommProd_eq_pow_card (univ.erase i), one_pow, mul_one]
     simp only [MonoidHom.single_apply, ne_eq, Pi.mulSingle_eq_same]
     · intro j hj
-      simp at hj
+      simp? at hj says simp only [mem_univ, not_true_eq_false, mem_erase, ne_eq, and_true] at hj
       simp only [MonoidHom.single_apply, Pi.mulSingle, Function.update, Eq.ndrec, Pi.one_apply,
         ne_eq, dite_eq_right_iff]
       intro h
fix(Tactic/ToAdditive): handle AddCommute and AddSemiconjBy correctly (#8757)

This removes the need for many manual overrides, and corrects some bad names.

We have to make sure to leave function_commute and function_semiconjBy untouched.

Diff
@@ -217,7 +217,7 @@ theorem noncommProd_eq_prod {α : Type*} [CommMonoid α] (s : Multiset α) :
 #align multiset.noncomm_prod_eq_prod Multiset.noncommProd_eq_prod
 #align multiset.noncomm_sum_eq_sum Multiset.noncommSum_eq_sum
 
-@[to_additive noncommSum_addCommute]
+@[to_additive]
 theorem noncommProd_commute (s : Multiset α) (comm) (y : α) (h : ∀ x ∈ s, Commute y x) :
     Commute y (s.noncommProd comm) := by
   induction s using Quotient.inductionOn
@@ -366,7 +366,7 @@ theorem noncommProd_eq_pow_card (s : Finset α) (f : α → β) (comm) (m : β)
 #align finset.noncomm_prod_eq_pow_card Finset.noncommProd_eq_pow_card
 #align finset.noncomm_sum_eq_card_nsmul Finset.noncommSum_eq_card_nsmul
 
-@[to_additive noncommSum_addCommute]
+@[to_additive]
 theorem noncommProd_commute (s : Finset α) (f : α → β) (comm) (y : β)
     (h : ∀ x ∈ s, Commute y (f x)) : Commute y (s.noncommProd f comm) := by
   apply Multiset.noncommProd_commute
feat: expand Finset.noncommProd API (#8155)
Diff
@@ -175,6 +175,14 @@ theorem noncommProd_add (s t : Multiset α) (comm) :
 #align multiset.noncomm_prod_add Multiset.noncommProd_add
 #align multiset.noncomm_sum_add Multiset.noncommSum_add
 
+@[to_additive]
+lemma noncommProd_induction (s : Multiset α) (comm)
+    (p : α → Prop) (hom : ∀ a b, p a → p b → p (a * b)) (unit : p 1) (base : ∀ x ∈ s, p x) :
+    p (s.noncommProd comm) := by
+  induction' s using Quotient.inductionOn with l
+  simp only [quot_mk_to_coe, noncommProd_coe, mem_coe] at base ⊢
+  exact l.prod_induction p hom unit base
+
 @[to_additive]
 protected theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
     (comm : { x | x ∈ s }.Pairwise Commute) (f : F) : { x | x ∈ s.map f }.Pairwise Commute := by
@@ -218,6 +226,25 @@ theorem noncommProd_commute (s : Multiset α) (comm) (y : α) (h : ∀ x ∈ s,
 #align multiset.noncomm_prod_commute Multiset.noncommProd_commute
 #align multiset.noncomm_sum_add_commute Multiset.noncommSum_addCommute
 
+theorem mul_noncommProd_erase [DecidableEq α] (s : Multiset α) {a : α} (h : a ∈ s) (comm)
+    (comm' := fun x hx y hy hxy ↦ comm (s.mem_of_mem_erase hx) (s.mem_of_mem_erase hy) hxy) :
+    a * (s.erase a).noncommProd comm' = s.noncommProd comm := by
+  induction' s using Quotient.inductionOn with l
+  simp only [quot_mk_to_coe, mem_coe, coe_erase, noncommProd_coe] at comm h ⊢
+  suffices ∀ x ∈ l, ∀ y ∈ l, x * y = y * x by rw [List.prod_erase_of_comm h this]
+  intro x hx y hy
+  rcases eq_or_ne x y with rfl | hxy; rfl
+  exact comm hx hy hxy
+
+theorem noncommProd_erase_mul [DecidableEq α] (s : Multiset α) {a : α} (h : a ∈ s) (comm)
+    (comm' := fun x hx y hy hxy ↦ comm (s.mem_of_mem_erase hx) (s.mem_of_mem_erase hy) hxy) :
+    (s.erase a).noncommProd comm' * a = s.noncommProd comm := by
+  suffices ∀ b ∈ erase s a, Commute a b by
+    rw [← (noncommProd_commute (s.erase a) comm' a this).eq, mul_noncommProd_erase s h comm comm']
+  intro b hb
+  rcases eq_or_ne a b with rfl | hab; rfl
+  exact comm h (mem_of_mem_erase hb) hab
+
 end Multiset
 
 namespace Finset
@@ -245,6 +272,14 @@ def noncommProd (s : Finset α) (f : α → β)
 #align finset.noncomm_prod Finset.noncommProd
 #align finset.noncomm_sum Finset.noncommSum
 
+@[to_additive]
+lemma noncommProd_induction (s : Finset α) (f : α → β) (comm)
+    (p : β → Prop) (hom : ∀ a b, p a → p b → p (a * b)) (unit : p 1) (base : ∀ x ∈ s, p (f x)) :
+    p (s.noncommProd f comm) := by
+  refine Multiset.noncommProd_induction _ _ _ hom unit fun b hb ↦ ?_
+  obtain (⟨a, ha : a ∈ s, rfl : f a = b⟩) := by simpa using hb
+  exact base a ha
+
 @[to_additive (attr := congr)]
 theorem noncommProd_congr {s₁ s₂ : Finset α} {f g : α → β} (h₁ : s₁ = s₂)
     (h₂ : ∀ x ∈ s₂, f x = g x) (comm) :
@@ -342,6 +377,20 @@ theorem noncommProd_commute (s : Finset α) (f : α → β) (comm) (y : β)
 #align finset.noncomm_prod_commute Finset.noncommProd_commute
 #align finset.noncomm_sum_add_commute Finset.noncommSum_addCommute
 
+theorem mul_noncommProd_erase [DecidableEq α] (s : Finset α) {a : α} (h : a ∈ s) (f : α → β) (comm)
+    (comm' := fun x hx y hy hxy ↦ comm (s.mem_of_mem_erase hx) (s.mem_of_mem_erase hy) hxy) :
+    f a * (s.erase a).noncommProd f comm' = s.noncommProd f comm := by
+  classical
+  simpa only [← Multiset.map_erase_of_mem _ _ h] using
+    Multiset.mul_noncommProd_erase (s.1.map f) (Multiset.mem_map_of_mem f h) _
+
+theorem noncommProd_erase_mul [DecidableEq α] (s : Finset α) {a : α} (h : a ∈ s) (f : α → β) (comm)
+    (comm' := fun x hx y hy hxy ↦ comm (s.mem_of_mem_erase hx) (s.mem_of_mem_erase hy) hxy) :
+    (s.erase a).noncommProd f comm' * f a = s.noncommProd f comm := by
+  classical
+  simpa only [← Multiset.map_erase_of_mem _ _ h] using
+    Multiset.noncommProd_erase_mul (s.1.map f) (Multiset.mem_map_of_mem f h) _
+
 @[to_additive]
 theorem noncommProd_eq_prod {β : Type*} [CommMonoid β] (s : Finset α) (f : α → β) :
     (noncommProd s f fun _ _ _ _ _ => Commute.all _ _) = s.prod f := by
refactor(Algebra/Hom): transpose Hom and file name (#8095)

I believe the file defining a type of morphisms belongs alongside the file defining the structure this morphism works on. So I would like to reorganize the files in the Mathlib.Algebra.Hom folder so that e.g. Mathlib.Algebra.Hom.Ring becomes Mathlib.Algebra.Ring.Hom and Mathlib.Algebra.Hom.NonUnitalAlg becomes Mathlib.Algebra.Algebra.NonUnitalHom.

While fixing the imports I went ahead and sorted them for good luck.

The full list of changes is: renamed: Mathlib/Algebra/Hom/NonUnitalAlg.lean -> Mathlib/Algebra/Algebra/NonUnitalHom.lean renamed: Mathlib/Algebra/Hom/Aut.lean -> Mathlib/Algebra/Group/Aut.lean renamed: Mathlib/Algebra/Hom/Commute.lean -> Mathlib/Algebra/Group/Commute/Hom.lean renamed: Mathlib/Algebra/Hom/Embedding.lean -> Mathlib/Algebra/Group/Embedding.lean renamed: Mathlib/Algebra/Hom/Equiv/Basic.lean -> Mathlib/Algebra/Group/Equiv/Basic.lean renamed: Mathlib/Algebra/Hom/Equiv/TypeTags.lean -> Mathlib/Algebra/Group/Equiv/TypeTags.lean renamed: Mathlib/Algebra/Hom/Equiv/Units/Basic.lean -> Mathlib/Algebra/Group/Units/Equiv.lean renamed: Mathlib/Algebra/Hom/Equiv/Units/GroupWithZero.lean -> Mathlib/Algebra/GroupWithZero/Units/Equiv.lean renamed: Mathlib/Algebra/Hom/Freiman.lean -> Mathlib/Algebra/Group/Freiman.lean renamed: Mathlib/Algebra/Hom/Group/Basic.lean -> Mathlib/Algebra/Group/Hom/Basic.lean renamed: Mathlib/Algebra/Hom/Group/Defs.lean -> Mathlib/Algebra/Group/Hom/Defs.lean renamed: Mathlib/Algebra/Hom/GroupAction.lean -> Mathlib/GroupTheory/GroupAction/Hom.lean renamed: Mathlib/Algebra/Hom/GroupInstances.lean -> Mathlib/Algebra/Group/Hom/Instances.lean renamed: Mathlib/Algebra/Hom/Iterate.lean -> Mathlib/Algebra/GroupPower/IterateHom.lean renamed: Mathlib/Algebra/Hom/Centroid.lean -> Mathlib/Algebra/Ring/CentroidHom.lean renamed: Mathlib/Algebra/Hom/Ring/Basic.lean -> Mathlib/Algebra/Ring/Hom/Basic.lean renamed: Mathlib/Algebra/Hom/Ring/Defs.lean -> Mathlib/Algebra/Ring/Hom/Defs.lean renamed: Mathlib/Algebra/Hom/Units.lean -> Mathlib/Algebra/Group/Units/Hom.lean

Zulip thread: https://leanprover.zulipchat.com/#narrow/stream/287929-mathlib4/topic/Reorganizing.20.60Mathlib.2EAlgebra.2EHom.60

Diff
@@ -3,9 +3,9 @@ Copyright (c) 2021 Yakov Pechersky. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yakov Pechersky
 -/
-import Mathlib.Data.Fintype.Card
-import Mathlib.Algebra.Hom.Commute
 import Mathlib.Algebra.BigOperators.Basic
+import Mathlib.Algebra.Group.Commute.Hom
+import Mathlib.Data.Fintype.Card
 
 #align_import data.finset.noncomm_prod from "leanprover-community/mathlib"@"509de852e1de55e1efa8eacfa11df0823f26f226"
 
chore: remove nonterminal simp (#7580)

Removes nonterminal simps on lines looking like simp [...]

Diff
@@ -430,7 +430,8 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
     simp only [MonoidHom.single_apply, ne_eq, Pi.mulSingle_eq_same]
     · intro j hj
       simp at hj
-      simp [Pi.mulSingle, Function.update]
+      simp only [MonoidHom.single_apply, Pi.mulSingle, Function.update, Eq.ndrec, Pi.one_apply,
+        ne_eq, dite_eq_right_iff]
       intro h
       simp [*] at *
 #align finset.noncomm_prod_mul_single Finset.noncommProd_mul_single
chore: fix nonterminal simps (#7497)

Fixes the nonterminal simps identified by #7496

Diff
@@ -427,7 +427,7 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
   · intro j _; dsimp
   · rw [noncommProd_insert_of_not_mem _ _ _ _ (not_mem_erase _ _),
       noncommProd_eq_pow_card (univ.erase i), one_pow, mul_one]
-    simp
+    simp only [MonoidHom.single_apply, ne_eq, Pi.mulSingle_eq_same]
     · intro j hj
       simp at hj
       simp [Pi.mulSingle, Function.update]
chore: fix some cases in names (#7469)

And fix some names in comments where this revealed issues

Diff
@@ -353,7 +353,7 @@ theorem noncommProd_eq_prod {β : Type*} [CommMonoid β] (s : Finset α) (f : α
 #align finset.noncomm_sum_eq_sum Finset.noncommSum_eq_sum
 
 /-- The non-commutative version of `Finset.prod_union` -/
-@[to_additive "The non-commutative version of `finset.sum_union`"]
+@[to_additive "The non-commutative version of `Finset.sum_union`"]
 theorem noncommProd_union_of_disjoint [DecidableEq α] {s t : Finset α} (h : Disjoint s t)
     (f : α → β) (comm : { x | x ∈ s ∪ t }.Pairwise fun a b => Commute (f a) (f b)) :
     noncommProd (s ∪ t) f comm =
chore: bump toolchain to v4.2.0-rc1 (#7370)

This rolls in the changed from #6928.

Co-authored-by: Thomas Murrills <thomasmurrills@gmail.com>

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

Diff
@@ -417,10 +417,11 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
     (univ.noncommProd (fun i => Pi.mulSingle i (x i)) fun i _ j _ _ =>
         Pi.mulSingle_apply_commute x i j) = x := by
   ext i
-  apply (univ.noncommProd_map (fun i => MonoidHom.single M i (x i)) _ (Pi.evalMonoidHom M i)).trans
-  refine' (noncommProd_congr (insert_erase (mem_univ i)).symm _ _).trans _
-  · intro i _ j _ _
+  apply (univ.noncommProd_map (fun i => MonoidHom.single M i (x i)) ?a (Pi.evalMonoidHom M i)).trans
+  case a =>
+    intro i _ j _ _
     exact Pi.mulSingle_apply_commute x i j
+  refine' (noncommProd_congr (insert_erase (mem_univ i)).symm _ _).trans _
   · intro j
     exact Pi.mulSingle j (x j) i
   · intro j _; dsimp
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
@@ -33,7 +33,7 @@ elements is commutative and using the `Finset.prod` versions of lemmas to prove
 version.
 -/
 
-variable {F ι α β γ : Type _} (f : α → β → β) (op : α → α → α)
+variable {F ι α β γ : Type*} (f : α → β → β) (op : α → α → α)
 
 namespace Multiset
 
@@ -202,7 +202,7 @@ theorem noncommProd_eq_pow_card (s : Multiset α) (comm) (m : α) (h : ∀ x ∈
 #align multiset.noncomm_sum_eq_card_nsmul Multiset.noncommSum_eq_card_nsmul
 
 @[to_additive]
-theorem noncommProd_eq_prod {α : Type _} [CommMonoid α] (s : Multiset α) :
+theorem noncommProd_eq_prod {α : Type*} [CommMonoid α] (s : Multiset α) :
     (noncommProd s fun _ _ _ _ _ => Commute.all _ _) = prod s := by
   induction s using Quotient.inductionOn
   simp
@@ -343,7 +343,7 @@ theorem noncommProd_commute (s : Finset α) (f : α → β) (comm) (y : β)
 #align finset.noncomm_sum_add_commute Finset.noncommSum_addCommute
 
 @[to_additive]
-theorem noncommProd_eq_prod {β : Type _} [CommMonoid β] (s : Finset α) (f : α → β) :
+theorem noncommProd_eq_prod {β : Type*} [CommMonoid β] (s : Finset α) (f : α → β) :
     (noncommProd s f fun _ _ _ _ _ => Commute.all _ _) = s.prod f := by
   classical
     induction' s using Finset.induction_on with a s ha IH
@@ -410,7 +410,7 @@ theorem noncommProd_mul_distrib {s : Finset α} (f : α → β) (g : α → β)
 
 section FinitePi
 
-variable {M : ι → Type _} [∀ i, Monoid (M i)]
+variable {M : ι → Type*} [∀ i, Monoid (M i)]
 
 @[to_additive]
 theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
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,16 +2,13 @@
 Copyright (c) 2021 Yakov Pechersky. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yakov Pechersky
-
-! This file was ported from Lean 3 source module data.finset.noncomm_prod
-! leanprover-community/mathlib commit 509de852e1de55e1efa8eacfa11df0823f26f226
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathlib.Data.Fintype.Card
 import Mathlib.Algebra.Hom.Commute
 import Mathlib.Algebra.BigOperators.Basic
 
+#align_import data.finset.noncomm_prod from "leanprover-community/mathlib"@"509de852e1de55e1efa8eacfa11df0823f26f226"
+
 /-!
 # Products (respectively, sums) over a finset or a multiset.
 
chore: cleanup whitespace (#5988)

Grepping for [^ .:{-] [^ :] and reviewing the results. Once I started I couldn't stop. :-)

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

Diff
@@ -367,9 +367,9 @@ theorem noncommProd_union_of_disjoint [DecidableEq α] {s t : Finset α} (h : Di
   rw [List.disjoint_toFinset_iff_disjoint] at h
   calc noncommProd (List.toFinset sl ∪ List.toFinset tl) f comm
      = noncommProd ⟨↑(sl ++ tl), Multiset.coe_nodup.2 (sl'.append tl' h)⟩ f
-        (by convert comm; simp [Set.ext_iff]) := noncommProd_congr (by ext; simp) (by simp) _
-   _ =  noncommProd (List.toFinset sl) f (comm.mono <| coe_subset.2 <| subset_union_left _ _) *
-        noncommProd (List.toFinset tl) f (comm.mono <| coe_subset.2 <| subset_union_right _ _) :=
+         (by convert comm; simp [Set.ext_iff]) := noncommProd_congr (by ext; simp) (by simp) _
+   _ = noncommProd (List.toFinset sl) f (comm.mono <| coe_subset.2 <| subset_union_left _ _) *
+         noncommProd (List.toFinset tl) f (comm.mono <| coe_subset.2 <| subset_union_right _ _) :=
     by simp [noncommProd, List.dedup_eq_self.2 sl', List.dedup_eq_self.2 tl', h]
 #align finset.noncomm_prod_union_of_disjoint Finset.noncommProd_union_of_disjoint
 #align finset.noncomm_sum_union_of_disjoint Finset.noncommSum_union_of_disjoint
chore: fix focusing dots (#5708)

This PR is the result of running

find . -type f -name "*.lean" -exec sed -i -E 's/^( +)\. /\1· /' {} \;
find . -type f -name "*.lean" -exec sed -i -E 'N;s/^( +·)\n +(.*)$/\1 \2/;P;D' {} \;

which firstly replaces . focusing dots with · and secondly removes isolated instances of such dots, unifying them with the following line. A new rule is placed in the style linter to verify this.

Diff
@@ -422,15 +422,15 @@ theorem noncommProd_mul_single [Fintype ι] [DecidableEq ι] (x : ∀ i, M i) :
   ext i
   apply (univ.noncommProd_map (fun i => MonoidHom.single M i (x i)) _ (Pi.evalMonoidHom M i)).trans
   refine' (noncommProd_congr (insert_erase (mem_univ i)).symm _ _).trans _
-  . intro i _ j _ _
+  · intro i _ j _ _
     exact Pi.mulSingle_apply_commute x i j
-  . intro j
+  · intro j
     exact Pi.mulSingle j (x j) i
-  . intro j _; dsimp
-  . rw [noncommProd_insert_of_not_mem _ _ _ _ (not_mem_erase _ _),
+  · intro j _; dsimp
+  · rw [noncommProd_insert_of_not_mem _ _ _ _ (not_mem_erase _ _),
       noncommProd_eq_pow_card (univ.erase i), one_pow, mul_one]
     simp
-    . intro j hj
+    · intro j hj
       simp at hj
       simp [Pi.mulSingle, Function.update]
       intro h
chore: fix backtick in docs (#5077)

I wrote a script to find lines that contain an odd number of backticks

Diff
@@ -228,7 +228,7 @@ namespace Finset
 variable [Monoid β] [Monoid γ]
 
 
-/-- Proof used in definition of `Finset.noncommProd -/
+/-- Proof used in definition of `Finset.noncommProd` -/
 @[to_additive]
 theorem noncommProd_lemma (s : Finset α) (f : α → β)
     (comm : (s : Set α).Pairwise fun a b => Commute (f a) (f b)) :
chore: bye-bye, solo bys! (#3825)

This PR puts, with one exception, every single remaining by that lies all by itself on its own line to the previous line, thus matching the current behaviour of start-port.sh. The exception is when the by begins the second or later argument to a tuple or anonymous constructor; see https://github.com/leanprover-community/mathlib4/pull/3825#discussion_r1186702599.

Essentially this is s/\n *by$/ by/g, but with manual editing to satisfy the linter's max-100-char-line requirement. The Python style linter is also modified to catch these "isolated bys".

Diff
@@ -189,8 +189,7 @@ protected theorem noncommProd_map_aux [MonoidHomClass F α β] (s : Multiset α)
 
 @[to_additive]
 theorem noncommProd_map [MonoidHomClass F α β] (s : Multiset α) (comm) (f : F) :
-    f (s.noncommProd comm) = (s.map f).noncommProd (Multiset.noncommProd_map_aux s comm f) :=
-  by
+    f (s.noncommProd comm) = (s.map f).noncommProd (Multiset.noncommProd_map_aux s comm f) := by
   induction s using Quotient.inductionOn
   simpa using map_list_prod f _
 #align multiset.noncomm_prod_map Multiset.noncommProd_map
@@ -264,8 +263,7 @@ theorem noncommProd_congr {s₁ s₂ : Finset α} {f g : α → β} (h₁ : s₁
 
 @[to_additive (attr := simp)]
 theorem noncommProd_toFinset [DecidableEq α] (l : List α) (f : α → β) (comm) (hl : l.Nodup) :
-    noncommProd l.toFinset f comm = (l.map f).prod :=
-  by
+    noncommProd l.toFinset f comm = (l.map f).prod := by
   rw [← List.dedup_eq_self] at hl
   simp [noncommProd, hl]
 #align finset.noncomm_prod_to_finset Finset.noncommProd_toFinset
chore: fix #align lines (#3640)

This PR fixes two things:

  • Most align statements for definitions and theorems and instances that are separated by two newlines from the relevant declaration (s/\n\n#align/\n#align). This is often seen in the mathport output after ending calc blocks.
  • All remaining more-than-one-line #align statements. (This was needed for a script I wrote for #3630.)
Diff
@@ -290,7 +290,6 @@ theorem noncommProd_insert_of_not_mem [DecidableEq α] (s : Finset α) (a : α)
        { congr
          rw [insert_val_of_not_mem ha, Multiset.map_cons] }
    _ = _ := by rw [Multiset.noncommProd_cons, noncommProd]
-
 #align finset.noncomm_prod_insert_of_not_mem Finset.noncommProd_insert_of_not_mem
 #align finset.noncomm_sum_insert_of_not_mem Finset.noncommSum_insert_of_not_mem
 
feat: improvements to congr! and convert (#2606)
  • There is now configuration for congr!, convert, and convert_to to control parts of the congruence algorithm, in particular transparency settings when applying congruence lemmas.
  • congr! now applies congruence lemmas with reducible transparency by default. This prevents it from unfolding definitions when applying congruence lemmas. It also now tries both the LHS-biased and RHS-biased simp congruence lemmas, with a configuration option to set which it should try first.
  • There is now a new HEq congruence lemma generator that gives each hypothesis access to the proofs of previous hypotheses. This means that if you have an equality ⊢ ⟨a, x⟩ = ⟨b, y⟩ of sigma types, congr! turns this into goals ⊢ a = b and ⊢ a = b → HEq x y (note that congr! will also auto-introduce a = b for you in the second goal). This congruence lemma generator applies to more cases than the simp congruence lemma generator does.
  • congr! (and hence convert) are more careful about applying lemmas that don't force definitions to unfold. There were a number of cases in mathlib where the implementation of congr was being abused to unfold definitions.
  • With set_option trace.congr! true you can see what congr! sees when it is deciding on congruence lemmas.
  • There is also a bug fix in convert_to to do using 1 when there is no using clause, to match its documentation.

Note that congr! is more capable than congr at finding a way to equate left-hand sides and right-hand sides, so you will frequently need to limit its depth with a using clause. However, there is also a new heuristic to prevent considering unlikely-to-be-provable type equalities (controlled by the typeEqs option), which can help limit the depth automatically.

There is also a predefined configuration that you can invoke with, for example, convert (config := .unfoldSameFun) h, that causes it to behave more like congr, including using default transparency when unfolding.

Diff
@@ -285,7 +285,7 @@ theorem noncommProd_insert_of_not_mem [DecidableEq α] (s : Finset α) (a : α)
   calc noncommProd (insert a s) f comm
      = Multiset.noncommProd ((insert a s).val.map f) _ := rfl
    _ = Multiset.noncommProd (f a ::ₘ s.1.map f)
-     (by convert noncommProd_lemma _ f comm
+     (by convert noncommProd_lemma _ f comm using 3
          simp [@eq_comm _ (f a)]) := by
        { congr
          rw [insert_val_of_not_mem ha, Multiset.map_cons] }
@@ -302,7 +302,7 @@ theorem noncommProd_insert_of_not_mem' [DecidableEq α] (s : Finset α) (a : α)
   calc noncommProd (insert a s) f comm
      = Multiset.noncommProd ((insert a s).val.map f) _ := rfl
    _ = Multiset.noncommProd (f a ::ₘ s.1.map f)
-     (by convert noncommProd_lemma _ f comm
+     (by convert noncommProd_lemma _ f comm using 3
          simp [@eq_comm _ (f a)]) := by
        { congr
          rw [insert_val_of_not_mem ha, Multiset.map_cons] }
Fix: Move more attributes to the attr argument of to_additive (#2558)
Diff
@@ -249,7 +249,7 @@ def noncommProd (s : Finset α) (f : α → β)
 #align finset.noncomm_prod Finset.noncommProd
 #align finset.noncomm_sum Finset.noncommSum
 
-@[congr, to_additive]
+@[to_additive (attr := congr)]
 theorem noncommProd_congr {s₁ s₂ : Finset α} {f g : α → β} (h₁ : s₁ = s₂)
     (h₂ : ∀ x ∈ s₂, f x = g x) (comm) :
     noncommProd s₁ f comm =
feat: port Data.Finset.NoncommProd (#1681)

Co-authored-by: Chris Hughes <33847686+ChrisHughes24@users.noreply.github.com>

Dependencies 3 + 198

199 files ported (98.5%)
88149 lines ported (98.8%)
Show graph

The unported dependencies are