goldbach-spectral-bridge
Li and Liu's GRH + S ⇒ Goldbach in Lean, checked against the paper by Comparator: clean it up together, and settle S
| 1 | module |
| 2 | |
| 3 | public import ConditionalGoldbach.Proofs.CharacterZeroLocalBounds |
| 4 | |
| 5 | /-! Summability of the zero measures obtained from the proved local counts. -/ |
| 6 | public section |
| 7 | |
| 8 | set_option autoImplicit false |
| 9 | noncomputable section |
| 10 | open scoped BigOperators ComplexConjugate Topology |
| 11 | open Set Complex Metric Filter |
| 12 | namespace ConditionalGoldbach |
| 13 | |
| 14 | lemma summable_int_one_add_abs_rpow (a : ℝ) (ha : 1 < a) : |
| 15 | Summable (fun k : ℤ => (1+|(k : ℝ)|)^(-a)) := by |
| 16 | have hn := (Real.summable_one_div_nat_add_rpow 1 a).mpr ha |
| 17 | have hn' : Summable (fun n : ℕ => (1+(n : ℝ))^(-a)) := by |
| 18 | apply hn.congr |
| 19 | intro n |
| 20 | rw [abs_of_nonneg (by positivity : (0 : ℝ) ≤ (n : ℝ)+1), |
| 21 | Real.rpow_neg (by positivity : (0 : ℝ) ≤ 1+(n : ℝ)), one_div, add_comm] |
| 22 | apply summable_int_iff_summable_nat_and_neg.mpr |
| 23 | constructor |
| 24 | · simpa using hn' |
| 25 | · simpa using hn' |
| 26 | |
| 27 | lemma summable_logarithmic_zero_majorant (d : ℕ) (hd : 1 ≤ d) : |
| 28 | Summable (fun k : ℤ => Real.log ((d : ℝ)*(|(k : ℝ)|+2)) / (1+|(k : ℝ)|)^2) := by |
| 29 | have hdR : (1 : ℝ) ≤ d := by exact_mod_cast hd |
| 30 | have hs := (summable_int_one_add_abs_rpow (3/2) (by norm_num)).mul_left (2*(2*(d : ℝ))^(1/2 : ℝ)) |
| 31 | apply hs.of_nonneg_of_le |
| 32 | · intro k |
| 33 | apply div_nonneg (Real.log_nonneg _) (sq_nonneg _) |
| 34 | nlinarith [abs_nonneg (k : ℝ)] |
| 35 | intro k |
| 36 | let x : ℝ := 1+|(k : ℝ)| |
| 37 | have hx : 0 < x := by dsimp [x]; positivity |
| 38 | have hlog : Real.log ((d : ℝ)*(|(k : ℝ)|+2)) ≤ 2*(2*(d : ℝ))^(1/2 : ℝ)*x^(1/2 : ℝ) := by |
| 39 | have hh := Real.log_le_rpow_div (by positivity : 0 ≤ (d : ℝ)*(|(k : ℝ)|+2)) (by norm_num : (0 : ℝ)<1/2) |
| 40 | have hb : (d : ℝ)*(|(k : ℝ)|+2) ≤ (2*(d : ℝ))*x := by dsimp [x]; nlinarith [abs_nonneg (k : ℝ)] |
| 41 | have hp := Real.rpow_le_rpow (by positivity : 0 ≤ (d : ℝ)*(|(k : ℝ)|+2)) hb (by norm_num : (0 : ℝ)≤1/2) |
| 42 | rw [Real.mul_rpow (by positivity) hx.le] at hp |
| 43 | linarith |
| 44 | change Real.log ((d : ℝ)*(|(k : ℝ)|+2))/x^2 ≤ 2*(2*(d : ℝ))^(1/2 : ℝ)*x^(-(3/2 : ℝ)) |
| 45 | apply (div_le_div_of_nonneg_right hlog (sq_nonneg x)).trans_eq |
| 46 | rw [mul_div_assoc, ← Real.rpow_two, ← Real.rpow_sub hx] |
| 47 | norm_num |
| 48 | |
| 49 | lemma zeroWindow_partition {d : ℕ} [NeZero d] (χ : Character d) (p : ZeroIndex χ) : |
| 50 | ∃! k : ℤ, p ∈ zeroWindow χ k := by |
| 51 | refine ⟨⌊p.val.1.im⌋, ⟨Int.floor_le _,Int.lt_floor_add_one _⟩,?_⟩ |
| 52 | intro k hk |
| 53 | exact (Int.floor_eq_iff.mpr hk).symm |
| 54 | |
| 55 | lemma primitive_zero_floor_square_summable {d : ℕ} [NeZero d] (χ : Character d) |
| 56 | (hχ : χ ≠ 1) (hprim : χ.IsPrimitive) : |
| 57 | Summable (fun p : ZeroIndex χ => (1+|((⌊p.val.1.im⌋ : ℤ) : ℝ)|)⁻¹^2) := by |
| 58 | classical |
| 59 | obtain ⟨C,hC,hcount⟩ := primitive_local_zero_count |
| 60 | have hc := hcount d inferInstance χ hχ hprim |
| 61 | let f : ZeroIndex χ → ℝ := fun p => (1+|((⌊p.val.1.im⌋ : ℤ) : ℝ)|)⁻¹^2 |
| 62 | have hf : 0 ≤ f := fun p => sq_nonneg _ |
| 63 | apply (summable_partition hf (zeroWindow_partition χ)).mpr |
| 64 | have hfinite (k : ℤ) : (zeroWindow χ k).Finite := (hc k).1 |
| 65 | have hsums (k : ℤ) : (∑' p : zeroWindow χ k, f p) = |
| 66 | ((zeroWindow χ k).ncard : ℝ)*(1+|(k : ℝ)|)⁻¹^2 := by |
| 67 | let := (hfinite k).fintype |
| 68 | have he (p : zeroWindow χ k) : f p = (1+|(k : ℝ)|)⁻¹^2 := by |
| 69 | dsimp [f] |
| 70 | rw [Int.floor_eq_iff.mpr p.property] |
| 71 | simp_rw [he] |
| 72 | rw [tsum_fintype, Finset.sum_const, Finset.card_univ, nsmul_eq_mul] |
| 73 | congr 2 |
| 74 | exact (Nat.card_eq_fintype_card).symm |
| 75 | refine ⟨fun k => by let := (hfinite k).fintype; exact (hasSum_fintype _).summable, ?_⟩ |
| 76 | simp_rw [hsums] |
| 77 | have hs := (summable_logarithmic_zero_majorant d (Nat.one_le_iff_ne_zero.mpr (NeZero.ne d))).mul_left C |
| 78 | apply hs.of_nonneg_of_le |
| 79 | · intro k; positivity |
| 80 | intro k |
| 81 | have hbound := mul_le_mul_of_nonneg_right (hc k).2 (sq_nonneg ((1+|(k : ℝ)|)⁻¹)) |
| 82 | convert hbound using 1; simp only [div_eq_mul_inv, inv_pow]; ring |
| 83 | |
| 84 | lemma primitive_zero_square_summable {d : ℕ} [NeZero d] (χ : Character d) |
| 85 | (hχ : χ ≠ 1) (hprim : χ.IsPrimitive) : |
| 86 | Summable (fun p : ZeroIndex χ => 1/(1+p.val.1.im^2)) := by |
| 87 | have hs := (primitive_zero_floor_square_summable χ hχ hprim).mul_left 9 |
| 88 | apply hs.of_nonneg_of_le |
| 89 | · intro p; positivity |
| 90 | intro p |
| 91 | let γ : ℝ := p.val.1.im |
| 92 | let k : ℝ := (⌊γ⌋ : ℤ) |
| 93 | have hk : |k| ≤ |γ|+1 := by |
| 94 | apply abs_le.mpr |
| 95 | have hkl := Int.floor_le γ |
| 96 | have hkg := Int.lt_floor_add_one γ |
| 97 | dsimp [k] |
| 98 | constructor <;> linarith [le_abs_self γ,neg_abs_le γ] |
| 99 | have hden : (1+|k|)^2 ≤ 9*(1+γ^2) := by |
| 100 | nlinarith [sq_abs γ,sq_nonneg (|γ|-1),sq_nonneg |k|,abs_nonneg k] |
| 101 | change 1/(1+γ^2) ≤ 9*((1+|k|)⁻¹)^2 |
| 102 | rw [inv_pow, ← div_eq_mul_inv] |
| 103 | exact (div_le_div_iff₀ (by positivity) (by positivity)).mpr (by nlinarith) |
| 104 | |
| 105 | lemma primitive_zero_poisson_summable {d : ℕ} [NeZero d] (χ : Character d) |
| 106 | (hχ : χ ≠ 1) (hprim : χ.IsPrimitive) (x t : ℝ) (hx : 0 < x) : |
| 107 | Summable (fun p : ZeroIndex χ => x/(x^2+(t-p.val.1.im)^2)) := by |
| 108 | let C : ℝ := (2*x^2+1+2*t^2)/x |
| 109 | have hC : 0 ≤ C := by dsimp [C]; positivity |
| 110 | have hCx : C*x = 2*x^2+1+2*t^2 := by dsimp [C]; field_simp |
| 111 | have hC2 : 2*x ≤ C := by apply (le_div_iff₀ hx).mpr; nlinarith [sq_nonneg t] |
| 112 | have hs := (primitive_zero_square_summable χ hχ hprim).mul_left C |
| 113 | apply hs.of_nonneg_of_le |
| 114 | · intro p; positivity |
| 115 | intro p |
| 116 | let γ : ℝ := p.val.1.im |
| 117 | change x/(x^2+(t-γ)^2) ≤ C*(1/(1+γ^2)) |
| 118 | rw [mul_one_div] |
| 119 | apply (div_le_div_iff₀ (by positivity) (by positivity)).mpr |
| 120 | have hγ : γ^2 ≤ 2*(t-γ)^2+2*t^2 := by nlinarith [sq_nonneg (γ-2*t)] |
| 121 | have hm := mul_le_mul_of_nonneg_left hγ hx.le |
| 122 | have hb := mul_nonneg (sub_nonneg.mpr hC2) (sq_nonneg (t-γ)) |
| 123 | nlinarith |
| 124 | |
| 125 | attribute [local instance] conductorNeZero in |
| 126 | theorem lemma_6_4_zero_poisson_convergence (N : ℕ) [NeZero N] (_hN : Even N) |
| 127 | (_hlarge : Real.exp 10 < (N : ℝ)) (_hGRH : GRH N) |
| 128 | (χ : Character N) (hχ : χ ∈ oddCharacters N) (x t : ℝ) (hx : 0 < x) : |
| 129 | Summable (fun p : ZeroIndex χ.primitiveCharacter => |
| 130 | x / (x ^ 2 + (t - p.val.1.im) ^ 2)) := by |
| 131 | exact primitive_zero_poisson_summable χ.primitiveCharacter |
| 132 | (primitiveCharacter_ne_one_of_ne_one χ (odd_character_ne_one χ (Finset.mem_filter.mp hχ).2)) |
| 133 | χ.primitiveCharacter_isPrimitive x t hx |
| 134 | |
| 135 | end ConditionalGoldbach |
