l3lab/ntp-mathlib huggingface dataset:
theorem hasMellin_one_div_sqrt_Ioc {s : ℂ} (hs : 1 / 2 < re s) :
    HasMellin (indicator (Ioc 0 1) (fun t => 1 / ↑(sqrt t) : ℝ → ℂ)) s (1 / (s - 1 / 2)) := by
  have h1 : EqOn (fun t => 1 / ↑(sqrt t) : ℝ → ℂ) (fun t => (t : ℂ) ^ (-1 / 2 : ℂ)) (Ioc 0 1) := by
    intro t ht
    simp_rw [neg_div, cpow_neg, ← one_div, sqrt_eq_rpow, ofReal_cpow ht.1.le]
    norm_num
  simp_rw [indicator_congr h1, (by ring : s - 1 / 2 = s + -1 / 2)]
  convert hasMellin_cpow_Ioc (-1 / 2) _
  rwa [(by 

Proof state:
s : ℂ
hs : 1 / 2 < s.re
h1 : EqOn (fun t => 1 / ↑(sqrt t)) (fun t => ↑t ^ (-1 / 2)) (Ioc 0 1)
⊢ -1 / 2 = ↑(-1 / 2)

Next tactic:
norm_num
/-- Evaluate the Mellin transform of the "fudge factor" in `zetaKernel₂` -/
theorem hasMellin_one_div_sqrt_sub_one_div_two_Ioc {s : ℂ} (hs : 1 / 2 < s.re) :
    HasMellin ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) s
      (1 / (2 * s) - 1 / (2 * s - 1)) := by
  

Proof state:
s : ℂ
hs : 1 / 2 < s.re
⊢ HasMellin (indicator (Ioc 0 1) fun t => (1 - 1 / ↑(sqrt t)) / 2) s (1 / (2 * s) - 1 / (2 * s - 1))

Next tactic:
have step1 :
    HasMellin (indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t) : ℝ → ℂ)) s
      (1 / s - 1 / (s - 1 / 2)) := by
    have a := hasMellin_one_Ioc (one_half_pos.trans hs)
    have b := hasMellin_one_div_sqrt_Ioc hs
    simpa only [a.2, b.2, ← indicator_sub] using hasMellin_sub a.1 b.1
/-- Evaluate the Mellin transform of the "fudge factor" in `zetaKernel₂` -/
theorem hasMellin_one_div_sqrt_sub_one_div_two_Ioc {s : ℂ} (hs : 1 / 2 < s.re) :
    HasMellin ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) s
      (1 / (2 * s) - 1 / (2 * s - 1)) := by
  have step1 :
    HasMellin (indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t) : ℝ → ℂ)) s
      (1 / s - 1 / (s - 1 / 2)) := by
    

Proof state:
s : ℂ
hs : 1 / 2 < s.re
⊢ HasMellin (indicator (Ioc 0 1) fun t => 1 - 1 / ↑(sqrt t)) s (1 / s - 1 / (s - 1 / 2))

Next tactic:
have a := hasMellin_one_Ioc (one_half_pos.trans hs)
/-- Evaluate the Mellin transform of the "fudge factor" in `zetaKernel₂` -/
theorem hasMellin_one_div_sqrt_sub_one_div_two_Ioc {s : ℂ} (hs : 1 / 2 < s.re) :
    HasMellin ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) s
      (1 / (2 * s) - 1 / (2 * s - 1)) := by
  have step1 :
    HasMellin (indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t) : ℝ → ℂ)) s
      (1 / s - 1 / (s - 1 / 2)) := by
    have a := hasMellin_one_Ioc (one_half_pos.trans hs)
    

Proof state:
s : ℂ
hs : 1 / 2 < s.re
a : HasMellin (indicator (Ioc 0 1) fun x => 1) s (1 / s)
⊢ HasMellin (indicator (Ioc 0 1) fun t => 1 - 1 / ↑(sqrt t)) s (1 / s - 1 / (s - 1 / 2))

Next tactic:
have b := hasMellin_one_div_sqrt_Ioc hs
/-- Evaluate the Mellin transform of the "fudge factor" in `zetaKernel₂` -/
theorem hasMellin_one_div_sqrt_sub_one_div_two_Ioc {s : ℂ} (hs : 1 / 2 < s.re) :
    HasMellin ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) s
      (1 / (2 * s) - 1 / (2 * s - 1)) := by
  have step1 :
    HasMellin (indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t) : ℝ → ℂ)) s
      (1 / s - 1 / (s - 1 / 2)) := by
    have a := hasMellin_one_Ioc (one_half_pos.trans hs)
    have b := hasMellin_one_div_sqrt_Ioc hs
    

