\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 5.194293911522653 \cdot 10^{144}\right):\\
\;\;\;\;y \cdot \left(\left(x - z\right) \cdot t\right)\\
\mathbf{else}:\\
\;\;\;\;\left(x \cdot y - z \cdot y\right) \cdot t\\
\end{array}double f(double x, double y, double z, double t) {
double r598111 = x;
double r598112 = y;
double r598113 = r598111 * r598112;
double r598114 = z;
double r598115 = r598114 * r598112;
double r598116 = r598113 - r598115;
double r598117 = t;
double r598118 = r598116 * r598117;
return r598118;
}
double f(double x, double y, double z, double t) {
double r598119 = x;
double r598120 = y;
double r598121 = r598119 * r598120;
double r598122 = z;
double r598123 = r598122 * r598120;
double r598124 = r598121 - r598123;
double r598125 = -inf.0;
bool r598126 = r598124 <= r598125;
double r598127 = 5.1942939115226525e+144;
bool r598128 = r598124 <= r598127;
double r598129 = !r598128;
bool r598130 = r598126 || r598129;
double r598131 = r598119 - r598122;
double r598132 = t;
double r598133 = r598131 * r598132;
double r598134 = r598120 * r598133;
double r598135 = r598124 * r598132;
double r598136 = r598130 ? r598134 : r598135;
return r598136;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t
Results
| Original | 6.9 |
|---|---|
| Target | 3.1 |
| Herbie | 1.8 |
if (- (* x y) (* z y)) < -inf.0 or 5.1942939115226525e+144 < (- (* x y) (* z y)) Initial program 30.9
rmApplied distribute-rgt-out--30.9
Applied associate-*l*2.2
if -inf.0 < (- (* x y) (* z y)) < 5.1942939115226525e+144Initial program 1.7
Final simplification1.8
herbie shell --seed 2020065
(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))