Average Error: 0 → 0
Time: 28.5s
Precision: 64
\[\left(\left(\left(x + x\right) + x\right) + x\right) + x\]
\[5 \cdot x\]
\left(\left(\left(x + x\right) + x\right) + x\right) + x
5 \cdot x
double f(double x) {
        double r7268158 = x;
        double r7268159 = r7268158 + r7268158;
        double r7268160 = r7268159 + r7268158;
        double r7268161 = r7268160 + r7268158;
        double r7268162 = r7268161 + r7268158;
        return r7268162;
}

double f(double x) {
        double r7268163 = 5.0;
        double r7268164 = x;
        double r7268165 = r7268163 * r7268164;
        return r7268165;
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0

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

    \[\leadsto \color{blue}{5 \cdot x}\]
  3. Final simplification0

    \[\leadsto 5 \cdot x\]

Reproduce

herbie shell --seed 2019158 
(FPCore (x)
  :name "Main:i from "
  (+ (+ (+ (+ x x) x) x) x))