l3lab/ntp-mathlib huggingface dataset:
/-- Bound for `zetaKernel₁` for `t → 0`. -/
theorem isBigO_zero_zetaKernel₁ : IsBigO (𝓝[>] 0) zetaKernel₁ fun t => t ^ (-(1 / 2) : ℝ) := by
  have : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => ((1 / sqrt t - 1) / 2 : ℂ) := by
    refine
      eventuallyEq_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t h => ?_
    rw [Pi.add_apply, zetaKernel₂, Pi.add_apply, indicator_of_mem h]
    

Proof state:
t : ℝ
h : t ∈ Ioc 0 1
⊢ zetaKernel₁ t = zetaKernel₁ t + (1 - 1 / ↑(sqrt t)) / 2 + (1 / ↑(sqrt t) - 1) / 2

Next tactic:
ring
/-- Bound for `zetaKernel₁` for `t → 0`. -/
theorem isBigO_zero_zetaKernel₁ : IsBigO (𝓝[>] 0) zetaKernel₁ fun t => t ^ (-(1 / 2) : ℝ) := by
  have : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => ((1 / sqrt t - 1) / 2 : ℂ) := by
    refine
      eventuallyEq_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t h => ?_
    rw [Pi.add_apply, zetaKernel₂, Pi.add_apply, indicator_of_mem h]
    ring
  

Proof state:
this : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => (1 / ↑(sqrt t) - 1) / 2
⊢ zetaKernel₁ =O[𝓝[>] 0] fun t => t ^ (-(1 / 2))

Next tactic:
refine ((isBigO_zero_zetaKernel₂_rpow _).add ?_).congr' this.symm (EventuallyEq.refl _ _)
/-- Bound for `zetaKernel₁` for `t → 0`. -/
theorem isBigO_zero_zetaKernel₁ : IsBigO (𝓝[>] 0) zetaKernel₁ fun t => t ^ (-(1 / 2) : ℝ) := by
  have : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => ((1 / sqrt t - 1) / 2 : ℂ) := by
    refine
      eventuallyEq_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t h => ?_
    rw [Pi.add_apply, zetaKernel₂, Pi.add_apply, indicator_of_mem h]
    ring
  refine ((isBigO_zero_zetaKernel₂_rpow _).add ?_).congr' this.symm (EventuallyEq.refl _ _)
  

Proof state:
this : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => (1 / ↑(sqrt t) - 1) / 2
⊢ (fun x => (fun t => (1 / ↑(sqrt t) - 1) / 2) x) =O[𝓝[>] 0] fun t => t ^ (-(1 / 2))

Next tactic:
simp_rw [sub_div]
/-- Bound for `zetaKernel₁` for `t → 0`. -/
theorem isBigO_zero_zetaKernel₁ : IsBigO (𝓝[>] 0) zetaKernel₁ fun t => t ^ (-(1 / 2) : ℝ) := by
  have : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => ((1 / sqrt t - 1) / 2 : ℂ) := by
    refine
      eventuallyEq_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t h => ?_
    rw [Pi.add_apply, zetaKernel₂, Pi.add_apply, indicator_of_mem h]
    ring
  refine ((isBigO_zero_zetaKernel₂_rpow _).add ?_).congr' this.symm (EventuallyEq.refl _ _)
  simp_rw [sub_div]
  

Proof state:
this : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => (1 / ↑(sqrt t) - 1) / 2
⊢ (fun x => 1 / ↑(sqrt x) / 2 - 1 / 2) =O[𝓝[>] 0] fun t => t ^ (-(1 / 2))

Next tactic:
apply IsBigO.sub
/-- Bound for `zetaKernel₁` for `t → 0`. -/
theorem isBigO_zero_zetaKernel₁ : IsBigO (𝓝[>] 0) zetaKernel₁ fun t => t ^ (-(1 / 2) : ℝ) := by
  have : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => ((1 / sqrt t - 1) / 2 : ℂ) := by
    refine
      eventuallyEq_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t h => ?_
    rw [Pi.add_apply, zetaKernel₂, Pi.add_apply, indicator_of_mem h]
    ring
  refine ((isBigO_zero_zetaKernel₂_rpow _).add ?_).congr' this.symm (EventuallyEq.refl _ _)
  simp_rw [sub_div]
  apply IsBigO.sub
  · 

