-
Notifications
You must be signed in to change notification settings - Fork 355
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
feat: A disjoint union is finite iff all sets are finite, and all but finitely many are empty #20457
base: master
Are you sure you want to change the base?
Conversation
PR summary 67885573b4Import changes for modified filesNo significant changes to the import graph Import changes for all files
|
Co-authored-by: Eric Wieser <[email protected]>
Thanks for the review! |
Mathlib/Data/Set/Finite/Lattice.lean
Outdated
finitely many are empty. -/ | ||
lemma PairwiseDisjoint.finite_biUnion_iff {f : β → Set α} {s : Set β} | ||
(hs : s.PairwiseDisjoint f) : | ||
Set.Finite (⋃ i ∈ s, f i) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd liked to have seen this be of the more general form
Set.Finite (⋃ i ∈ s, f i) | |
Set.Finite (⋃ (i) (h : i ∈ s, f i h) |
but I guess the definition of PairwiseDisjoint
doesn't permit this; so no action needed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bors d+
Consider waiting a day or two to let @YaelDillies have a look for any other API like elim_set
that can make this more concise
✌️ sgouezel can now approve this pull request. To approve and merge a pull request, simply reply with |
Co-authored-by: Yaël Dillies <[email protected]>
/-- An indexed union of pairwise disjoint sets is finite iff all sets are finite, and all but | ||
finitely many are empty. -/ | ||
lemma PairwiseDisjoint.finite_iUnion_iff {f : β → Set α} (hs : univ.PairwiseDisjoint f) : | ||
Set.Finite (⋃ i, f i) ↔ (∀ i, Set.Finite (f i)) ∧ Set.Finite {i | (f i).Nonempty} := by | ||
rw [← biUnion_univ, hs.finite_biUnion_iff] | ||
simp |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess this now duplicates finite_iUnion_iff
From the Carleson project