
(FPCore (x y z t a) :precision binary64 (+ x (/ (* (- y z) (- t x)) (- a z))))
double code(double x, double y, double z, double t, double a) {
return x + (((y - z) * (t - x)) / (a - z));
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = x + (((y - z) * (t - x)) / (a - z))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (((y - z) * (t - x)) / (a - z));
}
def code(x, y, z, t, a): return x + (((y - z) * (t - x)) / (a - z))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(Float64(y - z) * Float64(t - x)) / Float64(a - z))) end
function tmp = code(x, y, z, t, a) tmp = x + (((y - z) * (t - x)) / (a - z)); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(N[(y - z), $MachinePrecision] * N[(t - x), $MachinePrecision]), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 18 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a) :precision binary64 (+ x (/ (* (- y z) (- t x)) (- a z))))
double code(double x, double y, double z, double t, double a) {
return x + (((y - z) * (t - x)) / (a - z));
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = x + (((y - z) * (t - x)) / (a - z))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (((y - z) * (t - x)) / (a - z));
}
def code(x, y, z, t, a): return x + (((y - z) * (t - x)) / (a - z))
function code(x, y, z, t, a) return Float64(x + Float64(Float64(Float64(y - z) * Float64(t - x)) / Float64(a - z))) end
function tmp = code(x, y, z, t, a) tmp = x + (((y - z) * (t - x)) / (a - z)); end
code[x_, y_, z_, t_, a_] := N[(x + N[(N[(N[(y - z), $MachinePrecision] * N[(t - x), $MachinePrecision]), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z}
\end{array}
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (* (- y z) (/ (- t x) (- a z)))))
(t_2 (+ x (/ (* (- y z) (- t x)) (- a z)))))
(if (<= t_2 (- INFINITY))
t_1
(if (<= t_2 -2e-243)
t_2
(if (<= t_2 0.0)
(- t (/ (* (- t x) (- y a)) z))
(if (<= t_2 5e+263) t_2 t_1))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y - z) * ((t - x) / (a - z)));
double t_2 = x + (((y - z) * (t - x)) / (a - z));
double tmp;
if (t_2 <= -((double) INFINITY)) {
tmp = t_1;
} else if (t_2 <= -2e-243) {
tmp = t_2;
} else if (t_2 <= 0.0) {
tmp = t - (((t - x) * (y - a)) / z);
} else if (t_2 <= 5e+263) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x + ((y - z) * ((t - x) / (a - z)));
double t_2 = x + (((y - z) * (t - x)) / (a - z));
double tmp;
if (t_2 <= -Double.POSITIVE_INFINITY) {
tmp = t_1;
} else if (t_2 <= -2e-243) {
tmp = t_2;
} else if (t_2 <= 0.0) {
tmp = t - (((t - x) * (y - a)) / z);
} else if (t_2 <= 5e+263) {
tmp = t_2;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + ((y - z) * ((t - x) / (a - z))) t_2 = x + (((y - z) * (t - x)) / (a - z)) tmp = 0 if t_2 <= -math.inf: tmp = t_1 elif t_2 <= -2e-243: tmp = t_2 elif t_2 <= 0.0: tmp = t - (((t - x) * (y - a)) / z) elif t_2 <= 5e+263: tmp = t_2 else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z)))) t_2 = Float64(x + Float64(Float64(Float64(y - z) * Float64(t - x)) / Float64(a - z))) tmp = 0.0 if (t_2 <= Float64(-Inf)) tmp = t_1; elseif (t_2 <= -2e-243) tmp = t_2; elseif (t_2 <= 0.0) tmp = Float64(t - Float64(Float64(Float64(t - x) * Float64(y - a)) / z)); elseif (t_2 <= 5e+263) tmp = t_2; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + ((y - z) * ((t - x) / (a - z))); t_2 = x + (((y - z) * (t - x)) / (a - z)); tmp = 0.0; if (t_2 <= -Inf) tmp = t_1; elseif (t_2 <= -2e-243) tmp = t_2; elseif (t_2 <= 0.0) tmp = t - (((t - x) * (y - a)) / z); elseif (t_2 <= 5e+263) tmp = t_2; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(N[(N[(y - z), $MachinePrecision] * N[(t - x), $MachinePrecision]), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, (-Infinity)], t$95$1, If[LessEqual[t$95$2, -2e-243], t$95$2, If[LessEqual[t$95$2, 0.0], N[(t - N[(N[(N[(t - x), $MachinePrecision] * N[(y - a), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, 5e+263], t$95$2, t$95$1]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \left(y - z\right) \cdot \frac{t - x}{a - z}\\
t_2 := x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z}\\
\mathbf{if}\;t\_2 \leq -\infty:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t\_2 \leq -2 \cdot 10^{-243}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t\_2 \leq 0:\\
\;\;\;\;t - \frac{\left(t - x\right) \cdot \left(y - a\right)}{z}\\
\mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+263}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < -inf.0 or 5.00000000000000022e263 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) Initial program 34.7%
associate-/l*78.6%
Simplified78.6%
if -inf.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < -1.99999999999999999e-243 or 0.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < 5.00000000000000022e263Initial program 96.7%
if -1.99999999999999999e-243 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < 0.0Initial program 10.7%
+-commutative10.7%
*-commutative10.7%
associate-/l*10.7%
fma-define10.7%
Simplified10.7%
Taylor expanded in z around inf 99.8%
associate--l+99.8%
associate-*r/99.8%
associate-*r/99.8%
mul-1-neg99.8%
div-sub99.8%
mul-1-neg99.8%
distribute-lft-out--99.8%
associate-*r/99.8%
mul-1-neg99.8%
unsub-neg99.8%
distribute-rgt-out--99.8%
Simplified99.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (* (- y z) (- t x)) (- a z)))))
(if (or (<= t_1 -2e-228) (not (<= t_1 0.0)))
(fma (- t x) (/ (- y z) (- a z)) x)
(- t (/ (* (- t x) (- y a)) z)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (((y - z) * (t - x)) / (a - z));
double tmp;
if ((t_1 <= -2e-228) || !(t_1 <= 0.0)) {
tmp = fma((t - x), ((y - z) / (a - z)), x);
} else {
tmp = t - (((t - x) * (y - a)) / z);
}
return tmp;
}
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(Float64(y - z) * Float64(t - x)) / Float64(a - z))) tmp = 0.0 if ((t_1 <= -2e-228) || !(t_1 <= 0.0)) tmp = fma(Float64(t - x), Float64(Float64(y - z) / Float64(a - z)), x); else tmp = Float64(t - Float64(Float64(Float64(t - x) * Float64(y - a)) / z)); end return tmp end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(N[(y - z), $MachinePrecision] * N[(t - x), $MachinePrecision]), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -2e-228], N[Not[LessEqual[t$95$1, 0.0]], $MachinePrecision]], N[(N[(t - x), $MachinePrecision] * N[(N[(y - z), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision], N[(t - N[(N[(N[(t - x), $MachinePrecision] * N[(y - a), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z}\\
\mathbf{if}\;t\_1 \leq -2 \cdot 10^{-228} \lor \neg \left(t\_1 \leq 0\right):\\
\;\;\;\;\mathsf{fma}\left(t - x, \frac{y - z}{a - z}, x\right)\\
\mathbf{else}:\\
\;\;\;\;t - \frac{\left(t - x\right) \cdot \left(y - a\right)}{z}\\
\end{array}
\end{array}
if (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < -2.00000000000000007e-228 or 0.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) Initial program 71.9%
+-commutative71.9%
*-commutative71.9%
associate-/l*88.7%
fma-define88.6%
Simplified88.6%
if -2.00000000000000007e-228 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < 0.0Initial program 15.6%
+-commutative15.6%
*-commutative15.6%
associate-/l*10.3%
fma-define10.3%
Simplified10.3%
Taylor expanded in z around inf 91.4%
associate--l+91.4%
associate-*r/91.4%
associate-*r/91.4%
mul-1-neg91.4%
div-sub91.4%
mul-1-neg91.4%
distribute-lft-out--91.4%
associate-*r/91.4%
mul-1-neg91.4%
unsub-neg91.4%
distribute-rgt-out--91.4%
Simplified91.4%
Final simplification88.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ x (/ (* (- y z) (- t x)) (- a z)))))
(if (or (<= t_1 -2e-228) (not (<= t_1 0.0)))
(+ x (/ (- t x) (/ (- a z) (- y z))))
(- t (/ (* (- t x) (- y a)) z)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x + (((y - z) * (t - x)) / (a - z));
double tmp;
if ((t_1 <= -2e-228) || !(t_1 <= 0.0)) {
tmp = x + ((t - x) / ((a - z) / (y - z)));
} else {
tmp = t - (((t - x) * (y - a)) / z);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = x + (((y - z) * (t - x)) / (a - z))
if ((t_1 <= (-2d-228)) .or. (.not. (t_1 <= 0.0d0))) then
tmp = x + ((t - x) / ((a - z) / (y - z)))
else
tmp = t - (((t - x) * (y - a)) / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = x + (((y - z) * (t - x)) / (a - z));
double tmp;
if ((t_1 <= -2e-228) || !(t_1 <= 0.0)) {
tmp = x + ((t - x) / ((a - z) / (y - z)));
} else {
tmp = t - (((t - x) * (y - a)) / z);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x + (((y - z) * (t - x)) / (a - z)) tmp = 0 if (t_1 <= -2e-228) or not (t_1 <= 0.0): tmp = x + ((t - x) / ((a - z) / (y - z))) else: tmp = t - (((t - x) * (y - a)) / z) return tmp
function code(x, y, z, t, a) t_1 = Float64(x + Float64(Float64(Float64(y - z) * Float64(t - x)) / Float64(a - z))) tmp = 0.0 if ((t_1 <= -2e-228) || !(t_1 <= 0.0)) tmp = Float64(x + Float64(Float64(t - x) / Float64(Float64(a - z) / Float64(y - z)))); else tmp = Float64(t - Float64(Float64(Float64(t - x) * Float64(y - a)) / z)); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x + (((y - z) * (t - x)) / (a - z)); tmp = 0.0; if ((t_1 <= -2e-228) || ~((t_1 <= 0.0))) tmp = x + ((t - x) / ((a - z) / (y - z))); else tmp = t - (((t - x) * (y - a)) / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x + N[(N[(N[(y - z), $MachinePrecision] * N[(t - x), $MachinePrecision]), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[t$95$1, -2e-228], N[Not[LessEqual[t$95$1, 0.0]], $MachinePrecision]], N[(x + N[(N[(t - x), $MachinePrecision] / N[(N[(a - z), $MachinePrecision] / N[(y - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t - N[(N[(N[(t - x), $MachinePrecision] * N[(y - a), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + \frac{\left(y - z\right) \cdot \left(t - x\right)}{a - z}\\
\mathbf{if}\;t\_1 \leq -2 \cdot 10^{-228} \lor \neg \left(t\_1 \leq 0\right):\\
\;\;\;\;x + \frac{t - x}{\frac{a - z}{y - z}}\\
\mathbf{else}:\\
\;\;\;\;t - \frac{\left(t - x\right) \cdot \left(y - a\right)}{z}\\
\end{array}
\end{array}
if (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < -2.00000000000000007e-228 or 0.0 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) Initial program 71.9%
associate-/l*84.9%
Simplified84.9%
Taylor expanded in y around 0 72.2%
mul-1-neg72.2%
associate-/l*81.9%
distribute-lft-neg-out81.9%
+-commutative81.9%
div-sub81.9%
distribute-rgt-out84.9%
sub-neg84.9%
associate-/r/88.6%
Simplified88.6%
if -2.00000000000000007e-228 < (+.f64 x (/.f64 (*.f64 (-.f64 y z) (-.f64 t x)) (-.f64 a z))) < 0.0Initial program 15.6%
+-commutative15.6%
*-commutative15.6%
associate-/l*10.3%
fma-define10.3%
Simplified10.3%
Taylor expanded in z around inf 91.4%
associate--l+91.4%
associate-*r/91.4%
associate-*r/91.4%
mul-1-neg91.4%
div-sub91.4%
mul-1-neg91.4%
distribute-lft-out--91.4%
associate-*r/91.4%
mul-1-neg91.4%
unsub-neg91.4%
distribute-rgt-out--91.4%
Simplified91.4%
Final simplification88.8%
(FPCore (x y z t a)
:precision binary64
(if (<= z -2.5e-106)
(- x (* t (/ (- y z) z)))
(if (<= z 3.4e-68)
(+ x (* t (/ y (- a z))))
(if (<= z 7.4e+264)
(+ x (* t (/ z (- z a))))
(/ t (+ (/ (- y a) z) 1.0))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -2.5e-106) {
tmp = x - (t * ((y - z) / z));
} else if (z <= 3.4e-68) {
tmp = x + (t * (y / (a - z)));
} else if (z <= 7.4e+264) {
tmp = x + (t * (z / (z - a)));
} else {
tmp = t / (((y - a) / z) + 1.0);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (z <= (-2.5d-106)) then
tmp = x - (t * ((y - z) / z))
else if (z <= 3.4d-68) then
tmp = x + (t * (y / (a - z)))
else if (z <= 7.4d+264) then
tmp = x + (t * (z / (z - a)))
else
tmp = t / (((y - a) / z) + 1.0d0)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -2.5e-106) {
tmp = x - (t * ((y - z) / z));
} else if (z <= 3.4e-68) {
tmp = x + (t * (y / (a - z)));
} else if (z <= 7.4e+264) {
tmp = x + (t * (z / (z - a)));
} else {
tmp = t / (((y - a) / z) + 1.0);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -2.5e-106: tmp = x - (t * ((y - z) / z)) elif z <= 3.4e-68: tmp = x + (t * (y / (a - z))) elif z <= 7.4e+264: tmp = x + (t * (z / (z - a))) else: tmp = t / (((y - a) / z) + 1.0) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -2.5e-106) tmp = Float64(x - Float64(t * Float64(Float64(y - z) / z))); elseif (z <= 3.4e-68) tmp = Float64(x + Float64(t * Float64(y / Float64(a - z)))); elseif (z <= 7.4e+264) tmp = Float64(x + Float64(t * Float64(z / Float64(z - a)))); else tmp = Float64(t / Float64(Float64(Float64(y - a) / z) + 1.0)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -2.5e-106) tmp = x - (t * ((y - z) / z)); elseif (z <= 3.4e-68) tmp = x + (t * (y / (a - z))); elseif (z <= 7.4e+264) tmp = x + (t * (z / (z - a))); else tmp = t / (((y - a) / z) + 1.0); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -2.5e-106], N[(x - N[(t * N[(N[(y - z), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 3.4e-68], N[(x + N[(t * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 7.4e+264], N[(x + N[(t * N[(z / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t / N[(N[(N[(y - a), $MachinePrecision] / z), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.5 \cdot 10^{-106}:\\
\;\;\;\;x - t \cdot \frac{y - z}{z}\\
\mathbf{elif}\;z \leq 3.4 \cdot 10^{-68}:\\
\;\;\;\;x + t \cdot \frac{y}{a - z}\\
\mathbf{elif}\;z \leq 7.4 \cdot 10^{+264}:\\
\;\;\;\;x + t \cdot \frac{z}{z - a}\\
\mathbf{else}:\\
\;\;\;\;\frac{t}{\frac{y - a}{z} + 1}\\
\end{array}
\end{array}
if z < -2.49999999999999991e-106Initial program 60.1%
Taylor expanded in t around inf 55.8%
Taylor expanded in a around 0 50.0%
mul-1-neg50.0%
unsub-neg50.0%
associate-/l*59.8%
Simplified59.8%
if -2.49999999999999991e-106 < z < 3.40000000000000018e-68Initial program 88.9%
associate-/l*89.2%
Simplified89.2%
Taylor expanded in y around inf 80.4%
associate-*r/83.8%
Simplified83.8%
Taylor expanded in t around inf 73.7%
associate-/l*76.9%
Simplified76.9%
if 3.40000000000000018e-68 < z < 7.3999999999999998e264Initial program 61.6%
associate-/l*78.0%
Simplified78.0%
Taylor expanded in t around inf 59.6%
associate-/l*68.8%
Simplified68.8%
Taylor expanded in y around 0 50.0%
mul-1-neg50.0%
unsub-neg50.0%
associate-/l*55.8%
Simplified55.8%
if 7.3999999999999998e264 < z Initial program 12.9%
associate-/l*51.8%
Simplified51.8%
Taylor expanded in y around 0 12.9%
mul-1-neg12.9%
associate-/l*51.8%
distribute-lft-neg-out51.8%
+-commutative51.8%
div-sub51.8%
distribute-rgt-out51.8%
sub-neg51.8%
associate-/r/51.6%
Simplified51.6%
Taylor expanded in z around inf 43.4%
associate--l+43.4%
associate-*r/43.4%
associate-*r/43.4%
neg-mul-143.4%
div-sub43.4%
neg-mul-143.4%
distribute-lft-out--43.4%
associate-*r/43.4%
mul-1-neg43.4%
unsub-neg43.4%
Simplified43.4%
Taylor expanded in x around 0 78.4%
associate--l+78.4%
div-sub78.4%
Simplified78.4%
Final simplification65.4%
(FPCore (x y z t a)
:precision binary64
(if (<= z -2.5e-106)
(- x (* t (/ (- y z) z)))
(if (<= z 9e-66)
(+ x (* t (/ y (- a z))))
(if (<= z 1.45e+266) (+ x (* t (/ z (- z a)))) t))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -2.5e-106) {
tmp = x - (t * ((y - z) / z));
} else if (z <= 9e-66) {
tmp = x + (t * (y / (a - z)));
} else if (z <= 1.45e+266) {
tmp = x + (t * (z / (z - a)));
} else {
tmp = t;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (z <= (-2.5d-106)) then
tmp = x - (t * ((y - z) / z))
else if (z <= 9d-66) then
tmp = x + (t * (y / (a - z)))
else if (z <= 1.45d+266) then
tmp = x + (t * (z / (z - a)))
else
tmp = t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -2.5e-106) {
tmp = x - (t * ((y - z) / z));
} else if (z <= 9e-66) {
tmp = x + (t * (y / (a - z)));
} else if (z <= 1.45e+266) {
tmp = x + (t * (z / (z - a)));
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -2.5e-106: tmp = x - (t * ((y - z) / z)) elif z <= 9e-66: tmp = x + (t * (y / (a - z))) elif z <= 1.45e+266: tmp = x + (t * (z / (z - a))) else: tmp = t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -2.5e-106) tmp = Float64(x - Float64(t * Float64(Float64(y - z) / z))); elseif (z <= 9e-66) tmp = Float64(x + Float64(t * Float64(y / Float64(a - z)))); elseif (z <= 1.45e+266) tmp = Float64(x + Float64(t * Float64(z / Float64(z - a)))); else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -2.5e-106) tmp = x - (t * ((y - z) / z)); elseif (z <= 9e-66) tmp = x + (t * (y / (a - z))); elseif (z <= 1.45e+266) tmp = x + (t * (z / (z - a))); else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -2.5e-106], N[(x - N[(t * N[(N[(y - z), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9e-66], N[(x + N[(t * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.45e+266], N[(x + N[(t * N[(z / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2.5 \cdot 10^{-106}:\\
\;\;\;\;x - t \cdot \frac{y - z}{z}\\
\mathbf{elif}\;z \leq 9 \cdot 10^{-66}:\\
\;\;\;\;x + t \cdot \frac{y}{a - z}\\
\mathbf{elif}\;z \leq 1.45 \cdot 10^{+266}:\\
\;\;\;\;x + t \cdot \frac{z}{z - a}\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -2.49999999999999991e-106Initial program 60.1%
Taylor expanded in t around inf 55.8%
Taylor expanded in a around 0 50.0%
mul-1-neg50.0%
unsub-neg50.0%
associate-/l*59.8%
Simplified59.8%
if -2.49999999999999991e-106 < z < 8.9999999999999995e-66Initial program 88.9%
associate-/l*89.2%
Simplified89.2%
Taylor expanded in y around inf 80.4%
associate-*r/83.8%
Simplified83.8%
Taylor expanded in t around inf 73.7%
associate-/l*76.9%
Simplified76.9%
if 8.9999999999999995e-66 < z < 1.45000000000000009e266Initial program 61.6%
associate-/l*78.0%
Simplified78.0%
Taylor expanded in t around inf 59.6%
associate-/l*68.8%
Simplified68.8%
Taylor expanded in y around 0 50.0%
mul-1-neg50.0%
unsub-neg50.0%
associate-/l*55.8%
Simplified55.8%
if 1.45000000000000009e266 < z Initial program 12.9%
associate-/l*51.8%
Simplified51.8%
Taylor expanded in y around 0 12.9%
mul-1-neg12.9%
associate-/l*51.8%
distribute-lft-neg-out51.8%
+-commutative51.8%
div-sub51.8%
distribute-rgt-out51.8%
sub-neg51.8%
associate-/r/51.6%
Simplified51.6%
Taylor expanded in z around inf 77.8%
Final simplification65.4%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -3.2e-156) (not (<= a 2e-185))) (+ x (* (- y z) (/ (- t x) (- a z)))) (- t (/ (* (- t x) (- y a)) z))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -3.2e-156) || !(a <= 2e-185)) {
tmp = x + ((y - z) * ((t - x) / (a - z)));
} else {
tmp = t - (((t - x) * (y - a)) / z);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((a <= (-3.2d-156)) .or. (.not. (a <= 2d-185))) then
tmp = x + ((y - z) * ((t - x) / (a - z)))
else
tmp = t - (((t - x) * (y - a)) / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -3.2e-156) || !(a <= 2e-185)) {
tmp = x + ((y - z) * ((t - x) / (a - z)));
} else {
tmp = t - (((t - x) * (y - a)) / z);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -3.2e-156) or not (a <= 2e-185): tmp = x + ((y - z) * ((t - x) / (a - z))) else: tmp = t - (((t - x) * (y - a)) / z) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -3.2e-156) || !(a <= 2e-185)) tmp = Float64(x + Float64(Float64(y - z) * Float64(Float64(t - x) / Float64(a - z)))); else tmp = Float64(t - Float64(Float64(Float64(t - x) * Float64(y - a)) / z)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -3.2e-156) || ~((a <= 2e-185))) tmp = x + ((y - z) * ((t - x) / (a - z))); else tmp = t - (((t - x) * (y - a)) / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -3.2e-156], N[Not[LessEqual[a, 2e-185]], $MachinePrecision]], N[(x + N[(N[(y - z), $MachinePrecision] * N[(N[(t - x), $MachinePrecision] / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t - N[(N[(N[(t - x), $MachinePrecision] * N[(y - a), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -3.2 \cdot 10^{-156} \lor \neg \left(a \leq 2 \cdot 10^{-185}\right):\\
\;\;\;\;x + \left(y - z\right) \cdot \frac{t - x}{a - z}\\
\mathbf{else}:\\
\;\;\;\;t - \frac{\left(t - x\right) \cdot \left(y - a\right)}{z}\\
\end{array}
\end{array}
if a < -3.19999999999999982e-156 or 2e-185 < a Initial program 72.4%
associate-/l*86.7%
Simplified86.7%
if -3.19999999999999982e-156 < a < 2e-185Initial program 55.8%
+-commutative55.8%
*-commutative55.8%
associate-/l*65.9%
fma-define65.8%
Simplified65.8%
Taylor expanded in z around inf 84.3%
associate--l+84.3%
associate-*r/84.3%
associate-*r/84.3%
mul-1-neg84.3%
div-sub84.3%
mul-1-neg84.3%
distribute-lft-out--84.3%
associate-*r/84.3%
mul-1-neg84.3%
unsub-neg84.3%
distribute-rgt-out--84.3%
Simplified84.3%
Final simplification86.1%
(FPCore (x y z t a)
:precision binary64
(if (<= z -1.45e-31)
(+ x t)
(if (<= z -6e-196)
(* y (/ t (- a z)))
(if (<= z 1.6e+118) (+ x (* t (/ y a))) t))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.45e-31) {
tmp = x + t;
} else if (z <= -6e-196) {
tmp = y * (t / (a - z));
} else if (z <= 1.6e+118) {
tmp = x + (t * (y / a));
} else {
tmp = t;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (z <= (-1.45d-31)) then
tmp = x + t
else if (z <= (-6d-196)) then
tmp = y * (t / (a - z))
else if (z <= 1.6d+118) then
tmp = x + (t * (y / a))
else
tmp = t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.45e-31) {
tmp = x + t;
} else if (z <= -6e-196) {
tmp = y * (t / (a - z));
} else if (z <= 1.6e+118) {
tmp = x + (t * (y / a));
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -1.45e-31: tmp = x + t elif z <= -6e-196: tmp = y * (t / (a - z)) elif z <= 1.6e+118: tmp = x + (t * (y / a)) else: tmp = t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.45e-31) tmp = Float64(x + t); elseif (z <= -6e-196) tmp = Float64(y * Float64(t / Float64(a - z))); elseif (z <= 1.6e+118) tmp = Float64(x + Float64(t * Float64(y / a))); else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -1.45e-31) tmp = x + t; elseif (z <= -6e-196) tmp = y * (t / (a - z)); elseif (z <= 1.6e+118) tmp = x + (t * (y / a)); else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.45e-31], N[(x + t), $MachinePrecision], If[LessEqual[z, -6e-196], N[(y * N[(t / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 1.6e+118], N[(x + N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.45 \cdot 10^{-31}:\\
\;\;\;\;x + t\\
\mathbf{elif}\;z \leq -6 \cdot 10^{-196}:\\
\;\;\;\;y \cdot \frac{t}{a - z}\\
\mathbf{elif}\;z \leq 1.6 \cdot 10^{+118}:\\
\;\;\;\;x + t \cdot \frac{y}{a}\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -1.45e-31Initial program 51.0%
Taylor expanded in t around inf 49.7%
Taylor expanded in z around inf 47.8%
if -1.45e-31 < z < -6e-196Initial program 94.8%
+-commutative94.8%
*-commutative94.8%
associate-/l*92.2%
fma-define92.0%
Simplified92.0%
Taylor expanded in y around inf 65.7%
Taylor expanded in t around inf 57.3%
if -6e-196 < z < 1.60000000000000008e118Initial program 82.4%
associate-/l*89.5%
Simplified89.5%
Taylor expanded in y around inf 71.0%
associate-*r/75.4%
Simplified75.4%
Taylor expanded in t around inf 66.0%
Taylor expanded in a around inf 60.1%
associate-/l*62.6%
Simplified62.6%
if 1.60000000000000008e118 < z Initial program 38.0%
associate-/l*59.1%
Simplified59.1%
Taylor expanded in y around 0 37.7%
mul-1-neg37.7%
associate-/l*59.1%
distribute-lft-neg-out59.1%
+-commutative59.1%
div-sub59.1%
distribute-rgt-out59.1%
sub-neg59.1%
associate-/r/62.4%
Simplified62.4%
Taylor expanded in z around inf 50.3%
(FPCore (x y z t a)
:precision binary64
(if (<= z -6e-32)
(+ x t)
(if (<= z 7.5e-258)
(* y (/ t (- a z)))
(if (<= z 9.5e+117) (* x (- 1.0 (/ y a))) t))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -6e-32) {
tmp = x + t;
} else if (z <= 7.5e-258) {
tmp = y * (t / (a - z));
} else if (z <= 9.5e+117) {
tmp = x * (1.0 - (y / a));
} else {
tmp = t;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (z <= (-6d-32)) then
tmp = x + t
else if (z <= 7.5d-258) then
tmp = y * (t / (a - z))
else if (z <= 9.5d+117) then
tmp = x * (1.0d0 - (y / a))
else
tmp = t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -6e-32) {
tmp = x + t;
} else if (z <= 7.5e-258) {
tmp = y * (t / (a - z));
} else if (z <= 9.5e+117) {
tmp = x * (1.0 - (y / a));
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -6e-32: tmp = x + t elif z <= 7.5e-258: tmp = y * (t / (a - z)) elif z <= 9.5e+117: tmp = x * (1.0 - (y / a)) else: tmp = t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -6e-32) tmp = Float64(x + t); elseif (z <= 7.5e-258) tmp = Float64(y * Float64(t / Float64(a - z))); elseif (z <= 9.5e+117) tmp = Float64(x * Float64(1.0 - Float64(y / a))); else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -6e-32) tmp = x + t; elseif (z <= 7.5e-258) tmp = y * (t / (a - z)); elseif (z <= 9.5e+117) tmp = x * (1.0 - (y / a)); else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -6e-32], N[(x + t), $MachinePrecision], If[LessEqual[z, 7.5e-258], N[(y * N[(t / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 9.5e+117], N[(x * N[(1.0 - N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -6 \cdot 10^{-32}:\\
\;\;\;\;x + t\\
\mathbf{elif}\;z \leq 7.5 \cdot 10^{-258}:\\
\;\;\;\;y \cdot \frac{t}{a - z}\\
\mathbf{elif}\;z \leq 9.5 \cdot 10^{+117}:\\
\;\;\;\;x \cdot \left(1 - \frac{y}{a}\right)\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -6.0000000000000001e-32Initial program 51.0%
Taylor expanded in t around inf 49.7%
Taylor expanded in z around inf 47.8%
if -6.0000000000000001e-32 < z < 7.4999999999999998e-258Initial program 94.2%
+-commutative94.2%
*-commutative94.2%
associate-/l*92.9%
fma-define92.8%
Simplified92.8%
Taylor expanded in y around inf 66.7%
Taylor expanded in t around inf 56.3%
if 7.4999999999999998e-258 < z < 9.50000000000000041e117Initial program 78.2%
+-commutative78.2%
*-commutative78.2%
associate-/l*91.1%
fma-define91.1%
Simplified91.1%
Taylor expanded in t around 0 44.9%
*-rgt-identity44.9%
mul-1-neg44.9%
associate-/l*53.2%
distribute-rgt-neg-in53.2%
mul-1-neg53.2%
distribute-lft-in53.1%
mul-1-neg53.1%
unsub-neg53.1%
Simplified53.1%
Taylor expanded in z around 0 50.6%
if 9.50000000000000041e117 < z Initial program 38.0%
associate-/l*59.1%
Simplified59.1%
Taylor expanded in y around 0 37.7%
mul-1-neg37.7%
associate-/l*59.1%
distribute-lft-neg-out59.1%
+-commutative59.1%
div-sub59.1%
distribute-rgt-out59.1%
sub-neg59.1%
associate-/r/62.4%
Simplified62.4%
Taylor expanded in z around inf 50.3%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -1.26e-130) (not (<= t 3.5e-136))) (- x (* t (/ (- y z) (- z a)))) (- x (* y (/ (- t x) (- z a))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -1.26e-130) || !(t <= 3.5e-136)) {
tmp = x - (t * ((y - z) / (z - a)));
} else {
tmp = x - (y * ((t - x) / (z - a)));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((t <= (-1.26d-130)) .or. (.not. (t <= 3.5d-136))) then
tmp = x - (t * ((y - z) / (z - a)))
else
tmp = x - (y * ((t - x) / (z - a)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -1.26e-130) || !(t <= 3.5e-136)) {
tmp = x - (t * ((y - z) / (z - a)));
} else {
tmp = x - (y * ((t - x) / (z - a)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -1.26e-130) or not (t <= 3.5e-136): tmp = x - (t * ((y - z) / (z - a))) else: tmp = x - (y * ((t - x) / (z - a))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -1.26e-130) || !(t <= 3.5e-136)) tmp = Float64(x - Float64(t * Float64(Float64(y - z) / Float64(z - a)))); else tmp = Float64(x - Float64(y * Float64(Float64(t - x) / Float64(z - a)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -1.26e-130) || ~((t <= 3.5e-136))) tmp = x - (t * ((y - z) / (z - a))); else tmp = x - (y * ((t - x) / (z - a))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -1.26e-130], N[Not[LessEqual[t, 3.5e-136]], $MachinePrecision]], N[(x - N[(t * N[(N[(y - z), $MachinePrecision] / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x - N[(y * N[(N[(t - x), $MachinePrecision] / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.26 \cdot 10^{-130} \lor \neg \left(t \leq 3.5 \cdot 10^{-136}\right):\\
\;\;\;\;x - t \cdot \frac{y - z}{z - a}\\
\mathbf{else}:\\
\;\;\;\;x - y \cdot \frac{t - x}{z - a}\\
\end{array}
\end{array}
if t < -1.2599999999999999e-130 or 3.50000000000000029e-136 < t Initial program 71.8%
associate-/l*86.7%
Simplified86.7%
Taylor expanded in t around inf 72.0%
associate-/l*84.7%
Simplified84.7%
if -1.2599999999999999e-130 < t < 3.50000000000000029e-136Initial program 59.3%
associate-/l*63.5%
Simplified63.5%
Taylor expanded in y around inf 53.0%
associate-*r/58.6%
Simplified58.6%
Final simplification77.2%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (/ (- y z) (- z a))))
(if (or (<= x -4.2e+81) (not (<= x 3.9e+124)))
(* x (+ t_1 1.0))
(- x (* t t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = (y - z) / (z - a);
double tmp;
if ((x <= -4.2e+81) || !(x <= 3.9e+124)) {
tmp = x * (t_1 + 1.0);
} else {
tmp = x - (t * t_1);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = (y - z) / (z - a)
if ((x <= (-4.2d+81)) .or. (.not. (x <= 3.9d+124))) then
tmp = x * (t_1 + 1.0d0)
else
tmp = x - (t * t_1)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = (y - z) / (z - a);
double tmp;
if ((x <= -4.2e+81) || !(x <= 3.9e+124)) {
tmp = x * (t_1 + 1.0);
} else {
tmp = x - (t * t_1);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = (y - z) / (z - a) tmp = 0 if (x <= -4.2e+81) or not (x <= 3.9e+124): tmp = x * (t_1 + 1.0) else: tmp = x - (t * t_1) return tmp
function code(x, y, z, t, a) t_1 = Float64(Float64(y - z) / Float64(z - a)) tmp = 0.0 if ((x <= -4.2e+81) || !(x <= 3.9e+124)) tmp = Float64(x * Float64(t_1 + 1.0)); else tmp = Float64(x - Float64(t * t_1)); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = (y - z) / (z - a); tmp = 0.0; if ((x <= -4.2e+81) || ~((x <= 3.9e+124))) tmp = x * (t_1 + 1.0); else tmp = x - (t * t_1); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(y - z), $MachinePrecision] / N[(z - a), $MachinePrecision]), $MachinePrecision]}, If[Or[LessEqual[x, -4.2e+81], N[Not[LessEqual[x, 3.9e+124]], $MachinePrecision]], N[(x * N[(t$95$1 + 1.0), $MachinePrecision]), $MachinePrecision], N[(x - N[(t * t$95$1), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{y - z}{z - a}\\
\mathbf{if}\;x \leq -4.2 \cdot 10^{+81} \lor \neg \left(x \leq 3.9 \cdot 10^{+124}\right):\\
\;\;\;\;x \cdot \left(t\_1 + 1\right)\\
\mathbf{else}:\\
\;\;\;\;x - t \cdot t\_1\\
\end{array}
\end{array}
if x < -4.1999999999999997e81 or 3.9e124 < x Initial program 45.5%
+-commutative45.5%
*-commutative45.5%
associate-/l*72.5%
fma-define72.5%
Simplified72.5%
Taylor expanded in t around 0 43.1%
*-rgt-identity43.1%
mul-1-neg43.1%
associate-/l*64.4%
distribute-rgt-neg-in64.4%
mul-1-neg64.4%
distribute-lft-in64.3%
mul-1-neg64.3%
unsub-neg64.3%
Simplified64.3%
if -4.1999999999999997e81 < x < 3.9e124Initial program 78.3%
associate-/l*84.9%
Simplified84.9%
Taylor expanded in t around inf 72.9%
associate-/l*82.8%
Simplified82.8%
Final simplification77.1%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -7.6e-56) (not (<= y 4.9e+26))) (* y (/ 1.0 (/ (- a z) (- t x)))) (+ x (* t (/ z (- z a))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -7.6e-56) || !(y <= 4.9e+26)) {
tmp = y * (1.0 / ((a - z) / (t - x)));
} else {
tmp = x + (t * (z / (z - a)));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((y <= (-7.6d-56)) .or. (.not. (y <= 4.9d+26))) then
tmp = y * (1.0d0 / ((a - z) / (t - x)))
else
tmp = x + (t * (z / (z - a)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -7.6e-56) || !(y <= 4.9e+26)) {
tmp = y * (1.0 / ((a - z) / (t - x)));
} else {
tmp = x + (t * (z / (z - a)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -7.6e-56) or not (y <= 4.9e+26): tmp = y * (1.0 / ((a - z) / (t - x))) else: tmp = x + (t * (z / (z - a))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -7.6e-56) || !(y <= 4.9e+26)) tmp = Float64(y * Float64(1.0 / Float64(Float64(a - z) / Float64(t - x)))); else tmp = Float64(x + Float64(t * Float64(z / Float64(z - a)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((y <= -7.6e-56) || ~((y <= 4.9e+26))) tmp = y * (1.0 / ((a - z) / (t - x))); else tmp = x + (t * (z / (z - a))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -7.6e-56], N[Not[LessEqual[y, 4.9e+26]], $MachinePrecision]], N[(y * N[(1.0 / N[(N[(a - z), $MachinePrecision] / N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(t * N[(z / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -7.6 \cdot 10^{-56} \lor \neg \left(y \leq 4.9 \cdot 10^{+26}\right):\\
\;\;\;\;y \cdot \frac{1}{\frac{a - z}{t - x}}\\
\mathbf{else}:\\
\;\;\;\;x + t \cdot \frac{z}{z - a}\\
\end{array}
\end{array}
if y < -7.6000000000000004e-56 or 4.89999999999999974e26 < y Initial program 65.4%
+-commutative65.4%
*-commutative65.4%
associate-/l*85.8%
fma-define85.8%
Simplified85.8%
Taylor expanded in y around inf 63.5%
sub-div64.3%
clear-num64.2%
Applied egg-rr64.2%
if -7.6000000000000004e-56 < y < 4.89999999999999974e26Initial program 71.2%
associate-/l*75.9%
Simplified75.9%
Taylor expanded in t around inf 70.3%
associate-/l*77.3%
Simplified77.3%
Taylor expanded in y around 0 62.2%
mul-1-neg62.2%
unsub-neg62.2%
associate-/l*69.9%
Simplified69.9%
Final simplification66.9%
(FPCore (x y z t a)
:precision binary64
(if (<= a -0.0142)
(+ x (/ (- t x) (/ (- a z) y)))
(if (<= a 9.2e-178)
(- t (/ (* (- t x) (- y a)) z))
(- x (* t (/ (- y z) (- z a)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -0.0142) {
tmp = x + ((t - x) / ((a - z) / y));
} else if (a <= 9.2e-178) {
tmp = t - (((t - x) * (y - a)) / z);
} else {
tmp = x - (t * ((y - z) / (z - a)));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (a <= (-0.0142d0)) then
tmp = x + ((t - x) / ((a - z) / y))
else if (a <= 9.2d-178) then
tmp = t - (((t - x) * (y - a)) / z)
else
tmp = x - (t * ((y - z) / (z - a)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -0.0142) {
tmp = x + ((t - x) / ((a - z) / y));
} else if (a <= 9.2e-178) {
tmp = t - (((t - x) * (y - a)) / z);
} else {
tmp = x - (t * ((y - z) / (z - a)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -0.0142: tmp = x + ((t - x) / ((a - z) / y)) elif a <= 9.2e-178: tmp = t - (((t - x) * (y - a)) / z) else: tmp = x - (t * ((y - z) / (z - a))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -0.0142) tmp = Float64(x + Float64(Float64(t - x) / Float64(Float64(a - z) / y))); elseif (a <= 9.2e-178) tmp = Float64(t - Float64(Float64(Float64(t - x) * Float64(y - a)) / z)); else tmp = Float64(x - Float64(t * Float64(Float64(y - z) / Float64(z - a)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -0.0142) tmp = x + ((t - x) / ((a - z) / y)); elseif (a <= 9.2e-178) tmp = t - (((t - x) * (y - a)) / z); else tmp = x - (t * ((y - z) / (z - a))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -0.0142], N[(x + N[(N[(t - x), $MachinePrecision] / N[(N[(a - z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 9.2e-178], N[(t - N[(N[(N[(t - x), $MachinePrecision] * N[(y - a), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], N[(x - N[(t * N[(N[(y - z), $MachinePrecision] / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -0.0142:\\
\;\;\;\;x + \frac{t - x}{\frac{a - z}{y}}\\
\mathbf{elif}\;a \leq 9.2 \cdot 10^{-178}:\\
\;\;\;\;t - \frac{\left(t - x\right) \cdot \left(y - a\right)}{z}\\
\mathbf{else}:\\
\;\;\;\;x - t \cdot \frac{y - z}{z - a}\\
\end{array}
\end{array}
if a < -0.014200000000000001Initial program 64.6%
associate-/l*87.0%
Simplified87.0%
Taylor expanded in y around 0 75.9%
mul-1-neg75.9%
associate-/l*87.0%
distribute-lft-neg-out87.0%
+-commutative87.0%
div-sub87.0%
distribute-rgt-out87.0%
sub-neg87.0%
associate-/r/87.8%
Simplified87.8%
Taylor expanded in y around inf 79.2%
if -0.014200000000000001 < a < 9.19999999999999978e-178Initial program 61.1%
+-commutative61.1%
*-commutative61.1%
associate-/l*73.8%
fma-define73.8%
Simplified73.8%
Taylor expanded in z around inf 79.2%
associate--l+79.2%
associate-*r/79.2%
associate-*r/79.2%
mul-1-neg79.2%
div-sub81.3%
mul-1-neg81.3%
distribute-lft-out--81.3%
associate-*r/81.3%
mul-1-neg81.3%
unsub-neg81.3%
distribute-rgt-out--81.3%
Simplified81.3%
if 9.19999999999999978e-178 < a Initial program 75.7%
associate-/l*88.3%
Simplified88.3%
Taylor expanded in t around inf 73.2%
associate-/l*81.5%
Simplified81.5%
Final simplification81.0%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -1.06e-29) (not (<= y 1.85e+26))) (+ x (* t (/ y (- a z)))) (+ x (* t (/ z (- z a))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -1.06e-29) || !(y <= 1.85e+26)) {
tmp = x + (t * (y / (a - z)));
} else {
tmp = x + (t * (z / (z - a)));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((y <= (-1.06d-29)) .or. (.not. (y <= 1.85d+26))) then
tmp = x + (t * (y / (a - z)))
else
tmp = x + (t * (z / (z - a)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -1.06e-29) || !(y <= 1.85e+26)) {
tmp = x + (t * (y / (a - z)));
} else {
tmp = x + (t * (z / (z - a)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -1.06e-29) or not (y <= 1.85e+26): tmp = x + (t * (y / (a - z))) else: tmp = x + (t * (z / (z - a))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -1.06e-29) || !(y <= 1.85e+26)) tmp = Float64(x + Float64(t * Float64(y / Float64(a - z)))); else tmp = Float64(x + Float64(t * Float64(z / Float64(z - a)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((y <= -1.06e-29) || ~((y <= 1.85e+26))) tmp = x + (t * (y / (a - z))); else tmp = x + (t * (z / (z - a))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -1.06e-29], N[Not[LessEqual[y, 1.85e+26]], $MachinePrecision]], N[(x + N[(t * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(t * N[(z / N[(z - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.06 \cdot 10^{-29} \lor \neg \left(y \leq 1.85 \cdot 10^{+26}\right):\\
\;\;\;\;x + t \cdot \frac{y}{a - z}\\
\mathbf{else}:\\
\;\;\;\;x + t \cdot \frac{z}{z - a}\\
\end{array}
\end{array}
if y < -1.05999999999999995e-29 or 1.84999999999999994e26 < y Initial program 64.9%
associate-/l*84.2%
Simplified84.2%
Taylor expanded in y around inf 55.6%
associate-*r/69.9%
Simplified69.9%
Taylor expanded in t around inf 50.7%
associate-/l*58.3%
Simplified58.3%
if -1.05999999999999995e-29 < y < 1.84999999999999994e26Initial program 71.5%
associate-/l*75.8%
Simplified75.8%
Taylor expanded in t around inf 69.2%
associate-/l*75.1%
Simplified75.1%
Taylor expanded in y around 0 60.1%
mul-1-neg60.1%
unsub-neg60.1%
associate-/l*67.3%
Simplified67.3%
Final simplification62.8%
(FPCore (x y z t a) :precision binary64 (if (<= z -8e+124) t (if (<= z 9e+117) (+ x (* t (/ y (- a z)))) t)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -8e+124) {
tmp = t;
} else if (z <= 9e+117) {
tmp = x + (t * (y / (a - z)));
} else {
tmp = t;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (z <= (-8d+124)) then
tmp = t
else if (z <= 9d+117) then
tmp = x + (t * (y / (a - z)))
else
tmp = t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -8e+124) {
tmp = t;
} else if (z <= 9e+117) {
tmp = x + (t * (y / (a - z)));
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -8e+124: tmp = t elif z <= 9e+117: tmp = x + (t * (y / (a - z))) else: tmp = t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -8e+124) tmp = t; elseif (z <= 9e+117) tmp = Float64(x + Float64(t * Float64(y / Float64(a - z)))); else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -8e+124) tmp = t; elseif (z <= 9e+117) tmp = x + (t * (y / (a - z))); else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -8e+124], t, If[LessEqual[z, 9e+117], N[(x + N[(t * N[(y / N[(a - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -8 \cdot 10^{+124}:\\
\;\;\;\;t\\
\mathbf{elif}\;z \leq 9 \cdot 10^{+117}:\\
\;\;\;\;x + t \cdot \frac{y}{a - z}\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -7.99999999999999959e124 or 9e117 < z Initial program 38.3%
associate-/l*60.5%
Simplified60.5%
Taylor expanded in y around 0 35.9%
mul-1-neg35.9%
associate-/l*60.5%
distribute-lft-neg-out60.5%
+-commutative60.5%
div-sub60.5%
distribute-rgt-out60.5%
sub-neg60.5%
associate-/r/66.9%
Simplified66.9%
Taylor expanded in z around inf 49.5%
if -7.99999999999999959e124 < z < 9e117Initial program 82.0%
associate-/l*89.0%
Simplified89.0%
Taylor expanded in y around inf 66.6%
associate-*r/72.9%
Simplified72.9%
Taylor expanded in t around inf 62.4%
associate-/l*65.5%
Simplified65.5%
(FPCore (x y z t a) :precision binary64 (if (<= z -5.1e-76) (+ x t) (if (<= z 3.8e+118) (* x (- 1.0 (/ y a))) t)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -5.1e-76) {
tmp = x + t;
} else if (z <= 3.8e+118) {
tmp = x * (1.0 - (y / a));
} else {
tmp = t;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (z <= (-5.1d-76)) then
tmp = x + t
else if (z <= 3.8d+118) then
tmp = x * (1.0d0 - (y / a))
else
tmp = t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -5.1e-76) {
tmp = x + t;
} else if (z <= 3.8e+118) {
tmp = x * (1.0 - (y / a));
} else {
tmp = t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -5.1e-76: tmp = x + t elif z <= 3.8e+118: tmp = x * (1.0 - (y / a)) else: tmp = t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -5.1e-76) tmp = Float64(x + t); elseif (z <= 3.8e+118) tmp = Float64(x * Float64(1.0 - Float64(y / a))); else tmp = t; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -5.1e-76) tmp = x + t; elseif (z <= 3.8e+118) tmp = x * (1.0 - (y / a)); else tmp = t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -5.1e-76], N[(x + t), $MachinePrecision], If[LessEqual[z, 3.8e+118], N[(x * N[(1.0 - N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -5.1 \cdot 10^{-76}:\\
\;\;\;\;x + t\\
\mathbf{elif}\;z \leq 3.8 \cdot 10^{+118}:\\
\;\;\;\;x \cdot \left(1 - \frac{y}{a}\right)\\
\mathbf{else}:\\
\;\;\;\;t\\
\end{array}
\end{array}
if z < -5.09999999999999986e-76Initial program 57.1%
Taylor expanded in t around inf 53.7%
Taylor expanded in z around inf 44.7%
if -5.09999999999999986e-76 < z < 3.80000000000000016e118Initial program 84.2%
+-commutative84.2%
*-commutative84.2%
associate-/l*92.7%
fma-define92.7%
Simplified92.7%
Taylor expanded in t around 0 42.0%
*-rgt-identity42.0%
mul-1-neg42.0%
associate-/l*47.7%
distribute-rgt-neg-in47.7%
mul-1-neg47.7%
distribute-lft-in47.6%
mul-1-neg47.6%
unsub-neg47.6%
Simplified47.6%
Taylor expanded in z around 0 48.1%
if 3.80000000000000016e118 < z Initial program 38.0%
associate-/l*59.1%
Simplified59.1%
Taylor expanded in y around 0 37.7%
mul-1-neg37.7%
associate-/l*59.1%
distribute-lft-neg-out59.1%
+-commutative59.1%
div-sub59.1%
distribute-rgt-out59.1%
sub-neg59.1%
associate-/r/62.4%
Simplified62.4%
Taylor expanded in z around inf 50.3%
(FPCore (x y z t a) :precision binary64 (if (<= a -6.2e+40) x (if (<= a 2.1e-133) t (+ x t))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -6.2e+40) {
tmp = x;
} else if (a <= 2.1e-133) {
tmp = t;
} else {
tmp = x + t;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (a <= (-6.2d+40)) then
tmp = x
else if (a <= 2.1d-133) then
tmp = t
else
tmp = x + t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -6.2e+40) {
tmp = x;
} else if (a <= 2.1e-133) {
tmp = t;
} else {
tmp = x + t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -6.2e+40: tmp = x elif a <= 2.1e-133: tmp = t else: tmp = x + t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -6.2e+40) tmp = x; elseif (a <= 2.1e-133) tmp = t; else tmp = Float64(x + t); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -6.2e+40) tmp = x; elseif (a <= 2.1e-133) tmp = t; else tmp = x + t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -6.2e+40], x, If[LessEqual[a, 2.1e-133], t, N[(x + t), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -6.2 \cdot 10^{+40}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq 2.1 \cdot 10^{-133}:\\
\;\;\;\;t\\
\mathbf{else}:\\
\;\;\;\;x + t\\
\end{array}
\end{array}
if a < -6.1999999999999995e40Initial program 63.5%
+-commutative63.5%
*-commutative63.5%
associate-/l*88.9%
fma-define88.9%
Simplified88.9%
Taylor expanded in a around inf 49.7%
if -6.1999999999999995e40 < a < 2.1000000000000001e-133Initial program 63.4%
associate-/l*68.3%
Simplified68.3%
Taylor expanded in y around 0 56.8%
mul-1-neg56.8%
associate-/l*63.6%
distribute-lft-neg-out63.6%
+-commutative63.6%
div-sub63.7%
distribute-rgt-out68.3%
sub-neg68.3%
associate-/r/75.3%
Simplified75.3%
Taylor expanded in z around inf 38.3%
if 2.1000000000000001e-133 < a Initial program 75.2%
Taylor expanded in t around inf 73.4%
Taylor expanded in z around inf 45.6%
(FPCore (x y z t a) :precision binary64 (if (<= a -5.1e+35) x (if (<= a 1.45e+53) t x)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -5.1e+35) {
tmp = x;
} else if (a <= 1.45e+53) {
tmp = t;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (a <= (-5.1d+35)) then
tmp = x
else if (a <= 1.45d+53) then
tmp = t
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -5.1e+35) {
tmp = x;
} else if (a <= 1.45e+53) {
tmp = t;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -5.1e+35: tmp = x elif a <= 1.45e+53: tmp = t else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -5.1e+35) tmp = x; elseif (a <= 1.45e+53) tmp = t; else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -5.1e+35) tmp = x; elseif (a <= 1.45e+53) tmp = t; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -5.1e+35], x, If[LessEqual[a, 1.45e+53], t, x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -5.1 \cdot 10^{+35}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq 1.45 \cdot 10^{+53}:\\
\;\;\;\;t\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if a < -5.10000000000000017e35 or 1.4500000000000001e53 < a Initial program 69.0%
+-commutative69.0%
*-commutative69.0%
associate-/l*89.5%
fma-define89.5%
Simplified89.5%
Taylor expanded in a around inf 51.3%
if -5.10000000000000017e35 < a < 1.4500000000000001e53Initial program 67.6%
associate-/l*73.5%
Simplified73.5%
Taylor expanded in y around 0 63.3%
mul-1-neg63.3%
associate-/l*68.7%
distribute-lft-neg-out68.7%
+-commutative68.7%
div-sub68.7%
distribute-rgt-out73.5%
sub-neg73.5%
associate-/r/79.2%
Simplified79.2%
Taylor expanded in z around inf 36.4%
(FPCore (x y z t a) :precision binary64 t)
double code(double x, double y, double z, double t, double a) {
return t;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = t
end function
public static double code(double x, double y, double z, double t, double a) {
return t;
}
def code(x, y, z, t, a): return t
function code(x, y, z, t, a) return t end
function tmp = code(x, y, z, t, a) tmp = t; end
code[x_, y_, z_, t_, a_] := t
\begin{array}{l}
\\
t
\end{array}
Initial program 68.2%
associate-/l*80.0%
Simplified80.0%
Taylor expanded in y around 0 68.4%
mul-1-neg68.4%
associate-/l*77.1%
distribute-lft-neg-out77.1%
+-commutative77.1%
div-sub77.1%
distribute-rgt-out80.0%
sub-neg80.0%
associate-/r/83.4%
Simplified83.4%
Taylor expanded in z around inf 25.5%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (- t (* (/ y z) (- t x)))))
(if (< z -1.2536131056095036e+188)
t_1
(if (< z 4.446702369113811e+64)
(+ x (/ (- y z) (/ (- a z) (- t x))))
t_1))))
double code(double x, double y, double z, double t, double a) {
double t_1 = t - ((y / z) * (t - x));
double tmp;
if (z < -1.2536131056095036e+188) {
tmp = t_1;
} else if (z < 4.446702369113811e+64) {
tmp = x + ((y - z) / ((a - z) / (t - x)));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = t - ((y / z) * (t - x))
if (z < (-1.2536131056095036d+188)) then
tmp = t_1
else if (z < 4.446702369113811d+64) then
tmp = x + ((y - z) / ((a - z) / (t - x)))
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = t - ((y / z) * (t - x));
double tmp;
if (z < -1.2536131056095036e+188) {
tmp = t_1;
} else if (z < 4.446702369113811e+64) {
tmp = x + ((y - z) / ((a - z) / (t - x)));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = t - ((y / z) * (t - x)) tmp = 0 if z < -1.2536131056095036e+188: tmp = t_1 elif z < 4.446702369113811e+64: tmp = x + ((y - z) / ((a - z) / (t - x))) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(t - Float64(Float64(y / z) * Float64(t - x))) tmp = 0.0 if (z < -1.2536131056095036e+188) tmp = t_1; elseif (z < 4.446702369113811e+64) tmp = Float64(x + Float64(Float64(y - z) / Float64(Float64(a - z) / Float64(t - x)))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = t - ((y / z) * (t - x)); tmp = 0.0; if (z < -1.2536131056095036e+188) tmp = t_1; elseif (z < 4.446702369113811e+64) tmp = x + ((y - z) / ((a - z) / (t - x))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t - N[(N[(y / z), $MachinePrecision] * N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[z, -1.2536131056095036e+188], t$95$1, If[Less[z, 4.446702369113811e+64], N[(x + N[(N[(y - z), $MachinePrecision] / N[(N[(a - z), $MachinePrecision] / N[(t - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t - \frac{y}{z} \cdot \left(t - x\right)\\
\mathbf{if}\;z < -1.2536131056095036 \cdot 10^{+188}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z < 4.446702369113811 \cdot 10^{+64}:\\
\;\;\;\;x + \frac{y - z}{\frac{a - z}{t - x}}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
herbie shell --seed 2024146
(FPCore (x y z t a)
:name "Graphics.Rendering.Chart.Axis.Types:invLinMap from Chart-1.5.3"
:precision binary64
:alt
(! :herbie-platform default (if (< z -125361310560950360000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (- t (* (/ y z) (- t x))) (if (< z 44467023691138110000000000000000000000000000000000000000000000000) (+ x (/ (- y z) (/ (- a z) (- t x)))) (- t (* (/ y z) (- t x))))))
(+ x (/ (* (- y z) (- t x)) (- a z))))