Average Error: 58.1 → 57.1
Time: 4.6s
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 r11584 = 333.75;
        double r11585 = y;
        double r11586 = 6.0;
        double r11587 = pow(r11585, r11586);
        double r11588 = r11584 * r11587;
        double r11589 = x;
        double r11590 = r11589 * r11589;
        double r11591 = 11.0;
        double r11592 = r11591 * r11589;
        double r11593 = r11592 * r11589;
        double r11594 = r11593 * r11585;
        double r11595 = r11594 * r11585;
        double r11596 = r11595 - r11587;
        double r11597 = 121.0;
        double r11598 = 4.0;
        double r11599 = pow(r11585, r11598);
        double r11600 = r11597 * r11599;
        double r11601 = r11596 - r11600;
        double r11602 = 2.0;
        double r11603 = r11601 - r11602;
        double r11604 = r11590 * r11603;
        double r11605 = r11588 + r11604;
        double r11606 = 5.5;
        double r11607 = 8.0;
        double r11608 = pow(r11585, r11607);
        double r11609 = r11606 * r11608;
        double r11610 = r11605 + r11609;
        double r11611 = r11602 * r11585;
        double r11612 = r11589 / r11611;
        double r11613 = r11610 + r11612;
        return r11613;
}

double f(double x, double y) {
        double r11614 = 0.5;
        double r11615 = x;
        double r11616 = y;
        double r11617 = r11615 / r11616;
        double r11618 = r11614 * r11617;
        double r11619 = 2.0;
        double r11620 = 2.0;
        double r11621 = pow(r11615, r11620);
        double r11622 = r11619 * r11621;
        double r11623 = r11618 - r11622;
        return r11623;
}

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 2020045 +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))))