Average Error: 0.0 → 0.0
Time: 33.9s
Precision: 64
\[2 \cdot \tan^{-1} \left(\sqrt{\frac{1 - x}{1 + x}}\right)\]
\[\tan^{-1} \left(\sqrt{\frac{1}{\sqrt[3]{1 + x} \cdot \sqrt[3]{1 + x}} \cdot \frac{1 - x}{\sqrt[3]{1 + x}}}\right) \cdot 2\]
2 \cdot \tan^{-1} \left(\sqrt{\frac{1 - x}{1 + x}}\right)
\tan^{-1} \left(\sqrt{\frac{1}{\sqrt[3]{1 + x} \cdot \sqrt[3]{1 + x}} \cdot \frac{1 - x}{\sqrt[3]{1 + x}}}\right) \cdot 2
double f(double x) {
        double r831656 = 2.0;
        double r831657 = 1.0;
        double r831658 = x;
        double r831659 = r831657 - r831658;
        double r831660 = r831657 + r831658;
        double r831661 = r831659 / r831660;
        double r831662 = sqrt(r831661);
        double r831663 = atan(r831662);
        double r831664 = r831656 * r831663;
        return r831664;
}

double f(double x) {
        double r831665 = 1.0;
        double r831666 = x;
        double r831667 = r831665 + r831666;
        double r831668 = cbrt(r831667);
        double r831669 = r831668 * r831668;
        double r831670 = r831665 / r831669;
        double r831671 = r831665 - r831666;
        double r831672 = r831671 / r831668;
        double r831673 = r831670 * r831672;
        double r831674 = sqrt(r831673);
        double r831675 = atan(r831674);
        double r831676 = 2.0;
        double r831677 = r831675 * r831676;
        return r831677;
}

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 add-cube-cbrt0.0

    \[\leadsto 2 \cdot \tan^{-1} \left(\sqrt{\frac{1 - x}{\color{blue}{\left(\sqrt[3]{1 + x} \cdot \sqrt[3]{1 + x}\right) \cdot \sqrt[3]{1 + x}}}}\right)\]
  4. Applied *-un-lft-identity0.0

    \[\leadsto 2 \cdot \tan^{-1} \left(\sqrt{\frac{1 - \color{blue}{1 \cdot x}}{\left(\sqrt[3]{1 + x} \cdot \sqrt[3]{1 + x}\right) \cdot \sqrt[3]{1 + x}}}\right)\]
  5. Applied *-un-lft-identity0.0

    \[\leadsto 2 \cdot \tan^{-1} \left(\sqrt{\frac{\color{blue}{1 \cdot 1} - 1 \cdot x}{\left(\sqrt[3]{1 + x} \cdot \sqrt[3]{1 + x}\right) \cdot \sqrt[3]{1 + x}}}\right)\]
  6. Applied distribute-lft-out--0.0

    \[\leadsto 2 \cdot \tan^{-1} \left(\sqrt{\frac{\color{blue}{1 \cdot \left(1 - x\right)}}{\left(\sqrt[3]{1 + x} \cdot \sqrt[3]{1 + x}\right) \cdot \sqrt[3]{1 + x}}}\right)\]
  7. Applied times-frac0.0

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

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

Reproduce

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