\left(x \cdot y - z \cdot y\right) \cdot t
\begin{array}{l}
\mathbf{if}\;x \cdot y - z \cdot y = -\infty:\\
\;\;\;\;\left(x - z\right) \cdot \left(y \cdot t\right)\\
\mathbf{elif}\;x \cdot y - z \cdot y \le -3.305196693480939713514581034193979623053 \cdot 10^{-153}:\\
\;\;\;\;t \cdot \left(x \cdot y - z \cdot y\right)\\
\mathbf{elif}\;x \cdot y - z \cdot y \le 1.717842953697809163237341802420612798171 \cdot 10^{-196}:\\
\;\;\;\;\left(x - z\right) \cdot \left(y \cdot t\right)\\
\mathbf{elif}\;x \cdot y - z \cdot y \le 9.555835303684123458062564353397121419313 \cdot 10^{230}:\\
\;\;\;\;t \cdot \left(x \cdot y - z \cdot y\right)\\
\mathbf{else}:\\
\;\;\;\;\left(t \cdot \left(x - z\right)\right) \cdot y\\
\end{array}double f(double x, double y, double z, double t) {
double r20552698 = x;
double r20552699 = y;
double r20552700 = r20552698 * r20552699;
double r20552701 = z;
double r20552702 = r20552701 * r20552699;
double r20552703 = r20552700 - r20552702;
double r20552704 = t;
double r20552705 = r20552703 * r20552704;
return r20552705;
}
double f(double x, double y, double z, double t) {
double r20552706 = x;
double r20552707 = y;
double r20552708 = r20552706 * r20552707;
double r20552709 = z;
double r20552710 = r20552709 * r20552707;
double r20552711 = r20552708 - r20552710;
double r20552712 = -inf.0;
bool r20552713 = r20552711 <= r20552712;
double r20552714 = r20552706 - r20552709;
double r20552715 = t;
double r20552716 = r20552707 * r20552715;
double r20552717 = r20552714 * r20552716;
double r20552718 = -3.3051966934809397e-153;
bool r20552719 = r20552711 <= r20552718;
double r20552720 = r20552715 * r20552711;
double r20552721 = 1.7178429536978092e-196;
bool r20552722 = r20552711 <= r20552721;
double r20552723 = 9.555835303684123e+230;
bool r20552724 = r20552711 <= r20552723;
double r20552725 = r20552715 * r20552714;
double r20552726 = r20552725 * r20552707;
double r20552727 = r20552724 ? r20552720 : r20552726;
double r20552728 = r20552722 ? r20552717 : r20552727;
double r20552729 = r20552719 ? r20552720 : r20552728;
double r20552730 = r20552713 ? r20552717 : r20552729;
return r20552730;
}




Bits error versus x




Bits error versus y




Bits error versus z




Bits error versus t
Results
| Original | 7.3 |
|---|---|
| Target | 3.1 |
| Herbie | 0.5 |
if (- (* x y) (* z y)) < -inf.0 or -3.3051966934809397e-153 < (- (* x y) (* z y)) < 1.7178429536978092e-196Initial program 19.4
Simplified1.1
if -inf.0 < (- (* x y) (* z y)) < -3.3051966934809397e-153 or 1.7178429536978092e-196 < (- (* x y) (* z y)) < 9.555835303684123e+230Initial program 0.3
if 9.555835303684123e+230 < (- (* x y) (* z y)) Initial program 36.2
Simplified0.7
rmApplied associate-*r*1.0
Final simplification0.5
herbie shell --seed 2019168 +o rules:numerics
(FPCore (x y z t)
:name "Linear.Projection:inverseInfinitePerspective from linear-1.19.1.3"
: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))