Average Error: 0.1 → 0.1
Time: 10.1s
Precision: 64
\[x \cdot \left(\left(\left(\left(y + z\right) + z\right) + y\right) + t\right) + y \cdot 5\]
\[y \cdot 5 + \left(2 \cdot \left(z + y\right) + t\right) \cdot x\]
x \cdot \left(\left(\left(\left(y + z\right) + z\right) + y\right) + t\right) + y \cdot 5
y \cdot 5 + \left(2 \cdot \left(z + y\right) + t\right) \cdot x
double f(double x, double y, double z, double t) {
        double r764 = x;
        double r765 = y;
        double r766 = z;
        double r767 = r765 + r766;
        double r768 = r767 + r766;
        double r769 = r768 + r765;
        double r770 = t;
        double r771 = r769 + r770;
        double r772 = r764 * r771;
        double r773 = 5.0;
        double r774 = r765 * r773;
        double r775 = r772 + r774;
        return r775;
}

double f(double x, double y, double z, double t) {
        double r776 = y;
        double r777 = 5.0;
        double r778 = r776 * r777;
        double r779 = 2.0;
        double r780 = z;
        double r781 = r780 + r776;
        double r782 = r779 * r781;
        double r783 = t;
        double r784 = r782 + r783;
        double r785 = x;
        double r786 = r784 * r785;
        double r787 = r778 + r786;
        return r787;
}

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

Derivation

  1. Initial program 0.1

    \[x \cdot \left(\left(\left(\left(y + z\right) + z\right) + y\right) + t\right) + y \cdot 5\]
  2. Using strategy rm
  3. Applied *-un-lft-identity0.1

    \[\leadsto \color{blue}{\left(1 \cdot x\right)} \cdot \left(\left(\left(\left(y + z\right) + z\right) + y\right) + t\right) + y \cdot 5\]
  4. Applied associate-*l*0.1

    \[\leadsto \color{blue}{1 \cdot \left(x \cdot \left(\left(\left(\left(y + z\right) + z\right) + y\right) + t\right)\right)} + y \cdot 5\]
  5. Simplified0.1

    \[\leadsto 1 \cdot \color{blue}{\left(\left(2 \cdot \left(z + y\right) + t\right) \cdot x\right)} + y \cdot 5\]
  6. Final simplification0.1

    \[\leadsto y \cdot 5 + \left(2 \cdot \left(z + y\right) + t\right) \cdot x\]

Reproduce

herbie shell --seed 2020025 
(FPCore (x y z t)
  :name "Graphics.Rendering.Plot.Render.Plot.Legend:renderLegendOutside from plot-0.2.3.4, B"
  :precision binary64
  (+ (* x (+ (+ (+ (+ y z) z) y) t)) (* y 5)))