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(Order/Filter) : add 2 constructors #9200

Closed
wants to merge 13 commits into from

Conversation

JADekker
Copy link
Collaborator

@JADekker JADekker commented Dec 22, 2023

Add two constructors to create filters from a property on sets:

  • Filter.comk if the property is stable under finite unions and set shrinking.
  • Filter.ofCountableUnion if the property is stable under countable unions and set shrinking

Filter.comk is the key ingredient in IsCompact.induction_on but may be convenient to have as individual building block.
A Filter generated by Filter.ofCountableUnion is a CountableInterFilter, which is given by the instance Filter.countableInter_ofCountableUnion.

Other changes

  • Use Filter.comk for Filter.cofinite, Bornology.ofBounded and MeasureTheory.Measure.cofinite.
  • Use Filter.ofCountableUnion for MeasureTheory.Measure.ae.
  • Use {_ : Bornology _} instead of [Bornology _] in some lemmas so that rw/simp work with non-instance bornologies.

Open in Gitpod

Add two definitions to create filter from a property on sets:
- Filter.ofProp_finite_inter if the property is stable under finite
  intersections and set enlargements.
- Filter.ofProp_finite_union if the property is stable under finite
  unions and set shrinking.

Filter.ofProp_finite_union is the key ingredient in
IsCompact.induction_on but may be convenient to have as individual
building block.

Both results also specialise to properties that are stable under
countable unions/intersections, in which case the filter is a
CountableInterFilter. This plays a role in IsLindelof.induction_on and
will be added when this PR is accepted.
@JADekker JADekker added awaiting-review The author would like community review of the PR awaiting-CI t-topology Topological spaces, uniform spaces, metric spaces, filters new-contributor This PR was made by a contributor with fewer than 5 merged PRs. Welcome to the community! labels Dec 22, 2023
@urkud urkud 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 Dec 23, 2023
Rename Filter.ofProp_finite_union to Filter.comk
Remove Filter.ofProp_finite_inter
@JADekker JADekker added awaiting-review The author would like community review of the PR awaiting-CI and removed awaiting-author A reviewer has asked the author a question or requested changes labels Dec 24, 2023
@JADekker JADekker requested a review from urkud December 24, 2023 06:19
@urkud
Copy link
Member

urkud commented Dec 25, 2023

I added Filter.ofCountableUnion which is the constructor you need for Lindelöf spaces. Please update the top-level comment which will become the commit message.

@urkud urkud 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 Dec 25, 2023
@urkud urkud changed the title feat(Order/Filter/Basic) : Add Filter from prop feat(Order/Filter) : add 2 constructors Dec 25, 2023
@JADekker JADekker added awaiting-review The author would like community review of the PR awaiting-CI and removed awaiting-author A reviewer has asked the author a question or requested changes labels Dec 26, 2023
Also reorder arguments so that they match `Bornology.ofBounded`.
@leanprover-community-mathlib4-bot leanprover-community-mathlib4-bot added blocked-by-other-PR This PR depends on another PR which is still in the queue. merge-conflict The PR has a merge conflict with master, and needs manual merging. and removed blocked-by-other-PR This PR depends on another PR which is still in the queue. labels Dec 31, 2023
@leanprover-community-mathlib4-bot
Copy link
Collaborator

This PR/issue depends on:

@leanprover-community-mathlib4-bot leanprover-community-mathlib4-bot removed the merge-conflict The PR has a merge conflict with master, and needs manual merging. label Jan 2, 2024
@urkud
Copy link
Member

urkud commented Jan 2, 2024

maintainer merge

Copy link

github-actions bot commented Jan 2, 2024

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

Copy link
Member

@jcommelin jcommelin 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 merge

@leanprover-community-mathlib4-bot leanprover-community-mathlib4-bot added ready-to-merge This PR has been sent to bors. and removed awaiting-review The author would like community review of the PR labels Jan 2, 2024
mathlib-bors bot pushed a commit that referenced this pull request Jan 2, 2024
Add two constructors to create filters from a property on sets:
- `Filter.comk` if the property is stable under finite unions and set shrinking.
- `Filter.ofCountableUnion` if the property is stable under countable unions and set shrinking

`Filter.comk` is the key ingredient in `IsCompact.induction_on` but may be convenient to have as individual building block.
A `Filter` generated by `Filter.ofCountableUnion` is a `CountableInterFilter`, which is given by the instance `Filter.countableInter_ofCountableUnion`. 

### Other changes

- Use `Filter.comk` for `Filter.cofinite`, `Bornology.ofBounded` and `MeasureTheory.Measure.cofinite`.
- Use `Filter.ofCountableUnion` for `MeasureTheory.Measure.ae`.
- Use `{_ : Bornology _}` instead of `[Bornology _]` in some lemmas so that `rw/simp` work with non-instance bornologies.



Co-authored-by: Yury G. Kudryashov <urkud@urkud.name>
@mathlib-bors
Copy link

mathlib-bors bot commented Jan 2, 2024

Build failed:

@JADekker
Copy link
Collaborator Author

JADekker commented Jan 2, 2024

Does the failure of the build relate to the cache issues recently discussed on Zulip?

Topology/Compactness/Compact now imports Order/Filter/Basic to have
access to Filter.comk
@JADekker
Copy link
Collaborator Author

JADekker commented Jan 4, 2024

I've fixed the import issue, now everything seems to work!

@PatrickMassot
Copy link
Member

bors merge

mathlib-bors bot pushed a commit that referenced this pull request Jan 4, 2024
Add two constructors to create filters from a property on sets:
- `Filter.comk` if the property is stable under finite unions and set shrinking.
- `Filter.ofCountableUnion` if the property is stable under countable unions and set shrinking

`Filter.comk` is the key ingredient in `IsCompact.induction_on` but may be convenient to have as individual building block.
A `Filter` generated by `Filter.ofCountableUnion` is a `CountableInterFilter`, which is given by the instance `Filter.countableInter_ofCountableUnion`. 

### Other changes

- Use `Filter.comk` for `Filter.cofinite`, `Bornology.ofBounded` and `MeasureTheory.Measure.cofinite`.
- Use `Filter.ofCountableUnion` for `MeasureTheory.Measure.ae`.
- Use `{_ : Bornology _}` instead of `[Bornology _]` in some lemmas so that `rw/simp` work with non-instance bornologies.



Co-authored-by: Yury G. Kudryashov <urkud@urkud.name>
@mathlib-bors
Copy link

mathlib-bors bot commented Jan 4, 2024

Pull request successfully merged into master.

Build succeeded:

@mathlib-bors mathlib-bors bot changed the title feat(Order/Filter) : add 2 constructors [Merged by Bors] - feat(Order/Filter) : add 2 constructors Jan 4, 2024
@mathlib-bors mathlib-bors bot closed this Jan 4, 2024
@mathlib-bors mathlib-bors bot deleted the JADekker_filter_from_prop branch January 4, 2024 18:37
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 fewer than 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.

None yet

5 participants