Proof state:
case h₁
this : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => (1 / ↑(sqrt t) - 1) / 2
⊢ (fun x => 1 / ↑(sqrt x) / 2) =O[𝓝[>] 0] fun t => t ^ (-(1 / 2))

Next tactic:
apply IsBigO.of_norm_left
/-- Bound for `zetaKernel₁` for `t → 0`. -/
theorem isBigO_zero_zetaKernel₁ : IsBigO (𝓝[>] 0) zetaKernel₁ fun t => t ^ (-(1 / 2) : ℝ) := by
  have : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => ((1 / sqrt t - 1) / 2 : ℂ) := by
    refine
      eventuallyEq_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t h => ?_
    rw [Pi.add_apply, zetaKernel₂, Pi.add_apply, indicator_of_mem h]
    ring
  refine ((isBigO_zero_zetaKernel₂_rpow _).add ?_).congr' this.symm (EventuallyEq.refl _ _)
  simp_rw [sub_div]
  apply IsBigO.sub
  · apply IsBigO.of_norm_left
    

Proof state:
case h₁.a
this : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => (1 / ↑(sqrt t) - 1) / 2
⊢ (fun x => ‖1 / ↑(sqrt x) / 2‖) =O[𝓝[>] 0] fun t => t ^ (-(1 / 2))

Next tactic:
simp_rw [norm_div, norm_one, div_eq_mul_inv, one_mul, mul_comm _ ‖(2 : ℂ)‖⁻¹]
/-- Bound for `zetaKernel₁` for `t → 0`. -/
theorem isBigO_zero_zetaKernel₁ : IsBigO (𝓝[>] 0) zetaKernel₁ fun t => t ^ (-(1 / 2) : ℝ) := by
  have : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => ((1 / sqrt t - 1) / 2 : ℂ) := by
    refine
      eventuallyEq_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t h => ?_
    rw [Pi.add_apply, zetaKernel₂, Pi.add_apply, indicator_of_mem h]
    ring
  refine ((isBigO_zero_zetaKernel₂_rpow _).add ?_).congr' this.symm (EventuallyEq.refl _ _)
  simp_rw [sub_div]
  apply IsBigO.sub
  · apply IsBigO.of_norm_left
    simp_rw [norm_div, norm_one, div_eq_mul_inv, one_mul, mul_comm _ ‖(2 : ℂ)‖⁻¹]
    

Proof state:
case h₁.a
this : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => (1 / ↑(sqrt t) - 1) / 2
⊢ (fun x => ‖2‖⁻¹ * ‖↑(sqrt x)‖⁻¹) =O[𝓝[>] 0] fun t => t ^ (-2⁻¹)

Next tactic:
refine ((isBigO_refl _ _).congr' (EventuallyEq.refl _ _)
        (eventuallyEq_of_mem self_mem_nhdsWithin fun x hx => ?_)).const_mul_left _
/-- Bound for `zetaKernel₁` for `t → 0`. -/
theorem isBigO_zero_zetaKernel₁ : IsBigO (𝓝[>] 0) zetaKernel₁ fun t => t ^ (-(1 / 2) : ℝ) := by
  have : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => ((1 / sqrt t - 1) / 2 : ℂ) := by
    refine
      eventuallyEq_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t h => ?_
    rw [Pi.add_apply, zetaKernel₂, Pi.add_apply, indicator_of_mem h]
    ring
  refine ((isBigO_zero_zetaKernel₂_rpow _).add ?_).congr' this.symm (EventuallyEq.refl _ _)
  simp_rw [sub_div]
  apply IsBigO.sub
  · apply IsBigO.of_norm_left
    simp_rw [norm_div, norm_one, div_eq_mul_inv, one_mul, mul_comm _ ‖(2 : ℂ)‖⁻¹]
    refine ((isBigO_refl _ _).congr' (EventuallyEq.refl _ _)
        (eventuallyEq_of_mem self_mem_nhdsWithin fun x hx => ?_)).const_mul_left _
    

