Average Error: 0.2 → 0.9
Time: 31.0s
Precision: 64
\[\left(-x \cdot \frac{1}{\tan B}\right) + \frac{1}{\sin B}\]
\[\frac{\frac{1}{\sqrt[3]{\sin B} \cdot \sqrt[3]{\sin B}}}{\sqrt[3]{\sin B}} - \frac{x}{\tan B}\]
\left(-x \cdot \frac{1}{\tan B}\right) + \frac{1}{\sin B}
\frac{\frac{1}{\sqrt[3]{\sin B} \cdot \sqrt[3]{\sin B}}}{\sqrt[3]{\sin B}} - \frac{x}{\tan B}
double f(double B, double x) {
        double r761197 = x;
        double r761198 = 1.0;
        double r761199 = B;
        double r761200 = tan(r761199);
        double r761201 = r761198 / r761200;
        double r761202 = r761197 * r761201;
        double r761203 = -r761202;
        double r761204 = sin(r761199);
        double r761205 = r761198 / r761204;
        double r761206 = r761203 + r761205;
        return r761206;
}

double f(double B, double x) {
        double r761207 = 1.0;
        double r761208 = B;
        double r761209 = sin(r761208);
        double r761210 = cbrt(r761209);
        double r761211 = r761210 * r761210;
        double r761212 = r761207 / r761211;
        double r761213 = r761212 / r761210;
        double r761214 = x;
        double r761215 = tan(r761208);
        double r761216 = r761214 / r761215;
        double r761217 = r761213 - r761216;
        return r761217;
}

Error

Bits error versus B

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.2

    \[\left(-x \cdot \frac{1}{\tan B}\right) + \frac{1}{\sin B}\]
  2. Simplified0.2

    \[\leadsto \color{blue}{\frac{1}{\sin B} - \frac{x}{\tan B}}\]
  3. Using strategy rm
  4. Applied add-cube-cbrt0.9

    \[\leadsto \frac{1}{\color{blue}{\left(\sqrt[3]{\sin B} \cdot \sqrt[3]{\sin B}\right) \cdot \sqrt[3]{\sin B}}} - \frac{x}{\tan B}\]
  5. Applied associate-/r*0.9

    \[\leadsto \color{blue}{\frac{\frac{1}{\sqrt[3]{\sin B} \cdot \sqrt[3]{\sin B}}}{\sqrt[3]{\sin B}}} - \frac{x}{\tan B}\]
  6. Final simplification0.9

    \[\leadsto \frac{\frac{1}{\sqrt[3]{\sin B} \cdot \sqrt[3]{\sin B}}}{\sqrt[3]{\sin B}} - \frac{x}{\tan B}\]

Reproduce

herbie shell --seed 2019125 
(FPCore (B x)
  :name "VandenBroeck and Keller, Equation (24)"
  (+ (- (* x (/ 1 (tan B)))) (/ 1 (sin B))))