l3lab/ntp-mathlib huggingface dataset:
theorem sin_mul_I : sin (x * I) = sinh x * I := by
  have h : I * sin (x * I) = -sinh x := by
    rw [mul_comm, ← sinh_mul_I]
    ring_nf
    simp
  rw [← neg_neg (sinh x), ← h]
  apply Complex.ext <;> 

Proof state:
case a
x y : ℂ
h : I * sin (x * I) = -sinh x
⊢ (sin (x * I)).re = (-(I * sin (x * I)) * I).re

Next tactic:
simp
theorem sin_mul_I : sin (x * I) = sinh x * I := by
  have h : I * sin (x * I) = -sinh x := by
    rw [mul_comm, ← sinh_mul_I]
    ring_nf
    simp
  rw [← neg_neg (sinh x), ← h]
  apply Complex.ext <;> 

Proof state:
case a
x y : ℂ
h : I * sin (x * I) = -sinh x
⊢ (sin (x * I)).im = (-(I * sin (x * I)) * I).im

Next tactic:
simp
theorem tan_mul_I : tan (x * I) = tanh x * I := by
  

Proof state:
x y : ℂ
⊢ tan (x * I) = tanh x * I

Next tactic:
rw [tan, sin_mul_I, cos_mul_I, mul_div_right_comm, tanh_eq_sinh_div_cosh]
theorem sin_add : sin (x + y) = sin x * cos y + cos x * sin y := by
  

Proof state:
x y : ℂ
⊢ sin (x + y) = sin x * cos y + cos x * sin y

Next tactic:
rw [← mul_left_inj' I_ne_zero, ← sinh_mul_I, add_mul, add_mul, mul_right_comm, ← sinh_mul_I,
    mul_assoc, ← sinh_mul_I, ← cosh_mul_I, ← cosh_mul_I, sinh_add]
@[simp]
theorem cos_zero : cos 0 = 1 := by 

Proof state:
x y : ℂ
⊢ cos 0 = 1

Next tactic:
simp [cos]
@[simp]
theorem cos_neg : cos (-x) = cos x := by 

Proof state:
x y : ℂ
⊢ cos (-x) = cos x

Next tactic:
simp [cos, sub_eq_add_neg, exp_neg, add_comm]
private theorem cos_add_aux {a b c d : ℂ} :
    (a + b) * (c + d) - (b - a) * (d - c) * -1 = 2 * (a * c + b * d) := by 

Proof state:
x y a b c d : ℂ
⊢ (a + b) * (c + d) - (b - a) * (d - c) * -1 = 2 * (a * c + b * d)

Next tactic:
ring
theorem cos_add : cos (x + y) = cos x * cos y - sin x * sin y := by
  

Proof state:
x y : ℂ
⊢ cos (x + y) = cos x * cos y - sin x * sin y

Next tactic:
rw [← cosh_mul_I, add_mul, cosh_add, cosh_mul_I, cosh_mul_I, sinh_mul_I, sinh_mul_I,
    mul_mul_mul_comm, I_mul_I, mul_neg_one, sub_eq_add_neg]
theorem sin_sub : sin (x - y) = sin x * cos y - cos x * sin y := by
  

Proof state:
x y : ℂ
⊢ sin (x - y) = sin x * cos y - cos x * sin y

Next tactic:
simp [sub_eq_add_neg, sin_add, sin_neg, cos_neg]
theorem cos_sub : cos (x - y) = cos x * cos y + sin x * sin y := by
  

Proof state:
x y : ℂ
⊢ cos (x - y) = cos x * cos y + sin x * sin y

Next tactic:
simp [sub_eq_add_neg, cos_add, sin_neg, cos_neg]
theorem sin_add_mul_I (x y : ℂ) : sin (x + y * I) = sin x * cosh y + cos x * sinh y * I := by
  

Proof state:
x✝ y✝ x y : ℂ
⊢ sin (x + y * I) = sin x * cosh y + cos x * sinh y * I

Next tactic:
rw [sin_add, cos_mul_I, sin_mul_I, mul_assoc]
theorem sin_eq (z : ℂ) : sin z = sin z.re * cosh z.im + cos z.re * sinh z.im * I := by
  

Proof state:
x y z : ℂ
⊢ sin z = sin ↑z.re * cosh ↑z.im + cos ↑z.re * sinh ↑z.im * I

Next tactic:
convert sin_add_mul_I z.re z.im
theorem sin_eq (z : ℂ) : sin z = sin z.re * cosh z.im + cos z.re * sinh z.im * I := by
  convert sin_add_mul_I z.re z.im; 

Proof state:
case h.e'_2.h.e'_1
x y z : ℂ
⊢ z = ↑z.re + ↑z.im * I

