Average Error: 10.6 → 1.1
Time: 5.7s
Precision: 64
\[x + \frac{\left(y - z\right) \cdot t}{a - z}\]
\[x + \frac{\sqrt[3]{y - z}}{\frac{\sqrt[3]{a - z} \cdot \sqrt[3]{a - z}}{\sqrt[3]{y - z}}} \cdot \frac{\sqrt[3]{y - z}}{\frac{\sqrt[3]{a - z}}{t}}\]
x + \frac{\left(y - z\right) \cdot t}{a - z}
x + \frac{\sqrt[3]{y - z}}{\frac{\sqrt[3]{a - z} \cdot \sqrt[3]{a - z}}{\sqrt[3]{y - z}}} \cdot \frac{\sqrt[3]{y - z}}{\frac{\sqrt[3]{a - z}}{t}}
double f(double x, double y, double z, double t, double a) {
        double r609887 = x;
        double r609888 = y;
        double r609889 = z;
        double r609890 = r609888 - r609889;
        double r609891 = t;
        double r609892 = r609890 * r609891;
        double r609893 = a;
        double r609894 = r609893 - r609889;
        double r609895 = r609892 / r609894;
        double r609896 = r609887 + r609895;
        return r609896;
}

double f(double x, double y, double z, double t, double a) {
        double r609897 = x;
        double r609898 = y;
        double r609899 = z;
        double r609900 = r609898 - r609899;
        double r609901 = cbrt(r609900);
        double r609902 = a;
        double r609903 = r609902 - r609899;
        double r609904 = cbrt(r609903);
        double r609905 = r609904 * r609904;
        double r609906 = r609905 / r609901;
        double r609907 = r609901 / r609906;
        double r609908 = t;
        double r609909 = r609904 / r609908;
        double r609910 = r609901 / r609909;
        double r609911 = r609907 * r609910;
        double r609912 = r609897 + r609911;
        return r609912;
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Bits error versus t

Bits error versus a

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original10.6
Target0.6
Herbie1.1
\[\begin{array}{l} \mathbf{if}\;t \lt -1.0682974490174067 \cdot 10^{-39}:\\ \;\;\;\;x + \frac{y - z}{a - z} \cdot t\\ \mathbf{elif}\;t \lt 3.9110949887586375 \cdot 10^{-141}:\\ \;\;\;\;x + \frac{\left(y - z\right) \cdot t}{a - z}\\ \mathbf{else}:\\ \;\;\;\;x + \frac{y - z}{a - z} \cdot t\\ \end{array}\]

Derivation

  1. Initial program 10.6

    \[x + \frac{\left(y - z\right) \cdot t}{a - z}\]
  2. Using strategy rm
  3. Applied associate-/l*3.1

    \[\leadsto x + \color{blue}{\frac{y - z}{\frac{a - z}{t}}}\]
  4. Using strategy rm
  5. Applied *-un-lft-identity3.1

    \[\leadsto x + \frac{y - z}{\frac{a - z}{\color{blue}{1 \cdot t}}}\]
  6. Applied add-cube-cbrt3.5

    \[\leadsto x + \frac{y - z}{\frac{\color{blue}{\left(\sqrt[3]{a - z} \cdot \sqrt[3]{a - z}\right) \cdot \sqrt[3]{a - z}}}{1 \cdot t}}\]
  7. Applied times-frac3.5

    \[\leadsto x + \frac{y - z}{\color{blue}{\frac{\sqrt[3]{a - z} \cdot \sqrt[3]{a - z}}{1} \cdot \frac{\sqrt[3]{a - z}}{t}}}\]
  8. Applied add-cube-cbrt3.5

    \[\leadsto x + \frac{\color{blue}{\left(\sqrt[3]{y - z} \cdot \sqrt[3]{y - z}\right) \cdot \sqrt[3]{y - z}}}{\frac{\sqrt[3]{a - z} \cdot \sqrt[3]{a - z}}{1} \cdot \frac{\sqrt[3]{a - z}}{t}}\]
  9. Applied times-frac1.1

    \[\leadsto x + \color{blue}{\frac{\sqrt[3]{y - z} \cdot \sqrt[3]{y - z}}{\frac{\sqrt[3]{a - z} \cdot \sqrt[3]{a - z}}{1}} \cdot \frac{\sqrt[3]{y - z}}{\frac{\sqrt[3]{a - z}}{t}}}\]
  10. Simplified1.1

    \[\leadsto x + \color{blue}{\frac{\sqrt[3]{y - z}}{\frac{\sqrt[3]{a - z} \cdot \sqrt[3]{a - z}}{\sqrt[3]{y - z}}}} \cdot \frac{\sqrt[3]{y - z}}{\frac{\sqrt[3]{a - z}}{t}}\]
  11. Final simplification1.1

    \[\leadsto x + \frac{\sqrt[3]{y - z}}{\frac{\sqrt[3]{a - z} \cdot \sqrt[3]{a - z}}{\sqrt[3]{y - z}}} \cdot \frac{\sqrt[3]{y - z}}{\frac{\sqrt[3]{a - z}}{t}}\]

Reproduce

herbie shell --seed 2020083 
(FPCore (x y z t a)
  :name "Graphics.Rendering.Plot.Render.Plot.Axis:renderAxisTick from plot-0.2.3.4, A"
  :precision binary64

  :herbie-target
  (if (< t -1.0682974490174067e-39) (+ x (* (/ (- y z) (- a z)) t)) (if (< t 3.9110949887586375e-141) (+ x (/ (* (- y z) t) (- a z))) (+ x (* (/ (- y z) (- a z)) t))))

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