Skip to content

Commit 6596905

Browse files
committed
1 parent d899146 commit 6596905

1 file changed

Lines changed: 30 additions & 0 deletions

File tree

Mathlib/Algebra/Group/Action/Units.lean

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,36 @@ instance isScalarTower'_left [Group G] [Monoid M] [MulAction G M] [SMul M α] [S
122122
example [Monoid M] [Monoid N] [MulAction M N] [SMulCommClass M N N] [IsScalarTower M N N] :
123123
MulAction Mˣ Nˣ := Units.mulAction'
124124

125+
section MulDistribMulAction
126+
variable {M N : Type*} [Monoid M] [Monoid N] [MulDistribMulAction M N]
127+
128+
/-- Note this has different defeqs than `Units.mulAction'`, but doesn't create a diamond
129+
with it in non-degenerate situations. Indeed, to get a diamond on `MulDistribMulAction G Mˣ`,
130+
we would need both instances to fire. But `Units.mulAction'` assumes `SMulCommClass G M M`,
131+
i.e. `∀ (g : G) (m₁ m₂ : M), g • (m₁ * m₂) = m₁ * g • m₂`), while
132+
`Units.instMulDistribMulActionRight` assumes `MulDistribMulAction G M`,
133+
i.e. `∀ (g : G) (m₁ m₂ : M), g • (m₁ * m₂) = g • m₁ * g • m₂`.
134+
In particular, if `M` is cancellative, then we obtain `∀ (g : G) (m : M), g • m = m`,
135+
i.e. the action is trivial!
136+
137+
This however does create a (propeq) diamond for `MulDistribMulAction (ConjAct Mˣ) Mˣ` with
138+
`ConjAct.unitsMulDistribMulAction` and `ConjAct.instMulDistribMulAction`. Indeed, if we go down
139+
one way then `u • v := ⟨ofConjAct u * v * ofConjAct u⁻¹, ofConjAct u * v⁻¹ * ofConjAct u⁻¹, _, _⟩`,
140+
while the other way is
141+
`u • v := ⟨ofConjAct u * v * ofConjAct u⁻¹, ofConjAct u * (v⁻¹ * ofConjAct u⁻¹), _, _⟩`. -/
142+
abbrev mulDistribMulActionRight : MulDistribMulAction M Nˣ where
143+
smul m u := ⟨m • u, m • u⁻¹, by simp [← smul_mul', smul_one], by simp [← smul_mul', smul_one]⟩
144+
one_smul u := Units.ext <| one_smul ..
145+
mul_smul m₁ m₂ u := Units.ext <| mul_smul ..
146+
smul_mul m₁ u₁ u₂ := Units.ext <| smul_mul' ..
147+
smul_one m := Units.ext <| smul_one m
148+
149+
attribute [local instance] mulDistribMulActionRight
150+
151+
@[simp, norm_cast] lemma coe_smul (m : M) (u : Nˣ) : (m • u).val = m • u.val := rfl
152+
@[simp, norm_cast] lemma coe_inv_smul (m : M) (u : Nˣ) : (m • u)⁻¹.val = m • u⁻¹.val := rfl
153+
154+
end MulDistribMulAction
125155
end Units
126156

127157
@[to_additive]

0 commit comments

Comments
 (0)