Average Error: 0.1 → 0.1
Time: 1.1s
Precision: binary64
\[\left(\left(\left(\left(1 + x\right) + x \cdot x\right) + \left(x \cdot x\right) \cdot x\right) + \left(\left(x \cdot x\right) \cdot x\right) \cdot x\right) + \left(\left(\left(x \cdot x\right) \cdot x\right) \cdot x\right) \cdot x\]
\[x + \left(1 + x \cdot \left(\left(x + 1\right) \cdot \left(x + {x}^{3}\right)\right)\right)\]
\left(\left(\left(\left(1 + x\right) + x \cdot x\right) + \left(x \cdot x\right) \cdot x\right) + \left(\left(x \cdot x\right) \cdot x\right) \cdot x\right) + \left(\left(\left(x \cdot x\right) \cdot x\right) \cdot x\right) \cdot x
x + \left(1 + x \cdot \left(\left(x + 1\right) \cdot \left(x + {x}^{3}\right)\right)\right)
double code(double x) {
	return ((double) (((double) (((double) (((double) (((double) (1.0 + x)) + ((double) (x * x)))) + ((double) (((double) (x * x)) * x)))) + ((double) (((double) (((double) (x * x)) * x)) * x)))) + ((double) (((double) (((double) (((double) (x * x)) * x)) * x)) * x))));
}
double code(double x) {
	return ((double) (x + ((double) (1.0 + ((double) (x * ((double) (((double) (x + 1.0)) * ((double) (x + ((double) pow(x, 3.0))))))))))));
}

Error

Bits error versus x

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Derivation

  1. Initial program 0.1

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

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

    \[\leadsto x + \left(1 + x \cdot \left(\left(x + 1\right) \cdot \left(x + {x}^{3}\right)\right)\right)\]

Reproduce

herbie shell --seed 2020153 
(FPCore (x)
  :name "(+ (+ (+ (+ (+ 1 x) (* x x)) (* (* x x) x)) (* (* (* x x) x) x)) (* (* (* (* x x) x) x) x))"
  :precision binary64
  (+ (+ (+ (+ (+ 1.0 x) (* x x)) (* (* x x) x)) (* (* (* x x) x) x)) (* (* (* (* x x) x) x) x)))