Documentation

Mathlib.Analysis.SpecialFunctions.Trigonometric.Arctan

The arctan function. #

Inequalities, identities and Real.tan as a PartialHomeomorph between (-(π / 2), π / 2) and the whole line.

The result of arctan x + arctan y is given by arctan_add, arctan_add_eq_add_pi or arctan_add_eq_sub_pi depending on whether x * y < 1 and 0 < x. As an application of arctan_add we give four Machin-like formulas (linear combinations of arctangents equal to π / 4 = arctan 1), including John Machin's original one at four_mul_arctan_inv_5_sub_arctan_inv_239.

theorem Real.tan_add {x y : } (h : ((∀ (k : ), x (2 * k + 1) * Real.pi / 2) ∀ (l : ), y (2 * l + 1) * Real.pi / 2) (∃ (k : ), x = (2 * k + 1) * Real.pi / 2) ∃ (l : ), y = (2 * l + 1) * Real.pi / 2) :
tan (x + y) = (tan x + tan y) / (1 - tan x * tan y)
theorem Real.tan_add' {x y : } (h : (∀ (k : ), x (2 * k + 1) * Real.pi / 2) ∀ (l : ), y (2 * l + 1) * Real.pi / 2) :
tan (x + y) = (tan x + tan y) / (1 - tan x * tan y)
theorem Real.tan_sub {x y : } (h : ((∀ (k : ), x (2 * k + 1) * Real.pi / 2) ∀ (l : ), y (2 * l + 1) * Real.pi / 2) (∃ (k : ), x = (2 * k + 1) * Real.pi / 2) ∃ (l : ), y = (2 * l + 1) * Real.pi / 2) :
tan (x - y) = (tan x - tan y) / (1 + tan x * tan y)
theorem Real.tan_sub' {x y : } (h : (∀ (k : ), x (2 * k + 1) * Real.pi / 2) ∀ (l : ), y (2 * l + 1) * Real.pi / 2) :
tan (x - y) = (tan x - tan y) / (1 + tan x * tan y)
theorem Real.tan_two_mul {x : } :
tan (2 * x) = 2 * tan x / (1 - tan x ^ 2)
theorem Real.continuous_tan :
Continuous fun (x : {x : | cos x 0}) => tan x

Real.tan as an OrderIso between (-(π / 2), π / 2) and .

Equations
    Instances For
      noncomputable def Real.arctan (x : ) :

      Inverse of the tan function, returns values in the range -π / 2 < arctan x and arctan x < π / 2

      Equations
        Instances For
          @[simp]
          theorem Real.tan_arctan (x : ) :
          tan (arctan x) = x
          theorem Real.arctan_tan {x : } (hx₁ : -(Real.pi / 2) < x) (hx₂ : x < Real.pi / 2) :
          arctan (tan x) = x
          theorem Real.cos_sq_arctan (x : ) :
          cos (arctan x) ^ 2 = 1 / (1 + x ^ 2)
          theorem Real.sin_arctan (x : ) :
          sin (arctan x) = x / (1 + x ^ 2)
          theorem Real.cos_arctan (x : ) :
          cos (arctan x) = 1 / (1 + x ^ 2)
          theorem Real.arctan_eq_arcsin (x : ) :
          arctan x = arcsin (x / (1 + x ^ 2))
          theorem Real.arcsin_eq_arctan {x : } (h : x Set.Ioo (-1) 1) :
          arcsin x = arctan (x / (1 - x ^ 2))
          @[simp]
          theorem Real.arctan_lt_arctan {x y : } (hxy : x < y) :
          @[simp]
          theorem Real.arctan_lt_arctan_iff {x y : } :
          arctan x < arctan y x < y
          theorem Real.arctan_le_arctan {x y : } (hxy : x y) :
          @[simp]
          @[simp]
          theorem Real.arctan_inj {x y : } :
          arctan x = arctan y x = y
          @[simp]
          theorem Real.arctan_eq_zero_iff {x : } :
          arctan x = 0 x = 0
          theorem Real.arctan_eq_of_tan_eq {x y : } (h : tan x = y) (hx : x Set.Ioo (-(Real.pi / 2)) (Real.pi / 2)) :
          arctan y = x
          @[simp]
          @[simp]
          @[simp]
          theorem Real.arctan_neg (x : ) :
          @[simp]
          @[simp]
          theorem Real.arctan_pos {x : } :
          0 < arctan x 0 < x
          @[simp]
          theorem Real.arctan_lt_zero {x : } :
          arctan x < 0 x < 0
          @[simp]
          theorem Real.arctan_nonneg {x : } :
          0 arctan x 0 x
          @[simp]
          theorem Real.arctan_le_zero {x : } :
          arctan x 0 x 0
          theorem Real.arctan_eq_arccos {x : } (h : 0 x) :
          arctan x = arccos ((1 + x ^ 2))⁻¹
          theorem Real.arccos_eq_arctan {x : } (h : 0 < x) :
          arccos x = arctan ((1 - x ^ 2) / x)
          theorem Real.arctan_inv_of_neg {x : } (h : x < 0) :
          theorem Real.arctan_ne_mul_pi_div_two {x : } (k : ) :
          arctan x (2 * k + 1) * Real.pi / 2
          theorem Real.arctan_add {x y : } (h : x * y < 1) :
          arctan x + arctan y = arctan ((x + y) / (1 - x * y))
          theorem Real.arctan_add_eq_add_pi {x y : } (h : 1 < x * y) (hx : 0 < x) :
          arctan x + arctan y = arctan ((x + y) / (1 - x * y)) + Real.pi
          theorem Real.arctan_add_eq_sub_pi {x y : } (h : 1 < x * y) (hx : x < 0) :
          arctan x + arctan y = arctan ((x + y) / (1 - x * y)) - Real.pi
          theorem Real.two_mul_arctan {x : } (h₁ : -1 < x) (h₂ : x < 1) :
          2 * arctan x = arctan (2 * x / (1 - x ^ 2))
          theorem Real.two_mul_arctan_add_pi {x : } (h : 1 < x) :
          2 * arctan x = arctan (2 * x / (1 - x ^ 2)) + Real.pi
          theorem Real.two_mul_arctan_sub_pi {x : } (h : x < -1) :
          2 * arctan x = arctan (2 * x / (1 - x ^ 2)) - Real.pi

          John Machin's 1706 formula, which he used to compute π to 100 decimal places.

          @[simp]
          theorem Real.sin_arctan_pos {x : } :
          0 < sin (arctan x) 0 < x
          @[simp]
          theorem Real.sin_arctan_lt_zero {x : } :
          sin (arctan x) < 0 x < 0
          @[simp]
          theorem Real.sin_arctan_eq_zero {x : } :
          sin (arctan x) = 0 x = 0
          @[simp]
          theorem Real.sin_arctan_nonneg {x : } :
          0 sin (arctan x) 0 x
          @[simp]
          theorem Real.sin_arctan_le_zero {x : } :
          sin (arctan x) 0 x 0

          Real.tan as a PartialHomeomorph between (-(π / 2), π / 2) and the whole line.

          Equations
            Instances For

              Extension for Real.cos (Real.arctan _).

              Equations
                Instances For

                  Extension for Real.sin (Real.arctan _).

                  Equations
                    Instances For