Next tactic:
exact (re_add_im z).symm
theorem cos_add_mul_I (x y : ℂ) : cos (x + y * I) = cos x * cosh y - sin x * sinh y * I := by
  

Proof state:
x✝ y✝ x y : ℂ
⊢ cos (x + y * I) = cos x * cosh y - sin x * sinh y * I

Next tactic:
rw [cos_add, cos_mul_I, sin_mul_I, mul_assoc]
theorem cos_eq (z : ℂ) : cos z = cos z.re * cosh z.im - sin z.re * sinh z.im * I := by
  

Proof state:
x y z : ℂ
⊢ cos z = cos ↑z.re * cosh ↑z.im - sin ↑z.re * sinh ↑z.im * I

Next tactic:
convert cos_add_mul_I z.re z.im
theorem cos_eq (z : ℂ) : cos z = cos z.re * cosh z.im - sin z.re * sinh z.im * I := by
  convert cos_add_mul_I z.re z.im; 

Proof state:
case h.e'_2.h.e'_1
x y z : ℂ
⊢ z = ↑z.re + ↑z.im * I

Next tactic:
exact (re_add_im z).symm
theorem sin_sub_sin : sin x - sin y = 2 * sin ((x - y) / 2) * cos ((x + y) / 2) := by
  

Proof state:
x y : ℂ
⊢ sin x - sin y = 2 * sin ((x - y) / 2) * cos ((x + y) / 2)

Next tactic:
have s1 := sin_add ((x + y) / 2) ((x - y) / 2)
theorem sin_sub_sin : sin x - sin y = 2 * sin ((x - y) / 2) * cos ((x + y) / 2) := by
  have s1 := sin_add ((x + y) / 2) ((x - y) / 2)
  

Proof state:
x y : ℂ
s1 : sin ((x + y) / 2 + (x - y) / 2) = sin ((x + y) / 2) * cos ((x - y) / 2) + cos ((x + y) / 2) * sin ((x - y) / 2)
⊢ sin x - sin y = 2 * sin ((x - y) / 2) * cos ((x + y) / 2)

Next tactic:
have s2 := sin_sub ((x + y) / 2) ((x - y) / 2)
theorem sin_sub_sin : sin x - sin y = 2 * sin ((x - y) / 2) * cos ((x + y) / 2) := by
  have s1 := sin_add ((x + y) / 2) ((x - y) / 2)
  have s2 := sin_sub ((x + y) / 2) ((x - y) / 2)
  

Proof state:
x y : ℂ
s1 : sin ((x + y) / 2 + (x - y) / 2) = sin ((x + y) / 2) * cos ((x - y) / 2) + cos ((x + y) / 2) * sin ((x - y) / 2)
s2 : sin ((x + y) / 2 - (x - y) / 2) = sin ((x + y) / 2) * cos ((x - y) / 2) - cos ((x + y) / 2) * sin ((x - y) / 2)
⊢ sin x - sin y = 2 * sin ((x - y) / 2) * cos ((x + y) / 2)

Next tactic:
rw [div_add_div_same, add_sub, add_right_comm, add_sub_cancel, half_add_self] at s1
theorem sin_sub_sin : sin x - sin y = 2 * sin ((x - y) / 2) * cos ((x + y) / 2) := by
  have s1 := sin_add ((x + y) / 2) ((x - y) / 2)
  have s2 := sin_sub ((x + y) / 2) ((x - y) / 2)
  rw [div_add_div_same, add_sub, add_right_comm, add_sub_cancel, half_add_self] at s1
  

Proof state:
x y : ℂ
s1 : sin x = sin ((x + y) / 2) * cos ((x - y) / 2) + cos ((x + y) / 2) * sin ((x - y) / 2)
s2 : sin ((x + y) / 2 - (x - y) / 2) = sin ((x + y) / 2) * cos ((x - y) / 2) - cos ((x + y) / 2) * sin ((x - y) / 2)
⊢ sin x - sin y = 2 * sin ((x - y) / 2) * cos ((x + y) / 2)

