Skip to content

Commit 17a95d6

Browse files
committed
feat(AlgebraicGeometry): residue field of a point and evaluation (#14302)
Defines the residue field of a point of a locally ringed space and the corresponding evaluation map.
1 parent 15d0b10 commit 17a95d6

File tree

4 files changed

+164
-0
lines changed

4 files changed

+164
-0
lines changed

Mathlib.lean

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2554,6 +2554,7 @@ import Mathlib.Geometry.Manifold.WhitneyEmbedding
25542554
import Mathlib.Geometry.RingedSpace.Basic
25552555
import Mathlib.Geometry.RingedSpace.LocallyRingedSpace
25562556
import Mathlib.Geometry.RingedSpace.LocallyRingedSpace.HasColimits
2557+
import Mathlib.Geometry.RingedSpace.LocallyRingedSpace.ResidueField
25572558
import Mathlib.Geometry.RingedSpace.OpenImmersion
25582559
import Mathlib.Geometry.RingedSpace.PresheafedSpace
25592560
import Mathlib.Geometry.RingedSpace.PresheafedSpace.Gluing

Mathlib/AlgebraicGeometry/GammaSpecAdjunction.lean

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,18 @@ def ΓToStalk (x : X) : Γ.obj (op X) ⟶ X.presheaf.stalk x :=
6969
X.presheaf.germ (⟨x, trivial⟩ : (⊤ : Opens X))
7070
#align algebraic_geometry.LocallyRingedSpace.Γ_to_stalk AlgebraicGeometry.LocallyRingedSpace.ΓToStalk
7171

72+
lemma ΓToStalk_stalkMap {X Y : LocallyRingedSpace} (f : X ⟶ Y) (x : X) :
73+
Y.ΓToStalk (f.val.base x) ≫ PresheafedSpace.stalkMap f.val x =
74+
f.val.c.app (op ⊤) ≫ X.ΓToStalk x := by
75+
dsimp only [LocallyRingedSpace.ΓToStalk]
76+
rw [PresheafedSpace.stalkMap_germ']
77+
78+
lemma ΓToStalk_stalkMap_apply {X Y : LocallyRingedSpace} (f : X ⟶ Y) (x : X)
79+
(a : Y.presheaf.obj (op ⊤)) :
80+
PresheafedSpace.stalkMap f.val x (Y.ΓToStalk (f.val.base x) a) =
81+
X.ΓToStalk x (f.val.c.app (op ⊤) a) := by
82+
simpa using congrFun (congrArg DFunLike.coe <| ΓToStalk_stalkMap f x) a
83+
7284
/-- The canonical map from the underlying set to the prime spectrum of `Γ(X)`. -/
7385
def toΓSpecFun : X → PrimeSpectrum (Γ.obj (op X)) := fun x =>
7486
comap (X.ΓToStalk x) (LocalRing.closedPoint (X.presheaf.stalk x))
Lines changed: 137 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,137 @@
1+
/-
2+
Copyright (c) 2024 Christian Merten. All rights reserved.
3+
Released under Apache 2.0 license as described in the file LICENSE.
4+
Authors: Christian Merten
5+
-/
6+
import Mathlib.Geometry.RingedSpace.LocallyRingedSpace
7+
8+
/-!
9+
10+
# Residue fields of points
11+
12+
Any point `x` of a locally ringed space `X` comes with a natural residue field, namely the residue
13+
field of the stalk at `x`. Moreover, for every open subset of `X` containing `x`, we have a
14+
canonical evaluation map from `Γ(X, U)` to the residue field of `X` at `x`.
15+
16+
## Main definitions
17+
18+
The following are in the `AlgebraicGeometry.LocallyRingedSpace` namespace:
19+
20+
- `residueField`: the residue field of the stalk at `x`.
21+
- `evaluation`: for open subsets `U` of `X` containing `x`, the evaluation map from sections over
22+
`U` to the residue field at `x`.
23+
- `evaluationMap`: a morphism of locally ringed spaces induces a morphism, i.e. extension, of
24+
residue fields.
25+
26+
-/
27+
28+
universe u
29+
30+
open CategoryTheory TopologicalSpace Opposite
31+
32+
noncomputable section
33+
34+
namespace AlgebraicGeometry.LocallyRingedSpace
35+
36+
variable (X : LocallyRingedSpace.{u}) {U : Opens X}
37+
38+
/-- The residue field of `X` at a point `x` is the residue field of the stalk of `X`
39+
at `x`. -/
40+
def residueField (x : X) : CommRingCat :=
41+
CommRingCat.of <| LocalRing.ResidueField (X.stalk x)
42+
43+
instance (x : X) : Field (X.residueField x) :=
44+
inferInstanceAs <| Field (LocalRing.ResidueField (X.stalk x))
45+
46+
/--
47+
If `U` is an open of `X` containing `x`, we have a canonical ring map from the sections
48+
over `U` to the residue field of `x`.
49+
50+
If we interpret sections over `U` as functions of `X` defined on `U`, then this ring map
51+
corresponds to evaluation at `x`.
52+
-/
53+
def evaluation (x : U) : X.presheaf.obj (op U) ⟶ X.residueField x :=
54+
X.presheaf.germ x ≫ LocalRing.residue _
55+
56+
/-- The global evaluation map from `Γ(X, ⊤)` to the residue field at `x`. -/
57+
def Γevaluation (x : X) : X.presheaf.obj (op ⊤) ⟶ X.residueField x :=
58+
X.evaluation ⟨x, show x ∈ ⊤ from trivial⟩
59+
60+
@[simp]
61+
lemma evaluation_eq_zero_iff_not_mem_basicOpen (x : U) (f : X.presheaf.obj (op U)) :
62+
X.evaluation x f = 0 ↔ x.val ∉ X.toRingedSpace.basicOpen f := by
63+
rw [X.toRingedSpace.mem_basicOpen f x, ← not_iff_not, not_not]
64+
exact (LocalRing.residue_ne_zero_iff_isUnit _)
65+
66+
lemma evaluation_ne_zero_iff_mem_basicOpen (x : U) (f : X.presheaf.obj (op U)) :
67+
X.evaluation x f ≠ 0 ↔ x.val ∈ X.toRingedSpace.basicOpen f := by
68+
simp
69+
70+
@[simp]
71+
lemma Γevaluation_eq_zero_iff_not_mem_basicOpen (x : X) (f : X.presheaf.obj (op ⊤)) :
72+
X.Γevaluation x f = 0 ↔ x ∉ X.toRingedSpace.basicOpen f :=
73+
evaluation_eq_zero_iff_not_mem_basicOpen X ⟨x, show x ∈ ⊤ by trivial⟩ f
74+
75+
lemma Γevaluation_ne_zero_iff_mem_basicOpen (x : X) (f : X.presheaf.obj (op ⊤)) :
76+
X.Γevaluation x f ≠ 0 ↔ x ∈ X.toRingedSpace.basicOpen f :=
77+
evaluation_ne_zero_iff_mem_basicOpen X ⟨x, show x ∈ ⊤ by trivial⟩ f
78+
79+
variable {X Y : LocallyRingedSpace.{u}} (f : X ⟶ Y)
80+
81+
/-- If `X ⟶ Y` is a morphism of locally ringed spaces and `x` a point of `X`, we obtain
82+
a morphism of residue fields in the other direction. -/
83+
def residueFieldMap (x : X) : Y.residueField (f.val.base x) ⟶ X.residueField x :=
84+
LocalRing.ResidueField.map (LocallyRingedSpace.stalkMap f x)
85+
86+
lemma residue_comp_residueFieldMap_eq_stalkMap_comp_residue (x : X) :
87+
LocalRing.residue _ ≫ residueFieldMap f x = stalkMap f x ≫ LocalRing.residue _ := by
88+
simp [residueFieldMap]
89+
rfl
90+
91+
@[simp]
92+
lemma residueFieldMap_id (x : X) :
93+
residueFieldMap (𝟙 X) x = 𝟙 (X.residueField x) := by
94+
simp only [id_val', SheafedSpace.id_base, TopCat.coe_id, id_eq, residueFieldMap, stalkMap]
95+
have : PresheafedSpace.stalkMap (𝟙 X.toSheafedSpace) x = 𝟙 (X.stalk x) :=
96+
PresheafedSpace.stalkMap.id _ _
97+
simp_rw [this]
98+
apply LocalRing.ResidueField.map_id
99+
100+
@[simp]
101+
lemma residueFieldMap_comp {Z : LocallyRingedSpace.{u}} (g : Y ⟶ Z) (x : X) :
102+
residueFieldMap (f ≫ g) x = residueFieldMap g (f.val.base x) ≫ residueFieldMap f x := by
103+
simp only [comp_val, SheafedSpace.comp_base, Function.comp_apply, residueFieldMap, stalkMap]
104+
convert_to LocalRing.ResidueField.map
105+
(PresheafedSpace.stalkMap g.val (f.val.base x) ≫ PresheafedSpace.stalkMap f.val x) = _
106+
· congr
107+
apply PresheafedSpace.stalkMap.comp
108+
· apply LocalRing.ResidueField.map_comp
109+
110+
@[reassoc]
111+
lemma evaluation_naturality {V : Opens Y} (x : (Opens.map f.1.base).obj V) :
112+
Y.evaluation ⟨f.val.base x, x.property⟩ ≫ residueFieldMap f x.val =
113+
f.val.c.app (op V) ≫ X.evaluation x := by
114+
dsimp only [LocallyRingedSpace.evaluation,
115+
LocallyRingedSpace.residueFieldMap]
116+
rw [Category.assoc]
117+
ext a
118+
simp only [comp_apply]
119+
erw [LocalRing.ResidueField.map_residue, PresheafedSpace.stalkMap_germ'_apply]
120+
rfl
121+
122+
lemma evaluation_naturality_apply {V : Opens Y} (x : (Opens.map f.1.base).obj V)
123+
(a : Y.presheaf.obj (op V)) :
124+
residueFieldMap f x.val (Y.evaluation ⟨f.val.base x, x.property⟩ a) =
125+
X.evaluation x (f.val.c.app (op V) a) := by
126+
simpa using congrFun (congrArg DFunLike.coe <| evaluation_naturality f x) a
127+
128+
@[reassoc]
129+
lemma Γevaluation_naturality (x : X) :
130+
Y.Γevaluation (f.val.base x) ≫ residueFieldMap f x =
131+
f.val.c.app (op ⊤) ≫ X.Γevaluation x :=
132+
evaluation_naturality f ⟨x, by simp only [Opens.map_top]; trivial⟩
133+
134+
lemma Γevaluation_naturality_apply (x : X) (a : Y.presheaf.obj (op ⊤)) :
135+
residueFieldMap f x (Y.Γevaluation (f.val.base x) a) =
136+
X.Γevaluation x (f.val.c.app (op ⊤) a) :=
137+
evaluation_naturality_apply f ⟨x, by simp only [Opens.map_top]; trivial⟩ a

Mathlib/RingTheory/Ideal/LocalRing.lean

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -369,6 +369,20 @@ def residue : R →+* ResidueField R :=
369369
Ideal.Quotient.mk _
370370
#align local_ring.residue LocalRing.residue
371371

372+
variable {R}
373+
374+
lemma ker_residue : RingHom.ker (residue R) = maximalIdeal R :=
375+
Ideal.mk_ker
376+
377+
@[simp]
378+
lemma residue_eq_zero_iff (x : R) : residue R x = 0 ↔ x ∈ maximalIdeal R := by
379+
rw [← RingHom.mem_ker, ker_residue]
380+
381+
lemma residue_ne_zero_iff_isUnit (x : R) : residue R x ≠ 0 ↔ IsUnit x := by
382+
simp
383+
384+
variable (R)
385+
372386
instance ResidueField.algebra : Algebra R (ResidueField R) :=
373387
Ideal.Quotient.algebra _
374388
#align local_ring.residue_field.algebra LocalRing.ResidueField.algebra

0 commit comments

Comments
 (0)