number_theory.legendre_symbol.mul_character
⟷
Mathlib.NumberTheory.LegendreSymbol.MulCharacter
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.
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(no changes)
(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)
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -454,7 +454,7 @@ theorem pow_apply_coe (χ : MulChar R R') (n : ℕ) (a : Rˣ) : (χ ^ n) a = χ
by
induction' n with n ih
· rw [pow_zero, pow_zero, one_apply_coe]
- · rw [pow_succ, pow_succ, mul_apply, ih]
+ · rw [pow_succ', pow_succ', mul_apply, ih]
#align mul_char.pow_apply_coe MulChar.pow_apply_coe
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -119,12 +119,14 @@ the value `1` on units. -/
@[simps]
noncomputable def trivial : MulChar R R'
where
- toFun := by classical
+ toFun := by classical exact fun x => if IsUnit x then 1 else 0
map_nonunit' := by intro a ha; simp only [ha, if_false]
map_one' := by simp only [isUnit_one, if_true]
map_mul' := by
intro x y
classical
+ simp only [IsUnit.mul_iff, boole_mul]
+ split_ifs <;> tauto
#align mul_char.trivial MulChar.trivial
-/
@@ -217,11 +219,22 @@ theorem coe_toUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(χ.toUnitHom a) = χ a
/-- Turn a homomorphism between unit groups into a `mul_char`. -/
noncomputable def ofUnitHom (f : Rˣ →* R'ˣ) : MulChar R R'
where
- toFun := by classical
+ toFun := by classical exact fun x => if hx : IsUnit x then f hx.Unit else 0
map_one' := by
have h1 : (is_unit_one.unit : Rˣ) = 1 := units.eq_iff.mp rfl
simp only [h1, dif_pos, Units.val_eq_one, map_one, isUnit_one]
- map_mul' := by classical
+ map_mul' := by
+ classical
+ intro x y
+ by_cases hx : IsUnit x
+ · simp only [hx, IsUnit.mul_iff, true_and_iff, dif_pos]
+ by_cases hy : IsUnit y
+ · simp only [hy, dif_pos]
+ have hm : (is_unit.mul_iff.mpr ⟨hx, hy⟩).Unit = hx.unit * hy.unit := units.eq_iff.mp rfl
+ rw [hm, map_mul]
+ norm_cast
+ · simp only [hy, not_false_iff, dif_neg, MulZeroClass.mul_zero]
+ · simp only [hx, IsUnit.mul_iff, false_and_iff, not_false_iff, dif_neg, MulZeroClass.zero_mul]
map_nonunit' := by intro a ha; simp only [ha, not_false_iff, dif_neg]
#align mul_char.of_unit_hom MulChar.ofUnitHom
-/
@@ -312,7 +325,7 @@ noncomputable instance inhabited : Inhabited (MulChar R R') :=
#print MulChar.one_apply_coe /-
/-- Evaluation of the trivial character -/
@[simp]
-theorem one_apply_coe (a : Rˣ) : (1 : MulChar R R') a = 1 := by classical
+theorem one_apply_coe (a : Rˣ) : (1 : MulChar R R') a = 1 := by classical exact dif_pos a.is_unit
#align mul_char.one_apply_coe MulChar.one_apply_coe
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/65a1391a0106c9204fe45bc73a039f056558cb83
@@ -119,14 +119,12 @@ the value `1` on units. -/
@[simps]
noncomputable def trivial : MulChar R R'
where
- toFun := by classical exact fun x => if IsUnit x then 1 else 0
+ toFun := by classical
map_nonunit' := by intro a ha; simp only [ha, if_false]
map_one' := by simp only [isUnit_one, if_true]
map_mul' := by
intro x y
classical
- simp only [IsUnit.mul_iff, boole_mul]
- split_ifs <;> tauto
#align mul_char.trivial MulChar.trivial
-/
@@ -219,22 +217,11 @@ theorem coe_toUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(χ.toUnitHom a) = χ a
/-- Turn a homomorphism between unit groups into a `mul_char`. -/
noncomputable def ofUnitHom (f : Rˣ →* R'ˣ) : MulChar R R'
where
- toFun := by classical exact fun x => if hx : IsUnit x then f hx.Unit else 0
+ toFun := by classical
map_one' := by
have h1 : (is_unit_one.unit : Rˣ) = 1 := units.eq_iff.mp rfl
simp only [h1, dif_pos, Units.val_eq_one, map_one, isUnit_one]
- map_mul' := by
- classical
- intro x y
- by_cases hx : IsUnit x
- · simp only [hx, IsUnit.mul_iff, true_and_iff, dif_pos]
- by_cases hy : IsUnit y
- · simp only [hy, dif_pos]
- have hm : (is_unit.mul_iff.mpr ⟨hx, hy⟩).Unit = hx.unit * hy.unit := units.eq_iff.mp rfl
- rw [hm, map_mul]
- norm_cast
- · simp only [hy, not_false_iff, dif_neg, MulZeroClass.mul_zero]
- · simp only [hx, IsUnit.mul_iff, false_and_iff, not_false_iff, dif_neg, MulZeroClass.zero_mul]
+ map_mul' := by classical
map_nonunit' := by intro a ha; simp only [ha, not_false_iff, dif_neg]
#align mul_char.of_unit_hom MulChar.ofUnitHom
-/
@@ -325,7 +312,7 @@ noncomputable instance inhabited : Inhabited (MulChar R R') :=
#print MulChar.one_apply_coe /-
/-- Evaluation of the trivial character -/
@[simp]
-theorem one_apply_coe (a : Rˣ) : (1 : MulChar R R') a = 1 := by classical exact dif_pos a.is_unit
+theorem one_apply_coe (a : Rˣ) : (1 : MulChar R R') a = 1 := by classical
#align mul_char.one_apply_coe MulChar.one_apply_coe
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/b1abe23ae96fef89ad30d9f4362c307f72a55010
@@ -502,7 +502,7 @@ def IsNontrivial (χ : MulChar R R') : Prop :=
#print MulChar.isNontrivial_iff /-
/-- A multiplicative character is nontrivial iff it is not the trivial character. -/
theorem isNontrivial_iff (χ : MulChar R R') : χ.IsNontrivial ↔ χ ≠ 1 := by
- simp only [is_nontrivial, Ne.def, ext_iff, not_forall, one_apply_coe]
+ simp only [is_nontrivial, Ne.def, ext_iff, Classical.not_forall, one_apply_coe]
#align mul_char.is_nontrivial_iff MulChar.isNontrivial_iff
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/ce64cd319bb6b3e82f31c2d38e79080d377be451
@@ -3,9 +3,9 @@ Copyright (c) 2022 Michael Stoll. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Michael Stoll
-/
-import Mathbin.Algebra.CharP.Basic
-import Mathbin.Algebra.EuclideanDomain.Instances
-import Mathbin.Data.Fintype.Units
+import Algebra.CharP.Basic
+import Algebra.EuclideanDomain.Instances
+import Data.Fintype.Units
#align_import number_theory.legendre_symbol.mul_character from "leanprover-community/mathlib"@"33c67ae661dd8988516ff7f247b0be3018cdd952"
mathlib commit https://github.com/leanprover-community/mathlib/commit/32a7e535287f9c73f2e4d2aef306a39190f0b504
@@ -164,7 +164,7 @@ instance : MulCharClass (MulChar R R') R R'
where
coe χ := χ.toMonoidHom.toFun
coe_injective' f g h := ext' fun a => congr_fun h a
- map_mul χ := χ.map_mul'
+ map_hMul χ := χ.map_mul'
map_one χ := χ.map_one'
map_nonunit χ := χ.map_nonunit'
@@ -440,7 +440,7 @@ noncomputable instance commGroup : CommGroup (MulChar R R') :=
{ one := 1
mul := (· * ·)
inv := Inv.inv
- mul_left_inv := inv_mul
+ hMul_left_inv := inv_mul
mul_assoc := by intro χ₁ χ₂ χ₃; ext a; simp [mul_assoc]
mul_comm := by intro χ₁ χ₂; ext a; simp [mul_comm]
one_mul
mathlib commit https://github.com/leanprover-community/mathlib/commit/8ea5598db6caeddde6cb734aa179cc2408dbd345
@@ -2,16 +2,13 @@
Copyright (c) 2022 Michael Stoll. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Michael Stoll
-
-! This file was ported from Lean 3 source module number_theory.legendre_symbol.mul_character
-! leanprover-community/mathlib commit 33c67ae661dd8988516ff7f247b0be3018cdd952
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
-/
import Mathbin.Algebra.CharP.Basic
import Mathbin.Algebra.EuclideanDomain.Instances
import Mathbin.Data.Fintype.Units
+#align_import number_theory.legendre_symbol.mul_character from "leanprover-community/mathlib"@"33c67ae661dd8988516ff7f247b0be3018cdd952"
+
/-!
# Multiplicative characters of finite rings and fields
mathlib commit https://github.com/leanprover-community/mathlib/commit/fdc286cc6967a012f41b87f76dcd2797b53152af
@@ -101,18 +101,14 @@ variable {R : Type u} [CommMonoid R]
-- The target
variable {R' : Type v} [CommMonoidWithZero R']
-#print MulChar.coeToFun /-
instance coeToFun : CoeFun (MulChar R R') fun _ => R → R' :=
⟨fun χ => χ.toFun⟩
#align mul_char.coe_to_fun MulChar.coeToFun
--/
-#print MulChar.Simps.apply /-
/-- See note [custom simps projection] -/
protected def Simps.apply (χ : MulChar R R') : R → R' :=
χ
#align mul_char.simps.apply MulChar.Simps.apply
--/
initialize_simps_projections MulChar (to_monoid_hom_to_fun → apply, -toMonoidHom)
@@ -139,19 +135,15 @@ noncomputable def trivial : MulChar R R'
end trivial
-#print MulChar.coe_coe /-
@[simp]
theorem coe_coe (χ : MulChar R R') : (χ.toMonoidHom : R → R') = χ :=
rfl
#align mul_char.coe_coe MulChar.coe_coe
--/
-#print MulChar.toFun_eq_coe /-
@[simp]
theorem toFun_eq_coe (χ : MulChar R R') : χ.toFun = χ :=
rfl
#align mul_char.to_fun_eq_coe MulChar.toFun_eq_coe
--/
#print MulChar.coe_mk /-
@[simp]
mathlib commit https://github.com/leanprover-community/mathlib/commit/9fb8964792b4237dac6200193a0d533f1b3f7423
@@ -139,20 +139,26 @@ noncomputable def trivial : MulChar R R'
end trivial
+#print MulChar.coe_coe /-
@[simp]
theorem coe_coe (χ : MulChar R R') : (χ.toMonoidHom : R → R') = χ :=
rfl
#align mul_char.coe_coe MulChar.coe_coe
+-/
+#print MulChar.toFun_eq_coe /-
@[simp]
theorem toFun_eq_coe (χ : MulChar R R') : χ.toFun = χ :=
rfl
#align mul_char.to_fun_eq_coe MulChar.toFun_eq_coe
+-/
+#print MulChar.coe_mk /-
@[simp]
theorem coe_mk (f : R →* R') (hf) : (MulChar.mk f hf : R → R') = f :=
rfl
#align mul_char.coe_mk MulChar.coe_mk
+-/
#print MulChar.ext' /-
/-- Extensionality. See `ext` below for the version that will actually be used. -/
@@ -173,9 +179,11 @@ instance : MulCharClass (MulChar R R') R R'
map_one χ := χ.map_one'
map_nonunit χ := χ.map_nonunit'
+#print MulChar.map_nonunit /-
theorem map_nonunit (χ : MulChar R R') {a : R} (ha : ¬IsUnit a) : χ a = 0 :=
χ.map_nonunit' a ha
#align mul_char.map_nonunit MulChar.map_nonunit
+-/
#print MulChar.ext /-
/-- Extensionality. Since `mul_char`s always take the value zero on non-units, it is sufficient
@@ -205,15 +213,20 @@ between `mul_char R R'` and `Rˣ →* R'ˣ`.
-/
+#print MulChar.toUnitHom /-
/-- Turn a `mul_char` into a homomorphism between the unit groups. -/
def toUnitHom (χ : MulChar R R') : Rˣ →* R'ˣ :=
Units.map χ
#align mul_char.to_unit_hom MulChar.toUnitHom
+-/
+#print MulChar.coe_toUnitHom /-
theorem coe_toUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(χ.toUnitHom a) = χ a :=
rfl
#align mul_char.coe_to_unit_hom MulChar.coe_toUnitHom
+-/
+#print MulChar.ofUnitHom /-
/-- Turn a homomorphism between unit groups into a `mul_char`. -/
noncomputable def ofUnitHom (f : Rˣ →* R'ˣ) : MulChar R R'
where
@@ -235,10 +248,14 @@ noncomputable def ofUnitHom (f : Rˣ →* R'ˣ) : MulChar R R'
· simp only [hx, IsUnit.mul_iff, false_and_iff, not_false_iff, dif_neg, MulZeroClass.zero_mul]
map_nonunit' := by intro a ha; simp only [ha, not_false_iff, dif_neg]
#align mul_char.of_unit_hom MulChar.ofUnitHom
+-/
+#print MulChar.ofUnitHom_coe /-
theorem ofUnitHom_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : of_unit_hom f ↑a = f a := by simp [of_unit_hom]
#align mul_char.of_unit_hom_coe MulChar.ofUnitHom_coe
+-/
+#print MulChar.equivToUnitHom /-
/-- The equivalence between multiplicative characters and homomorphisms of unit groups. -/
noncomputable def equivToUnitHom : MulChar R R' ≃ (Rˣ →* R'ˣ)
where
@@ -247,26 +264,35 @@ noncomputable def equivToUnitHom : MulChar R R' ≃ (Rˣ →* R'ˣ)
left_inv := by intro χ; ext x; rw [of_unit_hom_coe, coe_to_unit_hom]
right_inv := by intro f; ext x; rw [coe_to_unit_hom, of_unit_hom_coe]
#align mul_char.equiv_to_unit_hom MulChar.equivToUnitHom
+-/
+#print MulChar.toUnitHom_eq /-
@[simp]
theorem toUnitHom_eq (χ : MulChar R R') : to_unit_hom χ = equiv_to_unit_hom χ :=
rfl
#align mul_char.to_unit_hom_eq MulChar.toUnitHom_eq
+-/
+#print MulChar.ofUnitHom_eq /-
@[simp]
theorem ofUnitHom_eq (χ : Rˣ →* R'ˣ) : of_unit_hom χ = equiv_to_unit_hom.symm χ :=
rfl
#align mul_char.of_unit_hom_eq MulChar.ofUnitHom_eq
+-/
+#print MulChar.coe_equivToUnitHom /-
@[simp]
theorem coe_equivToUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(equiv_to_unit_hom χ a) = χ a :=
coe_to_unit_hom χ a
#align mul_char.coe_equiv_to_unit_hom MulChar.coe_equivToUnitHom
+-/
+#print MulChar.equivToUnitHom_symm_coe /-
@[simp]
theorem equivToUnitHom_symm_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : equiv_to_unit_hom.symm f ↑a = f a :=
of_unit_hom_coe f a
#align mul_char.equiv_unit_hom_symm_coe MulChar.equivToUnitHom_symm_coe
+-/
/-!
### Commutative group structure on multiplicative characters
@@ -275,19 +301,25 @@ The multiplicative characters `R → R'` form a commutative group.
-/
+#print MulChar.map_one /-
protected theorem map_one (χ : MulChar R R') : χ (1 : R) = 1 :=
χ.map_one'
#align mul_char.map_one MulChar.map_one
+-/
+#print MulChar.map_zero /-
/-- If the domain has a zero (and is nontrivial), then `χ 0 = 0`. -/
protected theorem map_zero {R : Type u} [CommMonoidWithZero R] [Nontrivial R] (χ : MulChar R R') :
χ (0 : R) = 0 := by rw [map_nonunit χ not_isUnit_zero]
#align mul_char.map_zero MulChar.map_zero
+-/
+#print MulChar.map_ringChar /-
/-- If the domain is a ring `R`, then `χ (ring_char R) = 0`. -/
theorem map_ringChar {R : Type u} [CommRing R] [Nontrivial R] (χ : MulChar R R') :
χ (ringChar R) = 0 := by rw [ringChar.Nat.cast_ringChar, χ.map_zero]
#align mul_char.map_ring_char MulChar.map_ringChar
+-/
#print MulChar.hasOne /-
noncomputable instance hasOne : One (MulChar R R') :=
@@ -301,10 +333,12 @@ noncomputable instance inhabited : Inhabited (MulChar R R') :=
#align mul_char.inhabited MulChar.inhabited
-/
+#print MulChar.one_apply_coe /-
/-- Evaluation of the trivial character -/
@[simp]
theorem one_apply_coe (a : Rˣ) : (1 : MulChar R R') a = 1 := by classical exact dif_pos a.is_unit
#align mul_char.one_apply_coe MulChar.one_apply_coe
+-/
#print MulChar.mul /-
/-- Multiplication of multiplicative characters. (This needs the target to be commutative.) -/
@@ -321,14 +355,18 @@ instance hasMul : Mul (MulChar R R') :=
#align mul_char.has_mul MulChar.hasMul
-/
+#print MulChar.mul_apply /-
theorem mul_apply (χ χ' : MulChar R R') (a : R) : (χ * χ') a = χ a * χ' a :=
rfl
#align mul_char.mul_apply MulChar.mul_apply
+-/
+#print MulChar.coeToFun_mul /-
@[simp]
theorem coeToFun_mul (χ χ' : MulChar R R') : ⇑(χ * χ') = χ * χ' :=
rfl
#align mul_char.coe_to_fun_mul MulChar.coeToFun_mul
+-/
#print MulChar.one_mul /-
protected theorem one_mul (χ : MulChar R R') : (1 : MulChar R R') * χ = χ := by ext; simp
@@ -364,11 +402,13 @@ theorem inv_apply_eq_inv (χ : MulChar R R') (a : R) : χ⁻¹ a = Ring.inverse
#align mul_char.inv_apply_eq_inv MulChar.inv_apply_eq_inv
-/
+#print MulChar.inv_apply_eq_inv' /-
/-- The inverse of a multiplicative character `χ`, applied to `a`, is the inverse of `χ a`.
Variant when the target is a field -/
theorem inv_apply_eq_inv' {R' : Type v} [Field R'] (χ : MulChar R R') (a : R) : χ⁻¹ a = (χ a)⁻¹ :=
(inv_apply_eq_inv χ a).trans <| Ring.inverse_eq_inv (χ a)
#align mul_char.inv_apply_eq_inv' MulChar.inv_apply_eq_inv'
+-/
#print MulChar.inv_apply /-
/-- When the domain has a zero, then the inverse of a multiplicative character `χ`,
@@ -386,11 +426,13 @@ theorem inv_apply {R : Type u} [CommMonoidWithZero R] (χ : MulChar R R') (a : R
#align mul_char.inv_apply MulChar.inv_apply
-/
+#print MulChar.inv_apply' /-
/-- When the domain has a zero, then the inverse of a multiplicative character `χ`,
applied to `a`, is `χ` applied to the inverse of `a`. -/
theorem inv_apply' {R : Type u} [Field R] (χ : MulChar R R') (a : R) : χ⁻¹ a = χ a⁻¹ :=
(inv_apply χ a).trans <| congr_arg _ (Ring.inverse_eq_inv a)
#align mul_char.inv_apply' MulChar.inv_apply'
+-/
#print MulChar.inv_mul /-
/-- The product of a character with its inverse is the trivial character. -/
@@ -482,6 +524,7 @@ def IsQuadratic (χ : MulChar R R') : Prop :=
#align mul_char.is_quadratic MulChar.IsQuadratic
-/
+#print MulChar.IsQuadratic.eq_of_eq_coe /-
/-- If two values of quadratic characters with target `ℤ` agree after coercion into a ring
of characteristic not `2`, then they agree in `ℤ`. -/
theorem IsQuadratic.eq_of_eq_coe {χ : MulChar R ℤ} (hχ : IsQuadratic χ) {χ' : MulChar R' ℤ}
@@ -489,6 +532,7 @@ theorem IsQuadratic.eq_of_eq_coe {χ : MulChar R ℤ} (hχ : IsQuadratic χ) {χ
(h : (χ a : R'') = χ' a') : χ a = χ' a' :=
Int.cast_injOn_of_ringChar_ne_two hR'' (hχ a) (hχ' a') h
#align mul_char.is_quadratic.eq_of_eq_coe MulChar.IsQuadratic.eq_of_eq_coe
+-/
#print MulChar.ringHomComp /-
/-- We can post-compose a multiplicative character with a ring homomorphism. -/
@@ -501,6 +545,7 @@ def ringHomComp (χ : MulChar R R') (f : R' →+* R'') : MulChar R R'' :=
#align mul_char.ring_hom_comp MulChar.ringHomComp
-/
+#print MulChar.IsNontrivial.comp /-
/-- Composition with an injective ring homomorphism preserves nontriviality. -/
theorem IsNontrivial.comp {χ : MulChar R R'} (hχ : χ.IsNontrivial) {f : R' →+* R''}
(hf : Function.Injective f) : (χ.ringHomComp f).IsNontrivial :=
@@ -510,6 +555,7 @@ theorem IsNontrivial.comp {χ : MulChar R R'} (hχ : χ.IsNontrivial) {f : R'
rw [ring_hom_comp_apply, ← RingHom.map_one f]
exact fun h => ha (hf h)
#align mul_char.is_nontrivial.comp MulChar.IsNontrivial.comp
+-/
#print MulChar.IsQuadratic.comp /-
/-- Composition with a ring homomorphism preserves the property of being a quadratic character. -/
@@ -543,6 +589,7 @@ theorem IsQuadratic.sq_eq_one {χ : MulChar R R'} (hχ : χ.IsQuadratic) : χ ^
#align mul_char.is_quadratic.sq_eq_one MulChar.IsQuadratic.sq_eq_one
-/
+#print MulChar.IsQuadratic.pow_char /-
/-- The `p`th power of a quadratic character is itself, when `p` is the (prime) characteristic
of the target ring. -/
theorem IsQuadratic.pow_char {χ : MulChar R R'} (hχ : χ.IsQuadratic) (p : ℕ) [hp : Fact p.Prime]
@@ -554,6 +601,7 @@ theorem IsQuadratic.pow_char {χ : MulChar R R'} (hχ : χ.IsQuadratic) (p : ℕ
· rw [one_pow]
· exact CharP.neg_one_pow_char R' p
#align mul_char.is_quadratic.pow_char MulChar.IsQuadratic.pow_char
+-/
#print MulChar.IsQuadratic.pow_even /-
/-- The `n`th power of a quadratic character is the trivial character, when `n` is even. -/
@@ -575,6 +623,7 @@ theorem IsQuadratic.pow_odd {χ : MulChar R R'} (hχ : χ.IsQuadratic) {n : ℕ}
open scoped BigOperators
+#print MulChar.IsNontrivial.sum_eq_zero /-
/-- The sum over all values of a nontrivial multiplicative character on a finite ring is zero
(when the target is a domain). -/
theorem IsNontrivial.sum_eq_zero [Fintype R] [IsDomain R'] {χ : MulChar R R'}
@@ -585,7 +634,9 @@ theorem IsNontrivial.sum_eq_zero [Fintype R] [IsDomain R'] {χ : MulChar R R'}
simp only [Finset.mul_sum, ← map_mul]
exact Fintype.sum_bijective _ (Units.mulLeft_bijective b) _ _ fun x => rfl
#align mul_char.is_nontrivial.sum_eq_zero MulChar.IsNontrivial.sum_eq_zero
+-/
+#print MulChar.sum_one_eq_card_units /-
/-- The sum over all values of the trivial multiplicative character on a finite ring is
the cardinality of its unit group. -/
theorem sum_one_eq_card_units [Fintype R] [DecidableEq R] :
@@ -605,6 +656,7 @@ theorem sum_one_eq_card_units [Fintype R] [DecidableEq R] :
simp only [Finset.mem_filter, Finset.mem_univ, true_and_iff, Finset.mem_map,
Function.Embedding.coeFn_mk, exists_true_left, IsUnit]
#align mul_char.sum_one_eq_card_units MulChar.sum_one_eq_card_units
+-/
end MulChar
mathlib commit https://github.com/leanprover-community/mathlib/commit/a3e83f0fa4391c8740f7d773a7a9b74e311ae2a3
@@ -578,7 +578,7 @@ open scoped BigOperators
/-- The sum over all values of a nontrivial multiplicative character on a finite ring is zero
(when the target is a domain). -/
theorem IsNontrivial.sum_eq_zero [Fintype R] [IsDomain R'] {χ : MulChar R R'}
- (hχ : χ.IsNontrivial) : (∑ a, χ a) = 0 :=
+ (hχ : χ.IsNontrivial) : ∑ a, χ a = 0 :=
by
rcases hχ with ⟨b, hb⟩
refine' eq_zero_of_mul_eq_self_left hb _
@@ -589,10 +589,10 @@ theorem IsNontrivial.sum_eq_zero [Fintype R] [IsDomain R'] {χ : MulChar R R'}
/-- The sum over all values of the trivial multiplicative character on a finite ring is
the cardinality of its unit group. -/
theorem sum_one_eq_card_units [Fintype R] [DecidableEq R] :
- (∑ a, (1 : MulChar R R') a) = Fintype.card Rˣ :=
+ ∑ a, (1 : MulChar R R') a = Fintype.card Rˣ :=
by
calc
- (∑ a, (1 : MulChar R R') a) = ∑ a : R, if IsUnit a then 1 else 0 :=
+ ∑ a, (1 : MulChar R R') a = ∑ a : R, if IsUnit a then 1 else 0 :=
Finset.sum_congr rfl fun a _ => _
_ = ((Finset.univ : Finset R).filterₓ IsUnit).card := Finset.sum_boole
_ = (finset.univ.map ⟨(coe : Rˣ → R), Units.ext⟩).card := _
mathlib commit https://github.com/leanprover-community/mathlib/commit/7e5137f579de09a059a5ce98f364a04e221aabf0
@@ -597,7 +597,6 @@ theorem sum_one_eq_card_units [Fintype R] [DecidableEq R] :
_ = ((Finset.univ : Finset R).filterₓ IsUnit).card := Finset.sum_boole
_ = (finset.univ.map ⟨(coe : Rˣ → R), Units.ext⟩).card := _
_ = Fintype.card Rˣ := congr_arg _ (Finset.card_map _)
-
· split_ifs with h h
· exact one_apply_coe h.unit
· exact map_nonunit _ h
mathlib commit https://github.com/leanprover-community/mathlib/commit/5f25c089cb34db4db112556f23c50d12da81b297
@@ -132,8 +132,8 @@ noncomputable def trivial : MulChar R R'
map_mul' := by
intro x y
classical
- simp only [IsUnit.mul_iff, boole_mul]
- split_ifs <;> tauto
+ simp only [IsUnit.mul_iff, boole_mul]
+ split_ifs <;> tauto
#align mul_char.trivial MulChar.trivial
-/
@@ -223,16 +223,16 @@ noncomputable def ofUnitHom (f : Rˣ →* R'ˣ) : MulChar R R'
simp only [h1, dif_pos, Units.val_eq_one, map_one, isUnit_one]
map_mul' := by
classical
- intro x y
- by_cases hx : IsUnit x
- · simp only [hx, IsUnit.mul_iff, true_and_iff, dif_pos]
- by_cases hy : IsUnit y
- · simp only [hy, dif_pos]
- have hm : (is_unit.mul_iff.mpr ⟨hx, hy⟩).Unit = hx.unit * hy.unit := units.eq_iff.mp rfl
- rw [hm, map_mul]
- norm_cast
- · simp only [hy, not_false_iff, dif_neg, MulZeroClass.mul_zero]
- · simp only [hx, IsUnit.mul_iff, false_and_iff, not_false_iff, dif_neg, MulZeroClass.zero_mul]
+ intro x y
+ by_cases hx : IsUnit x
+ · simp only [hx, IsUnit.mul_iff, true_and_iff, dif_pos]
+ by_cases hy : IsUnit y
+ · simp only [hy, dif_pos]
+ have hm : (is_unit.mul_iff.mpr ⟨hx, hy⟩).Unit = hx.unit * hy.unit := units.eq_iff.mp rfl
+ rw [hm, map_mul]
+ norm_cast
+ · simp only [hy, not_false_iff, dif_neg, MulZeroClass.mul_zero]
+ · simp only [hx, IsUnit.mul_iff, false_and_iff, not_false_iff, dif_neg, MulZeroClass.zero_mul]
map_nonunit' := by intro a ha; simp only [ha, not_false_iff, dif_neg]
#align mul_char.of_unit_hom MulChar.ofUnitHom
mathlib commit https://github.com/leanprover-community/mathlib/commit/cca40788df1b8755d5baf17ab2f27dacc2e17acb
@@ -82,7 +82,7 @@ structure MulChar extends MonoidHom R R' where
#print MulCharClass /-
/-- This is the corresponding extension of `monoid_hom_class`. -/
class MulCharClass (F : Type _) (R R' : outParam <| Type _) [CommMonoid R]
- [CommMonoidWithZero R'] extends MonoidHomClass F R R' where
+ [CommMonoidWithZero R'] extends MonoidHomClass F R R' where
map_nonunit : ∀ (χ : F) {a : R} (ha : ¬IsUnit a), χ a = 0
#align mul_char_class MulCharClass
-/
mathlib commit https://github.com/leanprover-community/mathlib/commit/cca40788df1b8755d5baf17ab2f27dacc2e17acb
@@ -264,9 +264,9 @@ theorem coe_equivToUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(equiv_to_unit_hom
#align mul_char.coe_equiv_to_unit_hom MulChar.coe_equivToUnitHom
@[simp]
-theorem equiv_unit_hom_symm_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : equiv_to_unit_hom.symm f ↑a = f a :=
+theorem equivToUnitHom_symm_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : equiv_to_unit_hom.symm f ↑a = f a :=
of_unit_hom_coe f a
-#align mul_char.equiv_unit_hom_symm_coe MulChar.equiv_unit_hom_symm_coe
+#align mul_char.equiv_unit_hom_symm_coe MulChar.equivToUnitHom_symm_coe
/-!
### Commutative group structure on multiplicative characters
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -573,7 +573,7 @@ theorem IsQuadratic.pow_odd {χ : MulChar R R'} (hχ : χ.IsQuadratic) {n : ℕ}
#align mul_char.is_quadratic.pow_odd MulChar.IsQuadratic.pow_odd
-/
-open BigOperators
+open scoped BigOperators
/-- The sum over all values of a nontrivial multiplicative character on a finite ring is zero
(when the target is a domain). -/
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -139,34 +139,16 @@ noncomputable def trivial : MulChar R R'
end trivial
-/- warning: mul_char.coe_coe -> MulChar.coe_coe is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} ((fun (_x : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => R -> R') (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ)) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => R -> R') (MonoidHom.hasCoeToFun.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ)
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (forall (a : R), (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : R) => R') a) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R (fun (_x : R) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : R) => R') _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (MulOneClass.toMul.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ)) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ)
-Case conversion may be inaccurate. Consider using '#align mul_char.coe_coe MulChar.coe_coeₓ'. -/
@[simp]
theorem coe_coe (χ : MulChar R R') : (χ.toMonoidHom : R → R') = χ :=
rfl
#align mul_char.coe_coe MulChar.coe_coe
-/- warning: mul_char.to_fun_eq_coe -> MulChar.toFun_eq_coe is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (R -> R') (MonoidHom.toFun.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ)
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (R -> R') (OneHom.toFun.{u1, u2} R R' (MulOneClass.toOne.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toOne.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.toOneHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ))) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ)
-Case conversion may be inaccurate. Consider using '#align mul_char.to_fun_eq_coe MulChar.toFun_eq_coeₓ'. -/
@[simp]
theorem toFun_eq_coe (χ : MulChar R R') : χ.toFun = χ :=
rfl
#align mul_char.to_fun_eq_coe MulChar.toFun_eq_coe
-/- warning: mul_char.coe_mk -> MulChar.coe_mk is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (hf : forall (a : R), (Not (IsUnit.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) -> (Eq.{succ u2} R' (MonoidHom.toFun.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) f a) (OfNat.ofNat.{u2} R' 0 (OfNat.mk.{u2} R' 0 (Zero.zero.{u2} R' (MulZeroClass.toHasZero.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))))))), Eq.{max (succ u1) (succ u2)} ((fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.mk.{u1, u2} R _inst_1 R' _inst_2 f hf)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (MulChar.mk.{u1, u2} R _inst_1 R' _inst_2 f hf)) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => R -> R') (MonoidHom.hasCoeToFun.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) f)
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (hf : forall (a : R), (Not (IsUnit.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) -> (Eq.{succ u2} R' (OneHom.toFun.{u1, u2} R R' (MulOneClass.toOne.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toOne.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.toOneHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) f) a) (OfNat.ofNat.{u2} R' 0 (Zero.toOfNat0.{u2} R' (CommMonoidWithZero.toZero.{u2} R' _inst_2))))), Eq.{max (succ u1) (succ u2)} (R -> R') (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (MulChar.mk.{u1, u2} R _inst_1 R' _inst_2 f hf)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R (fun (_x : R) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : R) => R') _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (MulOneClass.toMul.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) f)
-Case conversion may be inaccurate. Consider using '#align mul_char.coe_mk MulChar.coe_mkₓ'. -/
@[simp]
theorem coe_mk (f : R →* R') (hf) : (MulChar.mk f hf : R → R') = f :=
rfl
@@ -191,12 +173,6 @@ instance : MulCharClass (MulChar R R') R R'
map_one χ := χ.map_one'
map_nonunit χ := χ.map_nonunit'
-/- warning: mul_char.map_nonunit -> MulChar.map_nonunit is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) {a : R}, (Not (IsUnit.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) -> (Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ a) (OfNat.ofNat.{u2} R' 0 (OfNat.mk.{u2} R' 0 (Zero.zero.{u2} R' (MulZeroClass.toHasZero.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))))))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) {a : R}, (Not (IsUnit.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) -> (Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ a) (OfNat.ofNat.{u2} R' 0 (Zero.toOfNat0.{u2} R' (CommMonoidWithZero.toZero.{u2} R' _inst_2))))
-Case conversion may be inaccurate. Consider using '#align mul_char.map_nonunit MulChar.map_nonunitₓ'. -/
theorem map_nonunit (χ : MulChar R R') {a : R} (ha : ¬IsUnit a) : χ a = 0 :=
χ.map_nonunit' a ha
#align mul_char.map_nonunit MulChar.map_nonunit
@@ -229,33 +205,15 @@ between `mul_char R R'` and `Rˣ →* R'ˣ`.
-/
-/- warning: mul_char.to_unit_hom -> MulChar.toUnitHom is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'], (MulChar.{u1, u2} R _inst_1 R' _inst_2) -> (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'], (MulChar.{u1, u2} R _inst_1 R' _inst_2) -> (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))
-Case conversion may be inaccurate. Consider using '#align mul_char.to_unit_hom MulChar.toUnitHomₓ'. -/
/-- Turn a `mul_char` into a homomorphism between the unit groups. -/
def toUnitHom (χ : MulChar R R') : Rˣ →* R'ˣ :=
Units.map χ
#align mul_char.to_unit_hom MulChar.toUnitHom
-/- warning: mul_char.coe_to_unit_hom -> MulChar.coe_toUnitHom is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (HasLiftT.mk.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (CoeTCₓ.coe.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (coeBase.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (Units.hasCoe.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) -> (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.hasCoeToFun.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) a)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) a)) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a))
-Case conversion may be inaccurate. Consider using '#align mul_char.coe_to_unit_hom MulChar.coe_toUnitHomₓ'. -/
theorem coe_toUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(χ.toUnitHom a) = χ a :=
rfl
#align mul_char.coe_to_unit_hom MulChar.coe_toUnitHom
-/- warning: mul_char.of_unit_hom -> MulChar.ofUnitHom is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'], (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) -> (MulChar.{u1, u2} R _inst_1 R' _inst_2)
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'], (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) -> (MulChar.{u1, u2} R _inst_1 R' _inst_2)
-Case conversion may be inaccurate. Consider using '#align mul_char.of_unit_hom MulChar.ofUnitHomₓ'. -/
/-- Turn a homomorphism between unit groups into a `mul_char`. -/
noncomputable def ofUnitHom (f : Rˣ →* R'ˣ) : MulChar R R'
where
@@ -278,21 +236,9 @@ noncomputable def ofUnitHom (f : Rˣ →* R'ˣ) : MulChar R R'
map_nonunit' := by intro a ha; simp only [ha, not_false_iff, dif_neg]
#align mul_char.of_unit_hom MulChar.ofUnitHom
-/- warning: mul_char.of_unit_hom_coe -> MulChar.ofUnitHom_coe is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 f) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a)) ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (HasLiftT.mk.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (CoeTCₓ.coe.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (coeBase.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (Units.hasCoe.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) -> (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.hasCoeToFun.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) f a))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 f) (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) f a))
-Case conversion may be inaccurate. Consider using '#align mul_char.of_unit_hom_coe MulChar.ofUnitHom_coeₓ'. -/
theorem ofUnitHom_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : of_unit_hom f ↑a = f a := by simp [of_unit_hom]
#align mul_char.of_unit_hom_coe MulChar.ofUnitHom_coe
-/- warning: mul_char.equiv_to_unit_hom -> MulChar.equivToUnitHom is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'], Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'], Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))
-Case conversion may be inaccurate. Consider using '#align mul_char.equiv_to_unit_hom MulChar.equivToUnitHomₓ'. -/
/-- The equivalence between multiplicative characters and homomorphisms of unit groups. -/
noncomputable def equivToUnitHom : MulChar R R' ≃ (Rˣ →* R'ˣ)
where
@@ -302,39 +248,21 @@ noncomputable def equivToUnitHom : MulChar R R' ≃ (Rˣ →* R'ˣ)
right_inv := by intro f; ext x; rw [coe_to_unit_hom, of_unit_hom_coe]
#align mul_char.equiv_to_unit_hom MulChar.equivToUnitHom
-/- warning: mul_char.to_unit_hom_eq -> MulChar.toUnitHom_eq is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (coeFn.{max 1 (max (max (succ u1) (succ u2)) (succ u2) (succ u1)) (max (succ u2) (succ u1)) (succ u1) (succ u2), max (max (succ u1) (succ u2)) (succ u2) (succ u1)} (Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (fun (_x : Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) => (MulChar.{u1, u2} R _inst_1 R' _inst_2) -> (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (Equiv.hasCoeToFun.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ)
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ)
-Case conversion may be inaccurate. Consider using '#align mul_char.to_unit_hom_eq MulChar.toUnitHom_eqₓ'. -/
@[simp]
theorem toUnitHom_eq (χ : MulChar R R') : to_unit_hom χ = equiv_to_unit_hom χ :=
rfl
#align mul_char.to_unit_hom_eq MulChar.toUnitHom_eq
-/- warning: mul_char.of_unit_hom_eq -> MulChar.ofUnitHom_eq is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))), Eq.{max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (coeFn.{max 1 (max (max (succ u2) (succ u1)) (succ u1) (succ u2)) (max (succ u1) (succ u2)) (succ u2) (succ u1), max (max (succ u2) (succ u1)) (succ u1) (succ u2)} (Equiv.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (fun (_x : Equiv.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) => (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) -> (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.hasCoeToFun.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) χ)
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))), Eq.{max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => MulChar.{u1, u2} R _inst_1 R' _inst_2) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) χ)
-Case conversion may be inaccurate. Consider using '#align mul_char.of_unit_hom_eq MulChar.ofUnitHom_eqₓ'. -/
@[simp]
theorem ofUnitHom_eq (χ : Rˣ →* R'ˣ) : of_unit_hom χ = equiv_to_unit_hom.symm χ :=
rfl
#align mul_char.of_unit_hom_eq MulChar.ofUnitHom_eq
-/- warning: mul_char.coe_equiv_to_unit_hom -> MulChar.coe_equivToUnitHom is a dubious translation:
-<too large>
-Case conversion may be inaccurate. Consider using '#align mul_char.coe_equiv_to_unit_hom MulChar.coe_equivToUnitHomₓ'. -/
@[simp]
theorem coe_equivToUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(equiv_to_unit_hom χ a) = χ a :=
coe_to_unit_hom χ a
#align mul_char.coe_equiv_to_unit_hom MulChar.coe_equivToUnitHom
-/- warning: mul_char.equiv_unit_hom_symm_coe -> MulChar.equiv_unit_hom_symm_coe is a dubious translation:
-<too large>
-Case conversion may be inaccurate. Consider using '#align mul_char.equiv_unit_hom_symm_coe MulChar.equiv_unit_hom_symm_coeₓ'. -/
@[simp]
theorem equiv_unit_hom_symm_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : equiv_to_unit_hom.symm f ↑a = f a :=
of_unit_hom_coe f a
@@ -347,33 +275,15 @@ The multiplicative characters `R → R'` form a commutative group.
-/
-/- warning: mul_char.map_one -> MulChar.map_one is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ (OfNat.ofNat.{u1} R 1 (OfNat.mk.{u1} R 1 (One.one.{u1} R (MulOneClass.toHasOne.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))))) (OfNat.ofNat.{u2} R' 1 (OfNat.mk.{u2} R' 1 (One.one.{u2} R' (MulOneClass.toHasOne.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ (OfNat.ofNat.{u1} R 1 (One.toOfNat1.{u1} R (Monoid.toOne.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) (OfNat.ofNat.{u2} R' 1 (One.toOfNat1.{u2} R' (Monoid.toOne.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))
-Case conversion may be inaccurate. Consider using '#align mul_char.map_one MulChar.map_oneₓ'. -/
protected theorem map_one (χ : MulChar R R') : χ (1 : R) = 1 :=
χ.map_one'
#align mul_char.map_one MulChar.map_one
-/- warning: mul_char.map_zero -> MulChar.map_zero is a dubious translation:
-lean 3 declaration is
- forall {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] {R : Type.{u1}} [_inst_3 : CommMonoidWithZero.{u1} R] [_inst_4 : Nontrivial.{u1} R] (χ : MulChar.{u1, u2} R (CommMonoidWithZero.toCommMonoid.{u1} R _inst_3) R' _inst_2), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommMonoidWithZero.toCommMonoid.{u1} R _inst_3) R' _inst_2) (fun (_x : MulChar.{u1, u2} R (CommMonoidWithZero.toCommMonoid.{u1} R _inst_3) R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R (CommMonoidWithZero.toCommMonoid.{u1} R _inst_3) R' _inst_2) χ (OfNat.ofNat.{u1} R 0 (OfNat.mk.{u1} R 0 (Zero.zero.{u1} R (MulZeroClass.toHasZero.{u1} R (MulZeroOneClass.toMulZeroClass.{u1} R (MonoidWithZero.toMulZeroOneClass.{u1} R (CommMonoidWithZero.toMonoidWithZero.{u1} R _inst_3)))))))) (OfNat.ofNat.{u2} R' 0 (OfNat.mk.{u2} R' 0 (Zero.zero.{u2} R' (MulZeroClass.toHasZero.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))))
-but is expected to have type
- forall {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] {R : Type.{u1}} [_inst_3 : CommMonoidWithZero.{u1} R] [_inst_4 : Nontrivial.{u1} R] (χ : MulChar.{u1, u2} R (CommMonoidWithZero.toCommMonoid.{u1} R _inst_3) R' _inst_2), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R (CommMonoidWithZero.toCommMonoid.{u1} R _inst_3) R' _inst_2 χ (OfNat.ofNat.{u1} R 0 (Zero.toOfNat0.{u1} R (CommMonoidWithZero.toZero.{u1} R _inst_3)))) (OfNat.ofNat.{u2} R' 0 (Zero.toOfNat0.{u2} R' (CommMonoidWithZero.toZero.{u2} R' _inst_2)))
-Case conversion may be inaccurate. Consider using '#align mul_char.map_zero MulChar.map_zeroₓ'. -/
/-- If the domain has a zero (and is nontrivial), then `χ 0 = 0`. -/
protected theorem map_zero {R : Type u} [CommMonoidWithZero R] [Nontrivial R] (χ : MulChar R R') :
χ (0 : R) = 0 := by rw [map_nonunit χ not_isUnit_zero]
#align mul_char.map_zero MulChar.map_zero
-/- warning: mul_char.map_ring_char -> MulChar.map_ringChar is a dubious translation:
-lean 3 declaration is
- forall {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] {R : Type.{u1}} [_inst_3 : CommRing.{u1} R] [_inst_4 : Nontrivial.{u1} R] (χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_3) R' _inst_2), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_3) R' _inst_2) (fun (_x : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_3) R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_3) R' _inst_2) χ ((fun (a : Type) (b : Type.{u1}) [self : HasLiftT.{1, succ u1} a b] => self.0) Nat R (HasLiftT.mk.{1, succ u1} Nat R (CoeTCₓ.coe.{1, succ u1} Nat R (Nat.castCoe.{u1} R (AddMonoidWithOne.toNatCast.{u1} R (AddGroupWithOne.toAddMonoidWithOne.{u1} R (AddCommGroupWithOne.toAddGroupWithOne.{u1} R (Ring.toAddCommGroupWithOne.{u1} R (CommRing.toRing.{u1} R _inst_3)))))))) (ringChar.{u1} R (NonAssocRing.toNonAssocSemiring.{u1} R (Ring.toNonAssocRing.{u1} R (CommRing.toRing.{u1} R _inst_3)))))) (OfNat.ofNat.{u2} R' 0 (OfNat.mk.{u2} R' 0 (Zero.zero.{u2} R' (MulZeroClass.toHasZero.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))))
-but is expected to have type
- forall {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] {R : Type.{u1}} [_inst_3 : CommRing.{u1} R] [_inst_4 : Nontrivial.{u1} R] (χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_3) R' _inst_2), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_3) R' _inst_2 χ (Nat.cast.{u1} R (Semiring.toNatCast.{u1} R (CommSemiring.toSemiring.{u1} R (CommRing.toCommSemiring.{u1} R _inst_3))) (ringChar.{u1} R (Semiring.toNonAssocSemiring.{u1} R (CommSemiring.toSemiring.{u1} R (CommRing.toCommSemiring.{u1} R _inst_3)))))) (OfNat.ofNat.{u2} R' 0 (Zero.toOfNat0.{u2} R' (CommMonoidWithZero.toZero.{u2} R' _inst_2)))
-Case conversion may be inaccurate. Consider using '#align mul_char.map_ring_char MulChar.map_ringCharₓ'. -/
/-- If the domain is a ring `R`, then `χ (ring_char R) = 0`. -/
theorem map_ringChar {R : Type u} [CommRing R] [Nontrivial R] (χ : MulChar R R') :
χ (ringChar R) = 0 := by rw [ringChar.Nat.cast_ringChar, χ.map_zero]
@@ -391,12 +301,6 @@ noncomputable instance inhabited : Inhabited (MulChar R R') :=
#align mul_char.inhabited MulChar.inhabited
-/
-/- warning: mul_char.one_apply_coe -> MulChar.one_apply_coe is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (OfNat.ofNat.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) 1 (OfNat.mk.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) 1 (One.one.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.hasOne.{u1, u2} R _inst_1 R' _inst_2)))) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a)) (OfNat.ofNat.{u2} R' 1 (OfNat.mk.{u2} R' 1 (One.one.{u2} R' (MulOneClass.toHasOne.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (OfNat.ofNat.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) 1 (One.toOfNat1.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.hasOne.{u1, u2} R _inst_1 R' _inst_2))) (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) (OfNat.ofNat.{u2} R' 1 (One.toOfNat1.{u2} R' (Monoid.toOne.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))
-Case conversion may be inaccurate. Consider using '#align mul_char.one_apply_coe MulChar.one_apply_coeₓ'. -/
/-- Evaluation of the trivial character -/
@[simp]
theorem one_apply_coe (a : Rˣ) : (1 : MulChar R R') a = 1 := by classical exact dif_pos a.is_unit
@@ -417,22 +321,10 @@ instance hasMul : Mul (MulChar R R') :=
#align mul_char.has_mul MulChar.hasMul
-/
-/- warning: mul_char.mul_apply -> MulChar.mul_apply is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (χ' : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : R), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (instHMul.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.hasMul.{u1, u2} R _inst_1 R' _inst_2)) χ χ') a) (HMul.hMul.{u2, u2, u2} R' R' R' (instHMul.{u2} R' (MulZeroClass.toHasMul.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ a) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ' a))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (χ' : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : R), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (instHMul.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.hasMul.{u1, u2} R _inst_1 R' _inst_2)) χ χ') a) (HMul.hMul.{u2, u2, u2} R' R' R' (instHMul.{u2} R' (MulZeroClass.toMul.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ a) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ' a))
-Case conversion may be inaccurate. Consider using '#align mul_char.mul_apply MulChar.mul_applyₓ'. -/
theorem mul_apply (χ χ' : MulChar R R') (a : R) : (χ * χ') a = χ a * χ' a :=
rfl
#align mul_char.mul_apply MulChar.mul_apply
-/- warning: mul_char.coe_to_fun_mul -> MulChar.coeToFun_mul is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (χ' : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{succ (max u1 u2)} (R -> R') (coeFn.{succ (max u1 u2), succ (max u1 u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (instHMul.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.hasMul.{u1, u2} R _inst_1 R' _inst_2)) χ χ')) (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (R -> R') (R -> R') (R -> R') (instHMul.{max u1 u2} (R -> R') (Pi.instMul.{u1, u2} R (fun (ᾰ : R) => R') (fun (i : R) => MulZeroClass.toHasMul.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ'))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (χ' : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (R -> R') (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (instHMul.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.hasMul.{u1, u2} R _inst_1 R' _inst_2)) χ χ')) (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (R -> R') (R -> R') (R -> R') (instHMul.{max u1 u2} (R -> R') (Pi.instMul.{u1, u2} R (fun (ᾰ : R) => R') (fun (i : R) => MulZeroClass.toMul.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ'))
-Case conversion may be inaccurate. Consider using '#align mul_char.coe_to_fun_mul MulChar.coeToFun_mulₓ'. -/
@[simp]
theorem coeToFun_mul (χ χ' : MulChar R R') : ⇑(χ * χ') = χ * χ' :=
rfl
@@ -472,12 +364,6 @@ theorem inv_apply_eq_inv (χ : MulChar R R') (a : R) : χ⁻¹ a = Ring.inverse
#align mul_char.inv_apply_eq_inv MulChar.inv_apply_eq_inv
-/
-/- warning: mul_char.inv_apply_eq_inv' -> MulChar.inv_apply_eq_inv' is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_3 : Field.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (a : R), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (fun (_x : MulChar.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (Inv.inv.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (MulChar.hasInv.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) χ) a) (Inv.inv.{u2} R' (DivInvMonoid.toHasInv.{u2} R' (DivisionRing.toDivInvMonoid.{u2} R' (Field.toDivisionRing.{u2} R' _inst_3))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (fun (_x : MulChar.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) χ a))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_3 : Field.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' (CommGroupWithZero.toCommMonoidWithZero.{u2} R' (Semifield.toCommGroupWithZero.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (a : R), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' (CommGroupWithZero.toCommMonoidWithZero.{u2} R' (Semifield.toCommGroupWithZero.{u2} R' (Field.toSemifield.{u2} R' _inst_3))) (Inv.inv.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' (CommGroupWithZero.toCommMonoidWithZero.{u2} R' (Semifield.toCommGroupWithZero.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (MulChar.hasInv.{u1, u2} R _inst_1 R' (CommGroupWithZero.toCommMonoidWithZero.{u2} R' (Semifield.toCommGroupWithZero.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) χ) a) (Inv.inv.{u2} R' (Field.toInv.{u2} R' _inst_3) (MulChar.toFun'.{u1, u2} R _inst_1 R' (CommGroupWithZero.toCommMonoidWithZero.{u2} R' (Semifield.toCommGroupWithZero.{u2} R' (Field.toSemifield.{u2} R' _inst_3))) χ a))
-Case conversion may be inaccurate. Consider using '#align mul_char.inv_apply_eq_inv' MulChar.inv_apply_eq_inv'ₓ'. -/
/-- The inverse of a multiplicative character `χ`, applied to `a`, is the inverse of `χ a`.
Variant when the target is a field -/
theorem inv_apply_eq_inv' {R' : Type v} [Field R'] (χ : MulChar R R') (a : R) : χ⁻¹ a = (χ a)⁻¹ :=
@@ -500,12 +386,6 @@ theorem inv_apply {R : Type u} [CommMonoidWithZero R] (χ : MulChar R R') (a : R
#align mul_char.inv_apply MulChar.inv_apply
-/
-/- warning: mul_char.inv_apply' -> MulChar.inv_apply' is a dubious translation:
-lean 3 declaration is
- forall {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] {R : Type.{u1}} [_inst_3 : Field.{u1} R] (χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (a : R), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (fun (_x : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (Inv.inv.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (MulChar.hasInv.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) χ) a) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (fun (_x : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) χ (Inv.inv.{u1} R (DivInvMonoid.toHasInv.{u1} R (DivisionRing.toDivInvMonoid.{u1} R (Field.toDivisionRing.{u1} R _inst_3))) a))
-but is expected to have type
- forall {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] {R : Type.{u1}} [_inst_3 : Field.{u1} R] (χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (a : R), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2 (Inv.inv.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (MulChar.hasInv.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) χ) a) (MulChar.toFun'.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2 χ (Inv.inv.{u1} R (Field.toInv.{u1} R _inst_3) a))
-Case conversion may be inaccurate. Consider using '#align mul_char.inv_apply' MulChar.inv_apply'ₓ'. -/
/-- When the domain has a zero, then the inverse of a multiplicative character `χ`,
applied to `a`, is `χ` applied to the inverse of `a`. -/
theorem inv_apply' {R : Type u} [Field R] (χ : MulChar R R') (a : R) : χ⁻¹ a = χ a⁻¹ :=
@@ -602,12 +482,6 @@ def IsQuadratic (χ : MulChar R R') : Prop :=
#align mul_char.is_quadratic MulChar.IsQuadratic
-/
-/- warning: mul_char.is_quadratic.eq_of_eq_coe -> MulChar.IsQuadratic.eq_of_eq_coe is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {R'' : Type.{u3}} [_inst_3 : CommRing.{u3} R''] {χ : MulChar.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)}, (MulChar.IsQuadratic.{u1, 0} R _inst_1 Int Int.commRing χ) -> (forall {χ' : MulChar.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)}, (MulChar.IsQuadratic.{u2, 0} R' _inst_2 Int Int.commRing χ') -> (forall [_inst_4 : Nontrivial.{u3} R''], (Ne.{1} Nat (ringChar.{u3} R'' (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))) (OfNat.ofNat.{0} Nat 2 (OfNat.mk.{0} Nat 2 (bit0.{0} Nat Nat.hasAdd (One.one.{0} Nat Nat.hasOne))))) -> (forall {a : R} {a' : R'}, (Eq.{succ u3} R'' ((fun (a : Type) (b : Type.{u3}) [self : HasLiftT.{1, succ u3} a b] => self.0) Int R'' (HasLiftT.mk.{1, succ u3} Int R'' (CoeTCₓ.coe.{1, succ u3} Int R'' (Int.castCoe.{u3} R'' (AddGroupWithOne.toHasIntCast.{u3} R'' (AddCommGroupWithOne.toAddGroupWithOne.{u3} R'' (Ring.toAddCommGroupWithOne.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3))))))) (coeFn.{succ u1, succ u1} (MulChar.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) (fun (_x : MulChar.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) => R -> Int) (MulChar.coeToFun.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) χ a)) ((fun (a : Type) (b : Type.{u3}) [self : HasLiftT.{1, succ u3} a b] => self.0) Int R'' (HasLiftT.mk.{1, succ u3} Int R'' (CoeTCₓ.coe.{1, succ u3} Int R'' (Int.castCoe.{u3} R'' (AddGroupWithOne.toHasIntCast.{u3} R'' (AddCommGroupWithOne.toAddGroupWithOne.{u3} R'' (Ring.toAddCommGroupWithOne.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3))))))) (coeFn.{succ u2, succ u2} (MulChar.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) (fun (_x : MulChar.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) => R' -> Int) (MulChar.coeToFun.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) χ' a'))) -> (Eq.{1} Int (coeFn.{succ u1, succ u1} (MulChar.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) (fun (_x : MulChar.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) => R -> Int) (MulChar.coeToFun.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) χ a) (coeFn.{succ u2, succ u2} (MulChar.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) (fun (_x : MulChar.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) => R' -> Int) (MulChar.coeToFun.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) χ' a')))))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {R'' : Type.{u3}} [_inst_3 : CommRing.{u3} R''] {χ : MulChar.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CancelCommMonoidWithZero.toCommMonoidWithZero.{0} Int (IsDomain.toCancelCommMonoidWithZero.{0} Int Int.instCommSemiringInt (LinearOrderedRing.isDomain.{0} Int (LinearOrderedCommRing.toLinearOrderedRing.{0} Int Int.linearOrderedCommRing))))}, (MulChar.IsQuadratic.{u1, 0} R _inst_1 Int Int.instCommRingInt χ) -> (forall {χ' : MulChar.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CancelCommMonoidWithZero.toCommMonoidWithZero.{0} Int (IsDomain.toCancelCommMonoidWithZero.{0} Int Int.instCommSemiringInt (LinearOrderedRing.isDomain.{0} Int (LinearOrderedCommRing.toLinearOrderedRing.{0} Int Int.linearOrderedCommRing))))}, (MulChar.IsQuadratic.{u2, 0} R' _inst_2 Int Int.instCommRingInt χ') -> (forall [_inst_4 : Nontrivial.{u3} R''], (Ne.{1} Nat (ringChar.{u3} R'' (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) (OfNat.ofNat.{0} Nat 2 (instOfNatNat 2))) -> (forall {a : R} {a' : R'}, (Eq.{succ u3} R'' (Int.cast.{u3} R'' (Ring.toIntCast.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)) (MulChar.toFun'.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CancelCommMonoidWithZero.toCommMonoidWithZero.{0} Int (IsDomain.toCancelCommMonoidWithZero.{0} Int Int.instCommSemiringInt (LinearOrderedRing.isDomain.{0} Int (LinearOrderedCommRing.toLinearOrderedRing.{0} Int Int.linearOrderedCommRing)))) χ a)) (Int.cast.{u3} R'' (Ring.toIntCast.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)) (MulChar.toFun'.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CancelCommMonoidWithZero.toCommMonoidWithZero.{0} Int (IsDomain.toCancelCommMonoidWithZero.{0} Int Int.instCommSemiringInt (LinearOrderedRing.isDomain.{0} Int (LinearOrderedCommRing.toLinearOrderedRing.{0} Int Int.linearOrderedCommRing)))) χ' a'))) -> (Eq.{1} Int (MulChar.toFun'.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CancelCommMonoidWithZero.toCommMonoidWithZero.{0} Int (IsDomain.toCancelCommMonoidWithZero.{0} Int Int.instCommSemiringInt (LinearOrderedRing.isDomain.{0} Int (LinearOrderedCommRing.toLinearOrderedRing.{0} Int Int.linearOrderedCommRing)))) χ a) (MulChar.toFun'.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CancelCommMonoidWithZero.toCommMonoidWithZero.{0} Int (IsDomain.toCancelCommMonoidWithZero.{0} Int Int.instCommSemiringInt (LinearOrderedRing.isDomain.{0} Int (LinearOrderedCommRing.toLinearOrderedRing.{0} Int Int.linearOrderedCommRing)))) χ' a')))))
-Case conversion may be inaccurate. Consider using '#align mul_char.is_quadratic.eq_of_eq_coe MulChar.IsQuadratic.eq_of_eq_coeₓ'. -/
/-- If two values of quadratic characters with target `ℤ` agree after coercion into a ring
of characteristic not `2`, then they agree in `ℤ`. -/
theorem IsQuadratic.eq_of_eq_coe {χ : MulChar R ℤ} (hχ : IsQuadratic χ) {χ' : MulChar R' ℤ}
@@ -627,12 +501,6 @@ def ringHomComp (χ : MulChar R R') (f : R' →+* R'') : MulChar R R'' :=
#align mul_char.ring_hom_comp MulChar.ringHomComp
-/
-/- warning: mul_char.is_nontrivial.comp -> MulChar.IsNontrivial.comp is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {R'' : Type.{u3}} [_inst_3 : CommRing.{u3} R''] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))}, (MulChar.IsNontrivial.{u1, u2} R _inst_1 R' _inst_2 χ) -> (forall {f : RingHom.{u2, u3} R' R'' (NonAssocRing.toNonAssocSemiring.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))}, (Function.Injective.{succ u2, succ u3} R' R'' (coeFn.{max (succ u2) (succ u3), max (succ u2) (succ u3)} (RingHom.{u2, u3} R' R'' (NonAssocRing.toNonAssocSemiring.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))) (fun (_x : RingHom.{u2, u3} R' R'' (NonAssocRing.toNonAssocSemiring.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))) => R' -> R'') (RingHom.hasCoeToFun.{u2, u3} R' R'' (NonAssocRing.toNonAssocSemiring.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))) f)) -> (MulChar.IsNontrivial.{u1, u3} R _inst_1 R'' _inst_3 (MulChar.ringHomComp.{u1, u2, u3} R _inst_1 R' _inst_2 R'' _inst_3 χ f)))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {R'' : Type.{u3}} [_inst_3 : CommRing.{u3} R''] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))}, (MulChar.IsNontrivial.{u1, u2} R _inst_1 R' _inst_2 χ) -> (forall {f : RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))}, (Function.Injective.{succ u2, succ u3} R' R'' (FunLike.coe.{max (succ u2) (succ u3), succ u2, succ u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' (fun (_x : R') => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : R') => R'') _x) (MulHomClass.toFunLike.{max u2 u3, u2, u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' R'' (NonUnitalNonAssocSemiring.toMul.{u2} R' (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} R' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))))) (NonUnitalNonAssocSemiring.toMul.{u3} R'' (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u3} R'' (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3))))) (NonUnitalRingHomClass.toMulHomClass.{max u2 u3, u2, u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' R'' (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} R' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2)))) (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u3} R'' (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) (RingHomClass.toNonUnitalRingHomClass.{max u2 u3, u2, u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3))) (RingHom.instRingHomClassRingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3))))))) f)) -> (MulChar.IsNontrivial.{u1, u3} R _inst_1 R'' _inst_3 (MulChar.ringHomComp.{u1, u2, u3} R _inst_1 R' _inst_2 R'' _inst_3 χ f)))
-Case conversion may be inaccurate. Consider using '#align mul_char.is_nontrivial.comp MulChar.IsNontrivial.compₓ'. -/
/-- Composition with an injective ring homomorphism preserves nontriviality. -/
theorem IsNontrivial.comp {χ : MulChar R R'} (hχ : χ.IsNontrivial) {f : R' →+* R''}
(hf : Function.Injective f) : (χ.ringHomComp f).IsNontrivial :=
@@ -675,12 +543,6 @@ theorem IsQuadratic.sq_eq_one {χ : MulChar R R'} (hχ : χ.IsQuadratic) : χ ^
#align mul_char.is_quadratic.sq_eq_one MulChar.IsQuadratic.sq_eq_one
-/
-/- warning: mul_char.is_quadratic.pow_char -> MulChar.IsQuadratic.pow_char is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))}, (MulChar.IsQuadratic.{u1, u2} R _inst_1 R' _inst_2 χ) -> (forall (p : Nat) [hp : Fact (Nat.Prime p)] [_inst_4 : CharP.{u2} R' (AddGroupWithOne.toAddMonoidWithOne.{u2} R' (AddCommGroupWithOne.toAddGroupWithOne.{u2} R' (Ring.toAddCommGroupWithOne.{u2} R' (CommRing.toRing.{u2} R' _inst_2)))) p], Eq.{succ (max u1 u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (HPow.hPow.{max u1 u2, 0, max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) Nat (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (instHPow.{max u1 u2, 0} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) Nat (Monoid.Pow.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (DivInvMonoid.toMonoid.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Group.toDivInvMonoid.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (CommGroup.toGroup.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (MulChar.commGroup.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2)))))))) χ p) χ)
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))}, (MulChar.IsQuadratic.{u1, u2} R _inst_1 R' _inst_2 χ) -> (forall (p : Nat) [hp : Fact (Nat.Prime p)] [_inst_4 : CharP.{u2} R' (AddGroupWithOne.toAddMonoidWithOne.{u2} R' (Ring.toAddGroupWithOne.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) p], Eq.{max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (HPow.hPow.{max u1 u2, 0, max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) Nat (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (instHPow.{max u1 u2, 0} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) Nat (Monoid.Pow.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (DivInvMonoid.toMonoid.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Group.toDivInvMonoid.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (CommGroup.toGroup.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (MulChar.commGroup.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2)))))))) χ p) χ)
-Case conversion may be inaccurate. Consider using '#align mul_char.is_quadratic.pow_char MulChar.IsQuadratic.pow_charₓ'. -/
/-- The `p`th power of a quadratic character is itself, when `p` is the (prime) characteristic
of the target ring. -/
theorem IsQuadratic.pow_char {χ : MulChar R R'} (hχ : χ.IsQuadratic) (p : ℕ) [hp : Fact p.Prime]
@@ -713,12 +575,6 @@ theorem IsQuadratic.pow_odd {χ : MulChar R R'} (hχ : χ.IsQuadratic) {n : ℕ}
open BigOperators
-/- warning: mul_char.is_nontrivial.sum_eq_zero -> MulChar.IsNontrivial.sum_eq_zero is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] [_inst_4 : Fintype.{u1} R] [_inst_5 : IsDomain.{u2} R' (Ring.toSemiring.{u2} R' (CommRing.toRing.{u2} R' _inst_2))] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))}, (MulChar.IsNontrivial.{u1, u2} R _inst_1 R' _inst_2 χ) -> (Eq.{succ u2} R' (Finset.sum.{u2, u1} R' R (AddCommGroup.toAddCommMonoid.{u2} R' (NonUnitalNonAssocRing.toAddCommGroup.{u2} R' (NonAssocRing.toNonUnitalNonAssocRing.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))))) (Finset.univ.{u1} R _inst_4) (fun (a : R) => coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (fun (_x : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) => R -> R') (MulChar.coeToFun.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) χ a)) (OfNat.ofNat.{u2} R' 0 (OfNat.mk.{u2} R' 0 (Zero.zero.{u2} R' (MulZeroClass.toHasZero.{u2} R' (NonUnitalNonAssocSemiring.toMulZeroClass.{u2} R' (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u2} R' (NonAssocRing.toNonUnitalNonAssocRing.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))))))))))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] [_inst_4 : Fintype.{u1} R] [_inst_5 : IsDomain.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CancelCommMonoidWithZero.toCommMonoidWithZero.{u2} R' (IsDomain.toCancelCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2) _inst_5))}, (MulChar.IsNontrivial.{u1, u2} R _inst_1 R' _inst_2 χ) -> (Eq.{succ u2} R' (Finset.sum.{u2, u1} R' R (NonUnitalNonAssocSemiring.toAddCommMonoid.{u2} R' (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u2} R' (NonAssocRing.toNonUnitalNonAssocRing.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))))) (Finset.univ.{u1} R _inst_4) (fun (a : R) => MulChar.toFun'.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CancelCommMonoidWithZero.toCommMonoidWithZero.{u2} R' (IsDomain.toCancelCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2) _inst_5)) χ a)) (OfNat.ofNat.{u2} R' 0 (Zero.toOfNat0.{u2} R' (CommMonoidWithZero.toZero.{u2} R' (CancelCommMonoidWithZero.toCommMonoidWithZero.{u2} R' (IsDomain.toCancelCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2) _inst_5))))))
-Case conversion may be inaccurate. Consider using '#align mul_char.is_nontrivial.sum_eq_zero MulChar.IsNontrivial.sum_eq_zeroₓ'. -/
/-- The sum over all values of a nontrivial multiplicative character on a finite ring is zero
(when the target is a domain). -/
theorem IsNontrivial.sum_eq_zero [Fintype R] [IsDomain R'] {χ : MulChar R R'}
@@ -730,12 +586,6 @@ theorem IsNontrivial.sum_eq_zero [Fintype R] [IsDomain R'] {χ : MulChar R R'}
exact Fintype.sum_bijective _ (Units.mulLeft_bijective b) _ _ fun x => rfl
#align mul_char.is_nontrivial.sum_eq_zero MulChar.IsNontrivial.sum_eq_zero
-/- warning: mul_char.sum_one_eq_card_units -> MulChar.sum_one_eq_card_units is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] [_inst_4 : Fintype.{u1} R] [_inst_5 : DecidableEq.{succ u1} R], Eq.{succ u2} R' (Finset.sum.{u2, u1} R' R (AddCommGroup.toAddCommMonoid.{u2} R' (NonUnitalNonAssocRing.toAddCommGroup.{u2} R' (NonAssocRing.toNonUnitalNonAssocRing.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))))) (Finset.univ.{u1} R _inst_4) (fun (a : R) => coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (fun (_x : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) => R -> R') (MulChar.coeToFun.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (OfNat.ofNat.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) 1 (OfNat.mk.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) 1 (One.one.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (MulChar.hasOne.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2)))))) a)) ((fun (a : Type) (b : Type.{u2}) [self : HasLiftT.{1, succ u2} a b] => self.0) Nat R' (HasLiftT.mk.{1, succ u2} Nat R' (CoeTCₓ.coe.{1, succ u2} Nat R' (Nat.castCoe.{u2} R' (AddMonoidWithOne.toNatCast.{u2} R' (AddGroupWithOne.toAddMonoidWithOne.{u2} R' (AddCommGroupWithOne.toAddGroupWithOne.{u2} R' (Ring.toAddCommGroupWithOne.{u2} R' (CommRing.toRing.{u2} R' _inst_2)))))))) (Fintype.card.{u1} (Units.{u1} R (Ring.toMonoid.{u1} R (CommRing.toRing.{u1} R _inst_1))) (Units.fintype.{u1} R (Ring.toMonoid.{u1} R (CommRing.toRing.{u1} R _inst_1)) _inst_4 (fun (a : R) (b : R) => _inst_5 a b))))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] [_inst_4 : Fintype.{u1} R] [_inst_5 : DecidableEq.{succ u1} R], Eq.{succ u2} R' (Finset.sum.{u2, u1} R' R (NonUnitalNonAssocSemiring.toAddCommMonoid.{u2} R' (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u2} R' (NonAssocRing.toNonUnitalNonAssocRing.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))))) (Finset.univ.{u1} R _inst_4) (fun (a : R) => MulChar.toFun'.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2)) (OfNat.ofNat.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) 1 (One.toOfNat1.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (MulChar.hasOne.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))))) a)) (Nat.cast.{u2} R' (Semiring.toNatCast.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Fintype.card.{u1} (Units.{u1} R (MonoidWithZero.toMonoid.{u1} R (Semiring.toMonoidWithZero.{u1} R (CommSemiring.toSemiring.{u1} R (CommRing.toCommSemiring.{u1} R _inst_1))))) (instFintypeUnits.{u1} R (MonoidWithZero.toMonoid.{u1} R (Semiring.toMonoidWithZero.{u1} R (CommSemiring.toSemiring.{u1} R (CommRing.toCommSemiring.{u1} R _inst_1)))) _inst_4 (fun (a : R) (b : R) => _inst_5 a b))))
-Case conversion may be inaccurate. Consider using '#align mul_char.sum_one_eq_card_units MulChar.sum_one_eq_card_unitsₓ'. -/
/-- The sum over all values of the trivial multiplicative character on a finite ring is
the cardinality of its unit group. -/
theorem sum_one_eq_card_units [Fintype R] [DecidableEq R] :
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -127,9 +127,7 @@ the value `1` on units. -/
noncomputable def trivial : MulChar R R'
where
toFun := by classical exact fun x => if IsUnit x then 1 else 0
- map_nonunit' := by
- intro a ha
- simp only [ha, if_false]
+ map_nonunit' := by intro a ha; simp only [ha, if_false]
map_one' := by simp only [isUnit_one, if_true]
map_mul' := by
intro x y
@@ -219,9 +217,7 @@ theorem ext {χ χ' : MulChar R R'} (h : ∀ a : Rˣ, χ a = χ' a) : χ = χ' :
#print MulChar.ext_iff /-
theorem ext_iff {χ χ' : MulChar R R'} : χ = χ' ↔ ∀ a : Rˣ, χ a = χ' a :=
- ⟨by
- rintro rfl a
- rfl, ext⟩
+ ⟨by rintro rfl a; rfl, ext⟩
#align mul_char.ext_iff MulChar.ext_iff
-/
@@ -279,9 +275,7 @@ noncomputable def ofUnitHom (f : Rˣ →* R'ˣ) : MulChar R R'
norm_cast
· simp only [hy, not_false_iff, dif_neg, MulZeroClass.mul_zero]
· simp only [hx, IsUnit.mul_iff, false_and_iff, not_false_iff, dif_neg, MulZeroClass.zero_mul]
- map_nonunit' := by
- intro a ha
- simp only [ha, not_false_iff, dif_neg]
+ map_nonunit' := by intro a ha; simp only [ha, not_false_iff, dif_neg]
#align mul_char.of_unit_hom MulChar.ofUnitHom
/- warning: mul_char.of_unit_hom_coe -> MulChar.ofUnitHom_coe is a dubious translation:
@@ -304,14 +298,8 @@ noncomputable def equivToUnitHom : MulChar R R' ≃ (Rˣ →* R'ˣ)
where
toFun := to_unit_hom
invFun := of_unit_hom
- left_inv := by
- intro χ
- ext x
- rw [of_unit_hom_coe, coe_to_unit_hom]
- right_inv := by
- intro f
- ext x
- rw [coe_to_unit_hom, of_unit_hom_coe]
+ left_inv := by intro χ; ext x; rw [of_unit_hom_coe, coe_to_unit_hom]
+ right_inv := by intro f; ext x; rw [coe_to_unit_hom, of_unit_hom_coe]
#align mul_char.equiv_to_unit_hom MulChar.equivToUnitHom
/- warning: mul_char.to_unit_hom_eq -> MulChar.toUnitHom_eq is a dubious translation:
@@ -451,18 +439,12 @@ theorem coeToFun_mul (χ χ' : MulChar R R') : ⇑(χ * χ') = χ * χ' :=
#align mul_char.coe_to_fun_mul MulChar.coeToFun_mul
#print MulChar.one_mul /-
-protected theorem one_mul (χ : MulChar R R') : (1 : MulChar R R') * χ = χ :=
- by
- ext
- simp
+protected theorem one_mul (χ : MulChar R R') : (1 : MulChar R R') * χ = χ := by ext; simp
#align mul_char.one_mul MulChar.one_mul
-/
#print MulChar.mul_one /-
-protected theorem mul_one (χ : MulChar R R') : χ * 1 = χ :=
- by
- ext
- simp
+protected theorem mul_one (χ : MulChar R R') : χ * 1 = χ := by ext; simp
#align mul_char.mul_one MulChar.mul_one
-/
@@ -512,9 +494,7 @@ theorem inv_apply {R : Type u} [CommMonoidWithZero R] (χ : MulChar R R') (a : R
have h := IsUnit.map χ ha
apply_fun (· * ·) (χ a) using IsUnit.mul_right_injective h
rw [Ring.mul_inverse_cancel _ h, ← map_mul, Ring.mul_inverse_cancel _ ha, MulChar.map_one]
- · revert ha
- nontriviality R
- intro ha
+ · revert ha; nontriviality R; intro ha
-- `nontriviality R` by itself doesn't do it
rw [map_nonunit _ ha, Ring.inverse_non_unit a ha, MulChar.map_zero χ]
#align mul_char.inv_apply MulChar.inv_apply
@@ -550,14 +530,8 @@ noncomputable instance commGroup : CommGroup (MulChar R R') :=
mul := (· * ·)
inv := Inv.inv
mul_left_inv := inv_mul
- mul_assoc := by
- intro χ₁ χ₂ χ₃
- ext a
- simp [mul_assoc]
- mul_comm := by
- intro χ₁ χ₂
- ext a
- simp [mul_comm]
+ mul_assoc := by intro χ₁ χ₂ χ₃; ext a; simp [mul_assoc]
+ mul_comm := by intro χ₁ χ₂; ext a; simp [mul_comm]
one_mul
mul_one }
#align mul_char.comm_group MulChar.commGroup
mathlib commit https://github.com/leanprover-community/mathlib/commit/917c3c072e487b3cccdbfeff17e75b40e45f66cb
@@ -337,10 +337,7 @@ theorem ofUnitHom_eq (χ : Rˣ →* R'ˣ) : of_unit_hom χ = equiv_to_unit_hom.s
#align mul_char.of_unit_hom_eq MulChar.ofUnitHom_eq
/- warning: mul_char.coe_equiv_to_unit_hom -> MulChar.coe_equivToUnitHom is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (HasLiftT.mk.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (CoeTCₓ.coe.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (coeBase.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (Units.hasCoe.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) -> (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.hasCoeToFun.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (coeFn.{max 1 (max (max (succ u1) (succ u2)) (succ u2) (succ u1)) (max (succ u2) (succ u1)) (succ u1) (succ u2), max (max (succ u1) (succ u2)) (succ u2) (succ u1)} (Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (fun (_x : Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) => (MulChar.{u1, u2} R _inst_1 R' _inst_2) -> (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (Equiv.hasCoeToFun.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ) a)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} ((fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) χ) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} ((fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) χ) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} ((fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) χ) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ) a)) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a))
+<too large>
Case conversion may be inaccurate. Consider using '#align mul_char.coe_equiv_to_unit_hom MulChar.coe_equivToUnitHomₓ'. -/
@[simp]
theorem coe_equivToUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(equiv_to_unit_hom χ a) = χ a :=
@@ -348,10 +345,7 @@ theorem coe_equivToUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(equiv_to_unit_hom
#align mul_char.coe_equiv_to_unit_hom MulChar.coe_equivToUnitHom
/- warning: mul_char.equiv_unit_hom_symm_coe -> MulChar.equiv_unit_hom_symm_coe is a dubious translation:
-lean 3 declaration is
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (coeFn.{max 1 (max (max (succ u2) (succ u1)) (succ u1) (succ u2)) (max (succ u1) (succ u2)) (succ u2) (succ u1), max (max (succ u2) (succ u1)) (succ u1) (succ u2)} (Equiv.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (fun (_x : Equiv.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) => (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) -> (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.hasCoeToFun.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) f) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a)) ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (HasLiftT.mk.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (CoeTCₓ.coe.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (coeBase.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (Units.hasCoe.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) -> (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.hasCoeToFun.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) f a))
-but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => MulChar.{u1, u2} R _inst_1 R' _inst_2) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) f) (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) f a))
+<too large>
Case conversion may be inaccurate. Consider using '#align mul_char.equiv_unit_hom_symm_coe MulChar.equiv_unit_hom_symm_coeₓ'. -/
@[simp]
theorem equiv_unit_hom_symm_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : equiv_to_unit_hom.symm f ↑a = f a :=
mathlib commit https://github.com/leanprover-community/mathlib/commit/33c67ae661dd8988516ff7f247b0be3018cdd952
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Michael Stoll
! This file was ported from Lean 3 source module number_theory.legendre_symbol.mul_character
-! leanprover-community/mathlib commit f0c8bf9245297a541f468be517f1bde6195105e9
+! leanprover-community/mathlib commit 33c67ae661dd8988516ff7f247b0be3018cdd952
! Please do not edit these lines, except to modify the commit id
! if you have ported upstream changes.
-/
@@ -15,6 +15,9 @@ import Mathbin.Data.Fintype.Units
/-!
# Multiplicative characters of finite rings and fields
+> THIS FILE IS SYNCHRONIZED WITH MATHLIB4.
+> Any changes to this file require a corresponding PR to mathlib4.
+
Let `R` and `R'` be a commutative rings.
A *multiplicative character* of `R` with values in `R'` is a morphism of
monoids from the multiplicative monoid of `R` into that of `R'`
mathlib commit https://github.com/leanprover-community/mathlib/commit/95a87616d63b3cb49d3fe678d416fbe9c4217bf4
@@ -142,7 +142,7 @@ end trivial
lean 3 declaration is
forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} ((fun (_x : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => R -> R') (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ)) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => R -> R') (MonoidHom.hasCoeToFun.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ)
but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (forall (a : R), (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : R) => R') a) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R (fun (_x : R) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : R) => R') _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (MulOneClass.toMul.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ)) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ)
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (forall (a : R), (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : R) => R') a) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R (fun (_x : R) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : R) => R') _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (MulOneClass.toMul.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ)) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ)
Case conversion may be inaccurate. Consider using '#align mul_char.coe_coe MulChar.coe_coeₓ'. -/
@[simp]
theorem coe_coe (χ : MulChar R R') : (χ.toMonoidHom : R → R') = χ :=
@@ -164,7 +164,7 @@ theorem toFun_eq_coe (χ : MulChar R R') : χ.toFun = χ :=
lean 3 declaration is
forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (hf : forall (a : R), (Not (IsUnit.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) -> (Eq.{succ u2} R' (MonoidHom.toFun.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) f a) (OfNat.ofNat.{u2} R' 0 (OfNat.mk.{u2} R' 0 (Zero.zero.{u2} R' (MulZeroClass.toHasZero.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))))))), Eq.{max (succ u1) (succ u2)} ((fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.mk.{u1, u2} R _inst_1 R' _inst_2 f hf)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (MulChar.mk.{u1, u2} R _inst_1 R' _inst_2 f hf)) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => R -> R') (MonoidHom.hasCoeToFun.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) f)
but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (hf : forall (a : R), (Not (IsUnit.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) -> (Eq.{succ u2} R' (OneHom.toFun.{u1, u2} R R' (MulOneClass.toOne.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toOne.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.toOneHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) f) a) (OfNat.ofNat.{u2} R' 0 (Zero.toOfNat0.{u2} R' (CommMonoidWithZero.toZero.{u2} R' _inst_2))))), Eq.{max (succ u1) (succ u2)} (R -> R') (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (MulChar.mk.{u1, u2} R _inst_1 R' _inst_2 f hf)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R (fun (_x : R) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : R) => R') _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (MulOneClass.toMul.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) f)
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (hf : forall (a : R), (Not (IsUnit.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) -> (Eq.{succ u2} R' (OneHom.toFun.{u1, u2} R R' (MulOneClass.toOne.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toOne.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.toOneHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) f) a) (OfNat.ofNat.{u2} R' 0 (Zero.toOfNat0.{u2} R' (CommMonoidWithZero.toZero.{u2} R' _inst_2))))), Eq.{max (succ u1) (succ u2)} (R -> R') (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (MulChar.mk.{u1, u2} R _inst_1 R' _inst_2 f hf)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R (fun (_x : R) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : R) => R') _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (MulOneClass.toMul.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) f)
Case conversion may be inaccurate. Consider using '#align mul_char.coe_mk MulChar.coe_mkₓ'. -/
@[simp]
theorem coe_mk (f : R →* R') (hf) : (MulChar.mk f hf : R → R') = f :=
@@ -245,7 +245,7 @@ def toUnitHom (χ : MulChar R R') : Rˣ →* R'ˣ :=
lean 3 declaration is
forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (HasLiftT.mk.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (CoeTCₓ.coe.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (coeBase.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (Units.hasCoe.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) -> (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.hasCoeToFun.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) a)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a))
but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) a)) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a))
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) a)) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a))
Case conversion may be inaccurate. Consider using '#align mul_char.coe_to_unit_hom MulChar.coe_toUnitHomₓ'. -/
theorem coe_toUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(χ.toUnitHom a) = χ a :=
rfl
@@ -285,7 +285,7 @@ noncomputable def ofUnitHom (f : Rˣ →* R'ˣ) : MulChar R R'
lean 3 declaration is
forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 f) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a)) ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (HasLiftT.mk.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (CoeTCₓ.coe.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (coeBase.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (Units.hasCoe.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) -> (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.hasCoeToFun.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) f a))
but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 f) (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) f a))
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 f) (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) f a))
Case conversion may be inaccurate. Consider using '#align mul_char.of_unit_hom_coe MulChar.ofUnitHom_coeₓ'. -/
theorem ofUnitHom_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : of_unit_hom f ↑a = f a := by simp [of_unit_hom]
#align mul_char.of_unit_hom_coe MulChar.ofUnitHom_coe
@@ -315,7 +315,7 @@ noncomputable def equivToUnitHom : MulChar R R' ≃ (Rˣ →* R'ˣ)
lean 3 declaration is
forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (coeFn.{max 1 (max (max (succ u1) (succ u2)) (succ u2) (succ u1)) (max (succ u2) (succ u1)) (succ u1) (succ u2), max (max (succ u1) (succ u2)) (succ u2) (succ u1)} (Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (fun (_x : Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) => (MulChar.{u1, u2} R _inst_1 R' _inst_2) -> (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (Equiv.hasCoeToFun.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ)
but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ)
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ)
Case conversion may be inaccurate. Consider using '#align mul_char.to_unit_hom_eq MulChar.toUnitHom_eqₓ'. -/
@[simp]
theorem toUnitHom_eq (χ : MulChar R R') : to_unit_hom χ = equiv_to_unit_hom χ :=
@@ -326,7 +326,7 @@ theorem toUnitHom_eq (χ : MulChar R R') : to_unit_hom χ = equiv_to_unit_hom χ
lean 3 declaration is
forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))), Eq.{max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (coeFn.{max 1 (max (max (succ u2) (succ u1)) (succ u1) (succ u2)) (max (succ u1) (succ u2)) (succ u2) (succ u1), max (max (succ u2) (succ u1)) (succ u1) (succ u2)} (Equiv.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (fun (_x : Equiv.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) => (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) -> (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.hasCoeToFun.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) χ)
but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))), Eq.{max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => MulChar.{u1, u2} R _inst_1 R' _inst_2) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) χ)
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))), Eq.{max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => MulChar.{u1, u2} R _inst_1 R' _inst_2) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) χ)
Case conversion may be inaccurate. Consider using '#align mul_char.of_unit_hom_eq MulChar.ofUnitHom_eqₓ'. -/
@[simp]
theorem ofUnitHom_eq (χ : Rˣ →* R'ˣ) : of_unit_hom χ = equiv_to_unit_hom.symm χ :=
@@ -337,7 +337,7 @@ theorem ofUnitHom_eq (χ : Rˣ →* R'ˣ) : of_unit_hom χ = equiv_to_unit_hom.s
lean 3 declaration is
forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (HasLiftT.mk.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (CoeTCₓ.coe.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (coeBase.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (Units.hasCoe.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) -> (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.hasCoeToFun.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (coeFn.{max 1 (max (max (succ u1) (succ u2)) (succ u2) (succ u1)) (max (succ u2) (succ u1)) (succ u1) (succ u2), max (max (succ u1) (succ u2)) (succ u2) (succ u1)} (Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (fun (_x : Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) => (MulChar.{u1, u2} R _inst_1 R' _inst_2) -> (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (Equiv.hasCoeToFun.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ) a)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a))
but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} ((fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) χ) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} ((fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) χ) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} ((fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) χ) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ) a)) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a))
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} ((fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) χ) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} ((fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) χ) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} ((fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) χ) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ) a)) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a))
Case conversion may be inaccurate. Consider using '#align mul_char.coe_equiv_to_unit_hom MulChar.coe_equivToUnitHomₓ'. -/
@[simp]
theorem coe_equivToUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(equiv_to_unit_hom χ a) = χ a :=
@@ -348,7 +348,7 @@ theorem coe_equivToUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(equiv_to_unit_hom
lean 3 declaration is
forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (coeFn.{max 1 (max (max (succ u2) (succ u1)) (succ u1) (succ u2)) (max (succ u1) (succ u2)) (succ u2) (succ u1), max (max (succ u2) (succ u1)) (succ u1) (succ u2)} (Equiv.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (fun (_x : Equiv.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) => (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) -> (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.hasCoeToFun.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) f) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a)) ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (HasLiftT.mk.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (CoeTCₓ.coe.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (coeBase.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (Units.hasCoe.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) -> (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.hasCoeToFun.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) f a))
but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => MulChar.{u1, u2} R _inst_1 R' _inst_2) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) f) (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) f a))
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.812 : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => MulChar.{u1, u2} R _inst_1 R' _inst_2) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) f) (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) f a))
Case conversion may be inaccurate. Consider using '#align mul_char.equiv_unit_hom_symm_coe MulChar.equiv_unit_hom_symm_coeₓ'. -/
@[simp]
theorem equiv_unit_hom_symm_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : equiv_to_unit_hom.symm f ↑a = f a :=
@@ -660,7 +660,7 @@ def ringHomComp (χ : MulChar R R') (f : R' →+* R'') : MulChar R R'' :=
lean 3 declaration is
forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {R'' : Type.{u3}} [_inst_3 : CommRing.{u3} R''] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))}, (MulChar.IsNontrivial.{u1, u2} R _inst_1 R' _inst_2 χ) -> (forall {f : RingHom.{u2, u3} R' R'' (NonAssocRing.toNonAssocSemiring.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))}, (Function.Injective.{succ u2, succ u3} R' R'' (coeFn.{max (succ u2) (succ u3), max (succ u2) (succ u3)} (RingHom.{u2, u3} R' R'' (NonAssocRing.toNonAssocSemiring.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))) (fun (_x : RingHom.{u2, u3} R' R'' (NonAssocRing.toNonAssocSemiring.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))) => R' -> R'') (RingHom.hasCoeToFun.{u2, u3} R' R'' (NonAssocRing.toNonAssocSemiring.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))) f)) -> (MulChar.IsNontrivial.{u1, u3} R _inst_1 R'' _inst_3 (MulChar.ringHomComp.{u1, u2, u3} R _inst_1 R' _inst_2 R'' _inst_3 χ f)))
but is expected to have type
- forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {R'' : Type.{u3}} [_inst_3 : CommRing.{u3} R''] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))}, (MulChar.IsNontrivial.{u1, u2} R _inst_1 R' _inst_2 χ) -> (forall {f : RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))}, (Function.Injective.{succ u2, succ u3} R' R'' (FunLike.coe.{max (succ u2) (succ u3), succ u2, succ u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' (fun (_x : R') => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : R') => R'') _x) (MulHomClass.toFunLike.{max u2 u3, u2, u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' R'' (NonUnitalNonAssocSemiring.toMul.{u2} R' (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} R' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))))) (NonUnitalNonAssocSemiring.toMul.{u3} R'' (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u3} R'' (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3))))) (NonUnitalRingHomClass.toMulHomClass.{max u2 u3, u2, u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' R'' (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} R' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2)))) (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u3} R'' (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) (RingHomClass.toNonUnitalRingHomClass.{max u2 u3, u2, u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3))) (RingHom.instRingHomClassRingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3))))))) f)) -> (MulChar.IsNontrivial.{u1, u3} R _inst_1 R'' _inst_3 (MulChar.ringHomComp.{u1, u2, u3} R _inst_1 R' _inst_2 R'' _inst_3 χ f)))
+ forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {R'' : Type.{u3}} [_inst_3 : CommRing.{u3} R''] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))}, (MulChar.IsNontrivial.{u1, u2} R _inst_1 R' _inst_2 χ) -> (forall {f : RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))}, (Function.Injective.{succ u2, succ u3} R' R'' (FunLike.coe.{max (succ u2) (succ u3), succ u2, succ u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' (fun (_x : R') => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : R') => R'') _x) (MulHomClass.toFunLike.{max u2 u3, u2, u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' R'' (NonUnitalNonAssocSemiring.toMul.{u2} R' (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} R' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))))) (NonUnitalNonAssocSemiring.toMul.{u3} R'' (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u3} R'' (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3))))) (NonUnitalRingHomClass.toMulHomClass.{max u2 u3, u2, u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' R'' (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} R' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2)))) (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u3} R'' (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) (RingHomClass.toNonUnitalRingHomClass.{max u2 u3, u2, u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3))) (RingHom.instRingHomClassRingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3))))))) f)) -> (MulChar.IsNontrivial.{u1, u3} R _inst_1 R'' _inst_3 (MulChar.ringHomComp.{u1, u2, u3} R _inst_1 R' _inst_2 R'' _inst_3 χ f)))
Case conversion may be inaccurate. Consider using '#align mul_char.is_nontrivial.comp MulChar.IsNontrivial.compₓ'. -/
/-- Composition with an injective ring homomorphism preserves nontriviality. -/
theorem IsNontrivial.comp {χ : MulChar R R'} (hχ : χ.IsNontrivial) {f : R' →+* R''}
mathlib commit https://github.com/leanprover-community/mathlib/commit/c89fe2d59ae06402c3f55f978016d1ada444f57e
@@ -67,18 +67,22 @@ variable (R : Type u) [CommMonoid R]
-- The target
variable (R' : Type v) [CommMonoidWithZero R']
+#print MulChar /-
/-- Define a structure for multiplicative characters.
A multiplicative character from a commutative monoid `R` to a commutative monoid with zero `R'`
is a homomorphism of (multiplicative) monoids that sends non-units to zero. -/
structure MulChar extends MonoidHom R R' where
map_nonunit' : ∀ a : R, ¬IsUnit a → to_fun a = 0
#align mul_char MulChar
+-/
+#print MulCharClass /-
/-- This is the corresponding extension of `monoid_hom_class`. -/
class MulCharClass (F : Type _) (R R' : outParam <| Type _) [CommMonoid R]
[CommMonoidWithZero R'] extends MonoidHomClass F R R' where
map_nonunit : ∀ (χ : F) {a : R} (ha : ¬IsUnit a), χ a = 0
#align mul_char_class MulCharClass
+-/
attribute [simp] MulCharClass.map_nonunit
@@ -94,14 +98,18 @@ variable {R : Type u} [CommMonoid R]
-- The target
variable {R' : Type v} [CommMonoidWithZero R']
+#print MulChar.coeToFun /-
instance coeToFun : CoeFun (MulChar R R') fun _ => R → R' :=
⟨fun χ => χ.toFun⟩
#align mul_char.coe_to_fun MulChar.coeToFun
+-/
+#print MulChar.Simps.apply /-
/-- See note [custom simps projection] -/
protected def Simps.apply (χ : MulChar R R') : R → R' :=
χ
#align mul_char.simps.apply MulChar.Simps.apply
+-/
initialize_simps_projections MulChar (to_monoid_hom_to_fun → apply, -toMonoidHom)
@@ -109,6 +117,7 @@ section trivial
variable (R R')
+#print MulChar.trivial /-
/-- The trivial multiplicative character. It takes the value `0` on non-units and
the value `1` on units. -/
@[simps]
@@ -125,24 +134,44 @@ noncomputable def trivial : MulChar R R'
simp only [IsUnit.mul_iff, boole_mul]
split_ifs <;> tauto
#align mul_char.trivial MulChar.trivial
+-/
end trivial
+/- warning: mul_char.coe_coe -> MulChar.coe_coe is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} ((fun (_x : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => R -> R') (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ)) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => R -> R') (MonoidHom.hasCoeToFun.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ)
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (forall (a : R), (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : R) => R') a) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R (fun (_x : R) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : R) => R') _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (MulOneClass.toMul.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ)) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ)
+Case conversion may be inaccurate. Consider using '#align mul_char.coe_coe MulChar.coe_coeₓ'. -/
@[simp]
theorem coe_coe (χ : MulChar R R') : (χ.toMonoidHom : R → R') = χ :=
rfl
#align mul_char.coe_coe MulChar.coe_coe
+/- warning: mul_char.to_fun_eq_coe -> MulChar.toFun_eq_coe is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (R -> R') (MonoidHom.toFun.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ)
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (R -> R') (OneHom.toFun.{u1, u2} R R' (MulOneClass.toOne.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toOne.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.toOneHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulChar.toMonoidHom.{u1, u2} R _inst_1 R' _inst_2 χ))) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ)
+Case conversion may be inaccurate. Consider using '#align mul_char.to_fun_eq_coe MulChar.toFun_eq_coeₓ'. -/
@[simp]
theorem toFun_eq_coe (χ : MulChar R R') : χ.toFun = χ :=
rfl
#align mul_char.to_fun_eq_coe MulChar.toFun_eq_coe
+/- warning: mul_char.coe_mk -> MulChar.coe_mk is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (hf : forall (a : R), (Not (IsUnit.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) -> (Eq.{succ u2} R' (MonoidHom.toFun.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) f a) (OfNat.ofNat.{u2} R' 0 (OfNat.mk.{u2} R' 0 (Zero.zero.{u2} R' (MulZeroClass.toHasZero.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))))))), Eq.{max (succ u1) (succ u2)} ((fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.mk.{u1, u2} R _inst_1 R' _inst_2 f hf)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (MulChar.mk.{u1, u2} R _inst_1 R' _inst_2 f hf)) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => R -> R') (MonoidHom.hasCoeToFun.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) f)
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (hf : forall (a : R), (Not (IsUnit.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) -> (Eq.{succ u2} R' (OneHom.toFun.{u1, u2} R R' (MulOneClass.toOne.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toOne.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.toOneHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) f) a) (OfNat.ofNat.{u2} R' 0 (Zero.toOfNat0.{u2} R' (CommMonoidWithZero.toZero.{u2} R' _inst_2))))), Eq.{max (succ u1) (succ u2)} (R -> R') (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (MulChar.mk.{u1, u2} R _inst_1 R' _inst_2 f hf)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R (fun (_x : R) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : R) => R') _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (MulOneClass.toMul.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} R R' (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) f)
+Case conversion may be inaccurate. Consider using '#align mul_char.coe_mk MulChar.coe_mkₓ'. -/
@[simp]
theorem coe_mk (f : R →* R') (hf) : (MulChar.mk f hf : R → R') = f :=
rfl
#align mul_char.coe_mk MulChar.coe_mk
+#print MulChar.ext' /-
/-- Extensionality. See `ext` below for the version that will actually be used. -/
theorem ext' {χ χ' : MulChar R R'} (h : ∀ a, χ a = χ' a) : χ = χ' :=
by
@@ -151,6 +180,7 @@ theorem ext' {χ χ' : MulChar R R'} (h : ∀ a, χ a = χ' a) : χ = χ' :=
congr
exact MonoidHom.ext h
#align mul_char.ext' MulChar.ext'
+-/
instance : MulCharClass (MulChar R R') R R'
where
@@ -160,10 +190,17 @@ instance : MulCharClass (MulChar R R') R R'
map_one χ := χ.map_one'
map_nonunit χ := χ.map_nonunit'
+/- warning: mul_char.map_nonunit -> MulChar.map_nonunit is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) {a : R}, (Not (IsUnit.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) -> (Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ a) (OfNat.ofNat.{u2} R' 0 (OfNat.mk.{u2} R' 0 (Zero.zero.{u2} R' (MulZeroClass.toHasZero.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))))))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) {a : R}, (Not (IsUnit.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) -> (Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ a) (OfNat.ofNat.{u2} R' 0 (Zero.toOfNat0.{u2} R' (CommMonoidWithZero.toZero.{u2} R' _inst_2))))
+Case conversion may be inaccurate. Consider using '#align mul_char.map_nonunit MulChar.map_nonunitₓ'. -/
theorem map_nonunit (χ : MulChar R R') {a : R} (ha : ¬IsUnit a) : χ a = 0 :=
χ.map_nonunit' a ha
#align mul_char.map_nonunit MulChar.map_nonunit
+#print MulChar.ext /-
/-- Extensionality. Since `mul_char`s always take the value zero on non-units, it is sufficient
to compare the values on units. -/
@[ext]
@@ -175,12 +212,15 @@ theorem ext {χ χ' : MulChar R R'} (h : ∀ a : Rˣ, χ a = χ' a) : χ = χ' :
· exact h ha.unit
· rw [map_nonunit χ ha, map_nonunit χ' ha]
#align mul_char.ext MulChar.ext
+-/
+#print MulChar.ext_iff /-
theorem ext_iff {χ χ' : MulChar R R'} : χ = χ' ↔ ∀ a : Rˣ, χ a = χ' a :=
⟨by
rintro rfl a
rfl, ext⟩
#align mul_char.ext_iff MulChar.ext_iff
+-/
/-!
### Equivalence of multiplicative characters with homomorphisms on units
@@ -190,15 +230,33 @@ between `mul_char R R'` and `Rˣ →* R'ˣ`.
-/
+/- warning: mul_char.to_unit_hom -> MulChar.toUnitHom is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'], (MulChar.{u1, u2} R _inst_1 R' _inst_2) -> (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'], (MulChar.{u1, u2} R _inst_1 R' _inst_2) -> (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))
+Case conversion may be inaccurate. Consider using '#align mul_char.to_unit_hom MulChar.toUnitHomₓ'. -/
/-- Turn a `mul_char` into a homomorphism between the unit groups. -/
def toUnitHom (χ : MulChar R R') : Rˣ →* R'ˣ :=
Units.map χ
#align mul_char.to_unit_hom MulChar.toUnitHom
+/- warning: mul_char.coe_to_unit_hom -> MulChar.coe_toUnitHom is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (HasLiftT.mk.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (CoeTCₓ.coe.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (coeBase.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (Units.hasCoe.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) -> (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.hasCoeToFun.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) a)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) a)) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a))
+Case conversion may be inaccurate. Consider using '#align mul_char.coe_to_unit_hom MulChar.coe_toUnitHomₓ'. -/
theorem coe_toUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(χ.toUnitHom a) = χ a :=
rfl
#align mul_char.coe_to_unit_hom MulChar.coe_toUnitHom
+/- warning: mul_char.of_unit_hom -> MulChar.ofUnitHom is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'], (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) -> (MulChar.{u1, u2} R _inst_1 R' _inst_2)
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'], (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) -> (MulChar.{u1, u2} R _inst_1 R' _inst_2)
+Case conversion may be inaccurate. Consider using '#align mul_char.of_unit_hom MulChar.ofUnitHomₓ'. -/
/-- Turn a homomorphism between unit groups into a `mul_char`. -/
noncomputable def ofUnitHom (f : Rˣ →* R'ˣ) : MulChar R R'
where
@@ -223,9 +281,21 @@ noncomputable def ofUnitHom (f : Rˣ →* R'ˣ) : MulChar R R'
simp only [ha, not_false_iff, dif_neg]
#align mul_char.of_unit_hom MulChar.ofUnitHom
+/- warning: mul_char.of_unit_hom_coe -> MulChar.ofUnitHom_coe is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 f) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a)) ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (HasLiftT.mk.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (CoeTCₓ.coe.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (coeBase.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (Units.hasCoe.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) -> (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.hasCoeToFun.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) f a))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 f) (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) f a))
+Case conversion may be inaccurate. Consider using '#align mul_char.of_unit_hom_coe MulChar.ofUnitHom_coeₓ'. -/
theorem ofUnitHom_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : of_unit_hom f ↑a = f a := by simp [of_unit_hom]
#align mul_char.of_unit_hom_coe MulChar.ofUnitHom_coe
+/- warning: mul_char.equiv_to_unit_hom -> MulChar.equivToUnitHom is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'], Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'], Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))
+Case conversion may be inaccurate. Consider using '#align mul_char.equiv_to_unit_hom MulChar.equivToUnitHomₓ'. -/
/-- The equivalence between multiplicative characters and homomorphisms of unit groups. -/
noncomputable def equivToUnitHom : MulChar R R' ≃ (Rˣ →* R'ˣ)
where
@@ -241,21 +311,45 @@ noncomputable def equivToUnitHom : MulChar R R' ≃ (Rˣ →* R'ˣ)
rw [coe_to_unit_hom, of_unit_hom_coe]
#align mul_char.equiv_to_unit_hom MulChar.equivToUnitHom
+/- warning: mul_char.to_unit_hom_eq -> MulChar.toUnitHom_eq is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (coeFn.{max 1 (max (max (succ u1) (succ u2)) (succ u2) (succ u1)) (max (succ u2) (succ u1)) (succ u1) (succ u2), max (max (succ u1) (succ u2)) (succ u2) (succ u1)} (Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (fun (_x : Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) => (MulChar.{u1, u2} R _inst_1 R' _inst_2) -> (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (Equiv.hasCoeToFun.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ)
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.toUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ)
+Case conversion may be inaccurate. Consider using '#align mul_char.to_unit_hom_eq MulChar.toUnitHom_eqₓ'. -/
@[simp]
theorem toUnitHom_eq (χ : MulChar R R') : to_unit_hom χ = equiv_to_unit_hom χ :=
rfl
#align mul_char.to_unit_hom_eq MulChar.toUnitHom_eq
+/- warning: mul_char.of_unit_hom_eq -> MulChar.ofUnitHom_eq is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))), Eq.{max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (coeFn.{max 1 (max (max (succ u2) (succ u1)) (succ u1) (succ u2)) (max (succ u1) (succ u2)) (succ u2) (succ u1), max (max (succ u2) (succ u1)) (succ u1) (succ u2)} (Equiv.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (fun (_x : Equiv.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) => (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) -> (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.hasCoeToFun.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) χ)
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))), Eq.{max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.ofUnitHom.{u1, u2} R _inst_1 R' _inst_2 χ) (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => MulChar.{u1, u2} R _inst_1 R' _inst_2) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) χ)
+Case conversion may be inaccurate. Consider using '#align mul_char.of_unit_hom_eq MulChar.ofUnitHom_eqₓ'. -/
@[simp]
theorem ofUnitHom_eq (χ : Rˣ →* R'ˣ) : of_unit_hom χ = equiv_to_unit_hom.symm χ :=
rfl
#align mul_char.of_unit_hom_eq MulChar.ofUnitHom_eq
+/- warning: mul_char.coe_equiv_to_unit_hom -> MulChar.coe_equivToUnitHom is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (HasLiftT.mk.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (CoeTCₓ.coe.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (coeBase.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (Units.hasCoe.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) -> (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.hasCoeToFun.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (coeFn.{max 1 (max (max (succ u1) (succ u2)) (succ u2) (succ u1)) (max (succ u2) (succ u1)) (succ u1) (succ u2), max (max (succ u1) (succ u2)) (succ u2) (succ u1)} (Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (fun (_x : Equiv.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) => (MulChar.{u1, u2} R _inst_1 R' _inst_2) -> (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (Equiv.hasCoeToFun.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ) a)) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} ((fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) χ) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} ((fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) χ) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} ((fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) χ) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MulChar.{u1, u2} R _inst_1 R' _inst_2) => MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2) χ) a)) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a))
+Case conversion may be inaccurate. Consider using '#align mul_char.coe_equiv_to_unit_hom MulChar.coe_equivToUnitHomₓ'. -/
@[simp]
theorem coe_equivToUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(equiv_to_unit_hom χ a) = χ a :=
coe_to_unit_hom χ a
#align mul_char.coe_equiv_to_unit_hom MulChar.coe_equivToUnitHom
+/- warning: mul_char.equiv_unit_hom_symm_coe -> MulChar.equiv_unit_hom_symm_coe is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (coeFn.{max 1 (max (max (succ u2) (succ u1)) (succ u1) (succ u2)) (max (succ u1) (succ u2)) (succ u2) (succ u1), max (max (succ u2) (succ u1)) (succ u1) (succ u2)} (Equiv.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (fun (_x : Equiv.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) => (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) -> (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.hasCoeToFun.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u1) (succ u2), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) f) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a)) ((fun (a : Type.{u2}) (b : Type.{u2}) [self : HasLiftT.{succ u2, succ u2} a b] => self.0) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (HasLiftT.mk.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (CoeTCₓ.coe.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (coeBase.{succ u2, succ u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) R' (Units.hasCoe.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) -> (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHom.hasCoeToFun.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.mulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.mulOneClass.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) f a))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (f : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (FunLike.coe.{max (succ u2) (succ u1), max (succ u2) (succ u1), max (succ u2) (succ u1)} (Equiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (fun (_x : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => (fun (x._@.Mathlib.Logic.Equiv.Defs._hyg.808 : MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) => MulChar.{u1, u2} R _inst_1 R' _inst_2) _x) (Equiv.instFunLikeEquiv.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.{u1, u2} R _inst_1 R' _inst_2)) (Equiv.symm.{max (succ u2) (succ u1), max (succ u2) (succ u1)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MulChar.equivToUnitHom.{u1, u2} R _inst_1 R' _inst_2)) f) (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) (Units.val.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)) (FunLike.coe.{max (succ u1) (succ u2), succ u1, succ u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (fun (_x : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) => Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) _x) (MulHomClass.toFunLike.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MulOneClass.toMul.{u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))) (MulOneClass.toMul.{u2} (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (MonoidHomClass.toMulHomClass.{max u1 u2, u1, u2} (MonoidHom.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (MonoidHom.monoidHomClass.{u1, u2} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))) (Units.instMulOneClassUnits.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) (Units.instMulOneClassUnits.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) f a))
+Case conversion may be inaccurate. Consider using '#align mul_char.equiv_unit_hom_symm_coe MulChar.equiv_unit_hom_symm_coeₓ'. -/
@[simp]
theorem equiv_unit_hom_symm_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : equiv_to_unit_hom.symm f ↑a = f a :=
of_unit_hom_coe f a
@@ -268,65 +362,114 @@ The multiplicative characters `R → R'` form a commutative group.
-/
+/- warning: mul_char.map_one -> MulChar.map_one is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ (OfNat.ofNat.{u1} R 1 (OfNat.mk.{u1} R 1 (One.one.{u1} R (MulOneClass.toHasOne.{u1} R (Monoid.toMulOneClass.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))))) (OfNat.ofNat.{u2} R' 1 (OfNat.mk.{u2} R' 1 (One.one.{u2} R' (MulOneClass.toHasOne.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ (OfNat.ofNat.{u1} R 1 (One.toOfNat1.{u1} R (Monoid.toOne.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) (OfNat.ofNat.{u2} R' 1 (One.toOfNat1.{u2} R' (Monoid.toOne.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))
+Case conversion may be inaccurate. Consider using '#align mul_char.map_one MulChar.map_oneₓ'. -/
protected theorem map_one (χ : MulChar R R') : χ (1 : R) = 1 :=
χ.map_one'
#align mul_char.map_one MulChar.map_one
+/- warning: mul_char.map_zero -> MulChar.map_zero is a dubious translation:
+lean 3 declaration is
+ forall {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] {R : Type.{u1}} [_inst_3 : CommMonoidWithZero.{u1} R] [_inst_4 : Nontrivial.{u1} R] (χ : MulChar.{u1, u2} R (CommMonoidWithZero.toCommMonoid.{u1} R _inst_3) R' _inst_2), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommMonoidWithZero.toCommMonoid.{u1} R _inst_3) R' _inst_2) (fun (_x : MulChar.{u1, u2} R (CommMonoidWithZero.toCommMonoid.{u1} R _inst_3) R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R (CommMonoidWithZero.toCommMonoid.{u1} R _inst_3) R' _inst_2) χ (OfNat.ofNat.{u1} R 0 (OfNat.mk.{u1} R 0 (Zero.zero.{u1} R (MulZeroClass.toHasZero.{u1} R (MulZeroOneClass.toMulZeroClass.{u1} R (MonoidWithZero.toMulZeroOneClass.{u1} R (CommMonoidWithZero.toMonoidWithZero.{u1} R _inst_3)))))))) (OfNat.ofNat.{u2} R' 0 (OfNat.mk.{u2} R' 0 (Zero.zero.{u2} R' (MulZeroClass.toHasZero.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))))
+but is expected to have type
+ forall {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] {R : Type.{u1}} [_inst_3 : CommMonoidWithZero.{u1} R] [_inst_4 : Nontrivial.{u1} R] (χ : MulChar.{u1, u2} R (CommMonoidWithZero.toCommMonoid.{u1} R _inst_3) R' _inst_2), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R (CommMonoidWithZero.toCommMonoid.{u1} R _inst_3) R' _inst_2 χ (OfNat.ofNat.{u1} R 0 (Zero.toOfNat0.{u1} R (CommMonoidWithZero.toZero.{u1} R _inst_3)))) (OfNat.ofNat.{u2} R' 0 (Zero.toOfNat0.{u2} R' (CommMonoidWithZero.toZero.{u2} R' _inst_2)))
+Case conversion may be inaccurate. Consider using '#align mul_char.map_zero MulChar.map_zeroₓ'. -/
/-- If the domain has a zero (and is nontrivial), then `χ 0 = 0`. -/
protected theorem map_zero {R : Type u} [CommMonoidWithZero R] [Nontrivial R] (χ : MulChar R R') :
χ (0 : R) = 0 := by rw [map_nonunit χ not_isUnit_zero]
#align mul_char.map_zero MulChar.map_zero
+/- warning: mul_char.map_ring_char -> MulChar.map_ringChar is a dubious translation:
+lean 3 declaration is
+ forall {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] {R : Type.{u1}} [_inst_3 : CommRing.{u1} R] [_inst_4 : Nontrivial.{u1} R] (χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_3) R' _inst_2), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_3) R' _inst_2) (fun (_x : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_3) R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_3) R' _inst_2) χ ((fun (a : Type) (b : Type.{u1}) [self : HasLiftT.{1, succ u1} a b] => self.0) Nat R (HasLiftT.mk.{1, succ u1} Nat R (CoeTCₓ.coe.{1, succ u1} Nat R (Nat.castCoe.{u1} R (AddMonoidWithOne.toNatCast.{u1} R (AddGroupWithOne.toAddMonoidWithOne.{u1} R (AddCommGroupWithOne.toAddGroupWithOne.{u1} R (Ring.toAddCommGroupWithOne.{u1} R (CommRing.toRing.{u1} R _inst_3)))))))) (ringChar.{u1} R (NonAssocRing.toNonAssocSemiring.{u1} R (Ring.toNonAssocRing.{u1} R (CommRing.toRing.{u1} R _inst_3)))))) (OfNat.ofNat.{u2} R' 0 (OfNat.mk.{u2} R' 0 (Zero.zero.{u2} R' (MulZeroClass.toHasZero.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))))
+but is expected to have type
+ forall {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] {R : Type.{u1}} [_inst_3 : CommRing.{u1} R] [_inst_4 : Nontrivial.{u1} R] (χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_3) R' _inst_2), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_3) R' _inst_2 χ (Nat.cast.{u1} R (Semiring.toNatCast.{u1} R (CommSemiring.toSemiring.{u1} R (CommRing.toCommSemiring.{u1} R _inst_3))) (ringChar.{u1} R (Semiring.toNonAssocSemiring.{u1} R (CommSemiring.toSemiring.{u1} R (CommRing.toCommSemiring.{u1} R _inst_3)))))) (OfNat.ofNat.{u2} R' 0 (Zero.toOfNat0.{u2} R' (CommMonoidWithZero.toZero.{u2} R' _inst_2)))
+Case conversion may be inaccurate. Consider using '#align mul_char.map_ring_char MulChar.map_ringCharₓ'. -/
/-- If the domain is a ring `R`, then `χ (ring_char R) = 0`. -/
theorem map_ringChar {R : Type u} [CommRing R] [Nontrivial R] (χ : MulChar R R') :
χ (ringChar R) = 0 := by rw [ringChar.Nat.cast_ringChar, χ.map_zero]
#align mul_char.map_ring_char MulChar.map_ringChar
+#print MulChar.hasOne /-
noncomputable instance hasOne : One (MulChar R R') :=
⟨trivial R R'⟩
#align mul_char.has_one MulChar.hasOne
+-/
+#print MulChar.inhabited /-
noncomputable instance inhabited : Inhabited (MulChar R R') :=
⟨1⟩
#align mul_char.inhabited MulChar.inhabited
+-/
+/- warning: mul_char.one_apply_coe -> MulChar.one_apply_coe is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (OfNat.ofNat.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) 1 (OfNat.mk.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) 1 (One.one.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.hasOne.{u1, u2} R _inst_1 R' _inst_2)))) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (HasLiftT.mk.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (CoeTCₓ.coe.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (coeBase.{succ u1, succ u1} (Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)) R (Units.hasCoe.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1))))) a)) (OfNat.ofNat.{u2} R' 1 (OfNat.mk.{u2} R' 1 (One.one.{u2} R' (MulOneClass.toHasOne.{u2} R' (MulZeroOneClass.toMulOneClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (a : Units.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1)), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (OfNat.ofNat.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) 1 (One.toOfNat1.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.hasOne.{u1, u2} R _inst_1 R' _inst_2))) (Units.val.{u1} R (CommMonoid.toMonoid.{u1} R _inst_1) a)) (OfNat.ofNat.{u2} R' 1 (One.toOfNat1.{u2} R' (Monoid.toOne.{u2} R' (MonoidWithZero.toMonoid.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))
+Case conversion may be inaccurate. Consider using '#align mul_char.one_apply_coe MulChar.one_apply_coeₓ'. -/
/-- Evaluation of the trivial character -/
@[simp]
theorem one_apply_coe (a : Rˣ) : (1 : MulChar R R') a = 1 := by classical exact dif_pos a.is_unit
#align mul_char.one_apply_coe MulChar.one_apply_coe
+#print MulChar.mul /-
/-- Multiplication of multiplicative characters. (This needs the target to be commutative.) -/
def mul (χ χ' : MulChar R R') : MulChar R R' :=
{ χ.toMonoidHom * χ'.toMonoidHom with
toFun := χ * χ'
map_nonunit' := fun a ha => by simp [map_nonunit χ ha] }
#align mul_char.mul MulChar.mul
+-/
+#print MulChar.hasMul /-
instance hasMul : Mul (MulChar R R') :=
⟨mul⟩
#align mul_char.has_mul MulChar.hasMul
+-/
+/- warning: mul_char.mul_apply -> MulChar.mul_apply is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (χ' : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : R), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (instHMul.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.hasMul.{u1, u2} R _inst_1 R' _inst_2)) χ χ') a) (HMul.hMul.{u2, u2, u2} R' R' R' (instHMul.{u2} R' (MulZeroClass.toHasMul.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ a) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ' a))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (χ' : MulChar.{u1, u2} R _inst_1 R' _inst_2) (a : R), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (instHMul.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.hasMul.{u1, u2} R _inst_1 R' _inst_2)) χ χ') a) (HMul.hMul.{u2, u2, u2} R' R' R' (instHMul.{u2} R' (MulZeroClass.toMul.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2))))) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ a) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ' a))
+Case conversion may be inaccurate. Consider using '#align mul_char.mul_apply MulChar.mul_applyₓ'. -/
theorem mul_apply (χ χ' : MulChar R R') (a : R) : (χ * χ') a = χ a * χ' a :=
rfl
#align mul_char.mul_apply MulChar.mul_apply
+/- warning: mul_char.coe_to_fun_mul -> MulChar.coeToFun_mul is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (χ' : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{succ (max u1 u2)} (R -> R') (coeFn.{succ (max u1 u2), succ (max u1 u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (instHMul.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.hasMul.{u1, u2} R _inst_1 R' _inst_2)) χ χ')) (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (R -> R') (R -> R') (R -> R') (instHMul.{max u1 u2} (R -> R') (Pi.instMul.{u1, u2} R (fun (ᾰ : R) => R') (fun (i : R) => MulZeroClass.toHasMul.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (fun (_x : MulChar.{u1, u2} R _inst_1 R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' _inst_2) χ'))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' _inst_2) (χ' : MulChar.{u1, u2} R _inst_1 R' _inst_2), Eq.{max (succ u1) (succ u2)} (R -> R') (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.{u1, u2} R _inst_1 R' _inst_2) (instHMul.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' _inst_2) (MulChar.hasMul.{u1, u2} R _inst_1 R' _inst_2)) χ χ')) (HMul.hMul.{max u1 u2, max u1 u2, max u1 u2} (R -> R') (R -> R') (R -> R') (instHMul.{max u1 u2} (R -> R') (Pi.instMul.{u1, u2} R (fun (ᾰ : R) => R') (fun (i : R) => MulZeroClass.toMul.{u2} R' (MulZeroOneClass.toMulZeroClass.{u2} R' (MonoidWithZero.toMulZeroOneClass.{u2} R' (CommMonoidWithZero.toMonoidWithZero.{u2} R' _inst_2)))))) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ) (MulChar.toFun'.{u1, u2} R _inst_1 R' _inst_2 χ'))
+Case conversion may be inaccurate. Consider using '#align mul_char.coe_to_fun_mul MulChar.coeToFun_mulₓ'. -/
@[simp]
theorem coeToFun_mul (χ χ' : MulChar R R') : ⇑(χ * χ') = χ * χ' :=
rfl
#align mul_char.coe_to_fun_mul MulChar.coeToFun_mul
+#print MulChar.one_mul /-
protected theorem one_mul (χ : MulChar R R') : (1 : MulChar R R') * χ = χ :=
by
ext
simp
#align mul_char.one_mul MulChar.one_mul
+-/
+#print MulChar.mul_one /-
protected theorem mul_one (χ : MulChar R R') : χ * 1 = χ :=
by
ext
simp
#align mul_char.mul_one MulChar.mul_one
+-/
+#print MulChar.inv /-
/-- The inverse of a multiplicative character. We define it as `inverse ∘ χ`. -/
noncomputable def inv (χ : MulChar R R') : MulChar R R' :=
{
@@ -335,22 +478,34 @@ noncomputable def inv (χ : MulChar R R') : MulChar R R' :=
toFun := fun a => MonoidWithZero.inverse (χ a)
map_nonunit' := fun a ha => by simp [map_nonunit _ ha] }
#align mul_char.inv MulChar.inv
+-/
+#print MulChar.hasInv /-
noncomputable instance hasInv : Inv (MulChar R R') :=
⟨inv⟩
#align mul_char.has_inv MulChar.hasInv
+-/
+#print MulChar.inv_apply_eq_inv /-
/-- The inverse of a multiplicative character `χ`, applied to `a`, is the inverse of `χ a`. -/
theorem inv_apply_eq_inv (χ : MulChar R R') (a : R) : χ⁻¹ a = Ring.inverse (χ a) :=
Eq.refl <| inv χ a
#align mul_char.inv_apply_eq_inv MulChar.inv_apply_eq_inv
+-/
+/- warning: mul_char.inv_apply_eq_inv' -> MulChar.inv_apply_eq_inv' is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_3 : Field.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (a : R), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (fun (_x : MulChar.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (Inv.inv.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (MulChar.hasInv.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) χ) a) (Inv.inv.{u2} R' (DivInvMonoid.toHasInv.{u2} R' (DivisionRing.toDivInvMonoid.{u2} R' (Field.toDivisionRing.{u2} R' _inst_3))) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (fun (_x : MulChar.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) => R -> R') (MulChar.coeToFun.{u1, u2} R _inst_1 R' (CommSemiring.toCommMonoidWithZero.{u2} R' (Semifield.toCommSemiring.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) χ a))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommMonoid.{u1} R] {R' : Type.{u2}} [_inst_3 : Field.{u2} R'] (χ : MulChar.{u1, u2} R _inst_1 R' (CommGroupWithZero.toCommMonoidWithZero.{u2} R' (Semifield.toCommGroupWithZero.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (a : R), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R _inst_1 R' (CommGroupWithZero.toCommMonoidWithZero.{u2} R' (Semifield.toCommGroupWithZero.{u2} R' (Field.toSemifield.{u2} R' _inst_3))) (Inv.inv.{max u1 u2} (MulChar.{u1, u2} R _inst_1 R' (CommGroupWithZero.toCommMonoidWithZero.{u2} R' (Semifield.toCommGroupWithZero.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) (MulChar.hasInv.{u1, u2} R _inst_1 R' (CommGroupWithZero.toCommMonoidWithZero.{u2} R' (Semifield.toCommGroupWithZero.{u2} R' (Field.toSemifield.{u2} R' _inst_3)))) χ) a) (Inv.inv.{u2} R' (Field.toInv.{u2} R' _inst_3) (MulChar.toFun'.{u1, u2} R _inst_1 R' (CommGroupWithZero.toCommMonoidWithZero.{u2} R' (Semifield.toCommGroupWithZero.{u2} R' (Field.toSemifield.{u2} R' _inst_3))) χ a))
+Case conversion may be inaccurate. Consider using '#align mul_char.inv_apply_eq_inv' MulChar.inv_apply_eq_inv'ₓ'. -/
/-- The inverse of a multiplicative character `χ`, applied to `a`, is the inverse of `χ a`.
Variant when the target is a field -/
theorem inv_apply_eq_inv' {R' : Type v} [Field R'] (χ : MulChar R R') (a : R) : χ⁻¹ a = (χ a)⁻¹ :=
(inv_apply_eq_inv χ a).trans <| Ring.inverse_eq_inv (χ a)
#align mul_char.inv_apply_eq_inv' MulChar.inv_apply_eq_inv'
+#print MulChar.inv_apply /-
/-- When the domain has a zero, then the inverse of a multiplicative character `χ`,
applied to `a`, is `χ` applied to the inverse of `a`. -/
theorem inv_apply {R : Type u} [CommMonoidWithZero R] (χ : MulChar R R') (a : R) :
@@ -366,13 +521,21 @@ theorem inv_apply {R : Type u} [CommMonoidWithZero R] (χ : MulChar R R') (a : R
-- `nontriviality R` by itself doesn't do it
rw [map_nonunit _ ha, Ring.inverse_non_unit a ha, MulChar.map_zero χ]
#align mul_char.inv_apply MulChar.inv_apply
+-/
+/- warning: mul_char.inv_apply' -> MulChar.inv_apply' is a dubious translation:
+lean 3 declaration is
+ forall {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] {R : Type.{u1}} [_inst_3 : Field.{u1} R] (χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (a : R), Eq.{succ u2} R' (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (fun (_x : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (Inv.inv.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (MulChar.hasInv.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) χ) a) (coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (fun (_x : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) => R -> R') (MulChar.coeToFun.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) χ (Inv.inv.{u1} R (DivInvMonoid.toHasInv.{u1} R (DivisionRing.toDivInvMonoid.{u1} R (Field.toDivisionRing.{u1} R _inst_3))) a))
+but is expected to have type
+ forall {R' : Type.{u2}} [_inst_2 : CommMonoidWithZero.{u2} R'] {R : Type.{u1}} [_inst_3 : Field.{u1} R] (χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (a : R), Eq.{succ u2} R' (MulChar.toFun'.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2 (Inv.inv.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) (MulChar.hasInv.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2) χ) a) (MulChar.toFun'.{u1, u2} R (CommRing.toCommMonoid.{u1} R (EuclideanDomain.toCommRing.{u1} R (Field.toEuclideanDomain.{u1} R _inst_3))) R' _inst_2 χ (Inv.inv.{u1} R (Field.toInv.{u1} R _inst_3) a))
+Case conversion may be inaccurate. Consider using '#align mul_char.inv_apply' MulChar.inv_apply'ₓ'. -/
/-- When the domain has a zero, then the inverse of a multiplicative character `χ`,
applied to `a`, is `χ` applied to the inverse of `a`. -/
theorem inv_apply' {R : Type u} [Field R] (χ : MulChar R R') (a : R) : χ⁻¹ a = χ a⁻¹ :=
(inv_apply χ a).trans <| congr_arg _ (Ring.inverse_eq_inv a)
#align mul_char.inv_apply' MulChar.inv_apply'
+#print MulChar.inv_mul /-
/-- The product of a character with its inverse is the trivial character. -/
@[simp]
theorem inv_mul (χ : MulChar R R') : χ⁻¹ * χ = 1 :=
@@ -381,7 +544,9 @@ theorem inv_mul (χ : MulChar R R') : χ⁻¹ * χ = 1 :=
rw [coe_to_fun_mul, Pi.mul_apply, inv_apply_eq_inv,
Ring.inverse_mul_cancel _ (IsUnit.map _ x.is_unit), one_apply_coe]
#align mul_char.inv_mul MulChar.inv_mul
+-/
+#print MulChar.commGroup /-
/-- The commutative group structure on `mul_char R R'`. -/
noncomputable instance commGroup : CommGroup (MulChar R R') :=
{ one := 1
@@ -399,7 +564,9 @@ noncomputable instance commGroup : CommGroup (MulChar R R') :=
one_mul
mul_one }
#align mul_char.comm_group MulChar.commGroup
+-/
+#print MulChar.pow_apply_coe /-
/-- If `a` is a unit and `n : ℕ`, then `(χ ^ n) a = (χ a) ^ n`. -/
theorem pow_apply_coe (χ : MulChar R R') (n : ℕ) (a : Rˣ) : (χ ^ n) a = χ a ^ n :=
by
@@ -407,7 +574,9 @@ theorem pow_apply_coe (χ : MulChar R R') (n : ℕ) (a : Rˣ) : (χ ^ n) a = χ
· rw [pow_zero, pow_zero, one_apply_coe]
· rw [pow_succ, pow_succ, mul_apply, ih]
#align mul_char.pow_apply_coe MulChar.pow_apply_coe
+-/
+#print MulChar.pow_apply' /-
/-- If `n` is positive, then `(χ ^ n) a = (χ a) ^ n`. -/
theorem pow_apply' (χ : MulChar R R') {n : ℕ} (hn : 0 < n) (a : R) : (χ ^ n) a = χ a ^ n :=
by
@@ -415,6 +584,7 @@ theorem pow_apply' (χ : MulChar R R') {n : ℕ} (hn : 0 < n) (a : R) : (χ ^ n)
· exact pow_apply_coe χ n ha.unit
· rw [map_nonunit (χ ^ n) ha, map_nonunit χ ha, zero_pow hn]
#align mul_char.pow_apply' MulChar.pow_apply'
+-/
end MulChar
@@ -440,21 +610,33 @@ universe u v w
variable {R : Type u} [CommRing R] {R' : Type v} [CommRing R'] {R'' : Type w} [CommRing R'']
+#print MulChar.IsNontrivial /-
/-- A multiplicative character is *nontrivial* if it takes a value `≠ 1` on a unit. -/
def IsNontrivial (χ : MulChar R R') : Prop :=
∃ a : Rˣ, χ a ≠ 1
#align mul_char.is_nontrivial MulChar.IsNontrivial
+-/
+#print MulChar.isNontrivial_iff /-
/-- A multiplicative character is nontrivial iff it is not the trivial character. -/
theorem isNontrivial_iff (χ : MulChar R R') : χ.IsNontrivial ↔ χ ≠ 1 := by
simp only [is_nontrivial, Ne.def, ext_iff, not_forall, one_apply_coe]
#align mul_char.is_nontrivial_iff MulChar.isNontrivial_iff
+-/
+#print MulChar.IsQuadratic /-
/-- A multiplicative character is *quadratic* if it takes only the values `0`, `1`, `-1`. -/
def IsQuadratic (χ : MulChar R R') : Prop :=
∀ a, χ a = 0 ∨ χ a = 1 ∨ χ a = -1
#align mul_char.is_quadratic MulChar.IsQuadratic
+-/
+/- warning: mul_char.is_quadratic.eq_of_eq_coe -> MulChar.IsQuadratic.eq_of_eq_coe is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {R'' : Type.{u3}} [_inst_3 : CommRing.{u3} R''] {χ : MulChar.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)}, (MulChar.IsQuadratic.{u1, 0} R _inst_1 Int Int.commRing χ) -> (forall {χ' : MulChar.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)}, (MulChar.IsQuadratic.{u2, 0} R' _inst_2 Int Int.commRing χ') -> (forall [_inst_4 : Nontrivial.{u3} R''], (Ne.{1} Nat (ringChar.{u3} R'' (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))) (OfNat.ofNat.{0} Nat 2 (OfNat.mk.{0} Nat 2 (bit0.{0} Nat Nat.hasAdd (One.one.{0} Nat Nat.hasOne))))) -> (forall {a : R} {a' : R'}, (Eq.{succ u3} R'' ((fun (a : Type) (b : Type.{u3}) [self : HasLiftT.{1, succ u3} a b] => self.0) Int R'' (HasLiftT.mk.{1, succ u3} Int R'' (CoeTCₓ.coe.{1, succ u3} Int R'' (Int.castCoe.{u3} R'' (AddGroupWithOne.toHasIntCast.{u3} R'' (AddCommGroupWithOne.toAddGroupWithOne.{u3} R'' (Ring.toAddCommGroupWithOne.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3))))))) (coeFn.{succ u1, succ u1} (MulChar.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) (fun (_x : MulChar.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) => R -> Int) (MulChar.coeToFun.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) χ a)) ((fun (a : Type) (b : Type.{u3}) [self : HasLiftT.{1, succ u3} a b] => self.0) Int R'' (HasLiftT.mk.{1, succ u3} Int R'' (CoeTCₓ.coe.{1, succ u3} Int R'' (Int.castCoe.{u3} R'' (AddGroupWithOne.toHasIntCast.{u3} R'' (AddCommGroupWithOne.toAddGroupWithOne.{u3} R'' (Ring.toAddCommGroupWithOne.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3))))))) (coeFn.{succ u2, succ u2} (MulChar.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) (fun (_x : MulChar.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) => R' -> Int) (MulChar.coeToFun.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) χ' a'))) -> (Eq.{1} Int (coeFn.{succ u1, succ u1} (MulChar.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) (fun (_x : MulChar.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) => R -> Int) (MulChar.coeToFun.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) χ a) (coeFn.{succ u2, succ u2} (MulChar.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) (fun (_x : MulChar.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) => R' -> Int) (MulChar.coeToFun.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CommSemiring.toCommMonoidWithZero.{0} Int Int.commSemiring)) χ' a')))))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {R'' : Type.{u3}} [_inst_3 : CommRing.{u3} R''] {χ : MulChar.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CancelCommMonoidWithZero.toCommMonoidWithZero.{0} Int (IsDomain.toCancelCommMonoidWithZero.{0} Int Int.instCommSemiringInt (LinearOrderedRing.isDomain.{0} Int (LinearOrderedCommRing.toLinearOrderedRing.{0} Int Int.linearOrderedCommRing))))}, (MulChar.IsQuadratic.{u1, 0} R _inst_1 Int Int.instCommRingInt χ) -> (forall {χ' : MulChar.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CancelCommMonoidWithZero.toCommMonoidWithZero.{0} Int (IsDomain.toCancelCommMonoidWithZero.{0} Int Int.instCommSemiringInt (LinearOrderedRing.isDomain.{0} Int (LinearOrderedCommRing.toLinearOrderedRing.{0} Int Int.linearOrderedCommRing))))}, (MulChar.IsQuadratic.{u2, 0} R' _inst_2 Int Int.instCommRingInt χ') -> (forall [_inst_4 : Nontrivial.{u3} R''], (Ne.{1} Nat (ringChar.{u3} R'' (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) (OfNat.ofNat.{0} Nat 2 (instOfNatNat 2))) -> (forall {a : R} {a' : R'}, (Eq.{succ u3} R'' (Int.cast.{u3} R'' (Ring.toIntCast.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)) (MulChar.toFun'.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CancelCommMonoidWithZero.toCommMonoidWithZero.{0} Int (IsDomain.toCancelCommMonoidWithZero.{0} Int Int.instCommSemiringInt (LinearOrderedRing.isDomain.{0} Int (LinearOrderedCommRing.toLinearOrderedRing.{0} Int Int.linearOrderedCommRing)))) χ a)) (Int.cast.{u3} R'' (Ring.toIntCast.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)) (MulChar.toFun'.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CancelCommMonoidWithZero.toCommMonoidWithZero.{0} Int (IsDomain.toCancelCommMonoidWithZero.{0} Int Int.instCommSemiringInt (LinearOrderedRing.isDomain.{0} Int (LinearOrderedCommRing.toLinearOrderedRing.{0} Int Int.linearOrderedCommRing)))) χ' a'))) -> (Eq.{1} Int (MulChar.toFun'.{u1, 0} R (CommRing.toCommMonoid.{u1} R _inst_1) Int (CancelCommMonoidWithZero.toCommMonoidWithZero.{0} Int (IsDomain.toCancelCommMonoidWithZero.{0} Int Int.instCommSemiringInt (LinearOrderedRing.isDomain.{0} Int (LinearOrderedCommRing.toLinearOrderedRing.{0} Int Int.linearOrderedCommRing)))) χ a) (MulChar.toFun'.{u2, 0} R' (CommRing.toCommMonoid.{u2} R' _inst_2) Int (CancelCommMonoidWithZero.toCommMonoidWithZero.{0} Int (IsDomain.toCancelCommMonoidWithZero.{0} Int Int.instCommSemiringInt (LinearOrderedRing.isDomain.{0} Int (LinearOrderedCommRing.toLinearOrderedRing.{0} Int Int.linearOrderedCommRing)))) χ' a')))))
+Case conversion may be inaccurate. Consider using '#align mul_char.is_quadratic.eq_of_eq_coe MulChar.IsQuadratic.eq_of_eq_coeₓ'. -/
/-- If two values of quadratic characters with target `ℤ` agree after coercion into a ring
of characteristic not `2`, then they agree in `ℤ`. -/
theorem IsQuadratic.eq_of_eq_coe {χ : MulChar R ℤ} (hχ : IsQuadratic χ) {χ' : MulChar R' ℤ}
@@ -463,6 +645,7 @@ theorem IsQuadratic.eq_of_eq_coe {χ : MulChar R ℤ} (hχ : IsQuadratic χ) {χ
Int.cast_injOn_of_ringChar_ne_two hR'' (hχ a) (hχ' a') h
#align mul_char.is_quadratic.eq_of_eq_coe MulChar.IsQuadratic.eq_of_eq_coe
+#print MulChar.ringHomComp /-
/-- We can post-compose a multiplicative character with a ring homomorphism. -/
@[simps]
def ringHomComp (χ : MulChar R R') (f : R' →+* R'') : MulChar R R'' :=
@@ -471,7 +654,14 @@ def ringHomComp (χ : MulChar R R') (f : R' →+* R'') : MulChar R R'' :=
toFun := fun a => f (χ a)
map_nonunit' := fun a ha => by simp only [map_nonunit χ ha, map_zero] }
#align mul_char.ring_hom_comp MulChar.ringHomComp
+-/
+/- warning: mul_char.is_nontrivial.comp -> MulChar.IsNontrivial.comp is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {R'' : Type.{u3}} [_inst_3 : CommRing.{u3} R''] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))}, (MulChar.IsNontrivial.{u1, u2} R _inst_1 R' _inst_2 χ) -> (forall {f : RingHom.{u2, u3} R' R'' (NonAssocRing.toNonAssocSemiring.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))}, (Function.Injective.{succ u2, succ u3} R' R'' (coeFn.{max (succ u2) (succ u3), max (succ u2) (succ u3)} (RingHom.{u2, u3} R' R'' (NonAssocRing.toNonAssocSemiring.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))) (fun (_x : RingHom.{u2, u3} R' R'' (NonAssocRing.toNonAssocSemiring.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))) => R' -> R'') (RingHom.hasCoeToFun.{u2, u3} R' R'' (NonAssocRing.toNonAssocSemiring.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) (NonAssocRing.toNonAssocSemiring.{u3} R'' (Ring.toNonAssocRing.{u3} R'' (CommRing.toRing.{u3} R'' _inst_3)))) f)) -> (MulChar.IsNontrivial.{u1, u3} R _inst_1 R'' _inst_3 (MulChar.ringHomComp.{u1, u2, u3} R _inst_1 R' _inst_2 R'' _inst_3 χ f)))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {R'' : Type.{u3}} [_inst_3 : CommRing.{u3} R''] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))}, (MulChar.IsNontrivial.{u1, u2} R _inst_1 R' _inst_2 χ) -> (forall {f : RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))}, (Function.Injective.{succ u2, succ u3} R' R'' (FunLike.coe.{max (succ u2) (succ u3), succ u2, succ u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' (fun (_x : R') => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : R') => R'') _x) (MulHomClass.toFunLike.{max u2 u3, u2, u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' R'' (NonUnitalNonAssocSemiring.toMul.{u2} R' (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} R' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))))) (NonUnitalNonAssocSemiring.toMul.{u3} R'' (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u3} R'' (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3))))) (NonUnitalRingHomClass.toMulHomClass.{max u2 u3, u2, u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' R'' (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u2} R' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2)))) (NonAssocSemiring.toNonUnitalNonAssocSemiring.{u3} R'' (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) (RingHomClass.toNonUnitalRingHomClass.{max u2 u3, u2, u3} (RingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3)))) R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3))) (RingHom.instRingHomClassRingHom.{u2, u3} R' R'' (Semiring.toNonAssocSemiring.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Semiring.toNonAssocSemiring.{u3} R'' (CommSemiring.toSemiring.{u3} R'' (CommRing.toCommSemiring.{u3} R'' _inst_3))))))) f)) -> (MulChar.IsNontrivial.{u1, u3} R _inst_1 R'' _inst_3 (MulChar.ringHomComp.{u1, u2, u3} R _inst_1 R' _inst_2 R'' _inst_3 χ f)))
+Case conversion may be inaccurate. Consider using '#align mul_char.is_nontrivial.comp MulChar.IsNontrivial.compₓ'. -/
/-- Composition with an injective ring homomorphism preserves nontriviality. -/
theorem IsNontrivial.comp {χ : MulChar R R'} (hχ : χ.IsNontrivial) {f : R' →+* R''}
(hf : Function.Injective f) : (χ.ringHomComp f).IsNontrivial :=
@@ -482,13 +672,16 @@ theorem IsNontrivial.comp {χ : MulChar R R'} (hχ : χ.IsNontrivial) {f : R'
exact fun h => ha (hf h)
#align mul_char.is_nontrivial.comp MulChar.IsNontrivial.comp
+#print MulChar.IsQuadratic.comp /-
/-- Composition with a ring homomorphism preserves the property of being a quadratic character. -/
theorem IsQuadratic.comp {χ : MulChar R R'} (hχ : χ.IsQuadratic) (f : R' →+* R'') :
(χ.ringHomComp f).IsQuadratic := by
intro a
rcases hχ a with (ha | ha | ha) <;> simp [ha]
#align mul_char.is_quadratic.comp MulChar.IsQuadratic.comp
+-/
+#print MulChar.IsQuadratic.inv /-
/-- The inverse of a quadratic character is itself. → -/
theorem IsQuadratic.inv {χ : MulChar R R'} (hχ : χ.IsQuadratic) : χ⁻¹ = χ :=
by
@@ -500,14 +693,23 @@ theorem IsQuadratic.inv {χ : MulChar R R'} (hχ : χ.IsQuadratic) : χ⁻¹ =
· rw [h₂, (by norm_cast : (-1 : R') = (-1 : R'ˣ)), Ring.inverse_unit (-1 : R'ˣ)]
rfl
#align mul_char.is_quadratic.inv MulChar.IsQuadratic.inv
+-/
+#print MulChar.IsQuadratic.sq_eq_one /-
/-- The square of a quadratic character is the trivial character. -/
theorem IsQuadratic.sq_eq_one {χ : MulChar R R'} (hχ : χ.IsQuadratic) : χ ^ 2 = 1 :=
by
convert mul_left_inv _
rw [pow_two, hχ.inv]
#align mul_char.is_quadratic.sq_eq_one MulChar.IsQuadratic.sq_eq_one
+-/
+/- warning: mul_char.is_quadratic.pow_char -> MulChar.IsQuadratic.pow_char is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))}, (MulChar.IsQuadratic.{u1, u2} R _inst_1 R' _inst_2 χ) -> (forall (p : Nat) [hp : Fact (Nat.Prime p)] [_inst_4 : CharP.{u2} R' (AddGroupWithOne.toAddMonoidWithOne.{u2} R' (AddCommGroupWithOne.toAddGroupWithOne.{u2} R' (Ring.toAddCommGroupWithOne.{u2} R' (CommRing.toRing.{u2} R' _inst_2)))) p], Eq.{succ (max u1 u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (HPow.hPow.{max u1 u2, 0, max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) Nat (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (instHPow.{max u1 u2, 0} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) Nat (Monoid.Pow.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (DivInvMonoid.toMonoid.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Group.toDivInvMonoid.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (CommGroup.toGroup.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (MulChar.commGroup.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2)))))))) χ p) χ)
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))}, (MulChar.IsQuadratic.{u1, u2} R _inst_1 R' _inst_2 χ) -> (forall (p : Nat) [hp : Fact (Nat.Prime p)] [_inst_4 : CharP.{u2} R' (AddGroupWithOne.toAddMonoidWithOne.{u2} R' (Ring.toAddGroupWithOne.{u2} R' (CommRing.toRing.{u2} R' _inst_2))) p], Eq.{max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (HPow.hPow.{max u1 u2, 0, max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) Nat (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (instHPow.{max u1 u2, 0} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) Nat (Monoid.Pow.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (DivInvMonoid.toMonoid.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Group.toDivInvMonoid.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (CommGroup.toGroup.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (MulChar.commGroup.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2)))))))) χ p) χ)
+Case conversion may be inaccurate. Consider using '#align mul_char.is_quadratic.pow_char MulChar.IsQuadratic.pow_charₓ'. -/
/-- The `p`th power of a quadratic character is itself, when `p` is the (prime) characteristic
of the target ring. -/
theorem IsQuadratic.pow_char {χ : MulChar R R'} (hχ : χ.IsQuadratic) (p : ℕ) [hp : Fact p.Prime]
@@ -520,22 +722,32 @@ theorem IsQuadratic.pow_char {χ : MulChar R R'} (hχ : χ.IsQuadratic) (p : ℕ
· exact CharP.neg_one_pow_char R' p
#align mul_char.is_quadratic.pow_char MulChar.IsQuadratic.pow_char
+#print MulChar.IsQuadratic.pow_even /-
/-- The `n`th power of a quadratic character is the trivial character, when `n` is even. -/
theorem IsQuadratic.pow_even {χ : MulChar R R'} (hχ : χ.IsQuadratic) {n : ℕ} (hn : Even n) :
χ ^ n = 1 := by
obtain ⟨n, rfl⟩ := even_iff_two_dvd.mp hn
rw [pow_mul, hχ.sq_eq_one, one_pow]
#align mul_char.is_quadratic.pow_even MulChar.IsQuadratic.pow_even
+-/
+#print MulChar.IsQuadratic.pow_odd /-
/-- The `n`th power of a quadratic character is itself, when `n` is odd. -/
theorem IsQuadratic.pow_odd {χ : MulChar R R'} (hχ : χ.IsQuadratic) {n : ℕ} (hn : Odd n) :
χ ^ n = χ := by
obtain ⟨n, rfl⟩ := hn
rw [pow_add, pow_one, hχ.pow_even (even_two_mul _), one_mul]
#align mul_char.is_quadratic.pow_odd MulChar.IsQuadratic.pow_odd
+-/
open BigOperators
+/- warning: mul_char.is_nontrivial.sum_eq_zero -> MulChar.IsNontrivial.sum_eq_zero is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] [_inst_4 : Fintype.{u1} R] [_inst_5 : IsDomain.{u2} R' (Ring.toSemiring.{u2} R' (CommRing.toRing.{u2} R' _inst_2))] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))}, (MulChar.IsNontrivial.{u1, u2} R _inst_1 R' _inst_2 χ) -> (Eq.{succ u2} R' (Finset.sum.{u2, u1} R' R (AddCommGroup.toAddCommMonoid.{u2} R' (NonUnitalNonAssocRing.toAddCommGroup.{u2} R' (NonAssocRing.toNonUnitalNonAssocRing.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))))) (Finset.univ.{u1} R _inst_4) (fun (a : R) => coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (fun (_x : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) => R -> R') (MulChar.coeToFun.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) χ a)) (OfNat.ofNat.{u2} R' 0 (OfNat.mk.{u2} R' 0 (Zero.zero.{u2} R' (MulZeroClass.toHasZero.{u2} R' (NonUnitalNonAssocSemiring.toMulZeroClass.{u2} R' (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u2} R' (NonAssocRing.toNonUnitalNonAssocRing.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))))))))))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] [_inst_4 : Fintype.{u1} R] [_inst_5 : IsDomain.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))] {χ : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CancelCommMonoidWithZero.toCommMonoidWithZero.{u2} R' (IsDomain.toCancelCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2) _inst_5))}, (MulChar.IsNontrivial.{u1, u2} R _inst_1 R' _inst_2 χ) -> (Eq.{succ u2} R' (Finset.sum.{u2, u1} R' R (NonUnitalNonAssocSemiring.toAddCommMonoid.{u2} R' (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u2} R' (NonAssocRing.toNonUnitalNonAssocRing.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))))) (Finset.univ.{u1} R _inst_4) (fun (a : R) => MulChar.toFun'.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CancelCommMonoidWithZero.toCommMonoidWithZero.{u2} R' (IsDomain.toCancelCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2) _inst_5)) χ a)) (OfNat.ofNat.{u2} R' 0 (Zero.toOfNat0.{u2} R' (CommMonoidWithZero.toZero.{u2} R' (CancelCommMonoidWithZero.toCommMonoidWithZero.{u2} R' (IsDomain.toCancelCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2) _inst_5))))))
+Case conversion may be inaccurate. Consider using '#align mul_char.is_nontrivial.sum_eq_zero MulChar.IsNontrivial.sum_eq_zeroₓ'. -/
/-- The sum over all values of a nontrivial multiplicative character on a finite ring is zero
(when the target is a domain). -/
theorem IsNontrivial.sum_eq_zero [Fintype R] [IsDomain R'] {χ : MulChar R R'}
@@ -547,6 +759,12 @@ theorem IsNontrivial.sum_eq_zero [Fintype R] [IsDomain R'] {χ : MulChar R R'}
exact Fintype.sum_bijective _ (Units.mulLeft_bijective b) _ _ fun x => rfl
#align mul_char.is_nontrivial.sum_eq_zero MulChar.IsNontrivial.sum_eq_zero
+/- warning: mul_char.sum_one_eq_card_units -> MulChar.sum_one_eq_card_units is a dubious translation:
+lean 3 declaration is
+ forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] [_inst_4 : Fintype.{u1} R] [_inst_5 : DecidableEq.{succ u1} R], Eq.{succ u2} R' (Finset.sum.{u2, u1} R' R (AddCommGroup.toAddCommMonoid.{u2} R' (NonUnitalNonAssocRing.toAddCommGroup.{u2} R' (NonAssocRing.toNonUnitalNonAssocRing.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))))) (Finset.univ.{u1} R _inst_4) (fun (a : R) => coeFn.{max (succ u1) (succ u2), max (succ u1) (succ u2)} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (fun (_x : MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) => R -> R') (MulChar.coeToFun.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (OfNat.ofNat.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) 1 (OfNat.mk.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) 1 (One.one.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (MulChar.hasOne.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2)))))) a)) ((fun (a : Type) (b : Type.{u2}) [self : HasLiftT.{1, succ u2} a b] => self.0) Nat R' (HasLiftT.mk.{1, succ u2} Nat R' (CoeTCₓ.coe.{1, succ u2} Nat R' (Nat.castCoe.{u2} R' (AddMonoidWithOne.toNatCast.{u2} R' (AddGroupWithOne.toAddMonoidWithOne.{u2} R' (AddCommGroupWithOne.toAddGroupWithOne.{u2} R' (Ring.toAddCommGroupWithOne.{u2} R' (CommRing.toRing.{u2} R' _inst_2)))))))) (Fintype.card.{u1} (Units.{u1} R (Ring.toMonoid.{u1} R (CommRing.toRing.{u1} R _inst_1))) (Units.fintype.{u1} R (Ring.toMonoid.{u1} R (CommRing.toRing.{u1} R _inst_1)) _inst_4 (fun (a : R) (b : R) => _inst_5 a b))))
+but is expected to have type
+ forall {R : Type.{u1}} [_inst_1 : CommRing.{u1} R] {R' : Type.{u2}} [_inst_2 : CommRing.{u2} R'] [_inst_4 : Fintype.{u1} R] [_inst_5 : DecidableEq.{succ u1} R], Eq.{succ u2} R' (Finset.sum.{u2, u1} R' R (NonUnitalNonAssocSemiring.toAddCommMonoid.{u2} R' (NonUnitalNonAssocRing.toNonUnitalNonAssocSemiring.{u2} R' (NonAssocRing.toNonUnitalNonAssocRing.{u2} R' (Ring.toNonAssocRing.{u2} R' (CommRing.toRing.{u2} R' _inst_2))))) (Finset.univ.{u1} R _inst_4) (fun (a : R) => MulChar.toFun'.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2)) (OfNat.ofNat.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) 1 (One.toOfNat1.{max u1 u2} (MulChar.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (MulChar.hasOne.{u1, u2} R (CommRing.toCommMonoid.{u1} R _inst_1) R' (CommSemiring.toCommMonoidWithZero.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))))) a)) (Nat.cast.{u2} R' (Semiring.toNatCast.{u2} R' (CommSemiring.toSemiring.{u2} R' (CommRing.toCommSemiring.{u2} R' _inst_2))) (Fintype.card.{u1} (Units.{u1} R (MonoidWithZero.toMonoid.{u1} R (Semiring.toMonoidWithZero.{u1} R (CommSemiring.toSemiring.{u1} R (CommRing.toCommSemiring.{u1} R _inst_1))))) (instFintypeUnits.{u1} R (MonoidWithZero.toMonoid.{u1} R (Semiring.toMonoidWithZero.{u1} R (CommSemiring.toSemiring.{u1} R (CommRing.toCommSemiring.{u1} R _inst_1)))) _inst_4 (fun (a : R) (b : R) => _inst_5 a b))))
+Case conversion may be inaccurate. Consider using '#align mul_char.sum_one_eq_card_units MulChar.sum_one_eq_card_unitsₓ'. -/
/-- The sum over all values of the trivial multiplicative character on a finite ring is
the cardinality of its unit group. -/
theorem sum_one_eq_card_units [Fintype R] [DecidableEq R] :
mathlib commit https://github.com/leanprover-community/mathlib/commit/738054fa93d43512da144ec45ce799d18fd44248
@@ -4,13 +4,13 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Michael Stoll
! This file was ported from Lean 3 source module number_theory.legendre_symbol.mul_character
-! leanprover-community/mathlib commit 6623e6af705e97002a9054c1c05a980180276fc1
+! leanprover-community/mathlib commit f0c8bf9245297a541f468be517f1bde6195105e9
! Please do not edit these lines, except to modify the commit id
! if you have ported upstream changes.
-/
import Mathbin.Algebra.CharP.Basic
import Mathbin.Algebra.EuclideanDomain.Instances
-import Mathbin.Algebra.Group.ConjFinite
+import Mathbin.Data.Fintype.Units
/-!
# Multiplicative characters of finite rings and fields
mathlib commit https://github.com/leanprover-community/mathlib/commit/3180fab693e2cee3bff62675571264cb8778b212
@@ -216,8 +216,8 @@ noncomputable def ofUnitHom (f : Rˣ →* R'ˣ) : MulChar R R'
have hm : (is_unit.mul_iff.mpr ⟨hx, hy⟩).Unit = hx.unit * hy.unit := units.eq_iff.mp rfl
rw [hm, map_mul]
norm_cast
- · simp only [hy, not_false_iff, dif_neg, mul_zero]
- · simp only [hx, IsUnit.mul_iff, false_and_iff, not_false_iff, dif_neg, zero_mul]
+ · simp only [hy, not_false_iff, dif_neg, MulZeroClass.mul_zero]
+ · simp only [hx, IsUnit.mul_iff, false_and_iff, not_false_iff, dif_neg, MulZeroClass.zero_mul]
map_nonunit' := by
intro a ha
simp only [ha, not_false_iff, dif_neg]
mathlib commit https://github.com/leanprover-community/mathlib/commit/bd9851ca476957ea4549eb19b40e7b5ade9428cc
Take the content of
Algebra.BigOperators.List.Basic
Algebra.BigOperators.List.Lemmas
Algebra.BigOperators.Multiset.Basic
Algebra.BigOperators.Multiset.Lemmas
Algebra.BigOperators.Multiset.Order
Algebra.BigOperators.Order
and sort it into six files:
Algebra.Order.BigOperators.Group.List
. I credit Yakov for https://github.com/leanprover-community/mathlib/pull/8543.Algebra.Order.BigOperators.Group.Multiset
. Copyright inherited from Algebra.BigOperators.Multiset.Order
.Algebra.Order.BigOperators.Group.Finset
. Copyright inherited from Algebra.BigOperators.Order
.Algebra.Order.BigOperators.Ring.List
. I credit Stuart for https://github.com/leanprover-community/mathlib/pull/10184.Algebra.Order.BigOperators.Ring.Multiset
. I credit Ruben for https://github.com/leanprover-community/mathlib/pull/8787.Algebra.Order.BigOperators.Ring.Finset
. I credit Floris for https://github.com/leanprover-community/mathlib/pull/1294.Here are the design decisions at play:
Data.Nat.Order.Basic
in a few List
files.Algebra.Order.BigOperators
instead of Algebra.BigOperators.Order
because algebraic order theory is more of a theory than big operators algebra. Another reason is that algebraic order theory is the only way to mix pure order and pure algebra, while there are more ways to mix pure finiteness and pure algebra than just big operators.Algebra.Order.BigOperators.Group
should be additivisable (except a few Nat
- or Int
-specific lemmas). In contrast, things under Algebra.Order.BigOperators.Ring
are more prone to having heavy imports.List
vs Multiset
vs Finset
. This is not strictly necessary, and can be relaxed in cases where there aren't that many lemmas to be had. As an example, I could split out the AbsoluteValue
lemmas from Algebra.Order.BigOperators.Ring.Finset
to a file Algebra.Order.BigOperators.Ring.AbsoluteValue
and it could stay this way until too many lemmas are in this file (or a split is needed for import reasons), in which case we would need files Algebra.Order.BigOperators.Ring.AbsoluteValue.Finset
, Algebra.Order.BigOperators.Ring.AbsoluteValue.Multiset
, etc...Finsupp
big operator and finprod
/finsum
order lemmas also belong in Algebra.Order.BigOperators
. I haven't done so in this PR because the diff is big enough like that.@@ -556,7 +556,7 @@ theorem sum_one_eq_card_units [DecidableEq R] :
calc
(∑ a, (1 : MulChar R R') a) = ∑ a : R, if IsUnit a then 1 else 0 :=
Finset.sum_congr rfl fun a _ => ?_
- _ = ((Finset.univ : Finset R).filter IsUnit).card := Finset.sum_boole
+ _ = ((Finset.univ : Finset R).filter IsUnit).card := Finset.sum_boole _ _
_ = (Finset.univ.map ⟨((↑) : Rˣ → R), Units.ext⟩).card := ?_
_ = Fintype.card Rˣ := congr_arg _ (Finset.card_map _)
· split_ifs with h
@@ -440,7 +440,7 @@ def IsNontrivial (χ : MulChar R R') : Prop :=
/-- A multiplicative character is nontrivial iff it is not the trivial character. -/
theorem isNontrivial_iff (χ : MulChar R R') : χ.IsNontrivial ↔ χ ≠ 1 := by
- simp only [IsNontrivial, Ne.def, ext_iff, not_forall, one_apply_coe]
+ simp only [IsNontrivial, Ne, ext_iff, not_forall, one_apply_coe]
#align mul_char.is_nontrivial_iff MulChar.isNontrivial_iff
end nontrivial
I removed some redundant instance arguments throughout Mathlib. To do this, I used VS Code's regex search. See https://leanprover.zulipchat.com/#narrow/stream/287929-mathlib4/topic/repeating.20instances.20from.20variable.20command I closed the previous PR for this and reopened it.
@@ -551,7 +551,7 @@ theorem IsNontrivial.sum_eq_zero [IsDomain R'] {χ : MulChar R R'}
/-- The sum over all values of the trivial multiplicative character on a finite ring is
the cardinality of its unit group. -/
-theorem sum_one_eq_card_units [Fintype R] [DecidableEq R] :
+theorem sum_one_eq_card_units [DecidableEq R] :
(∑ a, (1 : MulChar R R') a) = Fintype.card Rˣ := by
calc
(∑ a, (1 : MulChar R R') a) = ∑ a : R, if IsUnit a then 1 else 0 :=
@@ -365,7 +365,7 @@ theorem inv_apply' {R : Type u} [Field R] (χ : MulChar R R') (a : R) : χ⁻¹
#align mul_char.inv_apply' MulChar.inv_apply'
/-- The product of a character with its inverse is the trivial character. -/
--- Porting note: @[simp] can prove this (later)
+-- Porting note (#10618): @[simp] can prove this (later)
theorem inv_mul (χ : MulChar R R') : χ⁻¹ * χ = 1 := by
ext x
rw [coeToFun_mul, Pi.mul_apply, inv_apply_eq_inv]
This PR weakens the type class assumptions on some results about multiplicative characters (from assuming the domain is a commutative ring to only requiring it is a commutative monoid).
See here on Zulip.
Co-authored-by: Michael Stoll <99838730+MichaelStollBayreuth@users.noreply.github.com>
@@ -419,7 +419,7 @@ end DefinitionAndGroup
We introduce the properties of being nontrivial or quadratic and prove
some basic facts about them.
-We now assume that domain and target are commutative rings.
+We now (mostly) assume that the target is a commutative ring.
-/
@@ -429,7 +429,9 @@ namespace MulChar
universe u v w
-variable {R : Type u} [CommRing R] {R' : Type v} [CommRing R'] {R'' : Type w} [CommRing R'']
+section nontrivial
+
+variable {R : Type u} [CommMonoid R] {R' : Type v} [CommMonoidWithZero R']
/-- A multiplicative character is *nontrivial* if it takes a value `≠ 1` on a unit. -/
def IsNontrivial (χ : MulChar R R') : Prop :=
@@ -441,6 +443,12 @@ theorem isNontrivial_iff (χ : MulChar R R') : χ.IsNontrivial ↔ χ ≠ 1 := b
simp only [IsNontrivial, Ne.def, ext_iff, not_forall, one_apply_coe]
#align mul_char.is_nontrivial_iff MulChar.isNontrivial_iff
+end nontrivial
+
+section quadratic_and_comp
+
+variable {R : Type u} [CommMonoid R] {R' : Type v} [CommRing R'] {R'' : Type w} [CommRing R'']
+
/-- A multiplicative character is *quadratic* if it takes only the values `0`, `1`, `-1`. -/
def IsQuadratic (χ : MulChar R R') : Prop :=
∀ a, χ a = 0 ∨ χ a = 1 ∨ χ a = -1
@@ -522,11 +530,17 @@ theorem IsQuadratic.pow_odd {χ : MulChar R R'} (hχ : χ.IsQuadratic) {n : ℕ}
rw [pow_add, pow_one, hχ.pow_even (even_two_mul _), one_mul]
#align mul_char.is_quadratic.pow_odd MulChar.IsQuadratic.pow_odd
+end quadratic_and_comp
+
open BigOperators
+section sum
+
+variable {R : Type u} [CommMonoid R] [Fintype R] {R' : Type v} [CommRing R']
+
/-- The sum over all values of a nontrivial multiplicative character on a finite ring is zero
(when the target is a domain). -/
-theorem IsNontrivial.sum_eq_zero [Fintype R] [IsDomain R'] {χ : MulChar R R'}
+theorem IsNontrivial.sum_eq_zero [IsDomain R'] {χ : MulChar R R'}
(hχ : χ.IsNontrivial) : ∑ a, χ a = 0 := by
rcases hχ with ⟨b, hb⟩
refine' eq_zero_of_mul_eq_self_left hb _
@@ -554,6 +568,8 @@ theorem sum_one_eq_card_units [Fintype R] [DecidableEq R] :
Function.Embedding.coeFn_mk, exists_true_left, IsUnit]
#align mul_char.sum_one_eq_card_units MulChar.sum_one_eq_card_units
+end sum
+
end MulChar
end Properties
refine
s (#10762)
I replaced a few "terminal" refine/refine'
s with exact
.
The strategy was very simple-minded: essentially any refine
whose following line had smaller indentation got replaced by exact
and then I cleaned up the mess.
This PR certainly leaves some further terminal refine
s, but maybe the current change is beneficial.
@@ -532,7 +532,7 @@ theorem IsNontrivial.sum_eq_zero [Fintype R] [IsDomain R'] {χ : MulChar R R'}
refine' eq_zero_of_mul_eq_self_left hb _
-- POrting note: `map_mul` isn't applied
simp only [Finset.mul_sum, ← map_mul]
- refine Fintype.sum_bijective _ (Units.mulLeft_bijective b) _ _ fun x => rfl
+ exact Fintype.sum_bijective _ (Units.mulLeft_bijective b) _ _ fun x => rfl
#align mul_char.is_nontrivial.sum_eq_zero MulChar.IsNontrivial.sum_eq_zero
/-- The sum over all values of the trivial multiplicative character on a finite ring is
@@ -260,10 +260,10 @@ the source has a zero and another element. -/
@[coe, simps]
def toMonoidWithZeroHom {R : Type*} [CommMonoidWithZero R] [Nontrivial R] (χ : MulChar R R') :
R →*₀ R' where
- toFun := χ.toFun
- map_zero' := χ.map_zero
- map_one' := χ.map_one'
- map_mul' := χ.map_mul'
+ toFun := χ.toFun
+ map_zero' := χ.map_zero
+ map_one' := χ.map_one'
+ map_mul' := χ.map_mul'
/-- If the domain is a ring `R`, then `χ (ringChar R) = 0`. -/
theorem map_ringChar {R : Type u} [CommRing R] [Nontrivial R] (χ : MulChar R R') :
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.
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]
.
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_param
s, [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 sometimesThis 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.
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 outParam
s 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.)
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>
@@ -77,7 +77,7 @@ instance MulChar.instFunLike : FunLike (MulChar R R') R R' :=
/-- This is the corresponding extension of `MonoidHomClass`. -/
class MulCharClass (F : Type*) (R R' : outParam <| Type*) [CommMonoid R]
- [CommMonoidWithZero R'] extends MonoidHomClass F R R' where
+ [CommMonoidWithZero R'] [FunLike F R R'] extends MonoidHomClass F R R' : Prop where
map_nonunit : ∀ (χ : F) {a : R} (_ : ¬IsUnit a), χ a = 0
#align mul_char_class MulCharClass
@@ -133,8 +133,6 @@ theorem ext' {χ χ' : MulChar R R'} (h : ∀ a, χ a = χ' a) : χ = χ' := by
#align mul_char.ext' MulChar.ext'
instance : MulCharClass (MulChar R R') R R' where
- coe χ := χ.toMonoidHom.toFun
- coe_injective' _ _ h := ext' fun a => congr_fun h a
map_mul χ := χ.map_mul'
map_one χ := χ.map_one'
map_nonunit χ := χ.map_nonunit' _
This is the sixth PR in a sequence that adds auxiliary lemmas from the EulerProducts project to Mathlib.
It adds a coercion from multiplicative characters to homomorphisms of monoids with zero and a variant of MulChar.one_apply_coe
that is more convenient to use in some contexts.
@@ -257,6 +257,16 @@ protected theorem map_zero {R : Type u} [CommMonoidWithZero R] [Nontrivial R] (
χ (0 : R) = 0 := by rw [map_nonunit χ not_isUnit_zero]
#align mul_char.map_zero MulChar.map_zero
+/-- We can convert a multiplicative character into a homomorphism of monoids with zero when
+the source has a zero and another element. -/
+@[coe, simps]
+def toMonoidWithZeroHom {R : Type*} [CommMonoidWithZero R] [Nontrivial R] (χ : MulChar R R') :
+ R →*₀ R' where
+ toFun := χ.toFun
+ map_zero' := χ.map_zero
+ map_one' := χ.map_one'
+ map_mul' := χ.map_mul'
+
/-- If the domain is a ring `R`, then `χ (ringChar R) = 0`. -/
theorem map_ringChar {R : Type u} [CommRing R] [Nontrivial R] (χ : MulChar R R') :
χ (ringChar R) = 0 := by rw [ringChar.Nat.cast_ringChar, χ.map_zero]
@@ -275,6 +285,9 @@ noncomputable instance inhabited : Inhabited (MulChar R R') :=
theorem one_apply_coe (a : Rˣ) : (1 : MulChar R R') a = 1 := by classical exact dif_pos a.isUnit
#align mul_char.one_apply_coe MulChar.one_apply_coe
+/-- Evaluation of the trivial character -/
+lemma one_apply {x : R} (hx : IsUnit x) : (1 : MulChar R R') x = 1 := one_apply_coe hx.unit
+
/-- Multiplication of multiplicative characters. (This needs the target to be commutative.) -/
def mul (χ χ' : MulChar R R') : MulChar R R' :=
{ χ.toMonoidHom * χ'.toMonoidHom with
f ^ n
(#9617)
This involves moving lemmas from Algebra.GroupPower.Ring
to Algebra.GroupWithZero.Basic
and changing some 0 < n
assumptions to n ≠ 0
.
From LeanAPAP
@@ -390,7 +390,7 @@ theorem pow_apply_coe (χ : MulChar R R') (n : ℕ) (a : Rˣ) : (χ ^ n) a = χ
#align mul_char.pow_apply_coe MulChar.pow_apply_coe
/-- If `n` is positive, then `(χ ^ n) a = (χ a) ^ n`. -/
-theorem pow_apply' (χ : MulChar R R') {n : ℕ} (hn : 0 < n) (a : R) : (χ ^ n) a = χ a ^ n := by
+theorem pow_apply' (χ : MulChar R R') {n : ℕ} (hn : n ≠ 0) (a : R) : (χ ^ n) a = χ a ^ n := by
by_cases ha : IsUnit a
· exact pow_apply_coe χ n ha.unit
· rw [map_nonunit (χ ^ n) ha, map_nonunit χ ha, zero_pow hn]
@@ -492,7 +492,7 @@ theorem IsQuadratic.pow_char {χ : MulChar R R'} (hχ : χ.IsQuadratic) (p : ℕ
ext x
rw [pow_apply_coe]
rcases hχ x with (hx | hx | hx) <;> rw [hx]
- · rw [zero_pow (@Fact.out p.Prime).pos]
+ · rw [zero_pow (@Fact.out p.Prime).ne_zero]
· rw [one_pow]
· exact CharP.neg_one_pow_char R' p
#align mul_char.is_quadratic.pow_char MulChar.IsQuadratic.pow_char
FunLike
(#9833)
This follows up from #9785, which renamed FunLike
to DFunLike
, by introducing a new abbreviation FunLike F α β := DFunLike F α (fun _ => β)
, to make the non-dependent use of FunLike
easier.
I searched for the pattern DFunLike.*fun
and DFunLike.*λ
in all files to replace expressions of the form DFunLike F α (fun _ => β)
with FunLike F α β
. I did this everywhere except for extends
clauses for two reasons: it would conflict with #8386, and more importantly extends
must directly refer to a structure with no unfolding of def
s or abbrev
s.
@@ -71,7 +71,7 @@ structure MulChar extends MonoidHom R R' where
map_nonunit' : ∀ a : R, ¬IsUnit a → toFun a = 0
#align mul_char MulChar
-instance MulChar.instDFunLike : DFunLike (MulChar R R') R (fun _ => R') :=
+instance MulChar.instFunLike : FunLike (MulChar R R') R R' :=
⟨fun χ => χ.toFun,
fun χ₀ χ₁ h => by cases χ₀; cases χ₁; congr; apply MonoidHom.ext (fun _ => congr_fun h _)⟩
FunLike
to DFunLike
(#9785)
This prepares for the introduction of a non-dependent synonym of FunLike, which helps a lot with keeping #8386 readable.
This is entirely search-and-replace in 680197f combined with manual fixes in 4145626, e900597 and b8428f8. The commands that generated this change:
sed -i 's/\bFunLike\b/DFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\btoFunLike\b/toDFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/import Mathlib.Data.DFunLike/import Mathlib.Data.FunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\bHom_FunLike\b/Hom_DFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\binstFunLike\b/instDFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\bfunLike\b/instDFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\btoo many metavariables to apply `fun_like.has_coe_to_fun`/too many metavariables to apply `DFunLike.hasCoeToFun`/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
Co-authored-by: Anne Baanen <Vierkantor@users.noreply.github.com>
@@ -71,7 +71,7 @@ structure MulChar extends MonoidHom R R' where
map_nonunit' : ∀ a : R, ¬IsUnit a → toFun a = 0
#align mul_char MulChar
-instance MulChar.instFunLike : FunLike (MulChar R R') R (fun _ => R') :=
+instance MulChar.instDFunLike : DFunLike (MulChar R R') R (fun _ => R') :=
⟨fun χ => χ.toFun,
fun χ₀ χ₁ h => by cases χ₀; cases χ₁; congr; apply MonoidHom.ext (fun _ => congr_fun h _)⟩
Items 1-3 in reference Zulip
Rename chartedSpace
, smoothMfldWithCorners
, and funLike
.
@@ -71,7 +71,7 @@ structure MulChar extends MonoidHom R R' where
map_nonunit' : ∀ a : R, ¬IsUnit a → toFun a = 0
#align mul_char MulChar
-instance funLike : FunLike (MulChar R R') R (fun _ => R') :=
+instance MulChar.instFunLike : FunLike (MulChar R R') R (fun _ => R') :=
⟨fun χ => χ.toFun,
fun χ₀ χ₁ h => by cases χ₀; cases χ₁; congr; apply MonoidHom.ext (fun _ => congr_fun h _)⟩
@@ -237,6 +237,10 @@ theorem equivToUnitHom_symm_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : equivToUnitHom.s
ofUnitHom_coe f a
#align mul_char.equiv_unit_hom_symm_coe MulChar.equivToUnitHom_symm_coe
+@[simp]
+lemma coe_toMonoidHom [CommMonoid R] (χ : MulChar R R')
+ (x : R) : χ.toMonoidHom x = χ x := rfl
+
/-!
### Commutative group structure on multiplicative characters
apply_fun
(#6732)
withMainContext
so that locals are treated properly@@ -330,9 +330,7 @@ theorem inv_apply {R : Type u} [CommMonoidWithZero R] (χ : MulChar R R') (a : R
by_cases ha : IsUnit a
· rw [inv_apply_eq_inv]
have h := IsUnit.map χ ha
- -- Porting note: was
- -- apply_fun (χ a * ·) using IsUnit.mul_right_injective h
- apply IsUnit.mul_right_injective h
+ apply_fun (χ a * ·) using IsUnit.mul_right_injective h
dsimp only
-- Porting note: was
-- rw [Ring.mul_inverse_cancel _ h, ← map_mul, Ring.mul_inverse_cancel _ ha, MulChar.map_one]
MulZeroClass.
in mul_zero
/zero_mul
(#6682)
Search&replace MulZeroClass.mul_zero
-> mul_zero
, MulZeroClass.zero_mul
-> zero_mul
.
These were introduced by Mathport, as the full name of mul_zero
is actually MulZeroClass.mul_zero
(it's exported with the short name).
@@ -193,8 +193,8 @@ noncomputable def ofUnitHom (f : Rˣ →* R'ˣ) : MulChar R R' where
have hm : (IsUnit.mul_iff.mpr ⟨hx, hy⟩).unit = hx.unit * hy.unit := Units.eq_iff.mp rfl
rw [hm, map_mul]
norm_cast
- · simp only [hy, not_false_iff, dif_neg, MulZeroClass.mul_zero]
- · simp only [hx, IsUnit.mul_iff, false_and_iff, not_false_iff, dif_neg, MulZeroClass.zero_mul]
+ · simp only [hy, not_false_iff, dif_neg, mul_zero]
+ · simp only [hx, IsUnit.mul_iff, false_and_iff, not_false_iff, dif_neg, zero_mul]
map_nonunit' := by
intro a ha
simp only [ha, not_false_iff, dif_neg]
Type _
and Sort _
(#6499)
We remove all possible occurences of Type _
and Sort _
in favor of Type*
and Sort*
.
This has nice performance benefits.
@@ -76,7 +76,7 @@ instance funLike : FunLike (MulChar R R') R (fun _ => R') :=
fun χ₀ χ₁ h => by cases χ₀; cases χ₁; congr; apply MonoidHom.ext (fun _ => congr_fun h _)⟩
/-- This is the corresponding extension of `MonoidHomClass`. -/
-class MulCharClass (F : Type _) (R R' : outParam <| Type _) [CommMonoid R]
+class MulCharClass (F : Type*) (R R' : outParam <| Type*) [CommMonoid R]
[CommMonoidWithZero R'] extends MonoidHomClass F R R' where
map_nonunit : ∀ (χ : F) {a : R} (_ : ¬IsUnit a), χ a = 0
#align mul_char_class MulCharClass
@@ -2,16 +2,13 @@
Copyright (c) 2022 Michael Stoll. All rights reserved.
Released under Apache 2.0 license as described in the file LICENSE.
Authors: Michael Stoll
-
-! This file was ported from Lean 3 source module number_theory.legendre_symbol.mul_character
-! leanprover-community/mathlib commit f0c8bf9245297a541f468be517f1bde6195105e9
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
-/
import Mathlib.Algebra.CharP.Basic
import Mathlib.Algebra.EuclideanDomain.Instances
import Mathlib.Data.Fintype.Units
+#align_import number_theory.legendre_symbol.mul_character from "leanprover-community/mathlib"@"f0c8bf9245297a541f468be517f1bde6195105e9"
+
/-!
# Multiplicative characters of finite rings and fields
@@ -76,7 +76,7 @@ structure MulChar extends MonoidHom R R' where
instance funLike : FunLike (MulChar R R') R (fun _ => R') :=
⟨fun χ => χ.toFun,
- fun χ₀ χ₁ h => by cases χ₀; cases χ₁; congr; apply MonoidHom.ext (fun _ => congr_fun h _)⟩
+ fun χ₀ χ₁ h => by cases χ₀; cases χ₁; congr; apply MonoidHom.ext (fun _ => congr_fun h _)⟩
/-- This is the corresponding extension of `MonoidHomClass`. -/
class MulCharClass (F : Type _) (R R' : outParam <| Type _) [CommMonoid R]
∑'
precedence (#5615)
∑
, ∏
and variants).([^a-zA-Zα-ωΑ-Ω'𝓝ℳ₀𝕂ₛ)]) \(([∑∏][^()∑∏]*,[^()∑∏:]*)\) ([⊂⊆=<≤])
replaced by $1 $2 $3
@@ -517,7 +517,7 @@ open BigOperators
/-- The sum over all values of a nontrivial multiplicative character on a finite ring is zero
(when the target is a domain). -/
theorem IsNontrivial.sum_eq_zero [Fintype R] [IsDomain R'] {χ : MulChar R R'}
- (hχ : χ.IsNontrivial) : (∑ a, χ a) = 0 := by
+ (hχ : χ.IsNontrivial) : ∑ a, χ a = 0 := by
rcases hχ with ⟨b, hb⟩
refine' eq_zero_of_mul_eq_self_left hb _
-- POrting note: `map_mul` isn't applied
@@ -74,12 +74,18 @@ structure MulChar extends MonoidHom R R' where
map_nonunit' : ∀ a : R, ¬IsUnit a → toFun a = 0
#align mul_char MulChar
+instance funLike : FunLike (MulChar R R') R (fun _ => R') :=
+ ⟨fun χ => χ.toFun,
+ fun χ₀ χ₁ h => by cases χ₀; cases χ₁; congr; apply MonoidHom.ext (fun _ => congr_fun h _)⟩
+
/-- This is the corresponding extension of `MonoidHomClass`. -/
class MulCharClass (F : Type _) (R R' : outParam <| Type _) [CommMonoid R]
[CommMonoidWithZero R'] extends MonoidHomClass F R R' where
map_nonunit : ∀ (χ : F) {a : R} (_ : ¬IsUnit a), χ a = 0
#align mul_char_class MulCharClass
+initialize_simps_projections MulChar (toFun → apply, -toMonoidHom)
+
attribute [simp] MulCharClass.map_nonunit
end Defi
@@ -94,21 +100,6 @@ variable {R : Type u} [CommMonoid R]
-- The target
variable {R' : Type v} [CommMonoidWithZero R']
-@[coe]
-nonrec def toFun' (χ : MulChar R R') : R → R' :=
- χ.toFun
-
-instance coeToFun : CoeFun (MulChar R R') fun _ => R → R' :=
- ⟨MulChar.toFun'⟩
-#align mul_char.coe_to_fun MulChar.coeToFun
-
-/-- See note [custom simps projection] -/
-protected def Simps.apply (χ : MulChar R R') : R → R' :=
- χ
-#align mul_char.simps.apply MulChar.Simps.apply
-
-initialize_simps_projections MulChar (toMonoidHom_toFun → apply, -toMonoidHom)
-
section trivial
variable (R R')
@@ -131,16 +122,6 @@ noncomputable def trivial : MulChar R R' where
end trivial
-@[simp]
-theorem coe_coe (χ : MulChar R R') : (χ.toMonoidHom : R → R') = χ :=
- rfl
-#align mul_char.coe_coe MulChar.coe_coe
-
-@[simp]
-theorem toFun_eq_coe (χ : MulChar R R') : χ.toFun = χ :=
- rfl
-#align mul_char.to_fun_eq_coe MulChar.toFun_eq_coe
-
@[simp]
theorem coe_mk (f : R →* R') (hf) : (MulChar.mk f hf : R → R') = f :=
rfl
@@ -476,7 +457,7 @@ theorem IsNontrivial.comp {χ : MulChar R R'} (hχ : χ.IsNontrivial) {f : R'
(hf : Function.Injective f) : (χ.ringHomComp f).IsNontrivial := by
obtain ⟨a, ha⟩ := hχ
use a
- rw [ringHomComp_apply, ← RingHom.map_one f]
+ simp_rw [ringHomComp_apply, ← RingHom.map_one f]
exact fun h => ha (hf h)
#align mul_char.is_nontrivial.comp MulChar.IsNontrivial.comp
@@ -541,8 +522,7 @@ theorem IsNontrivial.sum_eq_zero [Fintype R] [IsDomain R'] {χ : MulChar R R'}
refine' eq_zero_of_mul_eq_self_left hb _
-- POrting note: `map_mul` isn't applied
simp only [Finset.mul_sum, ← map_mul]
- refine Fintype.sum_bijective _ (Units.mulLeft_bijective b) _ _ fun x => ?_
- exact (map_mul χ (b : R) x).symm
+ refine Fintype.sum_bijective _ (Units.mulLeft_bijective b) _ _ fun x => rfl
#align mul_char.is_nontrivial.sum_eq_zero MulChar.IsNontrivial.sum_eq_zero
/-- The sum over all values of the trivial multiplicative character on a finite ring is
@@ -255,9 +255,9 @@ theorem coe_equivToUnitHom (χ : MulChar R R') (a : Rˣ) : ↑(equivToUnitHom χ
#align mul_char.coe_equiv_to_unit_hom MulChar.coe_equivToUnitHom
@[simp]
-theorem equiv_unit_hom_symm_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : equivToUnitHom.symm f ↑a = f a :=
+theorem equivToUnitHom_symm_coe (f : Rˣ →* R'ˣ) (a : Rˣ) : equivToUnitHom.symm f ↑a = f a :=
ofUnitHom_coe f a
-#align mul_char.equiv_unit_hom_symm_coe MulChar.equiv_unit_hom_symm_coe
+#align mul_char.equiv_unit_hom_symm_coe MulChar.equivToUnitHom_symm_coe
/-!
### Commutative group structure on multiplicative characters
@@ -325,8 +325,7 @@ protected theorem mul_one (χ : MulChar R R') : χ * 1 = χ := by
/-- The inverse of a multiplicative character. We define it as `inverse ∘ χ`. -/
noncomputable def inv (χ : MulChar R R') : MulChar R R' :=
- { MonoidWithZero.inverse.toMonoidHom.comp
- χ.toMonoidHom with
+ { MonoidWithZero.inverse.toMonoidHom.comp χ.toMonoidHom with
toFun := fun a => MonoidWithZero.inverse (χ a)
map_nonunit' := fun a ha => by simp [map_nonunit _ ha] }
#align mul_char.inv MulChar.inv
fix-comments.py
on all files.@@ -74,7 +74,7 @@ structure MulChar extends MonoidHom R R' where
map_nonunit' : ∀ a : R, ¬IsUnit a → toFun a = 0
#align mul_char MulChar
-/-- This is the corresponding extension of `monoid_hom_class`. -/
+/-- This is the corresponding extension of `MonoidHomClass`. -/
class MulCharClass (F : Type _) (R R' : outParam <| Type _) [CommMonoid R]
[CommMonoidWithZero R'] extends MonoidHomClass F R R' where
map_nonunit : ∀ (χ : F) {a : R} (_ : ¬IsUnit a), χ a = 0
@@ -275,7 +275,7 @@ protected theorem map_zero {R : Type u} [CommMonoidWithZero R] [Nontrivial R] (
χ (0 : R) = 0 := by rw [map_nonunit χ not_isUnit_zero]
#align mul_char.map_zero MulChar.map_zero
-/-- If the domain is a ring `R`, then `χ (ring_char R) = 0`. -/
+/-- If the domain is a ring `R`, then `χ (ringChar R) = 0`. -/
theorem map_ringChar {R : Type u} [CommRing R] [Nontrivial R] (χ : MulChar R R') :
χ (ringChar R) = 0 := by rw [ringChar.Nat.cast_ringChar, χ.map_zero]
#align mul_char.map_ring_char MulChar.map_ringChar
The unported dependencies are