Next tactic:
rw [div_sub_div_same, ← sub_add, add_sub_cancel', half_add_self] at s2
theorem sin_sub_sin : sin x - sin y = 2 * sin ((x - y) / 2) * cos ((x + y) / 2) := by
  have s1 := sin_add ((x + y) / 2) ((x - y) / 2)
  have s2 := sin_sub ((x + y) / 2) ((x - y) / 2)
  rw [div_add_div_same, add_sub, add_right_comm, add_sub_cancel, half_add_self] at s1
  rw [div_sub_div_same, ← sub_add, add_sub_cancel', half_add_self] at s2
  

Proof state:
x y : ℂ
s1 : sin x = sin ((x + y) / 2) * cos ((x - y) / 2) + cos ((x + y) / 2) * sin ((x - y) / 2)
s2 : sin y = sin ((x + y) / 2) * cos ((x - y) / 2) - cos ((x + y) / 2) * sin ((x - y) / 2)
⊢ sin x - sin y = 2 * sin ((x - y) / 2) * cos ((x + y) / 2)

Next tactic:
rw [s1, s2]
theorem sin_sub_sin : sin x - sin y = 2 * sin ((x - y) / 2) * cos ((x + y) / 2) := by
  have s1 := sin_add ((x + y) / 2) ((x - y) / 2)
  have s2 := sin_sub ((x + y) / 2) ((x - y) / 2)
  rw [div_add_div_same, add_sub, add_right_comm, add_sub_cancel, half_add_self] at s1
  rw [div_sub_div_same, ← sub_add, add_sub_cancel', half_add_self] at s2
  rw [s1, s2]
  

Proof state:
x y : ℂ
s1 : sin x = sin ((x + y) / 2) * cos ((x - y) / 2) + cos ((x + y) / 2) * sin ((x - y) / 2)
s2 : sin y = sin ((x + y) / 2) * cos ((x - y) / 2) - cos ((x + y) / 2) * sin ((x - y) / 2)
⊢ sin ((x + y) / 2) * cos ((x - y) / 2) + cos ((x + y) / 2) * sin ((x - y) / 2) -
      (sin ((x + y) / 2) * cos ((x - y) / 2) - cos ((x + y) / 2) * sin ((x - y) / 2)) =
    2 * sin ((x - y) / 2) * cos ((x + y) / 2)

Next tactic:
ring
theorem cos_sub_cos : cos x - cos y = -2 * sin ((x + y) / 2) * sin ((x - y) / 2) := by
  

Proof state:
x y : ℂ
⊢ cos x - cos y = -2 * sin ((x + y) / 2) * sin ((x - y) / 2)

Next tactic:
have s1 := cos_add ((x + y) / 2) ((x - y) / 2)
theorem cos_sub_cos : cos x - cos y = -2 * sin ((x + y) / 2) * sin ((x - y) / 2) := by
  have s1 := cos_add ((x + y) / 2) ((x - y) / 2)
  

Proof state:
x y : ℂ
s1 : cos ((x + y) / 2 + (x - y) / 2) = cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2)
⊢ cos x - cos y = -2 * sin ((x + y) / 2) * sin ((x - y) / 2)

Next tactic:
have s2 := cos_sub ((x + y) / 2) ((x - y) / 2)
theorem cos_sub_cos : cos x - cos y = -2 * sin ((x + y) / 2) * sin ((x - y) / 2) := by
  have s1 := cos_add ((x + y) / 2) ((x - y) / 2)
  have s2 := cos_sub ((x + y) / 2) ((x - y) / 2)
  

Proof state:
x y : ℂ
s1 : cos ((x + y) / 2 + (x - y) / 2) = cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2)
s2 : cos ((x + y) / 2 - (x - y) / 2) = cos ((x + y) / 2) * cos ((x - y) / 2) + sin ((x + y) / 2) * sin ((x - y) / 2)
⊢ cos x - cos y = -2 * sin ((x + y) / 2) * sin ((x - y) / 2)

Next tactic:
rw [div_add_div_same, add_sub, add_right_comm, add_sub_cancel, half_add_self] at s1
theorem cos_sub_cos : cos x - cos y = -2 * sin ((x + y) / 2) * sin ((x - y) / 2) := by
  have s1 := cos_add ((x + y) / 2) ((x - y) / 2)
  have s2 := cos_sub ((x + y) / 2) ((x - y) / 2)
  rw [div_add_div_same, add_sub, add_right_comm, add_sub_cancel, half_add_self] at s1
  

Proof state:
x y : ℂ
s1 : cos x = cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2)
s2 : cos ((x + y) / 2 - (x - y) / 2) = cos ((x + y) / 2) * cos ((x - y) / 2) + sin ((x + y) / 2) * sin ((x - y) / 2)
⊢ cos x - cos y = -2 * sin ((x + y) / 2) * sin ((x - y) / 2)

