
(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 16 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%
Final simplification99.8%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ (* a 120.0) (* -60.0 (/ x t)))))
(if (<= (* a 120.0) -2e-48)
t_1
(if (<= (* a 120.0) 1e-54)
(* 60.0 (/ (- x y) (- z t)))
(if (<= (* a 120.0) 5e-29)
(+ (* a 120.0) (* x (/ -60.0 t)))
(if (<= (* a 120.0) 3e+61) (+ (* a 120.0) (/ (* 60.0 x) z)) t_1))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = (a * 120.0) + (-60.0 * (x / t));
double tmp;
if ((a * 120.0) <= -2e-48) {
tmp = t_1;
} else if ((a * 120.0) <= 1e-54) {
tmp = 60.0 * ((x - y) / (z - t));
} else if ((a * 120.0) <= 5e-29) {
tmp = (a * 120.0) + (x * (-60.0 / t));
} else if ((a * 120.0) <= 3e+61) {
tmp = (a * 120.0) + ((60.0 * x) / z);
} 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 = (a * 120.0d0) + ((-60.0d0) * (x / t))
if ((a * 120.0d0) <= (-2d-48)) then
tmp = t_1
else if ((a * 120.0d0) <= 1d-54) then
tmp = 60.0d0 * ((x - y) / (z - t))
else if ((a * 120.0d0) <= 5d-29) then
tmp = (a * 120.0d0) + (x * ((-60.0d0) / t))
else if ((a * 120.0d0) <= 3d+61) then
tmp = (a * 120.0d0) + ((60.0d0 * x) / z)
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 = (a * 120.0) + (-60.0 * (x / t));
double tmp;
if ((a * 120.0) <= -2e-48) {
tmp = t_1;
} else if ((a * 120.0) <= 1e-54) {
tmp = 60.0 * ((x - y) / (z - t));
} else if ((a * 120.0) <= 5e-29) {
tmp = (a * 120.0) + (x * (-60.0 / t));
} else if ((a * 120.0) <= 3e+61) {
tmp = (a * 120.0) + ((60.0 * x) / z);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = (a * 120.0) + (-60.0 * (x / t)) tmp = 0 if (a * 120.0) <= -2e-48: tmp = t_1 elif (a * 120.0) <= 1e-54: tmp = 60.0 * ((x - y) / (z - t)) elif (a * 120.0) <= 5e-29: tmp = (a * 120.0) + (x * (-60.0 / t)) elif (a * 120.0) <= 3e+61: tmp = (a * 120.0) + ((60.0 * x) / z) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(x / t))) tmp = 0.0 if (Float64(a * 120.0) <= -2e-48) tmp = t_1; elseif (Float64(a * 120.0) <= 1e-54) tmp = Float64(60.0 * Float64(Float64(x - y) / Float64(z - t))); elseif (Float64(a * 120.0) <= 5e-29) tmp = Float64(Float64(a * 120.0) + Float64(x * Float64(-60.0 / t))); elseif (Float64(a * 120.0) <= 3e+61) tmp = Float64(Float64(a * 120.0) + Float64(Float64(60.0 * x) / z)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = (a * 120.0) + (-60.0 * (x / t)); tmp = 0.0; if ((a * 120.0) <= -2e-48) tmp = t_1; elseif ((a * 120.0) <= 1e-54) tmp = 60.0 * ((x - y) / (z - t)); elseif ((a * 120.0) <= 5e-29) tmp = (a * 120.0) + (x * (-60.0 / t)); elseif ((a * 120.0) <= 3e+61) tmp = (a * 120.0) + ((60.0 * x) / z); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(x / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(a * 120.0), $MachinePrecision], -2e-48], t$95$1, If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e-54], N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 5e-29], N[(N[(a * 120.0), $MachinePrecision] + N[(x * N[(-60.0 / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 3e+61], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(60.0 * x), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot 120 + -60 \cdot \frac{x}{t}\\
\mathbf{if}\;a \cdot 120 \leq -2 \cdot 10^{-48}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;a \cdot 120 \leq 10^{-54}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\mathbf{elif}\;a \cdot 120 \leq 5 \cdot 10^{-29}:\\
\;\;\;\;a \cdot 120 + x \cdot \frac{-60}{t}\\
\mathbf{elif}\;a \cdot 120 \leq 3 \cdot 10^{+61}:\\
\;\;\;\;a \cdot 120 + \frac{60 \cdot x}{z}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if (*.f64 a 120) < -1.9999999999999999e-48 or 3e61 < (*.f64 a 120) Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 90.5%
Taylor expanded in z around 0 81.6%
if -1.9999999999999999e-48 < (*.f64 a 120) < 1e-54Initial program 98.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 87.5%
if 1e-54 < (*.f64 a 120) < 4.99999999999999986e-29Initial program 99.7%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 90.9%
Taylor expanded in z around 0 90.9%
associate-*r/90.8%
Applied egg-rr90.8%
associate-/l*90.9%
associate-/r/91.1%
Applied egg-rr91.1%
if 4.99999999999999986e-29 < (*.f64 a 120) < 3e61Initial program 99.9%
associate-/l*100.0%
Simplified100.0%
associate-/l*99.9%
clear-num99.8%
associate-/r/100.0%
Applied egg-rr100.0%
Taylor expanded in x around inf 87.1%
*-commutative87.1%
Simplified87.1%
Taylor expanded in z around inf 73.1%
associate-*r/73.3%
*-commutative73.3%
Simplified73.3%
Final simplification83.8%
(FPCore (x y z t a)
:precision binary64
(if (<= (* a 120.0) -2e-48)
(+ (* a 120.0) (* (/ -1.0 t) (* 60.0 x)))
(if (<= (* a 120.0) 1e-54)
(* 60.0 (/ (- x y) (- z t)))
(if (<= (* a 120.0) 5e-29)
(+ (* a 120.0) (* x (/ -60.0 t)))
(if (<= (* a 120.0) 3e+61)
(+ (* a 120.0) (/ (* 60.0 x) z))
(+ (* a 120.0) (* -60.0 (/ x t))))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -2e-48) {
tmp = (a * 120.0) + ((-1.0 / t) * (60.0 * x));
} else if ((a * 120.0) <= 1e-54) {
tmp = 60.0 * ((x - y) / (z - t));
} else if ((a * 120.0) <= 5e-29) {
tmp = (a * 120.0) + (x * (-60.0 / t));
} else if ((a * 120.0) <= 3e+61) {
tmp = (a * 120.0) + ((60.0 * x) / z);
} else {
tmp = (a * 120.0) + (-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 ((a * 120.0d0) <= (-2d-48)) then
tmp = (a * 120.0d0) + (((-1.0d0) / t) * (60.0d0 * x))
else if ((a * 120.0d0) <= 1d-54) then
tmp = 60.0d0 * ((x - y) / (z - t))
else if ((a * 120.0d0) <= 5d-29) then
tmp = (a * 120.0d0) + (x * ((-60.0d0) / t))
else if ((a * 120.0d0) <= 3d+61) then
tmp = (a * 120.0d0) + ((60.0d0 * x) / z)
else
tmp = (a * 120.0d0) + ((-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 ((a * 120.0) <= -2e-48) {
tmp = (a * 120.0) + ((-1.0 / t) * (60.0 * x));
} else if ((a * 120.0) <= 1e-54) {
tmp = 60.0 * ((x - y) / (z - t));
} else if ((a * 120.0) <= 5e-29) {
tmp = (a * 120.0) + (x * (-60.0 / t));
} else if ((a * 120.0) <= 3e+61) {
tmp = (a * 120.0) + ((60.0 * x) / z);
} else {
tmp = (a * 120.0) + (-60.0 * (x / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a * 120.0) <= -2e-48: tmp = (a * 120.0) + ((-1.0 / t) * (60.0 * x)) elif (a * 120.0) <= 1e-54: tmp = 60.0 * ((x - y) / (z - t)) elif (a * 120.0) <= 5e-29: tmp = (a * 120.0) + (x * (-60.0 / t)) elif (a * 120.0) <= 3e+61: tmp = (a * 120.0) + ((60.0 * x) / z) else: tmp = (a * 120.0) + (-60.0 * (x / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (Float64(a * 120.0) <= -2e-48) tmp = Float64(Float64(a * 120.0) + Float64(Float64(-1.0 / t) * Float64(60.0 * x))); elseif (Float64(a * 120.0) <= 1e-54) tmp = Float64(60.0 * Float64(Float64(x - y) / Float64(z - t))); elseif (Float64(a * 120.0) <= 5e-29) tmp = Float64(Float64(a * 120.0) + Float64(x * Float64(-60.0 / t))); elseif (Float64(a * 120.0) <= 3e+61) tmp = Float64(Float64(a * 120.0) + Float64(Float64(60.0 * x) / z)); else tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(x / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a * 120.0) <= -2e-48) tmp = (a * 120.0) + ((-1.0 / t) * (60.0 * x)); elseif ((a * 120.0) <= 1e-54) tmp = 60.0 * ((x - y) / (z - t)); elseif ((a * 120.0) <= 5e-29) tmp = (a * 120.0) + (x * (-60.0 / t)); elseif ((a * 120.0) <= 3e+61) tmp = (a * 120.0) + ((60.0 * x) / z); else tmp = (a * 120.0) + (-60.0 * (x / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[N[(a * 120.0), $MachinePrecision], -2e-48], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(-1.0 / t), $MachinePrecision] * N[(60.0 * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e-54], N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 5e-29], N[(N[(a * 120.0), $MachinePrecision] + N[(x * N[(-60.0 / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 3e+61], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(60.0 * x), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(x / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -2 \cdot 10^{-48}:\\
\;\;\;\;a \cdot 120 + \frac{-1}{t} \cdot \left(60 \cdot x\right)\\
\mathbf{elif}\;a \cdot 120 \leq 10^{-54}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\mathbf{elif}\;a \cdot 120 \leq 5 \cdot 10^{-29}:\\
\;\;\;\;a \cdot 120 + x \cdot \frac{-60}{t}\\
\mathbf{elif}\;a \cdot 120 \leq 3 \cdot 10^{+61}:\\
\;\;\;\;a \cdot 120 + \frac{60 \cdot x}{z}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{x}{t}\\
\end{array}
\end{array}
if (*.f64 a 120) < -1.9999999999999999e-48Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
associate-/l*99.8%
clear-num99.8%
associate-/r/99.9%
Applied egg-rr99.9%
Taylor expanded in x around inf 87.5%
*-commutative87.5%
Simplified87.5%
Taylor expanded in z around 0 78.4%
if -1.9999999999999999e-48 < (*.f64 a 120) < 1e-54Initial program 98.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 87.5%
if 1e-54 < (*.f64 a 120) < 4.99999999999999986e-29Initial program 99.7%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 90.9%
Taylor expanded in z around 0 90.9%
associate-*r/90.8%
Applied egg-rr90.8%
associate-/l*90.9%
associate-/r/91.1%
Applied egg-rr91.1%
if 4.99999999999999986e-29 < (*.f64 a 120) < 3e61Initial program 99.9%
associate-/l*100.0%
Simplified100.0%
associate-/l*99.9%
clear-num99.8%
associate-/r/100.0%
Applied egg-rr100.0%
Taylor expanded in x around inf 87.1%
*-commutative87.1%
Simplified87.1%
Taylor expanded in z around inf 73.1%
associate-*r/73.3%
*-commutative73.3%
Simplified73.3%
if 3e61 < (*.f64 a 120) Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 94.7%
Taylor expanded in z around 0 86.0%
Final simplification83.8%
(FPCore (x y z t a)
:precision binary64
(if (<= (* a 120.0) -2e-48)
(+ (* a 120.0) (* -60.0 (/ x t)))
(if (<= (* a 120.0) 1e-54)
(* 60.0 (/ (- x y) (- z t)))
(+ (* a 120.0) (* x (/ -60.0 t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -2e-48) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} else if ((a * 120.0) <= 1e-54) {
tmp = 60.0 * ((x - y) / (z - t));
} else {
tmp = (a * 120.0) + (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 ((a * 120.0d0) <= (-2d-48)) then
tmp = (a * 120.0d0) + ((-60.0d0) * (x / t))
else if ((a * 120.0d0) <= 1d-54) then
tmp = 60.0d0 * ((x - y) / (z - t))
else
tmp = (a * 120.0d0) + (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 ((a * 120.0) <= -2e-48) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} else if ((a * 120.0) <= 1e-54) {
tmp = 60.0 * ((x - y) / (z - t));
} else {
tmp = (a * 120.0) + (x * (-60.0 / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a * 120.0) <= -2e-48: tmp = (a * 120.0) + (-60.0 * (x / t)) elif (a * 120.0) <= 1e-54: tmp = 60.0 * ((x - y) / (z - t)) else: tmp = (a * 120.0) + (x * (-60.0 / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (Float64(a * 120.0) <= -2e-48) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(x / t))); elseif (Float64(a * 120.0) <= 1e-54) tmp = Float64(60.0 * Float64(Float64(x - y) / Float64(z - t))); else tmp = Float64(Float64(a * 120.0) + Float64(x * Float64(-60.0 / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a * 120.0) <= -2e-48) tmp = (a * 120.0) + (-60.0 * (x / t)); elseif ((a * 120.0) <= 1e-54) tmp = 60.0 * ((x - y) / (z - t)); else tmp = (a * 120.0) + (x * (-60.0 / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[N[(a * 120.0), $MachinePrecision], -2e-48], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(x / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e-54], N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(x * N[(-60.0 / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -2 \cdot 10^{-48}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{x}{t}\\
\mathbf{elif}\;a \cdot 120 \leq 10^{-54}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + x \cdot \frac{-60}{t}\\
\end{array}
\end{array}
if (*.f64 a 120) < -1.9999999999999999e-48Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 87.5%
Taylor expanded in z around 0 78.4%
if -1.9999999999999999e-48 < (*.f64 a 120) < 1e-54Initial program 98.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 87.5%
if 1e-54 < (*.f64 a 120) Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 92.9%
Taylor expanded in z around 0 79.4%
associate-*r/79.4%
Applied egg-rr79.4%
associate-/l*79.5%
associate-/r/79.4%
Applied egg-rr79.4%
Final simplification82.2%
(FPCore (x y z t a)
:precision binary64
(if (<= (* a 120.0) -2e-49)
(+ (/ -60.0 (/ (- z t) y)) (* a 120.0))
(if (<= (* a 120.0) 1e-54)
(* 60.0 (/ (- x y) (- z t)))
(+ (* a 120.0) (* x (/ -60.0 t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -2e-49) {
tmp = (-60.0 / ((z - t) / y)) + (a * 120.0);
} else if ((a * 120.0) <= 1e-54) {
tmp = 60.0 * ((x - y) / (z - t));
} else {
tmp = (a * 120.0) + (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 ((a * 120.0d0) <= (-2d-49)) then
tmp = ((-60.0d0) / ((z - t) / y)) + (a * 120.0d0)
else if ((a * 120.0d0) <= 1d-54) then
tmp = 60.0d0 * ((x - y) / (z - t))
else
tmp = (a * 120.0d0) + (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 ((a * 120.0) <= -2e-49) {
tmp = (-60.0 / ((z - t) / y)) + (a * 120.0);
} else if ((a * 120.0) <= 1e-54) {
tmp = 60.0 * ((x - y) / (z - t));
} else {
tmp = (a * 120.0) + (x * (-60.0 / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a * 120.0) <= -2e-49: tmp = (-60.0 / ((z - t) / y)) + (a * 120.0) elif (a * 120.0) <= 1e-54: tmp = 60.0 * ((x - y) / (z - t)) else: tmp = (a * 120.0) + (x * (-60.0 / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (Float64(a * 120.0) <= -2e-49) tmp = Float64(Float64(-60.0 / Float64(Float64(z - t) / y)) + Float64(a * 120.0)); elseif (Float64(a * 120.0) <= 1e-54) tmp = Float64(60.0 * Float64(Float64(x - y) / Float64(z - t))); else tmp = Float64(Float64(a * 120.0) + Float64(x * Float64(-60.0 / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a * 120.0) <= -2e-49) tmp = (-60.0 / ((z - t) / y)) + (a * 120.0); elseif ((a * 120.0) <= 1e-54) tmp = 60.0 * ((x - y) / (z - t)); else tmp = (a * 120.0) + (x * (-60.0 / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[N[(a * 120.0), $MachinePrecision], -2e-49], N[(N[(-60.0 / N[(N[(z - t), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision] + N[(a * 120.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e-54], N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(x * N[(-60.0 / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -2 \cdot 10^{-49}:\\
\;\;\;\;\frac{-60}{\frac{z - t}{y}} + a \cdot 120\\
\mathbf{elif}\;a \cdot 120 \leq 10^{-54}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + x \cdot \frac{-60}{t}\\
\end{array}
\end{array}
if (*.f64 a 120) < -1.99999999999999987e-49Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around 0 84.1%
associate-*r/84.1%
associate-/l*84.1%
Simplified84.1%
if -1.99999999999999987e-49 < (*.f64 a 120) < 1e-54Initial program 98.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 88.4%
if 1e-54 < (*.f64 a 120) Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 92.9%
Taylor expanded in z around 0 79.4%
associate-*r/79.4%
Applied egg-rr79.4%
associate-/l*79.5%
associate-/r/79.4%
Applied egg-rr79.4%
Final simplification84.3%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -1.3e+72) (not (<= y 2.15e+46))) (+ (/ -60.0 (/ (- z t) y)) (* a 120.0)) (+ (/ 60.0 (/ (- z t) x)) (* a 120.0))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -1.3e+72) || !(y <= 2.15e+46)) {
tmp = (-60.0 / ((z - t) / y)) + (a * 120.0);
} else {
tmp = (60.0 / ((z - t) / x)) + (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.3d+72)) .or. (.not. (y <= 2.15d+46))) then
tmp = ((-60.0d0) / ((z - t) / y)) + (a * 120.0d0)
else
tmp = (60.0d0 / ((z - t) / x)) + (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.3e+72) || !(y <= 2.15e+46)) {
tmp = (-60.0 / ((z - t) / y)) + (a * 120.0);
} else {
tmp = (60.0 / ((z - t) / x)) + (a * 120.0);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -1.3e+72) or not (y <= 2.15e+46): tmp = (-60.0 / ((z - t) / y)) + (a * 120.0) else: tmp = (60.0 / ((z - t) / x)) + (a * 120.0) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -1.3e+72) || !(y <= 2.15e+46)) tmp = Float64(Float64(-60.0 / Float64(Float64(z - t) / y)) + Float64(a * 120.0)); else tmp = Float64(Float64(60.0 / Float64(Float64(z - t) / x)) + Float64(a * 120.0)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((y <= -1.3e+72) || ~((y <= 2.15e+46))) tmp = (-60.0 / ((z - t) / y)) + (a * 120.0); else tmp = (60.0 / ((z - t) / x)) + (a * 120.0); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -1.3e+72], N[Not[LessEqual[y, 2.15e+46]], $MachinePrecision]], N[(N[(-60.0 / N[(N[(z - t), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision] + N[(a * 120.0), $MachinePrecision]), $MachinePrecision], N[(N[(60.0 / N[(N[(z - t), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision] + N[(a * 120.0), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.3 \cdot 10^{+72} \lor \neg \left(y \leq 2.15 \cdot 10^{+46}\right):\\
\;\;\;\;\frac{-60}{\frac{z - t}{y}} + a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;\frac{60}{\frac{z - t}{x}} + a \cdot 120\\
\end{array}
\end{array}
if y < -1.29999999999999991e72 or 2.15000000000000002e46 < y Initial program 98.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in x around 0 88.9%
associate-*r/87.9%
associate-/l*88.9%
Simplified88.9%
if -1.29999999999999991e72 < y < 2.15000000000000002e46Initial program 99.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in x around inf 96.2%
Final simplification93.2%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -1.3e-50) (not (<= a 2.6e-54))) (+ (* a 120.0) (* -60.0 (/ x t))) (* 60.0 (/ (- x y) (- z t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -1.3e-50) || !(a <= 2.6e-54)) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} 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.3d-50)) .or. (.not. (a <= 2.6d-54))) then
tmp = (a * 120.0d0) + ((-60.0d0) * (x / t))
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.3e-50) || !(a <= 2.6e-54)) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} else {
tmp = 60.0 * ((x - y) / (z - t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -1.3e-50) or not (a <= 2.6e-54): tmp = (a * 120.0) + (-60.0 * (x / t)) else: tmp = 60.0 * ((x - y) / (z - t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -1.3e-50) || !(a <= 2.6e-54)) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(x / t))); 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.3e-50) || ~((a <= 2.6e-54))) tmp = (a * 120.0) + (-60.0 * (x / t)); else tmp = 60.0 * ((x - y) / (z - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -1.3e-50], N[Not[LessEqual[a, 2.6e-54]], $MachinePrecision]], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(x / t), $MachinePrecision]), $MachinePrecision]), $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.3 \cdot 10^{-50} \lor \neg \left(a \leq 2.6 \cdot 10^{-54}\right):\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{x}{t}\\
\mathbf{else}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\end{array}
\end{array}
if a < -1.3000000000000001e-50 or 2.60000000000000002e-54 < a Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 90.2%
Taylor expanded in z around 0 78.9%
if -1.3000000000000001e-50 < a < 2.60000000000000002e-54Initial program 98.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 87.5%
Final simplification82.2%
(FPCore (x y z t a) :precision binary64 (if (<= a -3.5e-20) (* a 120.0) (if (<= a 1.4e-48) (* 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 <= -3.5e-20) {
tmp = a * 120.0;
} else if (a <= 1.4e-48) {
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 <= (-3.5d-20)) then
tmp = a * 120.0d0
else if (a <= 1.4d-48) 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 <= -3.5e-20) {
tmp = a * 120.0;
} else if (a <= 1.4e-48) {
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 <= -3.5e-20: tmp = a * 120.0 elif a <= 1.4e-48: 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 (a <= -3.5e-20) tmp = Float64(a * 120.0); elseif (a <= 1.4e-48) 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 <= -3.5e-20) tmp = a * 120.0; elseif (a <= 1.4e-48) 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[a, -3.5e-20], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, 1.4e-48], 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 \leq -3.5 \cdot 10^{-20}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq 1.4 \cdot 10^{-48}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -3.50000000000000003e-20 or 1.40000000000000002e-48 < a Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 74.5%
if -3.50000000000000003e-20 < a < 1.40000000000000002e-48Initial program 98.8%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 84.6%
Final simplification78.8%
(FPCore (x y z t a)
:precision binary64
(if (<= a -1.35e-52)
(* a 120.0)
(if (<= a -8e-113)
(* 60.0 (/ x z))
(if (<= a 1.42e-67) (* 60.0 (/ y t)) (* a 120.0)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -1.35e-52) {
tmp = a * 120.0;
} else if (a <= -8e-113) {
tmp = 60.0 * (x / z);
} else if (a <= 1.42e-67) {
tmp = 60.0 * (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) :: tmp
if (a <= (-1.35d-52)) then
tmp = a * 120.0d0
else if (a <= (-8d-113)) then
tmp = 60.0d0 * (x / z)
else if (a <= 1.42d-67) then
tmp = 60.0d0 * (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 tmp;
if (a <= -1.35e-52) {
tmp = a * 120.0;
} else if (a <= -8e-113) {
tmp = 60.0 * (x / z);
} else if (a <= 1.42e-67) {
tmp = 60.0 * (y / t);
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -1.35e-52: tmp = a * 120.0 elif a <= -8e-113: tmp = 60.0 * (x / z) elif a <= 1.42e-67: tmp = 60.0 * (y / t) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -1.35e-52) tmp = Float64(a * 120.0); elseif (a <= -8e-113) tmp = Float64(60.0 * Float64(x / z)); elseif (a <= 1.42e-67) tmp = Float64(60.0 * Float64(y / 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 <= -1.35e-52) tmp = a * 120.0; elseif (a <= -8e-113) tmp = 60.0 * (x / z); elseif (a <= 1.42e-67) tmp = 60.0 * (y / t); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -1.35e-52], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, -8e-113], N[(60.0 * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.42e-67], N[(60.0 * N[(y / t), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.35 \cdot 10^{-52}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq -8 \cdot 10^{-113}:\\
\;\;\;\;60 \cdot \frac{x}{z}\\
\mathbf{elif}\;a \leq 1.42 \cdot 10^{-67}:\\
\;\;\;\;60 \cdot \frac{y}{t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -1.35000000000000005e-52 or 1.42000000000000004e-67 < a Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 71.0%
if -1.35000000000000005e-52 < a < -7.99999999999999983e-113Initial program 99.5%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in a around 0 86.6%
Taylor expanded in x around inf 61.8%
Taylor expanded in z around inf 38.0%
if -7.99999999999999983e-113 < a < 1.42000000000000004e-67Initial program 98.4%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in x around 0 63.4%
associate-*r/62.1%
associate-/l*63.3%
Simplified63.3%
Taylor expanded in z around 0 42.8%
Taylor expanded in a around 0 36.3%
Final simplification58.4%
(FPCore (x y z t a)
:precision binary64
(if (<= a -4e-52)
(* a 120.0)
(if (<= a -1.5e-112)
(* 60.0 (/ x z))
(if (<= a 1.42e-67) (/ 60.0 (/ t y)) (* a 120.0)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -4e-52) {
tmp = a * 120.0;
} else if (a <= -1.5e-112) {
tmp = 60.0 * (x / z);
} else if (a <= 1.42e-67) {
tmp = 60.0 / (t / 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 <= (-4d-52)) then
tmp = a * 120.0d0
else if (a <= (-1.5d-112)) then
tmp = 60.0d0 * (x / z)
else if (a <= 1.42d-67) then
tmp = 60.0d0 / (t / 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 <= -4e-52) {
tmp = a * 120.0;
} else if (a <= -1.5e-112) {
tmp = 60.0 * (x / z);
} else if (a <= 1.42e-67) {
tmp = 60.0 / (t / y);
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -4e-52: tmp = a * 120.0 elif a <= -1.5e-112: tmp = 60.0 * (x / z) elif a <= 1.42e-67: tmp = 60.0 / (t / y) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -4e-52) tmp = Float64(a * 120.0); elseif (a <= -1.5e-112) tmp = Float64(60.0 * Float64(x / z)); elseif (a <= 1.42e-67) tmp = Float64(60.0 / Float64(t / 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 <= -4e-52) tmp = a * 120.0; elseif (a <= -1.5e-112) tmp = 60.0 * (x / z); elseif (a <= 1.42e-67) tmp = 60.0 / (t / y); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -4e-52], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, -1.5e-112], N[(60.0 * N[(x / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.42e-67], N[(60.0 / N[(t / y), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -4 \cdot 10^{-52}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq -1.5 \cdot 10^{-112}:\\
\;\;\;\;60 \cdot \frac{x}{z}\\
\mathbf{elif}\;a \leq 1.42 \cdot 10^{-67}:\\
\;\;\;\;\frac{60}{\frac{t}{y}}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -4e-52 or 1.42000000000000004e-67 < a Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 71.0%
if -4e-52 < a < -1.5e-112Initial program 99.5%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in a around 0 86.6%
Taylor expanded in x around inf 61.8%
Taylor expanded in z around inf 38.0%
if -1.5e-112 < a < 1.42000000000000004e-67Initial program 98.4%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in x around 0 63.4%
associate-*r/62.1%
associate-/l*63.3%
Simplified63.3%
Taylor expanded in z around 0 42.8%
Taylor expanded in a around 0 36.3%
associate-*r/36.4%
associate-/l*36.3%
Simplified36.3%
Final simplification58.4%
(FPCore (x y z t a)
:precision binary64
(if (<= a -5.8e-52)
(* a 120.0)
(if (<= a -3.8e-114)
(/ (* 60.0 x) z)
(if (<= a 2.55e-67) (/ 60.0 (/ t y)) (* a 120.0)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -5.8e-52) {
tmp = a * 120.0;
} else if (a <= -3.8e-114) {
tmp = (60.0 * x) / z;
} else if (a <= 2.55e-67) {
tmp = 60.0 / (t / 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 <= (-5.8d-52)) then
tmp = a * 120.0d0
else if (a <= (-3.8d-114)) then
tmp = (60.0d0 * x) / z
else if (a <= 2.55d-67) then
tmp = 60.0d0 / (t / 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 <= -5.8e-52) {
tmp = a * 120.0;
} else if (a <= -3.8e-114) {
tmp = (60.0 * x) / z;
} else if (a <= 2.55e-67) {
tmp = 60.0 / (t / y);
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -5.8e-52: tmp = a * 120.0 elif a <= -3.8e-114: tmp = (60.0 * x) / z elif a <= 2.55e-67: tmp = 60.0 / (t / y) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -5.8e-52) tmp = Float64(a * 120.0); elseif (a <= -3.8e-114) tmp = Float64(Float64(60.0 * x) / z); elseif (a <= 2.55e-67) tmp = Float64(60.0 / Float64(t / 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 <= -5.8e-52) tmp = a * 120.0; elseif (a <= -3.8e-114) tmp = (60.0 * x) / z; elseif (a <= 2.55e-67) tmp = 60.0 / (t / y); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -5.8e-52], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, -3.8e-114], N[(N[(60.0 * x), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[a, 2.55e-67], N[(60.0 / N[(t / y), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -5.8 \cdot 10^{-52}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq -3.8 \cdot 10^{-114}:\\
\;\;\;\;\frac{60 \cdot x}{z}\\
\mathbf{elif}\;a \leq 2.55 \cdot 10^{-67}:\\
\;\;\;\;\frac{60}{\frac{t}{y}}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -5.8000000000000003e-52 or 2.54999999999999991e-67 < a Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 71.0%
if -5.8000000000000003e-52 < a < -3.7999999999999998e-114Initial program 99.5%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in a around 0 86.6%
Taylor expanded in x around inf 61.8%
Taylor expanded in z around inf 38.0%
associate-*r/38.2%
Simplified38.2%
if -3.7999999999999998e-114 < a < 2.54999999999999991e-67Initial program 98.4%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in x around 0 63.4%
associate-*r/62.1%
associate-/l*63.3%
Simplified63.3%
Taylor expanded in z around 0 42.8%
Taylor expanded in a around 0 36.3%
associate-*r/36.4%
associate-/l*36.3%
Simplified36.3%
Final simplification58.4%
(FPCore (x y z t a)
:precision binary64
(if (<= a -8.4e-53)
(* a 120.0)
(if (<= a -2e-112)
(/ (* 60.0 x) z)
(if (<= a 4.7e-67) (/ (* 60.0 y) t) (* a 120.0)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -8.4e-53) {
tmp = a * 120.0;
} else if (a <= -2e-112) {
tmp = (60.0 * x) / z;
} else if (a <= 4.7e-67) {
tmp = (60.0 * 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) :: tmp
if (a <= (-8.4d-53)) then
tmp = a * 120.0d0
else if (a <= (-2d-112)) then
tmp = (60.0d0 * x) / z
else if (a <= 4.7d-67) then
tmp = (60.0d0 * 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 tmp;
if (a <= -8.4e-53) {
tmp = a * 120.0;
} else if (a <= -2e-112) {
tmp = (60.0 * x) / z;
} else if (a <= 4.7e-67) {
tmp = (60.0 * y) / t;
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -8.4e-53: tmp = a * 120.0 elif a <= -2e-112: tmp = (60.0 * x) / z elif a <= 4.7e-67: tmp = (60.0 * y) / t else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -8.4e-53) tmp = Float64(a * 120.0); elseif (a <= -2e-112) tmp = Float64(Float64(60.0 * x) / z); elseif (a <= 4.7e-67) tmp = Float64(Float64(60.0 * y) / 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 <= -8.4e-53) tmp = a * 120.0; elseif (a <= -2e-112) tmp = (60.0 * x) / z; elseif (a <= 4.7e-67) tmp = (60.0 * y) / t; else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -8.4e-53], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, -2e-112], N[(N[(60.0 * x), $MachinePrecision] / z), $MachinePrecision], If[LessEqual[a, 4.7e-67], N[(N[(60.0 * y), $MachinePrecision] / t), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -8.4 \cdot 10^{-53}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq -2 \cdot 10^{-112}:\\
\;\;\;\;\frac{60 \cdot x}{z}\\
\mathbf{elif}\;a \leq 4.7 \cdot 10^{-67}:\\
\;\;\;\;\frac{60 \cdot y}{t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -8.3999999999999991e-53 or 4.70000000000000004e-67 < a Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 71.0%
if -8.3999999999999991e-53 < a < -1.9999999999999999e-112Initial program 99.5%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in a around 0 86.6%
Taylor expanded in x around inf 61.8%
Taylor expanded in z around inf 38.0%
associate-*r/38.2%
Simplified38.2%
if -1.9999999999999999e-112 < a < 4.70000000000000004e-67Initial program 98.4%
associate-/l*99.6%
Simplified99.6%
Taylor expanded in x around 0 63.4%
associate-*r/62.1%
associate-/l*63.3%
Simplified63.3%
Taylor expanded in z around 0 42.8%
Taylor expanded in a around 0 36.3%
associate-*r/36.4%
Simplified36.4%
Final simplification58.4%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -1.4e-52) (not (<= a 4.5e-58))) (* a 120.0) (* 60.0 (/ x (- z t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -1.4e-52) || !(a <= 4.5e-58)) {
tmp = a * 120.0;
} else {
tmp = 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 ((a <= (-1.4d-52)) .or. (.not. (a <= 4.5d-58))) then
tmp = a * 120.0d0
else
tmp = 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 ((a <= -1.4e-52) || !(a <= 4.5e-58)) {
tmp = a * 120.0;
} else {
tmp = 60.0 * (x / (z - t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -1.4e-52) or not (a <= 4.5e-58): tmp = a * 120.0 else: tmp = 60.0 * (x / (z - t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -1.4e-52) || !(a <= 4.5e-58)) tmp = Float64(a * 120.0); else tmp = 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 ((a <= -1.4e-52) || ~((a <= 4.5e-58))) tmp = a * 120.0; else tmp = 60.0 * (x / (z - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -1.4e-52], N[Not[LessEqual[a, 4.5e-58]], $MachinePrecision]], N[(a * 120.0), $MachinePrecision], N[(60.0 * N[(x / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.4 \cdot 10^{-52} \lor \neg \left(a \leq 4.5 \cdot 10^{-58}\right):\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;60 \cdot \frac{x}{z - t}\\
\end{array}
\end{array}
if a < -1.39999999999999997e-52 or 4.5000000000000003e-58 < a Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 71.9%
if -1.39999999999999997e-52 < a < 4.5000000000000003e-58Initial program 98.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 88.2%
Taylor expanded in x around inf 45.0%
Final simplification61.8%
(FPCore (x y z t a) :precision binary64 (if (<= a -1.6e-52) (* a 120.0) (if (<= a 1.85e-57) (/ 60.0 (/ (- z t) x)) (* a 120.0))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (a <= -1.6e-52) {
tmp = a * 120.0;
} else if (a <= 1.85e-57) {
tmp = 60.0 / ((z - t) / x);
} 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 <= (-1.6d-52)) then
tmp = a * 120.0d0
else if (a <= 1.85d-57) then
tmp = 60.0d0 / ((z - t) / x)
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 <= -1.6e-52) {
tmp = a * 120.0;
} else if (a <= 1.85e-57) {
tmp = 60.0 / ((z - t) / x);
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if a <= -1.6e-52: tmp = a * 120.0 elif a <= 1.85e-57: tmp = 60.0 / ((z - t) / x) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if (a <= -1.6e-52) tmp = Float64(a * 120.0); elseif (a <= 1.85e-57) tmp = Float64(60.0 / Float64(Float64(z - t) / x)); else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (a <= -1.6e-52) tmp = a * 120.0; elseif (a <= 1.85e-57) tmp = 60.0 / ((z - t) / x); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[a, -1.6e-52], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, 1.85e-57], N[(60.0 / N[(N[(z - t), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.6 \cdot 10^{-52}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq 1.85 \cdot 10^{-57}:\\
\;\;\;\;\frac{60}{\frac{z - t}{x}}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -1.60000000000000005e-52 or 1.85e-57 < a Initial program 99.8%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 71.9%
if -1.60000000000000005e-52 < a < 1.85e-57Initial program 98.7%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 88.2%
Taylor expanded in x around inf 45.0%
clear-num44.9%
un-div-inv45.0%
Applied egg-rr45.0%
Final simplification61.8%
(FPCore (x y z t a) :precision binary64 (if (or (<= x -3.5e+140) (not (<= x 1.05e+236))) (* -60.0 (/ x t)) (* a 120.0)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((x <= -3.5e+140) || !(x <= 1.05e+236)) {
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 <= (-3.5d+140)) .or. (.not. (x <= 1.05d+236))) 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 <= -3.5e+140) || !(x <= 1.05e+236)) {
tmp = -60.0 * (x / t);
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (x <= -3.5e+140) or not (x <= 1.05e+236): tmp = -60.0 * (x / t) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((x <= -3.5e+140) || !(x <= 1.05e+236)) 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 <= -3.5e+140) || ~((x <= 1.05e+236))) 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, -3.5e+140], N[Not[LessEqual[x, 1.05e+236]], $MachinePrecision]], N[(-60.0 * N[(x / t), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -3.5 \cdot 10^{+140} \lor \neg \left(x \leq 1.05 \cdot 10^{+236}\right):\\
\;\;\;\;-60 \cdot \frac{x}{t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if x < -3.49999999999999989e140 or 1.05000000000000003e236 < x Initial program 99.6%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in a around 0 78.3%
Taylor expanded in x around inf 78.0%
Taylor expanded in z around 0 53.1%
if -3.49999999999999989e140 < x < 1.05000000000000003e236Initial program 99.4%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 56.0%
Final simplification55.4%
(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 49.8%
Final simplification49.8%
(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 2023194
(FPCore (x y z t a)
:name "Data.Colour.RGB:hslsv from colour-2.3.3, B"
:precision binary64
:herbie-target
(+ (/ 60.0 (/ (- z t) (- x y))) (* a 120.0))
(+ (/ (* 60.0 (- x y)) (- z t)) (* a 120.0)))