Average Error: 62.0 → 52.0
Time: 2.4s
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(y \cdot y\right) \cdot \left(-2\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(y \cdot y\right) \cdot \left(-2\right)
double f(double x, double y) {
        double r79872 = 9.0;
        double r79873 = x;
        double r79874 = 4.0;
        double r79875 = pow(r79873, r79874);
        double r79876 = r79872 * r79875;
        double r79877 = y;
        double r79878 = r79877 * r79877;
        double r79879 = 2.0;
        double r79880 = r79878 - r79879;
        double r79881 = r79878 * r79880;
        double r79882 = r79876 - r79881;
        return r79882;
}

double f(double x, double y) {
        double r79883 = x;
        double r79884 = 4.0;
        double r79885 = pow(r79883, r79884);
        double r79886 = 9.0;
        double r79887 = y;
        double r79888 = 4.0;
        double r79889 = pow(r79887, r79888);
        double r79890 = -r79889;
        double r79891 = fma(r79885, r79886, r79890);
        double r79892 = 3.0;
        double r79893 = pow(r79891, r79892);
        double r79894 = cbrt(r79893);
        double r79895 = r79887 * r79887;
        double r79896 = 2.0;
        double r79897 = -r79896;
        double r79898 = r79895 * r79897;
        double r79899 = r79894 - r79898;
        return r79899;
}

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-lft-in62.0

    \[\leadsto 9 \cdot {x}^{4} - \color{blue}{\left(\left(y \cdot y\right) \cdot \left(y \cdot y\right) + \left(y \cdot y\right) \cdot \left(-2\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(y \cdot y\right) \cdot \left(-2\right)}\]
  6. Simplified52.0

    \[\leadsto \color{blue}{\mathsf{fma}\left({x}^{4}, 9, -{y}^{4}\right)} - \left(y \cdot y\right) \cdot \left(-2\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(y \cdot y\right) \cdot \left(-2\right)\]
  9. Simplified52.0

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

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

Reproduce

herbie shell --seed 2019353 +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))))