Next tactic:
rw [div_sub_div_same, ← sub_add, add_sub_cancel', half_add_self] at s2
theorem cos_sub_cos : cos x - cos y = -2 * sin ((x + y) / 2) * sin ((x - y) / 2) := by
  have s1 := cos_add ((x + y) / 2) ((x - y) / 2)
  have s2 := cos_sub ((x + y) / 2) ((x - y) / 2)
  rw [div_add_div_same, add_sub, add_right_comm, add_sub_cancel, half_add_self] at s1
  rw [div_sub_div_same, ← sub_add, add_sub_cancel', half_add_self] at s2
  

Proof state:
x y : ℂ
s1 : cos x = cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2)
s2 : cos y = cos ((x + y) / 2) * cos ((x - y) / 2) + sin ((x + y) / 2) * sin ((x - y) / 2)
⊢ cos x - cos y = -2 * sin ((x + y) / 2) * sin ((x - y) / 2)

Next tactic:
rw [s1, s2]
theorem cos_sub_cos : cos x - cos y = -2 * sin ((x + y) / 2) * sin ((x - y) / 2) := by
  have s1 := cos_add ((x + y) / 2) ((x - y) / 2)
  have s2 := cos_sub ((x + y) / 2) ((x - y) / 2)
  rw [div_add_div_same, add_sub, add_right_comm, add_sub_cancel, half_add_self] at s1
  rw [div_sub_div_same, ← sub_add, add_sub_cancel', half_add_self] at s2
  rw [s1, s2]
  

Proof state:
x y : ℂ
s1 : cos x = cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2)
s2 : cos y = cos ((x + y) / 2) * cos ((x - y) / 2) + sin ((x + y) / 2) * sin ((x - y) / 2)
⊢ cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2) -
      (cos ((x + y) / 2) * cos ((x - y) / 2) + sin ((x + y) / 2) * sin ((x - y) / 2)) =
    -2 * sin ((x + y) / 2) * sin ((x - y) / 2)

Next tactic:
ring
theorem cos_add_cos : cos x + cos y = 2 * cos ((x + y) / 2) * cos ((x - y) / 2) := by
  

Proof state:
x y : ℂ
⊢ cos x + cos y = 2 * cos ((x + y) / 2) * cos ((x - y) / 2)

Next tactic:
calc
    cos x + cos y = cos ((x + y) / 2 + (x - y) / 2) + cos ((x + y) / 2 - (x - y) / 2) := ?_
    _ =
        cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2) +
          (cos ((x + y) / 2) * cos ((x - y) / 2) + sin ((x + y) / 2) * sin ((x - y) / 2)) :=
      ?_
    _ = 2 * cos ((x + y) / 2) * cos ((x - y) / 2) := ?_
theorem cos_add_cos : cos x + cos y = 2 * cos ((x + y) / 2) * cos ((x - y) / 2) := by
  calc
    cos x + cos y = cos ((x + y) / 2 + (x - y) / 2) + cos ((x + y) / 2 - (x - y) / 2) := ?_
    _ =
        cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2) +
          (cos ((x + y) / 2) * cos ((x - y) / 2) + sin ((x + y) / 2) * sin ((x - y) / 2)) :=
      ?_
    _ = 2 * cos ((x + y) / 2) * cos ((x - y) / 2) := ?_

  · 

Proof state:
case calc_1
x y : ℂ
⊢ cos x + cos y = cos ((x + y) / 2 + (x - y) / 2) + cos ((x + y) / 2 - (x - y) / 2)

Next tactic:
congr
theorem cos_add_cos : cos x + cos y = 2 * cos ((x + y) / 2) * cos ((x - y) / 2) := by
  calc
    cos x + cos y = cos ((x + y) / 2 + (x - y) / 2) + cos ((x + y) / 2 - (x - y) / 2) := ?_
    _ =
        cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2) +
          (cos ((x + y) / 2) * cos ((x - y) / 2) + sin ((x + y) / 2) * sin ((x - y) / 2)) :=
      ?_
    _ = 2 * cos ((x + y) / 2) * cos ((x - y) / 2) := ?_

  · congr <;> 

Proof state:
case calc_1.e_a.e_z
x y : ℂ
⊢ x = (x + y) / 2 + (x - y) / 2

Next tactic:
field_simp
theorem cos_add_cos : cos x + cos y = 2 * cos ((x + y) / 2) * cos ((x - y) / 2) := by
  calc
    cos x + cos y = cos ((x + y) / 2 + (x - y) / 2) + cos ((x + y) / 2 - (x - y) / 2) := ?_
    _ =
        cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2) +
          (cos ((x + y) / 2) * cos ((x - y) / 2) + sin ((x + y) / 2) * sin ((x - y) / 2)) :=
      ?_
    _ = 2 * cos ((x + y) / 2) * cos ((x - y) / 2) := ?_

  · congr <;> 

Proof state:
case calc_1.e_a.e_z
x y : ℂ
⊢ y = (x + y) / 2 - (x - y) / 2

Next tactic:
field_simp
theorem cos_add_cos : cos x + cos y = 2 * cos ((x + y) / 2) * cos ((x - y) / 2) := by
  calc
    cos x + cos y = cos ((x + y) / 2 + (x - y) / 2) + cos ((x + y) / 2 - (x - y) / 2) := ?_
    _ =
        cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2) +
          (cos ((x + y) / 2) * cos ((x - y) / 2) + sin ((x + y) / 2) * sin ((x - y) / 2)) :=
      ?_
    _ = 2 * cos ((x + y) / 2) * cos ((x - y) / 2) := ?_

  · congr <;> field_simp
  · 

