Theorem: Complex.tsum_exp_neg_quadratic
File: Mathlib/Analysis/SpecialFunctions/Gaussian/PoissonSummation.lean

tactic: let f : ℝ → ℂ := fun x ↦ cexp (-π * a * x ^ 2 + 2 * π * b * x)
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) =
    1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2)
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) =
    1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2)

tactic: have hFf : 𝓕 f = fun x : ℝ ↦ 1 / a ^ (1 / 2 : ℂ) * cexp (-π / a * (x + I * b) ^ 2) :=
  fourierIntegral_gaussian_pi' ha b
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) =
    1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2)
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) =
    1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2)

tactic: have h1 : 0 < (↑π * a).re := by
  rw [re_ofReal_mul]
  exact mul_pos pi_pos ha
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) =
    1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2)
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) =
    1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2)

tactic: have h2 : 0 < (↑π / a).re := by
  rw [div_eq_mul_inv, re_ofReal_mul, inv_re]
  refine mul_pos pi_pos (div_pos ha <| normSq_pos.mpr ?_)
  contrapose! ha
  rw [ha, zero_re]
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) =
    1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2)
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) =
    1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2)

tactic: have f_bd : f =O[cocompact ℝ] (fun x => |x| ^ (-2 : ℝ)) := by
  convert (cexp_neg_quadratic_isLittleO_abs_rpow_cocompact ?_ _ (-2)).isBigO
  rwa [neg_mul, neg_re, neg_lt_zero]
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) =
    1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2)
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) =
    1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2)

tactic: have Ff_bd : (𝓕 f) =O[cocompact ℝ] (fun x => |x| ^ (-2 : ℝ)) := by
  rw [hFf]
  have : ∀ (x : ℝ), -↑π / a * (↑x + I * b) ^ 2 =
      -↑π / a * x ^ 2 + (-2 * π * I * b) / a * x + π * b ^ 2 / a := by
    intro x; ring_nf; rw [I_sq]; ring
  simp_rw [this]
  conv => enter [2, x]; rw [Complex.exp_add, ← mul_assoc _ _ (Complex.exp _), mul_comm]
  refine ((cexp_neg_quadratic_isLittleO_abs_rpow_cocompact
    (?_) (-2 * ↑π * I * b / a) (-2)).isBigO.const_mul_left _).const_mul_left _
  rwa [neg_div, neg_re, neg_lt_zero]
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) =
    1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2)
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
Ff_bd : 𝓕 f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) =
    1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2)

tactic: convert Real.tsum_eq_tsum_fourierIntegral_of_rpow_decay hCf one_lt_two f_bd Ff_bd 0 using 1
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
Ff_bd : 𝓕 f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) =
    1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2)
state_after: case h.e'_2
E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
Ff_bd : 𝓕 f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) = ∑' (n : ℤ), f (0 + ↑n)

case h.e'_3
E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
Ff_bd : 𝓕 f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ 1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2) = ∑' (n : ℤ), 𝓕 f ↑n * (fourier n) ↑0

tactic: refine Complex.continuous_exp.comp (Continuous.add ?_ ?_)
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
⊢ Continuous f
state_after: case refine_1
E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
⊢ Continuous fun x => -↑π * a * ↑x ^ 2

case refine_2
E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
⊢ Continuous fun x => 2 * ↑π * b * ↑x

tactic: exact continuous_const.mul (Complex.continuous_ofReal.pow 2)
state_before: case refine_1
E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
⊢ Continuous fun x => -↑π * a * ↑x ^ 2
state_after: no goals

tactic: exact continuous_const.mul Complex.continuous_ofReal
state_before: case refine_2
E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
⊢ Continuous fun x => 2 * ↑π * b * ↑x
state_after: no goals

tactic: rw [re_ofReal_mul]
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
⊢ 0 < (↑π * a).re
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
⊢ 0 < π * a.re

tactic: exact mul_pos pi_pos ha
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
⊢ 0 < π * a.re
state_after: no goals

tactic: rw [div_eq_mul_inv, re_ofReal_mul, inv_re]
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
⊢ 0 < (↑π / a).re
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
⊢ 0 < π * (a.re / normSq a)

