Average Error: 9.4 → 0.1
Time: 3.2s
Precision: binary64
\[\]
\[\]
double code(double x, double y) {
	return ((double) (((double) (x * ((double) (((double) (x / y)) + 1.0)))) / ((double) (x + 1.0))));
}
double code(double x, double y) {
	return ((double) (x * ((double) (((double) (((double) (x / y)) + 1.0)) / ((double) (x + 1.0))))));
}

Error

Bits error versus x

Bits error versus y

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original9.4
Target0.1
Herbie0.1
\[\]

Derivation

  1. Initial program 9.4

    \[\]
  2. Simplified0.1

    \[\leadsto \]
  3. Final simplification0.1

    \[\leadsto \]

Reproduce

herbie shell --seed 2020180 
(FPCore (x y)
  :name "Codec.Picture.Types:toneMapping from JuicyPixels-3.2.6.1"
  :precision binary64

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

  (/ (* x (+ (/ x y) 1.0)) (+ x 1.0)))