\frac{x}{\left(y - z\right) \cdot \left(t - z\right)}\frac{\frac{x}{y - z}}{t - z}double f(double x, double y, double z, double t) {
double r719981 = x;
double r719982 = y;
double r719983 = z;
double r719984 = r719982 - r719983;
double r719985 = t;
double r719986 = r719985 - r719983;
double r719987 = r719984 * r719986;
double r719988 = r719981 / r719987;
return r719988;
}
double f(double x, double y, double z, double t) {
double r719989 = x;
double r719990 = y;
double r719991 = z;
double r719992 = r719990 - r719991;
double r719993 = r719989 / r719992;
double r719994 = t;
double r719995 = r719994 - r719991;
double r719996 = r719993 / r719995;
return r719996;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t
Results
| Original | 7.7 |
|---|---|
| Target | 8.4 |
| Herbie | 2.1 |
if (* (- y z) (- t z)) < -1.5291856068033191e+116Initial program 10.1
rmApplied *-un-lft-identity10.1
Applied times-frac1.0
rmApplied *-un-lft-identity1.0
Applied associate-*l*1.0
Simplified0.9
if -1.5291856068033191e+116 < (* (- y z) (- t z)) < -5.9198914017313725e-123Initial program 0.2
if -5.9198914017313725e-123 < (* (- y z) (- t z)) Initial program 8.0
rmApplied add-cube-cbrt8.5
Applied times-frac1.5
rmApplied *-un-lft-identity1.5
Applied associate-*l*1.5
Simplified1.6
Final simplification2.1
herbie shell --seed 1978988140
(FPCore (x y z t)
:name "Data.Random.Distribution.Triangular:triangularCDF from random-fu-0.2.6.2, B"
:precision binary64
:herbie-target
(if (< (/ x (* (- y z) (- t z))) 0.0) (/ (/ x (- y z)) (- t z)) (* x (/ 1 (* (- y z) (- t z)))))
(/ x (* (- y z) (- t z))))