Average Error: 19.4 → 0.4
Time: 12.3s
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{x}{x + y} \cdot \left(\frac{1}{\sqrt[3]{\left(x + y\right) + 1} \cdot \sqrt[3]{\left(x + y\right) + 1}} \cdot \frac{\frac{y}{\sqrt[3]{\left(x + y\right) + 1}}}{x + y}\right)\]
\frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}
\frac{x}{x + y} \cdot \left(\frac{1}{\sqrt[3]{\left(x + y\right) + 1} \cdot \sqrt[3]{\left(x + y\right) + 1}} \cdot \frac{\frac{y}{\sqrt[3]{\left(x + y\right) + 1}}}{x + y}\right)
double f(double x, double y) {
        double r323809 = x;
        double r323810 = y;
        double r323811 = r323809 * r323810;
        double r323812 = r323809 + r323810;
        double r323813 = r323812 * r323812;
        double r323814 = 1.0;
        double r323815 = r323812 + r323814;
        double r323816 = r323813 * r323815;
        double r323817 = r323811 / r323816;
        return r323817;
}

double f(double x, double y) {
        double r323818 = x;
        double r323819 = y;
        double r323820 = r323818 + r323819;
        double r323821 = r323818 / r323820;
        double r323822 = 1.0;
        double r323823 = 1.0;
        double r323824 = r323820 + r323823;
        double r323825 = cbrt(r323824);
        double r323826 = r323825 * r323825;
        double r323827 = r323822 / r323826;
        double r323828 = r323819 / r323825;
        double r323829 = r323828 / r323820;
        double r323830 = r323827 * r323829;
        double r323831 = r323821 * r323830;
        return r323831;
}

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

Derivation

  1. Initial program 19.4

    \[\frac{x \cdot y}{\left(\left(x + y\right) \cdot \left(x + y\right)\right) \cdot \left(\left(x + y\right) + 1\right)}\]
  2. Using strategy rm
  3. Applied times-frac8.0

    \[\leadsto \color{blue}{\frac{x}{\left(x + y\right) \cdot \left(x + y\right)} \cdot \frac{y}{\left(x + y\right) + 1}}\]
  4. Using strategy rm
  5. Applied associate-/r*0.2

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

    \[\leadsto \color{blue}{\left(\frac{x}{x + y} \cdot \frac{1}{x + y}\right)} \cdot \frac{y}{\left(x + y\right) + 1}\]
  8. Applied associate-*l*0.2

    \[\leadsto \color{blue}{\frac{x}{x + y} \cdot \left(\frac{1}{x + y} \cdot \frac{y}{\left(x + y\right) + 1}\right)}\]
  9. Simplified0.1

    \[\leadsto \frac{x}{x + y} \cdot \color{blue}{\frac{\frac{y}{\left(x + y\right) + 1}}{x + y}}\]
  10. Using strategy rm
  11. Applied *-un-lft-identity0.1

    \[\leadsto \frac{x}{x + y} \cdot \frac{\frac{y}{\left(x + y\right) + 1}}{\color{blue}{1 \cdot \left(x + y\right)}}\]
  12. Applied add-cube-cbrt0.4

    \[\leadsto \frac{x}{x + y} \cdot \frac{\frac{y}{\color{blue}{\left(\sqrt[3]{\left(x + y\right) + 1} \cdot \sqrt[3]{\left(x + y\right) + 1}\right) \cdot \sqrt[3]{\left(x + y\right) + 1}}}}{1 \cdot \left(x + y\right)}\]
  13. Applied *-un-lft-identity0.4

    \[\leadsto \frac{x}{x + y} \cdot \frac{\frac{\color{blue}{1 \cdot y}}{\left(\sqrt[3]{\left(x + y\right) + 1} \cdot \sqrt[3]{\left(x + y\right) + 1}\right) \cdot \sqrt[3]{\left(x + y\right) + 1}}}{1 \cdot \left(x + y\right)}\]
  14. Applied times-frac0.4

    \[\leadsto \frac{x}{x + y} \cdot \frac{\color{blue}{\frac{1}{\sqrt[3]{\left(x + y\right) + 1} \cdot \sqrt[3]{\left(x + y\right) + 1}} \cdot \frac{y}{\sqrt[3]{\left(x + y\right) + 1}}}}{1 \cdot \left(x + y\right)}\]
  15. Applied times-frac0.4

    \[\leadsto \frac{x}{x + y} \cdot \color{blue}{\left(\frac{\frac{1}{\sqrt[3]{\left(x + y\right) + 1} \cdot \sqrt[3]{\left(x + y\right) + 1}}}{1} \cdot \frac{\frac{y}{\sqrt[3]{\left(x + y\right) + 1}}}{x + y}\right)}\]
  16. Simplified0.4

    \[\leadsto \frac{x}{x + y} \cdot \left(\color{blue}{\frac{1}{\sqrt[3]{\left(x + y\right) + 1} \cdot \sqrt[3]{\left(x + y\right) + 1}}} \cdot \frac{\frac{y}{\sqrt[3]{\left(x + y\right) + 1}}}{x + y}\right)\]
  17. Final simplification0.4

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

Reproduce

herbie shell --seed 2019212 +o rules:numerics
(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))))