roseking's picture
Add lean source and binary files (part 96)
e9f356b verified
Raw History Blame Contribute Delete
2.81 kB
16
def omega : ℂ := Complex.exp (2 * (Real.pi : ℂ) * Complex.I / 3)
18
def eisensteinRing : Subalgebra ℤ ℂ := Algebra.adjoin ℤ {omega}
19
abbrev Eisenstein := eisensteinRing
21
def omegaE : Eisenstein :=
body · 1 line
  ⟨omega, Algebra.subset_adjoin (Set.mem_singleton omega)⟩
24
def norm (a : Eisenstein) : ℝ := Complex.normSq (a : ℂ)
26
def normNat (a : Eisenstein) : ℕ := ⌊norm a⌋₊
28
def primary (a : Eisenstein) : Prop := (3 : Eisenstein) ∣ a - 1
30
def primaryPrime (a : Eisenstein) : Prop := primary a ∧ Prime a
32
def modulus (a : Eisenstein) : Ideal Eisenstein := Ideal.span {a}
34
abbrev Residues (a : Eisenstein) := Eisenstein ⧸ modulus a
36
def residueRepresentative (a : Eisenstein) (v : Residues a) : Eisenstein :=
body · 1 line
  Classical.choose (Ideal.Quotient.mk_surjective v)
39
def cubicSymbolAtPrime (p v : Eisenstein) : ℂ :=
body · 7 lines
  if IsUnit (Ideal.Quotient.mk (modulus p) v) then
    if h : ∃ j : Fin 3,
        Ideal.Quotient.mk (modulus p) (v ^ ((normNat p - 1) / 3)) =
          Ideal.Quotient.mk (modulus p) (omegaE ^ (j : ℕ)) then
      omega ^ ((Classical.choose h : Fin 3) : ℕ)
    else 0
  else 0
48
def additivePhase (p v : Eisenstein) : ℂ :=
body · 2 lines
  let z : ℂ := (v : ℂ) / (p : ℂ)
  Complex.exp (2 * (Real.pi : ℂ) * Complex.I * (z + star z))
52
def gaussAtPrime (p : Eisenstein) : ℂ :=
body · 4 lines
  (Real.sqrt (norm p) : ℂ)⁻¹ *
    ∑' v : Residues p,
      cubicSymbolAtPrime p (residueRepresentative p v) *
        additivePhase p (residueRepresentative p v)
58
def cStar : ℝ := (2 * Real.pi) ^ (2 / 3 : ℝ) / (3 * Real.Gamma (2 / 3))
60
def primeCutoffSum (f : Eisenstein → ℂ) (X : ℝ) : ℂ :=
body · 1 line
  ∑' p : Eisenstein, if primaryPrime p ∧ norm p ≤ X then f p else 0
63
def firstMomentScale (X : ℝ) : ℝ := X ^ (5 / 6 : ℝ) / Real.log X
65
def FirstMomentStatement : Prop :=
body · 4 lines
  Asymptotics.IsLittleO Filter.atTop
    (fun X : ℝ => primeCutoffSum gaussAtPrime X -
      (((6 / 5 : ℝ) * cStar * firstMomentScale X : ℝ) : ℂ))
    firstMomentScale
71
def theta (ℓ : ℤ) (a : Eisenstein) : ℂ := ((a : ℂ) / (‖(a : ℂ)‖ : ℂ)) ^ ℓ
73
def AngularComparisonStatement : Prop :=
body · 4 lines
  ∀ ℓ : ℤ, Asymptotics.IsLittleO Filter.atTop
    (primeCutoffSum (fun p => theta ℓ p *
       (gaussAtPrime p - ((cStar * norm p ^ (-1 / 6 : ℝ) : ℝ) : ℂ))))
    firstMomentScale
79
def AngularCancellationStatement : Prop :=
body · 2 lines
  ∀ ℓ : ℤ, ℓ ≠ 0 → Asymptotics.IsLittleO Filter.atTop
    (primeCutoffSum (fun p => theta ℓ p * gaussAtPrime p)) firstMomentScale