
(FPCore (x y z t a) :precision binary64 (+ (/ (* 60.0 (- x y)) (- z t)) (* a 120.0)))
double code(double x, double y, double z, double t, double a) {
return ((60.0 * (x - y)) / (z - t)) + (a * 120.0);
}
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 = ((60.0d0 * (x - y)) / (z - t)) + (a * 120.0d0)
end function
public static double code(double x, double y, double z, double t, double a) {
return ((60.0 * (x - y)) / (z - t)) + (a * 120.0);
}
def code(x, y, z, t, a): return ((60.0 * (x - y)) / (z - t)) + (a * 120.0)
function code(x, y, z, t, a) return Float64(Float64(Float64(60.0 * Float64(x - y)) / Float64(z - t)) + Float64(a * 120.0)) end
function tmp = code(x, y, z, t, a) tmp = ((60.0 * (x - y)) / (z - t)) + (a * 120.0); end
code[x_, y_, z_, t_, a_] := N[(N[(N[(60.0 * N[(x - y), $MachinePrecision]), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision] + N[(a * 120.0), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{60 \cdot \left(x - y\right)}{z - t} + a \cdot 120
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 21 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a) :precision binary64 (+ (/ (* 60.0 (- x y)) (- z t)) (* a 120.0)))
double code(double x, double y, double z, double t, double a) {
return ((60.0 * (x - y)) / (z - t)) + (a * 120.0);
}
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 = ((60.0d0 * (x - y)) / (z - t)) + (a * 120.0d0)
end function
public static double code(double x, double y, double z, double t, double a) {
return ((60.0 * (x - y)) / (z - t)) + (a * 120.0);
}
def code(x, y, z, t, a): return ((60.0 * (x - y)) / (z - t)) + (a * 120.0)
function code(x, y, z, t, a) return Float64(Float64(Float64(60.0 * Float64(x - y)) / Float64(z - t)) + Float64(a * 120.0)) end
function tmp = code(x, y, z, t, a) tmp = ((60.0 * (x - y)) / (z - t)) + (a * 120.0); end
code[x_, y_, z_, t_, a_] := N[(N[(N[(60.0 * N[(x - y), $MachinePrecision]), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision] + N[(a * 120.0), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{60 \cdot \left(x - y\right)}{z - t} + a \cdot 120
\end{array}
(FPCore (x y z t a) :precision binary64 (+ (* (- x y) (/ 60.0 (- z t))) (* a 120.0)))
double code(double x, double y, double z, double t, double a) {
return ((x - y) * (60.0 / (z - t))) + (a * 120.0);
}
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) * (60.0d0 / (z - t))) + (a * 120.0d0)
end function
public static double code(double x, double y, double z, double t, double a) {
return ((x - y) * (60.0 / (z - t))) + (a * 120.0);
}
def code(x, y, z, t, a): return ((x - y) * (60.0 / (z - t))) + (a * 120.0)
function code(x, y, z, t, a) return Float64(Float64(Float64(x - y) * Float64(60.0 / Float64(z - t))) + Float64(a * 120.0)) end
function tmp = code(x, y, z, t, a) tmp = ((x - y) * (60.0 / (z - t))) + (a * 120.0); end
code[x_, y_, z_, t_, a_] := N[(N[(N[(x - y), $MachinePrecision] * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * 120.0), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(x - y\right) \cdot \frac{60}{z - t} + a \cdot 120
\end{array}
Initial program 99.4%
*-commutative99.4%
associate-/l*99.8%
Applied egg-rr99.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* 60.0 (/ (- x y) (- z t)))))
(if (<= (* a 120.0) -2e+93)
(* a 120.0)
(if (<= (* a 120.0) -5e+43)
t_1
(if (<= (* a 120.0) -5e-27)
(+ (* a 120.0) (* -60.0 (/ x t)))
(if (<= (* a 120.0) 1e-21) t_1 (* a 120.0)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = 60.0 * ((x - y) / (z - t));
double tmp;
if ((a * 120.0) <= -2e+93) {
tmp = a * 120.0;
} else if ((a * 120.0) <= -5e+43) {
tmp = t_1;
} else if ((a * 120.0) <= -5e-27) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} else if ((a * 120.0) <= 1e-21) {
tmp = t_1;
} else {
tmp = a * 120.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) :: t_1
real(8) :: tmp
t_1 = 60.0d0 * ((x - y) / (z - t))
if ((a * 120.0d0) <= (-2d+93)) then
tmp = a * 120.0d0
else if ((a * 120.0d0) <= (-5d+43)) then
tmp = t_1
else if ((a * 120.0d0) <= (-5d-27)) then
tmp = (a * 120.0d0) + ((-60.0d0) * (x / t))
else if ((a * 120.0d0) <= 1d-21) then
tmp = t_1
else
tmp = a * 120.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = 60.0 * ((x - y) / (z - t));
double tmp;
if ((a * 120.0) <= -2e+93) {
tmp = a * 120.0;
} else if ((a * 120.0) <= -5e+43) {
tmp = t_1;
} else if ((a * 120.0) <= -5e-27) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} else if ((a * 120.0) <= 1e-21) {
tmp = t_1;
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = 60.0 * ((x - y) / (z - t)) tmp = 0 if (a * 120.0) <= -2e+93: tmp = a * 120.0 elif (a * 120.0) <= -5e+43: tmp = t_1 elif (a * 120.0) <= -5e-27: tmp = (a * 120.0) + (-60.0 * (x / t)) elif (a * 120.0) <= 1e-21: tmp = t_1 else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) t_1 = Float64(60.0 * Float64(Float64(x - y) / Float64(z - t))) tmp = 0.0 if (Float64(a * 120.0) <= -2e+93) tmp = Float64(a * 120.0); elseif (Float64(a * 120.0) <= -5e+43) tmp = t_1; elseif (Float64(a * 120.0) <= -5e-27) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(x / t))); elseif (Float64(a * 120.0) <= 1e-21) tmp = t_1; else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = 60.0 * ((x - y) / (z - t)); tmp = 0.0; if ((a * 120.0) <= -2e+93) tmp = a * 120.0; elseif ((a * 120.0) <= -5e+43) tmp = t_1; elseif ((a * 120.0) <= -5e-27) tmp = (a * 120.0) + (-60.0 * (x / t)); elseif ((a * 120.0) <= 1e-21) tmp = t_1; else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(a * 120.0), $MachinePrecision], -2e+93], N[(a * 120.0), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], -5e+43], t$95$1, If[LessEqual[N[(a * 120.0), $MachinePrecision], -5e-27], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(x / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e-21], t$95$1, N[(a * 120.0), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := 60 \cdot \frac{x - y}{z - t}\\
\mathbf{if}\;a \cdot 120 \leq -2 \cdot 10^{+93}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \cdot 120 \leq -5 \cdot 10^{+43}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \cdot 120 \leq -5 \cdot 10^{-27}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{x}{t}\\
\mathbf{elif}\;a \cdot 120 \leq 10^{-21}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if (*.f64 a #s(literal 120 binary64)) < -2.00000000000000009e93 or 9.99999999999999908e-22 < (*.f64 a #s(literal 120 binary64)) Initial program 99.1%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 75.7%
if -2.00000000000000009e93 < (*.f64 a #s(literal 120 binary64)) < -5.0000000000000004e43 or -5.0000000000000002e-27 < (*.f64 a #s(literal 120 binary64)) < 9.99999999999999908e-22Initial program 99.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 80.4%
if -5.0000000000000004e43 < (*.f64 a #s(literal 120 binary64)) < -5.0000000000000002e-27Initial program 99.6%
associate-/l*99.5%
Simplified99.5%
Taylor expanded in z around 0 91.9%
Taylor expanded in x around inf 84.7%
Final simplification78.5%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* 60.0 (/ (- x y) z))))
(if (<= a -1.05e-31)
(* a 120.0)
(if (<= a -2.45e-76)
t_1
(if (<= a -1.65e-134)
(* a 120.0)
(if (<= a 1.02e-273)
t_1
(if (<= a 9e-94) (* -60.0 (/ (- x y) t)) (* a 120.0))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = 60.0 * ((x - y) / z);
double tmp;
if (a <= -1.05e-31) {
tmp = a * 120.0;
} else if (a <= -2.45e-76) {
tmp = t_1;
} else if (a <= -1.65e-134) {
tmp = a * 120.0;
} else if (a <= 1.02e-273) {
tmp = t_1;
} else if (a <= 9e-94) {
tmp = -60.0 * ((x - y) / t);
} else {
tmp = a * 120.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) :: t_1
real(8) :: tmp
t_1 = 60.0d0 * ((x - y) / z)
if (a <= (-1.05d-31)) then
tmp = a * 120.0d0
else if (a <= (-2.45d-76)) then
tmp = t_1
else if (a <= (-1.65d-134)) then
tmp = a * 120.0d0
else if (a <= 1.02d-273) then
tmp = t_1
else if (a <= 9d-94) then
tmp = (-60.0d0) * ((x - y) / t)
else
tmp = a * 120.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = 60.0 * ((x - y) / z);
double tmp;
if (a <= -1.05e-31) {
tmp = a * 120.0;
} else if (a <= -2.45e-76) {
tmp = t_1;
} else if (a <= -1.65e-134) {
tmp = a * 120.0;
} else if (a <= 1.02e-273) {
tmp = t_1;
} else if (a <= 9e-94) {
tmp = -60.0 * ((x - y) / t);
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = 60.0 * ((x - y) / z) tmp = 0 if a <= -1.05e-31: tmp = a * 120.0 elif a <= -2.45e-76: tmp = t_1 elif a <= -1.65e-134: tmp = a * 120.0 elif a <= 1.02e-273: tmp = t_1 elif a <= 9e-94: tmp = -60.0 * ((x - y) / t) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) t_1 = Float64(60.0 * Float64(Float64(x - y) / z)) tmp = 0.0 if (a <= -1.05e-31) tmp = Float64(a * 120.0); elseif (a <= -2.45e-76) tmp = t_1; elseif (a <= -1.65e-134) tmp = Float64(a * 120.0); elseif (a <= 1.02e-273) tmp = t_1; elseif (a <= 9e-94) tmp = Float64(-60.0 * Float64(Float64(x - y) / t)); else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = 60.0 * ((x - y) / z); tmp = 0.0; if (a <= -1.05e-31) tmp = a * 120.0; elseif (a <= -2.45e-76) tmp = t_1; elseif (a <= -1.65e-134) tmp = a * 120.0; elseif (a <= 1.02e-273) tmp = t_1; elseif (a <= 9e-94) tmp = -60.0 * ((x - y) / t); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(60.0 * N[(N[(x - y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -1.05e-31], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, -2.45e-76], t$95$1, If[LessEqual[a, -1.65e-134], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, 1.02e-273], t$95$1, If[LessEqual[a, 9e-94], N[(-60.0 * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := 60 \cdot \frac{x - y}{z}\\
\mathbf{if}\;a \leq -1.05 \cdot 10^{-31}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq -2.45 \cdot 10^{-76}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq -1.65 \cdot 10^{-134}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq 1.02 \cdot 10^{-273}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 9 \cdot 10^{-94}:\\
\;\;\;\;-60 \cdot \frac{x - y}{t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -1.04999999999999996e-31 or -2.44999999999999986e-76 < a < -1.6500000000000001e-134 or 9.0000000000000004e-94 < a Initial program 99.3%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 67.2%
if -1.04999999999999996e-31 < a < -2.44999999999999986e-76 or -1.6500000000000001e-134 < a < 1.0200000000000001e-273Initial program 99.5%
associate-/l*99.5%
Simplified99.5%
Taylor expanded in a around 0 91.7%
Taylor expanded in z around inf 60.8%
if 1.0200000000000001e-273 < a < 9.0000000000000004e-94Initial program 99.8%
associate-/l*99.5%
Simplified99.5%
Taylor expanded in a around 0 79.9%
Taylor expanded in z around 0 49.9%
Final simplification63.1%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* -60.0 (/ y (- z t)))))
(if (<= a -7.5e-41)
(* a 120.0)
(if (<= a -3.3e-220)
(/ (* x -60.0) t)
(if (<= a -1.9e-274)
t_1
(if (<= a -1.3e-305)
(* x (/ 60.0 z))
(if (<= a 3e-39) t_1 (* a 120.0))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = -60.0 * (y / (z - t));
double tmp;
if (a <= -7.5e-41) {
tmp = a * 120.0;
} else if (a <= -3.3e-220) {
tmp = (x * -60.0) / t;
} else if (a <= -1.9e-274) {
tmp = t_1;
} else if (a <= -1.3e-305) {
tmp = x * (60.0 / z);
} else if (a <= 3e-39) {
tmp = t_1;
} else {
tmp = a * 120.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) :: t_1
real(8) :: tmp
t_1 = (-60.0d0) * (y / (z - t))
if (a <= (-7.5d-41)) then
tmp = a * 120.0d0
else if (a <= (-3.3d-220)) then
tmp = (x * (-60.0d0)) / t
else if (a <= (-1.9d-274)) then
tmp = t_1
else if (a <= (-1.3d-305)) then
tmp = x * (60.0d0 / z)
else if (a <= 3d-39) then
tmp = t_1
else
tmp = a * 120.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = -60.0 * (y / (z - t));
double tmp;
if (a <= -7.5e-41) {
tmp = a * 120.0;
} else if (a <= -3.3e-220) {
tmp = (x * -60.0) / t;
} else if (a <= -1.9e-274) {
tmp = t_1;
} else if (a <= -1.3e-305) {
tmp = x * (60.0 / z);
} else if (a <= 3e-39) {
tmp = t_1;
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = -60.0 * (y / (z - t)) tmp = 0 if a <= -7.5e-41: tmp = a * 120.0 elif a <= -3.3e-220: tmp = (x * -60.0) / t elif a <= -1.9e-274: tmp = t_1 elif a <= -1.3e-305: tmp = x * (60.0 / z) elif a <= 3e-39: tmp = t_1 else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) t_1 = Float64(-60.0 * Float64(y / Float64(z - t))) tmp = 0.0 if (a <= -7.5e-41) tmp = Float64(a * 120.0); elseif (a <= -3.3e-220) tmp = Float64(Float64(x * -60.0) / t); elseif (a <= -1.9e-274) tmp = t_1; elseif (a <= -1.3e-305) tmp = Float64(x * Float64(60.0 / z)); elseif (a <= 3e-39) tmp = t_1; else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = -60.0 * (y / (z - t)); tmp = 0.0; if (a <= -7.5e-41) tmp = a * 120.0; elseif (a <= -3.3e-220) tmp = (x * -60.0) / t; elseif (a <= -1.9e-274) tmp = t_1; elseif (a <= -1.3e-305) tmp = x * (60.0 / z); elseif (a <= 3e-39) tmp = t_1; else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(-60.0 * N[(y / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -7.5e-41], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, -3.3e-220], N[(N[(x * -60.0), $MachinePrecision] / t), $MachinePrecision], If[LessEqual[a, -1.9e-274], t$95$1, If[LessEqual[a, -1.3e-305], N[(x * N[(60.0 / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 3e-39], t$95$1, N[(a * 120.0), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := -60 \cdot \frac{y}{z - t}\\
\mathbf{if}\;a \leq -7.5 \cdot 10^{-41}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq -3.3 \cdot 10^{-220}:\\
\;\;\;\;\frac{x \cdot -60}{t}\\
\mathbf{elif}\;a \leq -1.9 \cdot 10^{-274}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq -1.3 \cdot 10^{-305}:\\
\;\;\;\;x \cdot \frac{60}{z}\\
\mathbf{elif}\;a \leq 3 \cdot 10^{-39}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -7.50000000000000049e-41 or 3.00000000000000028e-39 < a Initial program 99.2%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 69.0%
if -7.50000000000000049e-41 < a < -3.29999999999999999e-220Initial program 99.7%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 79.5%
Taylor expanded in x around inf 62.3%
associate-*r/80.5%
*-commutative80.5%
associate-*r/80.6%
Simplified62.4%
Taylor expanded in z around 0 45.0%
associate-*r/45.1%
Simplified45.1%
if -3.29999999999999999e-220 < a < -1.89999999999999992e-274 or -1.3000000000000001e-305 < a < 3.00000000000000028e-39Initial program 99.7%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 80.4%
Taylor expanded in x around 0 46.7%
if -1.89999999999999992e-274 < a < -1.3000000000000001e-305Initial program 99.1%
associate-/l*99.1%
Simplified99.1%
Taylor expanded in a around 0 86.2%
Taylor expanded in x around inf 86.2%
associate-*r/99.1%
*-commutative99.1%
associate-*r/99.3%
Simplified86.4%
Taylor expanded in z around inf 85.7%
Final simplification59.9%
(FPCore (x y z t a)
:precision binary64
(if (<= (* a 120.0) -2e+47)
(+ (* a 120.0) (* -60.0 (/ y z)))
(if (<= (* a 120.0) -5e-27)
(+ (* a 120.0) (* -60.0 (/ x t)))
(if (<= (* a 120.0) 1e-9)
(/ 60.0 (/ (- z t) (- x y)))
(+ (* a 120.0) (* 60.0 (/ x z)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -2e+47) {
tmp = (a * 120.0) + (-60.0 * (y / z));
} else if ((a * 120.0) <= -5e-27) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} else if ((a * 120.0) <= 1e-9) {
tmp = 60.0 / ((z - t) / (x - y));
} else {
tmp = (a * 120.0) + (60.0 * (x / 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 * 120.0d0) <= (-2d+47)) then
tmp = (a * 120.0d0) + ((-60.0d0) * (y / z))
else if ((a * 120.0d0) <= (-5d-27)) then
tmp = (a * 120.0d0) + ((-60.0d0) * (x / t))
else if ((a * 120.0d0) <= 1d-9) then
tmp = 60.0d0 / ((z - t) / (x - y))
else
tmp = (a * 120.0d0) + (60.0d0 * (x / 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 * 120.0) <= -2e+47) {
tmp = (a * 120.0) + (-60.0 * (y / z));
} else if ((a * 120.0) <= -5e-27) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} else if ((a * 120.0) <= 1e-9) {
tmp = 60.0 / ((z - t) / (x - y));
} else {
tmp = (a * 120.0) + (60.0 * (x / z));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a * 120.0) <= -2e+47: tmp = (a * 120.0) + (-60.0 * (y / z)) elif (a * 120.0) <= -5e-27: tmp = (a * 120.0) + (-60.0 * (x / t)) elif (a * 120.0) <= 1e-9: tmp = 60.0 / ((z - t) / (x - y)) else: tmp = (a * 120.0) + (60.0 * (x / z)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (Float64(a * 120.0) <= -2e+47) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / z))); elseif (Float64(a * 120.0) <= -5e-27) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(x / t))); elseif (Float64(a * 120.0) <= 1e-9) tmp = Float64(60.0 / Float64(Float64(z - t) / Float64(x - y))); else tmp = Float64(Float64(a * 120.0) + Float64(60.0 * Float64(x / z))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a * 120.0) <= -2e+47) tmp = (a * 120.0) + (-60.0 * (y / z)); elseif ((a * 120.0) <= -5e-27) tmp = (a * 120.0) + (-60.0 * (x / t)); elseif ((a * 120.0) <= 1e-9) tmp = 60.0 / ((z - t) / (x - y)); else tmp = (a * 120.0) + (60.0 * (x / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[N[(a * 120.0), $MachinePrecision], -2e+47], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], -5e-27], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(x / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e-9], N[(60.0 / N[(N[(z - t), $MachinePrecision] / N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(60.0 * N[(x / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -2 \cdot 10^{+47}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z}\\
\mathbf{elif}\;a \cdot 120 \leq -5 \cdot 10^{-27}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{x}{t}\\
\mathbf{elif}\;a \cdot 120 \leq 10^{-9}:\\
\;\;\;\;\frac{60}{\frac{z - t}{x - y}}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + 60 \cdot \frac{x}{z}\\
\end{array}
\end{array}
if (*.f64 a #s(literal 120 binary64)) < -2.0000000000000001e47Initial program 98.4%
*-commutative98.4%
associate-/l*99.8%
Applied egg-rr99.8%
Taylor expanded in z around inf 84.5%
Taylor expanded in x around 0 80.1%
if -2.0000000000000001e47 < (*.f64 a #s(literal 120 binary64)) < -5.0000000000000002e-27Initial program 99.7%
associate-/l*99.5%
Simplified99.5%
Taylor expanded in z around 0 87.0%
Taylor expanded in x around inf 80.8%
if -5.0000000000000002e-27 < (*.f64 a #s(literal 120 binary64)) < 1.00000000000000006e-9Initial program 99.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 80.1%
clear-num80.1%
un-div-inv80.2%
Applied egg-rr80.2%
if 1.00000000000000006e-9 < (*.f64 a #s(literal 120 binary64)) Initial program 100.0%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 93.7%
associate-*r/93.8%
Simplified93.8%
Taylor expanded in z around inf 79.9%
Final simplification80.1%
(FPCore (x y z t a)
:precision binary64
(if (<= (* a 120.0) -2e+47)
(+ (* a 120.0) (* -60.0 (/ y z)))
(if (<= (* a 120.0) -5e-27)
(+ (* a 120.0) (* -60.0 (/ x t)))
(if (<= (* a 120.0) 1e-9)
(* 60.0 (/ (- x y) (- z t)))
(+ (* a 120.0) (* 60.0 (/ x z)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -2e+47) {
tmp = (a * 120.0) + (-60.0 * (y / z));
} else if ((a * 120.0) <= -5e-27) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} else if ((a * 120.0) <= 1e-9) {
tmp = 60.0 * ((x - y) / (z - t));
} else {
tmp = (a * 120.0) + (60.0 * (x / 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 * 120.0d0) <= (-2d+47)) then
tmp = (a * 120.0d0) + ((-60.0d0) * (y / z))
else if ((a * 120.0d0) <= (-5d-27)) then
tmp = (a * 120.0d0) + ((-60.0d0) * (x / t))
else if ((a * 120.0d0) <= 1d-9) then
tmp = 60.0d0 * ((x - y) / (z - t))
else
tmp = (a * 120.0d0) + (60.0d0 * (x / 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 * 120.0) <= -2e+47) {
tmp = (a * 120.0) + (-60.0 * (y / z));
} else if ((a * 120.0) <= -5e-27) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} else if ((a * 120.0) <= 1e-9) {
tmp = 60.0 * ((x - y) / (z - t));
} else {
tmp = (a * 120.0) + (60.0 * (x / z));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a * 120.0) <= -2e+47: tmp = (a * 120.0) + (-60.0 * (y / z)) elif (a * 120.0) <= -5e-27: tmp = (a * 120.0) + (-60.0 * (x / t)) elif (a * 120.0) <= 1e-9: tmp = 60.0 * ((x - y) / (z - t)) else: tmp = (a * 120.0) + (60.0 * (x / z)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (Float64(a * 120.0) <= -2e+47) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / z))); elseif (Float64(a * 120.0) <= -5e-27) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(x / t))); elseif (Float64(a * 120.0) <= 1e-9) tmp = Float64(60.0 * Float64(Float64(x - y) / Float64(z - t))); else tmp = Float64(Float64(a * 120.0) + Float64(60.0 * Float64(x / z))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a * 120.0) <= -2e+47) tmp = (a * 120.0) + (-60.0 * (y / z)); elseif ((a * 120.0) <= -5e-27) tmp = (a * 120.0) + (-60.0 * (x / t)); elseif ((a * 120.0) <= 1e-9) tmp = 60.0 * ((x - y) / (z - t)); else tmp = (a * 120.0) + (60.0 * (x / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[N[(a * 120.0), $MachinePrecision], -2e+47], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], -5e-27], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(x / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e-9], N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(60.0 * N[(x / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -2 \cdot 10^{+47}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z}\\
\mathbf{elif}\;a \cdot 120 \leq -5 \cdot 10^{-27}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{x}{t}\\
\mathbf{elif}\;a \cdot 120 \leq 10^{-9}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + 60 \cdot \frac{x}{z}\\
\end{array}
\end{array}
if (*.f64 a #s(literal 120 binary64)) < -2.0000000000000001e47Initial program 98.4%
*-commutative98.4%
associate-/l*99.8%
Applied egg-rr99.8%
Taylor expanded in z around inf 84.5%
Taylor expanded in x around 0 80.1%
if -2.0000000000000001e47 < (*.f64 a #s(literal 120 binary64)) < -5.0000000000000002e-27Initial program 99.7%
associate-/l*99.5%
Simplified99.5%
Taylor expanded in z around 0 87.0%
Taylor expanded in x around inf 80.8%
if -5.0000000000000002e-27 < (*.f64 a #s(literal 120 binary64)) < 1.00000000000000006e-9Initial program 99.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 80.1%
if 1.00000000000000006e-9 < (*.f64 a #s(literal 120 binary64)) Initial program 100.0%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 93.7%
associate-*r/93.8%
Simplified93.8%
Taylor expanded in z around inf 79.9%
Final simplification80.1%
(FPCore (x y z t a)
:precision binary64
(if (<= (* a 120.0) -2e+47)
(+ (* a 120.0) (* -60.0 (/ y z)))
(if (<= (* a 120.0) -5e-27)
(+ (* a 120.0) (* -60.0 (/ x t)))
(if (<= (* a 120.0) 1e-21) (* 60.0 (/ (- x y) (- z t))) (* a 120.0)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -2e+47) {
tmp = (a * 120.0) + (-60.0 * (y / z));
} else if ((a * 120.0) <= -5e-27) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} else if ((a * 120.0) <= 1e-21) {
tmp = 60.0 * ((x - y) / (z - t));
} else {
tmp = a * 120.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 ((a * 120.0d0) <= (-2d+47)) then
tmp = (a * 120.0d0) + ((-60.0d0) * (y / z))
else if ((a * 120.0d0) <= (-5d-27)) then
tmp = (a * 120.0d0) + ((-60.0d0) * (x / t))
else if ((a * 120.0d0) <= 1d-21) then
tmp = 60.0d0 * ((x - y) / (z - t))
else
tmp = a * 120.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -2e+47) {
tmp = (a * 120.0) + (-60.0 * (y / z));
} else if ((a * 120.0) <= -5e-27) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} else if ((a * 120.0) <= 1e-21) {
tmp = 60.0 * ((x - y) / (z - t));
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a * 120.0) <= -2e+47: tmp = (a * 120.0) + (-60.0 * (y / z)) elif (a * 120.0) <= -5e-27: tmp = (a * 120.0) + (-60.0 * (x / t)) elif (a * 120.0) <= 1e-21: tmp = 60.0 * ((x - y) / (z - t)) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if (Float64(a * 120.0) <= -2e+47) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / z))); elseif (Float64(a * 120.0) <= -5e-27) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(x / t))); elseif (Float64(a * 120.0) <= 1e-21) tmp = Float64(60.0 * Float64(Float64(x - y) / Float64(z - t))); else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a * 120.0) <= -2e+47) tmp = (a * 120.0) + (-60.0 * (y / z)); elseif ((a * 120.0) <= -5e-27) tmp = (a * 120.0) + (-60.0 * (x / t)); elseif ((a * 120.0) <= 1e-21) tmp = 60.0 * ((x - y) / (z - t)); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[N[(a * 120.0), $MachinePrecision], -2e+47], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], -5e-27], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(x / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e-21], N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -2 \cdot 10^{+47}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z}\\
\mathbf{elif}\;a \cdot 120 \leq -5 \cdot 10^{-27}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{x}{t}\\
\mathbf{elif}\;a \cdot 120 \leq 10^{-21}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if (*.f64 a #s(literal 120 binary64)) < -2.0000000000000001e47Initial program 98.4%
*-commutative98.4%
associate-/l*99.8%
Applied egg-rr99.8%
Taylor expanded in z around inf 84.5%
Taylor expanded in x around 0 80.1%
if -2.0000000000000001e47 < (*.f64 a #s(literal 120 binary64)) < -5.0000000000000002e-27Initial program 99.7%
associate-/l*99.5%
Simplified99.5%
Taylor expanded in z around 0 87.0%
Taylor expanded in x around inf 80.8%
if -5.0000000000000002e-27 < (*.f64 a #s(literal 120 binary64)) < 9.99999999999999908e-22Initial program 99.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 80.6%
if 9.99999999999999908e-22 < (*.f64 a #s(literal 120 binary64)) Initial program 100.0%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 78.9%
Final simplification80.1%
(FPCore (x y z t a)
:precision binary64
(if (or (<= a -4.2e+89)
(not (or (<= a -3.6e+16) (and (not (<= a -8.5e-31)) (<= a 1.4e-20)))))
(* a 120.0)
(* 60.0 (/ (- x y) (- z t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -4.2e+89) || !((a <= -3.6e+16) || (!(a <= -8.5e-31) && (a <= 1.4e-20)))) {
tmp = a * 120.0;
} else {
tmp = 60.0 * ((x - y) / (z - 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 <= (-4.2d+89)) .or. (.not. (a <= (-3.6d+16)) .or. (.not. (a <= (-8.5d-31))) .and. (a <= 1.4d-20))) then
tmp = a * 120.0d0
else
tmp = 60.0d0 * ((x - y) / (z - 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 <= -4.2e+89) || !((a <= -3.6e+16) || (!(a <= -8.5e-31) && (a <= 1.4e-20)))) {
tmp = a * 120.0;
} else {
tmp = 60.0 * ((x - y) / (z - t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -4.2e+89) or not ((a <= -3.6e+16) or (not (a <= -8.5e-31) and (a <= 1.4e-20))): tmp = a * 120.0 else: tmp = 60.0 * ((x - y) / (z - t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -4.2e+89) || !((a <= -3.6e+16) || (!(a <= -8.5e-31) && (a <= 1.4e-20)))) tmp = Float64(a * 120.0); else tmp = Float64(60.0 * Float64(Float64(x - y) / Float64(z - t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -4.2e+89) || ~(((a <= -3.6e+16) || (~((a <= -8.5e-31)) && (a <= 1.4e-20))))) tmp = a * 120.0; else tmp = 60.0 * ((x - y) / (z - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -4.2e+89], N[Not[Or[LessEqual[a, -3.6e+16], And[N[Not[LessEqual[a, -8.5e-31]], $MachinePrecision], LessEqual[a, 1.4e-20]]]], $MachinePrecision]], N[(a * 120.0), $MachinePrecision], N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -4.2 \cdot 10^{+89} \lor \neg \left(a \leq -3.6 \cdot 10^{+16} \lor \neg \left(a \leq -8.5 \cdot 10^{-31}\right) \land a \leq 1.4 \cdot 10^{-20}\right):\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\end{array}
\end{array}
if a < -4.19999999999999972e89 or -3.6e16 < a < -8.5000000000000007e-31 or 1.4000000000000001e-20 < a Initial program 99.1%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 76.3%
if -4.19999999999999972e89 < a < -3.6e16 or -8.5000000000000007e-31 < a < 1.4000000000000001e-20Initial program 99.6%
associate-/l*99.5%
Simplified99.5%
Taylor expanded in a around 0 79.1%
Final simplification77.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* x (/ 60.0 (- z t)))))
(if (<= x -6.4e+102)
t_1
(if (<= x 1.1e-263)
(* a 120.0)
(if (<= x 4.6e-171)
(/ (* y -60.0) (- z t))
(if (<= x 2.1e+114) (* a 120.0) t_1))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x * (60.0 / (z - t));
double tmp;
if (x <= -6.4e+102) {
tmp = t_1;
} else if (x <= 1.1e-263) {
tmp = a * 120.0;
} else if (x <= 4.6e-171) {
tmp = (y * -60.0) / (z - t);
} else if (x <= 2.1e+114) {
tmp = a * 120.0;
} 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 = x * (60.0d0 / (z - t))
if (x <= (-6.4d+102)) then
tmp = t_1
else if (x <= 1.1d-263) then
tmp = a * 120.0d0
else if (x <= 4.6d-171) then
tmp = (y * (-60.0d0)) / (z - t)
else if (x <= 2.1d+114) then
tmp = a * 120.0d0
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 = x * (60.0 / (z - t));
double tmp;
if (x <= -6.4e+102) {
tmp = t_1;
} else if (x <= 1.1e-263) {
tmp = a * 120.0;
} else if (x <= 4.6e-171) {
tmp = (y * -60.0) / (z - t);
} else if (x <= 2.1e+114) {
tmp = a * 120.0;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x * (60.0 / (z - t)) tmp = 0 if x <= -6.4e+102: tmp = t_1 elif x <= 1.1e-263: tmp = a * 120.0 elif x <= 4.6e-171: tmp = (y * -60.0) / (z - t) elif x <= 2.1e+114: tmp = a * 120.0 else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x * Float64(60.0 / Float64(z - t))) tmp = 0.0 if (x <= -6.4e+102) tmp = t_1; elseif (x <= 1.1e-263) tmp = Float64(a * 120.0); elseif (x <= 4.6e-171) tmp = Float64(Float64(y * -60.0) / Float64(z - t)); elseif (x <= 2.1e+114) tmp = Float64(a * 120.0); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x * (60.0 / (z - t)); tmp = 0.0; if (x <= -6.4e+102) tmp = t_1; elseif (x <= 1.1e-263) tmp = a * 120.0; elseif (x <= 4.6e-171) tmp = (y * -60.0) / (z - t); elseif (x <= 2.1e+114) tmp = a * 120.0; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -6.4e+102], t$95$1, If[LessEqual[x, 1.1e-263], N[(a * 120.0), $MachinePrecision], If[LessEqual[x, 4.6e-171], N[(N[(y * -60.0), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.1e+114], N[(a * 120.0), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{60}{z - t}\\
\mathbf{if}\;x \leq -6.4 \cdot 10^{+102}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq 1.1 \cdot 10^{-263}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;x \leq 4.6 \cdot 10^{-171}:\\
\;\;\;\;\frac{y \cdot -60}{z - t}\\
\mathbf{elif}\;x \leq 2.1 \cdot 10^{+114}:\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if x < -6.3999999999999999e102 or 2.1e114 < x Initial program 99.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 76.9%
Taylor expanded in x around inf 65.7%
associate-*r/87.5%
*-commutative87.5%
associate-*r/87.5%
Simplified65.8%
if -6.3999999999999999e102 < x < 1.1e-263 or 4.59999999999999956e-171 < x < 2.1e114Initial program 99.2%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 64.5%
if 1.1e-263 < x < 4.59999999999999956e-171Initial program 99.9%
associate-/l*99.4%
Simplified99.4%
Taylor expanded in a around 0 72.9%
Taylor expanded in x around 0 72.8%
associate-*r/99.9%
Simplified73.2%
Final simplification65.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* x (/ 60.0 (- z t)))))
(if (<= x -1.46e+103)
t_1
(if (<= x 8.5e-264)
(* a 120.0)
(if (<= x 1.15e-179)
(* -60.0 (/ y (- z t)))
(if (<= x 2.1e+114) (* a 120.0) t_1))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = x * (60.0 / (z - t));
double tmp;
if (x <= -1.46e+103) {
tmp = t_1;
} else if (x <= 8.5e-264) {
tmp = a * 120.0;
} else if (x <= 1.15e-179) {
tmp = -60.0 * (y / (z - t));
} else if (x <= 2.1e+114) {
tmp = a * 120.0;
} 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 = x * (60.0d0 / (z - t))
if (x <= (-1.46d+103)) then
tmp = t_1
else if (x <= 8.5d-264) then
tmp = a * 120.0d0
else if (x <= 1.15d-179) then
tmp = (-60.0d0) * (y / (z - t))
else if (x <= 2.1d+114) then
tmp = a * 120.0d0
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 = x * (60.0 / (z - t));
double tmp;
if (x <= -1.46e+103) {
tmp = t_1;
} else if (x <= 8.5e-264) {
tmp = a * 120.0;
} else if (x <= 1.15e-179) {
tmp = -60.0 * (y / (z - t));
} else if (x <= 2.1e+114) {
tmp = a * 120.0;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = x * (60.0 / (z - t)) tmp = 0 if x <= -1.46e+103: tmp = t_1 elif x <= 8.5e-264: tmp = a * 120.0 elif x <= 1.15e-179: tmp = -60.0 * (y / (z - t)) elif x <= 2.1e+114: tmp = a * 120.0 else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(x * Float64(60.0 / Float64(z - t))) tmp = 0.0 if (x <= -1.46e+103) tmp = t_1; elseif (x <= 8.5e-264) tmp = Float64(a * 120.0); elseif (x <= 1.15e-179) tmp = Float64(-60.0 * Float64(y / Float64(z - t))); elseif (x <= 2.1e+114) tmp = Float64(a * 120.0); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = x * (60.0 / (z - t)); tmp = 0.0; if (x <= -1.46e+103) tmp = t_1; elseif (x <= 8.5e-264) tmp = a * 120.0; elseif (x <= 1.15e-179) tmp = -60.0 * (y / (z - t)); elseif (x <= 2.1e+114) tmp = a * 120.0; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(x * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.46e+103], t$95$1, If[LessEqual[x, 8.5e-264], N[(a * 120.0), $MachinePrecision], If[LessEqual[x, 1.15e-179], N[(-60.0 * N[(y / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.1e+114], N[(a * 120.0), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{60}{z - t}\\
\mathbf{if}\;x \leq -1.46 \cdot 10^{+103}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;x \leq 8.5 \cdot 10^{-264}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;x \leq 1.15 \cdot 10^{-179}:\\
\;\;\;\;-60 \cdot \frac{y}{z - t}\\
\mathbf{elif}\;x \leq 2.1 \cdot 10^{+114}:\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if x < -1.45999999999999998e103 or 2.1e114 < x Initial program 99.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 76.9%
Taylor expanded in x around inf 65.7%
associate-*r/87.5%
*-commutative87.5%
associate-*r/87.5%
Simplified65.8%
if -1.45999999999999998e103 < x < 8.5000000000000001e-264 or 1.14999999999999994e-179 < x < 2.1e114Initial program 99.2%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 64.4%
if 8.5000000000000001e-264 < x < 1.14999999999999994e-179Initial program 99.8%
associate-/l*99.5%
Simplified99.5%
Taylor expanded in a around 0 77.8%
Taylor expanded in x around 0 77.6%
Final simplification65.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* -60.0 (/ (- x y) t))))
(if (<= a -4.6e-38)
(* a 120.0)
(if (<= a -9.6e-274)
t_1
(if (<= a 1.95e-292)
(* x (/ 60.0 z))
(if (<= a 1.55e-93) t_1 (* a 120.0)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = -60.0 * ((x - y) / t);
double tmp;
if (a <= -4.6e-38) {
tmp = a * 120.0;
} else if (a <= -9.6e-274) {
tmp = t_1;
} else if (a <= 1.95e-292) {
tmp = x * (60.0 / z);
} else if (a <= 1.55e-93) {
tmp = t_1;
} else {
tmp = a * 120.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) :: t_1
real(8) :: tmp
t_1 = (-60.0d0) * ((x - y) / t)
if (a <= (-4.6d-38)) then
tmp = a * 120.0d0
else if (a <= (-9.6d-274)) then
tmp = t_1
else if (a <= 1.95d-292) then
tmp = x * (60.0d0 / z)
else if (a <= 1.55d-93) then
tmp = t_1
else
tmp = a * 120.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = -60.0 * ((x - y) / t);
double tmp;
if (a <= -4.6e-38) {
tmp = a * 120.0;
} else if (a <= -9.6e-274) {
tmp = t_1;
} else if (a <= 1.95e-292) {
tmp = x * (60.0 / z);
} else if (a <= 1.55e-93) {
tmp = t_1;
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = -60.0 * ((x - y) / t) tmp = 0 if a <= -4.6e-38: tmp = a * 120.0 elif a <= -9.6e-274: tmp = t_1 elif a <= 1.95e-292: tmp = x * (60.0 / z) elif a <= 1.55e-93: tmp = t_1 else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) t_1 = Float64(-60.0 * Float64(Float64(x - y) / t)) tmp = 0.0 if (a <= -4.6e-38) tmp = Float64(a * 120.0); elseif (a <= -9.6e-274) tmp = t_1; elseif (a <= 1.95e-292) tmp = Float64(x * Float64(60.0 / z)); elseif (a <= 1.55e-93) tmp = t_1; else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = -60.0 * ((x - y) / t); tmp = 0.0; if (a <= -4.6e-38) tmp = a * 120.0; elseif (a <= -9.6e-274) tmp = t_1; elseif (a <= 1.95e-292) tmp = x * (60.0 / z); elseif (a <= 1.55e-93) tmp = t_1; else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(-60.0 * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -4.6e-38], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, -9.6e-274], t$95$1, If[LessEqual[a, 1.95e-292], N[(x * N[(60.0 / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.55e-93], t$95$1, N[(a * 120.0), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := -60 \cdot \frac{x - y}{t}\\
\mathbf{if}\;a \leq -4.6 \cdot 10^{-38}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq -9.6 \cdot 10^{-274}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 1.95 \cdot 10^{-292}:\\
\;\;\;\;x \cdot \frac{60}{z}\\
\mathbf{elif}\;a \leq 1.55 \cdot 10^{-93}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -4.60000000000000003e-38 or 1.55e-93 < a Initial program 99.2%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 68.0%
if -4.60000000000000003e-38 < a < -9.600000000000001e-274 or 1.95e-292 < a < 1.55e-93Initial program 99.7%
associate-/l*99.5%
Simplified99.5%
Taylor expanded in a around 0 81.8%
Taylor expanded in z around 0 46.6%
if -9.600000000000001e-274 < a < 1.95e-292Initial program 99.2%
associate-/l*99.2%
Simplified99.2%
Taylor expanded in a around 0 90.2%
Taylor expanded in x around inf 80.3%
associate-*r/89.3%
*-commutative89.3%
associate-*r/89.5%
Simplified80.5%
Taylor expanded in z around inf 70.8%
Final simplification60.2%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -3.3e+97) (not (<= y 2.3e-6))) (+ (* a 120.0) (* -60.0 (/ y (- z t)))) (+ (* a 120.0) (* x (/ 60.0 (- z t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -3.3e+97) || !(y <= 2.3e-6)) {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
} else {
tmp = (a * 120.0) + (x * (60.0 / (z - 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 ((y <= (-3.3d+97)) .or. (.not. (y <= 2.3d-6))) then
tmp = (a * 120.0d0) + ((-60.0d0) * (y / (z - t)))
else
tmp = (a * 120.0d0) + (x * (60.0d0 / (z - t)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -3.3e+97) || !(y <= 2.3e-6)) {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
} else {
tmp = (a * 120.0) + (x * (60.0 / (z - t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -3.3e+97) or not (y <= 2.3e-6): tmp = (a * 120.0) + (-60.0 * (y / (z - t))) else: tmp = (a * 120.0) + (x * (60.0 / (z - t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -3.3e+97) || !(y <= 2.3e-6)) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / Float64(z - t)))); else tmp = Float64(Float64(a * 120.0) + Float64(x * Float64(60.0 / Float64(z - t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((y <= -3.3e+97) || ~((y <= 2.3e-6))) tmp = (a * 120.0) + (-60.0 * (y / (z - t))); else tmp = (a * 120.0) + (x * (60.0 / (z - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -3.3e+97], N[Not[LessEqual[y, 2.3e-6]], $MachinePrecision]], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(y / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(x * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.3 \cdot 10^{+97} \lor \neg \left(y \leq 2.3 \cdot 10^{-6}\right):\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + x \cdot \frac{60}{z - t}\\
\end{array}
\end{array}
if y < -3.3000000000000001e97 or 2.3e-6 < y Initial program 98.9%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in x around 0 88.6%
if -3.3000000000000001e97 < y < 2.3e-6Initial program 99.8%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in x around inf 97.1%
associate-*r/97.2%
*-commutative97.2%
associate-*r/97.2%
Simplified97.2%
Final simplification93.6%
(FPCore (x y z t a) :precision binary64 (if (or (<= z -6.6e-21) (not (<= z 3e-46))) (+ (* a 120.0) (* 60.0 (/ (- x y) z))) (+ (* a 120.0) (* -60.0 (/ (- x y) t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -6.6e-21) || !(z <= 3e-46)) {
tmp = (a * 120.0) + (60.0 * ((x - y) / z));
} else {
tmp = (a * 120.0) + (-60.0 * ((x - y) / 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 <= (-6.6d-21)) .or. (.not. (z <= 3d-46))) then
tmp = (a * 120.0d0) + (60.0d0 * ((x - y) / z))
else
tmp = (a * 120.0d0) + ((-60.0d0) * ((x - y) / 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 <= -6.6e-21) || !(z <= 3e-46)) {
tmp = (a * 120.0) + (60.0 * ((x - y) / z));
} else {
tmp = (a * 120.0) + (-60.0 * ((x - y) / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -6.6e-21) or not (z <= 3e-46): tmp = (a * 120.0) + (60.0 * ((x - y) / z)) else: tmp = (a * 120.0) + (-60.0 * ((x - y) / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -6.6e-21) || !(z <= 3e-46)) tmp = Float64(Float64(a * 120.0) + Float64(60.0 * Float64(Float64(x - y) / z))); else tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(Float64(x - y) / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -6.6e-21) || ~((z <= 3e-46))) tmp = (a * 120.0) + (60.0 * ((x - y) / z)); else tmp = (a * 120.0) + (-60.0 * ((x - y) / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -6.6e-21], N[Not[LessEqual[z, 3e-46]], $MachinePrecision]], N[(N[(a * 120.0), $MachinePrecision] + N[(60.0 * N[(N[(x - y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -6.6 \cdot 10^{-21} \lor \neg \left(z \leq 3 \cdot 10^{-46}\right):\\
\;\;\;\;a \cdot 120 + 60 \cdot \frac{x - y}{z}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{x - y}{t}\\
\end{array}
\end{array}
if z < -6.60000000000000018e-21 or 2.99999999999999987e-46 < z Initial program 99.1%
*-commutative99.1%
associate-/l*99.8%
Applied egg-rr99.8%
Taylor expanded in z around inf 88.1%
if -6.60000000000000018e-21 < z < 2.99999999999999987e-46Initial program 99.8%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in z around 0 84.9%
Final simplification86.8%
(FPCore (x y z t a) :precision binary64 (if (or (<= x -1.45e+103) (not (<= x 2.1e+114))) (/ 60.0 (/ (- z t) (- x y))) (+ (* a 120.0) (* -60.0 (/ y (- z t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((x <= -1.45e+103) || !(x <= 2.1e+114)) {
tmp = 60.0 / ((z - t) / (x - y));
} else {
tmp = (a * 120.0) + (-60.0 * (y / (z - 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 ((x <= (-1.45d+103)) .or. (.not. (x <= 2.1d+114))) then
tmp = 60.0d0 / ((z - t) / (x - y))
else
tmp = (a * 120.0d0) + ((-60.0d0) * (y / (z - t)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((x <= -1.45e+103) || !(x <= 2.1e+114)) {
tmp = 60.0 / ((z - t) / (x - y));
} else {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (x <= -1.45e+103) or not (x <= 2.1e+114): tmp = 60.0 / ((z - t) / (x - y)) else: tmp = (a * 120.0) + (-60.0 * (y / (z - t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((x <= -1.45e+103) || !(x <= 2.1e+114)) tmp = Float64(60.0 / Float64(Float64(z - t) / Float64(x - y))); else tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / Float64(z - t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((x <= -1.45e+103) || ~((x <= 2.1e+114))) tmp = 60.0 / ((z - t) / (x - y)); else tmp = (a * 120.0) + (-60.0 * (y / (z - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[x, -1.45e+103], N[Not[LessEqual[x, 2.1e+114]], $MachinePrecision]], N[(60.0 / N[(N[(z - t), $MachinePrecision] / N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(y / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.45 \cdot 10^{+103} \lor \neg \left(x \leq 2.1 \cdot 10^{+114}\right):\\
\;\;\;\;\frac{60}{\frac{z - t}{x - y}}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z - t}\\
\end{array}
\end{array}
if x < -1.4499999999999999e103 or 2.1e114 < x Initial program 99.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 76.9%
clear-num76.8%
un-div-inv77.0%
Applied egg-rr77.0%
if -1.4499999999999999e103 < x < 2.1e114Initial program 99.2%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in x around 0 89.1%
Final simplification84.4%
(FPCore (x y z t a)
:precision binary64
(if (<= y -9.2e+96)
(+ (* a 120.0) (/ (* y -60.0) (- z t)))
(if (<= y 2.4e-6)
(+ (* a 120.0) (* x (/ 60.0 (- z t))))
(+ (* a 120.0) (* -60.0 (/ y (- z t)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (y <= -9.2e+96) {
tmp = (a * 120.0) + ((y * -60.0) / (z - t));
} else if (y <= 2.4e-6) {
tmp = (a * 120.0) + (x * (60.0 / (z - t)));
} else {
tmp = (a * 120.0) + (-60.0 * (y / (z - 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 (y <= (-9.2d+96)) then
tmp = (a * 120.0d0) + ((y * (-60.0d0)) / (z - t))
else if (y <= 2.4d-6) then
tmp = (a * 120.0d0) + (x * (60.0d0 / (z - t)))
else
tmp = (a * 120.0d0) + ((-60.0d0) * (y / (z - t)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (y <= -9.2e+96) {
tmp = (a * 120.0) + ((y * -60.0) / (z - t));
} else if (y <= 2.4e-6) {
tmp = (a * 120.0) + (x * (60.0 / (z - t)));
} else {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if y <= -9.2e+96: tmp = (a * 120.0) + ((y * -60.0) / (z - t)) elif y <= 2.4e-6: tmp = (a * 120.0) + (x * (60.0 / (z - t))) else: tmp = (a * 120.0) + (-60.0 * (y / (z - t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (y <= -9.2e+96) tmp = Float64(Float64(a * 120.0) + Float64(Float64(y * -60.0) / Float64(z - t))); elseif (y <= 2.4e-6) tmp = Float64(Float64(a * 120.0) + Float64(x * Float64(60.0 / Float64(z - t)))); else tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / Float64(z - t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (y <= -9.2e+96) tmp = (a * 120.0) + ((y * -60.0) / (z - t)); elseif (y <= 2.4e-6) tmp = (a * 120.0) + (x * (60.0 / (z - t))); else tmp = (a * 120.0) + (-60.0 * (y / (z - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[y, -9.2e+96], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(y * -60.0), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 2.4e-6], N[(N[(a * 120.0), $MachinePrecision] + N[(x * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(y / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -9.2 \cdot 10^{+96}:\\
\;\;\;\;a \cdot 120 + \frac{y \cdot -60}{z - t}\\
\mathbf{elif}\;y \leq 2.4 \cdot 10^{-6}:\\
\;\;\;\;a \cdot 120 + x \cdot \frac{60}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z - t}\\
\end{array}
\end{array}
if y < -9.2000000000000006e96Initial program 99.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in x around 0 85.0%
associate-*r/85.0%
Simplified85.0%
if -9.2000000000000006e96 < y < 2.3999999999999999e-6Initial program 99.8%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in x around inf 97.1%
associate-*r/97.2%
*-commutative97.2%
associate-*r/97.2%
Simplified97.2%
if 2.3999999999999999e-6 < y Initial program 98.1%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in x around 0 91.5%
Final simplification93.6%
(FPCore (x y z t a) :precision binary64 (if (<= x -7e+182) (* 60.0 (/ x z)) (if (<= x 2.1e+114) (* a 120.0) (/ (* x -60.0) t))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (x <= -7e+182) {
tmp = 60.0 * (x / z);
} else if (x <= 2.1e+114) {
tmp = a * 120.0;
} else {
tmp = (x * -60.0) / 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 (x <= (-7d+182)) then
tmp = 60.0d0 * (x / z)
else if (x <= 2.1d+114) then
tmp = a * 120.0d0
else
tmp = (x * (-60.0d0)) / t
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (x <= -7e+182) {
tmp = 60.0 * (x / z);
} else if (x <= 2.1e+114) {
tmp = a * 120.0;
} else {
tmp = (x * -60.0) / t;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if x <= -7e+182: tmp = 60.0 * (x / z) elif x <= 2.1e+114: tmp = a * 120.0 else: tmp = (x * -60.0) / t return tmp
function code(x, y, z, t, a) tmp = 0.0 if (x <= -7e+182) tmp = Float64(60.0 * Float64(x / z)); elseif (x <= 2.1e+114) tmp = Float64(a * 120.0); else tmp = Float64(Float64(x * -60.0) / t); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (x <= -7e+182) tmp = 60.0 * (x / z); elseif (x <= 2.1e+114) tmp = a * 120.0; else tmp = (x * -60.0) / t; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[x, -7e+182], N[(60.0 * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.1e+114], N[(a * 120.0), $MachinePrecision], N[(N[(x * -60.0), $MachinePrecision] / t), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -7 \cdot 10^{+182}:\\
\;\;\;\;60 \cdot \frac{x}{z}\\
\mathbf{elif}\;x \leq 2.1 \cdot 10^{+114}:\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;\frac{x \cdot -60}{t}\\
\end{array}
\end{array}
if x < -7.00000000000000045e182Initial program 99.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 73.8%
Taylor expanded in x around inf 68.3%
associate-*r/94.3%
*-commutative94.3%
associate-*r/94.5%
Simplified68.4%
Taylor expanded in z around inf 44.4%
if -7.00000000000000045e182 < x < 2.1e114Initial program 99.3%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in z around inf 58.8%
if 2.1e114 < x Initial program 99.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 86.4%
Taylor expanded in x around inf 71.2%
associate-*r/83.0%
*-commutative83.0%
associate-*r/83.0%
Simplified71.3%
Taylor expanded in z around 0 49.9%
associate-*r/50.0%
Simplified50.0%
Final simplification55.3%
(FPCore (x y z t a) :precision binary64 (if (<= x -3.15e+181) (* 60.0 (/ x z)) (if (<= x 2.1e+114) (* a 120.0) (* x (/ -60.0 t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (x <= -3.15e+181) {
tmp = 60.0 * (x / z);
} else if (x <= 2.1e+114) {
tmp = a * 120.0;
} else {
tmp = x * (-60.0 / 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 (x <= (-3.15d+181)) then
tmp = 60.0d0 * (x / z)
else if (x <= 2.1d+114) then
tmp = a * 120.0d0
else
tmp = x * ((-60.0d0) / t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (x <= -3.15e+181) {
tmp = 60.0 * (x / z);
} else if (x <= 2.1e+114) {
tmp = a * 120.0;
} else {
tmp = x * (-60.0 / t);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if x <= -3.15e+181: tmp = 60.0 * (x / z) elif x <= 2.1e+114: tmp = a * 120.0 else: tmp = x * (-60.0 / t) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (x <= -3.15e+181) tmp = Float64(60.0 * Float64(x / z)); elseif (x <= 2.1e+114) tmp = Float64(a * 120.0); else tmp = Float64(x * Float64(-60.0 / t)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (x <= -3.15e+181) tmp = 60.0 * (x / z); elseif (x <= 2.1e+114) tmp = a * 120.0; else tmp = x * (-60.0 / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[x, -3.15e+181], N[(60.0 * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.1e+114], N[(a * 120.0), $MachinePrecision], N[(x * N[(-60.0 / t), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -3.15 \cdot 10^{+181}:\\
\;\;\;\;60 \cdot \frac{x}{z}\\
\mathbf{elif}\;x \leq 2.1 \cdot 10^{+114}:\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{-60}{t}\\
\end{array}
\end{array}
if x < -3.1500000000000001e181Initial program 99.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 73.8%
Taylor expanded in x around inf 68.3%
associate-*r/94.3%
*-commutative94.3%
associate-*r/94.5%
Simplified68.4%
Taylor expanded in z around inf 44.4%
if -3.1500000000000001e181 < x < 2.1e114Initial program 99.3%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in z around inf 58.8%
if 2.1e114 < x Initial program 99.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 86.4%
Taylor expanded in x around inf 71.2%
associate-*r/83.0%
*-commutative83.0%
associate-*r/83.0%
Simplified71.3%
Taylor expanded in z around 0 49.9%
Final simplification55.3%
(FPCore (x y z t a) :precision binary64 (if (<= x -8.5e+179) (* 60.0 (/ x z)) (if (<= x 2.1e+114) (* a 120.0) (* -60.0 (/ x t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (x <= -8.5e+179) {
tmp = 60.0 * (x / z);
} else if (x <= 2.1e+114) {
tmp = a * 120.0;
} else {
tmp = -60.0 * (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 (x <= (-8.5d+179)) then
tmp = 60.0d0 * (x / z)
else if (x <= 2.1d+114) then
tmp = a * 120.0d0
else
tmp = (-60.0d0) * (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 (x <= -8.5e+179) {
tmp = 60.0 * (x / z);
} else if (x <= 2.1e+114) {
tmp = a * 120.0;
} else {
tmp = -60.0 * (x / t);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if x <= -8.5e+179: tmp = 60.0 * (x / z) elif x <= 2.1e+114: tmp = a * 120.0 else: tmp = -60.0 * (x / t) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (x <= -8.5e+179) tmp = Float64(60.0 * Float64(x / z)); elseif (x <= 2.1e+114) tmp = Float64(a * 120.0); else tmp = Float64(-60.0 * Float64(x / t)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (x <= -8.5e+179) tmp = 60.0 * (x / z); elseif (x <= 2.1e+114) tmp = a * 120.0; else tmp = -60.0 * (x / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[x, -8.5e+179], N[(60.0 * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.1e+114], N[(a * 120.0), $MachinePrecision], N[(-60.0 * N[(x / t), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -8.5 \cdot 10^{+179}:\\
\;\;\;\;60 \cdot \frac{x}{z}\\
\mathbf{elif}\;x \leq 2.1 \cdot 10^{+114}:\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;-60 \cdot \frac{x}{t}\\
\end{array}
\end{array}
if x < -8.49999999999999962e179Initial program 99.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 73.8%
Taylor expanded in x around inf 68.3%
associate-*r/94.3%
*-commutative94.3%
associate-*r/94.5%
Simplified68.4%
Taylor expanded in z around inf 44.4%
if -8.49999999999999962e179 < x < 2.1e114Initial program 99.3%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in z around inf 58.8%
if 2.1e114 < x Initial program 99.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 86.4%
Taylor expanded in x around inf 71.2%
associate-*r/83.0%
*-commutative83.0%
associate-*r/83.0%
Simplified71.3%
Taylor expanded in z around 0 49.9%
Final simplification55.3%
(FPCore (x y z t a) :precision binary64 (+ (* a 120.0) (* 60.0 (/ (- x y) (- z t)))))
double code(double x, double y, double z, double t, double a) {
return (a * 120.0) + (60.0 * ((x - y) / (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 = (a * 120.0d0) + (60.0d0 * ((x - y) / (z - t)))
end function
public static double code(double x, double y, double z, double t, double a) {
return (a * 120.0) + (60.0 * ((x - y) / (z - t)));
}
def code(x, y, z, t, a): return (a * 120.0) + (60.0 * ((x - y) / (z - t)))
function code(x, y, z, t, a) return Float64(Float64(a * 120.0) + Float64(60.0 * Float64(Float64(x - y) / Float64(z - t)))) end
function tmp = code(x, y, z, t, a) tmp = (a * 120.0) + (60.0 * ((x - y) / (z - t))); end
code[x_, y_, z_, t_, a_] := N[(N[(a * 120.0), $MachinePrecision] + N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
a \cdot 120 + 60 \cdot \frac{x - y}{z - t}
\end{array}
Initial program 99.4%
associate-/l*99.7%
Simplified99.7%
Final simplification99.7%
(FPCore (x y z t a) :precision binary64 (if (<= x 2.1e+114) (* a 120.0) (* -60.0 (/ x t))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (x <= 2.1e+114) {
tmp = a * 120.0;
} else {
tmp = -60.0 * (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 (x <= 2.1d+114) then
tmp = a * 120.0d0
else
tmp = (-60.0d0) * (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 (x <= 2.1e+114) {
tmp = a * 120.0;
} else {
tmp = -60.0 * (x / t);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if x <= 2.1e+114: tmp = a * 120.0 else: tmp = -60.0 * (x / t) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (x <= 2.1e+114) tmp = Float64(a * 120.0); else tmp = Float64(-60.0 * Float64(x / t)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (x <= 2.1e+114) tmp = a * 120.0; else tmp = -60.0 * (x / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[x, 2.1e+114], N[(a * 120.0), $MachinePrecision], N[(-60.0 * N[(x / t), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 2.1 \cdot 10^{+114}:\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;-60 \cdot \frac{x}{t}\\
\end{array}
\end{array}
if x < 2.1e114Initial program 99.4%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in z around inf 53.7%
if 2.1e114 < x Initial program 99.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 86.4%
Taylor expanded in x around inf 71.2%
associate-*r/83.0%
*-commutative83.0%
associate-*r/83.0%
Simplified71.3%
Taylor expanded in z around 0 49.9%
Final simplification53.1%
(FPCore (x y z t a) :precision binary64 (* a 120.0))
double code(double x, double y, double z, double t, double a) {
return a * 120.0;
}
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 = a * 120.0d0
end function
public static double code(double x, double y, double z, double t, double a) {
return a * 120.0;
}
def code(x, y, z, t, a): return a * 120.0
function code(x, y, z, t, a) return Float64(a * 120.0) end
function tmp = code(x, y, z, t, a) tmp = a * 120.0; end
code[x_, y_, z_, t_, a_] := N[(a * 120.0), $MachinePrecision]
\begin{array}{l}
\\
a \cdot 120
\end{array}
Initial program 99.4%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in z around inf 47.3%
Final simplification47.3%
(FPCore (x y z t a) :precision binary64 (+ (/ 60.0 (/ (- z t) (- x y))) (* a 120.0)))
double code(double x, double y, double z, double t, double a) {
return (60.0 / ((z - t) / (x - y))) + (a * 120.0);
}
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 = (60.0d0 / ((z - t) / (x - y))) + (a * 120.0d0)
end function
public static double code(double x, double y, double z, double t, double a) {
return (60.0 / ((z - t) / (x - y))) + (a * 120.0);
}
def code(x, y, z, t, a): return (60.0 / ((z - t) / (x - y))) + (a * 120.0)
function code(x, y, z, t, a) return Float64(Float64(60.0 / Float64(Float64(z - t) / Float64(x - y))) + Float64(a * 120.0)) end
function tmp = code(x, y, z, t, a) tmp = (60.0 / ((z - t) / (x - y))) + (a * 120.0); end
code[x_, y_, z_, t_, a_] := N[(N[(60.0 / N[(N[(z - t), $MachinePrecision] / N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * 120.0), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{60}{\frac{z - t}{x - y}} + a \cdot 120
\end{array}
herbie shell --seed 2024094
(FPCore (x y z t a)
:name "Data.Colour.RGB:hslsv from colour-2.3.3, B"
:precision binary64
:alt
(+ (/ 60.0 (/ (- z t) (- x y))) (* a 120.0))
(+ (/ (* 60.0 (- x y)) (- z t)) (* a 120.0)))