Average Error: 0.0 → 0.0
Time: 3.7s
Precision: 64
\[2 \cdot \tan^{-1} \left(\sqrt{\frac{1 - x}{1 + x}}\right)\]
\[2 \cdot \tan^{-1} \left(\sqrt{\frac{1 - x}{{1}^{3} + {x}^{3}} \cdot \left(1 \cdot 1 + \left(x \cdot x - 1 \cdot x\right)\right)}\right)\]
2 \cdot \tan^{-1} \left(\sqrt{\frac{1 - x}{1 + x}}\right)
2 \cdot \tan^{-1} \left(\sqrt{\frac{1 - x}{{1}^{3} + {x}^{3}} \cdot \left(1 \cdot 1 + \left(x \cdot x - 1 \cdot x\right)\right)}\right)
double f(double x) {
        double r11403 = 2.0;
        double r11404 = 1.0;
        double r11405 = x;
        double r11406 = r11404 - r11405;
        double r11407 = r11404 + r11405;
        double r11408 = r11406 / r11407;
        double r11409 = sqrt(r11408);
        double r11410 = atan(r11409);
        double r11411 = r11403 * r11410;
        return r11411;
}

double f(double x) {
        double r11412 = 2.0;
        double r11413 = 1.0;
        double r11414 = x;
        double r11415 = r11413 - r11414;
        double r11416 = 3.0;
        double r11417 = pow(r11413, r11416);
        double r11418 = pow(r11414, r11416);
        double r11419 = r11417 + r11418;
        double r11420 = r11415 / r11419;
        double r11421 = r11413 * r11413;
        double r11422 = r11414 * r11414;
        double r11423 = r11413 * r11414;
        double r11424 = r11422 - r11423;
        double r11425 = r11421 + r11424;
        double r11426 = r11420 * r11425;
        double r11427 = sqrt(r11426);
        double r11428 = atan(r11427);
        double r11429 = r11412 * r11428;
        return r11429;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.0

    \[2 \cdot \tan^{-1} \left(\sqrt{\frac{1 - x}{1 + x}}\right)\]
  2. Using strategy rm
  3. Applied flip3-+0.0

    \[\leadsto 2 \cdot \tan^{-1} \left(\sqrt{\frac{1 - x}{\color{blue}{\frac{{1}^{3} + {x}^{3}}{1 \cdot 1 + \left(x \cdot x - 1 \cdot x\right)}}}}\right)\]
  4. Applied associate-/r/0.0

    \[\leadsto 2 \cdot \tan^{-1} \left(\sqrt{\color{blue}{\frac{1 - x}{{1}^{3} + {x}^{3}} \cdot \left(1 \cdot 1 + \left(x \cdot x - 1 \cdot x\right)\right)}}\right)\]
  5. Final simplification0.0

    \[\leadsto 2 \cdot \tan^{-1} \left(\sqrt{\frac{1 - x}{{1}^{3} + {x}^{3}} \cdot \left(1 \cdot 1 + \left(x \cdot x - 1 \cdot x\right)\right)}\right)\]

Reproduce

herbie shell --seed 2020001 +o rules:numerics
(FPCore (x)
  :name "arccos"
  :precision binary64
  (* 2 (atan (sqrt (/ (- 1 x) (+ 1 x))))))