Proof state:
case calc_2
x y : ℂ
⊢ cos ((x + y) / 2 + (x - y) / 2) + cos ((x + y) / 2 - (x - y) / 2) =
    cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2) +
      (cos ((x + y) / 2) * cos ((x - y) / 2) + sin ((x + y) / 2) * sin ((x - y) / 2))

Next tactic:
rw [cos_add, cos_sub]
theorem cos_add_cos : cos x + cos y = 2 * cos ((x + y) / 2) * cos ((x - y) / 2) := by
  calc
    cos x + cos y = cos ((x + y) / 2 + (x - y) / 2) + cos ((x + y) / 2 - (x - y) / 2) := ?_
    _ =
        cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2) +
          (cos ((x + y) / 2) * cos ((x - y) / 2) + sin ((x + y) / 2) * sin ((x - y) / 2)) :=
      ?_
    _ = 2 * cos ((x + y) / 2) * cos ((x - y) / 2) := ?_

  · congr <;> field_simp
  · rw [cos_add, cos_sub]
  

Proof state:
case calc_3
x y : ℂ
⊢ cos ((x + y) / 2) * cos ((x - y) / 2) - sin ((x + y) / 2) * sin ((x - y) / 2) +
      (cos ((x + y) / 2) * cos ((x - y) / 2) + sin ((x + y) / 2) * sin ((x - y) / 2)) =
    2 * cos ((x + y) / 2) * cos ((x - y) / 2)

Next tactic:
ring
theorem sin_conj : sin (conj x) = conj (sin x) := by
  

Proof state:
x y : ℂ
⊢ sin ((starRingEnd ℂ) x) = (starRingEnd ℂ) (sin x)

Next tactic:
rw [← mul_left_inj' I_ne_zero, ← sinh_mul_I, ← conj_neg_I, ← RingHom.map_mul, ← RingHom.map_mul,
    sinh_conj, mul_neg, sinh_neg, sinh_mul_I, mul_neg]
@[simp]
theorem ofReal_sin_ofReal_re (x : ℝ) : ((sin x).re : ℂ) = sin x :=
  conj_eq_iff_re.1 <| by 

Proof state:
x✝ y : ℂ
x : ℝ
⊢ (starRingEnd ℂ) (sin ↑x) = sin ↑x

Next tactic:
rw [← sin_conj, conj_ofReal]
@[simp]
theorem sin_ofReal_im (x : ℝ) : (sin x).im = 0 := by 

Proof state:
x✝ y : ℂ
x : ℝ
⊢ (sin ↑x).im = 0

Next tactic:
rw [← ofReal_sin_ofReal_re, ofReal_im]
theorem cos_conj : cos (conj x) = conj (cos x) := by
  

Proof state:
x y : ℂ
⊢ cos ((starRingEnd ℂ) x) = (starRingEnd ℂ) (cos x)

Next tactic:
rw [← cosh_mul_I, ← conj_neg_I, ← RingHom.map_mul, ← cosh_mul_I, cosh_conj, mul_neg, cosh_neg]
@[simp]
theorem ofReal_cos_ofReal_re (x : ℝ) : ((cos x).re : ℂ) = cos x :=
  conj_eq_iff_re.1 <| by 

Proof state:
x✝ y : ℂ
x : ℝ
⊢ (starRingEnd ℂ) (cos ↑x) = cos ↑x

Next tactic:
rw [← cos_conj, conj_ofReal]
@[simp]
theorem cos_ofReal_im (x : ℝ) : (cos x).im = 0 := by 

Proof state:
x✝ y : ℂ
x : ℝ
⊢ (cos ↑x).im = 0

Next tactic:
rw [← ofReal_cos_ofReal_re, ofReal_im]
@[simp]
theorem tan_zero : tan 0 = 0 := by 

Proof state:
x y : ℂ
⊢ tan 0 = 0

Next tactic:
simp [tan]
theorem tan_mul_cos {x : ℂ} (hx : cos x ≠ 0) : tan x * cos x = sin x := by
  

Proof state:
x✝ y x : ℂ
hx : cos x ≠ 0
⊢ tan x * cos x = sin x

Next tactic:
rw [tan_eq_sin_div_cos, div_mul_cancel _ hx]
@[simp]
theorem tan_neg : tan (-x) = -tan x := by 

Proof state:
x y : ℂ
⊢ tan (-x) = -tan x