Proof state:
s : ℂ
hs : 1 / 2 < s.re
a : HasMellin (indicator (Ioc 0 1) fun x => 1) s (1 / s)
b : HasMellin (indicator (Ioc 0 1) fun t => 1 / ↑(sqrt t)) s (1 / (s - 1 / 2))
⊢ HasMellin (indicator (Ioc 0 1) fun t => 1 - 1 / ↑(sqrt t)) s (1 / s - 1 / (s - 1 / 2))

Next tactic:
simpa only [a.2, b.2, ← indicator_sub] using hasMellin_sub a.1 b.1
/-- Evaluate the Mellin transform of the "fudge factor" in `zetaKernel₂` -/
theorem hasMellin_one_div_sqrt_sub_one_div_two_Ioc {s : ℂ} (hs : 1 / 2 < s.re) :
    HasMellin ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) s
      (1 / (2 * s) - 1 / (2 * s - 1)) := by
  have step1 :
    HasMellin (indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t) : ℝ → ℂ)) s
      (1 / s - 1 / (s - 1 / 2)) := by
    have a := hasMellin_one_Ioc (one_half_pos.trans hs)
    have b := hasMellin_one_div_sqrt_Ioc hs
    simpa only [a.2, b.2, ← indicator_sub] using hasMellin_sub a.1 b.1
  -- todo: implement something like "indicator.const_div" (blocked by the port for now)
  

Proof state:
s : ℂ
hs : 1 / 2 < s.re
step1 : HasMellin (indicator (Ioc 0 1) fun t => 1 - 1 / ↑(sqrt t)) s (1 / s - 1 / (s - 1 / 2))
⊢ HasMellin (indicator (Ioc 0 1) fun t => (1 - 1 / ↑(sqrt t)) / 2) s (1 / (2 * s) - 1 / (2 * s - 1))

Next tactic:
rw [show
      ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) = fun t =>
        (Ioc 0 1).indicator (fun t => 1 - 1 / (sqrt t : ℂ)) t / 2
      by ext1 t; simp_rw [div_eq_inv_mul, indicator_mul_right]]
/-- Evaluate the Mellin transform of the "fudge factor" in `zetaKernel₂` -/
theorem hasMellin_one_div_sqrt_sub_one_div_two_Ioc {s : ℂ} (hs : 1 / 2 < s.re) :
    HasMellin ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) s
      (1 / (2 * s) - 1 / (2 * s - 1)) := by
  have step1 :
    HasMellin (indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t) : ℝ → ℂ)) s
      (1 / s - 1 / (s - 1 / 2)) := by
    have a := hasMellin_one_Ioc (one_half_pos.trans hs)
    have b := hasMellin_one_div_sqrt_Ioc hs
    simpa only [a.2, b.2, ← indicator_sub] using hasMellin_sub a.1 b.1
  -- todo: implement something like "indicator.const_div" (blocked by the port for now)
  rw [show
      ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) = fun t =>
        (Ioc 0 1).indicator (fun t => 1 - 1 / (sqrt t : ℂ)) t / 2
      by 

Proof state:
s : ℂ
hs : 1 / 2 < s.re
step1 : HasMellin (indicator (Ioc 0 1) fun t => 1 - 1 / ↑(sqrt t)) s (1 / s - 1 / (s - 1 / 2))
⊢ (indicator (Ioc 0 1) fun t => (1 - 1 / ↑(sqrt t)) / 2) = fun t =>
    indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t)) t / 2

Next tactic:
ext1 t
/-- Evaluate the Mellin transform of the "fudge factor" in `zetaKernel₂` -/
theorem hasMellin_one_div_sqrt_sub_one_div_two_Ioc {s : ℂ} (hs : 1 / 2 < s.re) :
    HasMellin ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) s
      (1 / (2 * s) - 1 / (2 * s - 1)) := by
  have step1 :
    HasMellin (indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t) : ℝ → ℂ)) s
      (1 / s - 1 / (s - 1 / 2)) := by
    have a := hasMellin_one_Ioc (one_half_pos.trans hs)
    have b := hasMellin_one_div_sqrt_Ioc hs
    simpa only [a.2, b.2, ← indicator_sub] using hasMellin_sub a.1 b.1
  -- todo: implement something like "indicator.const_div" (blocked by the port for now)
  rw [show
      ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) = fun t =>
        (Ioc 0 1).indicator (fun t => 1 - 1 / (sqrt t : ℂ)) t / 2
      by ext1 t; 

