[Merged by Bors] - feat(Algebra/Pi): add various AlgEquivs and RingEquivs#24520
[Merged by Bors] - feat(Algebra/Pi): add various AlgEquivs and RingEquivs#24520
AlgEquivs and RingEquivs#24520Conversation
PR summary 824629269a
|
| File | Base Count | Head Count | Change |
|---|---|---|---|
| Mathlib.Algebra.Algebra.Pi | 706 | 707 | +1 (+0.14%) |
Import changes for all files
| Files | Import difference |
|---|---|
3 filesMathlib.Algebra.Algebra.Pi Mathlib.RingTheory.Localization.Away.Basic Mathlib.RingTheory.Localization.Pi |
1 |
Declarations diff
+ funUnique
+ funUnique_apply
+ funUnique_symm_apply
+ piCongrLeft
+ piCongrLeft'
+ piCongrLeft'_apply
+ piCongrLeft'_symm_apply
+ piCongrLeft_apply
+ piCongrLeft_symm_apply
+ prodCongr
+ prodCongr_apply
+ prodCongr_symm_apply
+ sumArrowEquivProdArrow_symm_apply
+ sumArrowEquivProdArrow_symm_apply_inr
++ sumArrowEquivProdArrow
++ sumArrowEquivProdArrow_apply
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
relativevalue is the weighted sum of the differences with weight given by the inverse of the current value of the statistic. - The
absolutevalue is therelativevalue divided by the total sum of the inverses of the current values (i.e. the weighted average of the differences).
|
Looking at the stats, I'm afraid I'm not really convinced by the import changes here, and even less convinced that they should happen in this PR |
I am not sure I understand: What do you suggest? Revert the last three commits and accept the +19% import bump? Or just split this PR? |
|
My vote would be to revert the move and accept the import shuffe; the import changes shallow out pretty quickly |
|
So is the inconsistency with having |
Mathlib/Algebra/Ring/Equiv.lean
Outdated
| @[simp] | ||
| lemma sumArrowEquivProdArrow_symm_apply_inl (α β) (x : (α → R) × (β → R)) (a : α) : | ||
| (sumArrowEquivProdArrow R α β).symm x (Sum.inl a) = x.fst a := rfl | ||
|
|
||
| @[simp] | ||
| lemma sumArrowEquivProdArrow_symm_apply_inr (α β) (x : (α → R) × (β → R)) (b : β) : | ||
| (sumArrowEquivProdArrow R α β).symm x (Sum.inr b) = x.snd b := rfl |
There was a problem hiding this comment.
I think these should say
| @[simp] | |
| lemma sumArrowEquivProdArrow_symm_apply_inl (α β) (x : (α → R) × (β → R)) (a : α) : | |
| (sumArrowEquivProdArrow R α β).symm x (Sum.inl a) = x.fst a := rfl | |
| @[simp] | |
| lemma sumArrowEquivProdArrow_symm_apply_inr (α β) (x : (α → R) × (β → R)) (b : β) : | |
| (sumArrowEquivProdArrow R α β).symm x (Sum.inr b) = x.snd b := rfl | |
| @[simp] | |
| lemma sumArrowEquivProdArrow_apply (α β) (x) : | |
| sumArrowEquivProdArrow R α β x = Equiv.sumArrowEquivProdArrow x := rfl | |
| @[simp] | |
| lemma sumArrowEquivProdArrow_symm_apply (α β) (x : (α → R) × (β → R)) (b : β) : | |
| (sumArrowEquivProdArrow R α β).symm x = (Equiv.sumArrowEquivProdArrow).symm x := rfl |
which should replace the simps above (unless it can generate exactly these for you)
There was a problem hiding this comment.
(same for the other similar results)
There was a problem hiding this comment.
Don't you then lose all ring hom simp lemmas on RingEquiv.sumArrowEquivProdArrow? Or do you suggest to add map_{add,mul,zero,one} lemmas for Equiv.sumArrowEquivProdArrow?
There was a problem hiding this comment.
Those lemmas would apply before this one I think.
There was a problem hiding this comment.
It does not seem so:
example (x y) : sumArrowEquivProdArrow α β R (x + y) =
sumArrowEquivProdArrow α β R x + sumArrowEquivProdArrow α β R y := by
simp
fails (and succeeds if I remove simp from the lemmas you suggest).
There was a problem hiding this comment.
Does it work if you use simp 900 on the lemmas I suggested?
There was a problem hiding this comment.
No, it only starts working with simp 100 (simp 101 is the first non-working one).
There was a problem hiding this comment.
Strange, thanks for investigating! I can look into this further tomorrow
There was a problem hiding this comment.
#25165 will help here I think. For now, can you set the priority to low - 1, with a comment saying that this is lower than map_add etc.? Then we can merge this without the other one.
There was a problem hiding this comment.
Since #25165 was merged before this one, I switched all the low - 1 to low.
|
Could you update the description to be explicit about what the new |
AlgEquiv.prodCongrAlgEquivs and RingEquivs
erdOne
left a comment
There was a problem hiding this comment.
The discussion above seems to be addressed already, and the PR has been stale for months so I'll
maintainer merge
|
🚀 Pull request has been placed on the maintainer queue by erdOne. |
|
Thanks! bors merge |
Add - `RingEquiv.sumArrowEquivProdArrow`: ring version of `Equiv.sumArrowEquivProdArrow`. - `AlgEquiv.sumArrowEquivProdArrow`: algebra version of `Equiv.sumArrowEquivProdArrow`. - `AlgEquiv.piCongrLeft'`: algebra version of `Equiv.piCongrLeft`. - `AlgEquiv.piCongrLeft`: algebra version of `Equiv.piCongrLeft`. - `AlgEquiv.funUnique`: algebra version of `Equiv.funUnique`. - `AlgEquiv.prodCongr`: algebra version of `Equiv.prodCongr`. The four last ones already have ring versions.
|
Pull request successfully merged into master. Build succeeded: |
AlgEquivs and RingEquivsAlgEquivs and RingEquivs
…r-community#24520) Add - `RingEquiv.sumArrowEquivProdArrow`: ring version of `Equiv.sumArrowEquivProdArrow`. - `AlgEquiv.sumArrowEquivProdArrow`: algebra version of `Equiv.sumArrowEquivProdArrow`. - `AlgEquiv.piCongrLeft'`: algebra version of `Equiv.piCongrLeft`. - `AlgEquiv.piCongrLeft`: algebra version of `Equiv.piCongrLeft`. - `AlgEquiv.funUnique`: algebra version of `Equiv.funUnique`. - `AlgEquiv.prodCongr`: algebra version of `Equiv.prodCongr`. The four last ones already have ring versions.
…r-community#24520) Add - `RingEquiv.sumArrowEquivProdArrow`: ring version of `Equiv.sumArrowEquivProdArrow`. - `AlgEquiv.sumArrowEquivProdArrow`: algebra version of `Equiv.sumArrowEquivProdArrow`. - `AlgEquiv.piCongrLeft'`: algebra version of `Equiv.piCongrLeft`. - `AlgEquiv.piCongrLeft`: algebra version of `Equiv.piCongrLeft`. - `AlgEquiv.funUnique`: algebra version of `Equiv.funUnique`. - `AlgEquiv.prodCongr`: algebra version of `Equiv.prodCongr`. The four last ones already have ring versions.
…r-community#24520) Add - `RingEquiv.sumArrowEquivProdArrow`: ring version of `Equiv.sumArrowEquivProdArrow`. - `AlgEquiv.sumArrowEquivProdArrow`: algebra version of `Equiv.sumArrowEquivProdArrow`. - `AlgEquiv.piCongrLeft'`: algebra version of `Equiv.piCongrLeft`. - `AlgEquiv.piCongrLeft`: algebra version of `Equiv.piCongrLeft`. - `AlgEquiv.funUnique`: algebra version of `Equiv.funUnique`. - `AlgEquiv.prodCongr`: algebra version of `Equiv.prodCongr`. The four last ones already have ring versions.
Add
RingEquiv.sumArrowEquivProdArrow: ring version ofEquiv.sumArrowEquivProdArrow.AlgEquiv.sumArrowEquivProdArrow: algebra version ofEquiv.sumArrowEquivProdArrow.AlgEquiv.piCongrLeft': algebra version ofEquiv.piCongrLeft.AlgEquiv.piCongrLeft: algebra version ofEquiv.piCongrLeft.AlgEquiv.funUnique: algebra version ofEquiv.funUnique.AlgEquiv.prodCongr: algebra version ofEquiv.prodCongr.The four last ones already have ring versions.