Next tactic:
simp [tan, neg_div]
theorem tan_conj : tan (conj x) = conj (tan x) := by 

Proof state:
x y : ℂ
⊢ tan ((starRingEnd ℂ) x) = (starRingEnd ℂ) (tan x)

Next tactic:
rw [tan, sin_conj, cos_conj, ← map_div₀, tan]
@[simp]
theorem ofReal_tan_ofReal_re (x : ℝ) : ((tan x).re : ℂ) = tan x :=
  conj_eq_iff_re.1 <| by 

Proof state:
x✝ y : ℂ
x : ℝ
⊢ (starRingEnd ℂ) (tan ↑x) = tan ↑x

Next tactic:
rw [← tan_conj, conj_ofReal]
@[simp]
theorem tan_ofReal_im (x : ℝ) : (tan x).im = 0 := by 

Proof state:
x✝ y : ℂ
x : ℝ
⊢ (tan ↑x).im = 0

Next tactic:
rw [← ofReal_tan_ofReal_re, ofReal_im]
theorem cos_add_sin_I : cos x + sin x * I = exp (x * I) := by
  

Proof state:
x y : ℂ
⊢ cos x + sin x * I = cexp (x * I)

Next tactic:
rw [← cosh_add_sinh, sinh_mul_I, cosh_mul_I]
theorem cos_sub_sin_I : cos x - sin x * I = exp (-x * I) := by
  

Proof state:
x y : ℂ
⊢ cos x - sin x * I = cexp (-x * I)