Proof state:
case h₁.a
this : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => (1 / ↑(sqrt t) - 1) / 2
x : ℝ
hx : x ∈ Ioi 0
⊢ ‖↑(sqrt x)‖⁻¹ = x ^ (-2⁻¹)

Next tactic:
rw [Complex.norm_eq_abs, abs_ofReal, abs_of_nonneg (sqrt_nonneg _), sqrt_eq_rpow,
      rpow_neg (le_of_lt hx), one_div]
/-- Bound for `zetaKernel₁` for `t → 0`. -/
theorem isBigO_zero_zetaKernel₁ : IsBigO (𝓝[>] 0) zetaKernel₁ fun t => t ^ (-(1 / 2) : ℝ) := by
  have : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => ((1 / sqrt t - 1) / 2 : ℂ) := by
    refine
      eventuallyEq_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t h => ?_
    rw [Pi.add_apply, zetaKernel₂, Pi.add_apply, indicator_of_mem h]
    ring
  refine ((isBigO_zero_zetaKernel₂_rpow _).add ?_).congr' this.symm (EventuallyEq.refl _ _)
  simp_rw [sub_div]
  apply IsBigO.sub
  · apply IsBigO.of_norm_left
    simp_rw [norm_div, norm_one, div_eq_mul_inv, one_mul, mul_comm _ ‖(2 : ℂ)‖⁻¹]
    refine ((isBigO_refl _ _).congr' (EventuallyEq.refl _ _)
        (eventuallyEq_of_mem self_mem_nhdsWithin fun x hx => ?_)).const_mul_left _
    rw [Complex.norm_eq_abs, abs_ofReal, abs_of_nonneg (sqrt_nonneg _), sqrt_eq_rpow,
      rpow_neg (le_of_lt hx), one_div]
  · 

Proof state:
case h₂
this : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => (1 / ↑(sqrt t) - 1) / 2
⊢ (fun x => 1 / 2) =O[𝓝[>] 0] fun t => t ^ (-(1 / 2))

Next tactic:
refine isBigO_iff.mpr ⟨‖(1 / 2 : ℂ)‖, ?_⟩
/-- Bound for `zetaKernel₁` for `t → 0`. -/
theorem isBigO_zero_zetaKernel₁ : IsBigO (𝓝[>] 0) zetaKernel₁ fun t => t ^ (-(1 / 2) : ℝ) := by
  have : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => ((1 / sqrt t - 1) / 2 : ℂ) := by
    refine
      eventuallyEq_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t h => ?_
    rw [Pi.add_apply, zetaKernel₂, Pi.add_apply, indicator_of_mem h]
    ring
  refine ((isBigO_zero_zetaKernel₂_rpow _).add ?_).congr' this.symm (EventuallyEq.refl _ _)
  simp_rw [sub_div]
  apply IsBigO.sub
  · apply IsBigO.of_norm_left
    simp_rw [norm_div, norm_one, div_eq_mul_inv, one_mul, mul_comm _ ‖(2 : ℂ)‖⁻¹]
    refine ((isBigO_refl _ _).congr' (EventuallyEq.refl _ _)
        (eventuallyEq_of_mem self_mem_nhdsWithin fun x hx => ?_)).const_mul_left _
    rw [Complex.norm_eq_abs, abs_ofReal, abs_of_nonneg (sqrt_nonneg _), sqrt_eq_rpow,
      rpow_neg (le_of_lt hx), one_div]
  · refine isBigO_iff.mpr ⟨‖(1 / 2 : ℂ)‖, ?_⟩
    

Proof state:
case h₂
this : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => (1 / ↑(sqrt t) - 1) / 2
⊢ ∀ᶠ (x : ℝ) in 𝓝[>] 0, ‖1 / 2‖ ≤ ‖1 / 2‖ * ‖x ^ (-(1 / 2))‖

