File size: 5,669 Bytes
b797a5b
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
import Mathlib.RingTheory.Spectrum.Prime.Topology
import OAI.NumberTheory.PiExponent.Ampleness.AffineFunctionFieldCompatibility
import OAI.NumberTheory.PiExponent.Geometry.CurveParameterFinite
import OAI.NumberTheory.PiExponent.LocalAlgebra.AffineTranscendenceDimension

namespace OAI

noncomputable section
namespace PiExponent.CurveGeometricFunctionField

open CategoryTheory AlgebraicGeometry

variable (k A E : Type*) [Field k] [CommRing A] [IsDomain A] [Field E]
  [Algebra k A] [Algebra k E] [Algebra A E] [IsScalarTower k A E]
  [IsFractionRing A E]

omit [IsDomain A] in
theorem fractionField_essFiniteType [Algebra.FiniteType k A] :
    Algebra.EssFiniteType k E := by
  let : Algebra.EssFiniteType A E :=
    Algebra.EssFiniteType.of_isLocalization E (nonZeroDivisors A)
  exact Algebra.EssFiniteType.comp k A E

theorem fractionField_trdeg_eq_one [Algebra.FiniteType k A]
    (hdim : ringKrullDim A = 1) : Algebra.trdeg k E = 1 := by
  let : FaithfulSMul A E :=
    (faithfulSMul_iff_algebraMap_injective A E).mpr (IsFractionRing.injective A E)
  have hd : (Algebra.trdeg k A).toNat = 1 := by
    rw [PiExponentJets.W24.finiteType_domain_krullDim_eq_trdeg k A] at hdim
    exact_mod_cast hdim
  have he := PiExponentJets.W24.localization_trdeg_toNat_eq k A E
    (nonZeroDivisors A)
  exact Cardinal.toNat_eq_one.mp (he.symm.trans hd)

def coordinates {ι : Type*} (φ : MvPolynomial ι k →ₐ[k] A) : ι → E :=
  fun i => algebraMap A E (φ (MvPolynomial.X i))

omit [IsDomain A] in
theorem adjoin_coordinates_eq_top {ι : Type*}
    (φ : MvPolynomial ι k →ₐ[k] A) (hφ : Function.Surjective φ) :
    IntermediateField.adjoin k (Set.range (coordinates k A E φ)) = ⊤ := by
  let x := coordinates k A E φ
  let K := IntermediateField.adjoin k (Set.range x)
  have hψ : (IsScalarTower.toAlgHom k A E).comp φ = MvPolynomial.aeval x := by
    apply MvPolynomial.algHom_ext
    intro i
    simp [x, coordinates]
  have hmem (a : A) : algebraMap A E a ∈ K := by
    obtain ⟨p, rfl⟩ := hφ a
    apply IntermediateField.algebra_adjoin_le_adjoin k (Set.range x)
    rw [← MvPolynomial.aeval_range]
    refine ⟨p, ?_⟩
    exact (congrArg (fun f : MvPolynomial ι k →ₐ[k] E => f p) hψ).symm
  apply top_le_iff.mp
  intro z _
  obtain ⟨a, b, _, rfl⟩ := IsFractionRing.div_surjective A z
  exact K.div_mem (hmem a) (hmem b)

theorem of_surjective_coordinates {ι : Type*} [Finite ι]
    (φ : MvPolynomial ι k →ₐ[k] A) (hφ : Function.Surjective φ)
    (hdim : ringKrullDim A = 1) :
    Algebra.EssFiniteType k E ∧ Algebra.trdeg k E = 1 ∧
      IntermediateField.adjoin k (Set.range (coordinates k A E φ)) = ⊤ := by
  let : Algebra.FiniteType k A := Algebra.FiniteType.of_surjective φ hφ
  exact ⟨fractionField_essFiniteType k A E,
    fractionField_trdeg_eq_one k A E hdim, adjoin_coordinates_eq_top k A E φ hφ⟩

