\left(x \cdot y - z \cdot y\right) \cdot t
\begin{array}{l}
\mathbf{if}\;x \cdot y - z \cdot y = -\infty \lor \neg \left(x \cdot y - z \cdot y \le -4.58287967372564715 \cdot 10^{-194} \lor \neg \left(x \cdot y - z \cdot y \le 3.33973174977735668 \cdot 10^{-232} \lor \neg \left(x \cdot y - z \cdot y \le 5.41316001391597297 \cdot 10^{273}\right)\right)\right):\\
\;\;\;\;y \cdot \left(\left(x - z\right) \cdot t\right)\\
\mathbf{else}:\\
\;\;\;\;t \cdot \left(x \cdot y - z \cdot y\right)\\
\end{array}double f(double x, double y, double z, double t) {
double r595305 = x;
double r595306 = y;
double r595307 = r595305 * r595306;
double r595308 = z;
double r595309 = r595308 * r595306;
double r595310 = r595307 - r595309;
double r595311 = t;
double r595312 = r595310 * r595311;
return r595312;
}
double f(double x, double y, double z, double t) {
double r595313 = x;
double r595314 = y;
double r595315 = r595313 * r595314;
double r595316 = z;
double r595317 = r595316 * r595314;
double r595318 = r595315 - r595317;
double r595319 = -inf.0;
bool r595320 = r595318 <= r595319;
double r595321 = -4.582879673725647e-194;
bool r595322 = r595318 <= r595321;
double r595323 = 3.339731749777357e-232;
bool r595324 = r595318 <= r595323;
double r595325 = 5.413160013915973e+273;
bool r595326 = r595318 <= r595325;
double r595327 = !r595326;
bool r595328 = r595324 || r595327;
double r595329 = !r595328;
bool r595330 = r595322 || r595329;
double r595331 = !r595330;
bool r595332 = r595320 || r595331;
double r595333 = r595313 - r595316;
double r595334 = t;
double r595335 = r595333 * r595334;
double r595336 = r595314 * r595335;
double r595337 = r595334 * r595318;
double r595338 = r595332 ? r595336 : r595337;
return r595338;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t
Results
| Original | 6.9 |
|---|---|
| Target | 3.1 |
| Herbie | 0.3 |
if (- (* x y) (* z y)) < -inf.0 or -4.582879673725647e-194 < (- (* x y) (* z y)) < 3.339731749777357e-232 or 5.413160013915973e+273 < (- (* x y) (* z y)) Initial program 29.2
rmApplied distribute-rgt-out--29.2
Applied associate-*l*0.6
if -inf.0 < (- (* x y) (* z y)) < -4.582879673725647e-194 or 3.339731749777357e-232 < (- (* x y) (* z y)) < 5.413160013915973e+273Initial program 0.3
rmApplied *-un-lft-identity0.3
Final simplification0.3
herbie shell --seed 2020036
(FPCore (x y z t)
:name "Linear.Projection:inverseInfinitePerspective from linear-1.19.1.3"
:precision binary64
:herbie-target
(if (< t -9.231879582886777e-80) (* (* y t) (- x z)) (if (< t 2.543067051564877e+83) (* y (* t (- x z))) (* (* y (- x z)) t)))
(* (- (* x y) (* z y)) t))