\left(x \cdot y - z \cdot y\right) \cdot t
\begin{array}{l}
\mathbf{if}\;y \le -4.856164112248959329219151378456217111614 \cdot 10^{-91} \lor \neg \left(y \le 3.025418364347031062019168566536185959801 \cdot 10^{108}\right):\\
\;\;\;\;y \cdot \left(\left(x - z\right) \cdot t\right)\\
\mathbf{else}:\\
\;\;\;\;\left(y \cdot \left(x - z\right)\right) \cdot t\\
\end{array}double f(double x, double y, double z, double t) {
double r1050452 = x;
double r1050453 = y;
double r1050454 = r1050452 * r1050453;
double r1050455 = z;
double r1050456 = r1050455 * r1050453;
double r1050457 = r1050454 - r1050456;
double r1050458 = t;
double r1050459 = r1050457 * r1050458;
return r1050459;
}
double f(double x, double y, double z, double t) {
double r1050460 = y;
double r1050461 = -4.8561641122489593e-91;
bool r1050462 = r1050460 <= r1050461;
double r1050463 = 3.025418364347031e+108;
bool r1050464 = r1050460 <= r1050463;
double r1050465 = !r1050464;
bool r1050466 = r1050462 || r1050465;
double r1050467 = x;
double r1050468 = z;
double r1050469 = r1050467 - r1050468;
double r1050470 = t;
double r1050471 = r1050469 * r1050470;
double r1050472 = r1050460 * r1050471;
double r1050473 = r1050460 * r1050469;
double r1050474 = r1050473 * r1050470;
double r1050475 = r1050466 ? r1050472 : r1050474;
return r1050475;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t
Results
| Original | 6.9 |
|---|---|
| Target | 3.2 |
| Herbie | 3.3 |
if y < -4.8561641122489593e-91 or 3.025418364347031e+108 < y Initial program 13.6
Simplified13.6
rmApplied pow113.6
Applied pow113.6
Applied pow113.6
Applied pow-prod-down13.6
Applied pow-prod-down13.6
Simplified3.8
if -4.8561641122489593e-91 < y < 3.025418364347031e+108Initial program 2.9
Simplified2.9
Final simplification3.3
herbie shell --seed 2019303
(FPCore (x y z t)
:name "Linear.Projection:inverseInfinitePerspective from linear-1.19.1.3"
:precision binary64
:herbie-target
(if (< t -9.2318795828867769e-80) (* (* y t) (- x z)) (if (< t 2.5430670515648771e83) (* y (* t (- x z))) (* (* y (- x z)) t)))
(* (- (* x y) (* z y)) t))