| 1 | module |
| 2 | |
| 3 | public import E424.DirichletError.Basic |
| 4 | public import E424.RoughElements.L12 |
| 5 | public import E424.Tools.T5 |
| 6 | public import E424.HighBand.L31Aux4 |
| 7 | |
| 8 | @[expose] public section |
| 9 | |
| 10 | /-! |
| 11 | # Section 8 of the outline: L31 |
| 12 | -/ |
| 13 | |
| 14 | set_option linter.style.header false |
| 15 | open Finset MeasureTheory |
| 16 | |
| 17 | namespace E424 |
| 18 | |
| 19 | /-- **Lemma 31** (`𝒰` is sparse). Proof: for each nonempty cell `v` (at most `V` of them), the points of |
| 20 | `𝒰_v ∩ [-N, N]` that are `1`-separated number at most `N^{0.006}/(2V)` (`cell_sep`: `P_v^ℓ` is a Dirichlet |
| 21 | polynomial on `[N, N z^200]`, T5 over dyadic-16 blocks); two parity classes give separation. -/ |
| 22 | theorem L31 : ∃ N0 : ℝ, ∀ lo ≥ N0, ∀ (cS : ℝ) (ρ : ℕ) (S : Finset ℕ), BlockFam cS (K2 lo) ρ S → |
| 23 | ∀ N : ℝ, lo ≤ N → N ≤ lo ^ (1.01 : ℝ) → ∃ 𝒦 : Finset ℤ, |
| 24 | (𝒦.card : ℝ) ≤ N ^ (0.006 : ℝ) ∧ ∀ t ∈ Ubad lo S, |t| ≤ N → ⌊t⌋ ∈ 𝒦 := by |
| 25 | classical |
| 26 | obtain ⟨L0, hcs⟩ := cell_sep |
| 27 | refine ⟨Real.exp (max L0 3), fun lo hlo cS ρ S hSB N hloN hNlo => ?_⟩ |
| 28 | have hlo' : Real.exp L0 ≤ lo := |
| 29 | le_trans (Real.exp_le_exp.2 (le_max_left _ _)) hlo |
| 30 | have hlo0 : 0 < lo := lt_of_lt_of_le (Real.exp_pos _) hlo |
| 31 | have hL3 : 3 ≤ Real.log lo := |
| 32 | le_trans (le_max_right _ _) ((Real.le_log_iff_exp_le hlo0).2 hlo) |
| 33 | set L := Real.log lo with hLdef |
| 34 | set LL := Real.log L with hLLdef |
| 35 | have hL0 : 0 < L := by linarith |
| 36 | have hLL0 : 0 ≤ LL := Real.log_nonneg (by linarith) |
| 37 | have hN0 : 0 < N := by linarith |
| 38 | set Vb : ℝ := 200 * L ^ 100 * (200000 * LL) + 1 with hVb |
| 39 | have hVb0 : 0 < Vb := by positivity |
| 40 | set δ : ℝ := (L ^ 200)⁻¹ with hδ |
| 41 | have hδ0 : 0 < δ := by positivity |
| 42 | set V : Finset ℕ := S.image (fun s => ⌊xi lo * Real.log (s : ℕ)⌋₊) with hV |
| 43 | set 𝒦 : Finset ℤ := (Icc (-⌈N⌉) ⌈N⌉).filter |
| 44 | (fun k => ∃ t ∈ Ubad lo S, |t| ≤ N ∧ ⌊t⌋ = k) with h𝒦 |
| 45 | refine ⟨𝒦, ?_, fun t ht hN => ?_⟩ |
| 46 | swap |
| 47 | · refine mem_filter.2 ⟨mem_Icc.2 ⟨?_, ?_⟩, t, ht, hN, rfl⟩ |
| 48 | · have h1 : -N ≤ t := (abs_le.1 hN).1 |
| 49 | have := Int.floor_mono h1 |
| 50 | rwa [Int.floor_neg] at this |
| 51 | · have h1 : t ≤ N := (abs_le.1 hN).2 |
| 52 | exact (Int.floor_mono h1).trans (Int.floor_le_ceil N) |
| 53 | -- cardinality |
| 54 | have hV_card : (V.card : ℝ) ≤ Vb := by |
| 55 | have hz : K2 lo = L ^ 200000 := by simp [K2, C2, hLdef] |
| 56 | have hlogz : Real.log (K2 lo ^ 200) = 200 * (200000 * LL) := by |
| 57 | rw [Real.log_pow, hz, Real.log_pow]; push_cast; ring |
| 58 | have hsub : V ⊆ range (⌊200 * L ^ 100 * (200000 * LL)⌋₊ + 1) := by |
| 59 | intro v hv |
| 60 | obtain ⟨s, hs, rfl⟩ := mem_image.1 hv |
| 61 | rw [mem_range, Nat.lt_succ_iff] |
| 62 | apply Nat.le_floor |
| 63 | have hfam := hSB.fam s hs |
| 64 | have hs1 : (1 : ℝ) < s := by |
| 65 | have := hfam.1 |
| 66 | have h3 : (3 : ℝ) ≤ K2 lo := by |
| 67 | rw [hz] |
| 68 | calc (3 : ℝ) ≤ L := hL3 |
| 69 | _ = L ^ 1 := (pow_one L).symm |
| 70 | _ ≤ L ^ 200000 := pow_le_pow_right₀ (by linarith) (by norm_num) |
| 71 | linarith |
| 72 | have hlogs : Real.log (s : ℝ) ≤ Real.log (K2 lo ^ 200) := |
| 73 | Real.log_le_log (by linarith) hfam.2.1 |
| 74 | have hxi : xi lo = L ^ 100 := rfl |
| 75 | have hxi0 : 0 ≤ xi lo := by rw [hxi]; positivity |
| 76 | calc ((⌊xi lo * Real.log (s : ℕ)⌋₊ : ℕ) : ℝ) ≤ xi lo * Real.log (s : ℕ) := |
| 77 | Nat.floor_le (mul_nonneg hxi0 (Real.log_nonneg hs1.le)) |
| 78 | _ ≤ xi lo * (200 * (200000 * LL)) := by |
| 79 | apply mul_le_mul_of_nonneg_left _ hxi0; rw [← hlogz]; exact hlogs |
| 80 | _ = _ := by rw [hxi]; ring |
| 81 | calc (V.card : ℝ) ≤ ((range (⌊200 * L ^ 100 * (200000 * LL)⌋₊ + 1)).card : ℝ) := by |
| 82 | exact_mod_cast card_le_card hsub |
| 83 | _ = (⌊200 * L ^ 100 * (200000 * LL)⌋₊ : ℝ) + 1 := by rw [card_range]; push_cast; ring |
| 84 | _ ≤ Vb := by |
| 85 | have := Nat.floor_le (show (0 : ℝ) ≤ 200 * L ^ 100 * (200000 * LL) by positivity) |
| 86 | rw [hVb]; linarith |
| 87 | have hnonV : ∀ v ∉ V, ∀ t, Pv lo S v t = 0 := by |
| 88 | intro v hv t |
| 89 | unfold Pv |
| 90 | refine sum_eq_zero fun s hs => ?_ |
| 91 | obtain ⟨hsS, hsv⟩ := mem_filter.1 hs |
| 92 | exact absurd (mem_image.2 ⟨s, hsS, hsv⟩) hv |
| 93 | let 𝒦v : ℕ → Finset ℤ := fun v => 𝒦.filter fun k => ∃ t : ℝ, δ < ‖Pv lo S v t‖ ∧ |t| ≤ N ∧ ⌊t⌋ = k |
| 94 | have hcover : 𝒦 ⊆ V.biUnion 𝒦v := by |
| 95 | intro k hk |
| 96 | obtain ⟨hkI, t, htU, htN, htk⟩ := mem_filter.1 hk |
| 97 | obtain ⟨v, hv⟩ := htU |
| 98 | have hvV : v ∈ V := by |
| 99 | by_contra hvn |
| 100 | rw [hnonV v hvn t, norm_zero] at hv |
| 101 | linarith |
| 102 | exact mem_biUnion.2 ⟨v, hvV, mem_filter.2 ⟨hk, t, hv, htN, htk⟩⟩ |
| 103 | have hper : ∀ v ∈ V, ((𝒦v v).card : ℝ) ≤ 2 * (Real.exp (0.006 * Real.log N) / (2 * Vb)) := by |
| 104 | intro v hv |
| 105 | obtain ⟨s0, hs0, rfl⟩ := mem_image.1 hv |
| 106 | refine card_le_of_separated {t | δ < ‖Pv lo S ⌊xi lo * Real.log (s0 : ℕ)⌋₊ t‖} N _ ?_ _ ?_ |
| 107 | · intro τ hτ hsep |
| 108 | exact hcs lo hlo' cS ρ S hSB N hloN hNlo s0 hs0 τ (fun t ht => (hτ t ht).2) hsep |
| 109 | (fun t ht => (hτ t ht).1) |
| 110 | · intro k hk |
| 111 | obtain ⟨-, t, hδt, htN, htk⟩ := mem_filter.1 hk |
| 112 | exact ⟨t, hδt, htN, htk⟩ |
| 113 | calc (𝒦.card : ℝ) ≤ ((V.biUnion 𝒦v).card : ℝ) := by exact_mod_cast card_le_card hcover |
| 114 | _ ≤ ∑ v ∈ V, ((𝒦v v).card : ℝ) := by exact_mod_cast card_biUnion_le |
| 115 | _ ≤ ∑ _v ∈ V, 2 * (Real.exp (0.006 * Real.log N) / (2 * Vb)) := sum_le_sum hper |
| 116 | _ = (V.card : ℝ) * (2 * (Real.exp (0.006 * Real.log N) / (2 * Vb))) := by simp |
| 117 | _ ≤ Vb * (2 * (Real.exp (0.006 * Real.log N) / (2 * Vb))) := |
| 118 | mul_le_mul_of_nonneg_right hV_card (by positivity) |
| 119 | _ = Real.exp (0.006 * Real.log N) := by field_simp |
| 120 | _ = N ^ (0.006 : ℝ) := by rw [Real.rpow_def_of_pos hN0, mul_comm] |
| 121 | |
| 122 | end E424 |
| 123 | |