feat(GroupTheory): define left-orderable groups#41505
Conversation
…oups Introduce `IsLeftOrderable`, a `Prop`-valued class recording that a group admits a linear order invariant under left multiplication (`MulLeftMono`), together with the instance deriving it from a concrete compatible order. The `@[mk_iff]` attribute generates `isLeftOrderable_iff`. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…into IsLeftOrderable
|
+LLM-generated |
PR summary 242407fa16Import changes for modified filesNo significant changes to the import graph Import changes for all files
|
| Current number | Change | Type (weak) |
|---|---|---|
| 5002 | 1 | exposed public sections |
Current commit 242407fa16
Reference commit 27c42f4d5c
This script lives in the mathlib-ci repository. To run it locally, from your mathlib4 directory:
git clone https://github.com/leanprover-community/mathlib-ci.git ../mathlib-ci
../mathlib-ci/scripts/reporting/technical-debt-metrics.sh pr_summary
- The
relativevalue is the weighted sum of the differences with weight given by the inverse of the current value of the statistic. - The
absolutevalue is therelativevalue divided by the total sum of the inverses of the current values (i.e. the weighted average of the differences).
YaelDillies
left a comment
There was a problem hiding this comment.
I was going to ask if we could have (bi-)orderable groups/monoids because they would be useful to state things in formal-conjectures, but then I read somewhere that a monoid is orderable iff it is cancellative and torsion-free. Assuming this is true, I believe we shouldn't have IsOrderable but instead spell it out as cancellative + torsion-free. Could you then leave a comment that cancellative + torsion-free implies IsLeftOrderable M?
I believe this refers to a commutative semigroup? I've found the statement is in p.5 of this paper https://arxiv.org/pdf/2511.00691, where Definition 2.1 refers to a monoid as a commutative and cancellative semigroup with identity so I think they are talking about the commutative monoid case. Just as a sanity check, I tried to work out a counterexample, that is, finding a non-commutative monoid that is cancellative and torsion-free but not (bi)-orderable. Take the Klein bottle group as a monoid with presentation w.l.o.g assuming
I might be wrong because I’m not solid on my monoids, but I do know that this Klein bottle group is not bi-orderable by non-example 1.5.0.6 in my thesis https://arxiv.org/pdf/2512.07035, so at the very least this statement doesn't make sense when you pass down to groups (groups are always cancellative, and left-orderable groups are always torsion-free unless they are the identity, and that doesn't automatically make them bi-orderable). |
|
-awaiting-author |
|
Looking at this code, I find the repetition of the statements with right-orderable groups quite repetitive. Sorry if this has already been covered, but what would be a possible better way to do it? |
| i.e. `a < b → c * a < c * b`. -/ | ||
| @[mk_iff] | ||
| class IsLeftOrderable (G : Type*) [Group G] : Prop where | ||
| exists_linearOrder_mulLeftStrictMono (G) : ∃ _ : LinearOrder G, MulLeftStrictMono G |
There was a problem hiding this comment.
Even though MulLeftStrictMono might be how it's often written, I think MulLeftMono might make your life slightly easier, and then the MulLeftStrictMono version can be an API lemma.
| isBiOrderable_iff_exists_linearOrder_mulLeftMono_mulRightMono.mp ‹_› | ||
|
|
||
| /-- A group is left-orderable iff it is right-orderable. -/ | ||
| theorem isLeftOrderable_iff_isRightOrderable : IsLeftOrderable G ↔ IsRightOrderable G := by |
There was a problem hiding this comment.
If these are equivalent, then there's no point in having both definitions, I feel. Why not just have an IsOrderable class with API lemmas giving the equivalence with left-orderability and right-orderability?
There was a problem hiding this comment.
(although if you generalize to monoids, then maybe having both is necessary)
| class IsLeftOrderable (G : Type*) [Group G] : Prop where | ||
| exists_linearOrder_mulLeftStrictMono (G) : ∃ _ : LinearOrder G, MulLeftStrictMono G |
There was a problem hiding this comment.
Can you to_additive-ize this file?
| single order invariant under both left and right multiplication; this is strictly stronger than | ||
| being both left- and right-orderable, since the latter may be witnessed by different orders. |
There was a problem hiding this comment.
Since you're just dealing with Prop-valued typeclasses, I don't think IsBiOrderable G is any stronger than IsLeftOrderable, right?
A group
Gis left-orderable if it admits a linear order invariant under left-multiplication that is, for all group elementsa,b, andc,a < b → c * a < c * b. A groupGis right-orderable if it admits a linear order invariant under right-multiplicationa < b → a * c < b * c. A groupGis bi-orderable if it admits a linear order invariant under left and right-multiplicationa < b → c * a < c * banda < b → a * c < b * cThis file defines the
Prop-valued classIsLeftOrderable G,IsRightOrderable GandIsBiOrderableasserting the existence of such orders.
Co-authored by: Yaël Dillies yael.dillies@gmail.com
Authored using Claude Fable during the Fermat’s Last Theorem workshop.