Skip to content

[Merged by Bors] - feat(SetTheory/Cardinal): generalize and rename theorems on Cardinal.sum#29351

Closed
staroperator wants to merge 10 commits intoleanprover-community:masterfrom
staroperator:cardinal_refactor
Closed

[Merged by Bors] - feat(SetTheory/Cardinal): generalize and rename theorems on Cardinal.sum#29351
staroperator wants to merge 10 commits intoleanprover-community:masterfrom
staroperator:cardinal_refactor

Conversation

@staroperator
Copy link
Copy Markdown
Collaborator

@staroperator staroperator commented Sep 4, 2025

Some theorems on Cardinal.sum f are taking f : ι → Cardinal.{max u v}, which can be generalized to f : ι → Cardinal.{v}. Also rename sum_le_iSup_lift, sum_eq_iSup_lift etc. to reflect their signatures in names.


Open in Gitpod

@github-actions
Copy link
Copy Markdown

github-actions bot commented Sep 4, 2025

PR summary 5c98c223ad

Import changes for modified files

No significant changes to the import graph

Import changes for all files
Files Import difference

Declarations diff

+ lift_iSup_le_sum
+ lift_le_sum
+ lift_power_sum
+ sum_eq_iSup_of_lift_mk_le_iSup
+ sum_eq_iSup_of_mk_le_iSup
+ sum_eq_lift_iSup_of_lift_mk_le_lift_iSup
+ sum_le_lift_mk_mul_iSup
+ sum_le_lift_mk_mul_iSup_lift
+ sum_le_mk_mul_iSup

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).

@staroperator staroperator added the t-set-theory Set theory label Sep 4, 2025
Copy link
Copy Markdown
Collaborator

@vihdzp vihdzp left a comment

Choose a reason for hiding this comment

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

Thank you!

(∀ i, f i < c) → iSup f < c :=
iSup_lt (by rwa [hc.cof_eq])

theorem sum_lt_lift_of_isRegular' {ι} {f : ι → Cardinal} {c : Cardinal} (hc : IsRegular c)
Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

This name is a bit scary. Any suggestions are welcome!

Copy link
Copy Markdown
Collaborator Author

@staroperator staroperator Sep 6, 2025

Choose a reason for hiding this comment

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

Renamed to IsRegular.sum_lt_of_lift_mk_lt_of_lift_lt. We should also rename other _of_isRegular theorems to IsRegular. in the same file in future.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

I have reverted those renames. I plan to do that with generalization of other IsRegular theorems together, in the future.

@staroperator staroperator changed the title feat(SetTheory/Cardinal): generalize some theorems on Cardinal.sum feat(SetTheory/Cardinal): generalize and rename theorems on Cardinal.sum Sep 6, 2025
Copy link
Copy Markdown
Contributor

@alreadydone alreadydone 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 delegate

(and please merge master)

@github-actions
Copy link
Copy Markdown

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

@ghost ghost added the maintainer-merge A reviewer has approved the changed; awaiting maintainer approval. label Oct 18, 2025
@riccardobrasca
Copy link
Copy Markdown
Member

Thanks!

bors merge

@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 Oct 22, 2025
mathlib-bors bot pushed a commit that referenced this pull request Oct 22, 2025
….sum` (#29351)

Some theorems on `Cardinal.sum f` are taking `f : ι → Cardinal.{max u v}`, which can be generalized to `f : ι → Cardinal.{v}`. Also rename `sum_le_iSup_lift`, `sum_eq_iSup_lift` etc. to reflect their signatures in names.
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Oct 22, 2025

Build failed (retrying...):

@alreadydone
Copy link
Copy Markdown
Contributor

alreadydone commented Oct 22, 2025

It would be nicer if you used merge rather than rebase to update the branch, since the comparison shows too large a diff with rebase. It took me a while to figure out the changes after my review are the four commits starting from 4fe67f2.
image

mathlib-bors bot pushed a commit that referenced this pull request Oct 22, 2025
….sum` (#29351)

Some theorems on `Cardinal.sum f` are taking `f : ι → Cardinal.{max u v}`, which can be generalized to `f : ι → Cardinal.{v}`. Also rename `sum_le_iSup_lift`, `sum_eq_iSup_lift` etc. to reflect their signatures in names.
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Oct 22, 2025

Build failed (retrying...):

@staroperator
Copy link
Copy Markdown
Collaborator Author

It would be nicer if you used merge rather than rebase to update the branch, since the comparison shows too large a diff with rebase. It took me a while to figure out the changes after my review are the four commits starting from 4fe67f2. image

Emm, I personally strongly prefer rebase because it makes neat commit history. Though what you said makes sense; let me try to do merge instead of rebase in my other PRs after someone has reviewed.

mathlib-bors bot pushed a commit that referenced this pull request Oct 22, 2025
….sum` (#29351)

Some theorems on `Cardinal.sum f` are taking `f : ι → Cardinal.{max u v}`, which can be generalized to `f : ι → Cardinal.{v}`. Also rename `sum_le_iSup_lift`, `sum_eq_iSup_lift` etc. to reflect their signatures in names.
@riccardobrasca
Copy link
Copy Markdown
Member

It would be nicer if you used merge rather than rebase to update the branch, since the comparison shows too large a diff with rebase. It took me a while to figure out the changes after my review are the four commits starting from 4fe67f2. image

Emm, I personally strongly prefer rebase because it makes neat commit history. Though what you said makes sense; let me try to do merge instead of rebase in my other PRs after someone has reviewed.

We squash merge, so the history of your branch does not really matter.

@staroperator
Copy link
Copy Markdown
Collaborator Author

It would be nicer if you used merge rather than rebase to update the branch, since the comparison shows too large a diff with rebase. It took me a while to figure out the changes after my review are the four commits starting from 4fe67f2. image

Emm, I personally strongly prefer rebase because it makes neat commit history. Though what you said makes sense; let me try to do merge instead of rebase in my other PRs after someone has reviewed.

We squash merge, so the history of your branch does not really matter.

That's right, keeping a neat commit history is my personal aestheticism 😃 Especially when merge does not allow deleting commits from dependency PRs.

mathlib-bors bot pushed a commit that referenced this pull request Oct 22, 2025
….sum` (#29351)

Some theorems on `Cardinal.sum f` are taking `f : ι → Cardinal.{max u v}`, which can be generalized to `f : ι → Cardinal.{v}`. Also rename `sum_le_iSup_lift`, `sum_eq_iSup_lift` etc. to reflect their signatures in names.
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Oct 22, 2025

Build failed (retrying...):

mathlib-bors bot pushed a commit that referenced this pull request Oct 22, 2025
….sum` (#29351)

Some theorems on `Cardinal.sum f` are taking `f : ι → Cardinal.{max u v}`, which can be generalized to `f : ι → Cardinal.{v}`. Also rename `sum_le_iSup_lift`, `sum_eq_iSup_lift` etc. to reflect their signatures in names.
mathlib-bors bot pushed a commit that referenced this pull request Oct 22, 2025
….sum` (#29351)

Some theorems on `Cardinal.sum f` are taking `f : ι → Cardinal.{max u v}`, which can be generalized to `f : ι → Cardinal.{v}`. Also rename `sum_le_iSup_lift`, `sum_eq_iSup_lift` etc. to reflect their signatures in names.
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Oct 22, 2025

Build failed (retrying...):

mathlib-bors bot pushed a commit that referenced this pull request Oct 22, 2025
….sum` (#29351)

Some theorems on `Cardinal.sum f` are taking `f : ι → Cardinal.{max u v}`, which can be generalized to `f : ι → Cardinal.{v}`. Also rename `sum_le_iSup_lift`, `sum_eq_iSup_lift` etc. to reflect their signatures in names.
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Oct 22, 2025

Pull request successfully merged into master.

Build succeeded:

@mathlib-bors mathlib-bors bot changed the title feat(SetTheory/Cardinal): generalize and rename theorems on Cardinal.sum [Merged by Bors] - feat(SetTheory/Cardinal): generalize and rename theorems on Cardinal.sum Oct 22, 2025
@mathlib-bors mathlib-bors bot closed this Oct 22, 2025
Jlh18 pushed a commit to Jlh18/mathlib4 that referenced this pull request Oct 24, 2025
….sum` (leanprover-community#29351)

Some theorems on `Cardinal.sum f` are taking `f : ι → Cardinal.{max u v}`, which can be generalized to `f : ι → Cardinal.{v}`. Also rename `sum_le_iSup_lift`, `sum_eq_iSup_lift` etc. to reflect their signatures in names.
BeibeiX0 pushed a commit to BeibeiX0/mathlib4 that referenced this pull request Nov 7, 2025
….sum` (leanprover-community#29351)

Some theorems on `Cardinal.sum f` are taking `f : ι → Cardinal.{max u v}`, which can be generalized to `f : ι → Cardinal.{v}`. Also rename `sum_le_iSup_lift`, `sum_eq_iSup_lift` etc. to reflect their signatures in names.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-to-merge This PR has been sent to bors. t-set-theory Set theory

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants