Skip to content
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(data/set/intervals/image_preimage, algebra/ordered_monoid): new typeclass for interval bijection lemmas #6629

Closed
wants to merge 11 commits into from

Conversation

apnelson1
Copy link
Collaborator

@apnelson1 apnelson1 commented Mar 10, 2021

This commit introduces a has_exists_add_of_le typeclass extending ordered_add_comm_monoid; this is the assumption needed so that additively translating an interval gives a bijection. We then prove this fact for all flavours of interval.

https://leanprover.zulipchat.com/#narrow/stream/217875-Is-there.20code.20for.20X.3F/topic/Correct.20setting.20for.20positive.20shifts.20of.20intervals

@apnelson1 apnelson1 added the awaiting-review The author would like community review of the PR label Mar 10, 2021
Copy link
Collaborator

@bryangingechen bryangingechen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is looking quite good; just a few more suggestions.

src/algebra/ordered_monoid.lean Outdated Show resolved Hide resolved
src/data/set/intervals/image_preimage.lean Outdated Show resolved Hide resolved
src/data/set/intervals/image_preimage.lean Outdated Show resolved Hide resolved
src/data/set/intervals/image_preimage.lean Outdated Show resolved Hide resolved
src/data/set/intervals/image_preimage.lean Outdated Show resolved Hide resolved
@bryangingechen bryangingechen added awaiting-author A reviewer has asked the author a question or requested changes and removed awaiting-review The author would like community review of the PR labels Mar 14, 2021
@apnelson1 apnelson1 added the awaiting-review The author would like community review of the PR label Mar 16, 2021
@apnelson1 apnelson1 removed the awaiting-author A reviewer has asked the author a question or requested changes label Mar 16, 2021
Copy link
Collaborator

@bryangingechen bryangingechen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!
bors r+

bors bot pushed a commit that referenced this pull request Mar 17, 2021
…typeclass for interval bijection lemmas (#6629)

This commit introduces a ``has_exists_add_of_le`` typeclass extending ``ordered_add_comm_monoid``; is the assumption needed so that additively translating an interval gives a bijection. We then prove this fact for all flavours of interval. 

https://leanprover.zulipchat.com/#narrow/stream/217875-Is-there.20code.20for.20X.3F/topic/Correct.20setting.20for.20positive.20shifts.20of.20intervals

Co-authored-by: Peter Nelson <71660771+apnelson1@users.noreply.github.com>
Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
@github-actions github-actions bot added ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.) and removed awaiting-review The author would like community review of the PR labels Mar 17, 2021
@bors
Copy link

bors bot commented Mar 17, 2021

Pull request successfully merged into master.

Build succeeded:

@bors bors bot changed the title feat(data/set/intervals/image_preimage, algebra/ordered_monoid): new typeclass for interval bijection lemmas [Merged by Bors] - feat(data/set/intervals/image_preimage, algebra/ordered_monoid): new typeclass for interval bijection lemmas Mar 17, 2021
@bors bors bot closed this Mar 17, 2021
@bors bors bot deleted the has_exists_add_of_le branch March 17, 2021 16:20
b-mehta pushed a commit that referenced this pull request Apr 2, 2021
…typeclass for interval bijection lemmas (#6629)

This commit introduces a ``has_exists_add_of_le`` typeclass extending ``ordered_add_comm_monoid``; is the assumption needed so that additively translating an interval gives a bijection. We then prove this fact for all flavours of interval. 

https://leanprover.zulipchat.com/#narrow/stream/217875-Is-there.20code.20for.20X.3F/topic/Correct.20setting.20for.20positive.20shifts.20of.20intervals

Co-authored-by: Peter Nelson <71660771+apnelson1@users.noreply.github.com>
Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants