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(measure_theory/measure/measure_space): In sigma finite measure spaces, disjoint unions can have at most countably many positive measure parts. #15492

Closed
wants to merge 19 commits into from

Conversation

kkytola
Copy link
Collaborator

@kkytola kkytola commented Jul 18, 2022

Main addition of this PR: In sigma finite measure spaces, disjoint unions can have at most countably many positive measure parts.

Also in this PR: A disjoint union whose measure is finite has at most finitely many parts of measure greater than any positive constant.


Open in Gitpod

@kkytola kkytola added the WIP Work in progress label Jul 18, 2022
@kkytola kkytola added awaiting-review The author would like community review of the PR and removed WIP Work in progress labels Jul 18, 2022
Copy link
Member

@fpvandoorn fpvandoorn left a comment

Choose a reason for hiding this comment

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

I think some things can be improved about this PR. I gave some suggestions to refactor the proofs.
I'm think the results in data/real/ennreal are very specific, so are probably not worth having in that generality. Some of them are unused, and I think you can avoid using the others by using an arbitrary sequence using something like exists_seq_strict_anti_tendsto instead of 1/n specifically.

@@ -1371,6 +1371,42 @@ begin
exact n.lt_two_pow
end

lemma Union_Ioi_add_inv_nat (z : ℝ≥0∞) : (⋃ (n : ℕ), Ioi (z + n⁻¹)) = Ioi z :=
Copy link
Member

Choose a reason for hiding this comment

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

It would be nice to have a lemma (⋃ (i : ι), Ioi (f i)) = Ioi (⨅ i, f i) (on an arbitrary type with appropriate order conditions), and that should simplify this proof.

Copy link
Collaborator Author

@kkytola kkytola Jul 19, 2022

Choose a reason for hiding this comment

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

I added the lemma you suggested, Union_Ioi_eq_Ioi_infi. But it is not clear it leads to a simplification here. I rewrote the proof (and also tested directly for the proof of the next lemma, if the current one is too specialized), and it is almost the same length and I think uses less familiar components.

I of course agree that Union_Ioi_eq_Ioi_infi is in principle good to have, and I'll try to find the right place for it. But I would consider reverting the proofs here to the original ones, or similar, perhaps keeping only the ones that are actually used in this PR.

Copy link
Member

Choose a reason for hiding this comment

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

There is ennreal.add_infi, and it would be nice if you could add lemmas computing ⨅ i, (f i)⁻¹ (I think that is (⨆ i, f i)⁻¹ assuming f i ≠ 0).

But as I said, I'm not sure if this special case is worth having, especially since you're not using it.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I removed these --- indeed exists_seq_strict_anti_tendsto' and the general lemmas you suggested are sufficiently convenient to use within the main proof that the auxiliary pieces here are not necessary.

by simp_rw [(show {x : ℝ≥0∞ | x ≠ 0} = Ioi 0, by { ext x, exact pos_iff_ne_zero.symm, }),
← ennreal.Union_Ioi_add_inv_nat 0, zero_add]

lemma Union_Ici_add_inv_nat {z : ℝ≥0∞} (z_ne_top : z ≠ ∞) : (⋃ (n : ℕ), Ici (z + n⁻¹)) = Ioi z :=
Copy link
Member

Choose a reason for hiding this comment

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

Can you prove (⋃ (i : ι), Ici (f i)) = Ioi (⨅ i, f i) under the assumption that there is no least f i? Not sure how to best write that, maybe disjoint (range f) (lower_bounds (range f)).

Copy link
Collaborator Author

@kkytola kkytola Nov 17, 2022

Choose a reason for hiding this comment

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

I don't think these parts will simplify a lot, but I made #17587 for what I think are the appropriate versions of the requested lemma. Instead of the disjoint (range f) (lower_bounds (range f)) spelling I propose is_glb and conditions about whether the glb is a member of the set (here the range) or not.

I'm requesting your review of that very small PR, I hope that's ok. I will return to the design choices in this PR afterwards.

src/measure_theory/measure/measure_space.lean Outdated Show resolved Hide resolved

/-- If the union of disjoint measurable sets has finite measure, then there are only
finitely many members of the union whose measure exceeds any given positive number. -/
lemma finite_const_le_meas_of_disjoint_Union {ι : Type*} [measurable_space α] {μ : measure α}
Copy link
Member

Choose a reason for hiding this comment

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

The main part of this proof should be a result about tsum on ennreal: if you have a tsum on ennreal that is finite, then there are finitely many terms above ε. I feel like we should have that already somewhere.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I found summable.tendsto_cofinite_zero. To me it would look useful to have also the more explicit statement about the finiteness of the set of indices for which the summands exceed a given positive level.

I will try to rewrite using this.

Copy link
Collaborator Author

@kkytola kkytola Jul 19, 2022

Choose a reason for hiding this comment

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

In fact, the summands here are ennreal-valued (measures), and so summable hypothesis is automatic from ennreal.summable, but useless because the additive group hypothesis is not true. Therefore summable.tendsto_cofinite_zero does not apply here. Maybe one needs ennreal-specific versions, with summable hypothesis replaced by ∑' i, a i < ∞.

I found also nnreal.tendsto_cofinite_zero_of_summable, but it is also not exactly what I want.

Copy link
Member

Choose a reason for hiding this comment

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

I agree that summable.tendsto_cofinite_zero doesn't apply, but probably you can easily get an ennreal version from nnreal.tendsto_cofinite_zero_of_summable (from the assumption that the tsum is finite, all elements are finite and you can use ennreal.to_nnreal to use the nnreal result).

Copy link
Collaborator Author

@kkytola kkytola Nov 18, 2022

Choose a reason for hiding this comment

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

The main part of this proof should be a result about tsum on ennreal: if you have a tsum on ennreal that is finite, then there are finitely many terms above ε. I feel like we should have that already somewhere.

As discussed, I don't believe we had this as such. I made #17588 for that. The approach there is to translate measure theory results from counting measure to tsum and finset.card, which may be a bit import-heavy, but I think it is way more convenient than to use cardinalities API directly (I expect the convenience gap will only increase in the long run for more substantial manipulation of tsums).

I'd be grateful if you could review that PR!


/-- In a σ-finite space, among disjoint measurable sets, only countably many can have positive
measure. -/
lemma countable_meas_pos_of_disjoint_Union
Copy link
Member

Choose a reason for hiding this comment

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

The main part of this proof should be a lemma about tsum on ennreal: if you have a tsum on ennreal that is finite, then there are countably many positive terms. I feel like we should have that already somewhere.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I did not actually find this fact about tsum, but it is a similar argument as in the PR, at least if one first reformulates summable.tendsto_cofinite_zero as the finiteness of the set of indices where the summands exceed a given positive level.

Copy link
Collaborator Author

@kkytola kkytola Jul 19, 2022

Choose a reason for hiding this comment

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

Actually... How did you plan to reduce countable_meas_pos_of_disjoint_Union to a fact about tsum anyway?

If the indexing type of the disjoint union is not countable to start with, the measure of the disjoint union is not the tsum of measures of the sets in the union. And if the indexing type is countable, there is nothing to prove.

Copy link
Member

Choose a reason for hiding this comment

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

Oh, that is a good point. I didn't think that through very well. Is it true that the measure of a (not necessarily countable) disjoint union is always at least the sum of the measures?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yes, I added tsum_meas_le_meas_Union_of_disjoint and use it to shorten the main proof.

@fpvandoorn fpvandoorn 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 Jul 19, 2022
@RemyDegenne RemyDegenne added the t-measure-probability Measure theory / Probability theory label Sep 14, 2022
@RemyDegenne
Copy link
Collaborator

Is this PR still awaiting-author?

@kkytola
Copy link
Collaborator Author

kkytola commented Oct 7, 2022

Is this PR still awaiting-author?

Yes! Sorry!

The remaining two implications of portmanteau theorem and also a useful variant of the layercake representation (needed also for one of the remaining portmanteau implications) definitely need this, so I have not abandoned this. It is just that I have time for Lean only very sporadically, and for the past two months I have unfortunately not had time for Lean. I keep hoping that I will have time for Lean "next weekend", and things related to the "awaiting author" issue here are first on my agenda.

Specifically, Floris raised some (perhaps minor) implementation questions, and I will have to think them through. I will want the implementation to be good for mathlib, and I want to simultaneously make sure that this applies to portmanteau and layercake as intended.

Or do you need this immediately for something else?

@RemyDegenne
Copy link
Collaborator

No problem, there is no rush and I don't need this right now. I simply saw that there were a couple of commits since the awaiting-author tag was applied and thought that maybe you forgot to switch it back to awaiting-review.

@kkytola kkytola requested a review from a team as a code owner November 18, 2022 09:07
@kkytola kkytola added awaiting-review The author would like community review of the PR and removed awaiting-author A reviewer has asked the author a question or requested changes labels Dec 1, 2022
@sgouezel sgouezel 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 2, 2022
@kkytola kkytola added awaiting-review The author would like community review of the PR and removed awaiting-author A reviewer has asked the author a question or requested changes labels Dec 3, 2022
@sgouezel
Copy link
Collaborator

sgouezel commented Dec 4, 2022

bors r+
Thanks!

@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 Dec 4, 2022
bors bot pushed a commit that referenced this pull request Dec 4, 2022
…paces, disjoint unions can have at most countably many positive measure parts. (#15492)

Main addition of this PR: In sigma finite measure spaces, disjoint unions can have at most countably many positive measure parts.

Also in this PR: A disjoint union whose measure is finite has at most finitely many parts of measure greater than any positive constant.



Co-authored-by: kkytola <“kalle.kytola@aalto.fi”>
@bors
Copy link

bors bot commented Dec 4, 2022

Pull request successfully merged into master.

Build succeeded:

@bors bors bot changed the title feat(measure_theory/measure/measure_space): In sigma finite measure spaces, disjoint unions can have at most countably many positive measure parts. [Merged by Bors] - feat(measure_theory/measure/measure_space): In sigma finite measure spaces, disjoint unions can have at most countably many positive measure parts. Dec 4, 2022
@bors bors bot closed this Dec 4, 2022
@bors bors bot deleted the kkytola/sigma_finite_countable_pos_meas branch December 4, 2022 12:16
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+`.) t-measure-probability Measure theory / Probability theory
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants