Average Error: 0 → 0
Time: 312.0ms
Precision: 64
\[\left(x \cdot 2\right) \cdot x\]
\[\left(x \cdot 2\right) \cdot x\]
\left(x \cdot 2\right) \cdot x
\left(x \cdot 2\right) \cdot x
double f(double x) {
        double r678450 = x;
        double r678451 = 2.0;
        double r678452 = r678450 * r678451;
        double r678453 = r678452 * r678450;
        return r678453;
}

double f(double x) {
        double r678454 = x;
        double r678455 = 2.0;
        double r678456 = r678454 * r678455;
        double r678457 = r678456 * r678454;
        return r678457;
}

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 \cdot x\right) \cdot x\]

Derivation

  1. Initial program 0

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

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

Reproduce

herbie shell --seed 2020045 +o rules:numerics
(FPCore (x)
  :name "Numeric.Log:$cexpm1 from log-domain-0.10.2.1, A"
  :precision binary64

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

  (* (* x 2) x))