Average Error: 58.1 → 57.1
Time: 4.7s
Precision: 64
\[x = 77617 \land y = 33096\]
\[\left(\left(333.75 \cdot {y}^{6} + \left(x \cdot x\right) \cdot \left(\left(\left(\left(\left(\left(11 \cdot x\right) \cdot x\right) \cdot y\right) \cdot y - {y}^{6}\right) - 121 \cdot {y}^{4}\right) - 2\right)\right) + 5.5 \cdot {y}^{8}\right) + \frac{x}{2 \cdot y}\]
\[0.5 \cdot \frac{x}{y} - 2 \cdot {x}^{2}\]
\left(\left(333.75 \cdot {y}^{6} + \left(x \cdot x\right) \cdot \left(\left(\left(\left(\left(\left(11 \cdot x\right) \cdot x\right) \cdot y\right) \cdot y - {y}^{6}\right) - 121 \cdot {y}^{4}\right) - 2\right)\right) + 5.5 \cdot {y}^{8}\right) + \frac{x}{2 \cdot y}
0.5 \cdot \frac{x}{y} - 2 \cdot {x}^{2}
double f(double x, double y) {
        double r11546 = 333.75;
        double r11547 = y;
        double r11548 = 6.0;
        double r11549 = pow(r11547, r11548);
        double r11550 = r11546 * r11549;
        double r11551 = x;
        double r11552 = r11551 * r11551;
        double r11553 = 11.0;
        double r11554 = r11553 * r11551;
        double r11555 = r11554 * r11551;
        double r11556 = r11555 * r11547;
        double r11557 = r11556 * r11547;
        double r11558 = r11557 - r11549;
        double r11559 = 121.0;
        double r11560 = 4.0;
        double r11561 = pow(r11547, r11560);
        double r11562 = r11559 * r11561;
        double r11563 = r11558 - r11562;
        double r11564 = 2.0;
        double r11565 = r11563 - r11564;
        double r11566 = r11552 * r11565;
        double r11567 = r11550 + r11566;
        double r11568 = 5.5;
        double r11569 = 8.0;
        double r11570 = pow(r11547, r11569);
        double r11571 = r11568 * r11570;
        double r11572 = r11567 + r11571;
        double r11573 = r11564 * r11547;
        double r11574 = r11551 / r11573;
        double r11575 = r11572 + r11574;
        return r11575;
}

double f(double x, double y) {
        double r11576 = 0.5;
        double r11577 = x;
        double r11578 = y;
        double r11579 = r11577 / r11578;
        double r11580 = r11576 * r11579;
        double r11581 = 2.0;
        double r11582 = 2.0;
        double r11583 = pow(r11577, r11582);
        double r11584 = r11581 * r11583;
        double r11585 = r11580 - r11584;
        return r11585;
}

Error

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 58.1

    \[\left(\left(333.75 \cdot {y}^{6} + \left(x \cdot x\right) \cdot \left(\left(\left(\left(\left(\left(11 \cdot x\right) \cdot x\right) \cdot y\right) \cdot y - {y}^{6}\right) - 121 \cdot {y}^{4}\right) - 2\right)\right) + 5.5 \cdot {y}^{8}\right) + \frac{x}{2 \cdot y}\]
  2. Simplified58.1

    \[\leadsto \color{blue}{\mathsf{fma}\left(x \cdot \left(\left(\left(\left(11 \cdot x\right) \cdot x\right) \cdot y\right) \cdot y - \left({y}^{6} + \mathsf{fma}\left({y}^{4}, 121, 2\right)\right)\right), x, \mathsf{fma}\left(333.75, {y}^{6}, \mathsf{fma}\left(5.5, {y}^{8}, \frac{x}{2 \cdot y}\right)\right)\right)}\]
  3. Taylor expanded around 0 57.1

    \[\leadsto \color{blue}{0.5 \cdot \frac{x}{y} - 2 \cdot {x}^{2}}\]
  4. Final simplification57.1

    \[\leadsto 0.5 \cdot \frac{x}{y} - 2 \cdot {x}^{2}\]

Reproduce

herbie shell --seed 2020047 +o rules:numerics
(FPCore (x y)
  :name "Rump's expression from Stadtherr's award speech"
  :precision binary64
  :pre (and (== x 77617) (== y 33096))
  (+ (+ (+ (* 333.75 (pow y 6)) (* (* x x) (- (- (- (* (* (* (* 11 x) x) y) y) (pow y 6)) (* 121 (pow y 4))) 2))) (* 5.5 (pow y 8))) (/ x (* 2 y))))