New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Merged by Bors] - feat(group_theory/group_action/sub_mul_action): orbit and stabilizer lemmas #11899
Conversation
Co-authored-by: Johan Commelin <johan@commelin.net>
Co-authored-by: Johan Commelin <johan@commelin.net>
/-- Orbits in a `sub_mul_action` coincide with orbits in the ambient space. -/ | ||
lemma orbit_of_sub_mul {p : sub_mul_action R M} (m : p) : | ||
(mul_action.orbit R m : set M) = mul_action.orbit R (m : M) := rfl |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This lemma is a tautology, both sides are syntactically identical. Did you mean
lemma coe_image_orbit {p : sub_mul_action R M} (m : p) :
coe '' mul_action.orbit R m = mul_action.orbit R (m : M) :=
(set.range_comp _ _).symm
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, I meant what I had written, because at some point I felt it had to exist.
(It is not clear to me why the orbit, a member of (set p), is automatically viewed as a member of (set M).
Let me try to understand what you wrote.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(I switched my lemma to yours, but it is not clear to me why the first one in syntactically obvious and not yours…)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(It is not clear to me why the orbit, a member of (set p), is automatically viewed as a member of (set M).
That's precisely the problem, that's not what you asked lean to do. When you write (mul_action.orbit R m : set M)
, that means "mul_action.orbit R m
will be a term of type set M
", from which the elaborator concludes "m
must be a term of type M
", and replaces it with ↑m
".
My guess is that you thought you'd written something equivalent to (↑(mul_action.orbit R m) : set M)
,
Which doesn't work because no such automatic coercion exists
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it is not clear to me why the first one in syntactically obvious and not yours
Put your cursor after the :=
in your original lemma. The goal view will show that both sides are already exactly the same.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You taught me something about how Lean's elaborator “thinks”.
I really expected that seeing (mul_action.orbit R m : set M)', it would want to make
(mul_action.orbit R m)' a member of `set M'.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, I wrote this lemma by a mere desire of completing the square (If something is proven about stabilizer, something about orbits has to, and the lemma for orbits was the wrong one, as you observed!), but I don't think I had to use it.
You seem to have removed the |
Is this better now? |
Thanks! bors d+ |
✌️ AntoineChambert-Loir can now approve this pull request. To approve and merge a pull request, simply reply with |
bors r+ |
…lemmas (#11899) Feat: add lemmas for stabilizer and orbit for sub_mul_action Co-authored-by: Antoine Chambert-Loir <antoine.chambert-loir@math.univ-paris-diderot.fr>
This PR was included in a batch that was canceled, it will be automatically retried |
…lemmas (#11899) Feat: add lemmas for stabilizer and orbit for sub_mul_action Co-authored-by: Antoine Chambert-Loir <antoine.chambert-loir@math.univ-paris-diderot.fr>
Pull request successfully merged into master. Build succeeded: |
Feat: add lemmas for stabilizer and orbit for sub_mul_action