Average Error: 19.8 → 9.3
Time: 14.4s
Precision: 64
\[\frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}\]
\[\frac{\frac{x}{\sqrt{x \cdot x + y \cdot \left(2 \cdot x + y\right)}}}{\sqrt{x \cdot x + y \cdot \left(2 \cdot x + y\right)}} \cdot \frac{y}{\left(x + y\right) + 1}\]
\frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}
\frac{\frac{x}{\sqrt{x \cdot x + y \cdot \left(2 \cdot x + y\right)}}}{\sqrt{x \cdot x + y \cdot \left(2 \cdot x + y\right)}} \cdot \frac{y}{\left(x + y\right) + 1}
double f(double x, double y) {
        double r285244 = x;
        double r285245 = y;
        double r285246 = r285244 * r285245;
        double r285247 = r285244 + r285245;
        double r285248 = r285247 * r285247;
        double r285249 = 1.0;
        double r285250 = r285247 + r285249;
        double r285251 = r285248 * r285250;
        double r285252 = r285246 / r285251;
        return r285252;
}

double f(double x, double y) {
        double r285253 = x;
        double r285254 = r285253 * r285253;
        double r285255 = y;
        double r285256 = 2.0;
        double r285257 = r285256 * r285253;
        double r285258 = r285257 + r285255;
        double r285259 = r285255 * r285258;
        double r285260 = r285254 + r285259;
        double r285261 = sqrt(r285260);
        double r285262 = r285253 / r285261;
        double r285263 = r285262 / r285261;
        double r285264 = r285253 + r285255;
        double r285265 = 1.0;
        double r285266 = r285264 + r285265;
        double r285267 = r285255 / r285266;
        double r285268 = r285263 * r285267;
        return r285268;
}

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.8
Target0.1
Herbie9.3
\[\frac{\frac{\frac{x}{\left(y + 1\right) + x}}{y + x}}{\frac{1}{\frac{y}{y + x}}}\]

Derivation

  1. Initial program 19.8

    \[\frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}\]
  2. Taylor expanded around 0 19.8

    \[\leadsto \frac{x \cdot y}{\color{blue}{\left({x}^{2} + \left({y}^{2} + 2 \cdot \left(x \cdot y\right)\right)\right)} \cdot \left(\left(x + y\right) + 1\right)}\]
  3. Simplified19.8

    \[\leadsto \frac{x \cdot y}{\color{blue}{\left(x \cdot x + y \cdot \left(2 \cdot x + y\right)\right)} \cdot \left(\left(x + y\right) + 1\right)}\]
  4. Using strategy rm
  5. Applied times-frac9.3

    \[\leadsto \color{blue}{\frac{x}{x \cdot x + y \cdot \left(2 \cdot x + y\right)} \cdot \frac{y}{\left(x + y\right) + 1}}\]
  6. Using strategy rm
  7. Applied add-sqr-sqrt9.3

    \[\leadsto \frac{x}{\color{blue}{\sqrt{x \cdot x + y \cdot \left(2 \cdot x + y\right)} \cdot \sqrt{x \cdot x + y \cdot \left(2 \cdot x + y\right)}}} \cdot \frac{y}{\left(x + y\right) + 1}\]
  8. Applied associate-/r*9.3

    \[\leadsto \color{blue}{\frac{\frac{x}{\sqrt{x \cdot x + y \cdot \left(2 \cdot x + y\right)}}}{\sqrt{x \cdot x + y \cdot \left(2 \cdot x + y\right)}}} \cdot \frac{y}{\left(x + y\right) + 1}\]
  9. Final simplification9.3

    \[\leadsto \frac{\frac{x}{\sqrt{x \cdot x + y \cdot \left(2 \cdot x + y\right)}}}{\sqrt{x \cdot x + y \cdot \left(2 \cdot x + y\right)}} \cdot \frac{y}{\left(x + y\right) + 1}\]

Reproduce

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

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

  (/ (* x y) (* (* (+ x y) (+ x y)) (+ (+ x y) 1))))