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.CharacterShortPolynomial |
| 4 | public import ConditionalGoldbach.Proofs.SpectralDiagonalBound |
| 5 | |
| 6 | /-! The short smoothed polynomial has uniformly controlled odd-character mean square. -/ |
| 7 | public section |
| 8 | |
| 9 | set_option autoImplicit false |
| 10 | noncomputable section |
| 11 | open MeasureTheory Filter Set Complex |
| 12 | open scoped Topology ComplexConjugate BigOperators |
| 13 | namespace ConditionalGoldbach |
| 14 | |
| 15 | lemma smoothed_coefficient_norm_sq (X σ t : ℝ) (n : ℕ) (hn : 0 < n) : |
| 16 | ‖(mangoldt n : ℂ) * (n : ℂ) ^ (-(1 / 2 + line σ t)) * smoothedPerronWeight X n‖ ^ 2 = |
| 17 | (mangoldt n) ^ 2 * (n : ℝ) ^ (-1 - 2 * σ) * smoothedPerronWeight X n ^ 2 := by |
| 18 | rw [norm_mul, norm_mul, mul_pow, mul_pow, Complex.norm_natCast_cpow_of_pos hn] |
| 19 | simp only [Complex.norm_real, Real.norm_eq_abs] |
| 20 | have hp : ((n : ℝ) ^ (-(1 / 2 + line σ t)).re) ^ 2 = (n : ℝ) ^ (-1 - 2 * σ) := by |
| 21 | rw [← Real.rpow_natCast, ← Real.rpow_mul (Nat.cast_nonneg n)] |
| 22 | congr 1 |
| 23 | simp [line] |
| 24 | ring |
| 25 | rw [hp] |
| 26 | simp only [sq_abs] |
| 27 | |
| 28 | lemma smoothed_polynomial_average_bound (N : ℕ) [NeZero N] (hN : Even N) (hN4 : 4 ≤ N) |
| 29 | (σ t : ℝ) (hσ : 0 < σ) : |
| 30 | (2 / (N.totient : ℝ)) * ∑ χ ∈ oddCharacters N, |
| 31 | ‖smoothedDirichletPolynomial χ ((N : ℝ) / 2) (1 / 2 + line σ t)‖ ^ 2 ≤ |
| 32 | (1 + σ) * (Real.log 4 + 4) / σ ^ 2 := by |
| 33 | rw [smoothed_polynomial_odd_parseval N hN hN4] |
| 34 | let k : ℕ := ⌊(N : ℝ) / 2⌋₊ |
| 35 | have hNreal : (4 : ℝ) ≤ N := by exact_mod_cast hN4 |
| 36 | have ht (n : ℕ) : (if Nat.Coprime n N then |
| 37 | ‖(mangoldt n : ℂ) * (n : ℂ) ^ (-(1 / 2 + line σ t)) * smoothedPerronWeight ((N : ℝ) / 2) n‖ ^ 2 else 0) ≤ |
| 38 | if 0 < n then diagonalCoefficient N (n - 1) * (n : ℝ) ^ (-2 * σ) else 0 := by |
| 39 | by_cases hn : 0 < n |
| 40 | · rw [ite_eq_left hn] |
| 41 | have he : n - 1 + 1 = n := by omega |
| 42 | by_cases hc : Nat.Coprime n N |
| 43 | · rw [ite_eq_left hc, smoothed_coefficient_norm_sq _ _ _ n hn] |
| 44 | have hw := smoothedPerronWeight_nonneg_le_one (by linarith : 1 < (N : ℝ) / 2) n |
| 45 | have hsq : smoothedPerronWeight ((N : ℝ) / 2) n ^ 2 ≤ 1 := by nlinarith [hw.1, hw.2] |
| 46 | calc |
| 47 | _ ≤ mangoldt n ^ 2 * (n : ℝ) ^ (-1 - 2 * σ) := by |
| 48 | simpa only [mul_one] using mul_le_mul_of_nonneg_left hsq |
| 49 | (mul_nonneg (sq_nonneg _) (Real.rpow_nonneg (Nat.cast_nonneg n) _)) |
| 50 | _ = _ := by |
| 51 | rw [show diagonalCoefficient N (n - 1) = mangoldt n ^ 2 / (n : ℝ) by |
| 52 | simp [diagonalCoefficient, he, hc]] |
| 53 | rw [show -1 - 2 * σ = -2 * σ - 1 by ring, |
| 54 | Real.rpow_sub (by exact_mod_cast hn : (0 : ℝ) < n), Real.rpow_one] |
| 55 | ring |
| 56 | · simp [hc, diagonalCoefficient, he] |
| 57 | · have he : n = 0 := by omega |
| 58 | subst n |
| 59 | simp [mangoldt] |
| 60 | calc |
| 61 | _ ≤ ∑ n ∈ Finset.range (k + 1), if 0 < n then diagonalCoefficient N (n - 1) * (n : ℝ) ^ (-2 * σ) else 0 := |
| 62 | Finset.sum_le_sum (fun n _ => ht n) |
| 63 | _ = ∑ j ∈ Finset.range k, diagonalCoefficient N j * (j + 1 : ℕ) ^ (-2 * σ) := by |
| 64 | rw [Finset.sum_range_succ'] |
| 65 | simp |
| 66 | _ ≤ ∑' j, diagonalCoefficient N j * (j + 1 : ℕ) ^ (-2 * σ) := |
| 67 | (diagonalCoefficient_power_summable N σ hσ).sum_le_tsum _ |
| 68 | (fun j _ => mul_nonneg (diagonalCoefficient_nonneg N j) (Real.rpow_nonneg (by positivity) _)) |
| 69 | _ ≤ _ := diagonalCoefficient_series_bound N σ hσ |
| 70 | |
| 71 | end ConditionalGoldbach |
