Stafford38/Characteristic/ArtinianCoefficientField.lean

This project (Stafford38) · 1029fdb382eee06e7b59bcf32801f40931e2079a

1 module
2 public import Mathlib.RingTheory.AlgebraicIndependent.Adjoin
3 public import Mathlib.RingTheory.AlgebraicIndependent.TranscendenceBasis
4 public import Mathlib.RingTheory.Artinian.Ring
5 public import Mathlib.RingTheory.Etale.Field
6 
7 @[expose] public section
8 
9 /-!
10 # Coefficient fields in equal-characteristic-zero Artinian local rings
11 
12 The Artinian-local trace argument needs a genuine coefficient field: a
13 section of the residue map by a field homomorphism.  Mathlib does not package
14 the equal-characteristic coefficient-field theorem directly.  This file
15 proves the required characteristic-zero case from its formal-smoothness API.
16 
17 The field-theoretic input is that every characteristic-zero field extension
18 is formally smooth.  A transcendence basis factors the extension into a
19 rational-function extension and an algebraic separable extension.  The first
20 is formally smooth because polynomial algebras and localizations are; the
21 second is formally etale because characteristic-zero fields are perfect.
22 
23 For an Artinian local algebra, the maximal ideal is nilpotent.  Formal
24 smoothness of the residue field therefore lifts its identity map through the
25 residue quotient, producing the coefficient-field section.
26 -/
27 
28 noncomputable section
29 
30 namespace Stafford38.Characteristic.ArtinianCoefficientField
31 
32 open Algebra
33 open scoped IntermediateField
34 
35 universe u
36 
37 /-- Every extension of a characteristic-zero field is formally smooth.
38 
39 Mathlib's `Algebra.IsSeparable` describes algebraic separability, so the
40 transcendental part is first isolated with a transcendence basis. -/
41 theorem formallySmooth_fieldExtension_of_charZero
42     (F E : Type u) [Field F] [Field E] [Algebra F E] [CharZero F] :
43     Algebra.FormallySmooth F E := by
44   obtain ⟨ι, x, hx⟩ :=
45     exists_isTranscendenceBasis' F E
46   let K := IntermediateField.adjoin F (Set.range x)
47   let P := MvPolynomial ι F
48   let L := FractionRing P
49   haveI : Algebra.FormallySmooth F P := inferInstance
50   haveI : Algebra.FormallySmooth P L :=
51     Algebra.FormallySmooth.of_isLocalization (nonZeroDivisors P)
52   haveI : Algebra.FormallySmooth F L :=
53     Algebra.FormallySmooth.comp F P L
54   haveI : Algebra.FormallySmooth F K :=
55     Algebra.FormallySmooth.of_equiv hx.1.aevalEquivField
56   haveI : Algebra.IsAlgebraic K E := hx.isAlgebraic_field
57   haveI : CharZero K :=
58     charZero_of_injective_algebraMap (algebraMap F K).injective
59   haveI : PerfectField K := PerfectField.ofCharZero
60   haveI : Algebra.IsSeparable K E := inferInstance
61   haveI : Algebra.FormallyEtale K E :=
62     Algebra.FormallyEtale.of_isSeparable K E
63   exact Algebra.FormallySmooth.comp F K E
64 
65 section ArtinianLocal
66 
67 variable (F R : Type u) [Field F] [CharZero F]
68 variable [CommRing R] [Algebra F R] [IsLocalRing R] [IsArtinianRing R]
69 
70 local notation "𝔪" => IsLocalRing.maximalIdeal R
71 local notation "κ" => IsLocalRing.ResidueField R
72 
73 /-- The maximal ideal of a commutative Artinian local ring is nilpotent. -/
74 lemma maximalIdeal_isNilpotent : IsNilpotent 𝔪 := by
75   rw [← IsLocalRing.jacobson_eq_maximalIdeal (⊥ : Ideal R)]
76   · exact IsArtinianRing.isNilpotent_jacobson_bot
77   · exact bot_ne_top
78 
79 /-- An equal-characteristic-zero Artinian local algebra contains a coefficient
80 field: the residue map has a section as an algebra homomorphism over the base
81 field. -/
82 theorem exists_residue_algHom_section :
83     ∃ s : κ →ₐ[F] R,
84       (Ideal.Quotient.mkₐ F 𝔪).comp s = AlgHom.id F κ := by
85   letI : Algebra.FormallySmooth F κ :=
86     formallySmooth_fieldExtension_of_charZero F κ
87   exact Algebra.FormallySmooth.exists_lift 𝔪
88     (maximalIdeal_isNilpotent (R := R)) (AlgHom.id F κ)
89 
90 /-- Pointwise form of `exists_residue_algHom_section`. -/
91 theorem exists_residue_section :
92     ∃ s : κ →ₐ[F] R, ∀ a : κ, IsLocalRing.residue R (s a) = a := by
93   obtain ⟨s, hs⟩ := exists_residue_algHom_section F R
94   refine ⟨s, fun a ↦ ?_⟩
95   exact AlgHom.congr_fun hs a
96 
97 #print axioms formallySmooth_fieldExtension_of_charZero
98 #print axioms maximalIdeal_isNilpotent
99 #print axioms exists_residue_algHom_section
100 #print axioms exists_residue_section
101 
102 end ArtinianLocal
103 
104 end Stafford38.Characteristic.ArtinianCoefficientField
105