Average Error: 52.0 → 52.0
Time: 7.0s
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 r65967 = 9.0;
        double r65968 = x;
        double r65969 = 4.0;
        double r65970 = pow(r65968, r65969);
        double r65971 = r65967 * r65970;
        double r65972 = y;
        double r65973 = pow(r65972, r65969);
        double r65974 = r65971 - r65973;
        double r65975 = 2.0;
        double r65976 = r65972 * r65972;
        double r65977 = r65975 * r65976;
        double r65978 = r65974 + r65977;
        return r65978;
}

double f(double x, double y) {
        double r65979 = 2.0;
        double r65980 = y;
        double r65981 = r65979 * r65980;
        double r65982 = x;
        double r65983 = 4.0;
        double r65984 = pow(r65982, r65983);
        double r65985 = 9.0;
        double r65986 = pow(r65980, r65983);
        double r65987 = -r65986;
        double r65988 = fma(r65984, r65985, r65987);
        double r65989 = 3.0;
        double r65990 = pow(r65988, r65989);
        double r65991 = cbrt(r65990);
        double r65992 = fma(r65981, r65980, r65991);
        return r65992;
}

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