
(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 22 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 (+ (/ 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}
Initial program 99.4%
associate-/l*99.8%
Simplified99.8%
clear-num99.8%
un-div-inv99.8%
Applied egg-rr99.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (/ 60.0 (/ (- z t) (- x y))))
(t_2 (+ (* a 120.0) (/ (* x -60.0) t))))
(if (<= (* a 120.0) -2e-46)
t_2
(if (<= (* a 120.0) 6e-59)
t_1
(if (<= (* a 120.0) 1e-6)
(* a 120.0)
(if (<= (* a 120.0) 5000000000.0)
t_1
(if (<= (* a 120.0) 2e+132)
t_2
(+ (* a 120.0) (* -60.0 (/ y z))))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = 60.0 / ((z - t) / (x - y));
double t_2 = (a * 120.0) + ((x * -60.0) / t);
double tmp;
if ((a * 120.0) <= -2e-46) {
tmp = t_2;
} else if ((a * 120.0) <= 6e-59) {
tmp = t_1;
} else if ((a * 120.0) <= 1e-6) {
tmp = a * 120.0;
} else if ((a * 120.0) <= 5000000000.0) {
tmp = t_1;
} else if ((a * 120.0) <= 2e+132) {
tmp = t_2;
} else {
tmp = (a * 120.0) + (-60.0 * (y / z));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = 60.0d0 / ((z - t) / (x - y))
t_2 = (a * 120.0d0) + ((x * (-60.0d0)) / t)
if ((a * 120.0d0) <= (-2d-46)) then
tmp = t_2
else if ((a * 120.0d0) <= 6d-59) then
tmp = t_1
else if ((a * 120.0d0) <= 1d-6) then
tmp = a * 120.0d0
else if ((a * 120.0d0) <= 5000000000.0d0) then
tmp = t_1
else if ((a * 120.0d0) <= 2d+132) then
tmp = t_2
else
tmp = (a * 120.0d0) + ((-60.0d0) * (y / z))
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 / ((z - t) / (x - y));
double t_2 = (a * 120.0) + ((x * -60.0) / t);
double tmp;
if ((a * 120.0) <= -2e-46) {
tmp = t_2;
} else if ((a * 120.0) <= 6e-59) {
tmp = t_1;
} else if ((a * 120.0) <= 1e-6) {
tmp = a * 120.0;
} else if ((a * 120.0) <= 5000000000.0) {
tmp = t_1;
} else if ((a * 120.0) <= 2e+132) {
tmp = t_2;
} else {
tmp = (a * 120.0) + (-60.0 * (y / z));
}
return tmp;
}
def code(x, y, z, t, a): t_1 = 60.0 / ((z - t) / (x - y)) t_2 = (a * 120.0) + ((x * -60.0) / t) tmp = 0 if (a * 120.0) <= -2e-46: tmp = t_2 elif (a * 120.0) <= 6e-59: tmp = t_1 elif (a * 120.0) <= 1e-6: tmp = a * 120.0 elif (a * 120.0) <= 5000000000.0: tmp = t_1 elif (a * 120.0) <= 2e+132: tmp = t_2 else: tmp = (a * 120.0) + (-60.0 * (y / z)) return tmp
function code(x, y, z, t, a) t_1 = Float64(60.0 / Float64(Float64(z - t) / Float64(x - y))) t_2 = Float64(Float64(a * 120.0) + Float64(Float64(x * -60.0) / t)) tmp = 0.0 if (Float64(a * 120.0) <= -2e-46) tmp = t_2; elseif (Float64(a * 120.0) <= 6e-59) tmp = t_1; elseif (Float64(a * 120.0) <= 1e-6) tmp = Float64(a * 120.0); elseif (Float64(a * 120.0) <= 5000000000.0) tmp = t_1; elseif (Float64(a * 120.0) <= 2e+132) tmp = t_2; else tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / z))); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = 60.0 / ((z - t) / (x - y)); t_2 = (a * 120.0) + ((x * -60.0) / t); tmp = 0.0; if ((a * 120.0) <= -2e-46) tmp = t_2; elseif ((a * 120.0) <= 6e-59) tmp = t_1; elseif ((a * 120.0) <= 1e-6) tmp = a * 120.0; elseif ((a * 120.0) <= 5000000000.0) tmp = t_1; elseif ((a * 120.0) <= 2e+132) tmp = t_2; else tmp = (a * 120.0) + (-60.0 * (y / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(60.0 / N[(N[(z - t), $MachinePrecision] / N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(a * 120.0), $MachinePrecision] + N[(N[(x * -60.0), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(a * 120.0), $MachinePrecision], -2e-46], t$95$2, If[LessEqual[N[(a * 120.0), $MachinePrecision], 6e-59], t$95$1, If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e-6], N[(a * 120.0), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 5000000000.0], t$95$1, If[LessEqual[N[(a * 120.0), $MachinePrecision], 2e+132], t$95$2, N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{60}{\frac{z - t}{x - y}}\\
t_2 := a \cdot 120 + \frac{x \cdot -60}{t}\\
\mathbf{if}\;a \cdot 120 \leq -2 \cdot 10^{-46}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;a \cdot 120 \leq 6 \cdot 10^{-59}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \cdot 120 \leq 10^{-6}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \cdot 120 \leq 5000000000:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \cdot 120 \leq 2 \cdot 10^{+132}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z}\\
\end{array}
\end{array}
if (*.f64 a #s(literal 120 binary64)) < -2.00000000000000005e-46 or 5e9 < (*.f64 a #s(literal 120 binary64)) < 1.99999999999999998e132Initial program 99.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in x around inf 90.2%
Taylor expanded in z around 0 76.2%
associate-*r/76.2%
Simplified76.2%
if -2.00000000000000005e-46 < (*.f64 a #s(literal 120 binary64)) < 6.0000000000000002e-59 or 9.99999999999999955e-7 < (*.f64 a #s(literal 120 binary64)) < 5e9Initial program 98.9%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 81.4%
clear-num99.6%
un-div-inv99.8%
Applied egg-rr81.6%
if 6.0000000000000002e-59 < (*.f64 a #s(literal 120 binary64)) < 9.99999999999999955e-7Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 74.0%
if 1.99999999999999998e132 < (*.f64 a #s(literal 120 binary64)) Initial program 100.0%
associate-/l*100.0%
Simplified100.0%
Taylor expanded in x around 0 94.8%
associate-*r/94.7%
Simplified94.7%
Taylor expanded in z around inf 83.4%
Final simplification79.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ (* a 120.0) (/ (* x -60.0) t))))
(if (<= (* a 120.0) -2e-46)
t_1
(if (<= (* a 120.0) 6e-59)
(* (- x y) (/ 60.0 (- z t)))
(if (<= (* a 120.0) 1e-6)
(* a 120.0)
(if (<= (* a 120.0) 5000000000.0)
(* 60.0 (/ (- x y) (- z t)))
(if (<= (* a 120.0) 2e+132)
t_1
(+ (* a 120.0) (* -60.0 (/ y z))))))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = (a * 120.0) + ((x * -60.0) / t);
double tmp;
if ((a * 120.0) <= -2e-46) {
tmp = t_1;
} else if ((a * 120.0) <= 6e-59) {
tmp = (x - y) * (60.0 / (z - t));
} else if ((a * 120.0) <= 1e-6) {
tmp = a * 120.0;
} else if ((a * 120.0) <= 5000000000.0) {
tmp = 60.0 * ((x - y) / (z - t));
} else if ((a * 120.0) <= 2e+132) {
tmp = t_1;
} else {
tmp = (a * 120.0) + (-60.0 * (y / z));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = (a * 120.0d0) + ((x * (-60.0d0)) / t)
if ((a * 120.0d0) <= (-2d-46)) then
tmp = t_1
else if ((a * 120.0d0) <= 6d-59) then
tmp = (x - y) * (60.0d0 / (z - t))
else if ((a * 120.0d0) <= 1d-6) then
tmp = a * 120.0d0
else if ((a * 120.0d0) <= 5000000000.0d0) then
tmp = 60.0d0 * ((x - y) / (z - t))
else if ((a * 120.0d0) <= 2d+132) then
tmp = t_1
else
tmp = (a * 120.0d0) + ((-60.0d0) * (y / z))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = (a * 120.0) + ((x * -60.0) / t);
double tmp;
if ((a * 120.0) <= -2e-46) {
tmp = t_1;
} else if ((a * 120.0) <= 6e-59) {
tmp = (x - y) * (60.0 / (z - t));
} else if ((a * 120.0) <= 1e-6) {
tmp = a * 120.0;
} else if ((a * 120.0) <= 5000000000.0) {
tmp = 60.0 * ((x - y) / (z - t));
} else if ((a * 120.0) <= 2e+132) {
tmp = t_1;
} else {
tmp = (a * 120.0) + (-60.0 * (y / z));
}
return tmp;
}
def code(x, y, z, t, a): t_1 = (a * 120.0) + ((x * -60.0) / t) tmp = 0 if (a * 120.0) <= -2e-46: tmp = t_1 elif (a * 120.0) <= 6e-59: tmp = (x - y) * (60.0 / (z - t)) elif (a * 120.0) <= 1e-6: tmp = a * 120.0 elif (a * 120.0) <= 5000000000.0: tmp = 60.0 * ((x - y) / (z - t)) elif (a * 120.0) <= 2e+132: tmp = t_1 else: tmp = (a * 120.0) + (-60.0 * (y / z)) return tmp
function code(x, y, z, t, a) t_1 = Float64(Float64(a * 120.0) + Float64(Float64(x * -60.0) / t)) tmp = 0.0 if (Float64(a * 120.0) <= -2e-46) tmp = t_1; elseif (Float64(a * 120.0) <= 6e-59) tmp = Float64(Float64(x - y) * Float64(60.0 / Float64(z - t))); elseif (Float64(a * 120.0) <= 1e-6) tmp = Float64(a * 120.0); elseif (Float64(a * 120.0) <= 5000000000.0) tmp = Float64(60.0 * Float64(Float64(x - y) / Float64(z - t))); elseif (Float64(a * 120.0) <= 2e+132) tmp = t_1; else tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / z))); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = (a * 120.0) + ((x * -60.0) / t); tmp = 0.0; if ((a * 120.0) <= -2e-46) tmp = t_1; elseif ((a * 120.0) <= 6e-59) tmp = (x - y) * (60.0 / (z - t)); elseif ((a * 120.0) <= 1e-6) tmp = a * 120.0; elseif ((a * 120.0) <= 5000000000.0) tmp = 60.0 * ((x - y) / (z - t)); elseif ((a * 120.0) <= 2e+132) tmp = t_1; else tmp = (a * 120.0) + (-60.0 * (y / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(a * 120.0), $MachinePrecision] + N[(N[(x * -60.0), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(a * 120.0), $MachinePrecision], -2e-46], t$95$1, If[LessEqual[N[(a * 120.0), $MachinePrecision], 6e-59], N[(N[(x - y), $MachinePrecision] * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e-6], N[(a * 120.0), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 5000000000.0], N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 2e+132], t$95$1, N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot 120 + \frac{x \cdot -60}{t}\\
\mathbf{if}\;a \cdot 120 \leq -2 \cdot 10^{-46}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \cdot 120 \leq 6 \cdot 10^{-59}:\\
\;\;\;\;\left(x - y\right) \cdot \frac{60}{z - t}\\
\mathbf{elif}\;a \cdot 120 \leq 10^{-6}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \cdot 120 \leq 5000000000:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\mathbf{elif}\;a \cdot 120 \leq 2 \cdot 10^{+132}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z}\\
\end{array}
\end{array}
if (*.f64 a #s(literal 120 binary64)) < -2.00000000000000005e-46 or 5e9 < (*.f64 a #s(literal 120 binary64)) < 1.99999999999999998e132Initial program 99.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in x around inf 90.2%
Taylor expanded in z around 0 76.2%
associate-*r/76.2%
Simplified76.2%
if -2.00000000000000005e-46 < (*.f64 a #s(literal 120 binary64)) < 6.0000000000000002e-59Initial program 98.8%
associate-/l*99.6%
Simplified99.6%
clear-num99.6%
un-div-inv99.8%
Applied egg-rr99.8%
Taylor expanded in a around 0 81.4%
associate-*r/80.6%
associate-*l/81.6%
metadata-eval81.6%
associate-*r/81.4%
*-commutative81.4%
associate-*r/81.6%
metadata-eval81.6%
Simplified81.6%
if 6.0000000000000002e-59 < (*.f64 a #s(literal 120 binary64)) < 9.99999999999999955e-7Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 74.0%
if 9.99999999999999955e-7 < (*.f64 a #s(literal 120 binary64)) < 5e9Initial program 100.0%
associate-/l*100.0%
Simplified100.0%
Taylor expanded in a around 0 80.4%
if 1.99999999999999998e132 < (*.f64 a #s(literal 120 binary64)) Initial program 100.0%
associate-/l*100.0%
Simplified100.0%
Taylor expanded in x around 0 94.8%
associate-*r/94.7%
Simplified94.7%
Taylor expanded in z around inf 83.4%
Final simplification79.3%
(FPCore (x y z t a)
:precision binary64
(if (or (<= (* a 120.0) -2e+45)
(not
(or (<= (* a 120.0) -5e+21)
(and (not (<= (* a 120.0) -2e-46)) (<= (* a 120.0) 6e-59)))))
(* a 120.0)
(* (- x y) (/ 60.0 (- z t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (((a * 120.0) <= -2e+45) || !(((a * 120.0) <= -5e+21) || (!((a * 120.0) <= -2e-46) && ((a * 120.0) <= 6e-59)))) {
tmp = a * 120.0;
} else {
tmp = (x - y) * (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 (((a * 120.0d0) <= (-2d+45)) .or. (.not. ((a * 120.0d0) <= (-5d+21)) .or. (.not. ((a * 120.0d0) <= (-2d-46))) .and. ((a * 120.0d0) <= 6d-59))) then
tmp = a * 120.0d0
else
tmp = (x - y) * (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 (((a * 120.0) <= -2e+45) || !(((a * 120.0) <= -5e+21) || (!((a * 120.0) <= -2e-46) && ((a * 120.0) <= 6e-59)))) {
tmp = a * 120.0;
} else {
tmp = (x - y) * (60.0 / (z - t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if ((a * 120.0) <= -2e+45) or not (((a * 120.0) <= -5e+21) or (not ((a * 120.0) <= -2e-46) and ((a * 120.0) <= 6e-59))): tmp = a * 120.0 else: tmp = (x - y) * (60.0 / (z - t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((Float64(a * 120.0) <= -2e+45) || !((Float64(a * 120.0) <= -5e+21) || (!(Float64(a * 120.0) <= -2e-46) && (Float64(a * 120.0) <= 6e-59)))) tmp = Float64(a * 120.0); else tmp = Float64(Float64(x - y) * Float64(60.0 / Float64(z - t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (((a * 120.0) <= -2e+45) || ~((((a * 120.0) <= -5e+21) || (~(((a * 120.0) <= -2e-46)) && ((a * 120.0) <= 6e-59))))) tmp = a * 120.0; else tmp = (x - y) * (60.0 / (z - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[N[(a * 120.0), $MachinePrecision], -2e+45], N[Not[Or[LessEqual[N[(a * 120.0), $MachinePrecision], -5e+21], And[N[Not[LessEqual[N[(a * 120.0), $MachinePrecision], -2e-46]], $MachinePrecision], LessEqual[N[(a * 120.0), $MachinePrecision], 6e-59]]]], $MachinePrecision]], N[(a * 120.0), $MachinePrecision], N[(N[(x - y), $MachinePrecision] * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -2 \cdot 10^{+45} \lor \neg \left(a \cdot 120 \leq -5 \cdot 10^{+21} \lor \neg \left(a \cdot 120 \leq -2 \cdot 10^{-46}\right) \land a \cdot 120 \leq 6 \cdot 10^{-59}\right):\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;\left(x - y\right) \cdot \frac{60}{z - t}\\
\end{array}
\end{array}
if (*.f64 a #s(literal 120 binary64)) < -1.9999999999999999e45 or -5e21 < (*.f64 a #s(literal 120 binary64)) < -2.00000000000000005e-46 or 6.0000000000000002e-59 < (*.f64 a #s(literal 120 binary64)) Initial program 99.9%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 75.0%
if -1.9999999999999999e45 < (*.f64 a #s(literal 120 binary64)) < -5e21 or -2.00000000000000005e-46 < (*.f64 a #s(literal 120 binary64)) < 6.0000000000000002e-59Initial program 98.9%
associate-/l*99.6%
Simplified99.6%
clear-num99.6%
un-div-inv99.8%
Applied egg-rr99.8%
Taylor expanded in a around 0 81.6%
associate-*r/80.9%
associate-*l/81.8%
metadata-eval81.8%
associate-*r/81.6%
*-commutative81.6%
associate-*r/81.8%
metadata-eval81.8%
Simplified81.8%
Final simplification77.9%
(FPCore (x y z t a)
:precision binary64
(if (<= (* a 120.0) -5e+52)
(+ (* a 120.0) (* 60.0 (/ x z)))
(if (or (<= (* a 120.0) -5e+21)
(and (not (<= (* a 120.0) -2e-46)) (<= (* a 120.0) 6e-59)))
(* (- x y) (/ 60.0 (- z t)))
(* a 120.0))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -5e+52) {
tmp = (a * 120.0) + (60.0 * (x / z));
} else if (((a * 120.0) <= -5e+21) || (!((a * 120.0) <= -2e-46) && ((a * 120.0) <= 6e-59))) {
tmp = (x - y) * (60.0 / (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) <= (-5d+52)) then
tmp = (a * 120.0d0) + (60.0d0 * (x / z))
else if (((a * 120.0d0) <= (-5d+21)) .or. (.not. ((a * 120.0d0) <= (-2d-46))) .and. ((a * 120.0d0) <= 6d-59)) then
tmp = (x - y) * (60.0d0 / (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) <= -5e+52) {
tmp = (a * 120.0) + (60.0 * (x / z));
} else if (((a * 120.0) <= -5e+21) || (!((a * 120.0) <= -2e-46) && ((a * 120.0) <= 6e-59))) {
tmp = (x - y) * (60.0 / (z - t));
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a * 120.0) <= -5e+52: tmp = (a * 120.0) + (60.0 * (x / z)) elif ((a * 120.0) <= -5e+21) or (not ((a * 120.0) <= -2e-46) and ((a * 120.0) <= 6e-59)): tmp = (x - y) * (60.0 / (z - t)) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if (Float64(a * 120.0) <= -5e+52) tmp = Float64(Float64(a * 120.0) + Float64(60.0 * Float64(x / z))); elseif ((Float64(a * 120.0) <= -5e+21) || (!(Float64(a * 120.0) <= -2e-46) && (Float64(a * 120.0) <= 6e-59))) tmp = Float64(Float64(x - y) * Float64(60.0 / 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) <= -5e+52) tmp = (a * 120.0) + (60.0 * (x / z)); elseif (((a * 120.0) <= -5e+21) || (~(((a * 120.0) <= -2e-46)) && ((a * 120.0) <= 6e-59))) tmp = (x - y) * (60.0 / (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], -5e+52], N[(N[(a * 120.0), $MachinePrecision] + N[(60.0 * N[(x / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[N[(a * 120.0), $MachinePrecision], -5e+21], And[N[Not[LessEqual[N[(a * 120.0), $MachinePrecision], -2e-46]], $MachinePrecision], LessEqual[N[(a * 120.0), $MachinePrecision], 6e-59]]], N[(N[(x - y), $MachinePrecision] * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -5 \cdot 10^{+52}:\\
\;\;\;\;a \cdot 120 + 60 \cdot \frac{x}{z}\\
\mathbf{elif}\;a \cdot 120 \leq -5 \cdot 10^{+21} \lor \neg \left(a \cdot 120 \leq -2 \cdot 10^{-46}\right) \land a \cdot 120 \leq 6 \cdot 10^{-59}:\\
\;\;\;\;\left(x - y\right) \cdot \frac{60}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if (*.f64 a #s(literal 120 binary64)) < -5e52Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 94.2%
Taylor expanded in z around inf 83.1%
if -5e52 < (*.f64 a #s(literal 120 binary64)) < -5e21 or -2.00000000000000005e-46 < (*.f64 a #s(literal 120 binary64)) < 6.0000000000000002e-59Initial program 98.9%
associate-/l*99.6%
Simplified99.6%
clear-num99.6%
un-div-inv99.8%
Applied egg-rr99.8%
Taylor expanded in a around 0 81.1%
associate-*r/80.4%
associate-*l/81.2%
metadata-eval81.2%
associate-*r/81.1%
*-commutative81.1%
associate-*r/81.2%
metadata-eval81.2%
Simplified81.2%
if -5e21 < (*.f64 a #s(literal 120 binary64)) < -2.00000000000000005e-46 or 6.0000000000000002e-59 < (*.f64 a #s(literal 120 binary64)) Initial program 99.9%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 71.9%
Final simplification78.3%
(FPCore (x y z t a)
:precision binary64
(if (or (<= a -1.1e+36)
(and (not (<= a -5.5e+19)) (or (<= a -1.9e-48) (not (<= a 6.4e-61)))))
(* 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 <= -1.1e+36) || (!(a <= -5.5e+19) && ((a <= -1.9e-48) || !(a <= 6.4e-61)))) {
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 <= (-1.1d+36)) .or. (.not. (a <= (-5.5d+19))) .and. (a <= (-1.9d-48)) .or. (.not. (a <= 6.4d-61))) 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 <= -1.1e+36) || (!(a <= -5.5e+19) && ((a <= -1.9e-48) || !(a <= 6.4e-61)))) {
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 <= -1.1e+36) or (not (a <= -5.5e+19) and ((a <= -1.9e-48) or not (a <= 6.4e-61))): 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 <= -1.1e+36) || (!(a <= -5.5e+19) && ((a <= -1.9e-48) || !(a <= 6.4e-61)))) 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 <= -1.1e+36) || (~((a <= -5.5e+19)) && ((a <= -1.9e-48) || ~((a <= 6.4e-61))))) 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, -1.1e+36], And[N[Not[LessEqual[a, -5.5e+19]], $MachinePrecision], Or[LessEqual[a, -1.9e-48], N[Not[LessEqual[a, 6.4e-61]], $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 -1.1 \cdot 10^{+36} \lor \neg \left(a \leq -5.5 \cdot 10^{+19}\right) \land \left(a \leq -1.9 \cdot 10^{-48} \lor \neg \left(a \leq 6.4 \cdot 10^{-61}\right)\right):\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\end{array}
\end{array}
if a < -1.1e36 or -5.5e19 < a < -1.90000000000000001e-48 or 6.4000000000000003e-61 < a Initial program 99.9%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 75.0%
if -1.1e36 < a < -5.5e19 or -1.90000000000000001e-48 < a < 6.4000000000000003e-61Initial program 98.9%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 81.6%
Final simplification77.8%
(FPCore (x y z t a)
:precision binary64
(if (<= x -2.9e+176)
(* (- x y) (/ 60.0 (- z t)))
(if (<= x 2.05e+188)
(+ (* a 120.0) (* -60.0 (/ y (- z t))))
(if (<= x 1.2e+274)
(+ (* a 120.0) (* -60.0 (/ (- x y) t)))
(+ (* a 120.0) (* 60.0 (/ x z)))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (x <= -2.9e+176) {
tmp = (x - y) * (60.0 / (z - t));
} else if (x <= 2.05e+188) {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
} else if (x <= 1.2e+274) {
tmp = (a * 120.0) + (-60.0 * ((x - y) / 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 (x <= (-2.9d+176)) then
tmp = (x - y) * (60.0d0 / (z - t))
else if (x <= 2.05d+188) then
tmp = (a * 120.0d0) + ((-60.0d0) * (y / (z - t)))
else if (x <= 1.2d+274) then
tmp = (a * 120.0d0) + ((-60.0d0) * ((x - y) / 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 (x <= -2.9e+176) {
tmp = (x - y) * (60.0 / (z - t));
} else if (x <= 2.05e+188) {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
} else if (x <= 1.2e+274) {
tmp = (a * 120.0) + (-60.0 * ((x - y) / t));
} else {
tmp = (a * 120.0) + (60.0 * (x / z));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if x <= -2.9e+176: tmp = (x - y) * (60.0 / (z - t)) elif x <= 2.05e+188: tmp = (a * 120.0) + (-60.0 * (y / (z - t))) elif x <= 1.2e+274: tmp = (a * 120.0) + (-60.0 * ((x - y) / t)) else: tmp = (a * 120.0) + (60.0 * (x / z)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (x <= -2.9e+176) tmp = Float64(Float64(x - y) * Float64(60.0 / Float64(z - t))); elseif (x <= 2.05e+188) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / Float64(z - t)))); elseif (x <= 1.2e+274) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(Float64(x - y) / 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 (x <= -2.9e+176) tmp = (x - y) * (60.0 / (z - t)); elseif (x <= 2.05e+188) tmp = (a * 120.0) + (-60.0 * (y / (z - t))); elseif (x <= 1.2e+274) tmp = (a * 120.0) + (-60.0 * ((x - y) / t)); else tmp = (a * 120.0) + (60.0 * (x / z)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[x, -2.9e+176], N[(N[(x - y), $MachinePrecision] * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 2.05e+188], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(y / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 1.2e+274], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(N[(x - y), $MachinePrecision] / 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}\;x \leq -2.9 \cdot 10^{+176}:\\
\;\;\;\;\left(x - y\right) \cdot \frac{60}{z - t}\\
\mathbf{elif}\;x \leq 2.05 \cdot 10^{+188}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z - t}\\
\mathbf{elif}\;x \leq 1.2 \cdot 10^{+274}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{x - y}{t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + 60 \cdot \frac{x}{z}\\
\end{array}
\end{array}
if x < -2.9000000000000001e176Initial program 99.9%
associate-/l*99.7%
Simplified99.7%
clear-num99.6%
un-div-inv99.8%
Applied egg-rr99.8%
Taylor expanded in a around 0 84.1%
associate-*r/84.3%
associate-*l/84.2%
metadata-eval84.2%
associate-*r/84.1%
*-commutative84.1%
associate-*r/84.2%
metadata-eval84.2%
Simplified84.2%
if -2.9000000000000001e176 < x < 2.05e188Initial program 99.3%
associate-/l*99.8%
Simplified99.8%
clear-num99.8%
un-div-inv99.9%
Applied egg-rr99.9%
Taylor expanded in x around 0 86.8%
if 2.05e188 < x < 1.2e274Initial program 99.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in z around 0 86.8%
if 1.2e274 < x Initial program 99.3%
associate-/l*99.5%
Simplified99.5%
Taylor expanded in x around inf 99.5%
Taylor expanded in z around inf 78.1%
Final simplification86.2%
(FPCore (x y z t a)
:precision binary64
(if (<= a -3.8e-50)
(* a 120.0)
(if (<= a 1.25e-207)
(* -60.0 (/ (- x y) t))
(if (<= a 1.16e-144) (/ 60.0 (/ z (- x y))) (* a 120.0)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -3.8e-50) {
tmp = a * 120.0;
} else if (a <= 1.25e-207) {
tmp = -60.0 * ((x - y) / t);
} else if (a <= 1.16e-144) {
tmp = 60.0 / (z / (x - y));
} 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 <= (-3.8d-50)) then
tmp = a * 120.0d0
else if (a <= 1.25d-207) then
tmp = (-60.0d0) * ((x - y) / t)
else if (a <= 1.16d-144) then
tmp = 60.0d0 / (z / (x - y))
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 <= -3.8e-50) {
tmp = a * 120.0;
} else if (a <= 1.25e-207) {
tmp = -60.0 * ((x - y) / t);
} else if (a <= 1.16e-144) {
tmp = 60.0 / (z / (x - y));
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -3.8e-50: tmp = a * 120.0 elif a <= 1.25e-207: tmp = -60.0 * ((x - y) / t) elif a <= 1.16e-144: tmp = 60.0 / (z / (x - y)) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -3.8e-50) tmp = Float64(a * 120.0); elseif (a <= 1.25e-207) tmp = Float64(-60.0 * Float64(Float64(x - y) / t)); elseif (a <= 1.16e-144) tmp = Float64(60.0 / Float64(z / Float64(x - y))); else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -3.8e-50) tmp = a * 120.0; elseif (a <= 1.25e-207) tmp = -60.0 * ((x - y) / t); elseif (a <= 1.16e-144) tmp = 60.0 / (z / (x - y)); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -3.8e-50], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, 1.25e-207], N[(-60.0 * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.16e-144], N[(60.0 / N[(z / N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -3.8 \cdot 10^{-50}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq 1.25 \cdot 10^{-207}:\\
\;\;\;\;-60 \cdot \frac{x - y}{t}\\
\mathbf{elif}\;a \leq 1.16 \cdot 10^{-144}:\\
\;\;\;\;\frac{60}{\frac{z}{x - y}}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -3.7999999999999999e-50 or 1.15999999999999994e-144 < a Initial program 99.9%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 68.0%
if -3.7999999999999999e-50 < a < 1.25000000000000004e-207Initial program 98.3%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 84.4%
Taylor expanded in z around 0 49.1%
if 1.25000000000000004e-207 < a < 1.15999999999999994e-144Initial program 99.7%
associate-/l*99.5%
Simplified99.5%
Taylor expanded in a around 0 99.5%
clear-num99.6%
un-div-inv99.9%
Applied egg-rr99.9%
Taylor expanded in z around inf 78.4%
Final simplification63.4%
(FPCore (x y z t a)
:precision binary64
(if (<= a -2.9e-55)
(* a 120.0)
(if (<= a 6e-208)
(* -60.0 (/ (- x y) t))
(if (<= a 8e-145) (* 60.0 (/ (- x y) z)) (* a 120.0)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -2.9e-55) {
tmp = a * 120.0;
} else if (a <= 6e-208) {
tmp = -60.0 * ((x - y) / t);
} else if (a <= 8e-145) {
tmp = 60.0 * ((x - y) / z);
} 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 <= (-2.9d-55)) then
tmp = a * 120.0d0
else if (a <= 6d-208) then
tmp = (-60.0d0) * ((x - y) / t)
else if (a <= 8d-145) then
tmp = 60.0d0 * ((x - y) / z)
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 <= -2.9e-55) {
tmp = a * 120.0;
} else if (a <= 6e-208) {
tmp = -60.0 * ((x - y) / t);
} else if (a <= 8e-145) {
tmp = 60.0 * ((x - y) / z);
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -2.9e-55: tmp = a * 120.0 elif a <= 6e-208: tmp = -60.0 * ((x - y) / t) elif a <= 8e-145: tmp = 60.0 * ((x - y) / z) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -2.9e-55) tmp = Float64(a * 120.0); elseif (a <= 6e-208) tmp = Float64(-60.0 * Float64(Float64(x - y) / t)); elseif (a <= 8e-145) tmp = Float64(60.0 * Float64(Float64(x - y) / z)); else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -2.9e-55) tmp = a * 120.0; elseif (a <= 6e-208) tmp = -60.0 * ((x - y) / t); elseif (a <= 8e-145) tmp = 60.0 * ((x - y) / z); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -2.9e-55], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, 6e-208], N[(-60.0 * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 8e-145], N[(60.0 * N[(N[(x - y), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -2.9 \cdot 10^{-55}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq 6 \cdot 10^{-208}:\\
\;\;\;\;-60 \cdot \frac{x - y}{t}\\
\mathbf{elif}\;a \leq 8 \cdot 10^{-145}:\\
\;\;\;\;60 \cdot \frac{x - y}{z}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -2.9e-55 or 7.99999999999999932e-145 < a Initial program 99.9%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 68.0%
if -2.9e-55 < a < 5.99999999999999972e-208Initial program 98.3%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 84.4%
Taylor expanded in z around 0 49.1%
if 5.99999999999999972e-208 < a < 7.99999999999999932e-145Initial program 99.7%
associate-/l*99.5%
Simplified99.5%
Taylor expanded in a around 0 99.5%
Taylor expanded in z around inf 78.1%
Final simplification63.4%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -400000000000.0) (not (<= y 1e+45))) (+ (* a 120.0) (* -60.0 (/ y (- z t)))) (+ (* a 120.0) (/ 60.0 (/ (- z t) x)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -400000000000.0) || !(y <= 1e+45)) {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
} else {
tmp = (a * 120.0) + (60.0 / ((z - t) / 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 ((y <= (-400000000000.0d0)) .or. (.not. (y <= 1d+45))) then
tmp = (a * 120.0d0) + ((-60.0d0) * (y / (z - t)))
else
tmp = (a * 120.0d0) + (60.0d0 / ((z - t) / x))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -400000000000.0) || !(y <= 1e+45)) {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
} else {
tmp = (a * 120.0) + (60.0 / ((z - t) / x));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -400000000000.0) or not (y <= 1e+45): tmp = (a * 120.0) + (-60.0 * (y / (z - t))) else: tmp = (a * 120.0) + (60.0 / ((z - t) / x)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -400000000000.0) || !(y <= 1e+45)) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / Float64(z - t)))); else tmp = Float64(Float64(a * 120.0) + Float64(60.0 / Float64(Float64(z - t) / x))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((y <= -400000000000.0) || ~((y <= 1e+45))) tmp = (a * 120.0) + (-60.0 * (y / (z - t))); else tmp = (a * 120.0) + (60.0 / ((z - t) / x)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -400000000000.0], N[Not[LessEqual[y, 1e+45]], $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[(60.0 / N[(N[(z - t), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -400000000000 \lor \neg \left(y \leq 10^{+45}\right):\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + \frac{60}{\frac{z - t}{x}}\\
\end{array}
\end{array}
if y < -4e11 or 9.9999999999999993e44 < y Initial program 98.9%
associate-/l*99.7%
Simplified99.7%
clear-num99.7%
un-div-inv99.7%
Applied egg-rr99.7%
Taylor expanded in x around 0 90.5%
if -4e11 < y < 9.9999999999999993e44Initial program 99.9%
associate-/l*99.8%
Simplified99.8%
clear-num99.8%
un-div-inv99.9%
Applied egg-rr99.9%
Taylor expanded in x around inf 95.9%
Final simplification93.6%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -420000000000.0) (not (<= y 4e+44))) (+ (* 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 <= -420000000000.0) || !(y <= 4e+44)) {
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 <= (-420000000000.0d0)) .or. (.not. (y <= 4d+44))) 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 <= -420000000000.0) || !(y <= 4e+44)) {
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 <= -420000000000.0) or not (y <= 4e+44): 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 <= -420000000000.0) || !(y <= 4e+44)) 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 <= -420000000000.0) || ~((y <= 4e+44))) 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, -420000000000.0], N[Not[LessEqual[y, 4e+44]], $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 -420000000000 \lor \neg \left(y \leq 4 \cdot 10^{+44}\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 < -4.2e11 or 4.0000000000000004e44 < y Initial program 98.9%
associate-/l*99.7%
Simplified99.7%
clear-num99.7%
un-div-inv99.7%
Applied egg-rr99.7%
Taylor expanded in x around 0 90.5%
if -4.2e11 < y < 4.0000000000000004e44Initial program 99.9%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in x around inf 95.9%
associate-*r/95.9%
*-commutative95.9%
associate-*r/95.9%
Simplified95.9%
Final simplification93.6%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -6000000000000.0) (not (<= y 7.2e+44))) (+ (* a 120.0) (* -60.0 (/ y (- z t)))) (+ (* a 120.0) (* 60.0 (/ x (- z t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -6000000000000.0) || !(y <= 7.2e+44)) {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
} else {
tmp = (a * 120.0) + (60.0 * (x / (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 <= (-6000000000000.0d0)) .or. (.not. (y <= 7.2d+44))) then
tmp = (a * 120.0d0) + ((-60.0d0) * (y / (z - t)))
else
tmp = (a * 120.0d0) + (60.0d0 * (x / (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 <= -6000000000000.0) || !(y <= 7.2e+44)) {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
} else {
tmp = (a * 120.0) + (60.0 * (x / (z - t)));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -6000000000000.0) or not (y <= 7.2e+44): tmp = (a * 120.0) + (-60.0 * (y / (z - t))) else: tmp = (a * 120.0) + (60.0 * (x / (z - t))) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -6000000000000.0) || !(y <= 7.2e+44)) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / Float64(z - t)))); else tmp = Float64(Float64(a * 120.0) + Float64(60.0 * Float64(x / Float64(z - t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((y <= -6000000000000.0) || ~((y <= 7.2e+44))) tmp = (a * 120.0) + (-60.0 * (y / (z - t))); else tmp = (a * 120.0) + (60.0 * (x / (z - t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -6000000000000.0], N[Not[LessEqual[y, 7.2e+44]], $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[(60.0 * N[(x / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -6000000000000 \lor \neg \left(y \leq 7.2 \cdot 10^{+44}\right):\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + 60 \cdot \frac{x}{z - t}\\
\end{array}
\end{array}
if y < -6e12 or 7.2e44 < y Initial program 98.9%
associate-/l*99.7%
Simplified99.7%
clear-num99.7%
un-div-inv99.7%
Applied egg-rr99.7%
Taylor expanded in x around 0 90.5%
if -6e12 < y < 7.2e44Initial program 99.9%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in x around inf 95.9%
Final simplification93.6%
(FPCore (x y z t a)
:precision binary64
(if (<= y -5000000000000.0)
(+ (* a 120.0) (* -60.0 (/ y (- z t))))
(if (<= y 3.6e+44)
(+ (* a 120.0) (/ 60.0 (/ (- z t) x)))
(+ (* a 120.0) (/ (* y -60.0) (- z t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (y <= -5000000000000.0) {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
} else if (y <= 3.6e+44) {
tmp = (a * 120.0) + (60.0 / ((z - t) / x));
} else {
tmp = (a * 120.0) + ((y * -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 <= (-5000000000000.0d0)) then
tmp = (a * 120.0d0) + ((-60.0d0) * (y / (z - t)))
else if (y <= 3.6d+44) then
tmp = (a * 120.0d0) + (60.0d0 / ((z - t) / x))
else
tmp = (a * 120.0d0) + ((y * (-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 <= -5000000000000.0) {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
} else if (y <= 3.6e+44) {
tmp = (a * 120.0) + (60.0 / ((z - t) / x));
} else {
tmp = (a * 120.0) + ((y * -60.0) / (z - t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if y <= -5000000000000.0: tmp = (a * 120.0) + (-60.0 * (y / (z - t))) elif y <= 3.6e+44: tmp = (a * 120.0) + (60.0 / ((z - t) / x)) else: tmp = (a * 120.0) + ((y * -60.0) / (z - t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (y <= -5000000000000.0) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / Float64(z - t)))); elseif (y <= 3.6e+44) tmp = Float64(Float64(a * 120.0) + Float64(60.0 / Float64(Float64(z - t) / x))); else tmp = Float64(Float64(a * 120.0) + Float64(Float64(y * -60.0) / Float64(z - t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (y <= -5000000000000.0) tmp = (a * 120.0) + (-60.0 * (y / (z - t))); elseif (y <= 3.6e+44) tmp = (a * 120.0) + (60.0 / ((z - t) / x)); else tmp = (a * 120.0) + ((y * -60.0) / (z - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[y, -5000000000000.0], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(y / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.6e+44], N[(N[(a * 120.0), $MachinePrecision] + N[(60.0 / N[(N[(z - t), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(y * -60.0), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -5000000000000:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z - t}\\
\mathbf{elif}\;y \leq 3.6 \cdot 10^{+44}:\\
\;\;\;\;a \cdot 120 + \frac{60}{\frac{z - t}{x}}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + \frac{y \cdot -60}{z - t}\\
\end{array}
\end{array}
if y < -5e12Initial program 97.9%
associate-/l*99.8%
Simplified99.8%
clear-num99.8%
un-div-inv99.7%
Applied egg-rr99.7%
Taylor expanded in x around 0 88.0%
if -5e12 < y < 3.6e44Initial program 99.9%
associate-/l*99.8%
Simplified99.8%
clear-num99.8%
un-div-inv99.9%
Applied egg-rr99.9%
Taylor expanded in x around inf 95.9%
if 3.6e44 < y Initial program 99.8%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in x around 0 92.8%
associate-*r/93.0%
Simplified93.0%
Final simplification93.7%
(FPCore (x y z t a)
:precision binary64
(if (<= x -7.5e+177)
(* (- x y) (/ 60.0 (- z t)))
(if (<= x 5e+208)
(+ (* a 120.0) (* -60.0 (/ y (- z t))))
(/ 60.0 (/ (- z t) (- x y))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (x <= -7.5e+177) {
tmp = (x - y) * (60.0 / (z - t));
} else if (x <= 5e+208) {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
} else {
tmp = 60.0 / ((z - t) / (x - 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 (x <= (-7.5d+177)) then
tmp = (x - y) * (60.0d0 / (z - t))
else if (x <= 5d+208) then
tmp = (a * 120.0d0) + ((-60.0d0) * (y / (z - t)))
else
tmp = 60.0d0 / ((z - t) / (x - y))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (x <= -7.5e+177) {
tmp = (x - y) * (60.0 / (z - t));
} else if (x <= 5e+208) {
tmp = (a * 120.0) + (-60.0 * (y / (z - t)));
} else {
tmp = 60.0 / ((z - t) / (x - y));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if x <= -7.5e+177: tmp = (x - y) * (60.0 / (z - t)) elif x <= 5e+208: tmp = (a * 120.0) + (-60.0 * (y / (z - t))) else: tmp = 60.0 / ((z - t) / (x - y)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (x <= -7.5e+177) tmp = Float64(Float64(x - y) * Float64(60.0 / Float64(z - t))); elseif (x <= 5e+208) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / Float64(z - t)))); else tmp = Float64(60.0 / Float64(Float64(z - t) / Float64(x - y))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (x <= -7.5e+177) tmp = (x - y) * (60.0 / (z - t)); elseif (x <= 5e+208) tmp = (a * 120.0) + (-60.0 * (y / (z - t))); else tmp = 60.0 / ((z - t) / (x - y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[x, -7.5e+177], N[(N[(x - y), $MachinePrecision] * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 5e+208], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(y / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(60.0 / N[(N[(z - t), $MachinePrecision] / N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -7.5 \cdot 10^{+177}:\\
\;\;\;\;\left(x - y\right) \cdot \frac{60}{z - t}\\
\mathbf{elif}\;x \leq 5 \cdot 10^{+208}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z - t}\\
\mathbf{else}:\\
\;\;\;\;\frac{60}{\frac{z - t}{x - y}}\\
\end{array}
\end{array}
if x < -7.50000000000000039e177Initial program 99.9%
associate-/l*99.7%
Simplified99.7%
clear-num99.6%
un-div-inv99.8%
Applied egg-rr99.8%
Taylor expanded in a around 0 84.1%
associate-*r/84.3%
associate-*l/84.2%
metadata-eval84.2%
associate-*r/84.1%
*-commutative84.1%
associate-*r/84.2%
metadata-eval84.2%
Simplified84.2%
if -7.50000000000000039e177 < x < 5.0000000000000004e208Initial program 99.4%
associate-/l*99.8%
Simplified99.8%
clear-num99.8%
un-div-inv99.9%
Applied egg-rr99.9%
Taylor expanded in x around 0 86.0%
if 5.0000000000000004e208 < x Initial program 99.6%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 74.4%
clear-num99.7%
un-div-inv99.8%
Applied egg-rr74.6%
Final simplification84.6%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* -60.0 (/ y z))))
(if (<= y -1.4e+227)
t_1
(if (<= y 1.95e+133)
(* a 120.0)
(if (<= y 5.5e+227) (* y (/ 60.0 t)) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = -60.0 * (y / z);
double tmp;
if (y <= -1.4e+227) {
tmp = t_1;
} else if (y <= 1.95e+133) {
tmp = a * 120.0;
} else if (y <= 5.5e+227) {
tmp = y * (60.0 / t);
} 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 = (-60.0d0) * (y / z)
if (y <= (-1.4d+227)) then
tmp = t_1
else if (y <= 1.95d+133) then
tmp = a * 120.0d0
else if (y <= 5.5d+227) then
tmp = y * (60.0d0 / t)
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 = -60.0 * (y / z);
double tmp;
if (y <= -1.4e+227) {
tmp = t_1;
} else if (y <= 1.95e+133) {
tmp = a * 120.0;
} else if (y <= 5.5e+227) {
tmp = y * (60.0 / t);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = -60.0 * (y / z) tmp = 0 if y <= -1.4e+227: tmp = t_1 elif y <= 1.95e+133: tmp = a * 120.0 elif y <= 5.5e+227: tmp = y * (60.0 / t) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(-60.0 * Float64(y / z)) tmp = 0.0 if (y <= -1.4e+227) tmp = t_1; elseif (y <= 1.95e+133) tmp = Float64(a * 120.0); elseif (y <= 5.5e+227) tmp = Float64(y * Float64(60.0 / t)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = -60.0 * (y / z); tmp = 0.0; if (y <= -1.4e+227) tmp = t_1; elseif (y <= 1.95e+133) tmp = a * 120.0; elseif (y <= 5.5e+227) tmp = y * (60.0 / t); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(-60.0 * N[(y / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.4e+227], t$95$1, If[LessEqual[y, 1.95e+133], N[(a * 120.0), $MachinePrecision], If[LessEqual[y, 5.5e+227], N[(y * N[(60.0 / t), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := -60 \cdot \frac{y}{z}\\
\mathbf{if}\;y \leq -1.4 \cdot 10^{+227}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 1.95 \cdot 10^{+133}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;y \leq 5.5 \cdot 10^{+227}:\\
\;\;\;\;y \cdot \frac{60}{t}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -1.39999999999999992e227 or 5.5000000000000001e227 < y Initial program 97.3%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in x around 0 92.1%
associate-*r/89.9%
Simplified89.9%
Taylor expanded in z around inf 70.5%
Taylor expanded in y around inf 54.5%
if -1.39999999999999992e227 < y < 1.95000000000000007e133Initial program 99.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 58.7%
if 1.95000000000000007e133 < y < 5.5000000000000001e227Initial program 99.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 79.0%
Taylor expanded in z around 0 65.0%
Taylor expanded in x around 0 64.8%
associate-*r/64.7%
*-commutative64.7%
associate-*r/64.9%
Simplified64.9%
Final simplification58.4%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* -60.0 (/ y z))))
(if (<= y -3.65e+233)
t_1
(if (<= y 2.6e+133)
(* a 120.0)
(if (<= y 5.5e+218) (* 60.0 (/ y t)) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = -60.0 * (y / z);
double tmp;
if (y <= -3.65e+233) {
tmp = t_1;
} else if (y <= 2.6e+133) {
tmp = a * 120.0;
} else if (y <= 5.5e+218) {
tmp = 60.0 * (y / t);
} 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 = (-60.0d0) * (y / z)
if (y <= (-3.65d+233)) then
tmp = t_1
else if (y <= 2.6d+133) then
tmp = a * 120.0d0
else if (y <= 5.5d+218) then
tmp = 60.0d0 * (y / t)
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 = -60.0 * (y / z);
double tmp;
if (y <= -3.65e+233) {
tmp = t_1;
} else if (y <= 2.6e+133) {
tmp = a * 120.0;
} else if (y <= 5.5e+218) {
tmp = 60.0 * (y / t);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = -60.0 * (y / z) tmp = 0 if y <= -3.65e+233: tmp = t_1 elif y <= 2.6e+133: tmp = a * 120.0 elif y <= 5.5e+218: tmp = 60.0 * (y / t) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(-60.0 * Float64(y / z)) tmp = 0.0 if (y <= -3.65e+233) tmp = t_1; elseif (y <= 2.6e+133) tmp = Float64(a * 120.0); elseif (y <= 5.5e+218) tmp = Float64(60.0 * Float64(y / t)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = -60.0 * (y / z); tmp = 0.0; if (y <= -3.65e+233) tmp = t_1; elseif (y <= 2.6e+133) tmp = a * 120.0; elseif (y <= 5.5e+218) tmp = 60.0 * (y / t); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(-60.0 * N[(y / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -3.65e+233], t$95$1, If[LessEqual[y, 2.6e+133], N[(a * 120.0), $MachinePrecision], If[LessEqual[y, 5.5e+218], N[(60.0 * N[(y / t), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := -60 \cdot \frac{y}{z}\\
\mathbf{if}\;y \leq -3.65 \cdot 10^{+233}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 2.6 \cdot 10^{+133}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;y \leq 5.5 \cdot 10^{+218}:\\
\;\;\;\;60 \cdot \frac{y}{t}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -3.65e233 or 5.5000000000000004e218 < y Initial program 97.3%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in x around 0 92.1%
associate-*r/89.9%
Simplified89.9%
Taylor expanded in z around inf 70.5%
Taylor expanded in y around inf 54.5%
if -3.65e233 < y < 2.5999999999999998e133Initial program 99.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 58.7%
if 2.5999999999999998e133 < y < 5.5000000000000004e218Initial program 99.6%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 79.0%
Taylor expanded in z around 0 65.0%
Taylor expanded in x around 0 64.8%
Final simplification58.4%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -6.2e-52) (not (<= a 1.55e-146))) (* a 120.0) (* -60.0 (/ (- x y) t))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -6.2e-52) || !(a <= 1.55e-146)) {
tmp = a * 120.0;
} else {
tmp = -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 ((a <= (-6.2d-52)) .or. (.not. (a <= 1.55d-146))) then
tmp = a * 120.0d0
else
tmp = (-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 ((a <= -6.2e-52) || !(a <= 1.55e-146)) {
tmp = a * 120.0;
} else {
tmp = -60.0 * ((x - y) / t);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -6.2e-52) or not (a <= 1.55e-146): tmp = a * 120.0 else: tmp = -60.0 * ((x - y) / t) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -6.2e-52) || !(a <= 1.55e-146)) tmp = Float64(a * 120.0); else tmp = 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 ((a <= -6.2e-52) || ~((a <= 1.55e-146))) tmp = a * 120.0; else tmp = -60.0 * ((x - y) / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -6.2e-52], N[Not[LessEqual[a, 1.55e-146]], $MachinePrecision]], N[(a * 120.0), $MachinePrecision], N[(-60.0 * N[(N[(x - y), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -6.2 \cdot 10^{-52} \lor \neg \left(a \leq 1.55 \cdot 10^{-146}\right):\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;-60 \cdot \frac{x - y}{t}\\
\end{array}
\end{array}
if a < -6.1999999999999998e-52 or 1.5499999999999999e-146 < a Initial program 99.9%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 67.7%
if -6.1999999999999998e-52 < a < 1.5499999999999999e-146Initial program 98.5%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in a around 0 86.5%
Taylor expanded in z around 0 45.3%
Final simplification60.7%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -1.15e+232) (not (<= y 9.5e+205))) (* -60.0 (/ y z)) (* a 120.0)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -1.15e+232) || !(y <= 9.5e+205)) {
tmp = -60.0 * (y / z);
} 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 ((y <= (-1.15d+232)) .or. (.not. (y <= 9.5d+205))) then
tmp = (-60.0d0) * (y / z)
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 ((y <= -1.15e+232) || !(y <= 9.5e+205)) {
tmp = -60.0 * (y / z);
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -1.15e+232) or not (y <= 9.5e+205): tmp = -60.0 * (y / z) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -1.15e+232) || !(y <= 9.5e+205)) tmp = Float64(-60.0 * Float64(y / z)); else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((y <= -1.15e+232) || ~((y <= 9.5e+205))) tmp = -60.0 * (y / z); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -1.15e+232], N[Not[LessEqual[y, 9.5e+205]], $MachinePrecision]], N[(-60.0 * N[(y / z), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.15 \cdot 10^{+232} \lor \neg \left(y \leq 9.5 \cdot 10^{+205}\right):\\
\;\;\;\;-60 \cdot \frac{y}{z}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if y < -1.15000000000000003e232 or 9.4999999999999997e205 < y Initial program 97.6%
associate-/l*99.5%
Simplified99.5%
Taylor expanded in x around 0 92.9%
associate-*r/91.0%
Simplified91.0%
Taylor expanded in z around inf 65.1%
Taylor expanded in y around inf 50.9%
if -1.15000000000000003e232 < y < 9.4999999999999997e205Initial program 99.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 57.8%
Final simplification56.6%
(FPCore (x y z t a) :precision binary64 (if (or (<= x -1.65e+184) (not (<= x 1.14e+210))) (* -60.0 (/ x t)) (* a 120.0)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((x <= -1.65e+184) || !(x <= 1.14e+210)) {
tmp = -60.0 * (x / 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 ((x <= (-1.65d+184)) .or. (.not. (x <= 1.14d+210))) then
tmp = (-60.0d0) * (x / 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 ((x <= -1.65e+184) || !(x <= 1.14e+210)) {
tmp = -60.0 * (x / t);
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (x <= -1.65e+184) or not (x <= 1.14e+210): tmp = -60.0 * (x / t) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((x <= -1.65e+184) || !(x <= 1.14e+210)) tmp = Float64(-60.0 * Float64(x / t)); else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((x <= -1.65e+184) || ~((x <= 1.14e+210))) tmp = -60.0 * (x / t); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[x, -1.65e+184], N[Not[LessEqual[x, 1.14e+210]], $MachinePrecision]], N[(-60.0 * N[(x / t), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.65 \cdot 10^{+184} \lor \neg \left(x \leq 1.14 \cdot 10^{+210}\right):\\
\;\;\;\;-60 \cdot \frac{x}{t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if x < -1.6499999999999999e184 or 1.14e210 < x Initial program 99.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 78.3%
Taylor expanded in z around 0 48.2%
Taylor expanded in x around inf 42.8%
if -1.6499999999999999e184 < x < 1.14e210Initial program 99.4%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 58.3%
Final simplification55.3%
(FPCore (x y z t a) :precision binary64 (+ (* a 120.0) (* (- x y) (/ 60.0 (- z t)))))
double code(double x, double y, double z, double t, double a) {
return (a * 120.0) + ((x - y) * (60.0 / (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) + ((x - y) * (60.0d0 / (z - t)))
end function
public static double code(double x, double y, double z, double t, double a) {
return (a * 120.0) + ((x - y) * (60.0 / (z - t)));
}
def code(x, y, z, t, a): return (a * 120.0) + ((x - y) * (60.0 / (z - t)))
function code(x, y, z, t, a) return Float64(Float64(a * 120.0) + Float64(Float64(x - y) * Float64(60.0 / Float64(z - t)))) end
function tmp = code(x, y, z, t, a) tmp = (a * 120.0) + ((x - y) * (60.0 / (z - t))); end
code[x_, y_, z_, t_, a_] := N[(N[(a * 120.0), $MachinePrecision] + N[(N[(x - y), $MachinePrecision] * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
a \cdot 120 + \left(x - y\right) \cdot \frac{60}{z - t}
\end{array}
Initial program 99.4%
*-commutative99.4%
associate-/l*99.8%
Applied egg-rr99.8%
Final simplification99.8%
(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.8%
Simplified99.8%
Final simplification99.8%
(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.8%
Simplified99.8%
Taylor expanded in z around inf 51.3%
Final simplification51.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 2024096
(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)))