Average Error: 62.0 → 52.0
Time: 2.6s
Precision: 64
\[x = 10864 \land y = 18817\]
\[9 \cdot {x}^{4} - \left(y \cdot y\right) \cdot \left(y \cdot y - 2\right)\]
\[\sqrt[3]{{\left(\mathsf{fma}\left({x}^{4}, 9, -{y}^{4}\right)\right)}^{3}} - \left(-2\right) \cdot \left(y \cdot y\right)\]
9 \cdot {x}^{4} - \left(y \cdot y\right) \cdot \left(y \cdot y - 2\right)
\sqrt[3]{{\left(\mathsf{fma}\left({x}^{4}, 9, -{y}^{4}\right)\right)}^{3}} - \left(-2\right) \cdot \left(y \cdot y\right)
double f(double x, double y) {
        double r73704 = 9.0;
        double r73705 = x;
        double r73706 = 4.0;
        double r73707 = pow(r73705, r73706);
        double r73708 = r73704 * r73707;
        double r73709 = y;
        double r73710 = r73709 * r73709;
        double r73711 = 2.0;
        double r73712 = r73710 - r73711;
        double r73713 = r73710 * r73712;
        double r73714 = r73708 - r73713;
        return r73714;
}

double f(double x, double y) {
        double r73715 = x;
        double r73716 = 4.0;
        double r73717 = pow(r73715, r73716);
        double r73718 = 9.0;
        double r73719 = y;
        double r73720 = 4.0;
        double r73721 = pow(r73719, r73720);
        double r73722 = -r73721;
        double r73723 = fma(r73717, r73718, r73722);
        double r73724 = 3.0;
        double r73725 = pow(r73723, r73724);
        double r73726 = cbrt(r73725);
        double r73727 = 2.0;
        double r73728 = -r73727;
        double r73729 = r73719 * r73719;
        double r73730 = r73728 * r73729;
        double r73731 = r73726 - r73730;
        return r73731;
}

Error

Derivation

  1. Initial program 62.0

    \[9 \cdot {x}^{4} - \left(y \cdot y\right) \cdot \left(y \cdot y - 2\right)\]
  2. Using strategy rm
  3. Applied sub-neg62.0

    \[\leadsto 9 \cdot {x}^{4} - \left(y \cdot y\right) \cdot \color{blue}{\left(y \cdot y + \left(-2\right)\right)}\]
  4. Applied distribute-rgt-in62.0

    \[\leadsto 9 \cdot {x}^{4} - \color{blue}{\left(\left(y \cdot y\right) \cdot \left(y \cdot y\right) + \left(-2\right) \cdot \left(y \cdot y\right)\right)}\]
  5. Applied associate--r+52.0

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

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

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

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

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

Reproduce

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