Skip to content

[Merged by Bors] - feat(Topology): add ContinuousOn union API lemmas#22684

Closed
vlad902 wants to merge 6 commits intomasterfrom
vlad.tsyrklevich/continuouson-missing-lemmas
Closed

[Merged by Bors] - feat(Topology): add ContinuousOn union API lemmas#22684
vlad902 wants to merge 6 commits intomasterfrom
vlad.tsyrklevich/continuouson-missing-lemmas

Conversation

@vlad902
Copy link
Copy Markdown
Collaborator

@vlad902 vlad902 commented Mar 7, 2025

Add lemmas to allow going from continuity on two open sets to continuity on their union. Note that there is already an existing lemma for continuity on the union of two closed sets.

@vlad902 vlad902 added the t-topology Topological spaces, uniform spaces, metric spaces, filters label Mar 7, 2025
@github-actions github-actions bot added the new-contributor This PR was made by a contributor with at most 5 merged PRs. Welcome to the community! label Mar 7, 2025
@github-actions
Copy link
Copy Markdown

github-actions bot commented Mar 7, 2025

PR summary 5ecc602a70

Import changes for modified files

No significant changes to the import graph

Import changes for all files
Files Import difference

Declarations diff

+ ContinuousOn.union_of_isClosed
+ ContinuousOn.union_of_isOpen
+ continouousOn_union_iff_of_isClosed
+ continouousOn_union_iff_of_isOpen

You can run this locally as follows
## summary with just the declaration names:
./scripts/declarations_diff.sh <optional_commit>

## more verbose report:
./scripts/declarations_diff.sh long <optional_commit>

The doc-module for script/declarations_diff.sh contains some details about this script.


No changes to technical debt.

You can run this locally as

./scripts/technical-debt-metrics.sh pr_summary
  • The relative value is the weighted sum of the differences with weight given by the inverse of the current value of the statistic.
  • The absolute value is the relative value divided by the total sum of the inverses of the current values (i.e. the weighted average of the differences).

vlad902 added 2 commits March 9, 2025 10:31
Add two lemmas to allow going from continuity of a union to
continuity on the individual sets, and continuity on two open sets
to continuity on their union. Note that there is already one lemma
for continuity of two closed sets.
@vlad902 vlad902 force-pushed the vlad.tsyrklevich/continuouson-missing-lemmas branch from 1739c0f to 45686c0 Compare March 9, 2025 09:53
@vlad902
Copy link
Copy Markdown
Collaborator Author

vlad902 commented Mar 9, 2025

Done, thanks for the feedback

Copy link
Copy Markdown
Contributor

@grunweg grunweg left a comment

Choose a reason for hiding this comment

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

Thanks: this PR looks basically good to me - except for a naming question I'm not sure about.

fun h ↦ ContinuousOn.union_of_isClosed hs ht h.1 h.2⟩

/-- If a function is continuous on two open sets, it is also continuous on their union. -/
theorem ContinuousOn.union_of_isOpen (hs : IsOpen s) (ht : IsOpen t) {f : α → β}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Should this be called continuousOn_union_of_isOpen? @YaelDillies as you're a local naming expert

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

(Note that there is also an iff version below, so perhaps a slightly different name is needed.)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

If the current name is fine, the ContinuousOn hypothesis should come first.

@peabrainiac
Copy link
Copy Markdown
Collaborator

This looks mostly good to me now - thanks.

Regarding the question Michael raised earlier, my suggestion would be to rename continuousOn_union_of_isOpen to continuousOn_union_iff_of_isOpen for clarity but keep ContinuousOn.union_of_isOpen as it is - it seems like a useful lemma to have dot notation for. He's also right that a more sensible order of arguments is probably hfs, hft, hs, ht, though I have no particularly strong preference there. The same goes for the closed counterparts of course.

@sgouezel sgouezel added the awaiting-author A reviewer has asked the author a question or requested changes. label May 7, 2025
@vlad902
Copy link
Copy Markdown
Collaborator Author

