Current task: —

← Session 36 — ii′-6-DL dog-leg + side bounds; Paper A review

#2262 assistant 2026-08-26 16:33:24.728 UTC · 1508→12812 tok open ⤢
thinking (33239 chars)
This gives me the exact working patterns: - `abs_re_le_norm` used unqualified ✓ - per-term norm: `rw [norm_div]`, then `‖(zeroMult ρ.1 : ℂ)‖ = (zeroMult ρ.1 : ℝ)` via `rw [show (zeroMult ρ.1 : ℂ) = ((zeroMult ρ.1 : ℝ) : ℂ) by push_cast; ring, Complex.norm_real]` + `abs_of_nonneg (Nat.cast_nonneg _)` ✓ - `div_le_div_of_nonneg_left` pattern available. Now I have all patterns. Note `Complex.norm_real` — good banked trick for the nat-cast norm. Also let me double-check `VIntegral` and `HIntegral` definitions from Zeta23 to make sure about the point form `↑x + ↑t * I`. From rectangleIntegral_Jlag_eq and VIntegral_norm usage it seems right. Let me quickly grep the Zeta23 defs. Also need `Jlag_differentiableAt`-style differentiability or just continuity along path for integrability — I have the plan. Also for step 3 middle I need `intervalIntegral.integral_const` and smul_eq_mul. Also need `Real.sqrt` cast facts: `(10:ℝ) ≤ Real.sqrt n` — via Real.le_sqrt (hx : 0 ≤ x) (hy : 0 ≤ y) : x ≤ √y ↔ x^2 ≤ y. With x = 10, y = n: 10 ≤ √n ↔ 100 ≤ n ✓ from hn : 100000 ≤ n (as naturals; cast: (100000:ℝ) ≤ (n:ℝ) via exact_mod_cast). Let me now also confirm the exact form of the tight capstone hypothesis names: (hσlo: -5/2 ≤ s.re) (hσhi : s.re ≤ 3) (him : s.im = t) (hζ: riemannZeta s ≠ 0). ✓ from the grep earlier. One more check — `intervalIntegral.integral_comp_neg`: section Comp has `variable {a b c d : ℝ} (f : ℝ → E)` — so f is EXPLICIT, a b implicit. `intervalIntegral.integral_comp_neg g : ∫ x in ?a..?b, g (-x) = ∫ x in -?b..-?a, g x`. ✓ And `integral_congr {a b : ℝ} (h : EqOn f g [[a, b]])` — section Basic variable `{a b : ℝ} {f g : ℝ → E} {μ : Measure ℝ}`. So `intervalIntegral.integral_congr (h : Set.EqOn f g (Set.uIcc a b))`. The `[[a, b]]` notation = uIcc. EqOn f g uIcc: `fun t _ => hge t` where hge : ∀ t, g t = g (-t) — wait need EqOn g (fun t => g (-t)) [[-T, -10]], i.e. ∀ t ∈ [[-T,-10]], g t = (fun u => g (-u)) t, i.e. g t = g (-t) ✓. Now write the code. Plan the theorem structure: ```lean /-! ## 2. 6-c-ii: I_III — the left vertical σ = −5/2 -/ /-- Z₂(t) ≥ 0 for t ≥ 1. -/ theorem Z2hat_nonneg {t : ℝ} (ht : 1 ≤ t) : 0 ≤ Z2hat t := by have ht2 : (0 : ℝ) < t + 2 := by linarith have hlog1 : (1 : ℝ) ≤ Real.log (t + 2) := by rw [Real.le_log_iff_exp_le ht2] have he := Real.exp_one_lt_d9.le linarith have hlog2 : (0 : ℝ) ≤ Real.log (Real.log (t + 2)) := Real.log_nonneg hlog1 unfold Z2hat linarith [hlog1.le, hlog2] ``` Wait hlog1 : 1 ≤ log(t+2) gives 0 ≤ log(t+2) via le_trans. unfold Z2hat : goal 0 ≤ 0.6 * Real.log (t+2) + 0.886 * Real.log (Real.log (t+2)) + 2.7. linarith [hlog1, hlog2]: 0.6*(≥1) + 0.886*(≥0) + 2.7 ≥ 0 ✓ linarith. Hmm — but will `unfold Z2hat` work? Z2hat is a def; in Z2hat_mono they used `unfold Z2hat` ✓. Main theorem: ```lean /-- **6-c-ii (I_III, the left vertical σ = −5/2)**: the full-side bound — kernel ≤ 2 (`kFun_norm_le_two`), |t| ≥ 10 by the tight R-bound capstone + the two-unit near count, |t| ≤ 10 by the perimeter `MZeroProp`; the two tails are equal by the even symmetry. -/ theorem vIntegral_Jlag_left_norm_le (hZC : ZeroCountProp) (hZC2 : ZeroCountProp2) (hNLZ : NoLowZeros) (hMZ : MZeroProp) {n : ℕ} (hn : 100000 ≤ n) {T : ℝ} (hTn : Real.sqrt n ≤ T) (hTn1 : T ≤ Real.sqrt n + 1) : ‖VIntegral (Jlag n) (-5 / 2) (-T) T‖ ≤ 4 * T * ((2 / 3) * Z2hat T + 10.5 * Real.log (T + 2) + 48) + 40 * 1.3352 := by classical -- T ≥ 10 from n ≥ 10⁵ have hnR : (100000 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn have h10T : (10 : ℝ) ≤ T := by have h1 : (10 : ℝ) ≤ Real.sqrt (n : ℝ) := by rw [Real.le_sqrt (by norm_num) (by positivity)] norm_num1 linarith [hnR] -- 10^2 = 100 ≤ n linarith have hT0 : (0 : ℝ) ≤ T := by linarith have hTT : -T ≤ T := by linarith -- the integrand and its continuity ... ``` Wait `Real.le_sqrt (hx : 0 ≤ x) (hy : 0 ≤ y) : x ≤ √y ↔ x ^ 2 ≤ y`. So `rw [Real.le_sqrt (by norm_num) (by positivity)]` at goal `10 ≤ √(n:ℝ)` — turns goal into `10^2 ≤ (n:ℝ)`. Then `norm_num1`? 10^2 → 100 — hmm rw leaves `(10:ℝ)^2 ≤ ↑n`; `norm_num1` won't fully close; use `nlinarith [hnR]`? 10^2 = 100 needs computing. `by norm_num; exact_mod_cast hn`... Let me: ```lean have h1 : (10 : ℝ) ≤ Real.sqrt (n : ℝ) := by rw [Real.le_sqrt (by norm_num) (by positivity)] calc (10:ℝ)^2 = 100 := by norm_num _ ≤ (n : ℝ) := by linarith [hnR] ``` Hmm — after rw the goal is `(10:ℝ)^2 ≤ ↑n`. `calc (10:ℝ)^2 = 100 := by norm_num` then `100 ≤ ↑n` — 100 ≤ 100000 ≤ n ✓ linarith [hnR]. Fine. Or `nlinarith [hnR]` — nlinarith computes 10^2 = 100? nlinarith normalizes numerals ✓ probably. Use the calc for safety. Note `Real.sqrt n` in hTn — n : ℕ, so `Real.sqrt ↑n` with the ℕ→ℝ cast. `Real.sqrt (n : ℝ)` — same. In the theorem hTn : Real.sqrt ↑n ≤ T where ↑ is Nat.cast. In my have h1 I wrote `Real.sqrt (n : ℝ)` — the elaborator will see `(n : ℝ)` = `((n : ℝ))` = Nat.cast n ✓ same as hTn's. Positivity for hy : 0 ≤ (n:ℝ): `by positivity` ✓ (Nat.cast_nonneg). Continuity of the integrand: ```lean -- continuity of Jlag on the left vertical line have hJcont : ∀ t : ℝ, ContinuousAt (Jlag n) (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I) := by intro t have hs1 : (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I) ≠ 1 := by intro h have hre := congrArg Complex.re h simp at hre norm_num at hre have hA := (kFun_differentiableAt hs1).continuousAt have hB := continuousAt_logDeriv_zeta hs1 (zeta_ne_zero_left_vertical t) show ContinuousAt (fun s => kFun n s * (-logDeriv riemannZeta s)) _ exact hA.mul hB.neg ``` Wait — simp at hre: hre : Complex.re (↑(-5/2) + ↑t * I) = Complex.re 1. simp simplifies LHS: `Complex.add_re`, `Complex.ofReal_re`, `Complex.mul_re`, `Complex.I_re`, `Complex.I_im` — these are simp lemmas; gives `-5/2 = 1`? simp might directly close hre to False via norm_num inside? simp doesn't evaluate `-5/2 = 1` to False by itself (numerals need norm_num). So `norm_num at hre` ✓. Hmm — but wait, in zeta_ne_zero_left_vertical (line 103) they used `by simp` for the re equation with the same expression ✓ so simp handles `(...).re = -5/2`. For hre after congrArg: LHS simp reduces to -5/2, RHS Complex.re 1 = 1 via Complex.one_re. So hre : (-5/2 : ℝ) = 1, norm_num at hre derives False and closes the goal ✓ (norm_num at h with h : False-equivalent closes any goal). For the `show` — goal: ContinuousAt (Jlag n) s. `show ContinuousAt (fun s => kFun n s * (-logDeriv riemannZeta s)) s` — defeq? Jlag n s = kFun n s * (-(deriv ζ s / ζ s)); my lambda body: kFun n s * (-logDeriv ζ s) = kFun n s * (-(deriv ζ s / ζ s)) after unfolding logDeriv (def). `show` uses defeq — should work ✓. ```lean have hpath : Continuous fun u : ℝ => (((-5 / 2 : ℝ) : ℂ) + (u : ℝ) * Complex.I) := by fun_prop have hcontJ : Continuous fun t : ℝ => Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I) := by rw [continuous_iff_continuousAt] intro t exact (hJcont t).comp hpath.continuousAt have hcontG : Continuous fun t : ℝ => ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ := hcontJ.norm' have hI : ∀ a b : ℝ, IntervalIntegrable (fun t : ℝ => ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖) MeasureTheory.volume a b := fun a b => hcontG.intervalIntegrable a b ``` fun_prop for hpath: `Continuous fun u : ℝ => (↑(-5/2) + ↑u * Complex.I)` — components: ofReal coe of u (continuous_ofReal), mul I, add const. fun_prop should handle ✓. The integrand abbreviation: to reduce repetition I could use `set g := fun t : ℝ => ‖Jlag n (((-5/2 : ℝ)) + t * I)‖ with hg`. Then hcontG : Continuous g := by rw [hg]; exact hcontJ.norm'. Hmm, set introduces g := ... and rewrites occurrences in goal — but the goal is the final VIntegral statement which doesn't contain g. The occurrences I create in have's I'd write as g directly. `set` requires the goal/hyps to contain the term — it still works even with 0 occurrences? `set x := e` works regardless. Then g t : needs `show`/`simp only [hg]` at application sites... Honestly, avoiding `set` and spelling the integrand out is verbose but robust. The pointwise bounds (tail/middle) I'll state with the applied form `‖Jlag n (↑(-5/2) + ↑t * I)‖ ≤ ...` and rely on beta-defeq when feeding integral_mono_on. Beta-defeq concern in integral_mono_on: hfg : ∀ x ∈ Icc a b, f x ≤ g x where f := fun t => ‖Jlag n (...)‖. The lambda I pass: `fun t ht => htailbound t ht` — type: ∀ t ∈ Icc 10 T, ‖Jlag n (↑(-5/2)+↑t*I)‖ ≤ K. Expected: ∀ t ∈ Icc 10 T, (fun t => ‖Jlag n _‖) t ≤ (fun _ => K) t. Defeq by beta ✓ `exact` accepts. Now the pointwise bounds. Middle: ```lean have hcast : ((-5 / 2 : ℂ)) = (((-5 / 2 : ℝ)) : ℂ) := by push_cast; ring have hmid : ∀ t : ℝ, t ∈ Set.Icc (-10 : ℝ) 10 → ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ ≤ 2 * 1.3352 := by intro t ht obtain ⟨ht1, ht2⟩ := ht have habs : |t| ≤ 10 := abs_le.mpr ⟨ht1, ht2⟩ have hMZt : ‖logDeriv riemannZeta ((((-5 / 2 : ℝ)) : ℂ) + (t : ℝ) * Complex.I)‖ ≤ 1.3352 := by have h := hMZ t habs rwa [hcast] at h have hk : ‖kFun n (((-5 / 2 : ℝ)) : ℂ) + (t : ℝ) * Complex.I)‖ ≤ 2 := by apply kFun_norm_le_two simp -- goal: (...).re ≤ 1/2 — simp reduces re to -5/2; then needs -5/2 ≤ 1/2? rw [Jlag_norm_eq] exact mul_le_mul hk hMZt (norm_nonneg _) (by norm_num) ``` Careful with kFun_norm_le_two's hypothesis: (hs : s.re ≤ 1/2). s = ↑(-5/2)+↑t*I, s.re = -5/2: `by simp` — does simp close `s.re ≤ 1/2`? simp simplifies s.re to -5/2, then the goal `-5/2 ≤ 1/2` — simp doesn't prove numeric inequalities; needs norm_num. So: `by have : (...).re = -5/2 := by simp; rw [this]; norm_num`. Or `by simp only [Complex.add_re, Complex.ofReal_re, Complex.mul_re, Complex.I_re, Complex.I_im]; norm_num`. I'll write a small have hre := ... by simp, then rw + norm_num. Wait — actually there's a subtlety with `abs_le.mpr ⟨ht1, ht2⟩`: abs_le : |a| ≤ b ↔ -b ≤ a ∧ a ≤ b ✓. ht : t ∈ Set.Icc (-10) 10 — obtain gives ht1 : -10 ≤ t, ht2 : t ≤ 10 ✓ (Set.mem_Icc is defeq And — obtain works). For hcast: `((-5/2 : ℂ)) = ↑(-5/2 : ℝ)`: push_cast on RHS: `↑(-5/2) = -(5/2)`?? push_cast normalizes: `↑(-5/2) = -5/2` hmm the RHS becomes `(-5 : ℂ)/(2 : ℂ)` and LHS `(-5/2 : ℂ)` is `Neg (HDiv 5 2)`? Lean 4 parses `-5/2` as `Neg.neg (HDiv.hDiv 5 2)`? I believe `-5/2` elaborates as `-(5/2)` where 5/2 is HDiv. And push_cast turns `↑(-(5/2))` into `-↑(5/2)` = `-(↑5/↑2)` = `-(5/2)`. Both sides `-(5/2)` ✓ ring closes (or rfl). But if hcast's sides are already equal after push_cast, ring closes ✓. But wait — MZeroProp's term: `(-5 \ 2 : ℂ)` — hmm the backslash is the division `/`. In the file it's written `(-5 \ 2: ℂ)`?? Look at the grep output: `‖logDeriv riemannZeta ((-5 \ 2: ℂ) + (t : ℝ) * Complex.I)‖` — the `\` is likely an artifact of grep output escaping? Actually no — the raw file might literally contain `-5 \ 2`... that would be a parse error in Lean. It must be `/` and the grep tool output shows `\` due to... hmm, weird. Actually I bet the file contains `/` and the display escaped it oddly. Let me not worry — I'll read the MZeroProp def directly to get the exact form. Also note: hMZ t habs gives the bound at the point `(-5/2 : ℂ) + ↑t * I` where (-5/2 : ℂ) is parsed in ℂ. rw [hcast] at h changes it to ↑(-5/2:ℝ) form ✓ matching my s. Now the tail bound: ```lean have htail : ∀ t : ℝ, t ∈ Set.Icc (10 : ℝ) T → ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ ≤ 2 * ((2 / 3) * Z2hat T + 10.5 * Real.log (T + 2) + 48) := by intro t ht obtain ⟨ht10, htT⟩ := ht set s := (((-5 / 2 : ℝ)) : ℂ) + (t : ℝ) * Complex.I with hs_def have hre : s.re = -5 / 2 := by simp [s] have him : s.im = t := by simp [s] have hk : ‖kFun n s‖ ≤ 2 := kFun_norm_le_two (by rw [hre]; norm_num) have hζ : riemannZeta s ≠ 0 := zeta_ne_zero_left_vertical t have hRtight := logDeriv_riemannZeta_sub_nearZeros_le_tight hZC hZC2 hNLZ ht10 (by rw [hre]; norm_num) (by rw [hre]; norm_num) him hζ rw [abs_of_nonneg (by linarith : (0:ℝ) ≤ t)] at hRtight have hlogT : Real.log (t + 2) ≤ Real.log (T + 2) := Real.log_le_log (by linarith) (by linarith) -- the near sum bound have hnear : ‖∑ ρ ∈ nearZerosSub t, (zeroMult ρ.1 : ℂ) / (s - ρ.1)‖ ≤ (2 / 5) * Z2hat t := by calc ‖∑ ρ ∈ nearZerosSub t, (zeroMult ρ.1 : ℂ) / (s - ρ.1)‖ ≤ ∑ ρ ∈ nearZerosSub t, ‖(zeroMult ρ.1 : ℂ) / (s - ρ.1)‖ := norm_sum_le _ _ _ ≤ ∑ ρ ∈ nearZerosSub t, (2 / 5) * (zeroMult ρ.1 : ℝ) := by apply Finset.sum_le_sum intro ρ hρ have hρre : (0 : ℝ) < ρ.1.re := ρ.2.2.1 have hrere : (s - ρ.1).re = -5 / 2 - ρ.1.re := by simp [hre, Complex.sub_re] -- hmm ... ``` Careful: (s - ρ.1).re = s.re - ρ.1.re. With hre : s.re = -5/2. `Complex.sub_re : (a - b).re = a.re - b.re` ✓ simp lemma. So `by simp [hre]` should give `(s - ρ.1).re = -5/2 - ρ.1.re`: simp [Complex.sub_re, hre] → s.re - ρ.1.re → -5/2 - ρ.1.re ✓. Actually just `by simp [Complex.sub_re, hre]`? The goal `(s - ρ.1).re = -5/2 - ρ.1.re`: simp rewrites LHS using Complex.sub_re to s.re - ρ.1.re, then hre : s.re = -5/2 rewrites to -5/2 - ρ.1.re ✓ closes. Then: ```lean have hnorm5 : (5 / 2 : ℝ) ≤ ‖s - ρ.1‖ := by have h1 := abs_re_le_norm (s - ρ.1) rw [hrere, abs_of_neg (by linarith)] at h1 linarith ``` h1 after rw : -(-5/2 - ρ.1.re) ≤ ‖s - ρ.1‖, i.e. 5/2 + ρ.1.re ≤ ‖·‖; with hρre : 0 < ρ.1.re: linarith gives 5/2 ≤ ‖·‖ ✓. ```lean have hnormpos : (0 : ℝ) < ‖s - ρ.1‖ := by linarith have h2 : ‖(zeroMult ρ.1 : ℂ)‖ = (zeroMult ρ.1 : ℝ) := by rw [show (zeroMult ρ.1 : ℂ) = ((zeroMult ρ.1 : ℝ) : ℂ) by push_cast; ring, Complex.norm_real] exact abs_of_nonneg (Nat.cast_nonneg _) rw [norm_div, h2, div_le_iff₀ hnormpos] nlinarith [hnorm5, Nat.cast_nonneg (α := ℝ) (zeroMult ρ.1)] ``` After rw [div_le_iff₀ hnormpos]: goal `↑(zeroMult ρ.1) ≤ (2/5) * ↑(zeroMult ρ.1) * ‖s - ρ.1‖`. nlinarith with hnorm5 (5/2 ≤ ‖s−ρ‖) and cast_nonneg: products: (‖s−ρ‖ − 5/2)*m ≥ 0 ⟹ m*‖s−ρ‖ ≥ (5/2)m ⟹ (2/5)m‖s−ρ‖ ≥ m. nlinarith should find (needs the product hnorm5*hm). ✓ Then the sum: ```lean _ = (2 / 5) * ∑ ρ ∈ nearZerosSub t, (zeroMult ρ.1 : ℝ) := by rw [Finset.mul_sum] _ ≤ (2 / 5) * Z2hat t := mul_le_mul_of_nonneg_left (nearZerosSub_mult_sum_le hZC2 ht10) (by norm_num) ``` Finset.mul_sum s f a : a * ∑ i ∈ s, f i = ∑ i ∈ s, a * f i — I have goal `∑ ρ ∈ S, (2/5)*m_ρ = (2/5) * ∑ ρ ∈ S, m_ρ` — that's (Finset.mul_sum S f (2/5)).symm. So `rw [← Finset.mul_sum]` — rewrites occurrences of `∑ i ∈ s, a * f i` to `a * ∑ i ∈ s, f i`. The LHS of my goal is `∑ ρ ∈ S, (2/5)*↑(zeroMult ρ.1)` ✓ matches with a := 2/5 ✓. So `rw [← Finset.mul_sum]` closes the goal to rfl ✓. Hmm — does `Finset.mul_sum` need explicit args? `lemma mul_sum (s : Finset ι) (f : ι → R) (a : R)` — all explicit. rw [← Finset.mul_sum] with metavars — rw will unify ✓ (the reversed rw: find pattern `∑ i ∈ ?s, ?a * ?f i` — hmm, higher-order pattern ?f applied to bound i — rw uses keyed matching; it should work since the sum body is literally `(2/5) * ↑(zeroMult ρ.1)` which matches `?a * ?f ρ` with ?f := fun ρ => ↑(zeroMult ρ.1) via pattern unification ✓). Continue: ```lean -- combine: ‖logDeriv‖ ≤ near + tight have hlog : ‖logDeriv riemannZeta s‖ ≤ (2 / 3) * Z2hat T + 10.5 * Real.log (T + 2) + 48 := by have h1 : ‖logDeriv riemannZeta s‖ ≤ ‖∑ ρ ∈ nearZerosSub t, (zeroMult ρ.1 : ℂ) / (s - ρ.1)‖ + ‖logDeriv riemannZeta s - ∑ ρ ∈ nearZerosSub t, (zeroMult ρ.1 : ℂ) / (s - ρ.1)‖ := norm_le_insert _ _ have hmono := Z2hat_mono (by linarith : (1 : ℝ) ≤ t) htT have hnn : (0 : ℝ) ≤ Z2hat T := Z2hat_nonneg (by linarith : (1 : ℝ) ≤ T) linarith [h1, hnear, hRtight, hlogT, hmono, hnn] rw [Jlag_norm_eq] exact mul_le_mul hk hlog (norm_nonneg _) (by norm_num) ``` linarith check: h1 : ‖logDeriv‖ ≤ ‖Σ‖ + ‖·−Σ‖; hnear : ‖Σ‖ ≤ (2/5)Z2hat t; hRtight : ‖·−Σ‖ ≤ 10.5*log(t+2)+48; hlogT : log(t+2) ≤ log(T+2); hmono : Z2hat t ≤ Z2hat T; hnn : 0 ≤ Z2hat T. Goal: ‖logDeriv‖ ≤ (2/3)Z2hat T + 10.5 log(T+2) + 48. Chain: ‖logDeriv‖ ≤ (2/5)Z2hat t + 10.5 log(t+2) + 48 ≤ (2/5)Z2hat T + 10.5 log(T+2) + 48 ≤ (2/3)Z2hat T + 10.5 log(T+2) + 48. All linear in atoms (Z2hat t, Z2hat T, log(t+2), log(T+2)) ✓ linarith. norm_le_insert (a b) : ‖a‖ ≤ ‖b‖ + ‖a − b‖ — with a := logDeriv ζ s, b := Σ ✓. mul_le_mul hk hlog (norm_nonneg _) (by norm_num : (0:ℝ) ≤ 2): gives ‖kFun‖*‖logDeriv‖ ≤ 2 * RHS ✓. And goal after rw [Jlag_norm_eq] is exactly that ✓. Wait — Jlag_norm_eq n s : ‖Jlag n s‖ = ‖kFun n s‖ * ‖logDeriv riemannZeta s‖. The goal is ‖Jlag n (↑(-5/2) + ↑t*I)‖ ≤ 2*(...). With `set s`, the goal shows ‖Jlag n s‖? Hmm — `set s := ... with hs_def` introduces s and rewrites occurrences of the term in the goal — the goal's `(((-5/2:ℝ):ℂ) + ↑t*I)` becomes s ✓ (set folds occurrences). Then rw [Jlag_norm_eq] — Jlag_norm_eq n s needs the argument to match — after set, goal is ‖Jlag n s‖ ≤ ... ✓ rw [Jlag_norm_eq n s]? If I write `rw [Jlag_norm_eq]` it'll unify ✓. Then the middle integral bound: ```lean have hmidInt : ∫ t in (-10 : ℝ)..(10 : ℝ), ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ ≤ 20 * (2 * 1.3352) := by have h := intervalIntegral.integral_mono_on (by norm_num : (-10:ℝ) ≤ 10) (hI _ _) intervalIntegrable_const (fun t ht => hmid t ht) rw [intervalIntegral.integral_const, smul_eq_mul] at h -- h : ∫ ≤ (10 - -10) * (2*1.3352) norm_num1 at h ⊢ -- (10 - -10) = 20 exact h ``` Hmm — (10 - (-10)) * (2*1.3352) vs my stated 20 * (2*1.3352): `norm_num1 at h` simplifies (10 - -10) to 20 ✓ then exact h. Actually smul_eq_mul turns (10 - -10) • c into (10 - -10) * c. Then norm_num1... hmm norm_num1 might mangle more. Alternative: `convert h using 2; norm_num`. Simpler: keep hmidInt statement as `≤ (10 - (-10)) * (2 * 1.3352)` and let the final linarith handle the arithmetic. Even simpler: state hmidInt with the exact RHS produced and let linarith close the assembly. Let me state: ```lean have hmidInt : ∫ t in (-10:ℝ)..(10:ℝ), g.. ≤ (10 - (-10)) * (2 * 1.3352) := ... ``` and in assembly linarith computes (10 - -10) * (2*1.3352) = 40*1.3352 ✓ linear arithmetic with numerals — linarith handles ✓. Similarly htailInt : ∫ t in 10..T, g.. ≤ (T - 10) * (2 * ((2/3)*Z2hat T + 10.5*log(T+2)+48)). ```lean have htailInt : ∫ t in (10 : ℝ)..T, ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ ≤ (T - 10) * (2 * ((2 / 3) * Z2hat T + 10.5 * Real.log (T + 2) + 48)) := by have h := intervalIntegral.integral_mono_on h10T (hI _ _) intervalIntegrable_const (fun t ht => htail t ht) rwa [intervalIntegral.integral_const, smul_eq_mul] at h ``` Careful: `intervalIntegrable_const` — signature `intervalIntegrable_const [IsLocallyFiniteMeasure μ] {c : E} : IntervalIntegrable (fun _ => c) μ a b` — c implicit, unified with the constant function in hg's slot. When passing as an argument to integral_mono_on whose hg expects IntervalIntegrable g μ a b with g := fun _ => K — unification `intervalIntegrable_const : IntervalIntegrable (fun _ => ?c) volume a b` ✓ instantiates ?c := K ✓. But WAIT: the μ in these lemmas — my integrals use volume (default in `∫ t in a..b, f t` notation is volume? The interval integral notation `∫ x in a..b, f x` defaults to ∂volume? In Mathlib, `∫ x in a..b, f x` without ∂μ uses `MeasureTheory.volume` by default ✓ (the notation has default volume). IsLocallyFiniteMeasure volume ✓ instance. The even piece: ```lean have hge : ∀ t : ℝ, ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ = ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (-t : ℝ) * Complex.I)‖ := fun t => (jlag_left_vertical_norm_even n t).symm have hleft : ∫ t in (-T)..(-10 : ℝ), ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ = ∫ t in (10 : ℝ)..T, ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ := by have h1 : ∫ t in (-T)..(-10 : ℝ), ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ = ∫ t in (-T)..(-10 : ℝ), ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (-t : ℝ) * Complex.I)‖ := intervalIntegral.integral_congr (fun t _ => hge t) rw [h1] have h2 := intervalIntegral.integral_comp_neg (fun t : ℝ => ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖) -- h2 : ∫ x in ?a..?b, f (-x) = ∫ x in -?b..-?a, f x rw [show (-T : ℝ) = ... ] hmm ``` Hmm — h2's LHS integrand: `f (-x)` where f = fun t => ‖Jlag n (↑(-5/2) + ↑t*I)‖. So `f (-x)` = ‖Jlag n (↑(-5/2) + ↑(-x)*I)‖ ✓ matches my transformed integrand. The rw [h2] would rewrite the goal's `∫ t in (-T)..(-10), f(-t)` to `∫ t in -(-10)..-(-T), f t` ✓. Then goal: `∫ t in -(-10)..-(-T), f t = ∫ t in 10..T, f t` — `simp only [neg_neg]` closes (-(-10) = 10, -(-T) = T) then rfl ✓. But the unification: `rw [h2]` where h2 has implicit ?a ?b metavars — rw needs to match `∫ x in ?a..?b, f (-x)` against goal subterm `∫ t in (-T)..(-10), (fun t => ‖Jlag n (↑(-5/2) + ↑(-t)*I)‖) t`... The goal after rw [h1] has integrand `fun t => ‖Jlag n (↑(-5/2)+↑(-t)*I)‖` or applied form `‖Jlag n (↑(-5/2)+↑(-t)*I)‖` under the binder. f(-x) with f the lambda: beta-redex `(fun t => ‖..t..‖) (-x)`. rw matching needs syntactic match up to defeq — integral_comp_neg's LHS is `∫ x in a..b, f (-x)`; with f instantiated to my lambda (I passed it explicitly, so no HO unification for f), the LHS term is `∫ x in ?a..?b, (fun t => ‖..t..‖) (-x)`. After beta this is `∫ x in ?a..?b, ‖..(-x)..‖`. Does rw beta-reduce when matching? rw matches up to reducible defeq? It should handle beta. Then ?a ?b from the endpoints -T, -10 ✓. Potential issue: the bound-variable name and the cast `↑(-t)`: in my h1-produced integrand the term is `↑(-t) * I`; in f(-x) instantiated: `↑(-x) * I` ✓ same up to alpha. Alternatively cleaner: prove hleft by direct calc: ```lean have hleft : ∫ t in (-T)..(-10:ℝ), F t = ∫ t in (10:ℝ)..T, F t := by have h1 : ∫ t in (-T)..(-10:ℝ), F t = ∫ t in (-T)..(-10:ℝ), F (-t) := intervalIntegral.integral_congr (fun t _ => hge t) have h2 : ∫ t in (-T)..(-10:ℝ), F (-t) = ∫ t in -(-10:ℝ)..-(-T), F t := intervalIntegral.integral_comp_neg F rw [h1, h2, neg_neg (10:ℝ), neg_neg T] -- hmm neg_neg needs the form -(-a) ``` neg_neg : -(-a) = a. rw [neg_neg] rewrites first occurrence... rw [neg_neg (10 : ℝ)]? The term is `-(-10)` = Neg.neg (Neg.neg 10) ✓ rw [neg_neg (10:ℝ)] → 10 ✓. But -( -T): Neg.neg (Neg.neg T) ✓ rw [neg_neg T]. But careful — `-(10:ℝ)`: is the literal `-10` displayed as Neg.neg 10 ✓. Hmm wait — the direction of h2: integral_comp_neg F : ∫ x in ?a..?b, F (-x) = ∫ x in -?b..-?a, F x. With ?a := -T, ?b := -10: RHS = ∫ x in -(-10)..-(-T), F x ✓. But h2 as stated with metavars — `intervalIntegral.integral_comp_neg F` leaves ?a ?b free; when I use it in `have h2 : ... := intervalIntegral.integral_comp_neg F`, the type ascription fixes ?a := -T, ?b := -10 ✓. For the LHS of h2's type ascription: ∫ t in (-T)..(-10), F (-t) — needs F(-t) to beta-match ✓ fine (defeq ascription). OK — but there's a subtlety: `intervalIntegral.integral_comp_neg F` — F is the lambda; the LHS `∫ x in ?a..?b, F (-x)` — the integrand is `(F · (-x))`?? Actually the lemma statement is `∫ x in a..b, f (-x)` which elaborates as `∫ x in a..b, f (Neg.neg x)` — with f the lambda, `f (Neg.neg x)` is a beta-redex. Lean stores it as such or beta-reduces during elaboration? The lemma was elaborated with f a section variable — so f (-x) stays `f (-x)` (not a redex since f was a variable at elaboration). When I instantiate f := my lambda, the term becomes `(myLambda) (-x)` — a redex, NOT beta-reduced automatically. My type ascription `∫ t in -T..-10, ‖Jlag n (↑(-5/2)+↑(-t)*I)‖` has the beta-reduced form. defeq check: ascription vs inferred — defeq handles beta ✓. Then `rw [h1, h2, ...]`: h2's LHS in redex form vs goal's reduced form — rw matches up to reducible + some defeq; beta usually OK. Alternatively use `calc` with exact: ```lean have hleft : ∫ t in (-T)..(-10:ℝ), F t = ∫ t in (10:ℝ)..T, F t := by calc ∫ t in (-T)..(-10:ℝ), F t = ∫ t in (-T)..(-10:ℝ), F (-t) := intervalIntegral.integral_congr (fun t _ => hge t) _ = ∫ t in -(-10:ℝ)..-(-T), F t := intervalIntegral.integral_comp_neg F _ = ∫ t in (10:ℝ)..T, F t := by rw [neg_neg, neg_neg] ``` The last step: goal ∫ t in -(-10)..-(-T), F t = ∫ t in 10..T, F t. rw [neg_neg] rewrites the FIRST -(-?) occurrence — neg_neg : -(-a) = a; first match: -(-10) → 10; second rw [neg_neg]: -(-T) → T; then rfl ✓. But rw [neg_neg] without args — could loop? No, after two applications no more -(-·). But careful: it might rewrite -(-T) first (term order) — either order, two rewrites then rfl ✓. Hmm, actually rw [neg_neg] rewrites ALL occurrences that match the first pattern found? No — rw rewrites all occurrences of the FIRST matched instance only. So first rw [neg_neg]: finds some -(-x), instantiates, rewrites all copies of that instance. Second: the other one. Fine. Wait — subtle: is `-(-10 : ℝ)` actually `Neg.neg (Neg.neg (10 : ℝ))`? The term `-(-10)` from integral_comp_neg RHS: `-?b` with ?b := -10 gives `Neg.neg (-10)` = `Neg.neg (Neg.neg 10)` ✓. Now the split & assembly: ```lean have hsplit : ∫ t in (-T)..T, F t = ∫ t in (-T)..(-10:ℝ), F t + (∫ t in (-10:ℝ)..(10:ℝ), F t + ∫ t in (10:ℝ)..T, F t) := by rw [← intervalIntegral.integral_add_adjacent_intervals (hI (-T) (-10)) (hI (-10) T)] rw [← intervalIntegral.integral_add_adjacent_intervals (hI (-10) 10) (hI 10 T)] ``` Hmm — direction: integral_add_adjacent_intervals hab hbc : (∫ a..b) + (∫ b..c) = ∫ a..c. ← direction: rewrites ∫ a..c into the sum. Goal LHS ∫ -T..T: rw [← integral_add_adjacent_intervals (hI (-T) (-10)) (hI (-10) T)] turns ∫(-T..T) into ∫(-T..-10) + ∫(-10..T) ✓. Then rw [← ... (hI (-10) 10) (hI 10 T)] turns ∫(-10..T) into ∫(-10..10) + ∫(10..T) ✓. Goal becomes `∫(-T..-10) + (∫(-10..10) + ∫(10..T)) = ∫(-T..-10) + (∫(-10..10) + ∫(10..T))` ✓ rfl closed by rw automatically. Wait — rw [← h] where h : A + B = C: rewrites C to A + B ✓. But there are two integrals matching the pattern... first rw targets ∫(-T..T) — the only occurrence of that exact term. But the rewrite pattern is the FULL RHS of the lemma instance: with the hI args given, the instance is `∫(-T..-10) + ∫(-10..T) = ∫(-T..T)` — fully determined (a=-T, b=-10, c=T) ✓ no ambiguity. Then final: ```lean calc ‖VIntegral (Jlag n) (-5 / 2) (-T) T‖ = ‖∫ t in (-T)..T, Jlag n (((-5 / 2 : ℝ)) + (t : ℝ) * Complex.I)‖ := VIntegral_norm _ ≤ ∫ t in (-T)..T, ‖Jlag n (((-5 / 2 : ℝ)) + (t : ℝ) * Complex.I)‖ := intervalIntegral.norm_integral_le_integral_norm hTT _ = ∫ t in (-T)..(-10:ℝ), F.. + (∫ t in (-10:ℝ)..(10:ℝ), F.. + ∫ t in (10:ℝ)..T, F..) := hsplit _ = (∫ t in (10:ℝ)..T, F..) + (∫ t in (-10:ℝ)..(10:ℝ), F..) + ∫ t in (10:ℝ)..T, F.. := by rw [hleft]; ring _ ≤ (T - 10) * K + (10 - -10) * (2 * 1.3352) + (T - 10) * K := by linarith [htailInt, hmidInt] _ ≤ 4 * T * ((2/3) * Z2hat T + 10.5 * Real.log (T + 2) + 48) + 40 * 1.3352 := by -- K ≥ 0 have hK0 : (0:ℝ) ≤ 2 * ((2/3) * Z2hat T + 10.5 * Real.log (T + 2) + 48) := by have hnn := Z2hat_nonneg (by linarith : (1:ℝ) ≤ T) have hlognn : 0 ≤ Real.log (T + 2) := Real.log_nonneg (by linarith) positivity -- or nlinarith nlinarith [hK0] ``` Hmm the last step: goal: (T-10)*K + 20*(2*1.3352) + (T-10)*K ≤ 4*T*(stuff) + 40*1.3352 where K = 2*(stuff). (T-10)*K ≤ T*K ⟺ -10K ≤ 0 ⟸ K ≥ 0. 2*(T-10)*K + 53.408 ≤ 2*T*K + 53.408. 2*T*K = 2*T*(2*stuff) = 4*T*stuff ✓. nlinarith with hK0: needs to expand (T-10)*K as T*K - 10*K — linearization handles numeral-multiplied products? nlinarith treats K and T*K as atoms; (T-10)*K = T*K - 10*K via distrib — nlinarith's ring_nf preprocessing handles ✓. linarith alone should also: 2*(T-10)*K + 40*1.3352 ≤ 4*T*stuff + 40*1.3352 ⟺ 2*(T-10)*K ≤ 4*T*stuff ⟺ 2*T*K - 20*K ≤ 2*T*K ⟺ -20*K ≤ 0. In atom terms: K atom, T*K atom. Goal (after ring normalization by linarith preprocessing): it distributes 2*(T-10)*K → 2*(T*K) - 20*K and 4*T*(stuff) where stuff = K/2... hmm — the RHS has `stuff` = (2/3)*Z2hat T + 10.5*log(T+2) + 48 as a DIFFERENT atom than K. linarith sees 4*T*stuff vs 2*T*K — different atoms! It won't know K = 2*stuff. PROBLEM. Fix: give linarith the relation hK : K = 2 * stuff explicitly as an equation, or better, don't introduce K at all — write htailInt with the fully expanded RHS (T - 10) * (2 * ((2/3)*Z2hat T + 10.5*log(T+2)+48)) and let linarith treat `Z2hat T`, `log (T+2)`, `T * Z2hat T`, `T * log(T+2)` as atoms. The goal RHS: 4*T*((2/3)*Z2hat T + 10.5*log(T+2)+48) + 40*1.3352. ring_nf normalization: LHS = 2*(T-10)*(2/3*Z + 10.5*L + 48) + 53.408... expand: 2*T*(2/3*Z) + ... linarith's preprocessing does ring_nf: atoms: T*Z, Z, T*L, L. LHS expands fine, RHS expands fine — all linear in these four atoms ✓ linarith closes given hK0-like facts: Z2hat T ≥ 0, log(T+2) ≥ 0, T ≥ 10. The needed inequality: -20*(2/3*Z+10.5*L+48) ≤ 0 — linear combo of Z, L, const ✓ linarith with hnn, hlognn. So: skip the K abbreviation; in the final step provide hnn : 0 ≤ Z2hat T and hlognn : 0 ≤ Real.log (T+2), then `linarith [htailInt, hmidInt, hnn, hlognn]` — wait but ttailInt's RHS (T-10)*(2*(...)) needs expansion to compare with 4*T*(...). linarith normalizes both sides via ring_nf — the products (T-10)*(...) expand into atom monomials T*Z etc ✓. And the goal inequality likewise. So one linarith with the nonneg haves should close: From hsplit-rw'd form: ∫(-T..-10) + (∫(-10..10) + ∫(10..T)) = [via hleft] ∫(10..T) + (∫(-10..10) + ∫(10..T)). ≤ (T-10)*K' + ((10-(-10))*(2*1.3352) + (T-10)*K') [htailInt, hmidInt] = 2*(T-10)*K' + 20*2.6704 ≤ 2*T*K' + 53.408 [K' ≥ 0] = 4*T*(stuff) + 40*1.3352 ✓ [2*K' = 4*stuff since K' := 2*stuff; 20*2.6704 = 53.408 = 40*1.3352 ✓] All linear after ring_nf ✓. So: ```lean _ ≤ 4 * T * ((2 / 3) * Z2hat T + 10.5 * Real.log (T + 2) + 48) + 40 * 1.3352 := by have hnn : (0:ℝ) ≤ Z2hat T := Z2hat_nonneg (by linarith) have hlognn : (0:ℝ) ≤ Real.log (T + 2) := Real.log_nonneg (by linarith) rw [hleft] linarith [htailInt, hmidInt, hnn, hlognn] ``` Hmm — but I need the calc step structure right. Let me restructure the final calc to: ```lean calc ‖VIntegral (Jlag n) (-5 / 2) (-T) T‖ = ‖∫ t in (-T)..T, Jlag n (((-5 / 2 : ℝ)) + (t : ℝ) * Complex.I)‖ := VIntegral_norm _ ≤ ∫ t in (-T)..T, ‖Jlag n (((-5 / 2 : ℝ)) + (t : ℝ) * Complex.I)‖ := intervalIntegral.norm_integral_le_integral_norm hTT _ = ∫ t in (-T)..(-10:ℝ), F + (∫ t in (-10:ℝ)..(10:ℝ), F + ∫ t in (10:ℝ)..T, F) := hsplit _ ≤ 4 * T * (...) + 40 * 1.3352 := by rw [hleft] have hnn ...; have hlognn ... linarith [htailInt, hmidInt, hnn, hlognn] ``` After rw [hleft]: goal ∫(10..T) + (∫(-10..10) + ∫(10..T)) ≤ RHS. linarith: substitute htailInt (∫(10..T) ≤ (T-10)*K') and hmidInt: atoms ∫(10..T), ∫(-10..10) ✓ linear in those atoms ✓, then the expansion ✓. linarith should close: goal = 2*∫(10..T) + ∫(-10..10) ≤ RHS'; with ∫(10..T) ≤ (T-10)*K', ∫(-10..10) ≤ 20*2.6704: 2*(T-10)*K' + 53.408 ≤ 4*T*stuff + 53.408 ⟺ 2*T*K' - 20*K' ≤ 2*T*K' ⟺ 0 ≤ 20*K' ⟸ Z, L ≥ 0 ✓. linarith handles ✓. One concern: `VIntegral_norm` — signature `{f : ℂ → ℂ} {x y₁ y₂ : ℝ} : ‖VIntegral f x y₁ y₂‖ = ‖∫ t in y₁..y₂, f ((x : ℝ) + (t : ℝ) * Complex.I)‖`. My VIntegral application: VIntegral (Jlag n) (-5/2) (-T) T — is -5/2 here ℝ? VIntegral f x y₁ y₂ with x : ℝ — in rectangleIntegral_Jlag_eq: VIntegral (Jlag n) (2 * Real.sqrt n) (-T) T — x = 2*√n : ℝ ✓. So x := (-5/2 : ℝ) ✓. The RHS point: `((x : ℝ) + (t : ℝ) * Complex.I)` — with x : ℝ the `(x : ℝ)` annotation is the identity (not a cast!) — hmm wait, in the theorem as written at line 173: `f ((x : ℝ) + (t : ℝ) * Complex.I)`. If x : ℝ, then (x : ℝ) is x, and `x + t * Complex.I` needs x coerced to ℂ. The elaborated term: `(↑x : ℂ) + (↑t : ℂ) * I`. My lambda `↑(-5/2) + ↑t * I` — same ✓. Hmm — one more check: VIntegral_norm's LHS `VIntegral f x y₁ y₂`. My goal's LHS: `VIntegral (Jlag n) (-5/2) (-T) T`. Match ✓. But wait — in the theorem statement I must write `VIntegral (Jlag n) (-5/2) (-T) T` with -5/2 elaborating as ℝ (since VIntegral expects ℝ for x). Fine. Also `intervalIntegral.norm_integral_le_integral_norm hTT : ‖∫ t in -T..T, Jlag n _‖ ≤ ∫ t in -T..T, ‖Jlag n _‖` ✓. Now — the `F` abbreviation: I'll avoid it and write the full integrand in hsplit/hleft. Verbose but fine. One more potential gotcha: in hmid, `rw [Jlag_norm_eq]` — the goal: ‖Jlag n (↑(-5/2)+↑t*I)‖ ≤ 2*1.3352. Jlag_norm_eq n s : ‖Jlag n s‖ = ‖kFun n s‖ * ‖logDeriv riemannZeta s‖. rw rewrites ‖Jlag n s‖ to the product ✓ then mul_le_mul. Also in hmid: hMZt's point form — after rwa [hcast] at h: h : ‖logDeriv riemannZeta (↑(-5/2) + ↑t*I)‖ ≤ 1.3352 ✓ matches. Wait — in hMZ's statement the point is `(-5 \ 2: ℂ) + (t : ℝ) * Complex.I`. I need to read MZeroProp's exact source to get the exact term. Let me read LiContour.lean lines 160-166.
All patterns confirmed. Let me check the exact source of `MZeroProp` (the grep showed an odd `\` character) and the `VIntegral` definition in Zeta23.
tool: Read
input
{
  "file_path": "D:\\Python\\Quantum\\research\\lean\\NguyenRH1\\NguyenRH1\\LiContour.lean",
  "offset": 155,
  "limit": 15
}
tool: Grep
input
{
  "pattern": "def VIntegral|def HIntegral|noncomputable def VIntegral|noncomputable def HIntegral",
  "path": "D:\\Python\\Quantum\\zeta-23-lean",
  "output_mode": "content",
  "-A": 4
}
raw content_json (database row)
[{"type":"thinking","thinking":"This gives me the exact working patterns:\n- `abs_re_le_norm` used unqualified ✓\n- per-term norm: `rw [norm_div]`, then `‖(zeroMult ρ.1 : ℂ)‖ = (zeroMult ρ.1 : ℝ)` via `rw [show (zeroMult ρ.1 : ℂ) = ((zeroMult ρ.1 : ℝ) : ℂ) by push_cast; ring, Complex.norm_real]` + `abs_of_nonneg (Nat.cast_nonneg _)` ✓\n- `div_le_div_of_nonneg_left` pattern available.\n\nNow I have all patterns. Note `Complex.norm_real` — good banked trick for the nat-cast norm.\n\nAlso let me double-check `VIntegral` and `HIntegral` definitions from Zeta23 to make sure about the point form `↑x + ↑t * I`. From rectangleIntegral_Jlag_eq and VIntegral_norm usage it seems right. Let me quickly grep the Zeta23 defs.\n\nAlso need `Jlag_differentiableAt`-style differentiability or just continuity along path for integrability — I have the plan.\n\nAlso for step 3 middle I need `intervalIntegral.integral_const` and smul_eq_mul.\n\nAlso need `Real.sqrt` cast facts: `(10:ℝ) ≤ Real.sqrt n` — via Real.le_sqrt (hx : 0 ≤ x) (hy : 0 ≤ y) : x ≤ √y ↔ x^2 ≤ y. With x = 10, y = n: 10 ≤ √n ↔ 100 ≤ n ✓ from hn : 100000 ≤ n (as naturals; cast: (100000:ℝ) ≤ (n:ℝ) via exact_mod_cast).\n\nLet me now also confirm the exact form of the tight capstone hypothesis names: (hσlo: -5/2 ≤ s.re) (hσhi : s.re ≤ 3) (him : s.im = t) (hζ: riemannZeta s ≠ 0). ✓ from the grep earlier.\n\nOne more check — `intervalIntegral.integral_comp_neg`: section Comp has `variable {a b c d : ℝ} (f : ℝ → E)` — so f is EXPLICIT, a b implicit. `intervalIntegral.integral_comp_neg g : ∫ x in ?a..?b, g (-x) = ∫ x in -?b..-?a, g x`. ✓\n\nAnd `integral_congr {a b : ℝ} (h : EqOn f g [[a, b]])` — section Basic variable `{a b : ℝ} {f g : ℝ → E} {μ : Measure ℝ}`. So `intervalIntegral.integral_congr (h : Set.EqOn f g (Set.uIcc a b))`. The `[[a, b]]` notation = uIcc. EqOn f g uIcc: `fun t _ => hge t` where hge : ∀ t, g t = g (-t) — wait need EqOn g (fun t => g (-t)) [[-T, -10]], i.e. ∀ t ∈ [[-T,-10]], g t = (fun u => g (-u)) t, i.e. g t = g (-t) ✓.\n\nNow write the code. Plan the theorem structure:\n\n```lean\n/-! ## 2. 6-c-ii: I_III — the left vertical σ = −5/2 -/\n\n/-- Z₂(t) ≥ 0 for t ≥ 1. -/\ntheorem Z2hat_nonneg {t : ℝ} (ht : 1 ≤ t) : 0 ≤ Z2hat t := by\n  have ht2 : (0 : ℝ) < t + 2 := by linarith\n  have hlog1 : (1 : ℝ) ≤ Real.log (t + 2) := by\n    rw [Real.le_log_iff_exp_le ht2]\n    have he := Real.exp_one_lt_d9.le\n    linarith\n  have hlog2 : (0 : ℝ) ≤ Real.log (Real.log (t + 2)) := Real.log_nonneg hlog1\n  unfold Z2hat\n  linarith [hlog1.le, hlog2]\n```\n\nWait hlog1 : 1 ≤ log(t+2) gives 0 ≤ log(t+2) via le_trans. unfold Z2hat : goal 0 ≤ 0.6 * Real.log (t+2) + 0.886 * Real.log (Real.log (t+2)) + 2.7. linarith [hlog1, hlog2]: 0.6*(≥1) + 0.886*(≥0) + 2.7 ≥ 0 ✓ linarith.\n\nHmm — but will `unfold Z2hat` work? Z2hat is a def; in Z2hat_mono they used `unfold Z2hat` ✓.\n\nMain theorem:\n\n```lean\n/-- **6-c-ii (I_III, the left vertical σ = −5/2)**: the full-side bound —\nkernel ≤ 2 (`kFun_norm_le_two`), |t| ≥ 10 by the tight R-bound capstone\n+ the two-unit near count, |t| ≤ 10 by the perimeter `MZeroProp`; the two\ntails are equal by the even symmetry. -/\ntheorem vIntegral_Jlag_left_norm_le (hZC : ZeroCountProp) (hZC2 : ZeroCountProp2)\n    (hNLZ : NoLowZeros) (hMZ : MZeroProp) {n : ℕ} (hn : 100000 ≤ n) {T : ℝ}\n    (hTn : Real.sqrt n ≤ T) (hTn1 : T ≤ Real.sqrt n + 1) :\n    ‖VIntegral (Jlag n) (-5 / 2) (-T) T‖ ≤\n      4 * T * ((2 / 3) * Z2hat T + 10.5 * Real.log (T + 2) + 48) + 40 * 1.3352 := by\n  classical\n  -- T ≥ 10 from n ≥ 10⁵\n  have hnR : (100000 : ℝ) ≤ (n : ℝ) := by exact_mod_cast hn\n  have h10T : (10 : ℝ) ≤ T := by\n    have h1 : (10 : ℝ) ≤ Real.sqrt (n : ℝ) := by\n      rw [Real.le_sqrt (by norm_num) (by positivity)]\n      norm_num1\n      linarith [hnR]  -- 10^2 = 100 ≤ n\n    linarith\n  have hT0 : (0 : ℝ) ≤ T := by linarith\n  have hTT : -T ≤ T := by linarith\n  -- the integrand and its continuity\n  ...\n```\n\nWait `Real.le_sqrt (hx : 0 ≤ x) (hy : 0 ≤ y) : x ≤ √y ↔ x ^ 2 ≤ y`. So `rw [Real.le_sqrt (by norm_num) (by positivity)]` at goal `10 ≤ √(n:ℝ)` — turns goal into `10^2 ≤ (n:ℝ)`. Then `norm_num1`? 10^2 → 100 — hmm rw leaves `(10:ℝ)^2 ≤ ↑n`; `norm_num1` won't fully close; use `nlinarith [hnR]`? 10^2 = 100 needs computing. `by norm_num; exact_mod_cast hn`... Let me: \n\n```lean\n    have h1 : (10 : ℝ) ≤ Real.sqrt (n : ℝ) := by\n      rw [Real.le_sqrt (by norm_num) (by positivity)]\n      calc (10:ℝ)^2 = 100 := by norm_num\n        _ ≤ (n : ℝ) := by linarith [hnR]\n```\n\nHmm — after rw the goal is `(10:ℝ)^2 ≤ ↑n`. `calc (10:ℝ)^2 = 100 := by norm_num` then `100 ≤ ↑n` — 100 ≤ 100000 ≤ n ✓ linarith [hnR]. Fine. Or `nlinarith [hnR]` — nlinarith computes 10^2 = 100? nlinarith normalizes numerals ✓ probably. Use the calc for safety.\n\nNote `Real.sqrt n` in hTn — n : ℕ, so `Real.sqrt ↑n` with the ℕ→ℝ cast. `Real.sqrt (n : ℝ)` — same. In the theorem hTn : Real.sqrt ↑n ≤ T where ↑ is Nat.cast. In my have h1 I wrote `Real.sqrt (n : ℝ)` — the elaborator will see `(n : ℝ)` = `((n : ℝ))` = Nat.cast n ✓ same as hTn's.\n\nPositivity for hy : 0 ≤ (n:ℝ): `by positivity` ✓ (Nat.cast_nonneg).\n\nContinuity of the integrand:\n\n```lean\n  -- continuity of Jlag on the left vertical line\n  have hJcont : ∀ t : ℝ, ContinuousAt (Jlag n)\n      (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I) := by\n    intro t\n    have hs1 : (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I) ≠ 1 := by\n      intro h\n      have hre := congrArg Complex.re h\n      simp at hre\n      norm_num at hre\n    have hA := (kFun_differentiableAt hs1).continuousAt\n    have hB := continuousAt_logDeriv_zeta hs1 (zeta_ne_zero_left_vertical t)\n    show ContinuousAt (fun s => kFun n s * (-logDeriv riemannZeta s)) _\n    exact hA.mul hB.neg\n```\n\nWait — simp at hre: hre : Complex.re (↑(-5/2) + ↑t * I) = Complex.re 1. simp simplifies LHS: `Complex.add_re`, `Complex.ofReal_re`, `Complex.mul_re`, `Complex.I_re`, `Complex.I_im` — these are simp lemmas; gives `-5/2 = 1`? simp might directly close hre to False via norm_num inside? simp doesn't evaluate `-5/2 = 1` to False by itself (numerals need norm_num). So `norm_num at hre` ✓.\n\nHmm — but wait, in zeta_ne_zero_left_vertical (line 103) they used `by simp` for the re equation with the same expression ✓ so simp handles `(...).re = -5/2`. For hre after congrArg: LHS simp reduces to -5/2, RHS Complex.re 1 = 1 via Complex.one_re. So hre : (-5/2 : ℝ) = 1, norm_num at hre derives False and closes the goal ✓ (norm_num at h with h : False-equivalent closes any goal).\n\nFor the `show` — goal: ContinuousAt (Jlag n) s. `show ContinuousAt (fun s => kFun n s * (-logDeriv riemannZeta s)) s` — defeq? Jlag n s = kFun n s * (-(deriv ζ s / ζ s)); my lambda body: kFun n s * (-logDeriv ζ s) = kFun n s * (-(deriv ζ s / ζ s)) after unfolding logDeriv (def). `show` uses defeq — should work ✓.\n\n```lean\n  have hpath : Continuous fun u : ℝ =>\n      (((-5 / 2 : ℝ) : ℂ) + (u : ℝ) * Complex.I) := by fun_prop\n  have hcontJ : Continuous fun t : ℝ =>\n      Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I) := by\n    rw [continuous_iff_continuousAt]\n    intro t\n    exact (hJcont t).comp hpath.continuousAt\n  have hcontG : Continuous fun t : ℝ =>\n      ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ := hcontJ.norm'\n  have hI : ∀ a b : ℝ, IntervalIntegrable\n      (fun t : ℝ => ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖)\n      MeasureTheory.volume a b := fun a b => hcontG.intervalIntegrable a b\n```\n\nfun_prop for hpath: `Continuous fun u : ℝ => (↑(-5/2) + ↑u * Complex.I)` — components: ofReal coe of u (continuous_ofReal), mul I, add const. fun_prop should handle ✓.\n\nThe integrand abbreviation: to reduce repetition I could use `set g := fun t : ℝ => ‖Jlag n (((-5/2 : ℝ)) + t * I)‖ with hg`. Then hcontG : Continuous g := by rw [hg]; exact hcontJ.norm'. Hmm, set introduces g := ... and rewrites occurrences in goal — but the goal is the final VIntegral statement which doesn't contain g. The occurrences I create in have's I'd write as g directly. `set` requires the goal/hyps to contain the term — it still works even with 0 occurrences? `set x := e` works regardless. Then g t : needs `show`/`simp only [hg]` at application sites... \n\nHonestly, avoiding `set` and spelling the integrand out is verbose but robust. The pointwise bounds (tail/middle) I'll state with the applied form `‖Jlag n (↑(-5/2) + ↑t * I)‖ ≤ ...` and rely on beta-defeq when feeding integral_mono_on.\n\nBeta-defeq concern in integral_mono_on: hfg : ∀ x ∈ Icc a b, f x ≤ g x where f := fun t => ‖Jlag n (...)‖. The lambda I pass: `fun t ht => htailbound t ht` — type: ∀ t ∈ Icc 10 T, ‖Jlag n (↑(-5/2)+↑t*I)‖ ≤ K. Expected: ∀ t ∈ Icc 10 T, (fun t => ‖Jlag n _‖) t ≤ (fun _ => K) t. Defeq by beta ✓ `exact` accepts.\n\nNow the pointwise bounds.\n\nMiddle:\n```lean\n  have hcast : ((-5 / 2 : ℂ)) = (((-5 / 2 : ℝ)) : ℂ) := by push_cast; ring\n  have hmid : ∀ t : ℝ, t ∈ Set.Icc (-10 : ℝ) 10 →\n      ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ ≤ 2 * 1.3352 := by\n    intro t ht\n    obtain ⟨ht1, ht2⟩ := ht\n    have habs : |t| ≤ 10 := abs_le.mpr ⟨ht1, ht2⟩\n    have hMZt : ‖logDeriv riemannZeta ((((-5 / 2 : ℝ)) : ℂ) + (t : ℝ) * Complex.I)‖ ≤ 1.3352 := by\n      have h := hMZ t habs\n      rwa [hcast] at h\n    have hk : ‖kFun n (((-5 / 2 : ℝ)) : ℂ) + (t : ℝ) * Complex.I)‖ ≤ 2 := by\n      apply kFun_norm_le_two\n      simp  -- goal: (...).re ≤ 1/2 — simp reduces re to -5/2; then needs -5/2 ≤ 1/2?\n    rw [Jlag_norm_eq]\n    exact mul_le_mul hk hMZt (norm_nonneg _) (by norm_num)\n```\n\nCareful with kFun_norm_le_two's hypothesis: (hs : s.re ≤ 1/2). s = ↑(-5/2)+↑t*I, s.re = -5/2: `by simp` — does simp close `s.re ≤ 1/2`? simp simplifies s.re to -5/2, then the goal `-5/2 ≤ 1/2` — simp doesn't prove numeric inequalities; needs norm_num. So: `by have : (...).re = -5/2 := by simp; rw [this]; norm_num`. Or `by simp only [Complex.add_re, Complex.ofReal_re, Complex.mul_re, Complex.I_re, Complex.I_im]; norm_num`. I'll write a small have hre := ... by simp, then rw + norm_num.\n\nWait — actually there's a subtlety with `abs_le.mpr ⟨ht1, ht2⟩`: abs_le : |a| ≤ b ↔ -b ≤ a ∧ a ≤ b ✓. ht : t ∈ Set.Icc (-10) 10 — obtain gives ht1 : -10 ≤ t, ht2 : t ≤ 10 ✓ (Set.mem_Icc is defeq And — obtain works).\n\nFor hcast: `((-5/2 : ℂ)) = ↑(-5/2 : ℝ)`: push_cast on RHS: `↑(-5/2) = -(5/2)`?? push_cast normalizes: `↑(-5/2) = -5/2` hmm the RHS becomes `(-5 : ℂ)/(2 : ℂ)` and LHS `(-5/2 : ℂ)` is `Neg (HDiv 5 2)`? Lean 4 parses `-5/2` as `Neg.neg (HDiv.hDiv 5 2)`? I believe `-5/2` elaborates as `-(5/2)` where 5/2 is HDiv. And push_cast turns `↑(-(5/2))` into `-↑(5/2)` = `-(↑5/↑2)` = `-(5/2)`. Both sides `-(5/2)` ✓ ring closes (or rfl). But if hcast's sides are already equal after push_cast, ring closes ✓.\n\nBut wait — MZeroProp's term: `(-5 \\ 2 : ℂ)` — hmm the backslash is the division `/`. In the file it's written `(-5 \\ 2: ℂ)`?? Look at the grep output: `‖logDeriv riemannZeta ((-5 \\ 2: ℂ) + (t : ℝ) * Complex.I)‖` — the `\\` is likely an artifact of grep output escaping? Actually no — the raw file might literally contain `-5 \\ 2`... that would be a parse error in Lean. It must be `/` and the grep tool output shows `\\` due to... hmm, weird. Actually I bet the file contains `/` and the display escaped it oddly. Let me not worry — I'll read the MZeroProp def directly to get the exact form.\n\nAlso note: hMZ t habs gives the bound at the point `(-5/2 : ℂ) + ↑t * I` where (-5/2 : ℂ) is parsed in ℂ. rw [hcast] at h changes it to ↑(-5/2:ℝ) form ✓ matching my s.\n\nNow the tail bound:\n\n```lean\n  have htail : ∀ t : ℝ, t ∈ Set.Icc (10 : ℝ) T →\n      ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ ≤\n        2 * ((2 / 3) * Z2hat T + 10.5 * Real.log (T + 2) + 48) := by\n    intro t ht\n    obtain ⟨ht10, htT⟩ := ht\n    set s := (((-5 / 2 : ℝ)) : ℂ) + (t : ℝ) * Complex.I with hs_def\n    have hre : s.re = -5 / 2 := by simp [s]\n    have him : s.im = t := by simp [s]\n    have hk : ‖kFun n s‖ ≤ 2 := kFun_norm_le_two (by rw [hre]; norm_num)\n    have hζ : riemannZeta s ≠ 0 := zeta_ne_zero_left_vertical t\n    have hRtight := logDeriv_riemannZeta_sub_nearZeros_le_tight hZC hZC2 hNLZ\n      ht10 (by rw [hre]; norm_num) (by rw [hre]; norm_num) him hζ\n    rw [abs_of_nonneg (by linarith : (0:ℝ) ≤ t)] at hRtight\n    have hlogT : Real.log (t + 2) ≤ Real.log (T + 2) :=\n      Real.log_le_log (by linarith) (by linarith)\n    -- the near sum bound\n    have hnear : ‖∑ ρ ∈ nearZerosSub t, (zeroMult ρ.1 : ℂ) / (s - ρ.1)‖ ≤\n        (2 / 5) * Z2hat t := by\n      calc ‖∑ ρ ∈ nearZerosSub t, (zeroMult ρ.1 : ℂ) / (s - ρ.1)‖\n          ≤ ∑ ρ ∈ nearZerosSub t, ‖(zeroMult ρ.1 : ℂ) / (s - ρ.1)‖ :=\n            norm_sum_le _ _\n        _ ≤ ∑ ρ ∈ nearZerosSub t, (2 / 5) * (zeroMult ρ.1 : ℝ) := by\n          apply Finset.sum_le_sum\n          intro ρ hρ\n          have hρre : (0 : ℝ) < ρ.1.re := ρ.2.2.1\n          have hrere : (s - ρ.1).re = -5 / 2 - ρ.1.re := by\n            simp [hre, Complex.sub_re]  -- hmm\n          ...\n```\n\nCareful: (s - ρ.1).re = s.re - ρ.1.re. With hre : s.re = -5/2. `Complex.sub_re : (a - b).re = a.re - b.re` ✓ simp lemma. So `by simp [hre]` should give `(s - ρ.1).re = -5/2 - ρ.1.re`: simp [Complex.sub_re, hre] → s.re - ρ.1.re → -5/2 - ρ.1.re ✓. Actually just `by simp [Complex.sub_re, hre]`? The goal `(s - ρ.1).re = -5/2 - ρ.1.re`: simp rewrites LHS using Complex.sub_re to s.re - ρ.1.re, then hre : s.re = -5/2 rewrites to -5/2 - ρ.1.re ✓ closes.\n\nThen:\n```lean\n          have hnorm5 : (5 / 2 : ℝ) ≤ ‖s - ρ.1‖ := by\n            have h1 := abs_re_le_norm (s - ρ.1)\n            rw [hrere, abs_of_neg (by linarith)] at h1\n            linarith\n```\nh1 after rw : -(-5/2 - ρ.1.re) ≤ ‖s - ρ.1‖, i.e. 5/2 + ρ.1.re ≤ ‖·‖; with hρre : 0 < ρ.1.re: linarith gives 5/2 ≤ ‖·‖ ✓.\n\n```lean\n          have hnormpos : (0 : ℝ) < ‖s - ρ.1‖ := by linarith\n          have h2 : ‖(zeroMult ρ.1 : ℂ)‖ = (zeroMult ρ.1 : ℝ) := by\n            rw [show (zeroMult ρ.1 : ℂ) = ((zeroMult ρ.1 : ℝ) : ℂ) by push_cast; ring,\n              Complex.norm_real]\n            exact abs_of_nonneg (Nat.cast_nonneg _)\n          rw [norm_div, h2, div_le_iff₀ hnormpos]\n          nlinarith [hnorm5, Nat.cast_nonneg (α := ℝ) (zeroMult ρ.1)]\n```\n\nAfter rw [div_le_iff₀ hnormpos]: goal `↑(zeroMult ρ.1) ≤ (2/5) * ↑(zeroMult ρ.1) * ‖s - ρ.1‖`. nlinarith with hnorm5 (5/2 ≤ ‖s−ρ‖) and cast_nonneg: products: (‖s−ρ‖ − 5/2)*m ≥ 0 ⟹ m*‖s−ρ‖ ≥ (5/2)m ⟹ (2/5)m‖s−ρ‖ ≥ m. nlinarith should find (needs the product hnorm5*hm). ✓\n\nThen the sum:\n```lean\n        _ = (2 / 5) * ∑ ρ ∈ nearZerosSub t, (zeroMult ρ.1 : ℝ) := by\n          rw [Finset.mul_sum]\n        _ ≤ (2 / 5) * Z2hat t :=\n          mul_le_mul_of_nonneg_left (nearZerosSub_mult_sum_le hZC2 ht10) (by norm_num)\n```\n\nFinset.mul_sum s f a : a * ∑ i ∈ s, f i = ∑ i ∈ s, a * f i — I have goal `∑ ρ ∈ S, (2/5)*m_ρ = (2/5) * ∑ ρ ∈ S, m_ρ` — that's (Finset.mul_sum S f (2/5)).symm. So `rw [← Finset.mul_sum]` — rewrites occurrences of `∑ i ∈ s, a * f i` to `a * ∑ i ∈ s, f i`. The LHS of my goal is `∑ ρ ∈ S, (2/5)*↑(zeroMult ρ.1)` ✓ matches with a := 2/5 ✓. So `rw [← Finset.mul_sum]` closes the goal to rfl ✓.\n\nHmm — does `Finset.mul_sum` need explicit args? `lemma mul_sum (s : Finset ι) (f : ι → R) (a : R)` — all explicit. rw [← Finset.mul_sum] with metavars — rw will unify ✓ (the reversed rw: find pattern `∑ i ∈ ?s, ?a * ?f i` — hmm, higher-order pattern ?f applied to bound i — rw uses keyed matching; it should work since the sum body is literally `(2/5) * ↑(zeroMult ρ.1)` which matches `?a * ?f ρ` with ?f := fun ρ => ↑(zeroMult ρ.1) via pattern unification ✓).\n\nContinue:\n\n```lean\n    -- combine: ‖logDeriv‖ ≤ near + tight\n    have hlog : ‖logDeriv riemannZeta s‖ ≤\n        (2 / 3) * Z2hat T + 10.5 * Real.log (T + 2) + 48 := by\n      have h1 : ‖logDeriv riemannZeta s‖ ≤\n          ‖∑ ρ ∈ nearZerosSub t, (zeroMult ρ.1 : ℂ) / (s - ρ.1)‖ +\n          ‖logDeriv riemannZeta s -\n            ∑ ρ ∈ nearZerosSub t, (zeroMult ρ.1 : ℂ) / (s - ρ.1)‖ :=\n        norm_le_insert _ _\n      have hmono := Z2hat_mono (by linarith : (1 : ℝ) ≤ t) htT\n      have hnn : (0 : ℝ) ≤ Z2hat T := Z2hat_nonneg (by linarith : (1 : ℝ) ≤ T)\n      linarith [h1, hnear, hRtight, hlogT, hmono, hnn]\n    rw [Jlag_norm_eq]\n    exact mul_le_mul hk hlog (norm_nonneg _) (by norm_num)\n```\n\nlinarith check: h1 : ‖logDeriv‖ ≤ ‖Σ‖ + ‖·−Σ‖; hnear : ‖Σ‖ ≤ (2/5)Z2hat t; hRtight : ‖·−Σ‖ ≤ 10.5*log(t+2)+48; hlogT : log(t+2) ≤ log(T+2); hmono : Z2hat t ≤ Z2hat T; hnn : 0 ≤ Z2hat T. Goal: ‖logDeriv‖ ≤ (2/3)Z2hat T + 10.5 log(T+2) + 48. Chain: ‖logDeriv‖ ≤ (2/5)Z2hat t + 10.5 log(t+2) + 48 ≤ (2/5)Z2hat T + 10.5 log(T+2) + 48 ≤ (2/3)Z2hat T + 10.5 log(T+2) + 48. All linear in atoms (Z2hat t, Z2hat T, log(t+2), log(T+2)) ✓ linarith.\n\nnorm_le_insert (a b) : ‖a‖ ≤ ‖b‖ + ‖a − b‖ — with a := logDeriv ζ s, b := Σ ✓.\n\nmul_le_mul hk hlog (norm_nonneg _) (by norm_num : (0:ℝ) ≤ 2): gives ‖kFun‖*‖logDeriv‖ ≤ 2 * RHS ✓. And goal after rw [Jlag_norm_eq] is exactly that ✓.\n\nWait — Jlag_norm_eq n s : ‖Jlag n s‖ = ‖kFun n s‖ * ‖logDeriv riemannZeta s‖. The goal is ‖Jlag n (↑(-5/2) + ↑t*I)‖ ≤ 2*(...). With `set s`, the goal shows ‖Jlag n s‖? Hmm — `set s := ... with hs_def` introduces s and rewrites occurrences of the term in the goal — the goal's `(((-5/2:ℝ):ℂ) + ↑t*I)` becomes s ✓ (set folds occurrences). Then rw [Jlag_norm_eq] — Jlag_norm_eq n s needs the argument to match — after set, goal is ‖Jlag n s‖ ≤ ... ✓ rw [Jlag_norm_eq n s]? If I write `rw [Jlag_norm_eq]` it'll unify ✓.\n\nThen the middle integral bound:\n```lean\n  have hmidInt : ∫ t in (-10 : ℝ)..(10 : ℝ),\n      ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ ≤ 20 * (2 * 1.3352) := by\n    have h := intervalIntegral.integral_mono_on (by norm_num : (-10:ℝ) ≤ 10)\n      (hI _ _) intervalIntegrable_const (fun t ht => hmid t ht)\n    rw [intervalIntegral.integral_const, smul_eq_mul] at h\n    -- h : ∫ ≤ (10 - -10) * (2*1.3352)\n    norm_num1 at h ⊢  -- (10 - -10) = 20\n    exact h\n```\n\nHmm — (10 - (-10)) * (2*1.3352) vs my stated 20 * (2*1.3352): `norm_num1 at h` simplifies (10 - -10) to 20 ✓ then exact h. Actually smul_eq_mul turns (10 - -10) • c into (10 - -10) * c. Then norm_num1... hmm norm_num1 might mangle more. Alternative: `convert h using 2; norm_num`. Simpler: keep hmidInt statement as `≤ (10 - (-10)) * (2 * 1.3352)` and let the final linarith handle the arithmetic. Even simpler: state hmidInt with the exact RHS produced and let linarith close the assembly. Let me state:\n\n```lean\n  have hmidInt : ∫ t in (-10:ℝ)..(10:ℝ), g.. ≤ (10 - (-10)) * (2 * 1.3352) := ...\n```\nand in assembly linarith computes (10 - -10) * (2*1.3352) = 40*1.3352 ✓ linear arithmetic with numerals — linarith handles ✓.\n\nSimilarly htailInt : ∫ t in 10..T, g.. ≤ (T - 10) * (2 * ((2/3)*Z2hat T + 10.5*log(T+2)+48)).\n\n```lean\n  have htailInt : ∫ t in (10 : ℝ)..T,\n      ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ ≤\n        (T - 10) * (2 * ((2 / 3) * Z2hat T + 10.5 * Real.log (T + 2) + 48)) := by\n    have h := intervalIntegral.integral_mono_on h10T (hI _ _)\n      intervalIntegrable_const (fun t ht => htail t ht)\n    rwa [intervalIntegral.integral_const, smul_eq_mul] at h\n```\n\nCareful: `intervalIntegrable_const` — signature `intervalIntegrable_const [IsLocallyFiniteMeasure μ] {c : E} : IntervalIntegrable (fun _ => c) μ a b` — c implicit, unified with the constant function in hg's slot. When passing as an argument to integral_mono_on whose hg expects IntervalIntegrable g μ a b with g := fun _ => K — unification `intervalIntegrable_const : IntervalIntegrable (fun _ => ?c) volume a b` ✓ instantiates ?c := K ✓.\n\nBut WAIT: the μ in these lemmas — my integrals use volume (default in `∫ t in a..b, f t` notation is volume? The interval integral notation `∫ x in a..b, f x` defaults to ∂volume? In Mathlib, `∫ x in a..b, f x` without ∂μ uses `MeasureTheory.volume` by default ✓ (the notation has default volume). IsLocallyFiniteMeasure volume ✓ instance.\n\nThe even piece:\n\n```lean\n  have hge : ∀ t : ℝ, ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ =\n      ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (-t : ℝ) * Complex.I)‖ :=\n    fun t => (jlag_left_vertical_norm_even n t).symm\n  have hleft : ∫ t in (-T)..(-10 : ℝ),\n      ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ =\n        ∫ t in (10 : ℝ)..T, ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ := by\n    have h1 : ∫ t in (-T)..(-10 : ℝ),\n        ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖ =\n          ∫ t in (-T)..(-10 : ℝ),\n            ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (-t : ℝ) * Complex.I)‖ :=\n      intervalIntegral.integral_congr (fun t _ => hge t)\n    rw [h1]\n    have h2 := intervalIntegral.integral_comp_neg\n      (fun t : ℝ => ‖Jlag n (((-5 / 2 : ℝ) : ℂ) + (t : ℝ) * Complex.I)‖)\n    -- h2 : ∫ x in ?a..?b, f (-x) = ∫ x in -?b..-?a, f x\n    rw [show (-T : ℝ) = ... ] hmm\n```\n\nHmm — h2's LHS integrand: `f (-x)` where f = fun t => ‖Jlag n (↑(-5/2) + ↑t*I)‖. So `f (-x)` = ‖Jlag n (↑(-5/2) + ↑(-x)*I)‖ ✓ matches my transformed integrand. The rw [h2] would rewrite the goal's `∫ t in (-T)..(-10), f(-t)` to `∫ t in -(-10)..-(-T), f t` ✓. Then goal: `∫ t in -(-10)..-(-T), f t = ∫ t in 10..T, f t` — `simp only [neg_neg]` closes (-(-10) = 10, -(-T) = T) then rfl ✓.\n\nBut the unification: `rw [h2]` where h2 has implicit ?a ?b metavars — rw needs to match `∫ x in ?a..?b, f (-x)` against goal subterm `∫ t in (-T)..(-10), (fun t => ‖Jlag n (↑(-5/2) + ↑(-t)*I)‖) t`... The goal after rw [h1] has integrand `fun t => ‖Jlag n (↑(-5/2)+↑(-t)*I)‖` or applied form `‖Jlag n (↑(-5/2)+↑(-t)*I)‖` under the binder. f(-x) with f the lambda: beta-redex `(fun t => ‖..t..‖) (-x)`. rw matching needs syntactic match up to defeq — integral_comp_neg's LHS is `∫ x in a..b, f (-x)`; with f instantiated to my lambda (I passed it explicitly, so no HO unification for f), the LHS term is `∫ x in ?a..?b, (fun t => ‖..t..‖) (-x)`. After beta this is `∫ x in ?a..?b, ‖..(-x)..‖`. Does rw beta-reduce when matching? rw matches up to reducible defeq? It should handle beta. Then ?a ?b from the endpoints -T, -10 ✓.\n\nPotential issue: the bound-variable name and the cast `↑(-t)`: in my h1-produced integrand the term is `↑(-t) * I`; in f(-x) instantiated: `↑(-x) * I` ✓ same up to alpha.\n\nAlternatively cleaner: prove hleft by direct calc:\n```lean\n  have hleft : ∫ t in (-T)..(-10:ℝ), F t = ∫ t in (10:ℝ)..T, F t := by\n    have h1 : ∫ t in (-T)..(-10:ℝ), F t = ∫ t in (-T)..(-10:ℝ), F (-t) :=\n      intervalIntegral.integral_congr (fun t _ => hge t)\n    have h2 : ∫ t in (-T)..(-10:ℝ), F (-t) = ∫ t in -(-10:ℝ)..-(-T), F t :=\n      intervalIntegral.integral_comp_neg F\n    rw [h1, h2, neg_neg (10:ℝ), neg_neg T]  -- hmm neg_neg needs the form -(-a)\n```\n\nneg_neg : -(-a) = a. rw [neg_neg] rewrites first occurrence... rw [neg_neg (10 : ℝ)]? The term is `-(-10)` = Neg.neg (Neg.neg 10) ✓ rw [neg_neg (10:ℝ)] → 10 ✓. But -( -T): Neg.neg (Neg.neg T) ✓ rw [neg_neg T]. But careful — `-(10:ℝ)`: is the literal `-10` displayed as Neg.neg 10 ✓.\n\nHmm wait — the direction of h2: integral_comp_neg F : ∫ x in ?a..?b, F (-x) = ∫ x in -?b..-?a, F x. With ?a := -T, ?b := -10: RHS = ∫ x in -(-10)..-(-T), F x ✓.\n\nBut h2 as stated with metavars — `intervalIntegral.integral_comp_neg F` leaves ?a ?b free; when I use it in `have h2 : ... := intervalIntegral.integral_comp_neg F`, the type ascription fixes ?a := -T, ?b := -10 ✓. For the LHS of h2's type ascription: ∫ t in (-T)..(-10), F (-t) — needs F(-t) to beta-match ✓ fine (defeq ascription).\n\nOK — but there's a subtlety: `intervalIntegral.integral_comp_neg F` — F is the lambda; the LHS `∫ x in ?a..?b, F (-x)` — the integrand is `(F · (-x))`?? Actually the lemma statement is `∫ x in a..b, f (-x)` which elaborates as `∫ x in a..b, f (Neg.neg x)` — with f the lambda, `f (Neg.neg x)` is a beta-redex. Lean stores it as such or beta-reduces during elaboration? The lemma was elaborated with f a section variable — so f (-x) stays `f (-x)` (not a redex since f was a variable at elaboration). When I instantiate f := my lambda, the term becomes `(myLambda) (-x)` — a redex, NOT beta-reduced automatically. My type ascription `∫ t in -T..-10, ‖Jlag n (↑(-5/2)+↑(-t)*I)‖` has the beta-reduced form. defeq check: ascription vs inferred — defeq handles beta ✓.\n\nThen `rw [h1, h2, ...]`: h2's LHS in redex form vs goal's reduced form — rw matches up to reducible + some defeq; beta usually OK. Alternatively use `calc` with exact:\n\n```lean\n  have hleft : ∫ t in (-T)..(-10:ℝ), F t = ∫ t in (10:ℝ)..T, F t := by\n    calc ∫ t in (-T)..(-10:ℝ), F t \n        = ∫ t in (-T)..(-10:ℝ), F (-t) :=\n          intervalIntegral.integral_congr (fun t _ => hge t)\n      _ = ∫ t in -(-10:ℝ)..-(-T), F t := intervalIntegral.integral_comp_neg F\n      _ = ∫ t in (10:ℝ)..T, F t := by rw [neg_neg, neg_neg]\n```\n\nThe last step: goal ∫ t in -(-10)..-(-T), F t = ∫ t in 10..T, F t. rw [neg_neg] rewrites the FIRST -(-?) occurrence — neg_neg : -(-a) = a; first match: -(-10) → 10; second rw [neg_neg]: -(-T) → T; then rfl ✓. But rw [neg_neg] without args — could loop? No, after two applications no more -(-·). But careful: it might rewrite -(-T) first (term order) — either order, two rewrites then rfl ✓. Hmm, actually rw [neg_neg] rewrites ALL occurrences that match the first pattern found? No — rw rewrites all occurrences of the FIRST matched instance only. So first rw [neg_neg]: finds some -(-x), instantiates, rewrites all copies of that instance. Second: the other one. Fine.\n\nWait — subtle: is `-(-10 : ℝ)` actually `Neg.neg (Neg.neg (10 : ℝ))`? The term `-(-10)` from integral_comp_neg RHS: `-?b` with ?b := -10 gives `Neg.neg (-10)` = `Neg.neg (Neg.neg 10)` ✓.\n\nNow the split & assembly:\n\n```lean\n  have hsplit : ∫ t in (-T)..T, F t =\n      ∫ t in (-T)..(-10:ℝ), F t + (∫ t in (-10:ℝ)..(10:ℝ), F t +\n        ∫ t in (10:ℝ)..T, F t) := by\n    rw [← intervalIntegral.integral_add_adjacent_intervals (hI (-T) (-10)) (hI (-10) T)]\n    rw [← intervalIntegral.integral_add_adjacent_intervals (hI (-10) 10) (hI 10 T)]\n```\n\nHmm — direction: integral_add_adjacent_intervals hab hbc : (∫ a..b) + (∫ b..c) = ∫ a..c. ← direction: rewrites ∫ a..c into the sum. Goal LHS ∫ -T..T: rw [← integral_add_adjacent_intervals (hI (-T) (-10)) (hI (-10) T)] turns ∫(-T..T) into ∫(-T..-10) + ∫(-10..T) ✓. Then rw [← ... (hI (-10) 10) (hI 10 T)] turns ∫(-10..T) into ∫(-10..10) + ∫(10..T) ✓. Goal becomes `∫(-T..-10) + (∫(-10..10) + ∫(10..T)) = ∫(-T..-10) + (∫(-10..10) + ∫(10..T))` ✓ rfl closed by rw automatically.\n\nWait — rw [← h] where h : A + B = C: rewrites C to A + B ✓. But there are two integrals matching the pattern... first rw targets ∫(-T..T) — the only occurrence of that exact term. But the rewrite pattern is the FULL RHS of the lemma instance: with the hI args given, the instance is `∫(-T..-10) + ∫(-10..T) = ∫(-T..T)` — fully determined (a=-T, b=-10, c=T) ✓ no ambiguity.\n\nThen final:\n\n```lean\n  calc ‖VIntegral (Jlag n) (-5 / 2) (-T) T‖\n      = ‖∫ t in (-T)..T, Jlag n (((-5 / 2 : ℝ)) + (t : ℝ) * Complex.I)‖ :=\n        VIntegral_norm\n    _ ≤ ∫ t in (-T)..T, ‖Jlag n (((-5 / 2 : ℝ)) + (t : ℝ) * Complex.I)‖ :=\n        intervalIntegral.norm_integral_le_integral_norm hTT\n    _ = ∫ t in (-T)..(-10:ℝ), F.. + (∫ t in (-10:ℝ)..(10:ℝ), F.. +\n          ∫ t in (10:ℝ)..T, F..) := hsplit\n    _ = (∫ t in (10:ℝ)..T, F..) + (∫ t in (-10:ℝ)..(10:ℝ), F..) +\n          ∫ t in (10:ℝ)..T, F.. := by rw [hleft]; ring\n    _ ≤ (T - 10) * K + (10 - -10) * (2 * 1.3352) + (T - 10) * K := by\n        linarith [htailInt, hmidInt]\n    _ ≤ 4 * T * ((2/3) * Z2hat T + 10.5 * Real.log (T + 2) + 48) + 40 * 1.3352 := by\n        -- K ≥ 0\n        have hK0 : (0:ℝ) ≤ 2 * ((2/3) * Z2hat T + 10.5 * Real.log (T + 2) + 48) := by\n          have hnn := Z2hat_nonneg (by linarith : (1:ℝ) ≤ T)\n          have hlognn : 0 ≤ Real.log (T + 2) := Real.log_nonneg (by linarith)\n          positivity  -- or nlinarith\n        nlinarith [hK0]\n```\n\nHmm the last step: goal: (T-10)*K + 20*(2*1.3352) + (T-10)*K ≤ 4*T*(stuff) + 40*1.3352 where K = 2*(stuff). (T-10)*K ≤ T*K ⟺ -10K ≤ 0 ⟸ K ≥ 0. 2*(T-10)*K + 53.408 ≤ 2*T*K + 53.408. 2*T*K = 2*T*(2*stuff) = 4*T*stuff ✓. nlinarith with hK0: needs to expand (T-10)*K as T*K - 10*K — linearization handles numeral-multiplied products? nlinarith treats K and T*K as atoms; (T-10)*K = T*K - 10*K via distrib — nlinarith's ring_nf preprocessing handles ✓. linarith alone should also: 2*(T-10)*K + 40*1.3352 ≤ 4*T*stuff + 40*1.3352 ⟺ 2*(T-10)*K ≤ 4*T*stuff ⟺ 2*T*K - 20*K ≤ 2*T*K ⟺ -20*K ≤ 0. In atom terms: K atom, T*K atom. Goal (after ring normalization by linarith preprocessing): it distributes 2*(T-10)*K → 2*(T*K) - 20*K and 4*T*(stuff) where stuff = K/2... hmm — the RHS has `stuff` = (2/3)*Z2hat T + 10.5*log(T+2) + 48 as a DIFFERENT atom than K. linarith sees 4*T*stuff vs 2*T*K — different atoms! It won't know K = 2*stuff. PROBLEM.\n\nFix: give linarith the relation hK : K = 2 * stuff explicitly as an equation, or better, don't introduce K at all — write htailInt with the fully expanded RHS (T - 10) * (2 * ((2/3)*Z2hat T + 10.5*log(T+2)+48)) and let linarith treat `Z2hat T`, `log (T+2)`, `T * Z2hat T`, `T * log(T+2)` as atoms. The goal RHS: 4*T*((2/3)*Z2hat T + 10.5*log(T+2)+48) + 40*1.3352. ring_nf normalization: LHS = 2*(T-10)*(2/3*Z + 10.5*L + 48) + 53.408... expand: 2*T*(2/3*Z) + ... linarith's preprocessing does ring_nf: atoms: T*Z, Z, T*L, L. LHS expands fine, RHS expands fine — all linear in these four atoms ✓ linarith closes given hK0-like facts: Z2hat T ≥ 0, log(T+2) ≥ 0, T ≥ 10. The needed inequality: -20*(2/3*Z+10.5*L+48) ≤ 0 — linear combo of Z, L, const ✓ linarith with hnn, hlognn.\n\nSo: skip the K abbreviation; in the final step provide hnn : 0 ≤ Z2hat T and hlognn : 0 ≤ Real.log (T+2), then `linarith [htailInt, hmidInt, hnn, hlognn]` — wait but ttailInt's RHS (T-10)*(2*(...)) needs expansion to compare with 4*T*(...). linarith normalizes both sides via ring_nf — the products (T-10)*(...) expand into atom monomials T*Z etc ✓. And the goal inequality likewise. So one linarith with the nonneg haves should close:\n\nFrom hsplit-rw'd form:\n∫(-T..-10) + (∫(-10..10) + ∫(10..T)) = [via hleft] ∫(10..T) + (∫(-10..10) + ∫(10..T)).\n≤ (T-10)*K' + ((10-(-10))*(2*1.3352) + (T-10)*K') [htailInt, hmidInt]\n= 2*(T-10)*K' + 20*2.6704\n≤ 2*T*K' + 53.408 [K' ≥ 0]\n= 4*T*(stuff) + 40*1.3352 ✓ [2*K' = 4*stuff since K' := 2*stuff; 20*2.6704 = 53.408 = 40*1.3352 ✓]\n\nAll linear after ring_nf ✓. So:\n\n```lean\n    _ ≤ 4 * T * ((2 / 3) * Z2hat T + 10.5 * Real.log (T + 2) + 48) + 40 * 1.3352 := by\n      have hnn : (0:ℝ) ≤ Z2hat T := Z2hat_nonneg (by linarith)\n      have hlognn : (0:ℝ) ≤ Real.log (T + 2) := Real.log_nonneg (by linarith)\n      rw [hleft]\n      linarith [htailInt, hmidInt, hnn, hlognn]\n```\n\nHmm — but I need the calc step structure right. Let me restructure the final calc to:\n\n```lean\n  calc ‖VIntegral (Jlag n) (-5 / 2) (-T) T‖\n      = ‖∫ t in (-T)..T, Jlag n (((-5 / 2 : ℝ)) + (t : ℝ) * Complex.I)‖ := VIntegral_norm\n    _ ≤ ∫ t in (-T)..T, ‖Jlag n (((-5 / 2 : ℝ)) + (t : ℝ) * Complex.I)‖ :=\n        intervalIntegral.norm_integral_le_integral_norm hTT\n    _ = ∫ t in (-T)..(-10:ℝ), F + (∫ t in (-10:ℝ)..(10:ℝ), F + ∫ t in (10:ℝ)..T, F) := hsplit\n    _ ≤ 4 * T * (...) + 40 * 1.3352 := by\n        rw [hleft]\n        have hnn ...; have hlognn ...\n        linarith [htailInt, hmidInt, hnn, hlognn]\n```\n\nAfter rw [hleft]: goal ∫(10..T) + (∫(-10..10) + ∫(10..T)) ≤ RHS. linarith: substitute htailInt (∫(10..T) ≤ (T-10)*K') and hmidInt: atoms ∫(10..T), ∫(-10..10) ✓ linear in those atoms ✓, then the expansion ✓. linarith should close: goal = 2*∫(10..T) + ∫(-10..10) ≤ RHS'; with ∫(10..T) ≤ (T-10)*K', ∫(-10..10) ≤ 20*2.6704: 2*(T-10)*K' + 53.408 ≤ 4*T*stuff + 53.408 ⟺ 2*T*K' - 20*K' ≤ 2*T*K' ⟺ 0 ≤ 20*K' ⟸ Z, L ≥ 0 ✓. linarith handles ✓.\n\nOne concern: `VIntegral_norm` — signature `{f : ℂ → ℂ} {x y₁ y₂ : ℝ} : ‖VIntegral f x y₁ y₂‖ = ‖∫ t in y₁..y₂, f ((x : ℝ) + (t : ℝ) * Complex.I)‖`. My VIntegral application: VIntegral (Jlag n) (-5/2) (-T) T — is -5/2 here ℝ? VIntegral f x y₁ y₂ with x : ℝ — in rectangleIntegral_Jlag_eq: VIntegral (Jlag n) (2 * Real.sqrt n) (-T) T — x = 2*√n : ℝ ✓. So x := (-5/2 : ℝ) ✓. The RHS point: `((x : ℝ) + (t : ℝ) * Complex.I)` — with x : ℝ the `(x : ℝ)` annotation is the identity (not a cast!) — hmm wait, in the theorem as written at line 173: `f ((x : ℝ) + (t : ℝ) * Complex.I)`. If x : ℝ, then (x : ℝ) is x, and `x + t * Complex.I` needs x coerced to ℂ. The elaborated term: `(↑x : ℂ) + (↑t : ℂ) * I`. My lambda `↑(-5/2) + ↑t * I` — same ✓.\n\nHmm — one more check: VIntegral_norm's LHS `VIntegral f x y₁ y₂`. My goal's LHS: `VIntegral (Jlag n) (-5/2) (-T) T`. Match ✓. But wait — in the theorem statement I must write `VIntegral (Jlag n) (-5/2) (-T) T` with -5/2 elaborating as ℝ (since VIntegral expects ℝ for x). Fine.\n\nAlso `intervalIntegral.norm_integral_le_integral_norm hTT : ‖∫ t in -T..T, Jlag n _‖ ≤ ∫ t in -T..T, ‖Jlag n _‖` ✓.\n\nNow — the `F` abbreviation: I'll avoid it and write the full integrand in hsplit/hleft. Verbose but fine.\n\nOne more potential gotcha: in hmid, `rw [Jlag_norm_eq]` — the goal: ‖Jlag n (↑(-5/2)+↑t*I)‖ ≤ 2*1.3352. Jlag_norm_eq n s : ‖Jlag n s‖ = ‖kFun n s‖ * ‖logDeriv riemannZeta s‖. rw rewrites ‖Jlag n s‖ to the product ✓ then mul_le_mul.\n\nAlso in hmid: hMZt's point form — after rwa [hcast] at h: h : ‖logDeriv riemannZeta (↑(-5/2) + ↑t*I)‖ ≤ 1.3352 ✓ matches.\n\nWait — in hMZ's statement the point is `(-5 \\ 2: ℂ) + (t : ℝ) * Complex.I`. I need to read MZeroProp's exact source to get the exact term. Let me read LiContour.lean lines 160-166.","signature":""},{"type":"text","text":"All patterns confirmed. Let me check the exact source of `MZeroProp` (the grep showed an odd `\\` character) and the `VIntegral` definition in Zeta23."},{"type":"tool_use","id":"Read_36","name":"Read","input":{"file_path":"D:\\Python\\Quantum\\research\\lean\\NguyenRH1\\NguyenRH1\\LiContour.lean","offset":155,"limit":15},"extra_content":null},{"type":"tool_use","id":"Grep_37","name":"Grep","input":{"pattern":"def VIntegral|def HIntegral|noncomputable def VIntegral|noncomputable def HIntegral","path":"D:\\Python\\Quantum\\zeta-23-lean","output_mode":"content","-A":4},"extra_content":null}]