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] - chore(group_theory): some new convenience lemmas #7555
Conversation
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'm not really convinced that the mk'_eq_mk'_...
lemmas here are a good idea. Why duplicate every lemma about coe
when the user can just write rw coe_mk', the_rest_of_the_proof_using_coe
?
Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
I tried using only |
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.
Thanks for pruning those lemmas, the rest looks good to me (modulo a whitespace nit you can ignore).
This lemma might be worth adding just below inv_mem_iff
in subgroup.lean
too:
@[to_additive] lemma div_mem_comm_iff {a b : G} : a / b ∈ H ↔ b / a ∈ H :=
by rw [←H.inv_mem_iff, div_eq_mul_inv, div_eq_mul_inv, mul_inv_rev, inv_inv]
which gives you the additive add_subgroup.sub_mem_comm_iff : a - b ∈ H ↔ b - a ∈ H
which it sounds like would make switching between the variations you had before easier.
bors d+ |
✌️ PatrickMassot can now approve this pull request. To approve and merge a pull request, simply reply with |
Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
bors merge |
Pull request successfully merged into master. Build succeeded:
|
from LTE
This does not decrease the mess with
group_theory/coset
vsgroup_theory/quotient_group
and various implicit or explicit parameters, it's only adding more API on top of the mess. In particular I added ad hoc reformulations for additive groups in order to avoid thex + -y
curse ofto_additive
.I also changed slightly an old lemma since preimages are more convenient to use than direct images.