Average Error: 0.0 → 0.4
Time: 25.2s
Precision: 64
\[x + \left(y - z\right) \cdot \left(t - x\right)\]
\[\left(x + t \cdot \left(y - z\right)\right) + \left(\sqrt[3]{x} \cdot \sqrt[3]{x}\right) \cdot \left(\left(-\sqrt[3]{x}\right) \cdot \left(y - z\right)\right)\]
x + \left(y - z\right) \cdot \left(t - x\right)
\left(x + t \cdot \left(y - z\right)\right) + \left(\sqrt[3]{x} \cdot \sqrt[3]{x}\right) \cdot \left(\left(-\sqrt[3]{x}\right) \cdot \left(y - z\right)\right)
double f(double x, double y, double z, double t) {
        double r910341 = x;
        double r910342 = y;
        double r910343 = z;
        double r910344 = r910342 - r910343;
        double r910345 = t;
        double r910346 = r910345 - r910341;
        double r910347 = r910344 * r910346;
        double r910348 = r910341 + r910347;
        return r910348;
}

double f(double x, double y, double z, double t) {
        double r910349 = x;
        double r910350 = t;
        double r910351 = y;
        double r910352 = z;
        double r910353 = r910351 - r910352;
        double r910354 = r910350 * r910353;
        double r910355 = r910349 + r910354;
        double r910356 = cbrt(r910349);
        double r910357 = r910356 * r910356;
        double r910358 = -r910356;
        double r910359 = r910358 * r910353;
        double r910360 = r910357 * r910359;
        double r910361 = r910355 + r910360;
        return r910361;
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original0.0
Target0.0
Herbie0.4
\[x + \left(t \cdot \left(y - z\right) + \left(-x\right) \cdot \left(y - z\right)\right)\]

Derivation

  1. Initial program 0.0

    \[x + \left(y - z\right) \cdot \left(t - x\right)\]
  2. Using strategy rm
  3. Applied sub-neg0.0

    \[\leadsto x + \left(y - z\right) \cdot \color{blue}{\left(t + \left(-x\right)\right)}\]
  4. Applied distribute-rgt-in0.0

    \[\leadsto x + \color{blue}{\left(t \cdot \left(y - z\right) + \left(-x\right) \cdot \left(y - z\right)\right)}\]
  5. Applied associate-+r+0.0

    \[\leadsto \color{blue}{\left(x + t \cdot \left(y - z\right)\right) + \left(-x\right) \cdot \left(y - z\right)}\]
  6. Using strategy rm
  7. Applied add-cube-cbrt0.4

    \[\leadsto \left(x + t \cdot \left(y - z\right)\right) + \left(-\color{blue}{\left(\sqrt[3]{x} \cdot \sqrt[3]{x}\right) \cdot \sqrt[3]{x}}\right) \cdot \left(y - z\right)\]
  8. Applied distribute-rgt-neg-in0.4

    \[\leadsto \left(x + t \cdot \left(y - z\right)\right) + \color{blue}{\left(\left(\sqrt[3]{x} \cdot \sqrt[3]{x}\right) \cdot \left(-\sqrt[3]{x}\right)\right)} \cdot \left(y - z\right)\]
  9. Applied associate-*l*0.4

    \[\leadsto \left(x + t \cdot \left(y - z\right)\right) + \color{blue}{\left(\sqrt[3]{x} \cdot \sqrt[3]{x}\right) \cdot \left(\left(-\sqrt[3]{x}\right) \cdot \left(y - z\right)\right)}\]
  10. Final simplification0.4

    \[\leadsto \left(x + t \cdot \left(y - z\right)\right) + \left(\sqrt[3]{x} \cdot \sqrt[3]{x}\right) \cdot \left(\left(-\sqrt[3]{x}\right) \cdot \left(y - z\right)\right)\]

Reproduce

herbie shell --seed 2020047 
(FPCore (x y z t)
  :name "Data.Metrics.Snapshot:quantile from metrics-0.3.0.2"
  :precision binary64

  :herbie-target
  (+ x (+ (* t (- y z)) (* (- x) (- y z))))

  (+ x (* (- y z) (- t x))))