Next tactic:
refine eventually_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t ht => ?_
/-- Bound for `zetaKernel₁` for `t → 0`. -/
theorem isBigO_zero_zetaKernel₁ : IsBigO (𝓝[>] 0) zetaKernel₁ fun t => t ^ (-(1 / 2) : ℝ) := by
  have : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => ((1 / sqrt t - 1) / 2 : ℂ) := by
    refine
      eventuallyEq_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t h => ?_
    rw [Pi.add_apply, zetaKernel₂, Pi.add_apply, indicator_of_mem h]
    ring
  refine ((isBigO_zero_zetaKernel₂_rpow _).add ?_).congr' this.symm (EventuallyEq.refl _ _)
  simp_rw [sub_div]
  apply IsBigO.sub
  · apply IsBigO.of_norm_left
    simp_rw [norm_div, norm_one, div_eq_mul_inv, one_mul, mul_comm _ ‖(2 : ℂ)‖⁻¹]
    refine ((isBigO_refl _ _).congr' (EventuallyEq.refl _ _)
        (eventuallyEq_of_mem self_mem_nhdsWithin fun x hx => ?_)).const_mul_left _
    rw [Complex.norm_eq_abs, abs_ofReal, abs_of_nonneg (sqrt_nonneg _), sqrt_eq_rpow,
      rpow_neg (le_of_lt hx), one_div]
  · refine isBigO_iff.mpr ⟨‖(1 / 2 : ℂ)‖, ?_⟩
    refine eventually_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t ht => ?_
    

Proof state:
case h₂
this : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => (1 / ↑(sqrt t) - 1) / 2
t : ℝ
ht : t ∈ Ioc 0 1
⊢ ‖1 / 2‖ ≤ ‖1 / 2‖ * ‖t ^ (-(1 / 2))‖

Next tactic:
refine le_mul_of_one_le_right (norm_nonneg _) ?_
/-- Bound for `zetaKernel₁` for `t → 0`. -/
theorem isBigO_zero_zetaKernel₁ : IsBigO (𝓝[>] 0) zetaKernel₁ fun t => t ^ (-(1 / 2) : ℝ) := by
  have : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => ((1 / sqrt t - 1) / 2 : ℂ) := by
    refine
      eventuallyEq_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t h => ?_
    rw [Pi.add_apply, zetaKernel₂, Pi.add_apply, indicator_of_mem h]
    ring
  refine ((isBigO_zero_zetaKernel₂_rpow _).add ?_).congr' this.symm (EventuallyEq.refl _ _)
  simp_rw [sub_div]
  apply IsBigO.sub
  · apply IsBigO.of_norm_left
    simp_rw [norm_div, norm_one, div_eq_mul_inv, one_mul, mul_comm _ ‖(2 : ℂ)‖⁻¹]
    refine ((isBigO_refl _ _).congr' (EventuallyEq.refl _ _)
        (eventuallyEq_of_mem self_mem_nhdsWithin fun x hx => ?_)).const_mul_left _
    rw [Complex.norm_eq_abs, abs_ofReal, abs_of_nonneg (sqrt_nonneg _), sqrt_eq_rpow,
      rpow_neg (le_of_lt hx), one_div]
  · refine isBigO_iff.mpr ⟨‖(1 / 2 : ℂ)‖, ?_⟩
    refine eventually_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t ht => ?_
    refine le_mul_of_one_le_right (norm_nonneg _) ?_
    

Proof state:
case h₂
this : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => (1 / ↑(sqrt t) - 1) / 2
t : ℝ
ht : t ∈ Ioc 0 1
⊢ 1 ≤ ‖t ^ (-(1 / 2))‖

Next tactic:
rw [norm_of_nonneg (rpow_nonneg_of_nonneg ht.1.le _), rpow_neg ht.1.le]
/-- Bound for `zetaKernel₁` for `t → 0`. -/
theorem isBigO_zero_zetaKernel₁ : IsBigO (𝓝[>] 0) zetaKernel₁ fun t => t ^ (-(1 / 2) : ℝ) := by
  have : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => ((1 / sqrt t - 1) / 2 : ℂ) := by
    refine
      eventuallyEq_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t h => ?_
    rw [Pi.add_apply, zetaKernel₂, Pi.add_apply, indicator_of_mem h]
    ring
  refine ((isBigO_zero_zetaKernel₂_rpow _).add ?_).congr' this.symm (EventuallyEq.refl _ _)
  simp_rw [sub_div]
  apply IsBigO.sub
  · apply IsBigO.of_norm_left
    simp_rw [norm_div, norm_one, div_eq_mul_inv, one_mul, mul_comm _ ‖(2 : ℂ)‖⁻¹]
    refine ((isBigO_refl _ _).congr' (EventuallyEq.refl _ _)
        (eventuallyEq_of_mem self_mem_nhdsWithin fun x hx => ?_)).const_mul_left _
    rw [Complex.norm_eq_abs, abs_ofReal, abs_of_nonneg (sqrt_nonneg _), sqrt_eq_rpow,
      rpow_neg (le_of_lt hx), one_div]
  · refine isBigO_iff.mpr ⟨‖(1 / 2 : ℂ)‖, ?_⟩
    refine eventually_of_mem (Ioc_mem_nhdsWithin_Ioi <| left_mem_Ico.mpr zero_lt_one) fun t ht => ?_
    refine le_mul_of_one_le_right (norm_nonneg _) ?_
    rw [norm_of_nonneg (rpow_nonneg_of_nonneg ht.1.le _), rpow_neg ht.1.le]
    

