Skip to content

Commit e7b3fc0

Browse files
feat(RingTheory): Valuation.Integers.not_denselyOrdered_of_isPrincipalIdealRing (#15939)
On the way to the iff when the range of valuation on nonzeros is `MulArchimedean`. Co-authored-by: Yakov Pechersky <pechersky@users.noreply.github.com> Co-authored-by: Yakov Pechersky <ffxen158@gmail.com> Co-authored-by: Yaël Dillies <yael.dillies@gmail.com>
1 parent e4699df commit e7b3fc0

File tree

2 files changed

+48
-0
lines changed

2 files changed

+48
-0
lines changed

Mathlib/RingTheory/Ideal/Basic.lean

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -490,6 +490,9 @@ theorem mul_mem_right (h : a ∈ I) : a * b ∈ I :=
490490

491491
variable {b}
492492

493+
lemma mem_of_dvd (hab : a ∣ b) (ha : a ∈ I) : b ∈ I := by
494+
obtain ⟨c, rfl⟩ := hab; exact I.mul_mem_right _ ha
495+
493496
theorem pow_mem_of_mem (ha : a ∈ I) (n : ℕ) (hn : 0 < n) : a ^ n ∈ I :=
494497
Nat.casesOn n (Not.elim (by decide))
495498
(fun m _hm => (pow_succ a m).symm ▸ I.mul_mem_left (a ^ m) ha) hn

Mathlib/RingTheory/Valuation/Integers.lean

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ The elements with valuation less than or equal to 1.
1313
TODO: Define characteristic predicate.
1414
-/
1515

16+
open Set
1617

1718
universe u v w
1819

@@ -144,6 +145,50 @@ theorem eq_algebraMap_or_inv_eq_algebraMap (hv : Integers v O) (x : F) :
144145
obtain ⟨a, ha⟩ := exists_of_le_one hv h
145146
exacts [⟨a, Or.inl ha.symm⟩, ⟨a, Or.inr ha.symm⟩]
146147

148+
lemma isPrincipal_iff_exists_isGreatest (hv : Integers v O) {I : Ideal O} :
149+
I.IsPrincipal ↔ ∃ x, IsGreatest (v ∘ algebraMap O F '' I) x := by
150+
constructor <;> rintro ⟨x, hx⟩
151+
· refine ⟨(v ∘ algebraMap O F) x, ?_, ?_⟩
152+
· refine Set.mem_image_of_mem _ ?_
153+
simp [hx, Ideal.mem_span_singleton_self]
154+
· intro y hy
155+
simp only [Function.comp_apply, hx, Ideal.submodule_span_eq, Set.mem_image,
156+
SetLike.mem_coe, Ideal.mem_span_singleton] at hy
157+
obtain ⟨y, hy, rfl⟩ := hy
158+
exact le_of_dvd hv hy
159+
· obtain ⟨a, ha, rfl⟩ : ∃ a ∈ I, (v ∘ algebraMap O F) a = x := by simpa using hx.left
160+
refine ⟨a, ?_⟩
161+
ext b
162+
simp only [Ideal.submodule_span_eq, Ideal.mem_span_singleton]
163+
exact ⟨fun hb ↦ dvd_of_le hv (hx.2 <| mem_image_of_mem _ hb), fun hb ↦ I.mem_of_dvd hb ha⟩
164+
165+
lemma not_denselyOrdered_of_isPrincipalIdealRing [IsPrincipalIdealRing O] (hv : Integers v O) :
166+
¬ DenselyOrdered (range v) := by
167+
intro H
168+
-- nonunits as an ideal isn't defined here, nor shown to be equivalent to `v x < 1`
169+
set I : Ideal O := {
170+
carrier := v ∘ algebraMap O F ⁻¹' Iio (1 : Γ₀)
171+
add_mem' := fun {a b} ha hb ↦ by simpa using map_add_lt v ha hb
172+
zero_mem' := by simp
173+
smul_mem' := by
174+
intro c x
175+
simp only [mem_preimage, Function.comp_apply, mem_Iio, smul_eq_mul, _root_.map_mul]
176+
intro hx
177+
exact Right.mul_lt_one_of_le_of_lt (hv.map_le_one c) hx
178+
}
179+
obtain ⟨x, hx₁, hx⟩ :
180+
∃ x, v (algebraMap O F x) < 1
181+
v (algebraMap O F x) ∈ upperBounds (Iio 1 ∩ range (v ∘ algebraMap O F)) := by
182+
simpa [I, IsGreatest, hv.isPrincipal_iff_exists_isGreatest, ← image_preimage_eq_inter_range]
183+
using IsPrincipalIdealRing.principal I
184+
obtain ⟨y, hy, hy₁⟩ : ∃ y, v (algebraMap O F x) < v y ∧ v y < 1 := by
185+
simpa only [Subtype.exists, Subtype.mk_lt_mk, exists_range_iff, exists_prop]
186+
using H.dense ⟨v (algebraMap O F x), mem_range_self _⟩ ⟨1, 1, v.map_one⟩ hx₁
187+
obtain ⟨z, rfl⟩ := hv.exists_of_le_one hy₁.le
188+
exact hy.not_le <| hx ⟨hy₁, mem_range_self _⟩
189+
190+
-- TODO: isPrincipalIdealRing_iff_not_denselyOrdered when MulArchimedean
191+
147192
end Integers
148193

149194
end Field

0 commit comments

Comments
 (0)