Average Error: 0 → 0
Time: 1.1s
Precision: 64
\[\left(x \cdot 2.0\right) \cdot x\]
\[x \cdot \left(x \cdot 2.0\right)\]
\left(x \cdot 2.0\right) \cdot x
x \cdot \left(x \cdot 2.0\right)
double f(double x) {
        double r9072733 = x;
        double r9072734 = 2.0;
        double r9072735 = r9072733 * r9072734;
        double r9072736 = r9072735 * r9072733;
        return r9072736;
}

double f(double x) {
        double r9072737 = x;
        double r9072738 = 2.0;
        double r9072739 = r9072737 * r9072738;
        double r9072740 = r9072737 * r9072739;
        return r9072740;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original0
Target0
Herbie0
\[\left(2.0 \cdot x\right) \cdot x\]

Derivation

  1. Initial program 0

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

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

Reproduce

herbie shell --seed 2019156 
(FPCore (x)
  :name "Numeric.Log:$cexpm1 from log-domain-0.10.2.1, A"

  :herbie-target
  (* (* 2.0 x) x)

  (* (* x 2.0) x))