
(FPCore (x y z t a) :precision binary64 (- x (/ (* y (- z t)) a)))
double code(double x, double y, double z, double t, double a) {
return x - ((y * (z - t)) / a);
}
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)) / a)
end function
public static double code(double x, double y, double z, double t, double a) {
return x - ((y * (z - t)) / a);
}
def code(x, y, z, t, a): return x - ((y * (z - t)) / a)
function code(x, y, z, t, a) return Float64(x - Float64(Float64(y * Float64(z - t)) / a)) end
function tmp = code(x, y, z, t, a) tmp = x - ((y * (z - t)) / a); end
code[x_, y_, z_, t_, a_] := N[(x - N[(N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x - \frac{y \cdot \left(z - t\right)}{a}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 15 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a) :precision binary64 (- x (/ (* y (- z t)) a)))
double code(double x, double y, double z, double t, double a) {
return x - ((y * (z - t)) / a);
}
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)) / a)
end function
public static double code(double x, double y, double z, double t, double a) {
return x - ((y * (z - t)) / a);
}
def code(x, y, z, t, a): return x - ((y * (z - t)) / a)
function code(x, y, z, t, a) return Float64(x - Float64(Float64(y * Float64(z - t)) / a)) end
function tmp = code(x, y, z, t, a) tmp = x - ((y * (z - t)) / a); end
code[x_, y_, z_, t_, a_] := N[(x - N[(N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x - \frac{y \cdot \left(z - t\right)}{a}
\end{array}
(FPCore (x y z t a)
:precision binary64
(if (<= a -4.3e+102)
(- x (/ y (/ a (- z t))))
(if (<= a 3.3e+34)
(- x (/ 1.0 (/ a (* y (- z t)))))
(+ x (* y (/ (- t z) a))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -4.3e+102) {
tmp = x - (y / (a / (z - t)));
} else if (a <= 3.3e+34) {
tmp = x - (1.0 / (a / (y * (z - t))));
} else {
tmp = x + (y * ((t - 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 <= (-4.3d+102)) then
tmp = x - (y / (a / (z - t)))
else if (a <= 3.3d+34) then
tmp = x - (1.0d0 / (a / (y * (z - t))))
else
tmp = x + (y * ((t - 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 <= -4.3e+102) {
tmp = x - (y / (a / (z - t)));
} else if (a <= 3.3e+34) {
tmp = x - (1.0 / (a / (y * (z - t))));
} else {
tmp = x + (y * ((t - z) / a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -4.3e+102: tmp = x - (y / (a / (z - t))) elif a <= 3.3e+34: tmp = x - (1.0 / (a / (y * (z - t)))) else: tmp = x + (y * ((t - z) / a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -4.3e+102) tmp = Float64(x - Float64(y / Float64(a / Float64(z - t)))); elseif (a <= 3.3e+34) tmp = Float64(x - Float64(1.0 / Float64(a / Float64(y * Float64(z - t))))); else tmp = Float64(x + Float64(y * Float64(Float64(t - z) / a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -4.3e+102) tmp = x - (y / (a / (z - t))); elseif (a <= 3.3e+34) tmp = x - (1.0 / (a / (y * (z - t)))); else tmp = x + (y * ((t - z) / a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -4.3e+102], N[(x - N[(y / N[(a / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 3.3e+34], N[(x - N[(1.0 / N[(a / N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * N[(N[(t - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -4.3 \cdot 10^{+102}:\\
\;\;\;\;x - \frac{y}{\frac{a}{z - t}}\\
\mathbf{elif}\;a \leq 3.3 \cdot 10^{+34}:\\
\;\;\;\;x - \frac{1}{\frac{a}{y \cdot \left(z - t\right)}}\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot \frac{t - z}{a}\\
\end{array}
\end{array}
if a < -4.3000000000000001e102Initial program 87.8%
associate-/l*99.8%
Simplified99.8%
clear-num99.8%
un-div-inv99.9%
Applied egg-rr99.9%
if -4.3000000000000001e102 < a < 3.29999999999999988e34Initial program 99.8%
associate-/l*87.7%
Simplified87.7%
associate-*r/99.8%
clear-num99.8%
Applied egg-rr99.8%
if 3.29999999999999988e34 < a Initial program 80.1%
associate-/l*100.0%
Simplified100.0%
Final simplification99.9%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* y (/ (- z) a))))
(if (<= t -1.75e+65)
(* t (/ y a))
(if (<= t -4.2e-240)
x
(if (<= t -2.9e-300)
t_1
(if (<= t 8.5e-55)
x
(if (<= t 4e+37) t_1 (if (<= t 6.3e+99) x (/ t (/ a y))))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = y * (-z / a);
double tmp;
if (t <= -1.75e+65) {
tmp = t * (y / a);
} else if (t <= -4.2e-240) {
tmp = x;
} else if (t <= -2.9e-300) {
tmp = t_1;
} else if (t <= 8.5e-55) {
tmp = x;
} else if (t <= 4e+37) {
tmp = t_1;
} else if (t <= 6.3e+99) {
tmp = x;
} else {
tmp = t / (a / y);
}
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 / a)
if (t <= (-1.75d+65)) then
tmp = t * (y / a)
else if (t <= (-4.2d-240)) then
tmp = x
else if (t <= (-2.9d-300)) then
tmp = t_1
else if (t <= 8.5d-55) then
tmp = x
else if (t <= 4d+37) then
tmp = t_1
else if (t <= 6.3d+99) then
tmp = x
else
tmp = t / (a / y)
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 / a);
double tmp;
if (t <= -1.75e+65) {
tmp = t * (y / a);
} else if (t <= -4.2e-240) {
tmp = x;
} else if (t <= -2.9e-300) {
tmp = t_1;
} else if (t <= 8.5e-55) {
tmp = x;
} else if (t <= 4e+37) {
tmp = t_1;
} else if (t <= 6.3e+99) {
tmp = x;
} else {
tmp = t / (a / y);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = y * (-z / a) tmp = 0 if t <= -1.75e+65: tmp = t * (y / a) elif t <= -4.2e-240: tmp = x elif t <= -2.9e-300: tmp = t_1 elif t <= 8.5e-55: tmp = x elif t <= 4e+37: tmp = t_1 elif t <= 6.3e+99: tmp = x else: tmp = t / (a / y) return tmp
function code(x, y, z, t, a) t_1 = Float64(y * Float64(Float64(-z) / a)) tmp = 0.0 if (t <= -1.75e+65) tmp = Float64(t * Float64(y / a)); elseif (t <= -4.2e-240) tmp = x; elseif (t <= -2.9e-300) tmp = t_1; elseif (t <= 8.5e-55) tmp = x; elseif (t <= 4e+37) tmp = t_1; elseif (t <= 6.3e+99) tmp = x; else tmp = Float64(t / Float64(a / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = y * (-z / a); tmp = 0.0; if (t <= -1.75e+65) tmp = t * (y / a); elseif (t <= -4.2e-240) tmp = x; elseif (t <= -2.9e-300) tmp = t_1; elseif (t <= 8.5e-55) tmp = x; elseif (t <= 4e+37) tmp = t_1; elseif (t <= 6.3e+99) tmp = x; else tmp = t / (a / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(y * N[((-z) / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.75e+65], N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, -4.2e-240], x, If[LessEqual[t, -2.9e-300], t$95$1, If[LessEqual[t, 8.5e-55], x, If[LessEqual[t, 4e+37], t$95$1, If[LessEqual[t, 6.3e+99], x, N[(t / N[(a / y), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y \cdot \frac{-z}{a}\\
\mathbf{if}\;t \leq -1.75 \cdot 10^{+65}:\\
\;\;\;\;t \cdot \frac{y}{a}\\
\mathbf{elif}\;t \leq -4.2 \cdot 10^{-240}:\\
\;\;\;\;x\\
\mathbf{elif}\;t \leq -2.9 \cdot 10^{-300}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 8.5 \cdot 10^{-55}:\\
\;\;\;\;x\\
\mathbf{elif}\;t \leq 4 \cdot 10^{+37}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 6.3 \cdot 10^{+99}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;\frac{t}{\frac{a}{y}}\\
\end{array}
\end{array}
if t < -1.75e65Initial program 88.9%
associate-/l*89.1%
Simplified89.1%
add-cube-cbrt88.0%
pow388.0%
associate-*r/87.9%
*-commutative87.9%
associate-/l*97.0%
Applied egg-rr97.0%
Taylor expanded in t around inf 61.0%
associate-*r/68.2%
Simplified68.2%
if -1.75e65 < t < -4.19999999999999987e-240 or -2.89999999999999992e-300 < t < 8.49999999999999968e-55 or 3.99999999999999982e37 < t < 6.2999999999999996e99Initial program 96.2%
associate-/l*95.8%
Simplified95.8%
Taylor expanded in x around inf 61.9%
if -4.19999999999999987e-240 < t < -2.89999999999999992e-300 or 8.49999999999999968e-55 < t < 3.99999999999999982e37Initial program 96.0%
associate-/l*85.3%
Simplified85.3%
Taylor expanded in z around inf 73.6%
mul-1-neg73.6%
associate-/l*62.9%
distribute-rgt-neg-in62.9%
distribute-frac-neg262.9%
Simplified62.9%
if 6.2999999999999996e99 < t Initial program 84.4%
associate-/l*94.4%
Simplified94.4%
add-cube-cbrt93.5%
pow393.4%
associate-*r/83.8%
*-commutative83.8%
associate-/l*95.1%
Applied egg-rr95.1%
Taylor expanded in t around inf 58.3%
associate-*r/64.6%
Simplified64.6%
clear-num64.6%
un-div-inv64.6%
Applied egg-rr64.6%
Final simplification63.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* z (/ y (- a)))) (t_2 (* t (/ y a))))
(if (<= t -1.25e+65)
t_2
(if (<= t -2.15e-240)
x
(if (<= t -6.5e-306)
t_1
(if (<= t 3.2e-78) x (if (<= t 3.85e+31) t_1 t_2)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = z * (y / -a);
double t_2 = t * (y / a);
double tmp;
if (t <= -1.25e+65) {
tmp = t_2;
} else if (t <= -2.15e-240) {
tmp = x;
} else if (t <= -6.5e-306) {
tmp = t_1;
} else if (t <= 3.2e-78) {
tmp = x;
} else if (t <= 3.85e+31) {
tmp = t_1;
} else {
tmp = t_2;
}
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) :: t_2
real(8) :: tmp
t_1 = z * (y / -a)
t_2 = t * (y / a)
if (t <= (-1.25d+65)) then
tmp = t_2
else if (t <= (-2.15d-240)) then
tmp = x
else if (t <= (-6.5d-306)) then
tmp = t_1
else if (t <= 3.2d-78) then
tmp = x
else if (t <= 3.85d+31) then
tmp = t_1
else
tmp = t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = z * (y / -a);
double t_2 = t * (y / a);
double tmp;
if (t <= -1.25e+65) {
tmp = t_2;
} else if (t <= -2.15e-240) {
tmp = x;
} else if (t <= -6.5e-306) {
tmp = t_1;
} else if (t <= 3.2e-78) {
tmp = x;
} else if (t <= 3.85e+31) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = z * (y / -a) t_2 = t * (y / a) tmp = 0 if t <= -1.25e+65: tmp = t_2 elif t <= -2.15e-240: tmp = x elif t <= -6.5e-306: tmp = t_1 elif t <= 3.2e-78: tmp = x elif t <= 3.85e+31: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a) t_1 = Float64(z * Float64(y / Float64(-a))) t_2 = Float64(t * Float64(y / a)) tmp = 0.0 if (t <= -1.25e+65) tmp = t_2; elseif (t <= -2.15e-240) tmp = x; elseif (t <= -6.5e-306) tmp = t_1; elseif (t <= 3.2e-78) tmp = x; elseif (t <= 3.85e+31) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = z * (y / -a); t_2 = t * (y / a); tmp = 0.0; if (t <= -1.25e+65) tmp = t_2; elseif (t <= -2.15e-240) tmp = x; elseif (t <= -6.5e-306) tmp = t_1; elseif (t <= 3.2e-78) tmp = x; elseif (t <= 3.85e+31) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(z * N[(y / (-a)), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.25e+65], t$95$2, If[LessEqual[t, -2.15e-240], x, If[LessEqual[t, -6.5e-306], t$95$1, If[LessEqual[t, 3.2e-78], x, If[LessEqual[t, 3.85e+31], t$95$1, t$95$2]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := z \cdot \frac{y}{-a}\\
t_2 := t \cdot \frac{y}{a}\\
\mathbf{if}\;t \leq -1.25 \cdot 10^{+65}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t \leq -2.15 \cdot 10^{-240}:\\
\;\;\;\;x\\
\mathbf{elif}\;t \leq -6.5 \cdot 10^{-306}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 3.2 \cdot 10^{-78}:\\
\;\;\;\;x\\
\mathbf{elif}\;t \leq 3.85 \cdot 10^{+31}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if t < -1.24999999999999993e65 or 3.84999999999999984e31 < t Initial program 87.5%
associate-/l*91.8%
Simplified91.8%
add-cube-cbrt90.8%
pow390.8%
associate-*r/86.6%
*-commutative86.6%
associate-/l*96.4%
Applied egg-rr96.4%
Taylor expanded in t around inf 56.2%
associate-*r/62.1%
Simplified62.1%
if -1.24999999999999993e65 < t < -2.15000000000000007e-240 or -6.5000000000000004e-306 < t < 3.2e-78Initial program 96.5%
associate-/l*96.9%
Simplified96.9%
Taylor expanded in x around inf 62.9%
if -2.15000000000000007e-240 < t < -6.5000000000000004e-306 or 3.2e-78 < t < 3.84999999999999984e31Initial program 96.2%
associate-/l*82.4%
Simplified82.4%
add-cube-cbrt81.4%
pow381.5%
associate-*r/95.1%
*-commutative95.1%
associate-/l*98.5%
Applied egg-rr98.5%
Taylor expanded in z around inf 74.7%
associate-*r/74.7%
*-commutative74.7%
neg-mul-174.7%
distribute-rgt-neg-out74.7%
associate-*r/78.2%
Simplified78.2%
Final simplification64.2%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* t (/ y a))))
(if (<= t -3.7e+65)
t_1
(if (<= t -5.5e-242)
x
(if (<= t -1.8e-302)
(* z (/ y (- a)))
(if (<= t 3.2e-77) x (if (<= t 3.6e+31) (/ (* y z) (- a)) t_1)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = t * (y / a);
double tmp;
if (t <= -3.7e+65) {
tmp = t_1;
} else if (t <= -5.5e-242) {
tmp = x;
} else if (t <= -1.8e-302) {
tmp = z * (y / -a);
} else if (t <= 3.2e-77) {
tmp = x;
} else if (t <= 3.6e+31) {
tmp = (y * z) / -a;
} 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 / a)
if (t <= (-3.7d+65)) then
tmp = t_1
else if (t <= (-5.5d-242)) then
tmp = x
else if (t <= (-1.8d-302)) then
tmp = z * (y / -a)
else if (t <= 3.2d-77) then
tmp = x
else if (t <= 3.6d+31) then
tmp = (y * z) / -a
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 / a);
double tmp;
if (t <= -3.7e+65) {
tmp = t_1;
} else if (t <= -5.5e-242) {
tmp = x;
} else if (t <= -1.8e-302) {
tmp = z * (y / -a);
} else if (t <= 3.2e-77) {
tmp = x;
} else if (t <= 3.6e+31) {
tmp = (y * z) / -a;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = t * (y / a) tmp = 0 if t <= -3.7e+65: tmp = t_1 elif t <= -5.5e-242: tmp = x elif t <= -1.8e-302: tmp = z * (y / -a) elif t <= 3.2e-77: tmp = x elif t <= 3.6e+31: tmp = (y * z) / -a else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(t * Float64(y / a)) tmp = 0.0 if (t <= -3.7e+65) tmp = t_1; elseif (t <= -5.5e-242) tmp = x; elseif (t <= -1.8e-302) tmp = Float64(z * Float64(y / Float64(-a))); elseif (t <= 3.2e-77) tmp = x; elseif (t <= 3.6e+31) tmp = Float64(Float64(y * z) / Float64(-a)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = t * (y / a); tmp = 0.0; if (t <= -3.7e+65) tmp = t_1; elseif (t <= -5.5e-242) tmp = x; elseif (t <= -1.8e-302) tmp = z * (y / -a); elseif (t <= 3.2e-77) tmp = x; elseif (t <= 3.6e+31) tmp = (y * z) / -a; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -3.7e+65], t$95$1, If[LessEqual[t, -5.5e-242], x, If[LessEqual[t, -1.8e-302], N[(z * N[(y / (-a)), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 3.2e-77], x, If[LessEqual[t, 3.6e+31], N[(N[(y * z), $MachinePrecision] / (-a)), $MachinePrecision], t$95$1]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := t \cdot \frac{y}{a}\\
\mathbf{if}\;t \leq -3.7 \cdot 10^{+65}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq -5.5 \cdot 10^{-242}:\\
\;\;\;\;x\\
\mathbf{elif}\;t \leq -1.8 \cdot 10^{-302}:\\
\;\;\;\;z \cdot \frac{y}{-a}\\
\mathbf{elif}\;t \leq 3.2 \cdot 10^{-77}:\\
\;\;\;\;x\\
\mathbf{elif}\;t \leq 3.6 \cdot 10^{+31}:\\
\;\;\;\;\frac{y \cdot z}{-a}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -3.69999999999999995e65 or 3.59999999999999996e31 < t Initial program 87.5%
associate-/l*91.8%
Simplified91.8%
add-cube-cbrt90.8%
pow390.8%
associate-*r/86.6%
*-commutative86.6%
associate-/l*96.4%
Applied egg-rr96.4%
Taylor expanded in t around inf 56.2%
associate-*r/62.1%
Simplified62.1%
if -3.69999999999999995e65 < t < -5.4999999999999998e-242 or -1.8e-302 < t < 3.2e-77Initial program 96.5%
associate-/l*96.9%
Simplified96.9%
Taylor expanded in x around inf 62.9%
if -5.4999999999999998e-242 < t < -1.8e-302Initial program 92.3%
associate-/l*78.0%
Simplified78.0%
add-cube-cbrt76.9%
pow376.9%
associate-*r/91.0%
*-commutative91.0%
associate-/l*98.1%
Applied egg-rr98.1%
Taylor expanded in z around inf 77.3%
associate-*r/77.3%
*-commutative77.3%
neg-mul-177.3%
distribute-rgt-neg-out77.3%
associate-*r/84.8%
Simplified84.8%
if 3.2e-77 < t < 3.59999999999999996e31Initial program 99.8%
associate-/l*86.6%
Simplified86.6%
Taylor expanded in z around inf 72.2%
mul-1-neg72.2%
associate-/l*58.8%
distribute-rgt-neg-in58.8%
distribute-frac-neg258.8%
Simplified58.8%
*-commutative58.8%
distribute-frac-neg258.8%
distribute-frac-neg58.8%
associate-*l/72.2%
Applied egg-rr72.2%
Final simplification64.2%
(FPCore (x y z t a)
:precision binary64
(if (or (<= z -4.4e+115)
(not (or (<= z 2.1e-22) (and (not (<= z 7.2e+17)) (<= z 2.7e+92)))))
(* (/ y a) (- t z))
(+ x (* t (/ y a)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -4.4e+115) || !((z <= 2.1e-22) || (!(z <= 7.2e+17) && (z <= 2.7e+92)))) {
tmp = (y / a) * (t - z);
} else {
tmp = x + (t * (y / 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 ((z <= (-4.4d+115)) .or. (.not. (z <= 2.1d-22) .or. (.not. (z <= 7.2d+17)) .and. (z <= 2.7d+92))) then
tmp = (y / a) * (t - z)
else
tmp = x + (t * (y / a))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -4.4e+115) || !((z <= 2.1e-22) || (!(z <= 7.2e+17) && (z <= 2.7e+92)))) {
tmp = (y / a) * (t - z);
} else {
tmp = x + (t * (y / a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -4.4e+115) or not ((z <= 2.1e-22) or (not (z <= 7.2e+17) and (z <= 2.7e+92))): tmp = (y / a) * (t - z) else: tmp = x + (t * (y / a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -4.4e+115) || !((z <= 2.1e-22) || (!(z <= 7.2e+17) && (z <= 2.7e+92)))) tmp = Float64(Float64(y / a) * Float64(t - z)); else tmp = Float64(x + Float64(t * Float64(y / a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -4.4e+115) || ~(((z <= 2.1e-22) || (~((z <= 7.2e+17)) && (z <= 2.7e+92))))) tmp = (y / a) * (t - z); else tmp = x + (t * (y / a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -4.4e+115], N[Not[Or[LessEqual[z, 2.1e-22], And[N[Not[LessEqual[z, 7.2e+17]], $MachinePrecision], LessEqual[z, 2.7e+92]]]], $MachinePrecision]], N[(N[(y / a), $MachinePrecision] * N[(t - z), $MachinePrecision]), $MachinePrecision], N[(x + N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -4.4 \cdot 10^{+115} \lor \neg \left(z \leq 2.1 \cdot 10^{-22} \lor \neg \left(z \leq 7.2 \cdot 10^{+17}\right) \land z \leq 2.7 \cdot 10^{+92}\right):\\
\;\;\;\;\frac{y}{a} \cdot \left(t - z\right)\\
\mathbf{else}:\\
\;\;\;\;x + t \cdot \frac{y}{a}\\
\end{array}
\end{array}
if z < -4.4000000000000001e115 or 2.10000000000000008e-22 < z < 7.2e17 or 2.6999999999999999e92 < z Initial program 90.3%
associate-/l*88.6%
Simplified88.6%
add-cube-cbrt87.7%
pow387.7%
associate-*r/89.2%
*-commutative89.2%
associate-/l*95.9%
Applied egg-rr95.9%
Taylor expanded in x around 0 73.8%
mul-1-neg73.8%
associate-/l*71.3%
distribute-lft-neg-in71.3%
div-sub71.1%
distribute-lft-out--70.2%
distribute-lft-neg-in70.2%
associate-*r/71.0%
mul-1-neg71.0%
cancel-sign-sub71.0%
*-commutative71.0%
associate-*l/72.8%
+-commutative72.8%
associate-*r/72.7%
fma-define72.7%
mul-1-neg72.7%
associate-*r/68.2%
fma-neg68.2%
*-commutative68.2%
associate-*l/72.7%
associate-*r/77.6%
distribute-rgt-out--80.6%
Simplified80.6%
if -4.4000000000000001e115 < z < 2.10000000000000008e-22 or 7.2e17 < z < 2.6999999999999999e92Initial program 93.8%
associate-/l*96.0%
Simplified96.0%
add-cube-cbrt94.3%
pow394.3%
associate-*r/92.2%
*-commutative92.2%
associate-/l*95.9%
Applied egg-rr95.9%
Taylor expanded in z around 0 86.7%
mul-1-neg86.7%
associate-*r/90.9%
distribute-lft-neg-out90.9%
cancel-sign-sub90.9%
Simplified90.9%
Final simplification86.9%
(FPCore (x y z t a)
:precision binary64
(if (<= a -1.5e+104)
(- x (/ y (/ a (- z t))))
(if (<= a 1.7e+34)
(- x (* (* y (- z t)) (/ 1.0 a)))
(+ x (* y (/ (- t z) a))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -1.5e+104) {
tmp = x - (y / (a / (z - t)));
} else if (a <= 1.7e+34) {
tmp = x - ((y * (z - t)) * (1.0 / a));
} else {
tmp = x + (y * ((t - 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 <= (-1.5d+104)) then
tmp = x - (y / (a / (z - t)))
else if (a <= 1.7d+34) then
tmp = x - ((y * (z - t)) * (1.0d0 / a))
else
tmp = x + (y * ((t - 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 <= -1.5e+104) {
tmp = x - (y / (a / (z - t)));
} else if (a <= 1.7e+34) {
tmp = x - ((y * (z - t)) * (1.0 / a));
} else {
tmp = x + (y * ((t - z) / a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -1.5e+104: tmp = x - (y / (a / (z - t))) elif a <= 1.7e+34: tmp = x - ((y * (z - t)) * (1.0 / a)) else: tmp = x + (y * ((t - z) / a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -1.5e+104) tmp = Float64(x - Float64(y / Float64(a / Float64(z - t)))); elseif (a <= 1.7e+34) tmp = Float64(x - Float64(Float64(y * Float64(z - t)) * Float64(1.0 / a))); else tmp = Float64(x + Float64(y * Float64(Float64(t - z) / a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -1.5e+104) tmp = x - (y / (a / (z - t))); elseif (a <= 1.7e+34) tmp = x - ((y * (z - t)) * (1.0 / a)); else tmp = x + (y * ((t - z) / a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -1.5e+104], N[(x - N[(y / N[(a / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.7e+34], N[(x - N[(N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision] * N[(1.0 / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * N[(N[(t - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.5 \cdot 10^{+104}:\\
\;\;\;\;x - \frac{y}{\frac{a}{z - t}}\\
\mathbf{elif}\;a \leq 1.7 \cdot 10^{+34}:\\
\;\;\;\;x - \left(y \cdot \left(z - t\right)\right) \cdot \frac{1}{a}\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot \frac{t - z}{a}\\
\end{array}
\end{array}
if a < -1.49999999999999984e104Initial program 87.8%
associate-/l*99.8%
Simplified99.8%
clear-num99.8%
un-div-inv99.9%
Applied egg-rr99.9%
if -1.49999999999999984e104 < a < 1.7e34Initial program 99.8%
clear-num99.8%
associate-/r/99.8%
Applied egg-rr99.8%
if 1.7e34 < a Initial program 80.1%
associate-/l*100.0%
Simplified100.0%
Final simplification99.8%
(FPCore (x y z t a) :precision binary64 (if (<= a -4.3e+102) (- x (/ y (/ a (- z t)))) (if (<= a 1e+34) (- x (/ (* y (- z t)) a)) (+ x (* y (/ (- t z) a))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -4.3e+102) {
tmp = x - (y / (a / (z - t)));
} else if (a <= 1e+34) {
tmp = x - ((y * (z - t)) / a);
} else {
tmp = x + (y * ((t - 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 <= (-4.3d+102)) then
tmp = x - (y / (a / (z - t)))
else if (a <= 1d+34) then
tmp = x - ((y * (z - t)) / a)
else
tmp = x + (y * ((t - 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 <= -4.3e+102) {
tmp = x - (y / (a / (z - t)));
} else if (a <= 1e+34) {
tmp = x - ((y * (z - t)) / a);
} else {
tmp = x + (y * ((t - z) / a));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -4.3e+102: tmp = x - (y / (a / (z - t))) elif a <= 1e+34: tmp = x - ((y * (z - t)) / a) else: tmp = x + (y * ((t - z) / a)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -4.3e+102) tmp = Float64(x - Float64(y / Float64(a / Float64(z - t)))); elseif (a <= 1e+34) tmp = Float64(x - Float64(Float64(y * Float64(z - t)) / a)); else tmp = Float64(x + Float64(y * Float64(Float64(t - z) / a))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -4.3e+102) tmp = x - (y / (a / (z - t))); elseif (a <= 1e+34) tmp = x - ((y * (z - t)) / a); else tmp = x + (y * ((t - z) / a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -4.3e+102], N[(x - N[(y / N[(a / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1e+34], N[(x - N[(N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * N[(N[(t - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -4.3 \cdot 10^{+102}:\\
\;\;\;\;x - \frac{y}{\frac{a}{z - t}}\\
\mathbf{elif}\;a \leq 10^{+34}:\\
\;\;\;\;x - \frac{y \cdot \left(z - t\right)}{a}\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot \frac{t - z}{a}\\
\end{array}
\end{array}
if a < -4.3000000000000001e102Initial program 87.8%
associate-/l*99.8%
Simplified99.8%
clear-num99.8%
un-div-inv99.9%
Applied egg-rr99.9%
if -4.3000000000000001e102 < a < 9.99999999999999946e33Initial program 99.8%
if 9.99999999999999946e33 < a Initial program 80.1%
associate-/l*100.0%
Simplified100.0%
Final simplification99.8%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -2.6e+40) (not (<= t 3.7e+31))) (+ x (* t (/ y a))) (- x (/ y (/ a z)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -2.6e+40) || !(t <= 3.7e+31)) {
tmp = x + (t * (y / a));
} else {
tmp = 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 ((t <= (-2.6d+40)) .or. (.not. (t <= 3.7d+31))) then
tmp = x + (t * (y / a))
else
tmp = 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 ((t <= -2.6e+40) || !(t <= 3.7e+31)) {
tmp = x + (t * (y / a));
} else {
tmp = x - (y / (a / z));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -2.6e+40) or not (t <= 3.7e+31): tmp = x + (t * (y / a)) else: tmp = x - (y / (a / z)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -2.6e+40) || !(t <= 3.7e+31)) tmp = Float64(x + Float64(t * Float64(y / a))); else tmp = Float64(x - Float64(y / Float64(a / z))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -2.6e+40) || ~((t <= 3.7e+31))) tmp = x + (t * (y / a)); else tmp = x - (y / (a / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -2.6e+40], N[Not[LessEqual[t, 3.7e+31]], $MachinePrecision]], N[(x + N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x - N[(y / N[(a / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.6 \cdot 10^{+40} \lor \neg \left(t \leq 3.7 \cdot 10^{+31}\right):\\
\;\;\;\;x + t \cdot \frac{y}{a}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{y}{\frac{a}{z}}\\
\end{array}
\end{array}
if t < -2.6000000000000001e40 or 3.6999999999999998e31 < t Initial program 87.7%
associate-/l*92.5%
Simplified92.5%
add-cube-cbrt91.4%
pow391.4%
associate-*r/86.8%
*-commutative86.8%
associate-/l*96.5%
Applied egg-rr96.5%
Taylor expanded in z around 0 78.5%
mul-1-neg78.5%
associate-*r/86.2%
distribute-lft-neg-out86.2%
cancel-sign-sub86.2%
Simplified86.2%
if -2.6000000000000001e40 < t < 3.6999999999999998e31Initial program 96.9%
associate-/l*93.7%
Simplified93.7%
clear-num93.4%
un-div-inv93.7%
Applied egg-rr93.7%
Taylor expanded in z around inf 89.4%
Final simplification87.9%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -3.6e-23) (not (<= t 3.85e+31))) (+ x (* t (/ y a))) (- x (/ (* y z) a))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -3.6e-23) || !(t <= 3.85e+31)) {
tmp = x + (t * (y / a));
} else {
tmp = x - ((y * 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 <= (-3.6d-23)) .or. (.not. (t <= 3.85d+31))) then
tmp = x + (t * (y / a))
else
tmp = x - ((y * 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 <= -3.6e-23) || !(t <= 3.85e+31)) {
tmp = x + (t * (y / a));
} else {
tmp = x - ((y * z) / a);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -3.6e-23) or not (t <= 3.85e+31): tmp = x + (t * (y / a)) else: tmp = x - ((y * z) / a) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -3.6e-23) || !(t <= 3.85e+31)) tmp = Float64(x + Float64(t * Float64(y / a))); else tmp = Float64(x - Float64(Float64(y * z) / a)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -3.6e-23) || ~((t <= 3.85e+31))) tmp = x + (t * (y / a)); else tmp = x - ((y * z) / a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -3.6e-23], N[Not[LessEqual[t, 3.85e+31]], $MachinePrecision]], N[(x + N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x - N[(N[(y * z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.6 \cdot 10^{-23} \lor \neg \left(t \leq 3.85 \cdot 10^{+31}\right):\\
\;\;\;\;x + t \cdot \frac{y}{a}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{y \cdot z}{a}\\
\end{array}
\end{array}
if t < -3.5999999999999998e-23 or 3.84999999999999984e31 < t Initial program 87.9%
associate-/l*93.0%
Simplified93.0%
add-cube-cbrt91.9%
pow391.9%
associate-*r/86.9%
*-commutative86.9%
associate-/l*96.6%
Applied egg-rr96.6%
Taylor expanded in z around 0 78.6%
mul-1-neg78.6%
associate-*r/85.8%
distribute-lft-neg-out85.8%
cancel-sign-sub85.8%
Simplified85.8%
if -3.5999999999999998e-23 < t < 3.84999999999999984e31Initial program 97.5%
associate-/l*93.2%
Simplified93.2%
Taylor expanded in z around inf 93.0%
Final simplification89.2%
(FPCore (x y z t a) :precision binary64 (if (<= a -1.05e+132) x (if (<= a 2.6e+53) (* (/ y a) (- t z)) x)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -1.05e+132) {
tmp = x;
} else if (a <= 2.6e+53) {
tmp = (y / a) * (t - z);
} 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 <= (-1.05d+132)) then
tmp = x
else if (a <= 2.6d+53) then
tmp = (y / a) * (t - z)
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 <= -1.05e+132) {
tmp = x;
} else if (a <= 2.6e+53) {
tmp = (y / a) * (t - z);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -1.05e+132: tmp = x elif a <= 2.6e+53: tmp = (y / a) * (t - z) else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -1.05e+132) tmp = x; elseif (a <= 2.6e+53) tmp = Float64(Float64(y / a) * Float64(t - z)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -1.05e+132) tmp = x; elseif (a <= 2.6e+53) tmp = (y / a) * (t - z); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -1.05e+132], x, If[LessEqual[a, 2.6e+53], N[(N[(y / a), $MachinePrecision] * N[(t - z), $MachinePrecision]), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.05 \cdot 10^{+132}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq 2.6 \cdot 10^{+53}:\\
\;\;\;\;\frac{y}{a} \cdot \left(t - z\right)\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if a < -1.04999999999999997e132 or 2.59999999999999998e53 < a Initial program 83.0%
associate-/l*100.0%
Simplified100.0%
Taylor expanded in x around inf 67.9%
if -1.04999999999999997e132 < a < 2.59999999999999998e53Initial program 98.6%
associate-/l*88.6%
Simplified88.6%
add-cube-cbrt87.6%
pow387.6%
associate-*r/97.4%
*-commutative97.4%
associate-/l*96.2%
Applied egg-rr96.2%
Taylor expanded in x around 0 75.1%
mul-1-neg75.1%
associate-/l*65.6%
distribute-lft-neg-in65.6%
div-sub65.5%
distribute-lft-out--61.6%
distribute-lft-neg-in61.6%
associate-*r/65.9%
mul-1-neg65.9%
cancel-sign-sub65.9%
*-commutative65.9%
associate-*l/71.2%
+-commutative71.2%
associate-*r/69.3%
fma-define69.3%
mul-1-neg69.3%
associate-*r/62.6%
fma-neg62.6%
*-commutative62.6%
associate-*l/69.3%
associate-*r/67.9%
distribute-rgt-out--74.6%
Simplified74.6%
Final simplification71.9%
(FPCore (x y z t a) :precision binary64 (if (or (<= t -3.4e+72) (not (<= t 1.3e+108))) (* t (/ y a)) x))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((t <= -3.4e+72) || !(t <= 1.3e+108)) {
tmp = t * (y / a);
} 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 ((t <= (-3.4d+72)) .or. (.not. (t <= 1.3d+108))) then
tmp = t * (y / a)
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 ((t <= -3.4e+72) || !(t <= 1.3e+108)) {
tmp = t * (y / a);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (t <= -3.4e+72) or not (t <= 1.3e+108): tmp = t * (y / a) else: tmp = x return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((t <= -3.4e+72) || !(t <= 1.3e+108)) tmp = Float64(t * Float64(y / a)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((t <= -3.4e+72) || ~((t <= 1.3e+108))) tmp = t * (y / a); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[t, -3.4e+72], N[Not[LessEqual[t, 1.3e+108]], $MachinePrecision]], N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision], x]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3.4 \cdot 10^{+72} \lor \neg \left(t \leq 1.3 \cdot 10^{+108}\right):\\
\;\;\;\;t \cdot \frac{y}{a}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if t < -3.3999999999999998e72 or 1.3000000000000001e108 < t Initial program 86.7%
associate-/l*91.7%
Simplified91.7%
add-cube-cbrt90.7%
pow390.7%
associate-*r/85.9%
*-commutative85.9%
associate-/l*96.1%
Applied egg-rr96.1%
Taylor expanded in t around inf 59.7%
associate-*r/66.4%
Simplified66.4%
if -3.3999999999999998e72 < t < 1.3000000000000001e108Initial program 96.1%
associate-/l*94.1%
Simplified94.1%
Taylor expanded in x around inf 54.5%
Final simplification59.2%
(FPCore (x y z t a) :precision binary64 (if (<= t -2.3e+68) (* t (/ y a)) (if (<= t 1.55e+105) x (/ t (/ a y)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -2.3e+68) {
tmp = t * (y / a);
} else if (t <= 1.55e+105) {
tmp = x;
} else {
tmp = t / (a / y);
}
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 <= (-2.3d+68)) then
tmp = t * (y / a)
else if (t <= 1.55d+105) then
tmp = x
else
tmp = t / (a / y)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (t <= -2.3e+68) {
tmp = t * (y / a);
} else if (t <= 1.55e+105) {
tmp = x;
} else {
tmp = t / (a / y);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if t <= -2.3e+68: tmp = t * (y / a) elif t <= 1.55e+105: tmp = x else: tmp = t / (a / y) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (t <= -2.3e+68) tmp = Float64(t * Float64(y / a)); elseif (t <= 1.55e+105) tmp = x; else tmp = Float64(t / Float64(a / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (t <= -2.3e+68) tmp = t * (y / a); elseif (t <= 1.55e+105) tmp = x; else tmp = t / (a / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[t, -2.3e+68], N[(t * N[(y / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.55e+105], x, N[(t / N[(a / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.3 \cdot 10^{+68}:\\
\;\;\;\;t \cdot \frac{y}{a}\\
\mathbf{elif}\;t \leq 1.55 \cdot 10^{+105}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;\frac{t}{\frac{a}{y}}\\
\end{array}
\end{array}
if t < -2.3e68Initial program 88.9%
associate-/l*89.1%
Simplified89.1%
add-cube-cbrt88.0%
pow388.0%
associate-*r/87.9%
*-commutative87.9%
associate-/l*97.0%
Applied egg-rr97.0%
Taylor expanded in t around inf 61.0%
associate-*r/68.2%
Simplified68.2%
if -2.3e68 < t < 1.55000000000000002e105Initial program 96.1%
associate-/l*94.1%
Simplified94.1%
Taylor expanded in x around inf 54.5%
if 1.55000000000000002e105 < t Initial program 84.4%
associate-/l*94.4%
Simplified94.4%
add-cube-cbrt93.5%
pow393.4%
associate-*r/83.8%
*-commutative83.8%
associate-/l*95.1%
Applied egg-rr95.1%
Taylor expanded in t around inf 58.3%
associate-*r/64.6%
Simplified64.6%
clear-num64.6%
un-div-inv64.6%
Applied egg-rr64.6%
Final simplification59.2%
(FPCore (x y z t a) :precision binary64 (+ x (* y (/ (- t z) a))))
double code(double x, double y, double z, double t, double a) {
return x + (y * ((t - z) / a));
}
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 * ((t - z) / a))
end function
public static double code(double x, double y, double z, double t, double a) {
return x + (y * ((t - z) / a));
}
def code(x, y, z, t, a): return x + (y * ((t - z) / a))
function code(x, y, z, t, a) return Float64(x + Float64(y * Float64(Float64(t - z) / a))) end
function tmp = code(x, y, z, t, a) tmp = x + (y * ((t - z) / a)); end
code[x_, y_, z_, t_, a_] := N[(x + N[(y * N[(N[(t - z), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + y \cdot \frac{t - z}{a}
\end{array}
Initial program 92.4%
associate-/l*93.1%
Simplified93.1%
Final simplification93.1%
(FPCore (x y z t a) :precision binary64 (- x (/ y (/ a (- z t)))))
double code(double x, double y, double z, double t, double a) {
return x - (y / (a / (z - 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 = x - (y / (a / (z - t)))
end function
public static double code(double x, double y, double z, double t, double a) {
return x - (y / (a / (z - t)));
}
def code(x, y, z, t, a): return x - (y / (a / (z - t)))
function code(x, y, z, t, a) return Float64(x - Float64(y / Float64(a / Float64(z - t)))) end
function tmp = code(x, y, z, t, a) tmp = x - (y / (a / (z - t))); end
code[x_, y_, z_, t_, a_] := N[(x - N[(y / N[(a / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x - \frac{y}{\frac{a}{z - t}}
\end{array}
Initial program 92.4%
associate-/l*93.1%
Simplified93.1%
clear-num92.9%
un-div-inv93.5%
Applied egg-rr93.5%
Final simplification93.5%
(FPCore (x y z t a) :precision binary64 x)
double code(double x, double y, double z, double t, double a) {
return x;
}
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
end function
public static double code(double x, double y, double z, double t, double a) {
return x;
}
def code(x, y, z, t, a): return x
function code(x, y, z, t, a) return x end
function tmp = code(x, y, z, t, a) tmp = x; end
code[x_, y_, z_, t_, a_] := x
\begin{array}{l}
\\
x
\end{array}
Initial program 92.4%
associate-/l*93.1%
Simplified93.1%
Taylor expanded in x around inf 42.2%
Final simplification42.2%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (/ a (- z t))))
(if (< y -1.0761266216389975e-10)
(- x (/ 1.0 (/ t_1 y)))
(if (< y 2.894426862792089e-49)
(- x (/ (* y (- z t)) a))
(- x (/ y t_1))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = a / (z - t);
double tmp;
if (y < -1.0761266216389975e-10) {
tmp = x - (1.0 / (t_1 / y));
} else if (y < 2.894426862792089e-49) {
tmp = x - ((y * (z - t)) / a);
} else {
tmp = x - (y / 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 = a / (z - t)
if (y < (-1.0761266216389975d-10)) then
tmp = x - (1.0d0 / (t_1 / y))
else if (y < 2.894426862792089d-49) then
tmp = x - ((y * (z - t)) / a)
else
tmp = x - (y / 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 = a / (z - t);
double tmp;
if (y < -1.0761266216389975e-10) {
tmp = x - (1.0 / (t_1 / y));
} else if (y < 2.894426862792089e-49) {
tmp = x - ((y * (z - t)) / a);
} else {
tmp = x - (y / t_1);
}
return tmp;
}
def code(x, y, z, t, a): t_1 = a / (z - t) tmp = 0 if y < -1.0761266216389975e-10: tmp = x - (1.0 / (t_1 / y)) elif y < 2.894426862792089e-49: tmp = x - ((y * (z - t)) / a) else: tmp = x - (y / t_1) return tmp
function code(x, y, z, t, a) t_1 = Float64(a / Float64(z - t)) tmp = 0.0 if (y < -1.0761266216389975e-10) tmp = Float64(x - Float64(1.0 / Float64(t_1 / y))); elseif (y < 2.894426862792089e-49) tmp = Float64(x - Float64(Float64(y * Float64(z - t)) / a)); else tmp = Float64(x - Float64(y / t_1)); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = a / (z - t); tmp = 0.0; if (y < -1.0761266216389975e-10) tmp = x - (1.0 / (t_1 / y)); elseif (y < 2.894426862792089e-49) tmp = x - ((y * (z - t)) / a); else tmp = x - (y / t_1); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(a / N[(z - t), $MachinePrecision]), $MachinePrecision]}, If[Less[y, -1.0761266216389975e-10], N[(x - N[(1.0 / N[(t$95$1 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Less[y, 2.894426862792089e-49], N[(x - N[(N[(y * N[(z - t), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], N[(x - N[(y / t$95$1), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{a}{z - t}\\
\mathbf{if}\;y < -1.0761266216389975 \cdot 10^{-10}:\\
\;\;\;\;x - \frac{1}{\frac{t\_1}{y}}\\
\mathbf{elif}\;y < 2.894426862792089 \cdot 10^{-49}:\\
\;\;\;\;x - \frac{y \cdot \left(z - t\right)}{a}\\
\mathbf{else}:\\
\;\;\;\;x - \frac{y}{t\_1}\\
\end{array}
\end{array}
herbie shell --seed 2024079
(FPCore (x y z t a)
:name "Optimisation.CirclePacking:place from circle-packing-0.1.0.4, F"
:precision binary64
:alt
(if (< y -1.0761266216389975e-10) (- x (/ 1.0 (/ (/ a (- z t)) y))) (if (< y 2.894426862792089e-49) (- x (/ (* y (- z t)) a)) (- x (/ y (/ a (- z t))))))
(- x (/ (* y (- z t)) a)))