
(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 15 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 98.7%
associate-/l*99.8%
Simplified99.8%
Final simplification99.8%
(FPCore (x y z t a)
:precision binary64
(if (<= z -1.56e+137)
(+ (* a 120.0) (* -60.0 (/ y z)))
(if (or (<= z -9.2e+68) (not (<= z 7.9e+28)))
(+ (* a 120.0) (/ 60.0 (/ z x)))
(+ (* a 120.0) (* (- x y) (/ -60.0 t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (z <= -1.56e+137) {
tmp = (a * 120.0) + (-60.0 * (y / z));
} else if ((z <= -9.2e+68) || !(z <= 7.9e+28)) {
tmp = (a * 120.0) + (60.0 / (z / x));
} else {
tmp = (a * 120.0) + ((x - y) * (-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 (z <= (-1.56d+137)) then
tmp = (a * 120.0d0) + ((-60.0d0) * (y / z))
else if ((z <= (-9.2d+68)) .or. (.not. (z <= 7.9d+28))) then
tmp = (a * 120.0d0) + (60.0d0 / (z / x))
else
tmp = (a * 120.0d0) + ((x - y) * ((-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 (z <= -1.56e+137) {
tmp = (a * 120.0) + (-60.0 * (y / z));
} else if ((z <= -9.2e+68) || !(z <= 7.9e+28)) {
tmp = (a * 120.0) + (60.0 / (z / x));
} else {
tmp = (a * 120.0) + ((x - y) * (-60.0 / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if z <= -1.56e+137: tmp = (a * 120.0) + (-60.0 * (y / z)) elif (z <= -9.2e+68) or not (z <= 7.9e+28): tmp = (a * 120.0) + (60.0 / (z / x)) else: tmp = (a * 120.0) + ((x - y) * (-60.0 / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (z <= -1.56e+137) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(y / z))); elseif ((z <= -9.2e+68) || !(z <= 7.9e+28)) tmp = Float64(Float64(a * 120.0) + Float64(60.0 / Float64(z / x))); else tmp = Float64(Float64(a * 120.0) + Float64(Float64(x - y) * Float64(-60.0 / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (z <= -1.56e+137) tmp = (a * 120.0) + (-60.0 * (y / z)); elseif ((z <= -9.2e+68) || ~((z <= 7.9e+28))) tmp = (a * 120.0) + (60.0 / (z / x)); else tmp = (a * 120.0) + ((x - y) * (-60.0 / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[z, -1.56e+137], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(y / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[z, -9.2e+68], N[Not[LessEqual[z, 7.9e+28]], $MachinePrecision]], N[(N[(a * 120.0), $MachinePrecision] + N[(60.0 / N[(z / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(x - y), $MachinePrecision] * N[(-60.0 / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.56 \cdot 10^{+137}:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{y}{z}\\
\mathbf{elif}\;z \leq -9.2 \cdot 10^{+68} \lor \neg \left(z \leq 7.9 \cdot 10^{+28}\right):\\
\;\;\;\;a \cdot 120 + \frac{60}{\frac{z}{x}}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + \left(x - y\right) \cdot \frac{-60}{t}\\
\end{array}
\end{array}
if z < -1.56000000000000008e137Initial program 96.9%
associate-/l*100.0%
Simplified100.0%
Taylor expanded in z around inf 94.2%
Taylor expanded in x around 0 91.1%
if -1.56000000000000008e137 < z < -9.1999999999999999e68 or 7.8999999999999997e28 < z Initial program 98.4%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in z around inf 91.9%
Taylor expanded in x around inf 79.5%
if -9.1999999999999999e68 < z < 7.8999999999999997e28Initial program 99.1%
associate-/l*99.8%
Simplified99.8%
associate-/r/99.8%
Applied egg-rr99.8%
Taylor expanded in z around 0 86.6%
Final simplification85.1%
(FPCore (x y z t a) :precision binary64 (if (<= (* a 120.0) -100000000.0) (+ (* a 120.0) (* -60.0 (/ x t))) (if (<= (* a 120.0) 5e-30) (* 60.0 (/ (- x y) (- z t))) (* a 120.0))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -100000000.0) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} else if ((a * 120.0) <= 5e-30) {
tmp = 60.0 * ((x - y) / (z - t));
} else {
tmp = a * 120.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((a * 120.0d0) <= (-100000000.0d0)) then
tmp = (a * 120.0d0) + ((-60.0d0) * (x / t))
else if ((a * 120.0d0) <= 5d-30) then
tmp = 60.0d0 * ((x - y) / (z - t))
else
tmp = a * 120.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -100000000.0) {
tmp = (a * 120.0) + (-60.0 * (x / t));
} else if ((a * 120.0) <= 5e-30) {
tmp = 60.0 * ((x - y) / (z - t));
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a * 120.0) <= -100000000.0: tmp = (a * 120.0) + (-60.0 * (x / t)) elif (a * 120.0) <= 5e-30: tmp = 60.0 * ((x - y) / (z - t)) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if (Float64(a * 120.0) <= -100000000.0) tmp = Float64(Float64(a * 120.0) + Float64(-60.0 * Float64(x / t))); elseif (Float64(a * 120.0) <= 5e-30) tmp = Float64(60.0 * Float64(Float64(x - y) / Float64(z - t))); else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a * 120.0) <= -100000000.0) tmp = (a * 120.0) + (-60.0 * (x / t)); elseif ((a * 120.0) <= 5e-30) tmp = 60.0 * ((x - y) / (z - t)); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[N[(a * 120.0), $MachinePrecision], -100000000.0], N[(N[(a * 120.0), $MachinePrecision] + N[(-60.0 * N[(x / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 5e-30], N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -100000000:\\
\;\;\;\;a \cdot 120 + -60 \cdot \frac{x}{t}\\
\mathbf{elif}\;a \cdot 120 \leq 5 \cdot 10^{-30}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if (*.f64 a 120) < -1e8Initial program 98.4%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 95.0%
Taylor expanded in z around 0 82.1%
if -1e8 < (*.f64 a 120) < 4.99999999999999972e-30Initial program 98.3%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 79.8%
if 4.99999999999999972e-30 < (*.f64 a 120) Initial program 99.9%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 71.9%
Final simplification78.8%
(FPCore (x y z t a) :precision binary64 (if (<= (* a 120.0) -100000000.0) (+ (* a 120.0) (/ 60.0 (/ (- t) x))) (if (<= (* a 120.0) 5e-30) (* 60.0 (/ (- x y) (- z t))) (* a 120.0))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -100000000.0) {
tmp = (a * 120.0) + (60.0 / (-t / x));
} else if ((a * 120.0) <= 5e-30) {
tmp = 60.0 * ((x - y) / (z - t));
} else {
tmp = a * 120.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((a * 120.0d0) <= (-100000000.0d0)) then
tmp = (a * 120.0d0) + (60.0d0 / (-t / x))
else if ((a * 120.0d0) <= 5d-30) then
tmp = 60.0d0 * ((x - y) / (z - t))
else
tmp = a * 120.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((a * 120.0) <= -100000000.0) {
tmp = (a * 120.0) + (60.0 / (-t / x));
} else if ((a * 120.0) <= 5e-30) {
tmp = 60.0 * ((x - y) / (z - t));
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (a * 120.0) <= -100000000.0: tmp = (a * 120.0) + (60.0 / (-t / x)) elif (a * 120.0) <= 5e-30: tmp = 60.0 * ((x - y) / (z - t)) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if (Float64(a * 120.0) <= -100000000.0) tmp = Float64(Float64(a * 120.0) + Float64(60.0 / Float64(Float64(-t) / x))); elseif (Float64(a * 120.0) <= 5e-30) tmp = Float64(60.0 * Float64(Float64(x - y) / Float64(z - t))); else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((a * 120.0) <= -100000000.0) tmp = (a * 120.0) + (60.0 / (-t / x)); elseif ((a * 120.0) <= 5e-30) tmp = 60.0 * ((x - y) / (z - t)); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[N[(a * 120.0), $MachinePrecision], -100000000.0], N[(N[(a * 120.0), $MachinePrecision] + N[(60.0 / N[((-t) / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(a * 120.0), $MachinePrecision], 5e-30], N[(60.0 * N[(N[(x - y), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \cdot 120 \leq -100000000:\\
\;\;\;\;a \cdot 120 + \frac{60}{\frac{-t}{x}}\\
\mathbf{elif}\;a \cdot 120 \leq 5 \cdot 10^{-30}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if (*.f64 a 120) < -1e8Initial program 98.4%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in x around inf 95.0%
Taylor expanded in z around 0 82.1%
neg-mul-182.1%
distribute-neg-frac82.1%
Simplified82.1%
if -1e8 < (*.f64 a 120) < 4.99999999999999972e-30Initial program 98.3%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 79.8%
if 4.99999999999999972e-30 < (*.f64 a 120) Initial program 99.9%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 71.9%
Final simplification78.8%
(FPCore (x y z t a) :precision binary64 (if (or (<= z -1.5e-11) (not (<= z 7.4e+30))) (+ (* a 120.0) (/ 60.0 (/ z (- x y)))) (+ (* a 120.0) (* (- x y) (/ -60.0 t)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((z <= -1.5e-11) || !(z <= 7.4e+30)) {
tmp = (a * 120.0) + (60.0 / (z / (x - y)));
} else {
tmp = (a * 120.0) + ((x - y) * (-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 ((z <= (-1.5d-11)) .or. (.not. (z <= 7.4d+30))) then
tmp = (a * 120.0d0) + (60.0d0 / (z / (x - y)))
else
tmp = (a * 120.0d0) + ((x - y) * ((-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 ((z <= -1.5e-11) || !(z <= 7.4e+30)) {
tmp = (a * 120.0) + (60.0 / (z / (x - y)));
} else {
tmp = (a * 120.0) + ((x - y) * (-60.0 / t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (z <= -1.5e-11) or not (z <= 7.4e+30): tmp = (a * 120.0) + (60.0 / (z / (x - y))) else: tmp = (a * 120.0) + ((x - y) * (-60.0 / t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((z <= -1.5e-11) || !(z <= 7.4e+30)) tmp = Float64(Float64(a * 120.0) + Float64(60.0 / Float64(z / Float64(x - y)))); else tmp = Float64(Float64(a * 120.0) + Float64(Float64(x - y) * Float64(-60.0 / t))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((z <= -1.5e-11) || ~((z <= 7.4e+30))) tmp = (a * 120.0) + (60.0 / (z / (x - y))); else tmp = (a * 120.0) + ((x - y) * (-60.0 / t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[z, -1.5e-11], N[Not[LessEqual[z, 7.4e+30]], $MachinePrecision]], N[(N[(a * 120.0), $MachinePrecision] + N[(60.0 / N[(z / N[(x - y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(x - y), $MachinePrecision] * N[(-60.0 / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.5 \cdot 10^{-11} \lor \neg \left(z \leq 7.4 \cdot 10^{+30}\right):\\
\;\;\;\;a \cdot 120 + \frac{60}{\frac{z}{x - y}}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + \left(x - y\right) \cdot \frac{-60}{t}\\
\end{array}
\end{array}
if z < -1.5e-11 or 7.40000000000000032e30 < z Initial program 98.2%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 90.2%
if -1.5e-11 < z < 7.40000000000000032e30Initial program 99.1%
associate-/l*99.8%
Simplified99.8%
associate-/r/99.8%
Applied egg-rr99.8%
Taylor expanded in z around 0 88.8%
Final simplification89.4%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -3.7e+79) (not (<= y 3.1e+68))) (+ (* a 120.0) (/ (* y -60.0) (- z t))) (+ (* a 120.0) (/ 60.0 (/ (- z t) x)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -3.7e+79) || !(y <= 3.1e+68)) {
tmp = (a * 120.0) + ((y * -60.0) / (z - t));
} else {
tmp = (a * 120.0) + (60.0 / ((z - t) / x));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((y <= (-3.7d+79)) .or. (.not. (y <= 3.1d+68))) then
tmp = (a * 120.0d0) + ((y * (-60.0d0)) / (z - t))
else
tmp = (a * 120.0d0) + (60.0d0 / ((z - t) / x))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -3.7e+79) || !(y <= 3.1e+68)) {
tmp = (a * 120.0) + ((y * -60.0) / (z - t));
} else {
tmp = (a * 120.0) + (60.0 / ((z - t) / x));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -3.7e+79) or not (y <= 3.1e+68): tmp = (a * 120.0) + ((y * -60.0) / (z - t)) else: tmp = (a * 120.0) + (60.0 / ((z - t) / x)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -3.7e+79) || !(y <= 3.1e+68)) tmp = Float64(Float64(a * 120.0) + Float64(Float64(y * -60.0) / Float64(z - t))); else tmp = Float64(Float64(a * 120.0) + Float64(60.0 / Float64(Float64(z - t) / x))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((y <= -3.7e+79) || ~((y <= 3.1e+68))) tmp = (a * 120.0) + ((y * -60.0) / (z - t)); else tmp = (a * 120.0) + (60.0 / ((z - t) / x)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -3.7e+79], N[Not[LessEqual[y, 3.1e+68]], $MachinePrecision]], N[(N[(a * 120.0), $MachinePrecision] + N[(N[(y * -60.0), $MachinePrecision] / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(60.0 / N[(N[(z - t), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.7 \cdot 10^{+79} \lor \neg \left(y \leq 3.1 \cdot 10^{+68}\right):\\
\;\;\;\;a \cdot 120 + \frac{y \cdot -60}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + \frac{60}{\frac{z - t}{x}}\\
\end{array}
\end{array}
if y < -3.70000000000000009e79 or 3.0999999999999998e68 < y Initial program 98.8%
Taylor expanded in x around 0 85.9%
if -3.70000000000000009e79 < y < 3.0999999999999998e68Initial program 98.6%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in x around inf 95.9%
Final simplification92.1%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -4.6e+78) (not (<= y 8.5e+70))) (+ (* a 120.0) (/ 60.0 (/ (- t z) y))) (+ (* a 120.0) (/ 60.0 (/ (- z t) x)))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -4.6e+78) || !(y <= 8.5e+70)) {
tmp = (a * 120.0) + (60.0 / ((t - z) / y));
} else {
tmp = (a * 120.0) + (60.0 / ((z - t) / x));
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if ((y <= (-4.6d+78)) .or. (.not. (y <= 8.5d+70))) then
tmp = (a * 120.0d0) + (60.0d0 / ((t - z) / y))
else
tmp = (a * 120.0d0) + (60.0d0 / ((z - t) / x))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -4.6e+78) || !(y <= 8.5e+70)) {
tmp = (a * 120.0) + (60.0 / ((t - z) / y));
} else {
tmp = (a * 120.0) + (60.0 / ((z - t) / x));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -4.6e+78) or not (y <= 8.5e+70): tmp = (a * 120.0) + (60.0 / ((t - z) / y)) else: tmp = (a * 120.0) + (60.0 / ((z - t) / x)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -4.6e+78) || !(y <= 8.5e+70)) tmp = Float64(Float64(a * 120.0) + Float64(60.0 / Float64(Float64(t - z) / y))); else tmp = Float64(Float64(a * 120.0) + Float64(60.0 / Float64(Float64(z - t) / x))); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if ((y <= -4.6e+78) || ~((y <= 8.5e+70))) tmp = (a * 120.0) + (60.0 / ((t - z) / y)); else tmp = (a * 120.0) + (60.0 / ((z - t) / x)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -4.6e+78], N[Not[LessEqual[y, 8.5e+70]], $MachinePrecision]], N[(N[(a * 120.0), $MachinePrecision] + N[(60.0 / N[(N[(t - z), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(a * 120.0), $MachinePrecision] + N[(60.0 / N[(N[(z - t), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.6 \cdot 10^{+78} \lor \neg \left(y \leq 8.5 \cdot 10^{+70}\right):\\
\;\;\;\;a \cdot 120 + \frac{60}{\frac{t - z}{y}}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120 + \frac{60}{\frac{z - t}{x}}\\
\end{array}
\end{array}
if y < -4.6000000000000004e78 or 8.4999999999999996e70 < y Initial program 98.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in x around 0 86.9%
associate-*r/86.9%
neg-mul-186.9%
Simplified86.9%
if -4.6000000000000004e78 < y < 8.4999999999999996e70Initial program 98.6%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in x around inf 95.9%
Final simplification92.5%
(FPCore (x y z t a) :precision binary64 (if (<= a -2950000000.0) (* a 120.0) (if (<= a 8.8e-20) (* 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 <= -2950000000.0) {
tmp = a * 120.0;
} else if (a <= 8.8e-20) {
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 <= (-2950000000.0d0)) then
tmp = a * 120.0d0
else if (a <= 8.8d-20) 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 <= -2950000000.0) {
tmp = a * 120.0;
} else if (a <= 8.8e-20) {
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 <= -2950000000.0: tmp = a * 120.0 elif a <= 8.8e-20: 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 <= -2950000000.0) tmp = Float64(a * 120.0); elseif (a <= 8.8e-20) 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 <= -2950000000.0) tmp = a * 120.0; elseif (a <= 8.8e-20) 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, -2950000000.0], N[(a * 120.0), $MachinePrecision], If[LessEqual[a, 8.8e-20], 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 -2950000000:\\
\;\;\;\;a \cdot 120\\
\mathbf{elif}\;a \leq 8.8 \cdot 10^{-20}:\\
\;\;\;\;60 \cdot \frac{x - y}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if a < -2.95e9 or 8.79999999999999964e-20 < a Initial program 99.1%
associate-/l*99.9%
Simplified99.9%
Taylor expanded in z around inf 76.8%
if -2.95e9 < a < 8.79999999999999964e-20Initial program 98.3%
associate-/l*99.7%
Simplified99.7%
Taylor expanded in a around 0 79.5%
Final simplification78.3%
(FPCore (x y z t a) :precision binary64 (+ (* a 120.0) (* (- x y) (/ 60.0 (- z t)))))
double code(double x, double y, double z, double t, double a) {
return (a * 120.0) + ((x - y) * (60.0 / (z - t)));
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
code = (a * 120.0d0) + ((x - y) * (60.0d0 / (z - t)))
end function
public static double code(double x, double y, double z, double t, double a) {
return (a * 120.0) + ((x - y) * (60.0 / (z - t)));
}
def code(x, y, z, t, a): return (a * 120.0) + ((x - y) * (60.0 / (z - t)))
function code(x, y, z, t, a) return Float64(Float64(a * 120.0) + Float64(Float64(x - y) * Float64(60.0 / Float64(z - t)))) end
function tmp = code(x, y, z, t, a) tmp = (a * 120.0) + ((x - y) * (60.0 / (z - t))); end
code[x_, y_, z_, t_, a_] := N[(N[(a * 120.0), $MachinePrecision] + N[(N[(x - y), $MachinePrecision] * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
a \cdot 120 + \left(x - y\right) \cdot \frac{60}{z - t}
\end{array}
Initial program 98.7%
associate-/l*99.8%
Simplified99.8%
associate-/r/99.8%
Applied egg-rr99.8%
Final simplification99.8%
(FPCore (x y z t a) :precision binary64 (if (or (<= y -1.05e+107) (not (<= y 3.4e+212))) (* -60.0 (/ y (- z t))) (* a 120.0)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((y <= -1.05e+107) || !(y <= 3.4e+212)) {
tmp = -60.0 * (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 ((y <= (-1.05d+107)) .or. (.not. (y <= 3.4d+212))) then
tmp = (-60.0d0) * (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 ((y <= -1.05e+107) || !(y <= 3.4e+212)) {
tmp = -60.0 * (y / (z - t));
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (y <= -1.05e+107) or not (y <= 3.4e+212): tmp = -60.0 * (y / (z - t)) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((y <= -1.05e+107) || !(y <= 3.4e+212)) tmp = Float64(-60.0 * Float64(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 ((y <= -1.05e+107) || ~((y <= 3.4e+212))) tmp = -60.0 * (y / (z - t)); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[y, -1.05e+107], N[Not[LessEqual[y, 3.4e+212]], $MachinePrecision]], N[(-60.0 * N[(y / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.05 \cdot 10^{+107} \lor \neg \left(y \leq 3.4 \cdot 10^{+212}\right):\\
\;\;\;\;-60 \cdot \frac{y}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if y < -1.05e107 or 3.40000000000000037e212 < y Initial program 98.0%
associate-/l*99.7%
Simplified99.7%
associate-/r/99.6%
Applied egg-rr99.6%
Taylor expanded in y around inf 65.8%
if -1.05e107 < y < 3.40000000000000037e212Initial program 98.9%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 53.5%
Final simplification56.2%
(FPCore (x y z t a) :precision binary64 (if (or (<= x -4.5e+40) (not (<= x 4e+139))) (* 60.0 (/ x (- z t))) (* a 120.0)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if ((x <= -4.5e+40) || !(x <= 4e+139)) {
tmp = 60.0 * (x / (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 ((x <= (-4.5d+40)) .or. (.not. (x <= 4d+139))) then
tmp = 60.0d0 * (x / (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 ((x <= -4.5e+40) || !(x <= 4e+139)) {
tmp = 60.0 * (x / (z - t));
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if (x <= -4.5e+40) or not (x <= 4e+139): tmp = 60.0 * (x / (z - t)) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if ((x <= -4.5e+40) || !(x <= 4e+139)) tmp = Float64(60.0 * Float64(x / 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 ((x <= -4.5e+40) || ~((x <= 4e+139))) tmp = 60.0 * (x / (z - t)); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[Or[LessEqual[x, -4.5e+40], N[Not[LessEqual[x, 4e+139]], $MachinePrecision]], N[(60.0 * N[(x / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -4.5 \cdot 10^{+40} \lor \neg \left(x \leq 4 \cdot 10^{+139}\right):\\
\;\;\;\;60 \cdot \frac{x}{z - t}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if x < -4.50000000000000032e40 or 4.00000000000000013e139 < x Initial program 97.6%
associate-/l*99.7%
Simplified99.7%
associate-/r/99.6%
Applied egg-rr99.6%
Taylor expanded in x around inf 66.1%
if -4.50000000000000032e40 < x < 4.00000000000000013e139Initial program 99.2%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 61.1%
Final simplification62.9%
(FPCore (x y z t a) :precision binary64 (if (<= x -4.5e+40) (* x (/ 60.0 (- z t))) (if (<= x 6e+138) (* a 120.0) (* 60.0 (/ x (- z t))))))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (x <= -4.5e+40) {
tmp = x * (60.0 / (z - t));
} else if (x <= 6e+138) {
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 (x <= (-4.5d+40)) then
tmp = x * (60.0d0 / (z - t))
else if (x <= 6d+138) 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 (x <= -4.5e+40) {
tmp = x * (60.0 / (z - t));
} else if (x <= 6e+138) {
tmp = a * 120.0;
} else {
tmp = 60.0 * (x / (z - t));
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if x <= -4.5e+40: tmp = x * (60.0 / (z - t)) elif x <= 6e+138: tmp = a * 120.0 else: tmp = 60.0 * (x / (z - t)) return tmp
function code(x, y, z, t, a) tmp = 0.0 if (x <= -4.5e+40) tmp = Float64(x * Float64(60.0 / Float64(z - t))); elseif (x <= 6e+138) 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 (x <= -4.5e+40) tmp = x * (60.0 / (z - t)); elseif (x <= 6e+138) tmp = a * 120.0; else tmp = 60.0 * (x / (z - t)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[x, -4.5e+40], N[(x * N[(60.0 / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 6e+138], N[(a * 120.0), $MachinePrecision], N[(60.0 * N[(x / N[(z - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -4.5 \cdot 10^{+40}:\\
\;\;\;\;x \cdot \frac{60}{z - t}\\
\mathbf{elif}\;x \leq 6 \cdot 10^{+138}:\\
\;\;\;\;a \cdot 120\\
\mathbf{else}:\\
\;\;\;\;60 \cdot \frac{x}{z - t}\\
\end{array}
\end{array}
if x < -4.50000000000000032e40Initial program 97.8%
associate-/l*99.7%
Simplified99.7%
associate-/r/99.7%
Applied egg-rr99.7%
Taylor expanded in x around inf 62.1%
associate-*r/60.3%
associate-*l/62.2%
*-commutative62.2%
Simplified62.2%
if -4.50000000000000032e40 < x < 6.0000000000000002e138Initial program 99.2%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 61.1%
if 6.0000000000000002e138 < x Initial program 97.5%
associate-/l*99.7%
Simplified99.7%
associate-/r/99.5%
Applied egg-rr99.5%
Taylor expanded in x around inf 70.5%
Final simplification62.9%
(FPCore (x y z t a) :precision binary64 (if (<= y -1.32e+107) (* -60.0 (/ y z)) (* a 120.0)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (y <= -1.32e+107) {
tmp = -60.0 * (y / z);
} else {
tmp = a * 120.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (y <= (-1.32d+107)) then
tmp = (-60.0d0) * (y / z)
else
tmp = a * 120.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (y <= -1.32e+107) {
tmp = -60.0 * (y / z);
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if y <= -1.32e+107: tmp = -60.0 * (y / z) else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if (y <= -1.32e+107) tmp = Float64(-60.0 * Float64(y / z)); else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (y <= -1.32e+107) tmp = -60.0 * (y / z); else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[y, -1.32e+107], N[(-60.0 * N[(y / z), $MachinePrecision]), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.32 \cdot 10^{+107}:\\
\;\;\;\;-60 \cdot \frac{y}{z}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if y < -1.32000000000000003e107Initial program 97.2%
associate-/l*99.6%
Simplified99.6%
associate-/r/99.6%
Applied egg-rr99.6%
Taylor expanded in y around inf 63.1%
Taylor expanded in z around inf 40.4%
if -1.32000000000000003e107 < y Initial program 98.9%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 50.9%
Final simplification49.3%
(FPCore (x y z t a) :precision binary64 (if (<= y -1.32e+107) (/ (* y -60.0) z) (* a 120.0)))
double code(double x, double y, double z, double t, double a) {
double tmp;
if (y <= -1.32e+107) {
tmp = (y * -60.0) / z;
} else {
tmp = a * 120.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8) :: tmp
if (y <= (-1.32d+107)) then
tmp = (y * (-60.0d0)) / z
else
tmp = a * 120.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a) {
double tmp;
if (y <= -1.32e+107) {
tmp = (y * -60.0) / z;
} else {
tmp = a * 120.0;
}
return tmp;
}
def code(x, y, z, t, a): tmp = 0 if y <= -1.32e+107: tmp = (y * -60.0) / z else: tmp = a * 120.0 return tmp
function code(x, y, z, t, a) tmp = 0.0 if (y <= -1.32e+107) tmp = Float64(Float64(y * -60.0) / z); else tmp = Float64(a * 120.0); end return tmp end
function tmp_2 = code(x, y, z, t, a) tmp = 0.0; if (y <= -1.32e+107) tmp = (y * -60.0) / z; else tmp = a * 120.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_] := If[LessEqual[y, -1.32e+107], N[(N[(y * -60.0), $MachinePrecision] / z), $MachinePrecision], N[(a * 120.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.32 \cdot 10^{+107}:\\
\;\;\;\;\frac{y \cdot -60}{z}\\
\mathbf{else}:\\
\;\;\;\;a \cdot 120\\
\end{array}
\end{array}
if y < -1.32000000000000003e107Initial program 97.2%
associate-/l*99.6%
Simplified99.6%
associate-/r/99.6%
Applied egg-rr99.6%
Taylor expanded in y around inf 63.1%
Taylor expanded in z around inf 40.4%
associate-*r/40.4%
Applied egg-rr40.4%
if -1.32000000000000003e107 < y Initial program 98.9%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 50.9%
Final simplification49.3%
(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.7%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in z around inf 47.0%
Final simplification47.0%
(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 2023252
(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)))