Average Error: 0.1 → 0.1
Time: 11.1s
Precision: 64
\[\left(\left(\left(\left(x + y\right) + y\right) + x\right) + z\right) + x\]
\[3 \cdot x + \left(z + 2 \cdot y\right)\]
\left(\left(\left(\left(x + y\right) + y\right) + x\right) + z\right) + x
3 \cdot x + \left(z + 2 \cdot y\right)
double f(double x, double y, double z) {
        double r147021 = x;
        double r147022 = y;
        double r147023 = r147021 + r147022;
        double r147024 = r147023 + r147022;
        double r147025 = r147024 + r147021;
        double r147026 = z;
        double r147027 = r147025 + r147026;
        double r147028 = r147027 + r147021;
        return r147028;
}

double f(double x, double y, double z) {
        double r147029 = 3.0;
        double r147030 = x;
        double r147031 = r147029 * r147030;
        double r147032 = z;
        double r147033 = 2.0;
        double r147034 = y;
        double r147035 = r147033 * r147034;
        double r147036 = r147032 + r147035;
        double r147037 = r147031 + r147036;
        return r147037;
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.1

    \[\left(\left(\left(\left(x + y\right) + y\right) + x\right) + z\right) + x\]
  2. Simplified0.1

    \[\leadsto \color{blue}{x + \left(z + 2 \cdot \left(x + y\right)\right)}\]
  3. Taylor expanded around 0 0.1

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

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

Reproduce

herbie shell --seed 2019326 
(FPCore (x y z)
  :name "Graphics.Rendering.Plot.Render.Plot.Legend:renderLegendInside from plot-0.2.3.4"
  :precision binary64
  (+ (+ (+ (+ (+ x y) y) x) z) x))