Average Error: 6.5 → 5.9
Time: 3.3s
Precision: 64
\[\frac{\frac{1}{x}}{y \cdot \left(1 + z \cdot z\right)}\]
\[\left(\left(\sqrt[3]{\frac{1}{y} \cdot \frac{\sqrt[3]{\frac{1}{x}} \cdot \sqrt[3]{\frac{1}{x}}}{\sqrt{1 + z \cdot z}}} \cdot \sqrt[3]{\frac{1}{y} \cdot \frac{\sqrt[3]{\frac{1}{x}} \cdot \sqrt[3]{\frac{1}{x}}}{\sqrt{1 + z \cdot z}}}\right) \cdot \sqrt[3]{\frac{1}{y} \cdot \frac{\sqrt[3]{\frac{1}{x}} \cdot \sqrt[3]{\frac{1}{x}}}{\sqrt{1 + z \cdot z}}}\right) \cdot \frac{\sqrt[3]{\frac{1}{x}}}{\sqrt{1 + z \cdot z}}\]
\frac{\frac{1}{x}}{y \cdot \left(1 + z \cdot z\right)}
\left(\left(\sqrt[3]{\frac{1}{y} \cdot \frac{\sqrt[3]{\frac{1}{x}} \cdot \sqrt[3]{\frac{1}{x}}}{\sqrt{1 + z \cdot z}}} \cdot \sqrt[3]{\frac{1}{y} \cdot \frac{\sqrt[3]{\frac{1}{x}} \cdot \sqrt[3]{\frac{1}{x}}}{\sqrt{1 + z \cdot z}}}\right) \cdot \sqrt[3]{\frac{1}{y} \cdot \frac{\sqrt[3]{\frac{1}{x}} \cdot \sqrt[3]{\frac{1}{x}}}{\sqrt{1 + z \cdot z}}}\right) \cdot \frac{\sqrt[3]{\frac{1}{x}}}{\sqrt{1 + z \cdot z}}
double f(double x, double y, double z) {
        double r349660 = 1.0;
        double r349661 = x;
        double r349662 = r349660 / r349661;
        double r349663 = y;
        double r349664 = z;
        double r349665 = r349664 * r349664;
        double r349666 = r349660 + r349665;
        double r349667 = r349663 * r349666;
        double r349668 = r349662 / r349667;
        return r349668;
}

double f(double x, double y, double z) {
        double r349669 = 1.0;
        double r349670 = y;
        double r349671 = r349669 / r349670;
        double r349672 = 1.0;
        double r349673 = x;
        double r349674 = r349672 / r349673;
        double r349675 = cbrt(r349674);
        double r349676 = r349675 * r349675;
        double r349677 = z;
        double r349678 = r349677 * r349677;
        double r349679 = r349669 + r349678;
        double r349680 = sqrt(r349679);
        double r349681 = r349676 / r349680;
        double r349682 = r349671 * r349681;
        double r349683 = cbrt(r349682);
        double r349684 = r349683 * r349683;
        double r349685 = r349684 * r349683;
        double r349686 = r349675 / r349680;
        double r349687 = r349685 * r349686;
        return r349687;
}

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.5
Target5.7
Herbie5.9
\[\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.68074325056725162 \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.5

    \[\frac{\frac{1}{x}}{y \cdot \left(1 + z \cdot z\right)}\]
  2. Using strategy rm
  3. Applied div-inv6.5

    \[\leadsto \frac{\color{blue}{1 \cdot \frac{1}{x}}}{y \cdot \left(1 + z \cdot z\right)}\]
  4. Applied times-frac6.5

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

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

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

    \[\leadsto \frac{1}{y} \cdot \color{blue}{\left(\frac{\sqrt[3]{\frac{1}{x}} \cdot \sqrt[3]{\frac{1}{x}}}{\sqrt{1 + z \cdot z}} \cdot \frac{\sqrt[3]{\frac{1}{x}}}{\sqrt{1 + z \cdot z}}\right)}\]
  9. Applied associate-*r*5.7

    \[\leadsto \color{blue}{\left(\frac{1}{y} \cdot \frac{\sqrt[3]{\frac{1}{x}} \cdot \sqrt[3]{\frac{1}{x}}}{\sqrt{1 + z \cdot z}}\right) \cdot \frac{\sqrt[3]{\frac{1}{x}}}{\sqrt{1 + z \cdot z}}}\]
  10. Using strategy rm
  11. Applied add-cube-cbrt5.9

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

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

Reproduce

herbie shell --seed 2020025 
(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)))))