Average Error: 52.0 → 52.0
Time: 11.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({x}^{4} \cdot 9 - {y}^{4}\right) \cdot \left(\left({x}^{4} \cdot 9 - {y}^{4}\right) \cdot \left({x}^{4} \cdot 9 - {y}^{4}\right)\right)}\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({x}^{4} \cdot 9 - {y}^{4}\right) \cdot \left(\left({x}^{4} \cdot 9 - {y}^{4}\right) \cdot \left({x}^{4} \cdot 9 - {y}^{4}\right)\right)}\right)
double f(double x, double y) {
        double r2976676 = 9.0;
        double r2976677 = x;
        double r2976678 = 4.0;
        double r2976679 = pow(r2976677, r2976678);
        double r2976680 = r2976676 * r2976679;
        double r2976681 = y;
        double r2976682 = pow(r2976681, r2976678);
        double r2976683 = r2976680 - r2976682;
        double r2976684 = 2.0;
        double r2976685 = r2976681 * r2976681;
        double r2976686 = r2976684 * r2976685;
        double r2976687 = r2976683 + r2976686;
        return r2976687;
}

double f(double x, double y) {
        double r2976688 = 2.0;
        double r2976689 = y;
        double r2976690 = r2976688 * r2976689;
        double r2976691 = x;
        double r2976692 = 4.0;
        double r2976693 = pow(r2976691, r2976692);
        double r2976694 = 9.0;
        double r2976695 = r2976693 * r2976694;
        double r2976696 = pow(r2976689, r2976692);
        double r2976697 = r2976695 - r2976696;
        double r2976698 = r2976697 * r2976697;
        double r2976699 = r2976697 * r2976698;
        double r2976700 = cbrt(r2976699);
        double r2976701 = fma(r2976690, r2976689, r2976700);
        return r2976701;
}

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, {x}^{4} \cdot 9 - {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({x}^{4} \cdot 9 - {y}^{4}\right) \cdot \left({x}^{4} \cdot 9 - {y}^{4}\right)\right) \cdot \left({x}^{4} \cdot 9 - {y}^{4}\right)}}\right)\]
  5. Final simplification52.0

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

Reproduce

herbie shell --seed 2019192 +o rules:numerics
(FPCore (x y)
  :name "From Rump in a 1983 paper"
  :pre (and (== x 10864.0) (== y 18817.0))
  (+ (- (* 9.0 (pow x 4.0)) (pow y 4.0)) (* 2.0 (* y y))))