Proof state:
case h
s : ℂ
hs : 1 / 2 < s.re
step1 : HasMellin (indicator (Ioc 0 1) fun t => 1 - 1 / ↑(sqrt t)) s (1 / s - 1 / (s - 1 / 2))
t : ℝ
⊢ indicator (Ioc 0 1) (fun t => (1 - 1 / ↑(sqrt t)) / 2) t = indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t)) t / 2

Next tactic:
simp_rw [div_eq_inv_mul, indicator_mul_right]
/-- Evaluate the Mellin transform of the "fudge factor" in `zetaKernel₂` -/
theorem hasMellin_one_div_sqrt_sub_one_div_two_Ioc {s : ℂ} (hs : 1 / 2 < s.re) :
    HasMellin ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) s
      (1 / (2 * s) - 1 / (2 * s - 1)) := by
  have step1 :
    HasMellin (indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t) : ℝ → ℂ)) s
      (1 / s - 1 / (s - 1 / 2)) := by
    have a := hasMellin_one_Ioc (one_half_pos.trans hs)
    have b := hasMellin_one_div_sqrt_Ioc hs
    simpa only [a.2, b.2, ← indicator_sub] using hasMellin_sub a.1 b.1
  -- todo: implement something like "indicator.const_div" (blocked by the port for now)
  rw [show
      ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) = fun t =>
        (Ioc 0 1).indicator (fun t => 1 - 1 / (sqrt t : ℂ)) t / 2
      by ext1 t; simp_rw [div_eq_inv_mul, indicator_mul_right]]
  

Proof state:
s : ℂ
hs : 1 / 2 < s.re
step1 : HasMellin (indicator (Ioc 0 1) fun t => 1 - 1 / ↑(sqrt t)) s (1 / s - 1 / (s - 1 / 2))
⊢ HasMellin (fun t => indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t)) t / 2) s (1 / (2 * s) - 1 / (2 * s - 1))

Next tactic:
simp_rw [HasMellin, mellin_div_const, step1.2, sub_div, div_div]
/-- Evaluate the Mellin transform of the "fudge factor" in `zetaKernel₂` -/
theorem hasMellin_one_div_sqrt_sub_one_div_two_Ioc {s : ℂ} (hs : 1 / 2 < s.re) :
    HasMellin ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) s
      (1 / (2 * s) - 1 / (2 * s - 1)) := by
  have step1 :
    HasMellin (indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t) : ℝ → ℂ)) s
      (1 / s - 1 / (s - 1 / 2)) := by
    have a := hasMellin_one_Ioc (one_half_pos.trans hs)
    have b := hasMellin_one_div_sqrt_Ioc hs
    simpa only [a.2, b.2, ← indicator_sub] using hasMellin_sub a.1 b.1
  -- todo: implement something like "indicator.const_div" (blocked by the port for now)
  rw [show
      ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) = fun t =>
        (Ioc 0 1).indicator (fun t => 1 - 1 / (sqrt t : ℂ)) t / 2
      by ext1 t; simp_rw [div_eq_inv_mul, indicator_mul_right]]
  simp_rw [HasMellin, mellin_div_const, step1.2, sub_div, div_div]
  

Proof state:
s : ℂ
hs : 1 / 2 < s.re
step1 : HasMellin (indicator (Ioc 0 1) fun t => 1 - 1 / ↑(sqrt t)) s (1 / s - 1 / (s - 1 / 2))
⊢ MellinConvergent (fun t => indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t)) t / 2) s ∧
    1 / (s * 2) - 1 / ((s - 1 / 2) * 2) = 1 / (2 * s) - 1 / (2 * s - 1)

Next tactic:
refine ⟨step1.1.div_const _, ?_⟩
/-- Evaluate the Mellin transform of the "fudge factor" in `zetaKernel₂` -/
theorem hasMellin_one_div_sqrt_sub_one_div_two_Ioc {s : ℂ} (hs : 1 / 2 < s.re) :
    HasMellin ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) s
      (1 / (2 * s) - 1 / (2 * s - 1)) := by
  have step1 :
    HasMellin (indicator (Ioc 0 1) (fun t => 1 - 1 / ↑(sqrt t) : ℝ → ℂ)) s
      (1 / s - 1 / (s - 1 / 2)) := by
    have a := hasMellin_one_Ioc (one_half_pos.trans hs)
    have b := hasMellin_one_div_sqrt_Ioc hs
    simpa only [a.2, b.2, ← indicator_sub] using hasMellin_sub a.1 b.1
  -- todo: implement something like "indicator.const_div" (blocked by the port for now)
  rw [show
      ((Ioc 0 1).indicator fun t => (1 - 1 / (sqrt t : ℂ)) / 2) = fun t =>
        (Ioc 0 1).indicator (fun t => 1 - 1 / (sqrt t : ℂ)) t / 2
      by ext1 t; simp_rw [div_eq_inv_mul, indicator_mul_right]]
  simp_rw [HasMellin, mellin_div_const, step1.2, sub_div, div_div]
  refine ⟨step1.1.div_const _, ?_⟩
  

