Average Error: 0.0 → 0.0
Time: 11.0s
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 r17619 = 2.0;
        double r17620 = 1.0;
        double r17621 = x;
        double r17622 = r17620 - r17621;
        double r17623 = r17620 + r17621;
        double r17624 = r17622 / r17623;
        double r17625 = sqrt(r17624);
        double r17626 = atan(r17625);
        double r17627 = r17619 * r17626;
        return r17627;
}

double f(double x) {
        double r17628 = 2.0;
        double r17629 = 1.0;
        double r17630 = x;
        double r17631 = r17629 - r17630;
        double r17632 = 3.0;
        double r17633 = pow(r17629, r17632);
        double r17634 = pow(r17630, r17632);
        double r17635 = r17633 + r17634;
        double r17636 = r17631 / r17635;
        double r17637 = r17629 * r17629;
        double r17638 = r17630 * r17630;
        double r17639 = r17629 * r17630;
        double r17640 = r17638 - r17639;
        double r17641 = r17637 + r17640;
        double r17642 = r17636 * r17641;
        double r17643 = sqrt(r17642);
        double r17644 = atan(r17643);
        double r17645 = r17628 * r17644;
        return r17645;
}

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 2019303 
(FPCore (x)
  :name "arccos"
  :precision binary64
  (* 2 (atan (sqrt (/ (- 1 x) (+ 1 x))))))