x + \frac{y \cdot \left(z - x\right)}{t}y \cdot \left(\frac{z}{t} - \frac{x}{t}\right) + xdouble f(double x, double y, double z, double t) {
double r236669 = x;
double r236670 = y;
double r236671 = z;
double r236672 = r236671 - r236669;
double r236673 = r236670 * r236672;
double r236674 = t;
double r236675 = r236673 / r236674;
double r236676 = r236669 + r236675;
return r236676;
}
double f(double x, double y, double z, double t) {
double r236677 = y;
double r236678 = z;
double r236679 = t;
double r236680 = r236678 / r236679;
double r236681 = x;
double r236682 = r236681 / r236679;
double r236683 = r236680 - r236682;
double r236684 = r236677 * r236683;
double r236685 = r236684 + r236681;
return r236685;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t
Results
| Original | 6.5 |
|---|---|
| Target | 2.0 |
| Herbie | 6.5 |
if y < -1.258518507926354e-57 or 3.732545607262176e-61 < y Initial program 12.1
rmApplied add-cube-cbrt12.7
Applied times-frac2.2
rmApplied add-cube-cbrt2.4
Applied *-un-lft-identity2.4
Applied times-frac2.4
Applied associate-*r*3.4
Simplified3.4
Taylor expanded around 0 12.1
rmApplied *-un-lft-identity12.1
Applied *-un-lft-identity12.1
Applied distribute-lft-out--12.1
Simplified1.9
if -1.258518507926354e-57 < y < 3.732545607262176e-61Initial program 1.2
rmApplied add-cube-cbrt1.6
Applied times-frac4.0
rmApplied add-cube-cbrt4.1
Applied *-un-lft-identity4.1
Applied times-frac4.2
Applied associate-*r*2.3
Simplified2.3
Taylor expanded around 0 1.2
rmApplied associate-/l*0.8
Final simplification6.5
herbie shell --seed 2019297
(FPCore (x y z t)
:name "Optimisation.CirclePacking:place from circle-packing-0.1.0.4, D"
:precision binary64
:herbie-target
(- x (+ (* x (/ y t)) (* (- z) (/ y t))))
(+ x (/ (* y (- z x)) t)))