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
chore: retain the verified S-3 proofs and remove temporary compiler diagnostics
Browse filesChecks
build Program · lake build and Comparator
Details
challenge Program · challenge files and build config
Details
+3 −3 ConditionalGoldbach/Proofs/ResidualAverage.lean View file
| @@ -84,9 +84,9 @@ private lemma extract_indices (u : ℕ → ℝ) (hu : ∀ j, 0 ≤ u j) | ||
| 84 | 84 | apply sum_le_sum |
| 85 | 85 | intro j hj |
| 86 | 86 | by_cases hjG : j ∈ Gᶜ |
| 87 | - · simpa only [hit, if_pos hjG, one_mul] using | |
| 87 | + · simpa only [hit, ite_eq_left hjG, one_mul] using | |
| 88 | 88 | (le_of_not_ge (fun hju => hjG ⟨M, (mem_range.mp hj).le, hju⟩) : g M ≤ u j) |
| 89 | - · simpa only [hit, if_neg hjG, zero_mul] using hu j | |
| 89 | + · simpa only [hit, ite_eq_right hjG, zero_mul] using hu j | |
| 90 | 90 | have hprod : frequency Gᶜ M * g M ≤ prefixMean u M := by |
| 91 | 91 | unfold frequency prefixMean |
| 92 | 92 | rw [div_mul_eq_mul_div, sum_mul] |
| @@ -220,7 +220,7 @@ theorem prefixMean_iff_blockMean {u : ℕ → ℝ} (hu : ∀ j, 0 ≤ u j) : | ||
| 220 | 220 | · have hx' : (X : ℝ) ≠ 0 := Nat.cast_ne_zero.mpr hx |
| 221 | 221 | have hxx : (X : ℝ) + X ≠ 0 := by positivity |
| 222 | 222 | field_simp |
| 223 | - <;> ring | |
| 223 | + ring | |
| 224 | 224 | rw [he] |
| 225 | 225 | exact le_add_of_nonneg_left (prefixMean_nonneg hu X) |
| 226 | 226 | |
+2 −2 ConditionalGoldbach/Proofs/ResidualWindow.lean View file
| @@ -36,9 +36,9 @@ lemma windowKernel_mem {a b : ℝ} {K : ℂ → ℂ → ℂ} | ||
| 36 | 36 | have hy' : (line y p.2).im = p.2 := by simp [line] |
| 37 | 37 | by_cases hp : |p.1| ≤ H ∧ |p.2| ≤ H |
| 38 | 38 | · rw [Set.indicator_of_mem (show p ∈ S from hp)] |
| 39 | - simp only [windowKernel, hx', hy', if_pos hp] | |
| 39 | + simp only [windowKernel, hx', hy', ite_eq_left hp] | |
| 40 | 40 | · rw [Set.indicator_of_notMem (show p ∉ S from hp)] |
| 41 | - simp only [windowKernel, hx', hy', if_neg hp] | |
| 41 | + simp only [windowKernel, hx', hy', ite_eq_right hp] | |
| 42 | 42 | |
| 43 | 43 | /-- Compress the masked boundary operator. The masked kernel only needs to be square integrable. -/ |
| 44 | 44 | def windowOperator {a b : ℝ} (hab : a < b) (K : ℂ → ℂ → ℂ) |
+2 −2 ConditionalGoldbach/Proofs/ResidualWindowAverage.lean View file
| @@ -54,14 +54,14 @@ private lemma ratio_difference (hF : FamilyGRH) : | ||
| 54 | 54 | refine ⟨Real.sqrt C, ?_⟩ |
| 55 | 55 | intro N he hl |
| 56 | 56 | obtain ⟨hN, hL, hab⟩ := large_parameters hl |
| 57 | - letI : NeZero N := ⟨by omega⟩ | |
| 57 | + haveI : NeZero N := ⟨by omega⟩ | |
| 58 | 58 | let T := residualOperator hab N |
| 59 | 59 | let W := windowResidualOperator N hl (hF N he hl) (Real.log N ^ 36) |
| 60 | 60 | have hb : ‖T - W‖ ≤ Real.sqrt C / Real.log N := by |
| 61 | 61 | apply (sq_le_sq₀ (norm_nonneg _) (by positivity)).mp |
| 62 | 62 | rw [div_pow, Real.sq_sqrt hC] |
| 63 | 63 | exact herr N inferInstance he hl (hF N he hl) |
| 64 | - simp only [residualRatio, windowRatio, dif_pos hl, dif_pos (And.intro hl he)] | |
| 64 | + simp only [residualRatio, windowRatio, dite_eq_left hl, dite_eq_left (And.intro hl he)] | |
| 65 | 65 | calc |
| 66 | 66 | |‖T‖ / singularSeries N - ‖W‖ / singularSeries N| = |
| 67 | 67 | |‖T‖ - ‖W‖| / singularSeries N := by rw [← sub_div, abs_div, abs_of_pos (singularSeries_pos N)] |
+0 −23 Open/S3CompileDiagnostics.lean deleted
| @@ -1,23 +0,0 @@ | ||
| 1 | -import ConditionalGoldbach.Remaining | |
| 2 | -import Lean.Elab.Command | |
| 3 | - | |
| 4 | -/-! Temporary remote compiler diagnostics for the S-3 route. -/ | |
| 5 | -open Lean Elab Command in | |
| 6 | -run_cmd do | |
| 7 | - let mut failures := #[] | |
| 8 | - for name in #["ResidualAverage", "ResidualKernelBound", "ResidualWindow", "ResidualWindowAverage"] do | |
| 9 | - let path := s!"ConditionalGoldbach/Proofs/{name}.lean" | |
| 10 | - let result ← IO.Process.output { cmd := "lake", args := #["env", "lean", path] } | |
| 11 | - if result.exitCode != 0 then | |
| 12 | - failures := failures.push ((result.stdout ++ result.stderr).replace "\n" " | ") | |
| 13 | - else | |
| 14 | - let warnings := (result.stdout ++ result.stderr).splitOn "\n" |>.filter (·.contains "warning:") | |
| 15 | - unless warnings.isEmpty do logInfo m!"{String.intercalate " | " warnings}" | |
| 16 | - unless failures.isEmpty do throwError "{String.intercalate "\n" failures.toList}" | |
| 17 | - let names := ["residual_clippedMean_iff", "windowResidual_error_log", | |
| 18 | - "residual_iff_window_clippedBlockMean", "residual_of_windowEnergy_blockMean"] | |
| 19 | - let source := "import ConditionalGoldbach.Proofs.ResidualWindowAverage\n" ++ | |
| 20 | - String.intercalate "\n" (names.map fun n => "#print axioms ConditionalGoldbach.ResidualAverage." ++ n) | |
| 21 | - let audit ← IO.Process.output { cmd := "lake", args := #["env", "lean", "--stdin"] } (some source) | |
| 22 | - if audit.exitCode != 0 then throwError "{audit.stdout}{audit.stderr}" | |
| 23 | - logInfo m!"S-3 modules compiled independently. {audit.stdout.replace "\n" " | "}" | |
+2 −2 routes/s3-average-n-shumo/README.md View file
| @@ -43,7 +43,7 @@ HS 能量趋零是充分条件。算子范数的截断平均给出等价条件 | ||
| 43 | 43 | $$ |
| 44 | 44 | O_b\!\left(Y^{-b/2}\log^2(N(2+|t|))\right). |
| 45 | 45 | $$ |
| 46 | -确实,$W(z)=\int_0^\infty w(v)v^{z-1}\,dv$ 延拓为 $-z^{-1}\int w'(v)v^z\,dv$,在零点留数为一,在固定竖条带内随虚部快速衰减。绝对收敛线上用 Mellin 反演,将含 $W(z)Y^z(-L'/L)(1/2+b+it+z,\chi)$ 的积分从 $\Re z=1$ 移至 $-b/2$。奇特征标非主,局部 GRH 保证所经条带无 $L$ 零点,唯一留数来自 $W$。固定距离 $b/2$ 的对数导数界与 $W$ 的快速衰减给出上式,并使水平边积分趋零。所有常数对 $\chi,N,t$ 一致。[对数导数界](../../ConditionalGoldbach/Proofs/CharacterGrowth.lean) · [项目的特征标定义](../../ConditionalGoldbach/Definitions/Characters.lean) | |
| 46 | +确实,$W(z)=\int_0^\infty w(v)v^{z-1}\,dv$ 延拓为 $-z^{-1}\int w'(v)v^z\,dv$,在零点留数为一,在固定竖条带内随虚部快速衰减。绝对收敛线上用 Mellin 反演,将含 $W(z)Y^z(-L'/L)(1/2+b+it+z,\chi)$ 的积分从 $\Re z=1$ 移至 $-b/2$。奇特征标非主,局部 GRH 保证所经条带无 $L$ 零点,唯一留数来自 $W$。固定距离 $b/2$ 的对数导数界与 $W$ 的快速衰减给出上式,并使水平边积分趋零。所有常数对 $\chi,N,t$ 一致。[对数导数界](../../ConditionalGoldbach/Proofs/CharacterGrowth.lean) · [对数导数的狄利克雷级数](../../ConditionalGoldbach/Proofs/CharacterSeries.lean) | |
| 47 | 47 | |
| 48 | 48 | 以 $1+b+it$ 除每个列函数。误差列的 $L^2(dt)$ 范数为 $O_b(Y^{-b/2}L^2)$,原列及短和列均为 $O_b(L^2)$,因为 $\int\log^4(2+|t|)/(1+t^2)\,dt<\infty$。逐列展开秩一算子之差,使用 $\|f\otimes g\|_{\rm HS}=\|f\|_2\|g\|_2$ 及归一化质量一,替换整个特征标 Gram 核的 HS 代价为 $O_b(Y^{-b/2}L^4)$。短和中 $m,n\le Y<N/2$,奇特征标正交恰留下 $m=n,\ (n,N)=1$。此时与完整对角的差是权 $1-w(n/Y)^2$ 的正算子,其迹至多 $C_b\sum_{n>Y/2}(\log n)^2 n^{-1-2b}\ll_b Y^{-2b}\log^2Y$。[短和正交](../../ConditionalGoldbach/Proofs/CharacterShortPolynomial.lean) · [对角展开](../../ConditionalGoldbach/Proofs/SpectralDiagonalOperator.lean) |
| 49 | 49 | |
| @@ -76,7 +76,7 @@ $$ | ||
| 76 | 76 | $$ |
| 77 | 77 | 这里截断平方 $x\mapsto\min(1,x^2)$ 在非负半轴上是 $2$-Lipschitz,且 $\min(1,(x+y)^2)\le2\min(1,x^2)+2\min(1,y^2)$。这使逐模数的 $O(L^{-1})$ 误差可以移过二倍区间平均。 |
| 78 | 78 | |
| 79 | -每个矩阵元使用整个 $P_N-D_N-K_N$。上述短和近似移到左边界时,$Y^{-a/2}\to e^{-1/2}$,不再给出衰减。项目引理 6.4 估计固定模数内的特征标平均,尚不能给出这两个矩阵范数的跨模数抵消。先前的外部笔记声称固定物理窗口上的平均结果,此处的谱高度和矩阵阶数都随 $N$ 增长。[固定模数引理](../../ConditionalGoldbach/Proofs/CharacterAverage.lean) · [外部笔记的固定窗口原文,704b7eb](https://github.com/h1n4k0/goldbach-spectral-research/blob/704b7eb728853a75f548a19124615d6cee7ef062/arithmetic.md#L67-L97) | |
| 79 | +每个矩阵元使用整个 $P_N-D_N-K_N$。在左边界,即便取 $Y=N/4$,移线给出的因子 $Y^{-a/2}$ 也只趋于 $e^{-1/2}$。若取 $Y=L^{64}$,它趋于一。项目引理 6.4 估计固定模数内的特征标平均,尚不能给出这两个矩阵范数的跨模数抵消。先前的外部笔记声称固定物理窗口上的平均结果,此处的谱高度和矩阵阶数都随 $N$ 增长。[固定模数引理](../../ConditionalGoldbach/Proofs/CharacterAverage.lean) · [外部笔记的固定窗口原文,704b7eb](https://github.com/h1n4k0/goldbach-spectral-research/blob/704b7eb728853a75f548a19124615d6cee7ef062/arithmetic.md#L67-L97) | |
| 80 | 80 | |
| 81 | 81 | ## 检验与复现 |
| 82 | 82 | |
