Average Error: 0.0 → 0.0
Time: 17.4s
Precision: 64
\[0.0 \le x \le 2\]
\[x \cdot \left(x \cdot x\right) + x \cdot x\]
\[\left(x \cdot x\right) \cdot x + x \cdot x\]
x \cdot \left(x \cdot x\right) + x \cdot x
\left(x \cdot x\right) \cdot x + x \cdot x
double f(double x) {
        double r3881884 = x;
        double r3881885 = r3881884 * r3881884;
        double r3881886 = r3881884 * r3881885;
        double r3881887 = r3881886 + r3881885;
        return r3881887;
}

double f(double x) {
        double r3881888 = x;
        double r3881889 = r3881888 * r3881888;
        double r3881890 = r3881889 * r3881888;
        double r3881891 = r3881890 + r3881889;
        return r3881891;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original0.0
Target0.0
Herbie0.0
\[\left(\left(1 + x\right) \cdot x\right) \cdot x\]

Derivation

  1. Initial program 0.0

    \[x \cdot \left(x \cdot x\right) + x \cdot x\]
  2. Final simplification0.0

    \[\leadsto \left(x \cdot x\right) \cdot x + x \cdot x\]

Reproduce

herbie shell --seed 2019200 +o rules:numerics
(FPCore (x)
  :name "Expression 3, p15"
  :pre (<= 0.0 x 2.0)

  :herbie-target
  (* (* (+ 1.0 x) x) x)

  (+ (* x (* x x)) (* x x)))