Average Error: 19.5 → 0.1
Time: 3.4s
Precision: binary64
\[\]
\[\]
double code(double x, double y) {
	return ((double) (((double) (x * y)) / ((double) (((double) (((double) (x + y)) * ((double) (x + y)))) * ((double) (((double) (x + y)) + 1.0))))));
}
double code(double x, double y) {
	return ((double) (((double) (((double) (x * ((double) (y / ((double) (x + y)))))) / ((double) (x + y)))) / ((double) (x + ((double) (y + 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

Original19.5
Target0.1
Herbie0.1
\[\]

Derivation

  1. Initial program 19.5

    \[\]
  2. Simplified11.8

    \[\leadsto \]
  3. Using strategy rm
  4. Applied *-un-lft-identity11.8

    \[\leadsto \]
  5. Applied times-frac5.8

    \[\leadsto \]
  6. Applied associate-*r*4.1

    \[\leadsto \]
  7. Simplified4.0

    \[\leadsto \]
  8. Using strategy rm
  9. Applied associate-/r*0.1

    \[\leadsto \]
  10. Simplified0.1

    \[\leadsto \]
  11. Using strategy rm
  12. Applied associate-*r/0.1

    \[\leadsto \]
  13. Simplified0.1

    \[\leadsto \]
  14. Using strategy rm
  15. Applied associate-*r/0.1

    \[\leadsto \]
  16. Simplified0.1

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

    \[\leadsto \]

Reproduce

herbie shell --seed 2020191 
(FPCore (x y)
  :name "Numeric.SpecFunctions:incompleteBetaApprox from math-functions-0.1.5.2, A"
  :precision binary64

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

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