Average Error: 52.0 → 52.0
Time: 12.4s
Precision: 64
\[x = 10864 \land y = 18817\]
\[\left(9 \cdot {x}^{4} - {y}^{4}\right) + 2 \cdot \left(y \cdot y\right)\]
\[\mathsf{fma}\left(2 \cdot y, y, \sqrt[3]{{\left(\mathsf{fma}\left({x}^{4}, 9, -{y}^{4}\right)\right)}^{3}}\right)\]
\left(9 \cdot {x}^{4} - {y}^{4}\right) + 2 \cdot \left(y \cdot y\right)
\mathsf{fma}\left(2 \cdot y, y, \sqrt[3]{{\left(\mathsf{fma}\left({x}^{4}, 9, -{y}^{4}\right)\right)}^{3}}\right)
double f(double x, double y) {
        double r60274 = 9.0;
        double r60275 = x;
        double r60276 = 4.0;
        double r60277 = pow(r60275, r60276);
        double r60278 = r60274 * r60277;
        double r60279 = y;
        double r60280 = pow(r60279, r60276);
        double r60281 = r60278 - r60280;
        double r60282 = 2.0;
        double r60283 = r60279 * r60279;
        double r60284 = r60282 * r60283;
        double r60285 = r60281 + r60284;
        return r60285;
}

double f(double x, double y) {
        double r60286 = 2.0;
        double r60287 = y;
        double r60288 = r60286 * r60287;
        double r60289 = x;
        double r60290 = 4.0;
        double r60291 = pow(r60289, r60290);
        double r60292 = 9.0;
        double r60293 = pow(r60287, r60290);
        double r60294 = -r60293;
        double r60295 = fma(r60291, r60292, r60294);
        double r60296 = 3.0;
        double r60297 = pow(r60295, r60296);
        double r60298 = cbrt(r60297);
        double r60299 = fma(r60288, r60287, r60298);
        return r60299;
}

Error

Derivation

  1. Initial program 52.0

    \[\left(9 \cdot {x}^{4} - {y}^{4}\right) + 2 \cdot \left(y \cdot y\right)\]
  2. Simplified52.0

    \[\leadsto \color{blue}{\mathsf{fma}\left(2 \cdot y, y, 9 \cdot {x}^{4} - {y}^{4}\right)}\]
  3. Using strategy rm
  4. Applied add-cbrt-cube52.0

    \[\leadsto \mathsf{fma}\left(2 \cdot y, y, \color{blue}{\sqrt[3]{\left(\left(9 \cdot {x}^{4} - {y}^{4}\right) \cdot \left(9 \cdot {x}^{4} - {y}^{4}\right)\right) \cdot \left(9 \cdot {x}^{4} - {y}^{4}\right)}}\right)\]
  5. Simplified52.0

    \[\leadsto \mathsf{fma}\left(2 \cdot y, y, \sqrt[3]{\color{blue}{{\left(\mathsf{fma}\left({x}^{4}, 9, -{y}^{4}\right)\right)}^{3}}}\right)\]
  6. Final simplification52.0

    \[\leadsto \mathsf{fma}\left(2 \cdot y, y, \sqrt[3]{{\left(\mathsf{fma}\left({x}^{4}, 9, -{y}^{4}\right)\right)}^{3}}\right)\]

Reproduce

herbie shell --seed 2019325 +o rules:numerics
(FPCore (x y)
  :name "From Rump in a 1983 paper"
  :precision binary64
  :pre (and (== x 10864) (== y 18817))
  (+ (- (* 9 (pow x 4)) (pow y 4)) (* 2 (* y y))))