theorem finite_over_every_parameter [Algebra.FiniteType k A]
    (hdim : ringKrullDim A = 1) :
    ∀ f : E, Transcendental k f →
      FiniteDimensional (IntermediateField.adjoin k {f}) E := by
  let := fractionField_essFiniteType k A E
  exact CurveParameterFinite.finite_over_every_parameter k E
    (fractionField_trdeg_eq_one k A E hdim)

omit [IsDomain A] in
theorem ringKrullDim_eq_one_of_affine_iso
    (X : Scheme) (e : X ≅ Spec (.of A)) (hdim : topologicalKrullDim X = 1) :
    ringKrullDim A = 1 := by
  have h := e.hom.homeomorph.isHomeomorph.topologicalKrullDim_eq
  change topologicalKrullDim X = topologicalKrullDim (PrimeSpectrum A) at h
  rw [PrimeSpectrum.topologicalKrullDim_eq_ringKrullDim] at h
  exact h.symm.trans hdim

theorem of_affine_curve {ι : Type*} [Finite ι]
    (X : Scheme) (e : X ≅ Spec (.of A)) (hdim : topologicalKrullDim X = 1)
    (φ : MvPolynomial ι k →ₐ[k] A) (hφ : Function.Surjective φ) :
    Algebra.EssFiniteType k E ∧ Algebra.trdeg k E = 1 ∧
      IntermediateField.adjoin k (Set.range (coordinates k A E φ)) = ⊤ :=
  of_surjective_coordinates k A E φ hφ
    (ringKrullDim_eq_one_of_affine_iso A X e hdim)

@[instance_reducible] def intrinsicSectionAlgebra (X : Scheme) [IsIntegral X] :
    Algebra Γ(X, ⊤) X.functionField := by
  letI : Nonempty (⊤ : X.Opens) := ⟨⟨genericPoint X, trivial⟩⟩
  exact (X.germToFunctionField ⊤).hom.toAlgebra

attribute [local instance] intrinsicSectionAlgebra

@[instance_reducible] def intrinsicFunctionFieldAlgebra (k : Type*) [Field k]
    (X : Scheme) [IsIntegral X] [Algebra k Γ(X, ⊤)] :
    Algebra k X.functionField :=
  ((algebraMap Γ(X, ⊤) X.functionField).comp (algebraMap k Γ(X, ⊤))).toAlgebra

theorem intrinsic_functionField (k : Type*) [Field k]
    (X : Scheme) [IsIntegral X] [IsAffine X] [Algebra k Γ(X, ⊤)]
    {ι : Type*} [Finite ι] (hdim : topologicalKrullDim X = 1)
    (φ : MvPolynomial ι k →ₐ[k] Γ(X, ⊤)) (hφ : Function.Surjective φ) :
    letI : Algebra k X.functionField := intrinsicFunctionFieldAlgebra k X
    Algebra.EssFiniteType k X.functionField ∧ Algebra.trdeg k X.functionField = 1 ∧
      IntermediateField.adjoin k
        (Set.range (coordinates k Γ(X, ⊤) X.functionField φ)) = ⊤ := by
  let : Algebra k X.functionField := intrinsicFunctionFieldAlgebra k X
  let : IsScalarTower k Γ(X, ⊤) X.functionField :=
    IsScalarTower.of_algebraMap_eq fun _ => rfl
  let : Nonempty (⊤ : X.Opens) := ⟨⟨genericPoint X, trivial⟩⟩
  let : IsFractionRing Γ(X, ⊤) X.functionField :=
    functionField_isFractionRing_of_isAffineOpen X (⊤ : X.Opens) (isAffineOpen_top X)
  exact of_affine_curve k Γ(X, ⊤) X.functionField X X.isoSpec hdim φ hφ

end PiExponent.CurveGeometricFunctionField

end

end OAI