Proof state:
s : ℂ
hs : 1 / 2 < s.re
step1 : HasMellin (indicator (Ioc 0 1) fun t => 1 - 1 / ↑(sqrt t)) s (1 / s - 1 / (s - 1 / 2))
⊢ 1 / (s * 2) - 1 / ((s - 1 / 2) * 2) = 1 / (2 * s) - 1 / (2 * s - 1)

Next tactic:
rw [mul_comm, sub_mul, div_mul_cancel _ (two_ne_zero' ℂ), mul_comm s 2]
theorem mellin_zetaKernel₂_eq_of_lt_re {s : ℂ} (hs : 1 / 2 < s.re) :
    mellin zetaKernel₂ s = mellin zetaKernel₁ s + 1 / (2 * s) - 1 / (2 * s - 1) := by
  

Proof state:
s : ℂ
hs : 1 / 2 < s.re
⊢ mellin zetaKernel₂ s = mellin zetaKernel₁ s + 1 / (2 * s) - 1 / (2 * s - 1)

Next tactic:
have h :=
    mellinConvergent_of_isBigO_rpow_exp pi_pos locally_integrable_zetaKernel₁
      isBigO_atTop_zetaKernel₁ isBigO_zero_zetaKernel₁ hs
theorem mellin_zetaKernel₂_eq_of_lt_re {s : ℂ} (hs : 1 / 2 < s.re) :
    mellin zetaKernel₂ s = mellin zetaKernel₁ s + 1 / (2 * s) - 1 / (2 * s - 1) := by
  have h :=
    mellinConvergent_of_isBigO_rpow_exp pi_pos locally_integrable_zetaKernel₁
      isBigO_atTop_zetaKernel₁ isBigO_zero_zetaKernel₁ hs
  

Proof state:
s : ℂ
hs : 1 / 2 < s.re
h : MellinConvergent zetaKernel₁ s
⊢ mellin zetaKernel₂ s = mellin zetaKernel₁ s + 1 / (2 * s) - 1 / (2 * s - 1)

Next tactic:
have h' := hasMellin_one_div_sqrt_sub_one_div_two_Ioc hs
theorem mellin_zetaKernel₂_eq_of_lt_re {s : ℂ} (hs : 1 / 2 < s.re) :
    mellin zetaKernel₂ s = mellin zetaKernel₁ s + 1 / (2 * s) - 1 / (2 * s - 1) := by
  have h :=
    mellinConvergent_of_isBigO_rpow_exp pi_pos locally_integrable_zetaKernel₁
      isBigO_atTop_zetaKernel₁ isBigO_zero_zetaKernel₁ hs
  have h' := hasMellin_one_div_sqrt_sub_one_div_two_Ioc hs
  

Proof state:
s : ℂ
hs : 1 / 2 < s.re
h : MellinConvergent zetaKernel₁ s
h' : HasMellin (indicator (Ioc 0 1) fun t => (1 - 1 / ↑(sqrt t)) / 2) s (1 / (2 * s) - 1 / (2 * s - 1))
⊢ mellin zetaKernel₂ s = mellin zetaKernel₁ s + 1 / (2 * s) - 1 / (2 * s - 1)

Next tactic:
simp_rw [zetaKernel₂, Pi.add_def, add_sub_assoc, (hasMellin_add h h'.1).2, h'.2]
theorem completed_zeta_eq_mellin_of_one_lt_re {s : ℂ} (hs : 1 < re s) :
    riemannCompletedZeta s = mellin zetaKernel₁ (s / 2) := by
  

Proof state:
s : ℂ
hs : 1 < s.re
⊢ riemannCompletedZeta s = mellin zetaKernel₁ (s / 2)

Next tactic:
have : 1 / 2 < (s / 2).re := by
    rw [show s / 2 = ↑(2⁻¹ : ℝ) * s by push_cast; rw [mul_comm]; rfl]
    rwa [ofReal_mul_re, ← div_eq_inv_mul, div_lt_div_right (zero_lt_two' ℝ)]
theorem completed_zeta_eq_mellin_of_one_lt_re {s : ℂ} (hs : 1 < re s) :
    riemannCompletedZeta s = mellin zetaKernel₁ (s / 2) := by
  have : 1 / 2 < (s / 2).re := by
    

Proof state:
s : ℂ
hs : 1 < s.re
⊢ 1 / 2 < (s / 2).re

Next tactic:
rw [show s / 2 = ↑(2⁻¹ : ℝ) * s by push_cast; rw [mul_comm]; rfl]
theorem completed_zeta_eq_mellin_of_one_lt_re {s : ℂ} (hs : 1 < re s) :
    riemannCompletedZeta s = mellin zetaKernel₁ (s / 2) := by
  have : 1 / 2 < (s / 2).re := by
    rw [show s / 2 = ↑(2⁻¹ : ℝ) * s by 

Proof state:
s : ℂ
hs : 1 < s.re
⊢ s / 2 = ↑2⁻¹ * s

Next tactic:
push_cast
theorem completed_zeta_eq_mellin_of_one_lt_re {s : ℂ} (hs : 1 < re s) :
    riemannCompletedZeta s = mellin zetaKernel₁ (s / 2) := by
  have : 1 / 2 < (s / 2).re := by
    rw [show s / 2 = ↑(2⁻¹ : ℝ) * s by push_cast; 

Proof state:
s : ℂ
hs : 1 < s.re
⊢ s / 2 = 2⁻¹ * s

Next tactic:
rw [mul_comm]
theorem completed_zeta_eq_mellin_of_one_lt_re {s : ℂ} (hs : 1 < re s) :
    riemannCompletedZeta s = mellin zetaKernel₁ (s / 2) := by
  have : 1 / 2 < (s / 2).re := by
    rw [show s / 2 = ↑(2⁻¹ : ℝ) * s by push_cast; rw [mul_comm]; 

Proof state:
s : ℂ
hs : 1 < s.re
⊢ s / 2 = s * 2⁻¹

Next tactic:
rfl
theorem completed_zeta_eq_mellin_of_one_lt_re {s : ℂ} (hs : 1 < re s) :
    riemannCompletedZeta s = mellin zetaKernel₁ (s / 2) := by
  have : 1 / 2 < (s / 2).re := by
    rw [show s / 2 = ↑(2⁻¹ : ℝ) * s by push_cast; rw [mul_comm]; rfl]
    

Proof state:
s : ℂ
hs : 1 < s.re
⊢ 1 / 2 < (↑2⁻¹ * s).re

Next tactic:
rwa [ofReal_mul_re, ← div_eq_inv_mul, div_lt_div_right (zero_lt_two' ℝ)]
theorem completed_zeta_eq_mellin_of_one_lt_re {s : ℂ} (hs : 1 < re s) :
    riemannCompletedZeta s = mellin zetaKernel₁ (s / 2) := by
  have : 1 / 2 < (s / 2).re := by
    rw [show s / 2 = ↑(2⁻¹ : ℝ) * s by push_cast; rw [mul_comm]; rfl]
    rwa [ofReal_mul_re, ← div_eq_inv_mul, div_lt_div_right (zero_lt_two' ℝ)]
  

Proof state:
s : ℂ
hs : 1 < s.re
this : 1 / 2 < (s / 2).re
⊢ riemannCompletedZeta s = mellin zetaKernel₁ (s / 2)

Next tactic:
rw [riemannCompletedZeta, riemannCompletedZeta₀, mellin_zetaKernel₂_eq_of_lt_re this, sub_add,
    sub_sub, ← add_sub]
theorem completed_zeta_eq_mellin_of_one_lt_re {s : ℂ} (hs : 1 < re s) :
    riemannCompletedZeta s = mellin zetaKernel₁ (s / 2) := by
  have : 1 / 2 < (s / 2).re := by
    rw [show s / 2 = ↑(2⁻¹ : ℝ) * s by push_cast; rw [mul_comm]; rfl]
    rwa [ofReal_mul_re, ← div_eq_inv_mul, div_lt_div_right (zero_lt_two' ℝ)]
  rw [riemannCompletedZeta, riemannCompletedZeta₀, mellin_zetaKernel₂_eq_of_lt_re this, sub_add,
    sub_sub, ← add_sub]
  

Proof state:
s : ℂ
hs : 1 < s.re
this : 1 / 2 < (s / 2).re
⊢ mellin zetaKernel₁ (s / 2) + (1 / (2 * (s / 2)) - (1 / (2 * (s / 2) - 1) + (1 / s - 1 / (s - 1)))) =
    mellin zetaKernel₁ (s / 2)

Next tactic:
conv_rhs => rw [← add_zero (mellin zetaKernel₁ <| s / 2)]
theorem completed_zeta_eq_mellin_of_one_lt_re {s : ℂ} (hs : 1 < re s) :
    riemannCompletedZeta s = mellin zetaKernel₁ (s / 2) := by
  have : 1 / 2 < (s / 2).re := by
    rw [show s / 2 = ↑(2⁻¹ : ℝ) * s by push_cast; rw [mul_comm]; rfl]
    rwa [ofReal_mul_re, ← div_eq_inv_mul, div_lt_div_right (zero_lt_two' ℝ)]
  rw [riemannCompletedZeta, riemannCompletedZeta₀, mellin_zetaKernel₂_eq_of_lt_re this, sub_add,
    sub_sub, ← add_sub]
  conv_rhs => 

Proof state:
s : ℂ
hs : 1 < s.re
this : 1 / 2 < (s / 2).re
| mellin zetaKernel₁ (s / 2)

Next tactic:
rw [← add_zero (mellin zetaKernel₁ <| s / 2)]
theorem completed_zeta_eq_mellin_of_one_lt_re {s : ℂ} (hs : 1 < re s) :
    riemannCompletedZeta s = mellin zetaKernel₁ (s / 2) := by
  have : 1 / 2 < (s / 2).re := by
    rw [show s / 2 = ↑(2⁻¹ : ℝ) * s by push_cast; rw [mul_comm]; rfl]
    rwa [ofReal_mul_re, ← div_eq_inv_mul, div_lt_div_right (zero_lt_two' ℝ)]
  rw [riemannCompletedZeta, riemannCompletedZeta₀, mellin_zetaKernel₂_eq_of_lt_re this, sub_add,
    sub_sub, ← add_sub]
  conv_rhs => rw [← add_zero (mellin zetaKernel₁ <| s / 2)]
  

Proof state:
s : ℂ
hs : 1 < s.re
this : 1 / 2 < (s / 2).re
⊢ mellin zetaKernel₁ (s / 2) + (1 / (2 * (s / 2)) - (1 / (2 * (s / 2) - 1) + (1 / s - 1 / (s - 1)))) =
    mellin zetaKernel₁ (s / 2) + 0

Next tactic:
congr 1
theorem completed_zeta_eq_mellin_of_one_lt_re {s : ℂ} (hs : 1 < re s) :
    riemannCompletedZeta s = mellin zetaKernel₁ (s / 2) := by
  have : 1 / 2 < (s / 2).re := by
    rw [show s / 2 = ↑(2⁻¹ : ℝ) * s by push_cast; rw [mul_comm]; rfl]
    rwa [ofReal_mul_re, ← div_eq_inv_mul, div_lt_div_right (zero_lt_two' ℝ)]
  rw [riemannCompletedZeta, riemannCompletedZeta₀, mellin_zetaKernel₂_eq_of_lt_re this, sub_add,
    sub_sub, ← add_sub]
  conv_rhs => rw [← add_zero (mellin zetaKernel₁ <| s / 2)]
  congr 1
  

Proof state:
case e_a
s : ℂ
hs : 1 < s.re
this : 1 / 2 < (s / 2).re
⊢ 1 / (2 * (s / 2)) - (1 / (2 * (s / 2) - 1) + (1 / s - 1 / (s - 1))) = 0

Next tactic:
rw [mul_div_cancel' _ (two_ne_zero' ℂ)]
theorem completed_zeta_eq_mellin_of_one_lt_re {s : ℂ} (hs : 1 < re s) :
    riemannCompletedZeta s = mellin zetaKernel₁ (s / 2) := by
  have : 1 / 2 < (s / 2).re := by
    rw [show s / 2 = ↑(2⁻¹ : ℝ) * s by push_cast; rw [mul_comm]; rfl]
    rwa [ofReal_mul_re, ← div_eq_inv_mul, div_lt_div_right (zero_lt_two' ℝ)]
  rw [riemannCompletedZeta, riemannCompletedZeta₀, mellin_zetaKernel₂_eq_of_lt_re this, sub_add,
    sub_sub, ← add_sub]
  conv_rhs => rw [← add_zero (mellin zetaKernel₁ <| s / 2)]
  congr 1
  rw [mul_div_cancel' _ (two_ne_zero' ℂ)]
  

Proof state:
case e_a
s : ℂ
hs : 1 < s.re
this : 1 / 2 < (s / 2).re
⊢ 1 / s - (1 / (s - 1) + (1 / s - 1 / (s - 1))) = 0

Next tactic:
abel
/-- Auxiliary lemma for `mellin_zetaKernel₁_eq_tsum`, computing the Mellin transform of an
individual term in the series. -/
theorem integral_cpow_mul_exp_neg_pi_mul_sq {s : ℂ} (hs : 0 < s.re) (n : ℕ) :
    ∫ t : ℝ in Ioi 0, (t : ℂ) ^ (s - 1) * rexp (-π * t * ((n : ℝ) + 1) ^ 2) =
      (π : ℂ) ^ (-s) * Complex.Gamma s * (1 / ((n : ℂ) + 1) ^ (2 * s)) := by
  

Proof state:
s : ℂ
hs : 0 < s.re
n : ℕ
⊢ ∫ (t : ℝ) in Ioi 0, ↑t ^ (s - 1) * ↑(rexp (-π * t * (↑n + 1) ^ 2)) =
    ↑π ^ (-s) * Complex.Gamma s * (1 / (↑n + 1) ^ (2 * s))

Next tactic:
rw [Complex.Gamma_eq_integral hs, GammaIntegral_eq_mellin]
/-- Auxiliary lemma for `mellin_zetaKernel₁_eq_tsum`, computing the Mellin transform of an
individual term in the series. -/
theorem integral_cpow_mul_exp_neg_pi_mul_sq {s : ℂ} (hs : 0 < s.re) (n : ℕ) :
    ∫ t : ℝ in Ioi 0, (t : ℂ) ^ (s - 1) * rexp (-π * t * ((n : ℝ) + 1) ^ 2) =
      (π : ℂ) ^ (-s) * Complex.Gamma s * (1 / ((n : ℂ) + 1) ^ (2 * s)) := by
  rw [Complex.Gamma_eq_integral hs, GammaIntegral_eq_mellin]
  

Proof state:
s : ℂ
hs : 0 < s.re
n : ℕ
⊢ ∫ (t : ℝ) in Ioi 0, ↑t ^ (s - 1) * ↑(rexp (-π * t * (↑n + 1) ^ 2)) =
    ↑π ^ (-s) * mellin (fun x => ↑(rexp (-x))) s * (1 / (↑n + 1) ^ (2 * s))

Next tactic:
conv_rhs =>
    congr
    rw [← smul_eq_mul, ← mellin_comp_mul_left _ _ pi_pos]
/-- Auxiliary lemma for `mellin_zetaKernel₁_eq_tsum`, computing the Mellin transform of an
individual term in the series. -/
theorem integral_cpow_mul_exp_neg_pi_mul_sq {s : ℂ} (hs : 0 < s.re) (n : ℕ) :
    ∫ t : ℝ in Ioi 0, (t : ℂ) ^ (s - 1) * rexp (-π * t * ((n : ℝ) + 1) ^ 2) =
      (π : ℂ) ^ (-s) * Complex.Gamma s * (1 / ((n : ℂ) + 1) ^ (2 * s)) := by
  rw [Complex.Gamma_eq_integral hs, GammaIntegral_eq_mellin]
  conv_rhs =>
    

Proof state:
s : ℂ
hs : 0 < s.re
n : ℕ
| ↑π ^ (-s) * mellin (fun x => ↑(rexp (-x))) s * (1 / (↑n + 1) ^ (2 * s))

Next tactic:
congr
    rw [← smul_eq_mul, ← mellin_comp_mul_left _ _ pi_pos]
/-- Auxiliary lemma for `mellin_zetaKernel₁_eq_tsum`, computing the Mellin transform of an
individual term in the series. -/
theorem integral_cpow_mul_exp_neg_pi_mul_sq {s : ℂ} (hs : 0 < s.re) (n : ℕ) :
    ∫ t : ℝ in Ioi 0, (t : ℂ) ^ (s - 1) * rexp (-π * t * ((n : ℝ) + 1) ^ 2) =
      (π : ℂ) ^ (-s) * Complex.Gamma s * (1 / ((n : ℂ) + 1) ^ (2 * s)) := by
  rw [Complex.Gamma_eq_integral hs, GammaIntegral_eq_mellin]
  conv_rhs =>
    

Proof state:
s : ℂ
hs : 0 < s.re
n : ℕ
| ↑π ^ (-s) * mellin (fun x => ↑(rexp (-x))) s * (1 / (↑n + 1) ^ (2 * s))

Next tactic:
congr
/-- Auxiliary lemma for `mellin_zetaKernel₁_eq_tsum`, computing the Mellin transform of an
individual term in the series. -/
theorem integral_cpow_mul_exp_neg_pi_mul_sq {s : ℂ} (hs : 0 < s.re) (n : ℕ) :
    ∫ t : ℝ in Ioi 0, (t : ℂ) ^ (s - 1) * rexp (-π * t * ((n : ℝ) + 1) ^ 2) =
      (π : ℂ) ^ (-s) * Complex.Gamma s * (1 / ((n : ℂ) + 1) ^ (2 * s)) := by
  rw [Complex.Gamma_eq_integral hs, GammaIntegral_eq_mellin]
  conv_rhs =>
    congr
    

Proof state:
case a
s : ℂ
hs : 0 < s.re
n : ℕ
| ↑π ^ (-s) * mellin (fun x => ↑(rexp (-x))) s
case a s : ℂ hs : 0 < s.re n : ℕ | 1 / (↑n + 1) ^ (2 * s)

Next tactic:
rw [← smul_eq_mul, ← mellin_comp_mul_left _ _ pi_pos]
/-- Auxiliary lemma for `mellin_zetaKernel₁_eq_tsum`, computing the Mellin transform of an
individual term in the series. -/
theorem integral_cpow_mul_exp_neg_pi_mul_sq {s : ℂ} (hs : 0 < s.re) (n : ℕ) :
    ∫ t : ℝ in Ioi 0, (t : ℂ) ^ (s - 1) * rexp (-π * t * ((n : ℝ) + 1) ^ 2) =
      (π : ℂ) ^ (-s) * Complex.Gamma s * (1 / ((n : ℂ) + 1) ^ (2 * s)) := by
  rw [Complex.Gamma_eq_integral hs, GammaIntegral_eq_mellin]
  conv_rhs =>
    congr
    rw [← smul_eq_mul, ← mellin_comp_mul_left _ _ pi_pos]
  

Proof state:
s : ℂ
hs : 0 < s.re
n : ℕ
⊢ ∫ (t : ℝ) in Ioi 0, ↑t ^ (s - 1) * ↑(rexp (-π * t * (↑n + 1) ^ 2)) =
    mellin (fun t => ↑(rexp (-(π * t)))) s * (1 / (↑n + 1) ^ (2 * s))

Next tactic:
have : 1 / ((n : ℂ) + 1) ^ (2 * s) = (((n + 1) ^ (2 : ℝ) : ℝ) : ℂ) ^ (-s) := by
    rw [(by norm_num : (n : ℂ) + 1 = ↑((n : ℝ) + 1)), (by norm_num : 2 * s = ↑(2 : ℝ) * s),
      cpow_mul_ofReal_nonneg, one_div, cpow_neg]
    rw [← Nat.cast_succ]
    exact Nat.cast_nonneg _
/-- Auxiliary lemma for `mellin_zetaKernel₁_eq_tsum`, computing the Mellin transform of an
individual term in the series. -/
theorem integral_cpow_mul_exp_neg_pi_mul_sq {s : ℂ} (hs : 0 < s.re) (n : ℕ) :
    ∫ t : ℝ in Ioi 0, (t : ℂ) ^ (s - 1) * rexp (-π * t * ((n : ℝ) + 1) ^ 2) =
      (π : ℂ) ^ (-s) * Complex.Gamma s * (1 / ((n : ℂ) + 1) ^ (2 * s)) := by
  rw [Complex.Gamma_eq_integral hs, GammaIntegral_eq_mellin]
  conv_rhs =>
    congr
    rw [← smul_eq_mul, ← mellin_comp_mul_left _ _ pi_pos]
  have : 1 / ((n : ℂ) + 1) ^ (2 * s) = (((n + 1) ^ (2 : ℝ) : ℝ) : ℂ) ^ (-s) := by
    

Proof state:
s : ℂ
hs : 0 < s.re
n : ℕ
⊢ 1 / (↑n + 1) ^ (2 * s) = ↑((↑n + 1) ^ 2) ^ (-s)

Next tactic:
rw [(by norm_num : (n : ℂ) + 1 = ↑((n : ℝ) + 1)), (by norm_num : 2 * s = ↑(2 : ℝ) * s),
      cpow_mul_ofReal_nonneg, one_div, cpow_neg]
/-- Auxiliary lemma for `mellin_zetaKernel₁_eq_tsum`, computing the Mellin transform of an
individual term in the series. -/
theorem integral_cpow_mul_exp_neg_pi_mul_sq {s : ℂ} (hs : 0 < s.re) (n : ℕ) :
    ∫ t : ℝ in Ioi 0, (t : ℂ) ^ (s - 1) * rexp (-π * t * ((n : ℝ) + 1) ^ 2) =
      (π : ℂ) ^ (-s) * Complex.Gamma s * (1 / ((n : ℂ) + 1) ^ (2 * s)) := by
  rw [Complex.Gamma_eq_integral hs, GammaIntegral_eq_mellin]
  conv_rhs =>
    congr
    rw [← smul_eq_mul, ← mellin_comp_mul_left _ _ pi_pos]
  have : 1 / ((n : ℂ) + 1) ^ (2 * s) = (((n + 1) ^ (2 : ℝ) : ℝ) : ℂ) ^ (-s) := by
    rw [(by 

Proof state:
s : ℂ
hs : 0 < s.re
n : ℕ
⊢ ↑n + 1 = ↑(↑n + 1)

Next tactic:
norm_num