tactic: refine mul_pos pi_pos (div_pos ha <| normSq_pos.mpr ?_)
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
⊢ 0 < π * (a.re / normSq a)
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
⊢ a ≠ 0

tactic: contrapose! ha
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
⊢ a ≠ 0
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
ha : a = 0
⊢ a.re ≤ 0

tactic: rw [ha, zero_re]
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
ha : a = 0
⊢ a.re ≤ 0
state_after: no goals

tactic: convert (cexp_neg_quadratic_isLittleO_abs_rpow_cocompact ?_ _ (-2)).isBigO
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
⊢ f =O[cocompact ℝ] fun x => |x| ^ (-2)
state_after: case convert_2
E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
⊢ (-↑π * a).re < 0

tactic: rwa [neg_mul, neg_re, neg_lt_zero]
state_before: case convert_2
E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
⊢ (-↑π * a).re < 0
state_after: no goals

tactic: rw [hFf]
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ 𝓕 f =O[cocompact ℝ] fun x => |x| ^ (-2)
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ (fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)) =O[cocompact ℝ] fun x => |x| ^ (-2)

tactic: have : ∀ (x : ℝ), -↑π / a * (↑x + I * b) ^ 2 =
    -↑π / a * x ^ 2 + (-2 * π * I * b) / a * x + π * b ^ 2 / a := by
  intro x; ring_nf; rw [I_sq]; ring
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ (fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)) =O[cocompact ℝ] fun x => |x| ^ (-2)
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
this : ∀ (x : ℝ), -↑π / a * (↑x + I * b) ^ 2 = -↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x + ↑π * b ^ 2 / a
⊢ (fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)) =O[cocompact ℝ] fun x => |x| ^ (-2)

tactic: simp_rw [this]
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
this : ∀ (x : ℝ), -↑π / a * (↑x + I * b) ^ 2 = -↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x + ↑π * b ^ 2 / a
⊢ (fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)) =O[cocompact ℝ] fun x => |x| ^ (-2)
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
this : ∀ (x : ℝ), -↑π / a * (↑x + I * b) ^ 2 = -↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x + ↑π * b ^ 2 / a
⊢ (fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x + ↑π * b ^ 2 / a)) =O[cocompact ℝ]
    fun x => |x| ^ (-2)

tactic: conv => enter [2, x]; rw [Complex.exp_add, ← mul_assoc _ _ (Complex.exp _), mul_comm]
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
this : ∀ (x : ℝ), -↑π / a * (↑x + I * b) ^ 2 = -↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x + ↑π * b ^ 2 / a
⊢ (fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x + ↑π * b ^ 2 / a)) =O[cocompact ℝ]
    fun x => |x| ^ (-2)
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
this : ∀ (x : ℝ), -↑π / a * (↑x + I * b) ^ 2 = -↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x + ↑π * b ^ 2 / a
⊢ (fun x =>
      cexp (↑π * b ^ 2 / a) * (1 / a ^ (1 / 2) * cexp (-↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x))) =O[cocompact ℝ]
    fun x => |x| ^ (-2)

tactic: refine ((cexp_neg_quadratic_isLittleO_abs_rpow_cocompact
  (?_) (-2 * ↑π * I * b / a) (-2)).isBigO.const_mul_left _).const_mul_left _
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
this : ∀ (x : ℝ), -↑π / a * (↑x + I * b) ^ 2 = -↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x + ↑π * b ^ 2 / a
⊢ (fun x =>
      cexp (↑π * b ^ 2 / a) * (1 / a ^ (1 / 2) * cexp (-↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x))) =O[cocompact ℝ]
    fun x => |x| ^ (-2)
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
this : ∀ (x : ℝ), -↑π / a * (↑x + I * b) ^ 2 = -↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x + ↑π * b ^ 2 / a
⊢ (-↑π / a).re < 0

tactic: rwa [neg_div, neg_re, neg_lt_zero]
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
this : ∀ (x : ℝ), -↑π / a * (↑x + I * b) ^ 2 = -↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x + ↑π * b ^ 2 / a
⊢ (-↑π / a).re < 0
state_after: no goals

