Skip to content

Commit db35195

Browse files
committed
fix(RingTheory/Ideal): quick fix Oka.lean (#28525)
I just noticed a naming discrepancy between the doc and the actual name of results in `Oka.lean` that I missed in #27200. The deprecation may not *really* be necessary since the theorem was added yesterday but better be safe. This PR is also the occasion to clean a little bit the proof of `IsOka.isPrime_of_maximal_not_isOka`.
1 parent 8939bd7 commit db35195

File tree

1 file changed

+18
-17
lines changed

1 file changed

+18
-17
lines changed

Mathlib/RingTheory/Ideal/Oka.lean

Lines changed: 18 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@ import Mathlib.RingTheory.Ideal.Colon
88
/-!
99
# Oka predicates
1010
11-
This file introduces the notion of oka predicates and standard results about them.
11+
This file introduces the notion of Oka predicates and standard results about them.
1212
1313
## Main results
1414
15-
- `Ideal.isPrime_of_maximal_not_isOka`: if an ideal is maximal for not satisfying an oka predicate
15+
- `Ideal.IsOka.isPrime_of_maximal_not`: if an ideal is maximal for not satisfying an Oka predicate,
1616
then it is prime.
17-
- `IsOka.forall_of_forall_prime`: if all prime ideals of a ring satisfy an oka predicate, then all
18-
its ideals also satisfy the predicate.
17+
- `Ideal.IsOka.forall_of_forall_prime`: if all prime ideals of a ring satisfy an Oka predicate,
18+
then all its ideals also satisfy the predicate.
1919
2020
## References
2121
@@ -39,25 +39,26 @@ namespace IsOka
3939

4040
variable {P : Ideal R → Prop}
4141

42-
/-- If an ideal is maximal for not satisfying an oka predicate then it is prime. -/
42+
/-- If an ideal is maximal for not satisfying an Oka predicate then it is prime. -/
4343
@[stacks 05KE]
44-
theorem isPrime_of_maximal_not_isOka (hP : IsOka P) {I : Ideal R}
45-
(hI : Maximal (¬P ·) I) : I.IsPrime := by
46-
by_contra h
47-
have I_ne_top : I ≠ ⊤ := fun hI' ↦ hI.prop (hI' ▸ hP.top)
48-
obtain ⟨a, ha, b, hb, hab⟩ := (not_isPrime_iff.1 h).resolve_left I_ne_top
49-
have h₁ : P (I ⊔ span {a}) := of_not_not <| hI.not_prop_of_gt (Submodule.lt_sup_iff_notMem.2 ha)
50-
have h₂ : P (I.colon (span {a})) := of_not_not <| hI.not_prop_of_gt <| lt_of_le_of_ne le_colon
51-
(fun H ↦ hb <| H ▸ mem_colon_singleton.2 (mul_comm a b ▸ hab))
52-
exact hI.prop (hP.oka h₁ h₂)
44+
theorem isPrime_of_maximal_not (hP : IsOka P) {I : Ideal R}
45+
(hI : Maximal (¬P ·) I) : I.IsPrime where
46+
ne_top' hI' := hI.prop (hI' ▸ hP.top)
47+
mem_or_mem' := by
48+
by_contra!
49+
obtain ⟨a, b, hab, ha, hb⟩ := this
50+
have h₁ : P (I ⊔ span {a}) := of_not_not <| hI.not_prop_of_gt (Submodule.lt_sup_iff_notMem.2 ha)
51+
have h₂ : P (I.colon (span {a})) := of_not_not <| hI.not_prop_of_gt <| lt_of_le_of_ne le_colon
52+
(fun H ↦ hb <| H ▸ mem_colon_singleton.2 (mul_comm a b ▸ hab))
53+
exact hI.prop (hP.oka h₁ h₂)
5354

54-
/-- If all prime ideals of a ring satisfy an oka predicate, then all its ideals also satisfy the
55+
/-- If all prime ideals of a ring satisfy an Oka predicate, then all its ideals also satisfy the
5556
predicate. `hmax` is generaly obtained using Zorn's lemma. -/
56-
theorem forall_of_forall_prime_isOka (hP : IsOka P)
57+
theorem forall_of_forall_prime (hP : IsOka P)
5758
(hmax : (∃ I, ¬P I) → ∃ I, Maximal (¬P ·) I) (hprime : ∀ I, I.IsPrime → P I) : ∀ I, P I := by
5859
by_contra!
5960
obtain ⟨I, hI⟩ := hmax this
60-
exact hI.prop <| hprime I (hP.isPrime_of_maximal_not_isOka hI)
61+
exact hI.prop <| hprime I (hP.isPrime_of_maximal_not hI)
6162

6263
end IsOka
6364

0 commit comments

Comments
 (0)