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/equiv/basic): lemmas about images and preimages #6398

Closed
wants to merge 4 commits into from

Conversation

gebner
Copy link
Member

@gebner gebner commented Feb 24, 2021


@gebner gebner added the awaiting-review The author would like community review of the PR label Feb 24, 2021
@@ -353,6 +353,29 @@ protected lemma image_compl {α β} (f : equiv α β) (s : set α) :
f '' sᶜ = (f '' s)ᶜ :=
set.image_compl_eq f.bijective

@[simp] lemma symm_preimage_preimage {α β} (e : α ≃ β) (s : set β) :
e.symm ⁻¹' (e ⁻¹' s) = s :=
Copy link
Member

Choose a reason for hiding this comment

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

Do we have a lemma that says f ⁻¹' (g ⁻¹' s) = (f \comp g) ⁻¹' s or whatever variant of that is true?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes it's called preimage_preimage (as you would expect). That is, a few characters longer than the current proof.

Copy link
Member

Choose a reason for hiding this comment

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

Right, I ask only because simp would solve this automatically if preimage_preimage were marked simp

Copy link
Member Author

Choose a reason for hiding this comment

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

In general I'm not too happy to mark conditional simp lemmas as simp.

Copy link
Member

Choose a reason for hiding this comment

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

In what way is preimage_preimage conditional?

Copy link
Member Author

Choose a reason for hiding this comment

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

Ah sorry, I was looking at the wrong lemma. No, preimage_preimage is indeed not conditional. But then I'm not so sure it's a good idea to mark it simp (because it prevents lemmas like bar (foo ⁻¹' X) ↔ baz X from triggering).

Copy link
Member

Choose a reason for hiding this comment

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

Don't you mean lemmas like bar ⁻¹' (foo ⁻¹' X) ↔ baz X with ⁻¹' twice? Do we have any of those?

Copy link
Member

Choose a reason for hiding this comment

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

Either way, I guess its out of scope for this PR.

@robertylewis
Copy link
Member

bors merge

@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 Feb 25, 2021
@bors
Copy link

bors bot commented Feb 25, 2021

Pull request successfully merged into master.

Build succeeded:

@bors bors bot changed the title feat(data/equiv/basic): lemmas about images and preimages [Merged by Bors] - feat(data/equiv/basic): lemmas about images and preimages Feb 25, 2021
@bors bors bot closed this Feb 25, 2021
@bors bors bot deleted the equiv_lemmas branch February 25, 2021 13:12
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