Average Error: 6.3 → 6.1
Time: 12.0s
Precision: 64
\[\frac{\frac{1}{x}}{y \cdot \left(1 + z \cdot z\right)}\]
\[\frac{\sqrt[3]{\frac{1}{y}}}{\frac{\sqrt{1 + z \cdot z}}{\sqrt[3]{\frac{1}{y}}}} \cdot \frac{\frac{\sqrt[3]{\frac{1}{y}}}{x}}{\sqrt{1 + z \cdot z}}\]
\frac{\frac{1}{x}}{y \cdot \left(1 + z \cdot z\right)}
\frac{\sqrt[3]{\frac{1}{y}}}{\frac{\sqrt{1 + z \cdot z}}{\sqrt[3]{\frac{1}{y}}}} \cdot \frac{\frac{\sqrt[3]{\frac{1}{y}}}{x}}{\sqrt{1 + z \cdot z}}
double f(double x, double y, double z) {
        double r284993 = 1.0;
        double r284994 = x;
        double r284995 = r284993 / r284994;
        double r284996 = y;
        double r284997 = z;
        double r284998 = r284997 * r284997;
        double r284999 = r284993 + r284998;
        double r285000 = r284996 * r284999;
        double r285001 = r284995 / r285000;
        return r285001;
}

double f(double x, double y, double z) {
        double r285002 = 1.0;
        double r285003 = y;
        double r285004 = r285002 / r285003;
        double r285005 = cbrt(r285004);
        double r285006 = z;
        double r285007 = r285006 * r285006;
        double r285008 = r285002 + r285007;
        double r285009 = sqrt(r285008);
        double r285010 = r285009 / r285005;
        double r285011 = r285005 / r285010;
        double r285012 = x;
        double r285013 = r285005 / r285012;
        double r285014 = r285013 / r285009;
        double r285015 = r285011 * r285014;
        return r285015;
}

Error

Bits error versus x

Bits error versus y

Bits error versus z

Try it out

Your Program's Arguments

Results

Enter valid numbers for all inputs

Target

Original6.3
Target5.7
Herbie6.1
\[\begin{array}{l} \mathbf{if}\;y \cdot \left(1 + z \cdot z\right) \lt -\infty:\\ \;\;\;\;\frac{\frac{1}{y}}{\left(1 + z \cdot z\right) \cdot x}\\ \mathbf{elif}\;y \cdot \left(1 + z \cdot z\right) \lt 8.680743250567251617010582226806563373013 \cdot 10^{305}:\\ \;\;\;\;\frac{\frac{1}{x}}{\left(1 + z \cdot z\right) \cdot y}\\ \mathbf{else}:\\ \;\;\;\;\frac{\frac{1}{y}}{\left(1 + z \cdot z\right) \cdot x}\\ \end{array}\]

Derivation

  1. Initial program 6.3

    \[\frac{\frac{1}{x}}{y \cdot \left(1 + z \cdot z\right)}\]
  2. Using strategy rm
  3. Applied associate-/r*6.6

    \[\leadsto \color{blue}{\frac{\frac{\frac{1}{x}}{y}}{1 + z \cdot z}}\]
  4. Simplified6.6

    \[\leadsto \frac{\color{blue}{\frac{\frac{1}{y}}{x}}}{1 + z \cdot z}\]
  5. Using strategy rm
  6. Applied add-sqr-sqrt6.6

    \[\leadsto \frac{\frac{\frac{1}{y}}{x}}{\color{blue}{\sqrt{1 + z \cdot z} \cdot \sqrt{1 + z \cdot z}}}\]
  7. Applied *-un-lft-identity6.6

    \[\leadsto \frac{\frac{\frac{1}{y}}{\color{blue}{1 \cdot x}}}{\sqrt{1 + z \cdot z} \cdot \sqrt{1 + z \cdot z}}\]
  8. Applied add-cube-cbrt7.2

    \[\leadsto \frac{\frac{\color{blue}{\left(\sqrt[3]{\frac{1}{y}} \cdot \sqrt[3]{\frac{1}{y}}\right) \cdot \sqrt[3]{\frac{1}{y}}}}{1 \cdot x}}{\sqrt{1 + z \cdot z} \cdot \sqrt{1 + z \cdot z}}\]
  9. Applied times-frac7.2

    \[\leadsto \frac{\color{blue}{\frac{\sqrt[3]{\frac{1}{y}} \cdot \sqrt[3]{\frac{1}{y}}}{1} \cdot \frac{\sqrt[3]{\frac{1}{y}}}{x}}}{\sqrt{1 + z \cdot z} \cdot \sqrt{1 + z \cdot z}}\]
  10. Applied times-frac6.1

    \[\leadsto \color{blue}{\frac{\frac{\sqrt[3]{\frac{1}{y}} \cdot \sqrt[3]{\frac{1}{y}}}{1}}{\sqrt{1 + z \cdot z}} \cdot \frac{\frac{\sqrt[3]{\frac{1}{y}}}{x}}{\sqrt{1 + z \cdot z}}}\]
  11. Simplified6.1

    \[\leadsto \color{blue}{\frac{\sqrt[3]{\frac{1}{y}}}{\frac{\sqrt{1 + z \cdot z}}{\sqrt[3]{\frac{1}{y}}}}} \cdot \frac{\frac{\sqrt[3]{\frac{1}{y}}}{x}}{\sqrt{1 + z \cdot z}}\]
  12. Final simplification6.1

    \[\leadsto \frac{\sqrt[3]{\frac{1}{y}}}{\frac{\sqrt{1 + z \cdot z}}{\sqrt[3]{\frac{1}{y}}}} \cdot \frac{\frac{\sqrt[3]{\frac{1}{y}}}{x}}{\sqrt{1 + z \cdot z}}\]

Reproduce

herbie shell --seed 2019353 +o rules:numerics
(FPCore (x y z)
  :name "Statistics.Distribution.CauchyLorentz:$cdensity from math-functions-0.1.5.2"
  :precision binary64

  :herbie-target
  (if (< (* y (+ 1 (* z z))) #f) (/ (/ 1 y) (* (+ 1 (* z z)) x)) (if (< (* y (+ 1 (* z z))) 8.680743250567252e+305) (/ (/ 1 x) (* (+ 1 (* z z)) y)) (/ (/ 1 y) (* (+ 1 (* z z)) x))))

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