tactic: intro x
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ ∀ (x : ℝ), -↑π / a * (↑x + I * b) ^ 2 = -↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x + ↑π * b ^ 2 / a
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
x : ℝ
⊢ -↑π / a * (↑x + I * b) ^ 2 = -↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x + ↑π * b ^ 2 / a

tactic: ring_nf
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
x : ℝ
⊢ -↑π / a * (↑x + I * b) ^ 2 = -↑π / a * ↑x ^ 2 + -2 * ↑π * I * b / a * ↑x + ↑π * b ^ 2 / a
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
x : ℝ
⊢ -(↑π * a⁻¹ * ↑x * I * b * 2) + (-(↑π * a⁻¹ * ↑x ^ 2) - ↑π * a⁻¹ * I ^ 2 * b ^ 2) =
    -(↑π * a⁻¹ * ↑x * I * b * 2) - ↑π * a⁻¹ * ↑x ^ 2 + ↑π * a⁻¹ * b ^ 2

tactic: rw [I_sq]
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
x : ℝ
⊢ -(↑π * a⁻¹ * ↑x * I * b * 2) + (-(↑π * a⁻¹ * ↑x ^ 2) - ↑π * a⁻¹ * I ^ 2 * b ^ 2) =
    -(↑π * a⁻¹ * ↑x * I * b * 2) - ↑π * a⁻¹ * ↑x ^ 2 + ↑π * a⁻¹ * b ^ 2
state_after: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
x : ℝ
⊢ -(↑π * a⁻¹ * ↑x * I * b * 2) + (-(↑π * a⁻¹ * ↑x ^ 2) - ↑π * a⁻¹ * -1 * b ^ 2) =
    -(↑π * a⁻¹ * ↑x * I * b * 2) - ↑π * a⁻¹ * ↑x ^ 2 + ↑π * a⁻¹ * b ^ 2

tactic: ring
state_before: E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
x : ℝ
⊢ -(↑π * a⁻¹ * ↑x * I * b * 2) + (-(↑π * a⁻¹ * ↑x ^ 2) - ↑π * a⁻¹ * -1 * b ^ 2) =
    -(↑π * a⁻¹ * ↑x * I * b * 2) - ↑π * a⁻¹ * ↑x ^ 2 + ↑π * a⁻¹ * b ^ 2
state_after: no goals

tactic: simp only [f, zero_add, ofReal_intCast]
state_before: case h.e'_2
E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
Ff_bd : 𝓕 f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ ∑' (n : ℤ), cexp (-↑π * a * ↑n ^ 2 + 2 * ↑π * b * ↑n) = ∑' (n : ℤ), f (0 + ↑n)
state_after: no goals

tactic: rw [← tsum_mul_left]
state_before: case h.e'_3
E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
Ff_bd : 𝓕 f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ 1 / a ^ (1 / 2) * ∑' (n : ℤ), cexp (-↑π / a * (↑n + I * b) ^ 2) = ∑' (n : ℤ), 𝓕 f ↑n * (fourier n) ↑0
state_after: case h.e'_3
E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
Ff_bd : 𝓕 f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ ∑' (x : ℤ), 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2) = ∑' (n : ℤ), 𝓕 f ↑n * (fourier n) ↑0

tactic: simp only [QuotientAddGroup.mk_zero, fourier_eval_zero, mul_one, hFf, ofReal_intCast]
state_before: case h.e'_3
E : Type u_1
inst✝ : NormedAddCommGroup E
a : ℂ
ha : 0 < a.re
b : ℂ
f : ℝ → ℂ := fun x => cexp (-↑π * a * ↑x ^ 2 + 2 * ↑π * b * ↑x)
hCf : Continuous f
hFf : 𝓕 f = fun x => 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2)
h1 : 0 < (↑π * a).re
h2 : 0 < (↑π / a).re
f_bd : f =O[cocompact ℝ] fun x => |x| ^ (-2)
Ff_bd : 𝓕 f =O[cocompact ℝ] fun x => |x| ^ (-2)
⊢ ∑' (x : ℤ), 1 / a ^ (1 / 2) * cexp (-↑π / a * (↑x + I * b) ^ 2) = ∑' (n : ℤ), 𝓕 f ↑n * (fourier n) ↑0
state_after: no goals