vlad902 commented May 16, 2025

This looks mostly good to me now - thanks.

Regarding the question Michael raised earlier, my suggestion would be to rename continuousOn_union_of_isOpen to continuousOn_union_iff_of_isOpen for clarity but keep ContinuousOn.union_of_isOpen as it is - it seems like a useful lemma to have dot notation for. He's also right that a more sensible order of arguments is probably hfs, hft, hs, ht, though I have no particularly strong preference there. The same goes for the closed counterparts of course.

updated names / param ordering

@vlad902 vlad902 removed the awaiting-author A reviewer has asked the author a question or requested changes. label May 16, 2025
Copy link
Copy Markdown
Contributor

@grunweg grunweg left a comment

Choose a reason for hiding this comment

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

Thanks!
maintainer merge

@github-actions
Copy link
Copy Markdown

🚀 Pull request has been placed on the maintainer queue by grunweg.

@github-actions github-actions bot added the maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. label May 16, 2025
@sgouezel
Copy link
Copy Markdown
Contributor

bors r+
Thanks!

@ghost ghost added ready-to-merge This PR has been sent to bors. and removed maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. labels May 16, 2025
mathlib-bors bot pushed a commit that referenced this pull request May 16, 2025
Add lemmas to allow going from continuity on two open sets to continuity on their union. Note that there is already an existing lemma for continuity on the union of two closed sets.

Co-authored-by: Vlad Tsyrklevich <vlad@tsyrklevich.net>
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented May 16, 2025

Pull request successfully merged into master.

Build succeeded:

@mathlib-bors mathlib-bors bot changed the title feat(Topology): add ContinuousOn union API lemmas [Merged by Bors] - feat(Topology): add ContinuousOn union API lemmas May 16, 2025
@mathlib-bors mathlib-bors bot closed this May 16, 2025
@mathlib-bors mathlib-bors bot deleted the vlad.tsyrklevich/continuouson-missing-lemmas branch May 16, 2025 09:28
jano-wol pushed a commit that referenced this pull request May 16, 2025
Add lemmas to allow going from continuity on two open sets to continuity on their union. Note that there is already an existing lemma for continuity on the union of two closed sets.

Co-authored-by: Vlad Tsyrklevich <vlad@tsyrklevich.net>
bwehlin pushed a commit to bwehlin/mathlib4 that referenced this pull request May 31, 2025
…nity#22684)

Add lemmas to allow going from continuity on two open sets to continuity on their union. Note that there is already an existing lemma for continuity on the union of two closed sets.

Co-authored-by: Vlad Tsyrklevich <vlad@tsyrklevich.net>
mathlib-bors bot pushed a commit that referenced this pull request Jul 3, 2025
A function is continuous on a union of open sets iff it is continuous on each individual set.
This extends the results in #22684 to arbitrary unions; the `ContMDiffOn` analogue is proven in #26673.
joelriou pushed a commit to joelriou/mathlib4 that referenced this pull request Jul 7, 2025
A function is continuous on a union of open sets iff it is continuous on each individual set.
This extends the results in leanprover-community#22684 to arbitrary unions; the `ContMDiffOn` analogue is proven in leanprover-community#26673.
callesonne pushed a commit to callesonne/mathlib4 that referenced this pull request Jul 24, 2025
A function is continuous on a union of open sets iff it is continuous on each individual set.
This extends the results in leanprover-community#22684 to arbitrary unions; the `ContMDiffOn` analogue is proven in leanprover-community#26673.
hrmacbeth pushed a commit to szqzs/mathlib4 that referenced this pull request Jul 28, 2025
A function is continuous on a union of open sets iff it is continuous on each individual set.
This extends the results in leanprover-community#22684 to arbitrary unions; the `ContMDiffOn` analogue is proven in leanprover-community#26673.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

new-contributor This PR was made by a contributor with at most 5 merged PRs. Welcome to the community! ready-to-merge This PR has been sent to bors. t-topology Topological spaces, uniform spaces, metric spaces, filters

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants