Skip to content

[Merged by Bors] - feat(Algebra/Group/Even): "Advanced" lemmas about even elements.#20272

Closed
artie2000 wants to merge 8 commits intomasterfrom
artie2000-sq-advanced
Closed

[Merged by Bors] - feat(Algebra/Group/Even): "Advanced" lemmas about even elements.#20272
artie2000 wants to merge 8 commits intomasterfrom
artie2000-sq-advanced

Conversation

@artie2000
Copy link
Copy Markdown
Collaborator

@artie2000 artie2000 commented Dec 27, 2024

Add construction of subgroup of even elements / squares.
Add result that squares (IsSquare) are non-negative.

These results cannot be added to Mathlib.Algebra.Group.Even directly because of import restrictions.
This PR is split off from #16094


Open in Gitpod

@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 Dec 27, 2024
@github-actions
Copy link
Copy Markdown

github-actions bot commented Dec 27, 2024

PR summary 3b54ab6da1

Import changes for modified files

No significant changes to the import graph

Import changes for all files
Files Import difference
Mathlib.Algebra.Group.Subgroup.Even (new file) 346

Declarations diff

+ IsSquare.nonneg
+ squareIn_toSubmonoid
+ squareIn_toSubsemigroup
+++ coe_squareIn
+++ mem_squareIn
+++ squareIn

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

@mathlib4-dependent-issues-bot mathlib4-dependent-issues-bot added blocked-by-other-PR This PR depends on another PR (this label is automatically managed by a bot) and removed blocked-by-other-PR This PR depends on another PR (this label is automatically managed by a bot) labels Dec 27, 2024
@mathlib4-dependent-issues-bot
Copy link
Copy Markdown
Collaborator

This PR/issue depends on:

@leanprover-community-bot-assistant leanprover-community-bot-assistant added the merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) label Dec 28, 2024
@YaelDillies
Copy link
Copy Markdown
Contributor

Advanced isn't really descriptive. What about Algebra.Group.Submonoid.Even?

@artie2000
Copy link
Copy Markdown
Collaborator Author

Advanced isn't really descriptive. What about Algebra.Group.Submonoid.Even?

That sounds good, but I'm also adding the non-negativity result. Maybe that should go elsewhere? Not sure where the right home for it is. It can't go in Algebra.Group.Even due to import restrictions on order.

@leanprover-community-bot-assistant leanprover-community-bot-assistant removed the merge-conflict The PR has a merge conflict with master, and needs manual merging. (this label is managed by a bot) label Dec 28, 2024
@YaelDillies
Copy link
Copy Markdown
Contributor

What about a file under Algebra.Order.Group? Also note that the diff currently contains unrelated changes. Likely your last merge was botched somehow.

@artie2000
Copy link
Copy Markdown
Collaborator Author

Uhh
I think I messed up the diff somehow
I was just trying to rebase onto the latest changes

@artie2000 artie2000 force-pushed the artie2000-sq-advanced branch from 9d9d7f8 to 406491e Compare December 28, 2024 19:26
@artie2000
Copy link
Copy Markdown
Collaborator Author

What about a file under Algebra.Order.Group? Also note that the diff currently contains unrelated changes. Likely your last merge was botched somehow.

The lemma this is a variation on (mul_self_nonneg) is in Algebra.Order.Ring.Unbundled.Basic. However, import restrictions prevent me from putting the lemma directly into that file (Group.Even imports MonoidHom). Other files such as Algebra.Order.Ring.Basic are about bundled order typeclasses. I've put it at the top of Algebra.Order.Ring.Basic for now, but this doesn't feel like the right solution.

@YaelDillies
Copy link
Copy Markdown
Contributor

I see you fiddle with Mathlib.lean quite a lot. Do you know about lake exe mk_all?

@jcommelin jcommelin added the awaiting-author A reviewer has asked the author a question or requested changes. label Jan 2, 2025
@artie2000 artie2000 added t-algebra Algebra (groups, rings, fields, etc) and removed awaiting-author A reviewer has asked the author a question or requested changes. new-contributor This PR was made by a contributor with at most 5 merged PRs. Welcome to the community! labels Jan 2, 2025
Copy link
Copy Markdown
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

@ghost ghost added the ready-to-merge This PR has been sent to bors. label Jan 3, 2025
mathlib-bors bot pushed a commit that referenced this pull request Jan 3, 2025
)

Add construction of subgroup of even elements / squares.
Add result that squares (`IsSquare`) are non-negative.

These results cannot be added to `Mathlib.Algebra.Group.Even` directly because of import restrictions.
This PR is split off from #16094
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Jan 3, 2025

Build failed (retrying...):

  • Build

mathlib-bors bot pushed a commit that referenced this pull request Jan 3, 2025
)

Add construction of subgroup of even elements / squares.
Add result that squares (`IsSquare`) are non-negative.

These results cannot be added to `Mathlib.Algebra.Group.Even` directly because of import restrictions.
This PR is split off from #16094
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Jan 3, 2025

Build failed (retrying...):

mathlib-bors bot pushed a commit that referenced this pull request Jan 3, 2025
)

Add construction of subgroup of even elements / squares.
Add result that squares (`IsSquare`) are non-negative.

These results cannot be added to `Mathlib.Algebra.Group.Even` directly because of import restrictions.
This PR is split off from #16094
@mathlib-bors
Copy link
Copy Markdown
Contributor

mathlib-bors bot commented Jan 3, 2025

Pull request successfully merged into master.

Build succeeded:

@mathlib-bors mathlib-bors bot changed the title feat(Algebra/Group/Even): "Advanced" lemmas about even elements. [Merged by Bors] - feat(Algebra/Group/Even): "Advanced" lemmas about even elements. Jan 3, 2025
@mathlib-bors mathlib-bors bot closed this Jan 3, 2025
@mathlib-bors mathlib-bors bot deleted the artie2000-sq-advanced branch January 3, 2025 07:31
mathlib-bors bot pushed a commit that referenced this pull request Jan 6, 2025
* Follows on from #20272
* Rename some substructure constructions to align with `oneLE` / `nonneg`
* Clarify some documentation

Moves:
* squareIn -> square
* evenIn -> even
* sumSqIn -> sumSq
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-algebra Algebra (groups, rings, fields, etc)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants