[Merged by Bors] - refactor(RingTheory/Ideal/Height): make Ideal.primeHeight private#37627
[Merged by Bors] - refactor(RingTheory/Ideal/Height): make Ideal.primeHeight private#37627Thmoas-Guan wants to merge 119 commits into
Ideal.primeHeight private#37627Conversation
PR summary 45b8864a30Import changes for modified filesNo significant changes to the import graph Import changes for all files
|
chrisflav
left a comment
There was a problem hiding this comment.
Thanks a lot!
maintainer merge
|
🚀 Pull request has been placed on the maintainer queue by chrisflav. |
|
Can you explain why you want to make this private and update both the PR title (add a verb) and the description with this explanation? |
Ideal.primeHeightIdeal.primeHeight private
The motivation is sort of vague, this part is from Andrew's old lean3 repo, but when migrating many things wasn't thought carefully enough. |
|
|
Yes, I imagined that this was the rationale. But given that the proof translating from the general height to prime height is easy but non-trivial (see mathlib4/Mathlib/RingTheory/Ideal/Height.lean Lines 44 to 48 in a0d161d primeHeight is only an implementation detail. I would argue that there might be cases where people are really only working with prime ideals and don't want to go through this each time.
|
|
If you want to use the order theoretic height, which only makes sense for prime ideals, you can use |
OK, perfect, thanks, now I understand and I've reviewed the whole PR with a different eye. |
|
bors r+ |
…37627) We mark `Ideal.primeHeight` as `private`, making `Ideal.height` the only public definition for heights of (prime) ideals. This makes the API more consistent and stops contributors from adding more declarations involving `Ideal.primeHeight`, which should instead be formulated in terms of `Ideal.height`. To relate `Ideal.height` to the order theoretic `Order.height` in the lattice of prime ideals `PrimeSpectrum` we add a lemma `PrimeSpectrum.height_eq_orderHeight`.
|
Build failed (retrying...): |
…37627) We mark `Ideal.primeHeight` as `private`, making `Ideal.height` the only public definition for heights of (prime) ideals. This makes the API more consistent and stops contributors from adding more declarations involving `Ideal.primeHeight`, which should instead be formulated in terms of `Ideal.height`. To relate `Ideal.height` to the order theoretic `Order.height` in the lattice of prime ideals `PrimeSpectrum` we add a lemma `PrimeSpectrum.height_eq_orderHeight`.
|
Pull request successfully merged into master. Build succeeded: |
Ideal.primeHeight privateIdeal.primeHeight private
…eanprover-community#37627) We mark `Ideal.primeHeight` as `private`, making `Ideal.height` the only public definition for heights of (prime) ideals. This makes the API more consistent and stops contributors from adding more declarations involving `Ideal.primeHeight`, which should instead be formulated in terms of `Ideal.height`. To relate `Ideal.height` to the order theoretic `Order.height` in the lattice of prime ideals `PrimeSpectrum` we add a lemma `PrimeSpectrum.height_eq_orderHeight`.
…eanprover-community#37627) We mark `Ideal.primeHeight` as `private`, making `Ideal.height` the only public definition for heights of (prime) ideals. This makes the API more consistent and stops contributors from adding more declarations involving `Ideal.primeHeight`, which should instead be formulated in terms of `Ideal.height`. To relate `Ideal.height` to the order theoretic `Order.height` in the lattice of prime ideals `PrimeSpectrum` we add a lemma `PrimeSpectrum.height_eq_orderHeight`.
…eanprover-community#37627) We mark `Ideal.primeHeight` as `private`, making `Ideal.height` the only public definition for heights of (prime) ideals. This makes the API more consistent and stops contributors from adding more declarations involving `Ideal.primeHeight`, which should instead be formulated in terms of `Ideal.height`. To relate `Ideal.height` to the order theoretic `Order.height` in the lattice of prime ideals `PrimeSpectrum` we add a lemma `PrimeSpectrum.height_eq_orderHeight`.


We mark
Ideal.primeHeightasprivate, makingIdeal.heightthe only public definition for heights of (prime) ideals. This makes the API more consistent and stops contributors from adding more declarations involvingIdeal.primeHeight, which should instead be formulated in terms ofIdeal.height.To relate
Ideal.heightto the order theoreticOrder.heightin the lattice of prime idealsPrimeSpectrumwe add a lemmaPrimeSpectrum.height_eq_orderHeight.