Zulip Chat Archive
Stream: Is there code for X?
Topic: trivial lieringmodule
Edison Xie (May 06 2025 at 09:51):
Do we not have this instance?
import Mathlib
variable (R : Type*) [CommRing R]
instance : LieRingModule R Unit where
bracket _ _ := Unit.unit
add_lie _ _ _ := rfl
lie_add _ _ _ := rfl
leibniz_lie _ _ _ := rfl
Eric Wieser (May 06 2025 at 10:13):
I guess if #synth says no, we don't
Eric Wieser (May 06 2025 at 10:14):
Note we should have it for the more general PUnit
Eric Wieser (May 06 2025 at 10:14):
(and the whole hierarchy of Lies)
Edison Xie (May 06 2025 at 10:15):
Eric Wieser said:
I guess if
#synthsays no, we don't
yeah that's what I tried :(
Edison Xie (May 06 2025 at 10:16):
Eric Wieser said:
Note we should have it for the more general PUnit
adding a "P" in front of everything just works lol
instance : LieRingModule R PUnit where
bracket _ _ := PUnit.unit
add_lie _ _ _ := rfl
lie_add _ _ _ := rfl
leibniz_lie _ _ _ := rfl
Edison Xie (May 06 2025 at 11:04):
@Eric Wieser so should we PR this instance?
Eric Wieser (May 06 2025 at 11:07):
Yes, but let's have @Oliver Nash review it
Ruben Van de Velde (May 06 2025 at 11:21):
Eric Wieser said:
(and the whole hierarchy of
Lies)
(How does one pronounce Lies?)
Oliver Nash (May 06 2025 at 11:26):
I think the instance should be:
instance (L : Type*) [LieRing L] : LieRingModule L PUnit where
bracket _ _ := PUnit.unit
add_lie _ _ _ := rfl
lie_add _ _ _ := rfl
leibniz_lie _ _ _ := rfl
partly because this is more general and partly because one day I'd like to demote docs#LieRing.ofAssociativeRing from being an instance.
Oliver Nash (May 06 2025 at 11:29):
In fact we should probably even generalise the above so that it doesn't just talk about the concrete type docs#PUnit but applies to any type with a unique element. I.e.,
instance (L M : Type*) [LieRing L] [Unique M] : LieRingModule L M := sorry
Eric Wieser (May 06 2025 at 11:32):
That looks like a diamond issue to me, I think best to stick with PUnit like we do for other algebraic structures
Oliver Nash (May 06 2025 at 11:33):
Oh indeed, that could be an issue. I guess it could be a def but then it's hardly worth it.
Junyan Xu (May 07 2025 at 09:35):
If we add a LieRing PUnit instance, do we get diamond with [LieRing L] : LieRingModule L PUnit when L = PUnit? (I guess not.)
Last updated: Dec 20 2025 at 21:32 UTC