
(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 18 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 (fma a 120.0 (* 60.0 (/ (- x y) (- z t)))))
double code(double x, double y, double z, double t, double a) {
return fma(a, 120.0, (60.0 * ((x - y) / (z - t))));
}
function code(x, y, z, t, a) return fma(a, 120.0, Float64(60.0 * Float64(Float64(x - y) / Float64(z - t)))) end
code[x_, y_, z_, t_, a_] := N[(a * 120.0 + N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\mathsf{fma}\left(a, 120, 60 \cdot \frac{x - y}{z - t}\right)
\end{array}
Initial program 98.6%
associate-/l*99.7%
Simplified99.7%
+-commutative99.7%
fma-define99.8%
Applied egg-rr99.8%
(FPCore (x y z t a)
:precision binary64
(if (<= (* a 120.0) -4e-73)
(+ (* a 120.0) (/ (* 60.0 x) z))
(if (<= (* a 120.0) 4e-20)
(* (- x y) (/ 60.0 (- z t)))
(if (<= (* a 120.0) 1e+121)
(+ (* a 120.0) (* 60.0 (/ (- y x) t)))
(+ (* a 120.0) (/ (* y -60.0) z))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -4e-73) {
tmp = (a * 120.0) + ((60.0 * x) / z);
} else if ((a * 120.0) <= 4e-20) {
tmp = (x - y) * (60.0 / (z - t));
} else if ((a * 120.0) <= 1e+121) {
tmp = (a * 120.0) + (60.0 * ((y - x) / t));
} else {
tmp = (a * 120.0) + ((y * -60.0) / z);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((a * 120.0d0) <= (-4d-73)) then
tmp = (a * 120.0d0) + ((60.0d0 * x) / z)
else if ((a * 120.0d0) <= 4d-20) then
tmp = (x - y) * (60.0d0 / (z - t))
else if ((a * 120.0d0) <= 1d+121) then
tmp = (a * 120.0d0) + (60.0d0 * ((y - x) / t))
else
tmp = (a * 120.0d0) + ((y * (-60.0d0)) / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -4e-73) {
tmp = (a * 120.0) + ((60.0 * x) / z);
} else if ((a * 120.0) <= 4e-20) {
tmp = (x - y) * (60.0 / (z - t));
} else if ((a * 120.0) <= 1e+121) {
tmp = (a * 120.0) + (60.0 * ((y - x) / t));
} else {
tmp = (a * 120.0) + ((y * -60.0) / z);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a * 120.0) <= -4e-73: tmp = (a * 120.0) + ((60.0 * x) / z) elif (a * 120.0) <= 4e-20: tmp = (x - y) * (60.0 / (z - t)) elif (a * 120.0) <= 1e+121: tmp = (a * 120.0) + (60.0 * ((y - x) / t)) else: tmp = (a * 120.0) + ((y * -60.0) / z) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (Float64(a * 120.0) <= -4e-73) tmp = Float64(Float64(a * 120.0) + Float64(Float64(60.0 * x) / z)); elseif (Float64(a * 120.0) <= 4e-20) tmp = Float64(Float64(x - y) * Float64(60.0 / Float64(z - t))); elseif (Float64(a * 120.0) <= 1e+121) tmp = Float64(Float64(a * 120.0) + Float64(60.0 * Float64(Float64(y - x) / t))); else tmp = Float64(Float64(a * 120.0) + Float64(Float64(y * -60.0) / z)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a * 120.0) <= -4e-73) tmp = (a * 120.0) + ((60.0 * x) / z); elseif ((a * 120.0) <= 4e-20) tmp = (x - y) * (60.0 / (z - t)); elseif ((a * 120.0) <= 1e+121) tmp = (a * 120.0) + (60.0 * ((y - x) / t)); else tmp = (a * 120.0) + ((y * -60.0) / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[N[(a * 120.0), $MachinePrecision], -4e-73], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(60.0 * x), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 4e-20], N[(N[(x - y), $MachinePrecision] * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e+121], N[(N[(a * 120.0), $MachinePrecision] + N[(60.0 * N[(N[(y - x), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(y * -60.0), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -4 \cdot 10^{-73}:\\
\;\;\;\;a \cdot 120 + \frac{60 \cdot x}{z}\\
\mathbf{elif}\;a \cdot 120 \leq 4 \cdot 10^{-20}:\\
\;\;\;\;\left(x - y\right) \cdot \frac{60}{z - t}\\
\mathbf{elif}\;a \cdot 120 \leq 10^{+121}:\\
\;\;\;\;a \cdot 120 + 60 \cdot \frac{y - x}{t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + \frac{y \cdot -60}{z}\\
\end{array}
\end{array}
if (*.f64 a #s(literal 120 binary64)) < -3.99999999999999999e-73Initial program 99.9%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 91.3%
associate-*r/91.3%
Simplified91.3%
Taylor expanded in z around inf 78.1%
if -3.99999999999999999e-73 < (*.f64 a #s(literal 120 binary64)) < 3.99999999999999978e-20Initial program 98.7%
associate-/l*99.5%
Simplified99.5%
+-commutative99.5%
fma-define99.6%
Applied egg-rr99.6%
Taylor expanded in a around 0 81.6%
*-commutative81.6%
associate-*l/80.8%
associate-*r/81.7%
Simplified81.7%
if 3.99999999999999978e-20 < (*.f64 a #s(literal 120 binary64)) < 1.00000000000000004e121Initial program 96.2%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in z around 0 75.2%
associate-*r/75.2%
neg-mul-175.2%
neg-sub075.2%
sub-neg75.2%
+-commutative75.2%
associate--r+75.2%
neg-sub075.2%
remove-double-neg75.2%
Simplified75.2%
if 1.00000000000000004e121 < (*.f64 a #s(literal 120 binary64)) Initial program 98.0%
Taylor expanded in x around 0 92.8%
Taylor expanded in z around inf 87.8%
Final simplification81.2%
(FPCore (x y z t a)
:precision binary64
(if (<= (* a 120.0) -4e-73)
(+ (* a 120.0) (/ (* 60.0 x) z))
(if (<= (* a 120.0) 2e+57)
(/ (- x y) (* (- z t) 0.016666666666666666))
(if (<= (* a 120.0) 1e+142)
(+ (* a 120.0) (* y (/ 60.0 t)))
(+ (* a 120.0) (/ (* y -60.0) z))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -4e-73) {
tmp = (a * 120.0) + ((60.0 * x) / z);
} else if ((a * 120.0) <= 2e+57) {
tmp = (x - y) / ((z - t) * 0.016666666666666666);
} else if ((a * 120.0) <= 1e+142) {
tmp = (a * 120.0) + (y * (60.0 / t));
} else {
tmp = (a * 120.0) + ((y * -60.0) / z);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((a * 120.0d0) <= (-4d-73)) then
tmp = (a * 120.0d0) + ((60.0d0 * x) / z)
else if ((a * 120.0d0) <= 2d+57) then
tmp = (x - y) / ((z - t) * 0.016666666666666666d0)
else if ((a * 120.0d0) <= 1d+142) then
tmp = (a * 120.0d0) + (y * (60.0d0 / t))
else
tmp = (a * 120.0d0) + ((y * (-60.0d0)) / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -4e-73) {
tmp = (a * 120.0) + ((60.0 * x) / z);
} else if ((a * 120.0) <= 2e+57) {
tmp = (x - y) / ((z - t) * 0.016666666666666666);
} else if ((a * 120.0) <= 1e+142) {
tmp = (a * 120.0) + (y * (60.0 / t));
} else {
tmp = (a * 120.0) + ((y * -60.0) / z);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a * 120.0) <= -4e-73: tmp = (a * 120.0) + ((60.0 * x) / z) elif (a * 120.0) <= 2e+57: tmp = (x - y) / ((z - t) * 0.016666666666666666) elif (a * 120.0) <= 1e+142: tmp = (a * 120.0) + (y * (60.0 / t)) else: tmp = (a * 120.0) + ((y * -60.0) / z) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (Float64(a * 120.0) <= -4e-73) tmp = Float64(Float64(a * 120.0) + Float64(Float64(60.0 * x) / z)); elseif (Float64(a * 120.0) <= 2e+57) tmp = Float64(Float64(x - y) / Float64(Float64(z - t) * 0.016666666666666666)); elseif (Float64(a * 120.0) <= 1e+142) tmp = Float64(Float64(a * 120.0) + Float64(y * Float64(60.0 / t))); else tmp = Float64(Float64(a * 120.0) + Float64(Float64(y * -60.0) / z)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a * 120.0) <= -4e-73) tmp = (a * 120.0) + ((60.0 * x) / z); elseif ((a * 120.0) <= 2e+57) tmp = (x - y) / ((z - t) * 0.016666666666666666); elseif ((a * 120.0) <= 1e+142) tmp = (a * 120.0) + (y * (60.0 / t)); else tmp = (a * 120.0) + ((y * -60.0) / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[N[(a * 120.0), $MachinePrecision], -4e-73], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(60.0 * x), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 2e+57], N[(N[(x - y), $MachinePrecision] / N[(N[(z - t), $MachinePrecision] * 0.016666666666666666), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e+142], N[(N[(a * 120.0), $MachinePrecision] + N[(y * N[(60.0 / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(y * -60.0), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -4 \cdot 10^{-73}:\\
\;\;\;\;a \cdot 120 + \frac{60 \cdot x}{z}\\
\mathbf{elif}\;a \cdot 120 \leq 2 \cdot 10^{+57}:\\
\;\;\;\;\frac{x - y}{\left(z - t\right) \cdot 0.016666666666666666}\\
\mathbf{elif}\;a \cdot 120 \leq 10^{+142}:\\
\;\;\;\;a \cdot 120 + y \cdot \frac{60}{t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + \frac{y \cdot -60}{z}\\
\end{array}
\end{array}
if (*.f64 a #s(literal 120 binary64)) < -3.99999999999999999e-73Initial program 99.9%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 91.3%
associate-*r/91.3%
Simplified91.3%
Taylor expanded in z around inf 78.1%
if -3.99999999999999999e-73 < (*.f64 a #s(literal 120 binary64)) < 2.0000000000000001e57Initial program 98.0%
associate-/l*99.6%
Simplified99.6%
+-commutative99.6%
fma-define99.6%
Applied egg-rr99.6%
Taylor expanded in a around 0 79.7%
*-commutative79.7%
associate-*l/79.0%
associate-*r/79.7%
Simplified79.7%
clear-num79.7%
un-div-inv79.7%
div-inv79.8%
metadata-eval79.8%
Applied egg-rr79.8%
if 2.0000000000000001e57 < (*.f64 a #s(literal 120 binary64)) < 1.00000000000000005e142Initial program 95.4%
Taylor expanded in x around 0 95.4%
Taylor expanded in z around 0 83.1%
associate-*r/78.9%
Simplified78.9%
Taylor expanded in y around 0 83.1%
associate-*r/78.9%
*-commutative78.9%
associate-*r/83.3%
Simplified83.3%
if 1.00000000000000005e142 < (*.f64 a #s(literal 120 binary64)) Initial program 99.9%
Taylor expanded in x around 0 93.8%
Taylor expanded in z around inf 88.1%
Final simplification81.0%
(FPCore (x y z t a)
:precision binary64
(if (<= (* a 120.0) -4e-73)
(+ (* a 120.0) (/ (* 60.0 x) z))
(if (<= (* a 120.0) 2e+57)
(* (- x y) (/ 60.0 (- z t)))
(if (<= (* a 120.0) 1e+142)
(+ (* a 120.0) (* y (/ 60.0 t)))
(+ (* a 120.0) (/ (* y -60.0) z))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -4e-73) {
tmp = (a * 120.0) + ((60.0 * x) / z);
} else if ((a * 120.0) <= 2e+57) {
tmp = (x - y) * (60.0 / (z - t));
} else if ((a * 120.0) <= 1e+142) {
tmp = (a * 120.0) + (y * (60.0 / t));
} else {
tmp = (a * 120.0) + ((y * -60.0) / z);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((a * 120.0d0) <= (-4d-73)) then
tmp = (a * 120.0d0) + ((60.0d0 * x) / z)
else if ((a * 120.0d0) <= 2d+57) then
tmp = (x - y) * (60.0d0 / (z - t))
else if ((a * 120.0d0) <= 1d+142) then
tmp = (a * 120.0d0) + (y * (60.0d0 / t))
else
tmp = (a * 120.0d0) + ((y * (-60.0d0)) / z)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -4e-73) {
tmp = (a * 120.0) + ((60.0 * x) / z);
} else if ((a * 120.0) <= 2e+57) {
tmp = (x - y) * (60.0 / (z - t));
} else if ((a * 120.0) <= 1e+142) {
tmp = (a * 120.0) + (y * (60.0 / t));
} else {
tmp = (a * 120.0) + ((y * -60.0) / z);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a * 120.0) <= -4e-73: tmp = (a * 120.0) + ((60.0 * x) / z) elif (a * 120.0) <= 2e+57: tmp = (x - y) * (60.0 / (z - t)) elif (a * 120.0) <= 1e+142: tmp = (a * 120.0) + (y * (60.0 / t)) else: tmp = (a * 120.0) + ((y * -60.0) / z) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (Float64(a * 120.0) <= -4e-73) tmp = Float64(Float64(a * 120.0) + Float64(Float64(60.0 * x) / z)); elseif (Float64(a * 120.0) <= 2e+57) tmp = Float64(Float64(x - y) * Float64(60.0 / Float64(z - t))); elseif (Float64(a * 120.0) <= 1e+142) tmp = Float64(Float64(a * 120.0) + Float64(y * Float64(60.0 / t))); else tmp = Float64(Float64(a * 120.0) + Float64(Float64(y * -60.0) / z)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a * 120.0) <= -4e-73) tmp = (a * 120.0) + ((60.0 * x) / z); elseif ((a * 120.0) <= 2e+57) tmp = (x - y) * (60.0 / (z - t)); elseif ((a * 120.0) <= 1e+142) tmp = (a * 120.0) + (y * (60.0 / t)); else tmp = (a * 120.0) + ((y * -60.0) / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[N[(a * 120.0), $MachinePrecision], -4e-73], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(60.0 * x), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 2e+57], N[(N[(x - y), $MachinePrecision] * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e+142], N[(N[(a * 120.0), $MachinePrecision] + N[(y * N[(60.0 / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(y * -60.0), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -4 \cdot 10^{-73}:\\
\;\;\;\;a \cdot 120 + \frac{60 \cdot x}{z}\\
\mathbf{elif}\;a \cdot 120 \leq 2 \cdot 10^{+57}:\\
\;\;\;\;\left(x - y\right) \cdot \frac{60}{z - t}\\
\mathbf{elif}\;a \cdot 120 \leq 10^{+142}:\\
\;\;\;\;a \cdot 120 + y \cdot \frac{60}{t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + \frac{y \cdot -60}{z}\\
\end{array}
\end{array}
if (*.f64 a #s(literal 120 binary64)) < -3.99999999999999999e-73Initial program 99.9%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 91.3%
associate-*r/91.3%
Simplified91.3%
Taylor expanded in z around inf 78.1%
if -3.99999999999999999e-73 < (*.f64 a #s(literal 120 binary64)) < 2.0000000000000001e57Initial program 98.0%
associate-/l*99.6%
Simplified99.6%
+-commutative99.6%
fma-define99.6%
Applied egg-rr99.6%
Taylor expanded in a around 0 79.7%
*-commutative79.7%
associate-*l/79.0%
associate-*r/79.7%
Simplified79.7%
if 2.0000000000000001e57 < (*.f64 a #s(literal 120 binary64)) < 1.00000000000000005e142Initial program 95.4%
Taylor expanded in x around 0 95.4%
Taylor expanded in z around 0 83.1%
associate-*r/78.9%
Simplified78.9%
Taylor expanded in y around 0 83.1%
associate-*r/78.9%
*-commutative78.9%
associate-*r/83.3%
Simplified83.3%
if 1.00000000000000005e142 < (*.f64 a #s(literal 120 binary64)) Initial program 99.9%
Taylor expanded in x around 0 93.8%
Taylor expanded in z around inf 88.1%
Final simplification81.0%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (+ (* a 120.0) (/ (* y -60.0) z))))
(if (<= (* a 120.0) -5e-84)
t_1
(if (<= (* a 120.0) 2e+57)
(* (- x y) (/ 60.0 (- z t)))
(if (<= (* a 120.0) 1e+142) (+ (* a 120.0) (* y (/ 60.0 t))) t_1)))))
double code(double x, double y, double z, double t, double a) {
double t_1 = (a * 120.0) + ((y * -60.0) / z);
double tmp;
if ((a * 120.0) <= -5e-84) {
tmp = t_1;
} else if ((a * 120.0) <= 2e+57) {
tmp = (x - y) * (60.0 / (z - t));
} else if ((a * 120.0) <= 1e+142) {
tmp = (a * 120.0) + (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 = (a * 120.0d0) + ((y * (-60.0d0)) / z)
if ((a * 120.0d0) <= (-5d-84)) then
tmp = t_1
else if ((a * 120.0d0) <= 2d+57) then
tmp = (x - y) * (60.0d0 / (z - t))
else if ((a * 120.0d0) <= 1d+142) then
tmp = (a * 120.0d0) + (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 = (a * 120.0) + ((y * -60.0) / z);
double tmp;
if ((a * 120.0) <= -5e-84) {
tmp = t_1;
} else if ((a * 120.0) <= 2e+57) {
tmp = (x - y) * (60.0 / (z - t));
} else if ((a * 120.0) <= 1e+142) {
tmp = (a * 120.0) + (y * (60.0 / t));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = (a * 120.0) + ((y * -60.0) / z) tmp = 0 if (a * 120.0) <= -5e-84: tmp = t_1 elif (a * 120.0) <= 2e+57: tmp = (x - y) * (60.0 / (z - t)) elif (a * 120.0) <= 1e+142: tmp = (a * 120.0) + (y * (60.0 / t)) else: tmp = t_1 return tmp
function code(x, y, z, t, a) t_1 = Float64(Float64(a * 120.0) + Float64(Float64(y * -60.0) / z)) tmp = 0.0 if (Float64(a * 120.0) <= -5e-84) tmp = t_1; elseif (Float64(a * 120.0) <= 2e+57) tmp = Float64(Float64(x - y) * Float64(60.0 / Float64(z - t))); elseif (Float64(a * 120.0) <= 1e+142) tmp = Float64(Float64(a * 120.0) + 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 = (a * 120.0) + ((y * -60.0) / z); tmp = 0.0; if ((a * 120.0) <= -5e-84) tmp = t_1; elseif ((a * 120.0) <= 2e+57) tmp = (x - y) * (60.0 / (z - t)); elseif ((a * 120.0) <= 1e+142) tmp = (a * 120.0) + (y * (60.0 / t)); 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[(N[(y * -60.0), $MachinePrecision] / z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(a * 120.0), $MachinePrecision], -5e-84], t$95$1, If[LessEqual[N[(a * 120.0), $MachinePrecision], 2e+57], N[(N[(x - y), $MachinePrecision] * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 1e+142], N[(N[(a * 120.0), $MachinePrecision] + N[(y * N[(60.0 / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := a \cdot 120 + \frac{y \cdot -60}{z}\\
\mathbf{if}\;a \cdot 120 \leq -5 \cdot 10^{-84}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \cdot 120 \leq 2 \cdot 10^{+57}:\\
\;\;\;\;\left(x - y\right) \cdot \frac{60}{z - t}\\
\mathbf{elif}\;a \cdot 120 \leq 10^{+142}:\\
\;\;\;\;a \cdot 120 + y \cdot \frac{60}{t}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if (*.f64 a #s(literal 120 binary64)) < -5.0000000000000002e-84 or 1.00000000000000005e142 < (*.f64 a #s(literal 120 binary64)) Initial program 99.9%
Taylor expanded in x around 0 87.7%
Taylor expanded in z around inf 81.1%
if -5.0000000000000002e-84 < (*.f64 a #s(literal 120 binary64)) < 2.0000000000000001e57Initial program 98.0%
associate-/l*99.6%
Simplified99.6%
+-commutative99.6%
fma-define99.6%
Applied egg-rr99.6%
Taylor expanded in a around 0 79.5%
*-commutative79.5%
associate-*l/78.8%
associate-*r/79.6%
Simplified79.6%
if 2.0000000000000001e57 < (*.f64 a #s(literal 120 binary64)) < 1.00000000000000005e142Initial program 95.4%
Taylor expanded in x around 0 95.4%
Taylor expanded in z around 0 83.1%
associate-*r/78.9%
Simplified78.9%
Taylor expanded in y around 0 83.1%
associate-*r/78.9%
*-commutative78.9%
associate-*r/83.3%
Simplified83.3%
Final simplification80.6%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* 60.0 (/ x (- z t)))))
(if (<= a -2.9e-111)
(* a 120.0)
(if (<= a -5e-226)
t_1
(if (<= a 6.4e-113)
(/ (* y -60.0) (- z t))
(if (<= a 1.12e+55) t_1 (* a 120.0)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = 60.0 * (x / (z - t));
double tmp;
if (a <= -2.9e-111) {
tmp = a * 120.0;
} else if (a <= -5e-226) {
tmp = t_1;
} else if (a <= 6.4e-113) {
tmp = (y * -60.0) / (z - t);
} else if (a <= 1.12e+55) {
tmp = t_1;
} else {
tmp = a * 120.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = 60.0d0 * (x / (z - t))
if (a <= (-2.9d-111)) then
tmp = a * 120.0d0
else if (a <= (-5d-226)) then
tmp = t_1
else if (a <= 6.4d-113) then
tmp = (y * (-60.0d0)) / (z - t)
else if (a <= 1.12d+55) then
tmp = t_1
else
tmp = a * 120.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = 60.0 * (x / (z - t));
double tmp;
if (a <= -2.9e-111) {
tmp = a * 120.0;
} else if (a <= -5e-226) {
tmp = t_1;
} else if (a <= 6.4e-113) {
tmp = (y * -60.0) / (z - t);
} else if (a <= 1.12e+55) {
tmp = t_1;
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = 60.0 * (x / (z - t)) tmp = 0 if a <= -2.9e-111: tmp = a * 120.0 elif a <= -5e-226: tmp = t_1 elif a <= 6.4e-113: tmp = (y * -60.0) / (z - t) elif a <= 1.12e+55: tmp = t_1 else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) t_1 = Float64(60.0 * Float64(x / Float64(z - t))) tmp = 0.0 if (a <= -2.9e-111) tmp = Float64(a * 120.0); elseif (a <= -5e-226) tmp = t_1; elseif (a <= 6.4e-113) tmp = Float64(Float64(y * -60.0) / Float64(z - t)); elseif (a <= 1.12e+55) tmp = t_1; else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = 60.0 * (x / (z - t)); tmp = 0.0; if (a <= -2.9e-111) tmp = a * 120.0; elseif (a <= -5e-226) tmp = t_1; elseif (a <= 6.4e-113) tmp = (y * -60.0) / (z - t); elseif (a <= 1.12e+55) tmp = t_1; else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(60.0 * N[(x / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -2.9e-111], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, -5e-226], t$95$1, If[LessEqual[a, 6.4e-113], N[(N[(y * -60.0), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.12e+55], t$95$1, N[(a * 120.0), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := 60 \cdot \frac{x}{z - t}\\
\mathbf{if}\;a \leq -2.9 \cdot 10^{-111}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq -5 \cdot 10^{-226}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 6.4 \cdot 10^{-113}:\\
\;\;\;\;\frac{y \cdot -60}{z - t}\\
\mathbf{elif}\;a \leq 1.12 \cdot 10^{+55}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -2.90000000000000002e-111 or 1.12000000000000006e55 < a Initial program 99.2%
associate-/l*99.8%
fma-define99.9%
Simplified99.9%
Taylor expanded in z around inf 75.2%
if -2.90000000000000002e-111 < a < -4.9999999999999998e-226 or 6.4000000000000003e-113 < a < 1.12000000000000006e55Initial program 96.4%
associate-/l*99.8%
Simplified99.8%
+-commutative99.8%
fma-define99.8%
Applied egg-rr99.8%
Taylor expanded in x around inf 58.3%
if -4.9999999999999998e-226 < a < 6.4000000000000003e-113Initial program 99.5%
associate-/l*99.4%
Simplified99.4%
+-commutative99.4%
fma-define99.4%
Applied egg-rr99.4%
Taylor expanded in a around inf 70.7%
associate-*r/70.7%
*-commutative70.7%
Simplified70.7%
Taylor expanded in y around inf 51.0%
associate-*r/51.0%
Simplified51.0%
Final simplification65.7%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* 60.0 (/ x (- z t)))))
(if (<= a -4.4e-97)
(* a 120.0)
(if (<= a -3.15e-235)
t_1
(if (<= a 1.7e-113)
(* y (/ -60.0 (- z t)))
(if (<= a 1.12e+55) t_1 (* a 120.0)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = 60.0 * (x / (z - t));
double tmp;
if (a <= -4.4e-97) {
tmp = a * 120.0;
} else if (a <= -3.15e-235) {
tmp = t_1;
} else if (a <= 1.7e-113) {
tmp = y * (-60.0 / (z - t));
} else if (a <= 1.12e+55) {
tmp = t_1;
} else {
tmp = a * 120.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = 60.0d0 * (x / (z - t))
if (a <= (-4.4d-97)) then
tmp = a * 120.0d0
else if (a <= (-3.15d-235)) then
tmp = t_1
else if (a <= 1.7d-113) then
tmp = y * ((-60.0d0) / (z - t))
else if (a <= 1.12d+55) then
tmp = t_1
else
tmp = a * 120.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = 60.0 * (x / (z - t));
double tmp;
if (a <= -4.4e-97) {
tmp = a * 120.0;
} else if (a <= -3.15e-235) {
tmp = t_1;
} else if (a <= 1.7e-113) {
tmp = y * (-60.0 / (z - t));
} else if (a <= 1.12e+55) {
tmp = t_1;
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = 60.0 * (x / (z - t)) tmp = 0 if a <= -4.4e-97: tmp = a * 120.0 elif a <= -3.15e-235: tmp = t_1 elif a <= 1.7e-113: tmp = y * (-60.0 / (z - t)) elif a <= 1.12e+55: tmp = t_1 else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) t_1 = Float64(60.0 * Float64(x / Float64(z - t))) tmp = 0.0 if (a <= -4.4e-97) tmp = Float64(a * 120.0); elseif (a <= -3.15e-235) tmp = t_1; elseif (a <= 1.7e-113) tmp = Float64(y * Float64(-60.0 / Float64(z - t))); elseif (a <= 1.12e+55) tmp = t_1; else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = 60.0 * (x / (z - t)); tmp = 0.0; if (a <= -4.4e-97) tmp = a * 120.0; elseif (a <= -3.15e-235) tmp = t_1; elseif (a <= 1.7e-113) tmp = y * (-60.0 / (z - t)); elseif (a <= 1.12e+55) tmp = t_1; else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(60.0 * N[(x / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -4.4e-97], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, -3.15e-235], t$95$1, If[LessEqual[a, 1.7e-113], N[(y * N[(-60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.12e+55], t$95$1, N[(a * 120.0), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := 60 \cdot \frac{x}{z - t}\\
\mathbf{if}\;a \leq -4.4 \cdot 10^{-97}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq -3.15 \cdot 10^{-235}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 1.7 \cdot 10^{-113}:\\
\;\;\;\;y \cdot \frac{-60}{z - t}\\
\mathbf{elif}\;a \leq 1.12 \cdot 10^{+55}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -4.3999999999999998e-97 or 1.12000000000000006e55 < a Initial program 99.2%
associate-/l*99.8%
fma-define99.9%
Simplified99.9%
Taylor expanded in z around inf 75.2%
if -4.3999999999999998e-97 < a < -3.1499999999999997e-235 or 1.7000000000000001e-113 < a < 1.12000000000000006e55Initial program 96.5%
associate-/l*99.7%
Simplified99.7%
+-commutative99.7%
fma-define99.7%
Applied egg-rr99.7%
Taylor expanded in x around inf 58.1%
if -3.1499999999999997e-235 < a < 1.7000000000000001e-113Initial program 99.5%
associate-/l*99.4%
Simplified99.4%
+-commutative99.4%
fma-define99.5%
Applied egg-rr99.5%
Taylor expanded in y around inf 51.0%
*-commutative51.0%
associate-*l/51.0%
associate-*r/51.0%
Simplified51.0%
Final simplification65.7%
(FPCore (x y z t a)
:precision binary64
(let* ((t_1 (* 60.0 (/ x (- z t)))))
(if (<= a -3e-96)
(* a 120.0)
(if (<= a -5.8e-234)
t_1
(if (<= a 7.5e-112)
(* -60.0 (/ y (- z t)))
(if (<= a 1.12e+55) t_1 (* a 120.0)))))))
double code(double x, double y, double z, double t, double a) {
double t_1 = 60.0 * (x / (z - t));
double tmp;
if (a <= -3e-96) {
tmp = a * 120.0;
} else if (a <= -5.8e-234) {
tmp = t_1;
} else if (a <= 7.5e-112) {
tmp = -60.0 * (y / (z - t));
} else if (a <= 1.12e+55) {
tmp = t_1;
} else {
tmp = a * 120.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: t_1
real(8) :: tmp
t_1 = 60.0d0 * (x / (z - t))
if (a <= (-3d-96)) then
tmp = a * 120.0d0
else if (a <= (-5.8d-234)) then
tmp = t_1
else if (a <= 7.5d-112) then
tmp = (-60.0d0) * (y / (z - t))
else if (a <= 1.12d+55) then
tmp = t_1
else
tmp = a * 120.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double t_1 = 60.0 * (x / (z - t));
double tmp;
if (a <= -3e-96) {
tmp = a * 120.0;
} else if (a <= -5.8e-234) {
tmp = t_1;
} else if (a <= 7.5e-112) {
tmp = -60.0 * (y / (z - t));
} else if (a <= 1.12e+55) {
tmp = t_1;
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): t_1 = 60.0 * (x / (z - t)) tmp = 0 if a <= -3e-96: tmp = a * 120.0 elif a <= -5.8e-234: tmp = t_1 elif a <= 7.5e-112: tmp = -60.0 * (y / (z - t)) elif a <= 1.12e+55: tmp = t_1 else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) t_1 = Float64(60.0 * Float64(x / Float64(z - t))) tmp = 0.0 if (a <= -3e-96) tmp = Float64(a * 120.0); elseif (a <= -5.8e-234) tmp = t_1; elseif (a <= 7.5e-112) tmp = Float64(-60.0 * Float64(y / Float64(z - t))); elseif (a <= 1.12e+55) tmp = t_1; else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) t_1 = 60.0 * (x / (z - t)); tmp = 0.0; if (a <= -3e-96) tmp = a * 120.0; elseif (a <= -5.8e-234) tmp = t_1; elseif (a <= 7.5e-112) tmp = -60.0 * (y / (z - t)); elseif (a <= 1.12e+55) tmp = t_1; else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := Block[{t$95$1 = N[(60.0 * N[(x / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -3e-96], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, -5.8e-234], t$95$1, If[LessEqual[a, 7.5e-112], N[(-60.0 * N[(y / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.12e+55], t$95$1, N[(a * 120.0), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := 60 \cdot \frac{x}{z - t}\\
\mathbf{if}\;a \leq -3 \cdot 10^{-96}:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq -5.8 \cdot 10^{-234}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 7.5 \cdot 10^{-112}:\\
\;\;\;\;-60 \cdot \frac{y}{z - t}\\
\mathbf{elif}\;a \leq 1.12 \cdot 10^{+55}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -3e-96 or 1.12000000000000006e55 < a Initial program 99.2%
associate-/l*99.8%
fma-define99.9%
Simplified99.9%
Taylor expanded in z around inf 75.2%
if -3e-96 < a < -5.80000000000000031e-234 or 7.5000000000000002e-112 < a < 1.12000000000000006e55Initial program 96.5%
associate-/l*99.7%
Simplified99.7%
+-commutative99.7%
fma-define99.7%
Applied egg-rr99.7%
Taylor expanded in x around inf 58.1%
if -5.80000000000000031e-234 < a < 7.5000000000000002e-112Initial program 99.5%
associate-/l*99.4%
Simplified99.4%
+-commutative99.4%
fma-define99.5%
Applied egg-rr99.5%
Taylor expanded in y around inf 51.0%
Final simplification65.7%
(FPCore (x y z t a) :precision binary64 (if (or (<= (* a 120.0) -4e-73) (not (<= (* a 120.0) 2e+57))) (+ (* a 120.0) (/ (* y -60.0) (- z t))) (/ (- x y) (* (- z t) 0.016666666666666666))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (((a * 120.0) <= -4e-73) || !((a * 120.0) <= 2e+57)) {
tmp = (a * 120.0) + ((y * -60.0) / (z - t));
} else {
tmp = (x - y) / ((z - t) * 0.016666666666666666);
}
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) <= (-4d-73)) .or. (.not. ((a * 120.0d0) <= 2d+57))) then
tmp = (a * 120.0d0) + ((y * (-60.0d0)) / (z - t))
else
tmp = (x - y) / ((z - t) * 0.016666666666666666d0)
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) <= -4e-73) || !((a * 120.0) <= 2e+57)) {
tmp = (a * 120.0) + ((y * -60.0) / (z - t));
} else {
tmp = (x - y) / ((z - t) * 0.016666666666666666);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if ((a * 120.0) <= -4e-73) or not ((a * 120.0) <= 2e+57): tmp = (a * 120.0) + ((y * -60.0) / (z - t)) else: tmp = (x - y) / ((z - t) * 0.016666666666666666) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((Float64(a * 120.0) <= -4e-73) || !(Float64(a * 120.0) <= 2e+57)) tmp = Float64(Float64(a * 120.0) + Float64(Float64(y * -60.0) / Float64(z - t))); else tmp = Float64(Float64(x - y) / Float64(Float64(z - t) * 0.016666666666666666)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (((a * 120.0) <= -4e-73) || ~(((a * 120.0) <= 2e+57))) tmp = (a * 120.0) + ((y * -60.0) / (z - t)); else tmp = (x - y) / ((z - t) * 0.016666666666666666); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[N[(a * 120.0), $MachinePrecision], -4e-73], N[Not[LessEqual[N[(a * 120.0), $MachinePrecision], 2e+57]], $MachinePrecision]], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(y * -60.0), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x - y), $MachinePrecision] / N[(N[(z - t), $MachinePrecision] * 0.016666666666666666), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -4 \cdot 10^{-73} \lor \neg \left(a \cdot 120 \leq 2 \cdot 10^{+57}\right):\\
\;\;\;\;a \cdot 120 + \frac{y \cdot -60}{z - t}\\
\mathbf{else}:\\
\;\;\;\;\frac{x - y}{\left(z - t\right) \cdot 0.016666666666666666}\\
\end{array}
\end{array}
if (*.f64 a #s(literal 120 binary64)) < -3.99999999999999999e-73 or 2.0000000000000001e57 < (*.f64 a #s(literal 120 binary64)) Initial program 99.2%
Taylor expanded in x around 0 88.8%
if -3.99999999999999999e-73 < (*.f64 a #s(literal 120 binary64)) < 2.0000000000000001e57Initial program 98.0%
associate-/l*99.6%
Simplified99.6%
+-commutative99.6%
fma-define99.6%
Applied egg-rr99.6%
Taylor expanded in a around 0 79.7%
*-commutative79.7%
associate-*l/79.0%
associate-*r/79.7%
Simplified79.7%
clear-num79.7%
un-div-inv79.7%
div-inv79.8%
metadata-eval79.8%
Applied egg-rr79.8%
Final simplification84.6%
(FPCore (x y z t a) :precision binary64 (if (or (<= (* a 120.0) -1e-11) (not (<= (* a 120.0) 2e+57))) (* 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) <= -1e-11) || !((a * 120.0) <= 2e+57)) {
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) <= (-1d-11)) .or. (.not. ((a * 120.0d0) <= 2d+57))) 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) <= -1e-11) || !((a * 120.0) <= 2e+57)) {
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) <= -1e-11) or not ((a * 120.0) <= 2e+57): 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) <= -1e-11) || !(Float64(a * 120.0) <= 2e+57)) 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) <= -1e-11) || ~(((a * 120.0) <= 2e+57))) 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], -1e-11], N[Not[LessEqual[N[(a * 120.0), $MachinePrecision], 2e+57]], $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 -1 \cdot 10^{-11} \lor \neg \left(a \cdot 120 \leq 2 \cdot 10^{+57}\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)) < -9.99999999999999939e-12 or 2.0000000000000001e57 < (*.f64 a #s(literal 120 binary64)) Initial program 99.1%
associate-/l*99.9%
fma-define99.9%
Simplified99.9%
Taylor expanded in z around inf 78.9%
if -9.99999999999999939e-12 < (*.f64 a #s(literal 120 binary64)) < 2.0000000000000001e57Initial program 98.2%
associate-/l*99.6%
Simplified99.6%
+-commutative99.6%
fma-define99.6%
Applied egg-rr99.6%
Taylor expanded in a around 0 78.1%
*-commutative78.1%
associate-*l/77.4%
associate-*r/78.1%
Simplified78.1%
Final simplification78.5%
(FPCore (x y z t a) :precision binary64 (if (or (<= x -3.7e+105) (not (<= x 2.4e+19))) (+ (* a 120.0) (/ (* 60.0 x) (- z t))) (+ (* a 120.0) (/ (* y -60.0) (- z t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((x <= -3.7e+105) || !(x <= 2.4e+19)) {
tmp = (a * 120.0) + ((60.0 * x) / (z - t));
} 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 ((x <= (-3.7d+105)) .or. (.not. (x <= 2.4d+19))) then
tmp = (a * 120.0d0) + ((60.0d0 * x) / (z - t))
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 ((x <= -3.7e+105) || !(x <= 2.4e+19)) {
tmp = (a * 120.0) + ((60.0 * x) / (z - t));
} else {
tmp = (a * 120.0) + ((y * -60.0) / (z - t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (x <= -3.7e+105) or not (x <= 2.4e+19): tmp = (a * 120.0) + ((60.0 * x) / (z - t)) else: tmp = (a * 120.0) + ((y * -60.0) / (z - t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((x <= -3.7e+105) || !(x <= 2.4e+19)) tmp = Float64(Float64(a * 120.0) + Float64(Float64(60.0 * x) / Float64(z - t))); 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 ((x <= -3.7e+105) || ~((x <= 2.4e+19))) tmp = (a * 120.0) + ((60.0 * x) / (z - t)); else tmp = (a * 120.0) + ((y * -60.0) / (z - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[x, -3.7e+105], N[Not[LessEqual[x, 2.4e+19]], $MachinePrecision]], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(60.0 * x), $MachinePrecision] / N[(z - t), $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}\;x \leq -3.7 \cdot 10^{+105} \lor \neg \left(x \leq 2.4 \cdot 10^{+19}\right):\\
\;\;\;\;a \cdot 120 + \frac{60 \cdot x}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + \frac{y \cdot -60}{z - t}\\
\end{array}
\end{array}
if x < -3.69999999999999985e105 or 2.4e19 < x Initial program 97.1%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in x around inf 90.0%
associate-*r/89.2%
Simplified89.2%
if -3.69999999999999985e105 < x < 2.4e19Initial program 99.8%
Taylor expanded in x around 0 93.1%
Final simplification91.4%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -4.6e-14) (not (<= a 1.12e+55))) (* a 120.0) (* 60.0 (/ (- x y) (- z t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -4.6e-14) || !(a <= 1.12e+55)) {
tmp = a * 120.0;
} else {
tmp = 60.0 * ((x - y) / (z - t));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((a <= (-4.6d-14)) .or. (.not. (a <= 1.12d+55))) then
tmp = a * 120.0d0
else
tmp = 60.0d0 * ((x - y) / (z - t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -4.6e-14) || !(a <= 1.12e+55)) {
tmp = a * 120.0;
} else {
tmp = 60.0 * ((x - y) / (z - t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -4.6e-14) or not (a <= 1.12e+55): tmp = a * 120.0 else: tmp = 60.0 * ((x - y) / (z - t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -4.6e-14) || !(a <= 1.12e+55)) tmp = Float64(a * 120.0); else tmp = Float64(60.0 * Float64(Float64(x - y) / Float64(z - t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -4.6e-14) || ~((a <= 1.12e+55))) tmp = a * 120.0; else tmp = 60.0 * ((x - y) / (z - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -4.6e-14], N[Not[LessEqual[a, 1.12e+55]], $MachinePrecision]], N[(a * 120.0), $MachinePrecision], N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -4.6 \cdot 10^{-14} \lor \neg \left(a \leq 1.12 \cdot 10^{+55}\right):\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\end{array}
\end{array}
if a < -4.59999999999999996e-14 or 1.12000000000000006e55 < a Initial program 99.1%
associate-/l*99.9%
fma-define99.9%
Simplified99.9%
Taylor expanded in z around inf 78.9%
if -4.59999999999999996e-14 < a < 1.12000000000000006e55Initial program 98.2%
associate-/l*99.6%
fma-define99.6%
Simplified99.6%
Taylor expanded in a around 0 78.1%
Final simplification78.5%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -2.65e-76) (not (<= a 6.5e-56))) (* a 120.0) (* -60.0 (/ y (- z t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -2.65e-76) || !(a <= 6.5e-56)) {
tmp = a * 120.0;
} else {
tmp = -60.0 * (y / (z - t));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((a <= (-2.65d-76)) .or. (.not. (a <= 6.5d-56))) then
tmp = a * 120.0d0
else
tmp = (-60.0d0) * (y / (z - t))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -2.65e-76) || !(a <= 6.5e-56)) {
tmp = a * 120.0;
} else {
tmp = -60.0 * (y / (z - t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -2.65e-76) or not (a <= 6.5e-56): tmp = a * 120.0 else: tmp = -60.0 * (y / (z - t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -2.65e-76) || !(a <= 6.5e-56)) tmp = Float64(a * 120.0); else tmp = Float64(-60.0 * Float64(y / Float64(z - t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -2.65e-76) || ~((a <= 6.5e-56))) tmp = a * 120.0; else tmp = -60.0 * (y / (z - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -2.65e-76], N[Not[LessEqual[a, 6.5e-56]], $MachinePrecision]], N[(a * 120.0), $MachinePrecision], N[(-60.0 * N[(y / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -2.65 \cdot 10^{-76} \lor \neg \left(a \leq 6.5 \cdot 10^{-56}\right):\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;-60 \cdot \frac{y}{z - t}\\
\end{array}
\end{array}
if a < -2.65e-76 or 6.4999999999999997e-56 < a Initial program 98.6%
associate-/l*99.8%
fma-define99.9%
Simplified99.9%
Taylor expanded in z around inf 71.7%
if -2.65e-76 < a < 6.4999999999999997e-56Initial program 98.7%
associate-/l*99.6%
Simplified99.6%
+-commutative99.6%
fma-define99.6%
Applied egg-rr99.6%
Taylor expanded in y around inf 43.5%
Final simplification60.6%
(FPCore (x y z t a) :precision binary64 (if (or (<= z -8.2e-148) (not (<= z 4e-264))) (* a 120.0) (* 60.0 (/ y t))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -8.2e-148) || !(z <= 4e-264)) {
tmp = a * 120.0;
} else {
tmp = 60.0 * (y / t);
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((z <= (-8.2d-148)) .or. (.not. (z <= 4d-264))) then
tmp = a * 120.0d0
else
tmp = 60.0d0 * (y / t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -8.2e-148) || !(z <= 4e-264)) {
tmp = a * 120.0;
} else {
tmp = 60.0 * (y / t);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -8.2e-148) or not (z <= 4e-264): tmp = a * 120.0 else: tmp = 60.0 * (y / t) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -8.2e-148) || !(z <= 4e-264)) tmp = Float64(a * 120.0); else tmp = Float64(60.0 * Float64(y / t)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -8.2e-148) || ~((z <= 4e-264))) tmp = a * 120.0; else tmp = 60.0 * (y / t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -8.2e-148], N[Not[LessEqual[z, 4e-264]], $MachinePrecision]], N[(a * 120.0), $MachinePrecision], N[(60.0 * N[(y / t), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -8.2 \cdot 10^{-148} \lor \neg \left(z \leq 4 \cdot 10^{-264}\right):\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;60 \cdot \frac{y}{t}\\
\end{array}
\end{array}
if z < -8.2000000000000005e-148 or 4e-264 < z Initial program 98.9%
associate-/l*99.8%
fma-define99.8%
Simplified99.8%
Taylor expanded in z around inf 55.9%
if -8.2000000000000005e-148 < z < 4e-264Initial program 96.9%
associate-/l*99.4%
Simplified99.4%
+-commutative99.4%
fma-define99.4%
Applied egg-rr99.4%
Taylor expanded in y around inf 53.1%
Taylor expanded in z around 0 52.5%
Final simplification55.5%
(FPCore (x y z t a) :precision binary64 (if (or (<= a -8e-86) (not (<= a 3.7e-215))) (* a 120.0) (* -60.0 (/ y z))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a <= -8e-86) || !(a <= 3.7e-215)) {
tmp = a * 120.0;
} else {
tmp = -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) :: tmp
if ((a <= (-8d-86)) .or. (.not. (a <= 3.7d-215))) then
tmp = a * 120.0d0
else
tmp = (-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 tmp;
if ((a <= -8e-86) || !(a <= 3.7e-215)) {
tmp = a * 120.0;
} else {
tmp = -60.0 * (y / z);
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a <= -8e-86) or not (a <= 3.7e-215): tmp = a * 120.0 else: tmp = -60.0 * (y / z) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((a <= -8e-86) || !(a <= 3.7e-215)) tmp = Float64(a * 120.0); else tmp = Float64(-60.0 * Float64(y / z)); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a <= -8e-86) || ~((a <= 3.7e-215))) tmp = a * 120.0; else tmp = -60.0 * (y / z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[a, -8e-86], N[Not[LessEqual[a, 3.7e-215]], $MachinePrecision]], N[(a * 120.0), $MachinePrecision], N[(-60.0 * N[(y / z), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -8 \cdot 10^{-86} \lor \neg \left(a \leq 3.7 \cdot 10^{-215}\right):\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;-60 \cdot \frac{y}{z}\\
\end{array}
\end{array}
if a < -8.00000000000000068e-86 or 3.70000000000000009e-215 < a Initial program 98.8%
associate-/l*99.8%
fma-define99.8%
Simplified99.8%
Taylor expanded in z around inf 64.0%
if -8.00000000000000068e-86 < a < 3.70000000000000009e-215Initial program 98.2%
associate-/l*99.5%
Simplified99.5%
+-commutative99.5%
fma-define99.5%
Applied egg-rr99.5%
Taylor expanded in y around inf 44.4%
Taylor expanded in z around inf 26.3%
Final simplification53.9%
(FPCore (x y z t a) :precision binary64 (+ (* (- x y) (/ 60.0 (- z t))) (* a 120.0)))
double code(double x, double y, double z, double t, double a) {
return ((x - y) * (60.0 / (z - t))) + (a * 120.0);
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = ((x - y) * (60.0d0 / (z - t))) + (a * 120.0d0)
end function
public static double code(double x, double y, double z, double t, double a) {
return ((x - y) * (60.0 / (z - t))) + (a * 120.0);
}
def code(x, y, z, t, a): return ((x - y) * (60.0 / (z - t))) + (a * 120.0)
function code(x, y, z, t, a) return Float64(Float64(Float64(x - y) * Float64(60.0 / Float64(z - t))) + Float64(a * 120.0)) end
function tmp = code(x, y, z, t, a) tmp = ((x - y) * (60.0 / (z - t))) + (a * 120.0); end
code[x_, y_, z_, t_, a_] := N[(N[(N[(x - y), $MachinePrecision] * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * 120.0), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(x - y\right) \cdot \frac{60}{z - t} + a \cdot 120
\end{array}
Initial program 98.6%
*-commutative98.6%
associate-/l*99.8%
Applied egg-rr99.8%
(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(60.0 * Float64(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[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(a * 120.0), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
60 \cdot \frac{x - y}{z - t} + a \cdot 120
\end{array}
Initial program 98.6%
associate-/l*99.7%
Simplified99.7%
(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 98.6%
associate-/l*99.7%
fma-define99.7%
Simplified99.7%
Taylor expanded in z around inf 50.4%
Final simplification50.4%
(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 2024130
(FPCore (x y z t a)
:name "Data.Colour.RGB:hslsv from colour-2.3.3, B"
:precision binary64
:alt
(! :herbie-platform default (+ (/ 60 (/ (- z t) (- x y))) (* a 120)))
(+ (/ (* 60.0 (- x y)) (- z t)) (* a 120.0)))