Proof state:
case h₂
this : zetaKernel₁ =ᶠ[𝓝[>] 0] zetaKernel₂ + fun t => (1 / ↑(sqrt t) - 1) / 2
t : ℝ
ht : t ∈ Ioc 0 1
⊢ 1 ≤ (t ^ (1 / 2))⁻¹

Next tactic:
exact one_le_inv (rpow_pos_of_pos ht.1 _) (rpow_le_one ht.1.le ht.2 one_half_pos.le)
/-- The completed Riemann zeta function `Λ(s)` is differentiable away from `s = 0` and `s = 1`
(where it has simple poles). -/
theorem differentiableAt_completed_zeta {s : ℂ} (hs : s ≠ 0) (hs' : s ≠ 1) :
    DifferentiableAt ℂ riemannCompletedZeta s := by
  

Proof state:
s : ℂ
hs : s ≠ 0
hs' : s ≠ 1
⊢ DifferentiableAt ℂ riemannCompletedZeta s

Next tactic:
refine (differentiable_completed_zeta₀.differentiableAt.sub ?_).add ?_
/-- The completed Riemann zeta function `Λ(s)` is differentiable away from `s = 0` and `s = 1`
(where it has simple poles). -/
theorem differentiableAt_completed_zeta {s : ℂ} (hs : s ≠ 0) (hs' : s ≠ 1) :
    DifferentiableAt ℂ riemannCompletedZeta s := by
  refine (differentiable_completed_zeta₀.differentiableAt.sub ?_).add ?_
  · 

Proof state:
case refine_1
s : ℂ
hs : s ≠ 0
hs' : s ≠ 1
⊢ DifferentiableAt ℂ (fun y => 1 / y) s

Next tactic:
exact (Differentiable.differentiableAt (differentiable_const _)).div differentiableAt_id hs
/-- The completed Riemann zeta function `Λ(s)` is differentiable away from `s = 0` and `s = 1`
(where it has simple poles). -/
theorem differentiableAt_completed_zeta {s : ℂ} (hs : s ≠ 0) (hs' : s ≠ 1) :
    DifferentiableAt ℂ riemannCompletedZeta s := by
  refine (differentiable_completed_zeta₀.differentiableAt.sub ?_).add ?_
  · exact (Differentiable.differentiableAt (differentiable_const _)).div differentiableAt_id hs
  · 

Proof state:
case refine_2
s : ℂ
hs : s ≠ 0
hs' : s ≠ 1
⊢ DifferentiableAt ℂ (fun y => 1 / (y - 1)) s

Next tactic:
refine (differentiable_const _).differentiableAt.div ?_ (sub_ne_zero.mpr hs')
/-- The completed Riemann zeta function `Λ(s)` is differentiable away from `s = 0` and `s = 1`
(where it has simple poles). -/
theorem differentiableAt_completed_zeta {s : ℂ} (hs : s ≠ 0) (hs' : s ≠ 1) :
    DifferentiableAt ℂ riemannCompletedZeta s := by
  refine (differentiable_completed_zeta₀.differentiableAt.sub ?_).add ?_
  · exact (Differentiable.differentiableAt (differentiable_const _)).div differentiableAt_id hs
  · refine (differentiable_const _).differentiableAt.div ?_ (sub_ne_zero.mpr hs')
    

Proof state:
case refine_2
s : ℂ
hs : s ≠ 0
hs' : s ≠ 1
⊢ DifferentiableAt ℂ (fun y => y - 1) s

Next tactic:
exact differentiableAt_id.sub (differentiableAt_const _)
/-- The Riemann zeta function is differentiable away from `s = 1`. -/
theorem differentiableAt_riemannZeta {s : ℂ} (hs' : s ≠ 1) : DifferentiableAt ℂ riemannZeta s := by
  /- First claim: the result holds at `t` for `t ≠ 0`. Note we will need to use this for the case
    `s = 0` also, as a hypothesis for the removable-singularity criterion. -/
  

Proof state:
s : ℂ
hs' : s ≠ 1
⊢ DifferentiableAt ℂ riemannZeta s

Next tactic:
have c1 : ∀ (t : ℂ) (_ : t ≠ 0) (_ : t ≠ 1),
      DifferentiableAt ℂ
        (fun u : ℂ => (π : ℂ) ^ (u / 2) * riemannCompletedZeta u / Gamma (u / 2)) t := by
    intro t ht ht'
    apply DifferentiableAt.mul
    · refine (DifferentiableAt.const_cpow ?_ ?_).mul (differentiableAt_completed_zeta ht ht')
      · exact DifferentiableAt.div_const differentiableAt_id _
      · exact Or.inl (ofReal_ne_zero.mpr pi_pos.ne')
    · refine differentiable_one_div_Gamma.differentiableAt.comp t ?_
      exact DifferentiableAt.div_const differentiableAt_id _
/-- The Riemann zeta function is differentiable away from `s = 1`. -/
theorem differentiableAt_riemannZeta {s : ℂ} (hs' : s ≠ 1) : DifferentiableAt ℂ riemannZeta s := by
  /- First claim: the result holds at `t` for `t ≠ 0`. Note we will need to use this for the case
    `s = 0` also, as a hypothesis for the removable-singularity criterion. -/
  have c1 : ∀ (t : ℂ) (_ : t ≠ 0) (_ : t ≠ 1),
      DifferentiableAt ℂ
        (fun u : ℂ => (π : ℂ) ^ (u / 2) * riemannCompletedZeta u / Gamma (u / 2)) t := by
    

Proof state:
s : ℂ
hs' : s ≠ 1
⊢ ∀ (t : ℂ),
    t ≠ 0 → t ≠ 1 → DifferentiableAt ℂ (fun u => ↑π ^ (u / 2) * riemannCompletedZeta u / Complex.Gamma (u / 2)) t

Next tactic:
intro t ht ht'
/-- The Riemann zeta function is differentiable away from `s = 1`. -/
theorem differentiableAt_riemannZeta {s : ℂ} (hs' : s ≠ 1) : DifferentiableAt ℂ riemannZeta s := by
  /- First claim: the result holds at `t` for `t ≠ 0`. Note we will need to use this for the case
    `s = 0` also, as a hypothesis for the removable-singularity criterion. -/
  have c1 : ∀ (t : ℂ) (_ : t ≠ 0) (_ : t ≠ 1),
      DifferentiableAt ℂ
        (fun u : ℂ => (π : ℂ) ^ (u / 2) * riemannCompletedZeta u / Gamma (u / 2)) t := by
    intro t ht ht'
    

Proof state:
s : ℂ
hs' : s ≠ 1
t : ℂ
ht : t ≠ 0
ht' : t ≠ 1
⊢ DifferentiableAt ℂ (fun u => ↑π ^ (u / 2) * riemannCompletedZeta u / Complex.Gamma (u / 2)) t

Next tactic:
apply DifferentiableAt.mul
/-- The Riemann zeta function is differentiable away from `s = 1`. -/
theorem differentiableAt_riemannZeta {s : ℂ} (hs' : s ≠ 1) : DifferentiableAt ℂ riemannZeta s := by
  /- First claim: the result holds at `t` for `t ≠ 0`. Note we will need to use this for the case
    `s = 0` also, as a hypothesis for the removable-singularity criterion. -/
  have c1 : ∀ (t : ℂ) (_ : t ≠ 0) (_ : t ≠ 1),
      DifferentiableAt ℂ
        (fun u : ℂ => (π : ℂ) ^ (u / 2) * riemannCompletedZeta u / Gamma (u / 2)) t := by
    intro t ht ht'
    apply DifferentiableAt.mul
    · 

Proof state:
case ha
s : ℂ
hs' : s ≠ 1
t : ℂ
ht : t ≠ 0
ht' : t ≠ 1
⊢ DifferentiableAt ℂ (fun y => ↑π ^ (y / 2) * riemannCompletedZeta y) t

Next tactic:
refine (DifferentiableAt.const_cpow ?_ ?_).mul (differentiableAt_completed_zeta ht ht')
/-- The Riemann zeta function is differentiable away from `s = 1`. -/
theorem differentiableAt_riemannZeta {s : ℂ} (hs' : s ≠ 1) : DifferentiableAt ℂ riemannZeta s := by
  /- First claim: the result holds at `t` for `t ≠ 0`. Note we will need to use this for the case
    `s = 0` also, as a hypothesis for the removable-singularity criterion. -/
  have c1 : ∀ (t : ℂ) (_ : t ≠ 0) (_ : t ≠ 1),
      DifferentiableAt ℂ
        (fun u : ℂ => (π : ℂ) ^ (u / 2) * riemannCompletedZeta u / Gamma (u / 2)) t := by
    intro t ht ht'
    apply DifferentiableAt.mul
    · refine (DifferentiableAt.const_cpow ?_ ?_).mul (differentiableAt_completed_zeta ht ht')
      · 

Proof state:
case ha.refine_1
s : ℂ
hs' : s ≠ 1
t : ℂ
ht : t ≠ 0
ht' : t ≠ 1
⊢ DifferentiableAt ℂ (fun y => y / 2) t

Next tactic:
exact DifferentiableAt.div_const differentiableAt_id _
/-- The Riemann zeta function is differentiable away from `s = 1`. -/
theorem differentiableAt_riemannZeta {s : ℂ} (hs' : s ≠ 1) : DifferentiableAt ℂ riemannZeta s := by
  /- First claim: the result holds at `t` for `t ≠ 0`. Note we will need to use this for the case
    `s = 0` also, as a hypothesis for the removable-singularity criterion. -/
  have c1 : ∀ (t : ℂ) (_ : t ≠ 0) (_ : t ≠ 1),
      DifferentiableAt ℂ
        (fun u : ℂ => (π : ℂ) ^ (u / 2) * riemannCompletedZeta u / Gamma (u / 2)) t := by
    intro t ht ht'
    apply DifferentiableAt.mul
    · refine (DifferentiableAt.const_cpow ?_ ?_).mul (differentiableAt_completed_zeta ht ht')
      · exact DifferentiableAt.div_const differentiableAt_id _
      · 

Proof state:
case ha.refine_2
s : ℂ
hs' : s ≠ 1
t : ℂ
ht : t ≠ 0
ht' : t ≠ 1
⊢ ↑π ≠ 0 ∨ t / 2 ≠ 0

Next tactic:
exact Or.inl (ofReal_ne_zero.mpr pi_pos.ne')
/-- The Riemann zeta function is differentiable away from `s = 1`. -/
theorem differentiableAt_riemannZeta {s : ℂ} (hs' : s ≠ 1) : DifferentiableAt ℂ riemannZeta s := by
  /- First claim: the result holds at `t` for `t ≠ 0`. Note we will need to use this for the case
    `s = 0` also, as a hypothesis for the removable-singularity criterion. -/
  have c1 : ∀ (t : ℂ) (_ : t ≠ 0) (_ : t ≠ 1),
      DifferentiableAt ℂ
        (fun u : ℂ => (π : ℂ) ^ (u / 2) * riemannCompletedZeta u / Gamma (u / 2)) t := by
    intro t ht ht'
    apply DifferentiableAt.mul
    · refine (DifferentiableAt.const_cpow ?_ ?_).mul (differentiableAt_completed_zeta ht ht')
      · exact DifferentiableAt.div_const differentiableAt_id _
      · exact Or.inl (ofReal_ne_zero.mpr pi_pos.ne')
    · 

Proof state:
case hb
s : ℂ
hs' : s ≠ 1
t : ℂ
ht : t ≠ 0
ht' : t ≠ 1
⊢ DifferentiableAt ℂ (fun y => (Complex.Gamma (y / 2))⁻¹) t

Next tactic:
refine differentiable_one_div_Gamma.differentiableAt.comp t ?_
/-- The Riemann zeta function is differentiable away from `s = 1`. -/
theorem differentiableAt_riemannZeta {s : ℂ} (hs' : s ≠ 1) : DifferentiableAt ℂ riemannZeta s := by
  /- First claim: the result holds at `t` for `t ≠ 0`. Note we will need to use this for the case
    `s = 0` also, as a hypothesis for the removable-singularity criterion. -/
  have c1 : ∀ (t : ℂ) (_ : t ≠ 0) (_ : t ≠ 1),
      DifferentiableAt ℂ
        (fun u : ℂ => (π : ℂ) ^ (u / 2) * riemannCompletedZeta u / Gamma (u / 2)) t := by
    intro t ht ht'
    apply DifferentiableAt.mul
    · refine (DifferentiableAt.const_cpow ?_ ?_).mul (differentiableAt_completed_zeta ht ht')
      · exact DifferentiableAt.div_const differentiableAt_id _
      · exact Or.inl (ofReal_ne_zero.mpr pi_pos.ne')
    · refine differentiable_one_div_Gamma.differentiableAt.comp t ?_
      

Proof state:
case hb
s : ℂ
hs' : s ≠ 1
t : ℂ
ht : t ≠ 0
ht' : t ≠ 1
⊢ DifferentiableAt ℂ (fun y => y / 2) t

Next tactic:
exact DifferentiableAt.div_const differentiableAt_id _
/-- The Riemann zeta function is differentiable away from `s = 1`. -/
theorem differentiableAt_riemannZeta {s : ℂ} (hs' : s ≠ 1) : DifferentiableAt ℂ riemannZeta s := by
  /- First claim: the result holds at `t` for `t ≠ 0`. Note we will need to use this for the case
    `s = 0` also, as a hypothesis for the removable-singularity criterion. -/
  have c1 : ∀ (t : ℂ) (_ : t ≠ 0) (_ : t ≠ 1),
      DifferentiableAt ℂ
        (fun u : ℂ => (π : ℂ) ^ (u / 2) * riemannCompletedZeta u / Gamma (u / 2)) t := by
    intro t ht ht'
    apply DifferentiableAt.mul
    · refine (DifferentiableAt.const_cpow ?_ ?_).mul (differentiableAt_completed_zeta ht ht')
      · exact DifferentiableAt.div_const differentiableAt_id _
      · exact Or.inl (ofReal_ne_zero.mpr pi_pos.ne')
    · refine differentiable_one_div_Gamma.differentiableAt.comp t ?_
      exact DifferentiableAt.div_const differentiableAt_id _
  -- Second claim: the limit at `s = 0` exists and is equal to `-1 / 2`.
  have c2 : Tendsto (fun s : ℂ => (π : ℂ) ^ (s / 2) * riemannCompletedZeta s / Gamma (s / 2))
      (𝓝[≠] 0) (𝓝 <| -1 / 2) := by
    

Proof state:
s : ℂ
hs' : s ≠ 1
c1 :
  ∀ (t : ℂ),
    t ≠ 0 → t ≠ 1 → DifferentiableAt ℂ (fun u => ↑π ^ (u / 2) * riemannCompletedZeta u / Complex.Gamma (u / 2)) t
⊢ Tendsto (fun s => ↑π ^ (s / 2) * riemannCompletedZeta s / Complex.Gamma (s / 2)) (𝓝[≠] 0) (𝓝 (-1 / 2))

Next tactic:
have h1 : Tendsto (fun z : ℂ => (π : ℂ) ^ (z / 2)) (𝓝 0) (𝓝 1) := by
      convert (ContinuousAt.comp (f := fun z => z/2)
        (continuousAt_const_cpow (ofReal_ne_zero.mpr pi_pos.ne')) ?_).tendsto using 2
      · simp_rw [Function.comp_apply, zero_div, cpow_zero]
      · exact continuousAt_id.div continuousAt_const two_ne_zero