Next tactic:
rw [neg_mul, ← cosh_sub_sinh, sinh_mul_I, cosh_mul_I]
@[simp]
theorem sin_sq_add_cos_sq : sin x ^ 2 + cos x ^ 2 = 1 :=
  Eq.trans (by 

Proof state:
x y : ℂ
⊢ sin x ^ 2 + cos x ^ 2 = cosh (x * I) ^ 2 - sinh (x * I) ^ 2

Next tactic:
rw [cosh_mul_I, sinh_mul_I, mul_pow, I_sq, mul_neg_one, sub_neg_eq_add, add_comm]
@[simp]
theorem cos_sq_add_sin_sq : cos x ^ 2 + sin x ^ 2 = 1 := by 

Proof state:
x y : ℂ
⊢ cos x ^ 2 + sin x ^ 2 = 1

Next tactic:
rw [add_comm, sin_sq_add_cos_sq]
theorem cos_two_mul' : cos (2 * x) = cos x ^ 2 - sin x ^ 2 := by 

Proof state:
x y : ℂ
⊢ cos (2 * x) = cos x ^ 2 - sin x ^ 2

Next tactic:
rw [two_mul, cos_add, ← sq, ← sq]
theorem cos_two_mul : cos (2 * x) = 2 * cos x ^ 2 - 1 := by
  

Proof state:
x y : ℂ
⊢ cos (2 * x) = 2 * cos x ^ 2 - 1

Next tactic:
rw [cos_two_mul', eq_sub_iff_add_eq.2 (sin_sq_add_cos_sq x), ← sub_add, sub_add_eq_add_sub,
    two_mul]
theorem sin_two_mul : sin (2 * x) = 2 * sin x * cos x := by
  

Proof state:
x y : ℂ
⊢ sin (2 * x) = 2 * sin x * cos x

Next tactic:
rw [two_mul, sin_add, two_mul, add_mul, mul_comm]
theorem cos_sq : cos x ^ 2 = 1 / 2 + cos (2 * x) / 2 := by
  

Proof state:
x y : ℂ
⊢ cos x ^ 2 = 1 / 2 + cos (2 * x) / 2

Next tactic:
simp [cos_two_mul, div_add_div_same, mul_div_cancel_left, two_ne_zero, -one_div]
theorem cos_sq' : cos x ^ 2 = 1 - sin x ^ 2 := by 

Proof state:
x y : ℂ
⊢ cos x ^ 2 = 1 - sin x ^ 2

Next tactic:
rw [← sin_sq_add_cos_sq x, add_sub_cancel']
theorem sin_sq : sin x ^ 2 = 1 - cos x ^ 2 := by 

Proof state:
x y : ℂ
⊢ sin x ^ 2 = 1 - cos x ^ 2

Next tactic:
rw [← sin_sq_add_cos_sq x, add_sub_cancel]
theorem inv_one_add_tan_sq {x : ℂ} (hx : cos x ≠ 0) : (1 + tan x ^ 2)⁻¹ = cos x ^ 2 := by
  

Proof state:
x✝ y x : ℂ
hx : cos x ≠ 0
⊢ (1 + tan x ^ 2)⁻¹ = cos x ^ 2

Next tactic:
rw [tan_eq_sin_div_cos, div_pow]
theorem inv_one_add_tan_sq {x : ℂ} (hx : cos x ≠ 0) : (1 + tan x ^ 2)⁻¹ = cos x ^ 2 := by
  rw [tan_eq_sin_div_cos, div_pow]
  

Proof state:
x✝ y x : ℂ
hx : cos x ≠ 0
⊢ (1 + sin x ^ 2 / cos x ^ 2)⁻¹ = cos x ^ 2

Next tactic:
field_simp
theorem tan_sq_div_one_add_tan_sq {x : ℂ} (hx : cos x ≠ 0) :
    tan x ^ 2 / (1 + tan x ^ 2) = sin x ^ 2 := by
  

Proof state:
x✝ y x : ℂ
hx : cos x ≠ 0
⊢ tan x ^ 2 / (1 + tan x ^ 2) = sin x ^ 2

Next tactic:
simp only [← tan_mul_cos hx, mul_pow, ← inv_one_add_tan_sq hx, div_eq_mul_inv, one_mul]
theorem cos_three_mul : cos (3 * x) = 4 * cos x ^ 3 - 3 * cos x := by
  

Proof state:
x y : ℂ
⊢ cos (3 * x) = 4 * cos x ^ 3 - 3 * cos x

Next tactic:
have h1 : x + 2 * x = 3 * x := by ring
theorem cos_three_mul : cos (3 * x) = 4 * cos x ^ 3 - 3 * cos x := by
  have h1 : x + 2 * x = 3 * x := by 

Proof state:
x y : ℂ
⊢ x + 2 * x = 3 * x

Next tactic:
ring
theorem cos_three_mul : cos (3 * x) = 4 * cos x ^ 3 - 3 * cos x := by
  have h1 : x + 2 * x = 3 * x := by ring
  

Proof state:
x y : ℂ
h1 : x + 2 * x = 3 * x
⊢ cos (3 * x) = 4 * cos x ^ 3 - 3 * cos x

Next tactic:
rw [← h1, cos_add x (2 * x)]
theorem cos_three_mul : cos (3 * x) = 4 * cos x ^ 3 - 3 * cos x := by
  have h1 : x + 2 * x = 3 * x := by ring
  rw [← h1, cos_add x (2 * x)]
  

Proof state:
x y : ℂ
h1 : x + 2 * x = 3 * x
⊢ cos x * cos (2 * x) - sin x * sin (2 * x) = 4 * cos x ^ 3 - 3 * cos x

Next tactic:
simp only [cos_two_mul, sin_two_mul, mul_add, mul_sub, mul_one, sq]
theorem cos_three_mul : cos (3 * x) = 4 * cos x ^ 3 - 3 * cos x := by
  have h1 : x + 2 * x = 3 * x := by ring
  rw [← h1, cos_add x (2 * x)]
  simp only [cos_two_mul, sin_two_mul, mul_add, mul_sub, mul_one, sq]
  

Proof state:
x y : ℂ
h1 : x + 2 * x = 3 * x
⊢ cos x * (2 * (cos x * cos x)) - cos x - sin x * (2 * sin x * cos x) = 4 * cos x ^ 3 - 3 * cos x

Next tactic:
have h2 : 4 * cos x ^ 3 = 2 * cos x * cos x * cos x + 2 * cos x * cos x ^ 2 := by ring
theorem cos_three_mul : cos (3 * x) = 4 * cos x ^ 3 - 3 * cos x := by
  have h1 : x + 2 * x = 3 * x := by ring
  rw [← h1, cos_add x (2 * x)]
  simp only [cos_two_mul, sin_two_mul, mul_add, mul_sub, mul_one, sq]
  have h2 : 4 * cos x ^ 3 = 2 * cos x * cos x * cos x + 2 * cos x * cos x ^ 2 := by 

Proof state:
x y : ℂ
h1 : x + 2 * x = 3 * x
⊢ 4 * cos x ^ 3 = 2 * cos x * cos x * cos x + 2 * cos x * cos x ^ 2

Next tactic:
ring
theorem cos_three_mul : cos (3 * x) = 4 * cos x ^ 3 - 3 * cos x := by
  have h1 : x + 2 * x = 3 * x := by ring
  rw [← h1, cos_add x (2 * x)]
  simp only [cos_two_mul, sin_two_mul, mul_add, mul_sub, mul_one, sq]
  have h2 : 4 * cos x ^ 3 = 2 * cos x * cos x * cos x + 2 * cos x * cos x ^ 2 := by ring
  

Proof state:
x y : ℂ
h1 : x + 2 * x = 3 * x
h2 : 4 * cos x ^ 3 = 2 * cos x * cos x * cos x + 2 * cos x * cos x ^ 2
⊢ cos x * (2 * (cos x * cos x)) - cos x - sin x * (2 * sin x * cos x) = 4 * cos x ^ 3 - 3 * cos x

Next tactic:
rw [h2, cos_sq']
theorem cos_three_mul : cos (3 * x) = 4 * cos x ^ 3 - 3 * cos x := by
  have h1 : x + 2 * x = 3 * x := by ring
  rw [← h1, cos_add x (2 * x)]
  simp only [cos_two_mul, sin_two_mul, mul_add, mul_sub, mul_one, sq]
  have h2 : 4 * cos x ^ 3 = 2 * cos x * cos x * cos x + 2 * cos x * cos x ^ 2 := by ring
  rw [h2, cos_sq']
  

Proof state:
x y : ℂ
h1 : x + 2 * x = 3 * x
h2 : 4 * cos x ^ 3 = 2 * cos x * cos x * cos x + 2 * cos x * cos x ^ 2
⊢ cos x * (2 * (cos x * cos x)) - cos x - sin x * (2 * sin x * cos x) =
    2 * cos x * cos x * cos x + 2 * cos x * (1 - sin x ^ 2) - 3 * cos x

Next tactic:
ring
theorem sin_three_mul : sin (3 * x) = 3 * sin x - 4 * sin x ^ 3 := by
  

Proof state:
x y : ℂ
⊢ sin (3 * x) = 3 * sin x - 4 * sin x ^ 3

Next tactic:
have h1 : x + 2 * x = 3 * x := by ring
theorem sin_three_mul : sin (3 * x) = 3 * sin x - 4 * sin x ^ 3 := by
  have h1 : x + 2 * x = 3 * x := by 

Proof state:
x y : ℂ
⊢ x + 2 * x = 3 * x

Next tactic:
ring
theorem sin_three_mul : sin (3 * x) = 3 * sin x - 4 * sin x ^ 3 := by
  have h1 : x + 2 * x = 3 * x := by ring
  

Proof state:
x y : ℂ
h1 : x + 2 * x = 3 * x
⊢ sin (3 * x) = 3 * sin x - 4 * sin x ^ 3

Next tactic:
rw [← h1, sin_add x (2 * x)]
theorem sin_three_mul : sin (3 * x) = 3 * sin x - 4 * sin x ^ 3 := by
  have h1 : x + 2 * x = 3 * x := by ring
  rw [← h1, sin_add x (2 * x)]
  

Proof state:
x y : ℂ
h1 : x + 2 * x = 3 * x
⊢ sin x * cos (2 * x) + cos x * sin (2 * x) = 3 * sin x - 4 * sin x ^ 3

Next tactic:
simp only [cos_two_mul, sin_two_mul, cos_sq']
theorem sin_three_mul : sin (3 * x) = 3 * sin x - 4 * sin x ^ 3 := by
  have h1 : x + 2 * x = 3 * x := by ring
  rw [← h1, sin_add x (2 * x)]
  simp only [cos_two_mul, sin_two_mul, cos_sq']
  

Proof state:
x y : ℂ
h1 : x + 2 * x = 3 * x
⊢ sin x * (2 * (1 - sin x ^ 2) - 1) + cos x * (2 * sin x * cos x) = 3 * sin x - 4 * sin x ^ 3

Next tactic:
have h2 : cos x * (2 * sin x * cos x) = 2 * sin x * cos x ^ 2 := by ring
theorem sin_three_mul : sin (3 * x) = 3 * sin x - 4 * sin x ^ 3 := by
  have h1 : x + 2 * x = 3 * x := by ring
  rw [← h1, sin_add x (2 * x)]
  simp only [cos_two_mul, sin_two_mul, cos_sq']
  have h2 : cos x * (2 * sin x * cos x) = 2 * sin x * cos x ^ 2 := by 

Proof state:
x y : ℂ
h1 : x + 2 * x = 3 * x
⊢ cos x * (2 * sin x * cos x) = 2 * sin x * cos x ^ 2

Next tactic:
ring
theorem sin_three_mul : sin (3 * x) = 3 * sin x - 4 * sin x ^ 3 := by
  have h1 : x + 2 * x = 3 * x := by ring
  rw [← h1, sin_add x (2 * x)]
  simp only [cos_two_mul, sin_two_mul, cos_sq']
  have h2 : cos x * (2 * sin x * cos x) = 2 * sin x * cos x ^ 2 := by ring
  

Proof state:
x y : ℂ
h1 : x + 2 * x = 3 * x
h2 : cos x * (2 * sin x * cos x) = 2 * sin x * cos x ^ 2
⊢ sin x * (2 * (1 - sin x ^ 2) - 1) + cos x * (2 * sin x * cos x) = 3 * sin x - 4 * sin x ^ 3

Next tactic:
rw [h2, cos_sq']