Skip to content

Commit 30443f0

Browse files
committed
feat(RingTheory/Localization): R ⧸ pⁿ ≃+* Rₚ ⧸ (maximalIdeal Rₚ)ⁿ
1 parent f04df22 commit 30443f0

File tree

3 files changed

+53
-0
lines changed

3 files changed

+53
-0
lines changed

Mathlib/Algebra/Ring/Subring/Basic.lean

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -915,6 +915,14 @@ def subringCongr (h : s = t) : s ≃+* t :=
915915
map_mul' := fun _ _ => rfl
916916
map_add' := fun _ _ => rfl }
917917

918+
@[simp]
919+
theorem subringCongr_symm (h : s = t) :
920+
(subringCongr h).symm = subringCongr (h.symm) := rfl
921+
922+
@[simp]
923+
theorem coe_subringCongr_apply (h : s = t) (x : s) :
924+
(subringCongr h x).val = x.val := rfl
925+
918926
/-- Restrict a ring homomorphism with a left inverse to a ring isomorphism to its
919927
`RingHom.range`. -/
920928
def ofLeftInverse {g : S → R} {f : R →+* S} (h : Function.LeftInverse g f) : R ≃+* f.range :=

Mathlib/RingTheory/Ideal/Quotient/Nilpotent.lean

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,3 +90,10 @@ theorem Ideal.Quotient.isUnit_mk_pow_iff_notMem [I.IsMaximal] {n : ℕ} (hn : n
9090
let := Ideal.Quotient.field I
9191
rw [isUnit_mk_pow_iff_isUnit_mk I hn, isUnit_iff_ne_zero]
9292
exact Ideal.Quotient.eq_zero_iff_mem.not
93+
94+
theorem Ideal.Quotient.notMem_of_isUnit_mk_pow [I.IsMaximal] {n : ℕ} {x : S} (hx : x ∉ I) :
95+
IsUnit (mk (I ^ n) x) := by
96+
by_cases! hn : n = 0
97+
· rw [pow_eq_top_iff.mpr (Or.inr hn)]
98+
exact isUnit_of_subsingleton _
99+
exact (isUnit_mk_pow_iff_notMem I hn).mpr hx

Mathlib/RingTheory/Localization/AtPrime/Basic.lean

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ public import Mathlib.RingTheory.LocalRing.MaximalIdeal.Basic
1111
public import Mathlib.RingTheory.Localization.Basic
1212
public import Mathlib.RingTheory.Localization.Ideal
1313
public import Mathlib.RingTheory.Ideal.MinimalPrime.Basic
14+
public import Mathlib.RingTheory.Ideal.Quotient.Nilpotent
1415

1516
/-!
1617
# Localizations of commutative rings at the complement of a prime ideal
@@ -508,6 +509,43 @@ theorem equivQuotMaximalIdeal_symm_apply_mk (x : R) (s : p.primeCompl) :
508509
@[deprecated (since := "2025-11-13")] alias _root_.equivQuotMaximalIdealOfIsLocalization :=
509510
equivQuotMaximalIdeal
510511

512+
set_option backward.isDefEq.respectTransparency false in
513+
/-- The isomorphism `R ⧸ p ^ n ≃+* Rₚ ⧸ maximalIdeal Rₚ ^ n`, where `Rₚ` satisfies
514+
`IsLocalization.AtPrime Rₚ p`. -/
515+
noncomputable
516+
def equivQuotMaximalIdealPow (n : ℕ) : R ⧸ p ^ n ≃+* Rₚ ⧸ IsLocalRing.maximalIdeal Rₚ ^ n := by
517+
refine Subring.topEquiv.symm.trans <| -- R ⧸ p ^ n ≃ (⊤ : Subring (R ⧸ p ^ n))
518+
(RingEquiv.subringCongr ?_).trans <| -- ⊤ = (R ⧸ p ^ n ← Rₚ / ker).range
519+
(IsLocalization.lift fun (u : p.primeCompl) ↦ -- (R ⧸ p ^ n ← Rₚ) => R ⧸ p ^ n ← Rₚ / ker
520+
Ideal.Quotient.notMem_of_isUnit_mk_pow _
521+
(mem_primeCompl_iff.mp u.prop)).quotientKerEquivRange.symm.trans <|
522+
quotEquivOfEq ?_ -- ker = maximalIdeal ^ n
523+
· symm
524+
rw [RingHom.range_eq_top, IsLocalization.lift_surjective_iff]
525+
intro u
526+
obtain ⟨x, hx⟩ := Ideal.Quotient.mk_surjective u
527+
exact ⟨⟨x, 1⟩, by simp [hx]⟩
528+
· ext x
529+
obtain ⟨a, b, rfl⟩ := IsLocalization.exists_mk'_eq p.primeCompl x
530+
suffices a ∈ p ^ n ↔ algebraMap R Rₚ a ∈ IsLocalRing.maximalIdeal Rₚ ^ n by
531+
simpa [Ideal.Quotient.eq_zero_iff_mem, IsLocalization.mk'_mem_iff]
532+
rw [← map_eq_maximalIdeal p Rₚ, ← Ideal.map_pow,
533+
algebraMap_mem_map_algebraMap_iff p.primeCompl Rₚ]
534+
refine ⟨fun h ↦ ⟨1, by simp, by simp [h]⟩, fun ⟨m, hm, h⟩ ↦ ?_⟩
535+
exact (IsMaximal.mul_mem_pow _ h).resolve_left (mem_primeCompl_iff.mp hm)
536+
537+
@[simp]
538+
theorem equivQuotMaximalIdealPow_apply_mk (n : ℕ) (x : R) :
539+
equivQuotMaximalIdealPow p Rₚ n (Ideal.Quotient.mk _ x) =
540+
Ideal.Quotient.mk _ (algebraMap R Rₚ x) := by
541+
simp only [equivQuotMaximalIdealPow, RingEquiv.coe_trans, Function.comp_apply]
542+
rw [← RingEquiv.eq_symm_apply, RingEquiv.symm_apply_eq]
543+
simp only [RingHom.quotientKerEquivRange, Ideal.quotEquivOfEq_symm, Ideal.quotEquivOfEq_mk,
544+
RingEquiv.coe_trans, Function.comp_apply, RingHom.quotientKerEquivOfSurjective_apply_mk]
545+
rw [← RingEquiv.eq_symm_apply]
546+
ext
547+
simp
548+
511549
variable {Sₚ : Type*} [CommRing S] [Algebra R S] [CommRing Sₚ] [Algebra S Sₚ] [Algebra R Sₚ]
512550
variable [Algebra Rₚ Sₚ] [IsLocalization (Algebra.algebraMapSubmonoid S p.primeCompl) Sₚ]
513551
variable [IsScalarTower R S Sₚ]

0 commit comments

Comments
 (0)