
(FPCore (x y z t a b) :precision binary64 (/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y))
double code(double x, double y, double z, double t, double a, double b) {
return (x * exp((((y * log(z)) + ((t - 1.0) * log(a))) - b))) / y;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
code = (x * exp((((y * log(z)) + ((t - 1.0d0) * log(a))) - b))) / y
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return (x * Math.exp((((y * Math.log(z)) + ((t - 1.0) * Math.log(a))) - b))) / y;
}
def code(x, y, z, t, a, b): return (x * math.exp((((y * math.log(z)) + ((t - 1.0) * math.log(a))) - b))) / y
function code(x, y, z, t, a, b) return Float64(Float64(x * exp(Float64(Float64(Float64(y * log(z)) + Float64(Float64(t - 1.0) * log(a))) - b))) / y) end
function tmp = code(x, y, z, t, a, b) tmp = (x * exp((((y * log(z)) + ((t - 1.0) * log(a))) - b))) / y; end
code[x_, y_, z_, t_, a_, b_] := N[(N[(x * N[Exp[N[(N[(N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision] + N[(N[(t - 1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]
\begin{array}{l}
\\
\frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 31 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b) :precision binary64 (/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y))
double code(double x, double y, double z, double t, double a, double b) {
return (x * exp((((y * log(z)) + ((t - 1.0) * log(a))) - b))) / y;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
code = (x * exp((((y * log(z)) + ((t - 1.0d0) * log(a))) - b))) / y
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return (x * Math.exp((((y * Math.log(z)) + ((t - 1.0) * Math.log(a))) - b))) / y;
}
def code(x, y, z, t, a, b): return (x * math.exp((((y * math.log(z)) + ((t - 1.0) * math.log(a))) - b))) / y
function code(x, y, z, t, a, b) return Float64(Float64(x * exp(Float64(Float64(Float64(y * log(z)) + Float64(Float64(t - 1.0) * log(a))) - b))) / y) end
function tmp = code(x, y, z, t, a, b) tmp = (x * exp((((y * log(z)) + ((t - 1.0) * log(a))) - b))) / y; end
code[x_, y_, z_, t_, a_, b_] := N[(N[(x * N[Exp[N[(N[(N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision] + N[(N[(t - 1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]
\begin{array}{l}
\\
\frac{x \cdot e^{\left(y \cdot \log z + \left(t - 1\right) \cdot \log a\right) - b}}{y}
\end{array}
(FPCore (x y z t a b) :precision binary64 (/ (* x (exp (- (+ (* y (log z)) (* (+ t -1.0) (log a))) b))) y))
double code(double x, double y, double z, double t, double a, double b) {
return (x * exp((((y * log(z)) + ((t + -1.0) * log(a))) - b))) / y;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
code = (x * exp((((y * log(z)) + ((t + (-1.0d0)) * log(a))) - b))) / y
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return (x * Math.exp((((y * Math.log(z)) + ((t + -1.0) * Math.log(a))) - b))) / y;
}
def code(x, y, z, t, a, b): return (x * math.exp((((y * math.log(z)) + ((t + -1.0) * math.log(a))) - b))) / y
function code(x, y, z, t, a, b) return Float64(Float64(x * exp(Float64(Float64(Float64(y * log(z)) + Float64(Float64(t + -1.0) * log(a))) - b))) / y) end
function tmp = code(x, y, z, t, a, b) tmp = (x * exp((((y * log(z)) + ((t + -1.0) * log(a))) - b))) / y; end
code[x_, y_, z_, t_, a_, b_] := N[(N[(x * N[Exp[N[(N[(N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision] + N[(N[(t + -1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]
\begin{array}{l}
\\
\frac{x \cdot e^{\left(y \cdot \log z + \left(t + -1\right) \cdot \log a\right) - b}}{y}
\end{array}
Initial program 97.6%
Final simplification97.6%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -4.1e+20) (not (<= y 6.8e+79))) (/ (* x (exp (- (- (* y (log z)) (log a)) b))) y) (/ (* x (exp (- (* (+ t -1.0) (log a)) b))) y)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -4.1e+20) || !(y <= 6.8e+79)) {
tmp = (x * exp((((y * log(z)) - log(a)) - b))) / y;
} else {
tmp = (x * exp((((t + -1.0) * log(a)) - b))) / y;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if ((y <= (-4.1d+20)) .or. (.not. (y <= 6.8d+79))) then
tmp = (x * exp((((y * log(z)) - log(a)) - b))) / y
else
tmp = (x * exp((((t + (-1.0d0)) * log(a)) - b))) / y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -4.1e+20) || !(y <= 6.8e+79)) {
tmp = (x * Math.exp((((y * Math.log(z)) - Math.log(a)) - b))) / y;
} else {
tmp = (x * Math.exp((((t + -1.0) * Math.log(a)) - b))) / y;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -4.1e+20) or not (y <= 6.8e+79): tmp = (x * math.exp((((y * math.log(z)) - math.log(a)) - b))) / y else: tmp = (x * math.exp((((t + -1.0) * math.log(a)) - b))) / y return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -4.1e+20) || !(y <= 6.8e+79)) tmp = Float64(Float64(x * exp(Float64(Float64(Float64(y * log(z)) - log(a)) - b))) / y); else tmp = Float64(Float64(x * exp(Float64(Float64(Float64(t + -1.0) * log(a)) - b))) / y); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -4.1e+20) || ~((y <= 6.8e+79))) tmp = (x * exp((((y * log(z)) - log(a)) - b))) / y; else tmp = (x * exp((((t + -1.0) * log(a)) - b))) / y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -4.1e+20], N[Not[LessEqual[y, 6.8e+79]], $MachinePrecision]], N[(N[(x * N[Exp[N[(N[(N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision] - N[Log[a], $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(N[(x * N[Exp[N[(N[(N[(t + -1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.1 \cdot 10^{+20} \lor \neg \left(y \leq 6.8 \cdot 10^{+79}\right):\\
\;\;\;\;\frac{x \cdot e^{\left(y \cdot \log z - \log a\right) - b}}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x \cdot e^{\left(t + -1\right) \cdot \log a - b}}{y}\\
\end{array}
\end{array}
if y < -4.1e20 or 6.80000000000000063e79 < y Initial program 100.0%
Taylor expanded in t around 0 95.7%
+-commutative95.7%
mul-1-neg95.7%
unsub-neg95.7%
Simplified95.7%
if -4.1e20 < y < 6.80000000000000063e79Initial program 96.3%
Taylor expanded in y around 0 95.1%
Final simplification95.3%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -2e+39) (not (<= y 3e+205))) (/ (/ (* x (pow z y)) a) y) (/ (* x (exp (- (* (+ t -1.0) (log a)) b))) y)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -2e+39) || !(y <= 3e+205)) {
tmp = ((x * pow(z, y)) / a) / y;
} else {
tmp = (x * exp((((t + -1.0) * log(a)) - b))) / y;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if ((y <= (-2d+39)) .or. (.not. (y <= 3d+205))) then
tmp = ((x * (z ** y)) / a) / y
else
tmp = (x * exp((((t + (-1.0d0)) * log(a)) - b))) / y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -2e+39) || !(y <= 3e+205)) {
tmp = ((x * Math.pow(z, y)) / a) / y;
} else {
tmp = (x * Math.exp((((t + -1.0) * Math.log(a)) - b))) / y;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -2e+39) or not (y <= 3e+205): tmp = ((x * math.pow(z, y)) / a) / y else: tmp = (x * math.exp((((t + -1.0) * math.log(a)) - b))) / y return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -2e+39) || !(y <= 3e+205)) tmp = Float64(Float64(Float64(x * (z ^ y)) / a) / y); else tmp = Float64(Float64(x * exp(Float64(Float64(Float64(t + -1.0) * log(a)) - b))) / y); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -2e+39) || ~((y <= 3e+205))) tmp = ((x * (z ^ y)) / a) / y; else tmp = (x * exp((((t + -1.0) * log(a)) - b))) / y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -2e+39], N[Not[LessEqual[y, 3e+205]], $MachinePrecision]], N[(N[(N[(x * N[Power[z, y], $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision], N[(N[(x * N[Exp[N[(N[(N[(t + -1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2 \cdot 10^{+39} \lor \neg \left(y \leq 3 \cdot 10^{+205}\right):\\
\;\;\;\;\frac{\frac{x \cdot {z}^{y}}{a}}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x \cdot e^{\left(t + -1\right) \cdot \log a - b}}{y}\\
\end{array}
\end{array}
if y < -1.99999999999999988e39 or 2.9999999999999999e205 < y Initial program 100.0%
associate-/l*100.0%
associate--l+100.0%
exp-sum67.2%
associate-/l*61.2%
*-commutative61.2%
exp-to-pow61.2%
exp-diff49.3%
*-commutative49.3%
exp-to-pow49.3%
sub-neg49.3%
metadata-eval49.3%
Simplified49.3%
Taylor expanded in b around 0 70.2%
exp-to-pow70.2%
sub-neg70.2%
metadata-eval70.2%
Simplified70.2%
Taylor expanded in t around 0 94.1%
if -1.99999999999999988e39 < y < 2.9999999999999999e205Initial program 96.8%
Taylor expanded in y around 0 91.7%
Final simplification92.3%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -1.26e+38) (not (<= y 6.2e+49))) (/ (/ (* x (pow z y)) a) y) (* x (/ (/ (pow a (+ t -1.0)) (exp b)) y))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -1.26e+38) || !(y <= 6.2e+49)) {
tmp = ((x * pow(z, y)) / a) / y;
} else {
tmp = x * ((pow(a, (t + -1.0)) / exp(b)) / y);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if ((y <= (-1.26d+38)) .or. (.not. (y <= 6.2d+49))) then
tmp = ((x * (z ** y)) / a) / y
else
tmp = x * (((a ** (t + (-1.0d0))) / exp(b)) / y)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -1.26e+38) || !(y <= 6.2e+49)) {
tmp = ((x * Math.pow(z, y)) / a) / y;
} else {
tmp = x * ((Math.pow(a, (t + -1.0)) / Math.exp(b)) / y);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -1.26e+38) or not (y <= 6.2e+49): tmp = ((x * math.pow(z, y)) / a) / y else: tmp = x * ((math.pow(a, (t + -1.0)) / math.exp(b)) / y) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -1.26e+38) || !(y <= 6.2e+49)) tmp = Float64(Float64(Float64(x * (z ^ y)) / a) / y); else tmp = Float64(x * Float64(Float64((a ^ Float64(t + -1.0)) / exp(b)) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -1.26e+38) || ~((y <= 6.2e+49))) tmp = ((x * (z ^ y)) / a) / y; else tmp = x * (((a ^ (t + -1.0)) / exp(b)) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -1.26e+38], N[Not[LessEqual[y, 6.2e+49]], $MachinePrecision]], N[(N[(N[(x * N[Power[z, y], $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision], N[(x * N[(N[(N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision] / N[Exp[b], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.26 \cdot 10^{+38} \lor \neg \left(y \leq 6.2 \cdot 10^{+49}\right):\\
\;\;\;\;\frac{\frac{x \cdot {z}^{y}}{a}}{y}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{\frac{{a}^{\left(t + -1\right)}}{e^{b}}}{y}\\
\end{array}
\end{array}
if y < -1.25999999999999997e38 or 6.19999999999999985e49 < y Initial program 100.0%
associate-/l*100.0%
associate--l+100.0%
exp-sum64.2%
associate-/l*60.0%
*-commutative60.0%
exp-to-pow60.0%
exp-diff50.5%
*-commutative50.5%
exp-to-pow50.5%
sub-neg50.5%
metadata-eval50.5%
Simplified50.5%
Taylor expanded in b around 0 65.4%
exp-to-pow65.4%
sub-neg65.4%
metadata-eval65.4%
Simplified65.4%
Taylor expanded in t around 0 85.5%
if -1.25999999999999997e38 < y < 6.19999999999999985e49Initial program 96.2%
Taylor expanded in y around 0 94.4%
associate-/l*95.5%
div-exp84.4%
exp-to-pow85.8%
sub-neg85.8%
metadata-eval85.8%
Simplified85.8%
Final simplification85.7%
(FPCore (x y z t a b) :precision binary64 (if (or (<= t -3e+40) (not (<= t 2.9e+62))) (* x (/ (pow a (+ t -1.0)) y)) (* x (/ (/ (pow z y) a) (* y (exp b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -3e+40) || !(t <= 2.9e+62)) {
tmp = x * (pow(a, (t + -1.0)) / y);
} else {
tmp = x * ((pow(z, y) / a) / (y * exp(b)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if ((t <= (-3d+40)) .or. (.not. (t <= 2.9d+62))) then
tmp = x * ((a ** (t + (-1.0d0))) / y)
else
tmp = x * (((z ** y) / a) / (y * exp(b)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -3e+40) || !(t <= 2.9e+62)) {
tmp = x * (Math.pow(a, (t + -1.0)) / y);
} else {
tmp = x * ((Math.pow(z, y) / a) / (y * Math.exp(b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t <= -3e+40) or not (t <= 2.9e+62): tmp = x * (math.pow(a, (t + -1.0)) / y) else: tmp = x * ((math.pow(z, y) / a) / (y * math.exp(b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((t <= -3e+40) || !(t <= 2.9e+62)) tmp = Float64(x * Float64((a ^ Float64(t + -1.0)) / y)); else tmp = Float64(x * Float64(Float64((z ^ y) / a) / Float64(y * exp(b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((t <= -3e+40) || ~((t <= 2.9e+62))) tmp = x * ((a ^ (t + -1.0)) / y); else tmp = x * (((z ^ y) / a) / (y * exp(b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[t, -3e+40], N[Not[LessEqual[t, 2.9e+62]], $MachinePrecision]], N[(x * N[(N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(N[Power[z, y], $MachinePrecision] / a), $MachinePrecision] / N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -3 \cdot 10^{+40} \lor \neg \left(t \leq 2.9 \cdot 10^{+62}\right):\\
\;\;\;\;x \cdot \frac{{a}^{\left(t + -1\right)}}{y}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{\frac{{z}^{y}}{a}}{y \cdot e^{b}}\\
\end{array}
\end{array}
if t < -3.0000000000000002e40 or 2.89999999999999984e62 < t Initial program 100.0%
Taylor expanded in y around 0 91.9%
associate-/l*91.9%
div-exp68.9%
exp-to-pow68.9%
sub-neg68.9%
metadata-eval68.9%
Simplified68.9%
Taylor expanded in b around 0 84.6%
exp-to-pow84.6%
sub-neg84.6%
metadata-eval84.6%
Simplified84.6%
if -3.0000000000000002e40 < t < 2.89999999999999984e62Initial program 95.9%
associate-/l*97.1%
associate--l+97.1%
exp-sum81.4%
associate-/l*78.7%
*-commutative78.7%
exp-to-pow78.7%
exp-diff75.3%
*-commutative75.3%
exp-to-pow76.9%
sub-neg76.9%
metadata-eval76.9%
Simplified76.9%
Taylor expanded in t around 0 83.7%
associate-/r*87.1%
Simplified87.1%
Final simplification86.1%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (/ (* x (pow z y)) a) y)))
(if (<= y -4e-6)
t_1
(if (<= y 2.3e-144)
(/ x (* a (* y (exp b))))
(if (<= y 1.6e+79) (* x (/ (pow a (+ t -1.0)) y)) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = ((x * pow(z, y)) / a) / y;
double tmp;
if (y <= -4e-6) {
tmp = t_1;
} else if (y <= 2.3e-144) {
tmp = x / (a * (y * exp(b)));
} else if (y <= 1.6e+79) {
tmp = x * (pow(a, (t + -1.0)) / y);
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = ((x * (z ** y)) / a) / y
if (y <= (-4d-6)) then
tmp = t_1
else if (y <= 2.3d-144) then
tmp = x / (a * (y * exp(b)))
else if (y <= 1.6d+79) then
tmp = x * ((a ** (t + (-1.0d0))) / y)
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 b) {
double t_1 = ((x * Math.pow(z, y)) / a) / y;
double tmp;
if (y <= -4e-6) {
tmp = t_1;
} else if (y <= 2.3e-144) {
tmp = x / (a * (y * Math.exp(b)));
} else if (y <= 1.6e+79) {
tmp = x * (Math.pow(a, (t + -1.0)) / y);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = ((x * math.pow(z, y)) / a) / y tmp = 0 if y <= -4e-6: tmp = t_1 elif y <= 2.3e-144: tmp = x / (a * (y * math.exp(b))) elif y <= 1.6e+79: tmp = x * (math.pow(a, (t + -1.0)) / y) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(Float64(x * (z ^ y)) / a) / y) tmp = 0.0 if (y <= -4e-6) tmp = t_1; elseif (y <= 2.3e-144) tmp = Float64(x / Float64(a * Float64(y * exp(b)))); elseif (y <= 1.6e+79) tmp = Float64(x * Float64((a ^ Float64(t + -1.0)) / y)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = ((x * (z ^ y)) / a) / y; tmp = 0.0; if (y <= -4e-6) tmp = t_1; elseif (y <= 2.3e-144) tmp = x / (a * (y * exp(b))); elseif (y <= 1.6e+79) tmp = x * ((a ^ (t + -1.0)) / y); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[(x * N[Power[z, y], $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision]}, If[LessEqual[y, -4e-6], t$95$1, If[LessEqual[y, 2.3e-144], N[(x / N[(a * N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.6e+79], N[(x * N[(N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\frac{x \cdot {z}^{y}}{a}}{y}\\
\mathbf{if}\;y \leq -4 \cdot 10^{-6}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 2.3 \cdot 10^{-144}:\\
\;\;\;\;\frac{x}{a \cdot \left(y \cdot e^{b}\right)}\\
\mathbf{elif}\;y \leq 1.6 \cdot 10^{+79}:\\
\;\;\;\;x \cdot \frac{{a}^{\left(t + -1\right)}}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -3.99999999999999982e-6 or 1.60000000000000001e79 < y Initial program 100.0%
associate-/l*100.0%
associate--l+100.0%
exp-sum67.3%
associate-/l*63.4%
*-commutative63.4%
exp-to-pow63.4%
exp-diff54.5%
*-commutative54.5%
exp-to-pow54.5%
sub-neg54.5%
metadata-eval54.5%
Simplified54.5%
Taylor expanded in b around 0 69.4%
exp-to-pow69.4%
sub-neg69.4%
metadata-eval69.4%
Simplified69.4%
Taylor expanded in t around 0 85.4%
if -3.99999999999999982e-6 < y < 2.3e-144Initial program 95.5%
Taylor expanded in y around 0 95.5%
associate-/l*96.4%
div-exp85.3%
exp-to-pow87.1%
sub-neg87.1%
metadata-eval87.1%
Simplified87.1%
Taylor expanded in t around 0 82.0%
if 2.3e-144 < y < 1.60000000000000001e79Initial program 97.3%
Taylor expanded in y around 0 95.2%
associate-/l*97.0%
div-exp80.2%
exp-to-pow80.9%
sub-neg80.9%
metadata-eval80.9%
Simplified80.9%
Taylor expanded in b around 0 74.6%
exp-to-pow75.2%
sub-neg75.2%
metadata-eval75.2%
Simplified75.2%
Final simplification82.1%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (/ (* x (pow z y)) a) y)))
(if (<= y -4e-6)
t_1
(if (<= y 3.15e-145)
(/ (* x (/ (/ 1.0 a) (exp b))) y)
(if (<= y 2.1e+79) (* x (/ (pow a (+ t -1.0)) y)) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = ((x * pow(z, y)) / a) / y;
double tmp;
if (y <= -4e-6) {
tmp = t_1;
} else if (y <= 3.15e-145) {
tmp = (x * ((1.0 / a) / exp(b))) / y;
} else if (y <= 2.1e+79) {
tmp = x * (pow(a, (t + -1.0)) / y);
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = ((x * (z ** y)) / a) / y
if (y <= (-4d-6)) then
tmp = t_1
else if (y <= 3.15d-145) then
tmp = (x * ((1.0d0 / a) / exp(b))) / y
else if (y <= 2.1d+79) then
tmp = x * ((a ** (t + (-1.0d0))) / y)
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 b) {
double t_1 = ((x * Math.pow(z, y)) / a) / y;
double tmp;
if (y <= -4e-6) {
tmp = t_1;
} else if (y <= 3.15e-145) {
tmp = (x * ((1.0 / a) / Math.exp(b))) / y;
} else if (y <= 2.1e+79) {
tmp = x * (Math.pow(a, (t + -1.0)) / y);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = ((x * math.pow(z, y)) / a) / y tmp = 0 if y <= -4e-6: tmp = t_1 elif y <= 3.15e-145: tmp = (x * ((1.0 / a) / math.exp(b))) / y elif y <= 2.1e+79: tmp = x * (math.pow(a, (t + -1.0)) / y) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(Float64(x * (z ^ y)) / a) / y) tmp = 0.0 if (y <= -4e-6) tmp = t_1; elseif (y <= 3.15e-145) tmp = Float64(Float64(x * Float64(Float64(1.0 / a) / exp(b))) / y); elseif (y <= 2.1e+79) tmp = Float64(x * Float64((a ^ Float64(t + -1.0)) / y)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = ((x * (z ^ y)) / a) / y; tmp = 0.0; if (y <= -4e-6) tmp = t_1; elseif (y <= 3.15e-145) tmp = (x * ((1.0 / a) / exp(b))) / y; elseif (y <= 2.1e+79) tmp = x * ((a ^ (t + -1.0)) / y); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[(x * N[Power[z, y], $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision]}, If[LessEqual[y, -4e-6], t$95$1, If[LessEqual[y, 3.15e-145], N[(N[(x * N[(N[(1.0 / a), $MachinePrecision] / N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[y, 2.1e+79], N[(x * N[(N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\frac{x \cdot {z}^{y}}{a}}{y}\\
\mathbf{if}\;y \leq -4 \cdot 10^{-6}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 3.15 \cdot 10^{-145}:\\
\;\;\;\;\frac{x \cdot \frac{\frac{1}{a}}{e^{b}}}{y}\\
\mathbf{elif}\;y \leq 2.1 \cdot 10^{+79}:\\
\;\;\;\;x \cdot \frac{{a}^{\left(t + -1\right)}}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -3.99999999999999982e-6 or 2.10000000000000008e79 < y Initial program 100.0%
associate-/l*100.0%
associate--l+100.0%
exp-sum67.3%
associate-/l*63.4%
*-commutative63.4%
exp-to-pow63.4%
exp-diff54.5%
*-commutative54.5%
exp-to-pow54.5%
sub-neg54.5%
metadata-eval54.5%
Simplified54.5%
Taylor expanded in b around 0 69.4%
exp-to-pow69.4%
sub-neg69.4%
metadata-eval69.4%
Simplified69.4%
Taylor expanded in t around 0 85.4%
if -3.99999999999999982e-6 < y < 3.15e-145Initial program 95.5%
Taylor expanded in t around 0 80.2%
+-commutative80.2%
mul-1-neg80.2%
unsub-neg80.2%
Simplified80.2%
Taylor expanded in y around 0 80.2%
exp-neg80.2%
exp-sum80.2%
rem-exp-log82.0%
associate-/l/82.0%
Simplified82.0%
if 3.15e-145 < y < 2.10000000000000008e79Initial program 97.3%
Taylor expanded in y around 0 95.2%
associate-/l*97.0%
div-exp80.2%
exp-to-pow80.9%
sub-neg80.9%
metadata-eval80.9%
Simplified80.9%
Taylor expanded in b around 0 74.6%
exp-to-pow75.2%
sub-neg75.2%
metadata-eval75.2%
Simplified75.2%
Final simplification82.1%
(FPCore (x y z t a b) :precision binary64 (if (or (<= t -4e+56) (not (<= t 2.3e+62))) (* x (/ (pow a (+ t -1.0)) y)) (/ x (* a (* y (exp b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -4e+56) || !(t <= 2.3e+62)) {
tmp = x * (pow(a, (t + -1.0)) / y);
} else {
tmp = x / (a * (y * exp(b)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if ((t <= (-4d+56)) .or. (.not. (t <= 2.3d+62))) then
tmp = x * ((a ** (t + (-1.0d0))) / y)
else
tmp = x / (a * (y * exp(b)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -4e+56) || !(t <= 2.3e+62)) {
tmp = x * (Math.pow(a, (t + -1.0)) / y);
} else {
tmp = x / (a * (y * Math.exp(b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t <= -4e+56) or not (t <= 2.3e+62): tmp = x * (math.pow(a, (t + -1.0)) / y) else: tmp = x / (a * (y * math.exp(b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((t <= -4e+56) || !(t <= 2.3e+62)) tmp = Float64(x * Float64((a ^ Float64(t + -1.0)) / y)); else tmp = Float64(x / Float64(a * Float64(y * exp(b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((t <= -4e+56) || ~((t <= 2.3e+62))) tmp = x * ((a ^ (t + -1.0)) / y); else tmp = x / (a * (y * exp(b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[t, -4e+56], N[Not[LessEqual[t, 2.3e+62]], $MachinePrecision]], N[(x * N[(N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x / N[(a * N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4 \cdot 10^{+56} \lor \neg \left(t \leq 2.3 \cdot 10^{+62}\right):\\
\;\;\;\;x \cdot \frac{{a}^{\left(t + -1\right)}}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y \cdot e^{b}\right)}\\
\end{array}
\end{array}
if t < -4.00000000000000037e56 or 2.29999999999999984e62 < t Initial program 100.0%
Taylor expanded in y around 0 91.4%
associate-/l*91.4%
div-exp68.1%
exp-to-pow68.1%
sub-neg68.1%
metadata-eval68.1%
Simplified68.1%
Taylor expanded in b around 0 84.7%
exp-to-pow84.7%
sub-neg84.7%
metadata-eval84.7%
Simplified84.7%
if -4.00000000000000037e56 < t < 2.29999999999999984e62Initial program 96.0%
Taylor expanded in y around 0 71.3%
associate-/l*73.0%
div-exp68.5%
exp-to-pow70.0%
sub-neg70.0%
metadata-eval70.0%
Simplified70.0%
Taylor expanded in t around 0 74.6%
Final simplification78.7%
(FPCore (x y z t a b) :precision binary64 (if (<= y -4.8e+167) (/ x (* b (* a (+ y (/ y b))))) (/ x (* a (* y (exp b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -4.8e+167) {
tmp = x / (b * (a * (y + (y / b))));
} else {
tmp = x / (a * (y * exp(b)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (y <= (-4.8d+167)) then
tmp = x / (b * (a * (y + (y / b))))
else
tmp = x / (a * (y * exp(b)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -4.8e+167) {
tmp = x / (b * (a * (y + (y / b))));
} else {
tmp = x / (a * (y * Math.exp(b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -4.8e+167: tmp = x / (b * (a * (y + (y / b)))) else: tmp = x / (a * (y * math.exp(b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -4.8e+167) tmp = Float64(x / Float64(b * Float64(a * Float64(y + Float64(y / b))))); else tmp = Float64(x / Float64(a * Float64(y * exp(b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (y <= -4.8e+167) tmp = x / (b * (a * (y + (y / b)))); else tmp = x / (a * (y * exp(b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -4.8e+167], N[(x / N[(b * N[(a * N[(y + N[(y / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(a * N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.8 \cdot 10^{+167}:\\
\;\;\;\;\frac{x}{b \cdot \left(a \cdot \left(y + \frac{y}{b}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y \cdot e^{b}\right)}\\
\end{array}
\end{array}
if y < -4.79999999999999998e167Initial program 100.0%
Taylor expanded in y around 0 36.9%
associate-/l*36.7%
div-exp21.7%
exp-to-pow21.7%
sub-neg21.7%
metadata-eval21.7%
Simplified21.7%
Taylor expanded in t around 0 17.1%
Taylor expanded in b around 0 41.7%
Taylor expanded in b around inf 46.7%
associate-/l*56.3%
distribute-lft-out61.3%
Simplified61.3%
if -4.79999999999999998e167 < y Initial program 97.4%
Taylor expanded in y around 0 83.0%
associate-/l*84.1%
div-exp72.3%
exp-to-pow73.2%
sub-neg73.2%
metadata-eval73.2%
Simplified73.2%
Taylor expanded in t around 0 63.9%
Final simplification63.7%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1
(/
x
(*
a
(+
y
(*
b
(+
y
(*
b
(+
(* y 0.5)
(*
b
(+
(* y 0.16666666666666666)
(*
b
(+
(* 0.008333333333333333 (* y b))
(* y 0.041666666666666664)))))))))))))
(t_2 (/ x (* a (* y b))))
(t_3 (/ x (* y a)))
(t_4 (/ x (* b (* a (+ y (/ y b)))))))
(if (<= b -1.65e+126)
(/
(*
x
(+
(/ 1.0 a)
(*
b
(+
(* b (+ (* (/ 1.0 a) 0.5) (* (/ b a) -0.16666666666666666)))
(/ -1.0 a)))))
y)
(if (<= b -4e-26)
t_1
(if (<= b -1.45e-157)
(* b (- t_2 t_3))
(if (<= b -6.4e-260)
t_4
(if (<= b 5.2e-224)
(/ (/ x a) y)
(if (<= b 4e-177)
(/ (- t_3 (/ (- t_3 t_2) b)) b)
(if (<= b 4.4e+18) t_4 t_1)))))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664)))))))))));
double t_2 = x / (a * (y * b));
double t_3 = x / (y * a);
double t_4 = x / (b * (a * (y + (y / b))));
double tmp;
if (b <= -1.65e+126) {
tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) + ((b / a) * -0.16666666666666666))) + (-1.0 / a))))) / y;
} else if (b <= -4e-26) {
tmp = t_1;
} else if (b <= -1.45e-157) {
tmp = b * (t_2 - t_3);
} else if (b <= -6.4e-260) {
tmp = t_4;
} else if (b <= 5.2e-224) {
tmp = (x / a) / y;
} else if (b <= 4e-177) {
tmp = (t_3 - ((t_3 - t_2) / b)) / b;
} else if (b <= 4.4e+18) {
tmp = t_4;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: t_4
real(8) :: tmp
t_1 = x / (a * (y + (b * (y + (b * ((y * 0.5d0) + (b * ((y * 0.16666666666666666d0) + (b * ((0.008333333333333333d0 * (y * b)) + (y * 0.041666666666666664d0)))))))))))
t_2 = x / (a * (y * b))
t_3 = x / (y * a)
t_4 = x / (b * (a * (y + (y / b))))
if (b <= (-1.65d+126)) then
tmp = (x * ((1.0d0 / a) + (b * ((b * (((1.0d0 / a) * 0.5d0) + ((b / a) * (-0.16666666666666666d0)))) + ((-1.0d0) / a))))) / y
else if (b <= (-4d-26)) then
tmp = t_1
else if (b <= (-1.45d-157)) then
tmp = b * (t_2 - t_3)
else if (b <= (-6.4d-260)) then
tmp = t_4
else if (b <= 5.2d-224) then
tmp = (x / a) / y
else if (b <= 4d-177) then
tmp = (t_3 - ((t_3 - t_2) / b)) / b
else if (b <= 4.4d+18) then
tmp = t_4
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 b) {
double t_1 = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664)))))))))));
double t_2 = x / (a * (y * b));
double t_3 = x / (y * a);
double t_4 = x / (b * (a * (y + (y / b))));
double tmp;
if (b <= -1.65e+126) {
tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) + ((b / a) * -0.16666666666666666))) + (-1.0 / a))))) / y;
} else if (b <= -4e-26) {
tmp = t_1;
} else if (b <= -1.45e-157) {
tmp = b * (t_2 - t_3);
} else if (b <= -6.4e-260) {
tmp = t_4;
} else if (b <= 5.2e-224) {
tmp = (x / a) / y;
} else if (b <= 4e-177) {
tmp = (t_3 - ((t_3 - t_2) / b)) / b;
} else if (b <= 4.4e+18) {
tmp = t_4;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664))))))))))) t_2 = x / (a * (y * b)) t_3 = x / (y * a) t_4 = x / (b * (a * (y + (y / b)))) tmp = 0 if b <= -1.65e+126: tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) + ((b / a) * -0.16666666666666666))) + (-1.0 / a))))) / y elif b <= -4e-26: tmp = t_1 elif b <= -1.45e-157: tmp = b * (t_2 - t_3) elif b <= -6.4e-260: tmp = t_4 elif b <= 5.2e-224: tmp = (x / a) / y elif b <= 4e-177: tmp = (t_3 - ((t_3 - t_2) / b)) / b elif b <= 4.4e+18: tmp = t_4 else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x / Float64(a * Float64(y + Float64(b * Float64(y + Float64(b * Float64(Float64(y * 0.5) + Float64(b * Float64(Float64(y * 0.16666666666666666) + Float64(b * Float64(Float64(0.008333333333333333 * Float64(y * b)) + Float64(y * 0.041666666666666664)))))))))))) t_2 = Float64(x / Float64(a * Float64(y * b))) t_3 = Float64(x / Float64(y * a)) t_4 = Float64(x / Float64(b * Float64(a * Float64(y + Float64(y / b))))) tmp = 0.0 if (b <= -1.65e+126) tmp = Float64(Float64(x * Float64(Float64(1.0 / a) + Float64(b * Float64(Float64(b * Float64(Float64(Float64(1.0 / a) * 0.5) + Float64(Float64(b / a) * -0.16666666666666666))) + Float64(-1.0 / a))))) / y); elseif (b <= -4e-26) tmp = t_1; elseif (b <= -1.45e-157) tmp = Float64(b * Float64(t_2 - t_3)); elseif (b <= -6.4e-260) tmp = t_4; elseif (b <= 5.2e-224) tmp = Float64(Float64(x / a) / y); elseif (b <= 4e-177) tmp = Float64(Float64(t_3 - Float64(Float64(t_3 - t_2) / b)) / b); elseif (b <= 4.4e+18) tmp = t_4; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664))))))))))); t_2 = x / (a * (y * b)); t_3 = x / (y * a); t_4 = x / (b * (a * (y + (y / b)))); tmp = 0.0; if (b <= -1.65e+126) tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) + ((b / a) * -0.16666666666666666))) + (-1.0 / a))))) / y; elseif (b <= -4e-26) tmp = t_1; elseif (b <= -1.45e-157) tmp = b * (t_2 - t_3); elseif (b <= -6.4e-260) tmp = t_4; elseif (b <= 5.2e-224) tmp = (x / a) / y; elseif (b <= 4e-177) tmp = (t_3 - ((t_3 - t_2) / b)) / b; elseif (b <= 4.4e+18) tmp = t_4; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x / N[(a * N[(y + N[(b * N[(y + N[(b * N[(N[(y * 0.5), $MachinePrecision] + N[(b * N[(N[(y * 0.16666666666666666), $MachinePrecision] + N[(b * N[(N[(0.008333333333333333 * N[(y * b), $MachinePrecision]), $MachinePrecision] + N[(y * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x / N[(a * N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(x / N[(y * a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(x / N[(b * N[(a * N[(y + N[(y / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -1.65e+126], N[(N[(x * N[(N[(1.0 / a), $MachinePrecision] + N[(b * N[(N[(b * N[(N[(N[(1.0 / a), $MachinePrecision] * 0.5), $MachinePrecision] + N[(N[(b / a), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-1.0 / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, -4e-26], t$95$1, If[LessEqual[b, -1.45e-157], N[(b * N[(t$95$2 - t$95$3), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, -6.4e-260], t$95$4, If[LessEqual[b, 5.2e-224], N[(N[(x / a), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, 4e-177], N[(N[(t$95$3 - N[(N[(t$95$3 - t$95$2), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision], If[LessEqual[b, 4.4e+18], t$95$4, t$95$1]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{a \cdot \left(y + b \cdot \left(y + b \cdot \left(y \cdot 0.5 + b \cdot \left(y \cdot 0.16666666666666666 + b \cdot \left(0.008333333333333333 \cdot \left(y \cdot b\right) + y \cdot 0.041666666666666664\right)\right)\right)\right)\right)}\\
t_2 := \frac{x}{a \cdot \left(y \cdot b\right)}\\
t_3 := \frac{x}{y \cdot a}\\
t_4 := \frac{x}{b \cdot \left(a \cdot \left(y + \frac{y}{b}\right)\right)}\\
\mathbf{if}\;b \leq -1.65 \cdot 10^{+126}:\\
\;\;\;\;\frac{x \cdot \left(\frac{1}{a} + b \cdot \left(b \cdot \left(\frac{1}{a} \cdot 0.5 + \frac{b}{a} \cdot -0.16666666666666666\right) + \frac{-1}{a}\right)\right)}{y}\\
\mathbf{elif}\;b \leq -4 \cdot 10^{-26}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq -1.45 \cdot 10^{-157}:\\
\;\;\;\;b \cdot \left(t\_2 - t\_3\right)\\
\mathbf{elif}\;b \leq -6.4 \cdot 10^{-260}:\\
\;\;\;\;t\_4\\
\mathbf{elif}\;b \leq 5.2 \cdot 10^{-224}:\\
\;\;\;\;\frac{\frac{x}{a}}{y}\\
\mathbf{elif}\;b \leq 4 \cdot 10^{-177}:\\
\;\;\;\;\frac{t\_3 - \frac{t\_3 - t\_2}{b}}{b}\\
\mathbf{elif}\;b \leq 4.4 \cdot 10^{+18}:\\
\;\;\;\;t\_4\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -1.65000000000000006e126Initial program 100.0%
Taylor expanded in t around 0 93.0%
+-commutative93.0%
mul-1-neg93.0%
unsub-neg93.0%
Simplified93.0%
Taylor expanded in y around 0 85.9%
exp-neg85.9%
exp-sum85.9%
rem-exp-log85.9%
associate-/l/85.9%
Simplified85.9%
Taylor expanded in b around 0 85.9%
if -1.65000000000000006e126 < b < -4.0000000000000002e-26 or 4.4e18 < b Initial program 99.8%
Taylor expanded in y around 0 88.9%
associate-/l*88.9%
div-exp66.6%
exp-to-pow66.8%
sub-neg66.8%
metadata-eval66.8%
Simplified66.8%
Taylor expanded in t around 0 76.2%
Taylor expanded in b around 0 65.3%
if -4.0000000000000002e-26 < b < -1.44999999999999994e-157Initial program 98.3%
Taylor expanded in t around 0 58.6%
+-commutative58.6%
mul-1-neg58.6%
unsub-neg58.6%
Simplified58.6%
Taylor expanded in y around 0 45.2%
exp-neg45.2%
exp-sum45.2%
rem-exp-log46.8%
associate-/l/46.8%
Simplified46.8%
Taylor expanded in b around 0 46.8%
Taylor expanded in b around inf 50.0%
mul-1-neg50.0%
+-commutative50.0%
sub-neg50.0%
*-commutative50.0%
Simplified50.0%
if -1.44999999999999994e-157 < b < -6.3999999999999999e-260 or 3.99999999999999981e-177 < b < 4.4e18Initial program 94.2%
Taylor expanded in y around 0 63.0%
associate-/l*67.5%
div-exp64.1%
exp-to-pow65.2%
sub-neg65.2%
metadata-eval65.2%
Simplified65.2%
Taylor expanded in t around 0 39.7%
Taylor expanded in b around 0 40.0%
Taylor expanded in b around inf 46.5%
associate-/l*49.9%
distribute-lft-out51.8%
Simplified51.8%
if -6.3999999999999999e-260 < b < 5.2000000000000004e-224Initial program 94.0%
associate-/l*91.9%
associate--l+91.9%
exp-sum86.3%
associate-/l*83.5%
*-commutative83.5%
exp-to-pow83.5%
exp-diff83.5%
*-commutative83.5%
exp-to-pow86.3%
sub-neg86.3%
metadata-eval86.3%
Simplified86.3%
Taylor expanded in b around 0 88.4%
exp-to-pow91.6%
sub-neg91.6%
metadata-eval91.6%
Simplified91.6%
Taylor expanded in t around 0 83.6%
Taylor expanded in y around 0 56.9%
if 5.2000000000000004e-224 < b < 3.99999999999999981e-177Initial program 100.0%
Taylor expanded in y around 0 14.8%
associate-/l*14.8%
div-exp14.8%
exp-to-pow14.8%
sub-neg14.8%
metadata-eval14.8%
Simplified14.8%
Taylor expanded in t around 0 3.4%
Taylor expanded in b around 0 3.4%
Taylor expanded in b around -inf 39.9%
mul-1-neg39.9%
Simplified39.9%
Final simplification60.9%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ x (* y a))) (t_2 (/ x (* b (* a (+ y (/ y b)))))))
(if (<= b -1.75e-157)
(/
(*
x
(+
(/ 1.0 a)
(*
b
(+
(*
b
(-
(* (/ 1.0 a) 0.5)
(*
b
(-
(* (/ 1.0 a) 0.16666666666666666)
(* (/ b a) 0.041666666666666664)))))
(/ -1.0 a)))))
y)
(if (<= b -5e-263)
t_2
(if (<= b 2.9e-223)
(/ (/ x a) y)
(if (<= b 9.2e-176)
(/
(+
t_1
(/ (- (/ (+ t_1 (/ (- (/ x (* b (* y a))) t_1) b)) b) t_1) b))
b)
(if (<= b 6.6e+18)
t_2
(/
x
(*
a
(+
y
(*
b
(+
y
(*
b
(+
(* y 0.5)
(*
b
(+
(* y 0.16666666666666666)
(*
b
(+
(* 0.008333333333333333 (* y b))
(* y 0.041666666666666664)))))))))))))))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (y * a);
double t_2 = x / (b * (a * (y + (y / b))));
double tmp;
if (b <= -1.75e-157) {
tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) - (b * (((1.0 / a) * 0.16666666666666666) - ((b / a) * 0.041666666666666664))))) + (-1.0 / a))))) / y;
} else if (b <= -5e-263) {
tmp = t_2;
} else if (b <= 2.9e-223) {
tmp = (x / a) / y;
} else if (b <= 9.2e-176) {
tmp = (t_1 + ((((t_1 + (((x / (b * (y * a))) - t_1) / b)) / b) - t_1) / b)) / b;
} else if (b <= 6.6e+18) {
tmp = t_2;
} else {
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664)))))))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = x / (y * a)
t_2 = x / (b * (a * (y + (y / b))))
if (b <= (-1.75d-157)) then
tmp = (x * ((1.0d0 / a) + (b * ((b * (((1.0d0 / a) * 0.5d0) - (b * (((1.0d0 / a) * 0.16666666666666666d0) - ((b / a) * 0.041666666666666664d0))))) + ((-1.0d0) / a))))) / y
else if (b <= (-5d-263)) then
tmp = t_2
else if (b <= 2.9d-223) then
tmp = (x / a) / y
else if (b <= 9.2d-176) then
tmp = (t_1 + ((((t_1 + (((x / (b * (y * a))) - t_1) / b)) / b) - t_1) / b)) / b
else if (b <= 6.6d+18) then
tmp = t_2
else
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5d0) + (b * ((y * 0.16666666666666666d0) + (b * ((0.008333333333333333d0 * (y * b)) + (y * 0.041666666666666664d0)))))))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (y * a);
double t_2 = x / (b * (a * (y + (y / b))));
double tmp;
if (b <= -1.75e-157) {
tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) - (b * (((1.0 / a) * 0.16666666666666666) - ((b / a) * 0.041666666666666664))))) + (-1.0 / a))))) / y;
} else if (b <= -5e-263) {
tmp = t_2;
} else if (b <= 2.9e-223) {
tmp = (x / a) / y;
} else if (b <= 9.2e-176) {
tmp = (t_1 + ((((t_1 + (((x / (b * (y * a))) - t_1) / b)) / b) - t_1) / b)) / b;
} else if (b <= 6.6e+18) {
tmp = t_2;
} else {
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664)))))))))));
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x / (y * a) t_2 = x / (b * (a * (y + (y / b)))) tmp = 0 if b <= -1.75e-157: tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) - (b * (((1.0 / a) * 0.16666666666666666) - ((b / a) * 0.041666666666666664))))) + (-1.0 / a))))) / y elif b <= -5e-263: tmp = t_2 elif b <= 2.9e-223: tmp = (x / a) / y elif b <= 9.2e-176: tmp = (t_1 + ((((t_1 + (((x / (b * (y * a))) - t_1) / b)) / b) - t_1) / b)) / b elif b <= 6.6e+18: tmp = t_2 else: tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664))))))))))) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x / Float64(y * a)) t_2 = Float64(x / Float64(b * Float64(a * Float64(y + Float64(y / b))))) tmp = 0.0 if (b <= -1.75e-157) tmp = Float64(Float64(x * Float64(Float64(1.0 / a) + Float64(b * Float64(Float64(b * Float64(Float64(Float64(1.0 / a) * 0.5) - Float64(b * Float64(Float64(Float64(1.0 / a) * 0.16666666666666666) - Float64(Float64(b / a) * 0.041666666666666664))))) + Float64(-1.0 / a))))) / y); elseif (b <= -5e-263) tmp = t_2; elseif (b <= 2.9e-223) tmp = Float64(Float64(x / a) / y); elseif (b <= 9.2e-176) tmp = Float64(Float64(t_1 + Float64(Float64(Float64(Float64(t_1 + Float64(Float64(Float64(x / Float64(b * Float64(y * a))) - t_1) / b)) / b) - t_1) / b)) / b); elseif (b <= 6.6e+18) tmp = t_2; else tmp = Float64(x / Float64(a * Float64(y + Float64(b * Float64(y + Float64(b * Float64(Float64(y * 0.5) + Float64(b * Float64(Float64(y * 0.16666666666666666) + Float64(b * Float64(Float64(0.008333333333333333 * Float64(y * b)) + Float64(y * 0.041666666666666664)))))))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x / (y * a); t_2 = x / (b * (a * (y + (y / b)))); tmp = 0.0; if (b <= -1.75e-157) tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) - (b * (((1.0 / a) * 0.16666666666666666) - ((b / a) * 0.041666666666666664))))) + (-1.0 / a))))) / y; elseif (b <= -5e-263) tmp = t_2; elseif (b <= 2.9e-223) tmp = (x / a) / y; elseif (b <= 9.2e-176) tmp = (t_1 + ((((t_1 + (((x / (b * (y * a))) - t_1) / b)) / b) - t_1) / b)) / b; elseif (b <= 6.6e+18) tmp = t_2; else tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664))))))))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x / N[(y * a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x / N[(b * N[(a * N[(y + N[(y / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -1.75e-157], N[(N[(x * N[(N[(1.0 / a), $MachinePrecision] + N[(b * N[(N[(b * N[(N[(N[(1.0 / a), $MachinePrecision] * 0.5), $MachinePrecision] - N[(b * N[(N[(N[(1.0 / a), $MachinePrecision] * 0.16666666666666666), $MachinePrecision] - N[(N[(b / a), $MachinePrecision] * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-1.0 / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, -5e-263], t$95$2, If[LessEqual[b, 2.9e-223], N[(N[(x / a), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, 9.2e-176], N[(N[(t$95$1 + N[(N[(N[(N[(t$95$1 + N[(N[(N[(x / N[(b * N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t$95$1), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision] - t$95$1), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision], If[LessEqual[b, 6.6e+18], t$95$2, N[(x / N[(a * N[(y + N[(b * N[(y + N[(b * N[(N[(y * 0.5), $MachinePrecision] + N[(b * N[(N[(y * 0.16666666666666666), $MachinePrecision] + N[(b * N[(N[(0.008333333333333333 * N[(y * b), $MachinePrecision]), $MachinePrecision] + N[(y * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{y \cdot a}\\
t_2 := \frac{x}{b \cdot \left(a \cdot \left(y + \frac{y}{b}\right)\right)}\\
\mathbf{if}\;b \leq -1.75 \cdot 10^{-157}:\\
\;\;\;\;\frac{x \cdot \left(\frac{1}{a} + b \cdot \left(b \cdot \left(\frac{1}{a} \cdot 0.5 - b \cdot \left(\frac{1}{a} \cdot 0.16666666666666666 - \frac{b}{a} \cdot 0.041666666666666664\right)\right) + \frac{-1}{a}\right)\right)}{y}\\
\mathbf{elif}\;b \leq -5 \cdot 10^{-263}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;b \leq 2.9 \cdot 10^{-223}:\\
\;\;\;\;\frac{\frac{x}{a}}{y}\\
\mathbf{elif}\;b \leq 9.2 \cdot 10^{-176}:\\
\;\;\;\;\frac{t\_1 + \frac{\frac{t\_1 + \frac{\frac{x}{b \cdot \left(y \cdot a\right)} - t\_1}{b}}{b} - t\_1}{b}}{b}\\
\mathbf{elif}\;b \leq 6.6 \cdot 10^{+18}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y + b \cdot \left(y + b \cdot \left(y \cdot 0.5 + b \cdot \left(y \cdot 0.16666666666666666 + b \cdot \left(0.008333333333333333 \cdot \left(y \cdot b\right) + y \cdot 0.041666666666666664\right)\right)\right)\right)\right)}\\
\end{array}
\end{array}
if b < -1.7500000000000001e-157Initial program 99.3%
Taylor expanded in t around 0 77.4%
+-commutative77.4%
mul-1-neg77.4%
unsub-neg77.4%
Simplified77.4%
Taylor expanded in y around 0 61.0%
exp-neg61.0%
exp-sum60.9%
rem-exp-log61.7%
associate-/l/61.7%
Simplified61.7%
Taylor expanded in b around 0 56.5%
if -1.7500000000000001e-157 < b < -5.00000000000000006e-263 or 9.2000000000000005e-176 < b < 6.6e18Initial program 94.2%
Taylor expanded in y around 0 63.0%
associate-/l*67.5%
div-exp64.1%
exp-to-pow65.2%
sub-neg65.2%
metadata-eval65.2%
Simplified65.2%
Taylor expanded in t around 0 39.7%
Taylor expanded in b around 0 40.0%
Taylor expanded in b around inf 46.5%
associate-/l*49.9%
distribute-lft-out51.8%
Simplified51.8%
if -5.00000000000000006e-263 < b < 2.9e-223Initial program 94.0%
associate-/l*91.9%
associate--l+91.9%
exp-sum86.3%
associate-/l*83.5%
*-commutative83.5%
exp-to-pow83.5%
exp-diff83.5%
*-commutative83.5%
exp-to-pow86.3%
sub-neg86.3%
metadata-eval86.3%
Simplified86.3%
Taylor expanded in b around 0 88.4%
exp-to-pow91.6%
sub-neg91.6%
metadata-eval91.6%
Simplified91.6%
Taylor expanded in t around 0 83.6%
Taylor expanded in y around 0 56.9%
if 2.9e-223 < b < 9.2000000000000005e-176Initial program 100.0%
Taylor expanded in y around 0 14.8%
associate-/l*14.8%
div-exp14.8%
exp-to-pow14.8%
sub-neg14.8%
metadata-eval14.8%
Simplified14.8%
Taylor expanded in t around 0 3.4%
Taylor expanded in b around 0 3.4%
Taylor expanded in b around -inf 63.1%
Simplified50.8%
if 6.6e18 < b Initial program 100.0%
Taylor expanded in y around 0 92.2%
associate-/l*92.2%
div-exp69.9%
exp-to-pow69.9%
sub-neg69.9%
metadata-eval69.9%
Simplified69.9%
Taylor expanded in t around 0 87.5%
Taylor expanded in b around 0 75.4%
Final simplification60.0%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ x (* y a))) (t_2 (/ x (* b (* a (+ y (/ y b)))))))
(if (<= b -1.35e-162)
(/
(*
x
(+
(/ 1.0 a)
(*
b
(+
(*
b
(-
(* (/ 1.0 a) 0.5)
(*
b
(-
(* (/ 1.0 a) 0.16666666666666666)
(* (/ b a) 0.041666666666666664)))))
(/ -1.0 a)))))
y)
(if (<= b -1.75e-261)
t_2
(if (<= b 3.2e-223)
(/ (/ x a) y)
(if (<= b 4.2e-177)
(/
(-
t_1
(/ (+ t_1 (/ (- (/ (- t_1 (/ x (* a (* y b)))) b) t_1) b)) b))
b)
(if (<= b 4.3e+18)
t_2
(/
x
(*
a
(+
y
(*
b
(+
y
(*
b
(+
(* y 0.5)
(*
b
(+
(* y 0.16666666666666666)
(*
b
(+
(* 0.008333333333333333 (* y b))
(* y 0.041666666666666664)))))))))))))))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (y * a);
double t_2 = x / (b * (a * (y + (y / b))));
double tmp;
if (b <= -1.35e-162) {
tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) - (b * (((1.0 / a) * 0.16666666666666666) - ((b / a) * 0.041666666666666664))))) + (-1.0 / a))))) / y;
} else if (b <= -1.75e-261) {
tmp = t_2;
} else if (b <= 3.2e-223) {
tmp = (x / a) / y;
} else if (b <= 4.2e-177) {
tmp = (t_1 - ((t_1 + ((((t_1 - (x / (a * (y * b)))) / b) - t_1) / b)) / b)) / b;
} else if (b <= 4.3e+18) {
tmp = t_2;
} else {
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664)))))))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = x / (y * a)
t_2 = x / (b * (a * (y + (y / b))))
if (b <= (-1.35d-162)) then
tmp = (x * ((1.0d0 / a) + (b * ((b * (((1.0d0 / a) * 0.5d0) - (b * (((1.0d0 / a) * 0.16666666666666666d0) - ((b / a) * 0.041666666666666664d0))))) + ((-1.0d0) / a))))) / y
else if (b <= (-1.75d-261)) then
tmp = t_2
else if (b <= 3.2d-223) then
tmp = (x / a) / y
else if (b <= 4.2d-177) then
tmp = (t_1 - ((t_1 + ((((t_1 - (x / (a * (y * b)))) / b) - t_1) / b)) / b)) / b
else if (b <= 4.3d+18) then
tmp = t_2
else
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5d0) + (b * ((y * 0.16666666666666666d0) + (b * ((0.008333333333333333d0 * (y * b)) + (y * 0.041666666666666664d0)))))))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (y * a);
double t_2 = x / (b * (a * (y + (y / b))));
double tmp;
if (b <= -1.35e-162) {
tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) - (b * (((1.0 / a) * 0.16666666666666666) - ((b / a) * 0.041666666666666664))))) + (-1.0 / a))))) / y;
} else if (b <= -1.75e-261) {
tmp = t_2;
} else if (b <= 3.2e-223) {
tmp = (x / a) / y;
} else if (b <= 4.2e-177) {
tmp = (t_1 - ((t_1 + ((((t_1 - (x / (a * (y * b)))) / b) - t_1) / b)) / b)) / b;
} else if (b <= 4.3e+18) {
tmp = t_2;
} else {
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664)))))))))));
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x / (y * a) t_2 = x / (b * (a * (y + (y / b)))) tmp = 0 if b <= -1.35e-162: tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) - (b * (((1.0 / a) * 0.16666666666666666) - ((b / a) * 0.041666666666666664))))) + (-1.0 / a))))) / y elif b <= -1.75e-261: tmp = t_2 elif b <= 3.2e-223: tmp = (x / a) / y elif b <= 4.2e-177: tmp = (t_1 - ((t_1 + ((((t_1 - (x / (a * (y * b)))) / b) - t_1) / b)) / b)) / b elif b <= 4.3e+18: tmp = t_2 else: tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664))))))))))) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x / Float64(y * a)) t_2 = Float64(x / Float64(b * Float64(a * Float64(y + Float64(y / b))))) tmp = 0.0 if (b <= -1.35e-162) tmp = Float64(Float64(x * Float64(Float64(1.0 / a) + Float64(b * Float64(Float64(b * Float64(Float64(Float64(1.0 / a) * 0.5) - Float64(b * Float64(Float64(Float64(1.0 / a) * 0.16666666666666666) - Float64(Float64(b / a) * 0.041666666666666664))))) + Float64(-1.0 / a))))) / y); elseif (b <= -1.75e-261) tmp = t_2; elseif (b <= 3.2e-223) tmp = Float64(Float64(x / a) / y); elseif (b <= 4.2e-177) tmp = Float64(Float64(t_1 - Float64(Float64(t_1 + Float64(Float64(Float64(Float64(t_1 - Float64(x / Float64(a * Float64(y * b)))) / b) - t_1) / b)) / b)) / b); elseif (b <= 4.3e+18) tmp = t_2; else tmp = Float64(x / Float64(a * Float64(y + Float64(b * Float64(y + Float64(b * Float64(Float64(y * 0.5) + Float64(b * Float64(Float64(y * 0.16666666666666666) + Float64(b * Float64(Float64(0.008333333333333333 * Float64(y * b)) + Float64(y * 0.041666666666666664)))))))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x / (y * a); t_2 = x / (b * (a * (y + (y / b)))); tmp = 0.0; if (b <= -1.35e-162) tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) - (b * (((1.0 / a) * 0.16666666666666666) - ((b / a) * 0.041666666666666664))))) + (-1.0 / a))))) / y; elseif (b <= -1.75e-261) tmp = t_2; elseif (b <= 3.2e-223) tmp = (x / a) / y; elseif (b <= 4.2e-177) tmp = (t_1 - ((t_1 + ((((t_1 - (x / (a * (y * b)))) / b) - t_1) / b)) / b)) / b; elseif (b <= 4.3e+18) tmp = t_2; else tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664))))))))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x / N[(y * a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x / N[(b * N[(a * N[(y + N[(y / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -1.35e-162], N[(N[(x * N[(N[(1.0 / a), $MachinePrecision] + N[(b * N[(N[(b * N[(N[(N[(1.0 / a), $MachinePrecision] * 0.5), $MachinePrecision] - N[(b * N[(N[(N[(1.0 / a), $MachinePrecision] * 0.16666666666666666), $MachinePrecision] - N[(N[(b / a), $MachinePrecision] * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-1.0 / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, -1.75e-261], t$95$2, If[LessEqual[b, 3.2e-223], N[(N[(x / a), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, 4.2e-177], N[(N[(t$95$1 - N[(N[(t$95$1 + N[(N[(N[(N[(t$95$1 - N[(x / N[(a * N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision] - t$95$1), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision], If[LessEqual[b, 4.3e+18], t$95$2, N[(x / N[(a * N[(y + N[(b * N[(y + N[(b * N[(N[(y * 0.5), $MachinePrecision] + N[(b * N[(N[(y * 0.16666666666666666), $MachinePrecision] + N[(b * N[(N[(0.008333333333333333 * N[(y * b), $MachinePrecision]), $MachinePrecision] + N[(y * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{y \cdot a}\\
t_2 := \frac{x}{b \cdot \left(a \cdot \left(y + \frac{y}{b}\right)\right)}\\
\mathbf{if}\;b \leq -1.35 \cdot 10^{-162}:\\
\;\;\;\;\frac{x \cdot \left(\frac{1}{a} + b \cdot \left(b \cdot \left(\frac{1}{a} \cdot 0.5 - b \cdot \left(\frac{1}{a} \cdot 0.16666666666666666 - \frac{b}{a} \cdot 0.041666666666666664\right)\right) + \frac{-1}{a}\right)\right)}{y}\\
\mathbf{elif}\;b \leq -1.75 \cdot 10^{-261}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;b \leq 3.2 \cdot 10^{-223}:\\
\;\;\;\;\frac{\frac{x}{a}}{y}\\
\mathbf{elif}\;b \leq 4.2 \cdot 10^{-177}:\\
\;\;\;\;\frac{t\_1 - \frac{t\_1 + \frac{\frac{t\_1 - \frac{x}{a \cdot \left(y \cdot b\right)}}{b} - t\_1}{b}}{b}}{b}\\
\mathbf{elif}\;b \leq 4.3 \cdot 10^{+18}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y + b \cdot \left(y + b \cdot \left(y \cdot 0.5 + b \cdot \left(y \cdot 0.16666666666666666 + b \cdot \left(0.008333333333333333 \cdot \left(y \cdot b\right) + y \cdot 0.041666666666666664\right)\right)\right)\right)\right)}\\
\end{array}
\end{array}
if b < -1.34999999999999992e-162Initial program 99.3%
Taylor expanded in t around 0 77.4%
+-commutative77.4%
mul-1-neg77.4%
unsub-neg77.4%
Simplified77.4%
Taylor expanded in y around 0 61.0%
exp-neg61.0%
exp-sum60.9%
rem-exp-log61.7%
associate-/l/61.7%
Simplified61.7%
Taylor expanded in b around 0 56.5%
if -1.34999999999999992e-162 < b < -1.7499999999999999e-261 or 4.20000000000000002e-177 < b < 4.3e18Initial program 94.2%
Taylor expanded in y around 0 63.0%
associate-/l*67.5%
div-exp64.1%
exp-to-pow65.2%
sub-neg65.2%
metadata-eval65.2%
Simplified65.2%
Taylor expanded in t around 0 39.7%
Taylor expanded in b around 0 40.0%
Taylor expanded in b around inf 46.5%
associate-/l*49.9%
distribute-lft-out51.8%
Simplified51.8%
if -1.7499999999999999e-261 < b < 3.2000000000000001e-223Initial program 94.0%
associate-/l*91.9%
associate--l+91.9%
exp-sum86.3%
associate-/l*83.5%
*-commutative83.5%
exp-to-pow83.5%
exp-diff83.5%
*-commutative83.5%
exp-to-pow86.3%
sub-neg86.3%
metadata-eval86.3%
Simplified86.3%
Taylor expanded in b around 0 88.4%
exp-to-pow91.6%
sub-neg91.6%
metadata-eval91.6%
Simplified91.6%
Taylor expanded in t around 0 83.6%
Taylor expanded in y around 0 56.9%
if 3.2000000000000001e-223 < b < 4.20000000000000002e-177Initial program 100.0%
Taylor expanded in y around 0 14.8%
associate-/l*14.8%
div-exp14.8%
exp-to-pow14.8%
sub-neg14.8%
metadata-eval14.8%
Simplified14.8%
Taylor expanded in t around 0 3.4%
Taylor expanded in b around 0 3.4%
Taylor expanded in b around -inf 63.1%
Simplified63.1%
if 4.3e18 < b Initial program 100.0%
Taylor expanded in y around 0 92.2%
associate-/l*92.2%
div-exp69.9%
exp-to-pow69.9%
sub-neg69.9%
metadata-eval69.9%
Simplified69.9%
Taylor expanded in t around 0 87.5%
Taylor expanded in b around 0 75.4%
Final simplification60.4%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ x (* y a))) (t_2 (/ x (* b (* a (+ y (/ y b)))))))
(if (<= b -2e-161)
(/
(*
x
(-
(/ 1.0 a)
(*
b
(+
(/ 1.0 a)
(*
b
(+
(*
b
(+
(* (/ 1.0 a) 0.16666666666666666)
(*
b
(-
(* 0.041666666666666664 (/ -1.0 a))
(* -0.008333333333333333 (/ b a))))))
(* 0.5 (/ -1.0 a))))))))
y)
(if (<= b -1e-264)
t_2
(if (<= b 2.1e-223)
(/ (/ x a) y)
(if (<= b 4e-177)
(/
(-
t_1
(/ (+ t_1 (/ (- (/ (- t_1 (/ x (* a (* y b)))) b) t_1) b)) b))
b)
(if (<= b 1.5e+19)
t_2
(/
x
(*
a
(+
y
(*
b
(+
y
(*
b
(+
(* y 0.5)
(*
b
(+
(* y 0.16666666666666666)
(*
b
(+
(* 0.008333333333333333 (* y b))
(* y 0.041666666666666664)))))))))))))))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (y * a);
double t_2 = x / (b * (a * (y + (y / b))));
double tmp;
if (b <= -2e-161) {
tmp = (x * ((1.0 / a) - (b * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.16666666666666666) + (b * ((0.041666666666666664 * (-1.0 / a)) - (-0.008333333333333333 * (b / a)))))) + (0.5 * (-1.0 / a)))))))) / y;
} else if (b <= -1e-264) {
tmp = t_2;
} else if (b <= 2.1e-223) {
tmp = (x / a) / y;
} else if (b <= 4e-177) {
tmp = (t_1 - ((t_1 + ((((t_1 - (x / (a * (y * b)))) / b) - t_1) / b)) / b)) / b;
} else if (b <= 1.5e+19) {
tmp = t_2;
} else {
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664)))))))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = x / (y * a)
t_2 = x / (b * (a * (y + (y / b))))
if (b <= (-2d-161)) then
tmp = (x * ((1.0d0 / a) - (b * ((1.0d0 / a) + (b * ((b * (((1.0d0 / a) * 0.16666666666666666d0) + (b * ((0.041666666666666664d0 * ((-1.0d0) / a)) - ((-0.008333333333333333d0) * (b / a)))))) + (0.5d0 * ((-1.0d0) / a)))))))) / y
else if (b <= (-1d-264)) then
tmp = t_2
else if (b <= 2.1d-223) then
tmp = (x / a) / y
else if (b <= 4d-177) then
tmp = (t_1 - ((t_1 + ((((t_1 - (x / (a * (y * b)))) / b) - t_1) / b)) / b)) / b
else if (b <= 1.5d+19) then
tmp = t_2
else
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5d0) + (b * ((y * 0.16666666666666666d0) + (b * ((0.008333333333333333d0 * (y * b)) + (y * 0.041666666666666664d0)))))))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (y * a);
double t_2 = x / (b * (a * (y + (y / b))));
double tmp;
if (b <= -2e-161) {
tmp = (x * ((1.0 / a) - (b * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.16666666666666666) + (b * ((0.041666666666666664 * (-1.0 / a)) - (-0.008333333333333333 * (b / a)))))) + (0.5 * (-1.0 / a)))))))) / y;
} else if (b <= -1e-264) {
tmp = t_2;
} else if (b <= 2.1e-223) {
tmp = (x / a) / y;
} else if (b <= 4e-177) {
tmp = (t_1 - ((t_1 + ((((t_1 - (x / (a * (y * b)))) / b) - t_1) / b)) / b)) / b;
} else if (b <= 1.5e+19) {
tmp = t_2;
} else {
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664)))))))))));
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x / (y * a) t_2 = x / (b * (a * (y + (y / b)))) tmp = 0 if b <= -2e-161: tmp = (x * ((1.0 / a) - (b * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.16666666666666666) + (b * ((0.041666666666666664 * (-1.0 / a)) - (-0.008333333333333333 * (b / a)))))) + (0.5 * (-1.0 / a)))))))) / y elif b <= -1e-264: tmp = t_2 elif b <= 2.1e-223: tmp = (x / a) / y elif b <= 4e-177: tmp = (t_1 - ((t_1 + ((((t_1 - (x / (a * (y * b)))) / b) - t_1) / b)) / b)) / b elif b <= 1.5e+19: tmp = t_2 else: tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664))))))))))) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x / Float64(y * a)) t_2 = Float64(x / Float64(b * Float64(a * Float64(y + Float64(y / b))))) tmp = 0.0 if (b <= -2e-161) tmp = Float64(Float64(x * Float64(Float64(1.0 / a) - Float64(b * Float64(Float64(1.0 / a) + Float64(b * Float64(Float64(b * Float64(Float64(Float64(1.0 / a) * 0.16666666666666666) + Float64(b * Float64(Float64(0.041666666666666664 * Float64(-1.0 / a)) - Float64(-0.008333333333333333 * Float64(b / a)))))) + Float64(0.5 * Float64(-1.0 / a)))))))) / y); elseif (b <= -1e-264) tmp = t_2; elseif (b <= 2.1e-223) tmp = Float64(Float64(x / a) / y); elseif (b <= 4e-177) tmp = Float64(Float64(t_1 - Float64(Float64(t_1 + Float64(Float64(Float64(Float64(t_1 - Float64(x / Float64(a * Float64(y * b)))) / b) - t_1) / b)) / b)) / b); elseif (b <= 1.5e+19) tmp = t_2; else tmp = Float64(x / Float64(a * Float64(y + Float64(b * Float64(y + Float64(b * Float64(Float64(y * 0.5) + Float64(b * Float64(Float64(y * 0.16666666666666666) + Float64(b * Float64(Float64(0.008333333333333333 * Float64(y * b)) + Float64(y * 0.041666666666666664)))))))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x / (y * a); t_2 = x / (b * (a * (y + (y / b)))); tmp = 0.0; if (b <= -2e-161) tmp = (x * ((1.0 / a) - (b * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.16666666666666666) + (b * ((0.041666666666666664 * (-1.0 / a)) - (-0.008333333333333333 * (b / a)))))) + (0.5 * (-1.0 / a)))))))) / y; elseif (b <= -1e-264) tmp = t_2; elseif (b <= 2.1e-223) tmp = (x / a) / y; elseif (b <= 4e-177) tmp = (t_1 - ((t_1 + ((((t_1 - (x / (a * (y * b)))) / b) - t_1) / b)) / b)) / b; elseif (b <= 1.5e+19) tmp = t_2; else tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664))))))))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x / N[(y * a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x / N[(b * N[(a * N[(y + N[(y / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -2e-161], N[(N[(x * N[(N[(1.0 / a), $MachinePrecision] - N[(b * N[(N[(1.0 / a), $MachinePrecision] + N[(b * N[(N[(b * N[(N[(N[(1.0 / a), $MachinePrecision] * 0.16666666666666666), $MachinePrecision] + N[(b * N[(N[(0.041666666666666664 * N[(-1.0 / a), $MachinePrecision]), $MachinePrecision] - N[(-0.008333333333333333 * N[(b / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(0.5 * N[(-1.0 / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, -1e-264], t$95$2, If[LessEqual[b, 2.1e-223], N[(N[(x / a), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, 4e-177], N[(N[(t$95$1 - N[(N[(t$95$1 + N[(N[(N[(N[(t$95$1 - N[(x / N[(a * N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision] - t$95$1), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision], If[LessEqual[b, 1.5e+19], t$95$2, N[(x / N[(a * N[(y + N[(b * N[(y + N[(b * N[(N[(y * 0.5), $MachinePrecision] + N[(b * N[(N[(y * 0.16666666666666666), $MachinePrecision] + N[(b * N[(N[(0.008333333333333333 * N[(y * b), $MachinePrecision]), $MachinePrecision] + N[(y * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{y \cdot a}\\
t_2 := \frac{x}{b \cdot \left(a \cdot \left(y + \frac{y}{b}\right)\right)}\\
\mathbf{if}\;b \leq -2 \cdot 10^{-161}:\\
\;\;\;\;\frac{x \cdot \left(\frac{1}{a} - b \cdot \left(\frac{1}{a} + b \cdot \left(b \cdot \left(\frac{1}{a} \cdot 0.16666666666666666 + b \cdot \left(0.041666666666666664 \cdot \frac{-1}{a} - -0.008333333333333333 \cdot \frac{b}{a}\right)\right) + 0.5 \cdot \frac{-1}{a}\right)\right)\right)}{y}\\
\mathbf{elif}\;b \leq -1 \cdot 10^{-264}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;b \leq 2.1 \cdot 10^{-223}:\\
\;\;\;\;\frac{\frac{x}{a}}{y}\\
\mathbf{elif}\;b \leq 4 \cdot 10^{-177}:\\
\;\;\;\;\frac{t\_1 - \frac{t\_1 + \frac{\frac{t\_1 - \frac{x}{a \cdot \left(y \cdot b\right)}}{b} - t\_1}{b}}{b}}{b}\\
\mathbf{elif}\;b \leq 1.5 \cdot 10^{+19}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y + b \cdot \left(y + b \cdot \left(y \cdot 0.5 + b \cdot \left(y \cdot 0.16666666666666666 + b \cdot \left(0.008333333333333333 \cdot \left(y \cdot b\right) + y \cdot 0.041666666666666664\right)\right)\right)\right)\right)}\\
\end{array}
\end{array}
if b < -2.00000000000000006e-161Initial program 99.3%
Taylor expanded in t around 0 77.4%
+-commutative77.4%
mul-1-neg77.4%
unsub-neg77.4%
Simplified77.4%
Taylor expanded in y around 0 61.0%
exp-neg61.0%
exp-sum60.9%
rem-exp-log61.7%
associate-/l/61.7%
Simplified61.7%
Taylor expanded in b around 0 58.6%
if -2.00000000000000006e-161 < b < -1e-264 or 3.99999999999999981e-177 < b < 1.5e19Initial program 94.2%
Taylor expanded in y around 0 63.0%
associate-/l*67.5%
div-exp64.1%
exp-to-pow65.2%
sub-neg65.2%
metadata-eval65.2%
Simplified65.2%
Taylor expanded in t around 0 39.7%
Taylor expanded in b around 0 40.0%
Taylor expanded in b around inf 46.5%
associate-/l*49.9%
distribute-lft-out51.8%
Simplified51.8%
if -1e-264 < b < 2.09999999999999982e-223Initial program 94.0%
associate-/l*91.9%
associate--l+91.9%
exp-sum86.3%
associate-/l*83.5%
*-commutative83.5%
exp-to-pow83.5%
exp-diff83.5%
*-commutative83.5%
exp-to-pow86.3%
sub-neg86.3%
metadata-eval86.3%
Simplified86.3%
Taylor expanded in b around 0 88.4%
exp-to-pow91.6%
sub-neg91.6%
metadata-eval91.6%
Simplified91.6%
Taylor expanded in t around 0 83.6%
Taylor expanded in y around 0 56.9%
if 2.09999999999999982e-223 < b < 3.99999999999999981e-177Initial program 100.0%
Taylor expanded in y around 0 14.8%
associate-/l*14.8%
div-exp14.8%
exp-to-pow14.8%
sub-neg14.8%
metadata-eval14.8%
Simplified14.8%
Taylor expanded in t around 0 3.4%
Taylor expanded in b around 0 3.4%
Taylor expanded in b around -inf 63.1%
Simplified63.1%
if 1.5e19 < b Initial program 100.0%
Taylor expanded in y around 0 92.2%
associate-/l*92.2%
div-exp69.9%
exp-to-pow69.9%
sub-neg69.9%
metadata-eval69.9%
Simplified69.9%
Taylor expanded in t around 0 87.5%
Taylor expanded in b around 0 75.4%
Final simplification61.1%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ x (* y a))) (t_2 (/ x (* b (* a (+ y (/ y b)))))))
(if (<= b -1.4e-155)
(/
(*
x
(+
(/ 1.0 a)
(*
b
(+
(*
b
(-
(* (/ 1.0 a) 0.5)
(*
b
(-
(* (/ 1.0 a) 0.16666666666666666)
(* (/ b a) 0.041666666666666664)))))
(/ -1.0 a)))))
y)
(if (<= b -1.35e-262)
t_2
(if (<= b 8.2e-224)
(/ (/ x a) y)
(if (<= b 4.8e-177)
(/ (- t_1 (/ (- t_1 (/ x (* a (* y b)))) b)) b)
(if (<= b 6.8e+18)
t_2
(/
x
(*
a
(+
y
(*
b
(+
y
(*
b
(+
(* y 0.5)
(*
b
(+
(* y 0.16666666666666666)
(*
b
(+
(* 0.008333333333333333 (* y b))
(* y 0.041666666666666664)))))))))))))))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (y * a);
double t_2 = x / (b * (a * (y + (y / b))));
double tmp;
if (b <= -1.4e-155) {
tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) - (b * (((1.0 / a) * 0.16666666666666666) - ((b / a) * 0.041666666666666664))))) + (-1.0 / a))))) / y;
} else if (b <= -1.35e-262) {
tmp = t_2;
} else if (b <= 8.2e-224) {
tmp = (x / a) / y;
} else if (b <= 4.8e-177) {
tmp = (t_1 - ((t_1 - (x / (a * (y * b)))) / b)) / b;
} else if (b <= 6.8e+18) {
tmp = t_2;
} else {
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664)))))))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = x / (y * a)
t_2 = x / (b * (a * (y + (y / b))))
if (b <= (-1.4d-155)) then
tmp = (x * ((1.0d0 / a) + (b * ((b * (((1.0d0 / a) * 0.5d0) - (b * (((1.0d0 / a) * 0.16666666666666666d0) - ((b / a) * 0.041666666666666664d0))))) + ((-1.0d0) / a))))) / y
else if (b <= (-1.35d-262)) then
tmp = t_2
else if (b <= 8.2d-224) then
tmp = (x / a) / y
else if (b <= 4.8d-177) then
tmp = (t_1 - ((t_1 - (x / (a * (y * b)))) / b)) / b
else if (b <= 6.8d+18) then
tmp = t_2
else
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5d0) + (b * ((y * 0.16666666666666666d0) + (b * ((0.008333333333333333d0 * (y * b)) + (y * 0.041666666666666664d0)))))))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (y * a);
double t_2 = x / (b * (a * (y + (y / b))));
double tmp;
if (b <= -1.4e-155) {
tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) - (b * (((1.0 / a) * 0.16666666666666666) - ((b / a) * 0.041666666666666664))))) + (-1.0 / a))))) / y;
} else if (b <= -1.35e-262) {
tmp = t_2;
} else if (b <= 8.2e-224) {
tmp = (x / a) / y;
} else if (b <= 4.8e-177) {
tmp = (t_1 - ((t_1 - (x / (a * (y * b)))) / b)) / b;
} else if (b <= 6.8e+18) {
tmp = t_2;
} else {
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664)))))))))));
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x / (y * a) t_2 = x / (b * (a * (y + (y / b)))) tmp = 0 if b <= -1.4e-155: tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) - (b * (((1.0 / a) * 0.16666666666666666) - ((b / a) * 0.041666666666666664))))) + (-1.0 / a))))) / y elif b <= -1.35e-262: tmp = t_2 elif b <= 8.2e-224: tmp = (x / a) / y elif b <= 4.8e-177: tmp = (t_1 - ((t_1 - (x / (a * (y * b)))) / b)) / b elif b <= 6.8e+18: tmp = t_2 else: tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664))))))))))) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x / Float64(y * a)) t_2 = Float64(x / Float64(b * Float64(a * Float64(y + Float64(y / b))))) tmp = 0.0 if (b <= -1.4e-155) tmp = Float64(Float64(x * Float64(Float64(1.0 / a) + Float64(b * Float64(Float64(b * Float64(Float64(Float64(1.0 / a) * 0.5) - Float64(b * Float64(Float64(Float64(1.0 / a) * 0.16666666666666666) - Float64(Float64(b / a) * 0.041666666666666664))))) + Float64(-1.0 / a))))) / y); elseif (b <= -1.35e-262) tmp = t_2; elseif (b <= 8.2e-224) tmp = Float64(Float64(x / a) / y); elseif (b <= 4.8e-177) tmp = Float64(Float64(t_1 - Float64(Float64(t_1 - Float64(x / Float64(a * Float64(y * b)))) / b)) / b); elseif (b <= 6.8e+18) tmp = t_2; else tmp = Float64(x / Float64(a * Float64(y + Float64(b * Float64(y + Float64(b * Float64(Float64(y * 0.5) + Float64(b * Float64(Float64(y * 0.16666666666666666) + Float64(b * Float64(Float64(0.008333333333333333 * Float64(y * b)) + Float64(y * 0.041666666666666664)))))))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x / (y * a); t_2 = x / (b * (a * (y + (y / b)))); tmp = 0.0; if (b <= -1.4e-155) tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) - (b * (((1.0 / a) * 0.16666666666666666) - ((b / a) * 0.041666666666666664))))) + (-1.0 / a))))) / y; elseif (b <= -1.35e-262) tmp = t_2; elseif (b <= 8.2e-224) tmp = (x / a) / y; elseif (b <= 4.8e-177) tmp = (t_1 - ((t_1 - (x / (a * (y * b)))) / b)) / b; elseif (b <= 6.8e+18) tmp = t_2; else tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (b * ((0.008333333333333333 * (y * b)) + (y * 0.041666666666666664))))))))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x / N[(y * a), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x / N[(b * N[(a * N[(y + N[(y / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -1.4e-155], N[(N[(x * N[(N[(1.0 / a), $MachinePrecision] + N[(b * N[(N[(b * N[(N[(N[(1.0 / a), $MachinePrecision] * 0.5), $MachinePrecision] - N[(b * N[(N[(N[(1.0 / a), $MachinePrecision] * 0.16666666666666666), $MachinePrecision] - N[(N[(b / a), $MachinePrecision] * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-1.0 / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, -1.35e-262], t$95$2, If[LessEqual[b, 8.2e-224], N[(N[(x / a), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, 4.8e-177], N[(N[(t$95$1 - N[(N[(t$95$1 - N[(x / N[(a * N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision], If[LessEqual[b, 6.8e+18], t$95$2, N[(x / N[(a * N[(y + N[(b * N[(y + N[(b * N[(N[(y * 0.5), $MachinePrecision] + N[(b * N[(N[(y * 0.16666666666666666), $MachinePrecision] + N[(b * N[(N[(0.008333333333333333 * N[(y * b), $MachinePrecision]), $MachinePrecision] + N[(y * 0.041666666666666664), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{y \cdot a}\\
t_2 := \frac{x}{b \cdot \left(a \cdot \left(y + \frac{y}{b}\right)\right)}\\
\mathbf{if}\;b \leq -1.4 \cdot 10^{-155}:\\
\;\;\;\;\frac{x \cdot \left(\frac{1}{a} + b \cdot \left(b \cdot \left(\frac{1}{a} \cdot 0.5 - b \cdot \left(\frac{1}{a} \cdot 0.16666666666666666 - \frac{b}{a} \cdot 0.041666666666666664\right)\right) + \frac{-1}{a}\right)\right)}{y}\\
\mathbf{elif}\;b \leq -1.35 \cdot 10^{-262}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;b \leq 8.2 \cdot 10^{-224}:\\
\;\;\;\;\frac{\frac{x}{a}}{y}\\
\mathbf{elif}\;b \leq 4.8 \cdot 10^{-177}:\\
\;\;\;\;\frac{t\_1 - \frac{t\_1 - \frac{x}{a \cdot \left(y \cdot b\right)}}{b}}{b}\\
\mathbf{elif}\;b \leq 6.8 \cdot 10^{+18}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y + b \cdot \left(y + b \cdot \left(y \cdot 0.5 + b \cdot \left(y \cdot 0.16666666666666666 + b \cdot \left(0.008333333333333333 \cdot \left(y \cdot b\right) + y \cdot 0.041666666666666664\right)\right)\right)\right)\right)}\\
\end{array}
\end{array}
if b < -1.4e-155Initial program 99.3%
Taylor expanded in t around 0 77.4%
+-commutative77.4%
mul-1-neg77.4%
unsub-neg77.4%
Simplified77.4%
Taylor expanded in y around 0 61.0%
exp-neg61.0%
exp-sum60.9%
rem-exp-log61.7%
associate-/l/61.7%
Simplified61.7%
Taylor expanded in b around 0 56.5%
if -1.4e-155 < b < -1.3500000000000001e-262 or 4.7999999999999998e-177 < b < 6.8e18Initial program 94.2%
Taylor expanded in y around 0 63.0%
associate-/l*67.5%
div-exp64.1%
exp-to-pow65.2%
sub-neg65.2%
metadata-eval65.2%
Simplified65.2%
Taylor expanded in t around 0 39.7%
Taylor expanded in b around 0 40.0%
Taylor expanded in b around inf 46.5%
associate-/l*49.9%
distribute-lft-out51.8%
Simplified51.8%
if -1.3500000000000001e-262 < b < 8.19999999999999972e-224Initial program 94.0%
associate-/l*91.9%
associate--l+91.9%
exp-sum86.3%
associate-/l*83.5%
*-commutative83.5%
exp-to-pow83.5%
exp-diff83.5%
*-commutative83.5%
exp-to-pow86.3%
sub-neg86.3%
metadata-eval86.3%
Simplified86.3%
Taylor expanded in b around 0 88.4%
exp-to-pow91.6%
sub-neg91.6%
metadata-eval91.6%
Simplified91.6%
Taylor expanded in t around 0 83.6%
Taylor expanded in y around 0 56.9%
if 8.19999999999999972e-224 < b < 4.7999999999999998e-177Initial program 100.0%
Taylor expanded in y around 0 14.8%
associate-/l*14.8%
div-exp14.8%
exp-to-pow14.8%
sub-neg14.8%
metadata-eval14.8%
Simplified14.8%
Taylor expanded in t around 0 3.4%
Taylor expanded in b around 0 3.4%
Taylor expanded in b around -inf 39.9%
mul-1-neg39.9%
Simplified39.9%
if 6.8e18 < b Initial program 100.0%
Taylor expanded in y around 0 92.2%
associate-/l*92.2%
div-exp69.9%
exp-to-pow69.9%
sub-neg69.9%
metadata-eval69.9%
Simplified69.9%
Taylor expanded in t around 0 87.5%
Taylor expanded in b around 0 75.4%
Final simplification59.7%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ x (* b (* a (+ y (/ y b)))))) (t_2 (/ x (* y a))))
(if (<= b -8e-157)
(/
(*
x
(+
(/ 1.0 a)
(*
b
(+
(* b (+ (* (/ 1.0 a) 0.5) (* (/ b a) -0.16666666666666666)))
(/ -1.0 a)))))
y)
(if (<= b -2.25e-262)
t_1
(if (<= b 8.2e-224)
(/ (/ x a) y)
(if (<= b 4e-177)
(/ (- t_2 (/ (- t_2 (/ x (* a (* y b)))) b)) b)
(if (<= b 1e-61)
t_1
(/
x
(*
a
(*
y
(-
1.0
(*
b
(- -1.0 (* b (+ 0.5 (* b 0.16666666666666666))))))))))))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (b * (a * (y + (y / b))));
double t_2 = x / (y * a);
double tmp;
if (b <= -8e-157) {
tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) + ((b / a) * -0.16666666666666666))) + (-1.0 / a))))) / y;
} else if (b <= -2.25e-262) {
tmp = t_1;
} else if (b <= 8.2e-224) {
tmp = (x / a) / y;
} else if (b <= 4e-177) {
tmp = (t_2 - ((t_2 - (x / (a * (y * b)))) / b)) / b;
} else if (b <= 1e-61) {
tmp = t_1;
} else {
tmp = x / (a * (y * (1.0 - (b * (-1.0 - (b * (0.5 + (b * 0.16666666666666666))))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = x / (b * (a * (y + (y / b))))
t_2 = x / (y * a)
if (b <= (-8d-157)) then
tmp = (x * ((1.0d0 / a) + (b * ((b * (((1.0d0 / a) * 0.5d0) + ((b / a) * (-0.16666666666666666d0)))) + ((-1.0d0) / a))))) / y
else if (b <= (-2.25d-262)) then
tmp = t_1
else if (b <= 8.2d-224) then
tmp = (x / a) / y
else if (b <= 4d-177) then
tmp = (t_2 - ((t_2 - (x / (a * (y * b)))) / b)) / b
else if (b <= 1d-61) then
tmp = t_1
else
tmp = x / (a * (y * (1.0d0 - (b * ((-1.0d0) - (b * (0.5d0 + (b * 0.16666666666666666d0))))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (b * (a * (y + (y / b))));
double t_2 = x / (y * a);
double tmp;
if (b <= -8e-157) {
tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) + ((b / a) * -0.16666666666666666))) + (-1.0 / a))))) / y;
} else if (b <= -2.25e-262) {
tmp = t_1;
} else if (b <= 8.2e-224) {
tmp = (x / a) / y;
} else if (b <= 4e-177) {
tmp = (t_2 - ((t_2 - (x / (a * (y * b)))) / b)) / b;
} else if (b <= 1e-61) {
tmp = t_1;
} else {
tmp = x / (a * (y * (1.0 - (b * (-1.0 - (b * (0.5 + (b * 0.16666666666666666))))))));
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x / (b * (a * (y + (y / b)))) t_2 = x / (y * a) tmp = 0 if b <= -8e-157: tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) + ((b / a) * -0.16666666666666666))) + (-1.0 / a))))) / y elif b <= -2.25e-262: tmp = t_1 elif b <= 8.2e-224: tmp = (x / a) / y elif b <= 4e-177: tmp = (t_2 - ((t_2 - (x / (a * (y * b)))) / b)) / b elif b <= 1e-61: tmp = t_1 else: tmp = x / (a * (y * (1.0 - (b * (-1.0 - (b * (0.5 + (b * 0.16666666666666666)))))))) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x / Float64(b * Float64(a * Float64(y + Float64(y / b))))) t_2 = Float64(x / Float64(y * a)) tmp = 0.0 if (b <= -8e-157) tmp = Float64(Float64(x * Float64(Float64(1.0 / a) + Float64(b * Float64(Float64(b * Float64(Float64(Float64(1.0 / a) * 0.5) + Float64(Float64(b / a) * -0.16666666666666666))) + Float64(-1.0 / a))))) / y); elseif (b <= -2.25e-262) tmp = t_1; elseif (b <= 8.2e-224) tmp = Float64(Float64(x / a) / y); elseif (b <= 4e-177) tmp = Float64(Float64(t_2 - Float64(Float64(t_2 - Float64(x / Float64(a * Float64(y * b)))) / b)) / b); elseif (b <= 1e-61) tmp = t_1; else tmp = Float64(x / Float64(a * Float64(y * Float64(1.0 - Float64(b * Float64(-1.0 - Float64(b * Float64(0.5 + Float64(b * 0.16666666666666666))))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x / (b * (a * (y + (y / b)))); t_2 = x / (y * a); tmp = 0.0; if (b <= -8e-157) tmp = (x * ((1.0 / a) + (b * ((b * (((1.0 / a) * 0.5) + ((b / a) * -0.16666666666666666))) + (-1.0 / a))))) / y; elseif (b <= -2.25e-262) tmp = t_1; elseif (b <= 8.2e-224) tmp = (x / a) / y; elseif (b <= 4e-177) tmp = (t_2 - ((t_2 - (x / (a * (y * b)))) / b)) / b; elseif (b <= 1e-61) tmp = t_1; else tmp = x / (a * (y * (1.0 - (b * (-1.0 - (b * (0.5 + (b * 0.16666666666666666)))))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x / N[(b * N[(a * N[(y + N[(y / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x / N[(y * a), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -8e-157], N[(N[(x * N[(N[(1.0 / a), $MachinePrecision] + N[(b * N[(N[(b * N[(N[(N[(1.0 / a), $MachinePrecision] * 0.5), $MachinePrecision] + N[(N[(b / a), $MachinePrecision] * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-1.0 / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, -2.25e-262], t$95$1, If[LessEqual[b, 8.2e-224], N[(N[(x / a), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, 4e-177], N[(N[(t$95$2 - N[(N[(t$95$2 - N[(x / N[(a * N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision], If[LessEqual[b, 1e-61], t$95$1, N[(x / N[(a * N[(y * N[(1.0 - N[(b * N[(-1.0 - N[(b * N[(0.5 + N[(b * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{b \cdot \left(a \cdot \left(y + \frac{y}{b}\right)\right)}\\
t_2 := \frac{x}{y \cdot a}\\
\mathbf{if}\;b \leq -8 \cdot 10^{-157}:\\
\;\;\;\;\frac{x \cdot \left(\frac{1}{a} + b \cdot \left(b \cdot \left(\frac{1}{a} \cdot 0.5 + \frac{b}{a} \cdot -0.16666666666666666\right) + \frac{-1}{a}\right)\right)}{y}\\
\mathbf{elif}\;b \leq -2.25 \cdot 10^{-262}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq 8.2 \cdot 10^{-224}:\\
\;\;\;\;\frac{\frac{x}{a}}{y}\\
\mathbf{elif}\;b \leq 4 \cdot 10^{-177}:\\
\;\;\;\;\frac{t\_2 - \frac{t\_2 - \frac{x}{a \cdot \left(y \cdot b\right)}}{b}}{b}\\
\mathbf{elif}\;b \leq 10^{-61}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y \cdot \left(1 - b \cdot \left(-1 - b \cdot \left(0.5 + b \cdot 0.16666666666666666\right)\right)\right)\right)}\\
\end{array}
\end{array}
if b < -7.99999999999999955e-157Initial program 99.3%
Taylor expanded in t around 0 77.4%
+-commutative77.4%
mul-1-neg77.4%
unsub-neg77.4%
Simplified77.4%
Taylor expanded in y around 0 61.0%
exp-neg61.0%
exp-sum60.9%
rem-exp-log61.7%
associate-/l/61.7%
Simplified61.7%
Taylor expanded in b around 0 54.5%
if -7.99999999999999955e-157 < b < -2.24999999999999999e-262 or 3.99999999999999981e-177 < b < 1e-61Initial program 95.3%
Taylor expanded in y around 0 64.5%
associate-/l*69.9%
div-exp69.9%
exp-to-pow71.1%
sub-neg71.1%
metadata-eval71.1%
Simplified71.1%
Taylor expanded in t around 0 42.7%
Taylor expanded in b around 0 42.7%
Taylor expanded in b around inf 50.5%
associate-/l*54.6%
distribute-lft-out56.8%
Simplified56.8%
if -2.24999999999999999e-262 < b < 8.19999999999999972e-224Initial program 94.0%
associate-/l*91.9%
associate--l+91.9%
exp-sum86.3%
associate-/l*83.5%
*-commutative83.5%
exp-to-pow83.5%
exp-diff83.5%
*-commutative83.5%
exp-to-pow86.3%
sub-neg86.3%
metadata-eval86.3%
Simplified86.3%
Taylor expanded in b around 0 88.4%
exp-to-pow91.6%
sub-neg91.6%
metadata-eval91.6%
Simplified91.6%
Taylor expanded in t around 0 83.6%
Taylor expanded in y around 0 56.9%
if 8.19999999999999972e-224 < b < 3.99999999999999981e-177Initial program 100.0%
Taylor expanded in y around 0 14.8%
associate-/l*14.8%
div-exp14.8%
exp-to-pow14.8%
sub-neg14.8%
metadata-eval14.8%
Simplified14.8%
Taylor expanded in t around 0 3.4%
Taylor expanded in b around 0 3.4%
Taylor expanded in b around -inf 39.9%
mul-1-neg39.9%
Simplified39.9%
if 1e-61 < b Initial program 98.5%
Taylor expanded in y around 0 87.6%
associate-/l*87.5%
div-exp65.4%
exp-to-pow65.5%
sub-neg65.5%
metadata-eval65.5%
Simplified65.5%
Taylor expanded in t around 0 79.6%
Taylor expanded in b around 0 61.1%
Taylor expanded in y around 0 66.4%
Final simplification58.1%
(FPCore (x y z t a b)
:precision binary64
(if (<= a 1.6e-258)
(/ (* x (+ (/ 1.0 a) (* b (+ (* (/ b a) 0.5) (/ -1.0 a))))) y)
(/
x
(*
a
(+
y
(*
b
(+
y
(*
b
(+
(* y 0.5)
(*
b
(+
(* y 0.16666666666666666)
(* 0.041666666666666664 (* y b)))))))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= 1.6e-258) {
tmp = (x * ((1.0 / a) + (b * (((b / a) * 0.5) + (-1.0 / a))))) / y;
} else {
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (0.041666666666666664 * (y * b))))))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (a <= 1.6d-258) then
tmp = (x * ((1.0d0 / a) + (b * (((b / a) * 0.5d0) + ((-1.0d0) / a))))) / y
else
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5d0) + (b * ((y * 0.16666666666666666d0) + (0.041666666666666664d0 * (y * b))))))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= 1.6e-258) {
tmp = (x * ((1.0 / a) + (b * (((b / a) * 0.5) + (-1.0 / a))))) / y;
} else {
tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (0.041666666666666664 * (y * b))))))))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if a <= 1.6e-258: tmp = (x * ((1.0 / a) + (b * (((b / a) * 0.5) + (-1.0 / a))))) / y else: tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (0.041666666666666664 * (y * b)))))))))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (a <= 1.6e-258) tmp = Float64(Float64(x * Float64(Float64(1.0 / a) + Float64(b * Float64(Float64(Float64(b / a) * 0.5) + Float64(-1.0 / a))))) / y); else tmp = Float64(x / Float64(a * Float64(y + Float64(b * Float64(y + Float64(b * Float64(Float64(y * 0.5) + Float64(b * Float64(Float64(y * 0.16666666666666666) + Float64(0.041666666666666664 * Float64(y * b))))))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (a <= 1.6e-258) tmp = (x * ((1.0 / a) + (b * (((b / a) * 0.5) + (-1.0 / a))))) / y; else tmp = x / (a * (y + (b * (y + (b * ((y * 0.5) + (b * ((y * 0.16666666666666666) + (0.041666666666666664 * (y * b)))))))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[a, 1.6e-258], N[(N[(x * N[(N[(1.0 / a), $MachinePrecision] + N[(b * N[(N[(N[(b / a), $MachinePrecision] * 0.5), $MachinePrecision] + N[(-1.0 / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(x / N[(a * N[(y + N[(b * N[(y + N[(b * N[(N[(y * 0.5), $MachinePrecision] + N[(b * N[(N[(y * 0.16666666666666666), $MachinePrecision] + N[(0.041666666666666664 * N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq 1.6 \cdot 10^{-258}:\\
\;\;\;\;\frac{x \cdot \left(\frac{1}{a} + b \cdot \left(\frac{b}{a} \cdot 0.5 + \frac{-1}{a}\right)\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y + b \cdot \left(y + b \cdot \left(y \cdot 0.5 + b \cdot \left(y \cdot 0.16666666666666666 + 0.041666666666666664 \cdot \left(y \cdot b\right)\right)\right)\right)\right)}\\
\end{array}
\end{array}
if a < 1.6000000000000001e-258Initial program 99.4%
Taylor expanded in t around 0 81.5%
+-commutative81.5%
mul-1-neg81.5%
unsub-neg81.5%
Simplified81.5%
Taylor expanded in y around 0 63.8%
exp-neg63.8%
exp-sum63.8%
rem-exp-log64.4%
associate-/l/64.4%
Simplified64.4%
Taylor expanded in b around 0 59.9%
if 1.6000000000000001e-258 < a Initial program 97.5%
Taylor expanded in y around 0 78.3%
associate-/l*80.2%
div-exp68.2%
exp-to-pow69.2%
sub-neg69.2%
metadata-eval69.2%
Simplified69.2%
Taylor expanded in t around 0 61.0%
Taylor expanded in b around 0 49.4%
Final simplification50.3%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ x (* b (* a (+ y (/ y b)))))))
(if (<= y -8.4e+152)
t_1
(if (<= y -9.5e-135)
(/ (* b (- (/ x (* a b)) (/ x a))) y)
(if (<= y 8.6e-43) (* x (/ 1.0 (* y a))) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (b * (a * (y + (y / b))));
double tmp;
if (y <= -8.4e+152) {
tmp = t_1;
} else if (y <= -9.5e-135) {
tmp = (b * ((x / (a * b)) - (x / a))) / y;
} else if (y <= 8.6e-43) {
tmp = x * (1.0 / (y * a));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = x / (b * (a * (y + (y / b))))
if (y <= (-8.4d+152)) then
tmp = t_1
else if (y <= (-9.5d-135)) then
tmp = (b * ((x / (a * b)) - (x / a))) / y
else if (y <= 8.6d-43) then
tmp = x * (1.0d0 / (y * a))
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 b) {
double t_1 = x / (b * (a * (y + (y / b))));
double tmp;
if (y <= -8.4e+152) {
tmp = t_1;
} else if (y <= -9.5e-135) {
tmp = (b * ((x / (a * b)) - (x / a))) / y;
} else if (y <= 8.6e-43) {
tmp = x * (1.0 / (y * a));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x / (b * (a * (y + (y / b)))) tmp = 0 if y <= -8.4e+152: tmp = t_1 elif y <= -9.5e-135: tmp = (b * ((x / (a * b)) - (x / a))) / y elif y <= 8.6e-43: tmp = x * (1.0 / (y * a)) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x / Float64(b * Float64(a * Float64(y + Float64(y / b))))) tmp = 0.0 if (y <= -8.4e+152) tmp = t_1; elseif (y <= -9.5e-135) tmp = Float64(Float64(b * Float64(Float64(x / Float64(a * b)) - Float64(x / a))) / y); elseif (y <= 8.6e-43) tmp = Float64(x * Float64(1.0 / Float64(y * a))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x / (b * (a * (y + (y / b)))); tmp = 0.0; if (y <= -8.4e+152) tmp = t_1; elseif (y <= -9.5e-135) tmp = (b * ((x / (a * b)) - (x / a))) / y; elseif (y <= 8.6e-43) tmp = x * (1.0 / (y * a)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x / N[(b * N[(a * N[(y + N[(y / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -8.4e+152], t$95$1, If[LessEqual[y, -9.5e-135], N[(N[(b * N[(N[(x / N[(a * b), $MachinePrecision]), $MachinePrecision] - N[(x / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[y, 8.6e-43], N[(x * N[(1.0 / N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{b \cdot \left(a \cdot \left(y + \frac{y}{b}\right)\right)}\\
\mathbf{if}\;y \leq -8.4 \cdot 10^{+152}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq -9.5 \cdot 10^{-135}:\\
\;\;\;\;\frac{b \cdot \left(\frac{x}{a \cdot b} - \frac{x}{a}\right)}{y}\\
\mathbf{elif}\;y \leq 8.6 \cdot 10^{-43}:\\
\;\;\;\;x \cdot \frac{1}{y \cdot a}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -8.4000000000000007e152 or 8.59999999999999927e-43 < y Initial program 100.0%
Taylor expanded in y around 0 63.0%
associate-/l*63.9%
div-exp50.2%
exp-to-pow50.2%
sub-neg50.2%
metadata-eval50.2%
Simplified50.2%
Taylor expanded in t around 0 41.7%
Taylor expanded in b around 0 35.6%
Taylor expanded in b around inf 35.2%
associate-/l*38.3%
distribute-lft-out42.6%
Simplified42.6%
if -8.4000000000000007e152 < y < -9.50000000000000007e-135Initial program 99.1%
Taylor expanded in t around 0 83.7%
+-commutative83.7%
mul-1-neg83.7%
unsub-neg83.7%
Simplified83.7%
Taylor expanded in y around 0 59.3%
exp-neg59.3%
exp-sum59.4%
rem-exp-log60.2%
associate-/l/60.2%
Simplified60.2%
Taylor expanded in b around 0 29.0%
Taylor expanded in b around inf 50.1%
+-commutative50.1%
mul-1-neg50.1%
unsub-neg50.1%
Simplified50.1%
if -9.50000000000000007e-135 < y < 8.59999999999999927e-43Initial program 94.4%
Taylor expanded in y around 0 94.4%
associate-/l*96.2%
div-exp85.0%
exp-to-pow86.8%
sub-neg86.8%
metadata-eval86.8%
Simplified86.8%
Taylor expanded in b around 0 69.6%
exp-to-pow71.3%
sub-neg71.3%
metadata-eval71.3%
Simplified71.3%
Taylor expanded in t around 0 43.7%
*-commutative43.7%
Simplified43.7%
Final simplification44.8%
(FPCore (x y z t a b)
:precision binary64
(if (<= y -7.4e+152)
(/ x (* b (* a (+ y (/ y b)))))
(if (<= y -6.5e-55)
(/ (* b (- (/ x (* a b)) (/ x a))) y)
(/ x (* a (+ y (* b (+ y (* 0.5 (* y b))))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -7.4e+152) {
tmp = x / (b * (a * (y + (y / b))));
} else if (y <= -6.5e-55) {
tmp = (b * ((x / (a * b)) - (x / a))) / y;
} else {
tmp = x / (a * (y + (b * (y + (0.5 * (y * b))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (y <= (-7.4d+152)) then
tmp = x / (b * (a * (y + (y / b))))
else if (y <= (-6.5d-55)) then
tmp = (b * ((x / (a * b)) - (x / a))) / y
else
tmp = x / (a * (y + (b * (y + (0.5d0 * (y * b))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -7.4e+152) {
tmp = x / (b * (a * (y + (y / b))));
} else if (y <= -6.5e-55) {
tmp = (b * ((x / (a * b)) - (x / a))) / y;
} else {
tmp = x / (a * (y + (b * (y + (0.5 * (y * b))))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -7.4e+152: tmp = x / (b * (a * (y + (y / b)))) elif y <= -6.5e-55: tmp = (b * ((x / (a * b)) - (x / a))) / y else: tmp = x / (a * (y + (b * (y + (0.5 * (y * b)))))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -7.4e+152) tmp = Float64(x / Float64(b * Float64(a * Float64(y + Float64(y / b))))); elseif (y <= -6.5e-55) tmp = Float64(Float64(b * Float64(Float64(x / Float64(a * b)) - Float64(x / a))) / y); else tmp = Float64(x / Float64(a * Float64(y + Float64(b * Float64(y + Float64(0.5 * Float64(y * b))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (y <= -7.4e+152) tmp = x / (b * (a * (y + (y / b)))); elseif (y <= -6.5e-55) tmp = (b * ((x / (a * b)) - (x / a))) / y; else tmp = x / (a * (y + (b * (y + (0.5 * (y * b)))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -7.4e+152], N[(x / N[(b * N[(a * N[(y + N[(y / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -6.5e-55], N[(N[(b * N[(N[(x / N[(a * b), $MachinePrecision]), $MachinePrecision] - N[(x / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(x / N[(a * N[(y + N[(b * N[(y + N[(0.5 * N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -7.4 \cdot 10^{+152}:\\
\;\;\;\;\frac{x}{b \cdot \left(a \cdot \left(y + \frac{y}{b}\right)\right)}\\
\mathbf{elif}\;y \leq -6.5 \cdot 10^{-55}:\\
\;\;\;\;\frac{b \cdot \left(\frac{x}{a \cdot b} - \frac{x}{a}\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y + b \cdot \left(y + 0.5 \cdot \left(y \cdot b\right)\right)\right)}\\
\end{array}
\end{array}
if y < -7.39999999999999992e152Initial program 100.0%
Taylor expanded in y around 0 40.8%
associate-/l*40.7%
div-exp27.5%
exp-to-pow27.5%
sub-neg27.5%
metadata-eval27.5%
Simplified27.5%
Taylor expanded in t around 0 27.9%
Taylor expanded in b around 0 45.1%
Taylor expanded in b around inf 45.2%
associate-/l*53.6%
distribute-lft-out58.0%
Simplified58.0%
if -7.39999999999999992e152 < y < -6.50000000000000006e-55Initial program 99.5%
Taylor expanded in t around 0 84.0%
+-commutative84.0%
mul-1-neg84.0%
unsub-neg84.0%
Simplified84.0%
Taylor expanded in y around 0 49.1%
exp-neg49.1%
exp-sum49.2%
rem-exp-log49.6%
associate-/l/49.6%
Simplified49.6%
Taylor expanded in b around 0 25.0%
Taylor expanded in b around inf 50.7%
+-commutative50.7%
mul-1-neg50.7%
unsub-neg50.7%
Simplified50.7%
if -6.50000000000000006e-55 < y Initial program 96.9%
Taylor expanded in y around 0 85.5%
associate-/l*86.9%
div-exp74.8%
exp-to-pow75.9%
sub-neg75.9%
metadata-eval75.9%
Simplified75.9%
Taylor expanded in t around 0 66.1%
Taylor expanded in b around 0 42.6%
*-commutative42.6%
Simplified42.6%
Final simplification45.4%
(FPCore (x y z t a b)
:precision binary64
(if (<= a 1.2e-258)
(/ 1.0 (/ y (* (/ x a) (- 1.0 b))))
(/
x
(*
a
(* y (- 1.0 (* b (- -1.0 (* b (+ 0.5 (* b 0.16666666666666666)))))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= 1.2e-258) {
tmp = 1.0 / (y / ((x / a) * (1.0 - b)));
} else {
tmp = x / (a * (y * (1.0 - (b * (-1.0 - (b * (0.5 + (b * 0.16666666666666666))))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (a <= 1.2d-258) then
tmp = 1.0d0 / (y / ((x / a) * (1.0d0 - b)))
else
tmp = x / (a * (y * (1.0d0 - (b * ((-1.0d0) - (b * (0.5d0 + (b * 0.16666666666666666d0))))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= 1.2e-258) {
tmp = 1.0 / (y / ((x / a) * (1.0 - b)));
} else {
tmp = x / (a * (y * (1.0 - (b * (-1.0 - (b * (0.5 + (b * 0.16666666666666666))))))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if a <= 1.2e-258: tmp = 1.0 / (y / ((x / a) * (1.0 - b))) else: tmp = x / (a * (y * (1.0 - (b * (-1.0 - (b * (0.5 + (b * 0.16666666666666666)))))))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (a <= 1.2e-258) tmp = Float64(1.0 / Float64(y / Float64(Float64(x / a) * Float64(1.0 - b)))); else tmp = Float64(x / Float64(a * Float64(y * Float64(1.0 - Float64(b * Float64(-1.0 - Float64(b * Float64(0.5 + Float64(b * 0.16666666666666666))))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (a <= 1.2e-258) tmp = 1.0 / (y / ((x / a) * (1.0 - b))); else tmp = x / (a * (y * (1.0 - (b * (-1.0 - (b * (0.5 + (b * 0.16666666666666666)))))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[a, 1.2e-258], N[(1.0 / N[(y / N[(N[(x / a), $MachinePrecision] * N[(1.0 - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(a * N[(y * N[(1.0 - N[(b * N[(-1.0 - N[(b * N[(0.5 + N[(b * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq 1.2 \cdot 10^{-258}:\\
\;\;\;\;\frac{1}{\frac{y}{\frac{x}{a} \cdot \left(1 - b\right)}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y \cdot \left(1 - b \cdot \left(-1 - b \cdot \left(0.5 + b \cdot 0.16666666666666666\right)\right)\right)\right)}\\
\end{array}
\end{array}
if a < 1.2000000000000001e-258Initial program 99.4%
Taylor expanded in t around 0 81.5%
+-commutative81.5%
mul-1-neg81.5%
unsub-neg81.5%
Simplified81.5%
Taylor expanded in y around 0 63.8%
exp-neg63.8%
exp-sum63.8%
rem-exp-log64.4%
associate-/l/64.4%
Simplified64.4%
Taylor expanded in b around 0 41.6%
clear-num41.7%
inv-pow41.7%
fma-define41.7%
associate-/l*41.6%
Applied egg-rr41.6%
unpow-141.6%
fma-undefine41.6%
associate-*r*41.6%
distribute-lft1-in50.9%
mul-1-neg50.9%
Simplified50.9%
if 1.2000000000000001e-258 < a Initial program 97.5%
Taylor expanded in y around 0 78.3%
associate-/l*80.2%
div-exp68.2%
exp-to-pow69.2%
sub-neg69.2%
metadata-eval69.2%
Simplified69.2%
Taylor expanded in t around 0 61.0%
Taylor expanded in b around 0 47.7%
Taylor expanded in y around 0 49.3%
Final simplification49.5%
(FPCore (x y z t a b)
:precision binary64
(if (<= a 2.85e-257)
(/ (* x (+ (/ 1.0 a) (* b (+ (* (/ b a) 0.5) (/ -1.0 a))))) y)
(/
x
(*
a
(* y (- 1.0 (* b (- -1.0 (* b (+ 0.5 (* b 0.16666666666666666)))))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= 2.85e-257) {
tmp = (x * ((1.0 / a) + (b * (((b / a) * 0.5) + (-1.0 / a))))) / y;
} else {
tmp = x / (a * (y * (1.0 - (b * (-1.0 - (b * (0.5 + (b * 0.16666666666666666))))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (a <= 2.85d-257) then
tmp = (x * ((1.0d0 / a) + (b * (((b / a) * 0.5d0) + ((-1.0d0) / a))))) / y
else
tmp = x / (a * (y * (1.0d0 - (b * ((-1.0d0) - (b * (0.5d0 + (b * 0.16666666666666666d0))))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= 2.85e-257) {
tmp = (x * ((1.0 / a) + (b * (((b / a) * 0.5) + (-1.0 / a))))) / y;
} else {
tmp = x / (a * (y * (1.0 - (b * (-1.0 - (b * (0.5 + (b * 0.16666666666666666))))))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if a <= 2.85e-257: tmp = (x * ((1.0 / a) + (b * (((b / a) * 0.5) + (-1.0 / a))))) / y else: tmp = x / (a * (y * (1.0 - (b * (-1.0 - (b * (0.5 + (b * 0.16666666666666666)))))))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (a <= 2.85e-257) tmp = Float64(Float64(x * Float64(Float64(1.0 / a) + Float64(b * Float64(Float64(Float64(b / a) * 0.5) + Float64(-1.0 / a))))) / y); else tmp = Float64(x / Float64(a * Float64(y * Float64(1.0 - Float64(b * Float64(-1.0 - Float64(b * Float64(0.5 + Float64(b * 0.16666666666666666))))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (a <= 2.85e-257) tmp = (x * ((1.0 / a) + (b * (((b / a) * 0.5) + (-1.0 / a))))) / y; else tmp = x / (a * (y * (1.0 - (b * (-1.0 - (b * (0.5 + (b * 0.16666666666666666)))))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[a, 2.85e-257], N[(N[(x * N[(N[(1.0 / a), $MachinePrecision] + N[(b * N[(N[(N[(b / a), $MachinePrecision] * 0.5), $MachinePrecision] + N[(-1.0 / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(x / N[(a * N[(y * N[(1.0 - N[(b * N[(-1.0 - N[(b * N[(0.5 + N[(b * 0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq 2.85 \cdot 10^{-257}:\\
\;\;\;\;\frac{x \cdot \left(\frac{1}{a} + b \cdot \left(\frac{b}{a} \cdot 0.5 + \frac{-1}{a}\right)\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y \cdot \left(1 - b \cdot \left(-1 - b \cdot \left(0.5 + b \cdot 0.16666666666666666\right)\right)\right)\right)}\\
\end{array}
\end{array}
if a < 2.8499999999999999e-257Initial program 99.4%
Taylor expanded in t around 0 81.5%
+-commutative81.5%
mul-1-neg81.5%
unsub-neg81.5%
Simplified81.5%
Taylor expanded in y around 0 63.8%
exp-neg63.8%
exp-sum63.8%
rem-exp-log64.4%
associate-/l/64.4%
Simplified64.4%
Taylor expanded in b around 0 59.9%
if 2.8499999999999999e-257 < a Initial program 97.5%
Taylor expanded in y around 0 78.3%
associate-/l*80.2%
div-exp68.2%
exp-to-pow69.2%
sub-neg69.2%
metadata-eval69.2%
Simplified69.2%
Taylor expanded in t around 0 61.0%
Taylor expanded in b around 0 47.7%
Taylor expanded in y around 0 49.3%
Final simplification50.2%
(FPCore (x y z t a b) :precision binary64 (if (<= b -1.26e+34) (* b (/ x (* y (- a)))) (if (<= b 3.5e+61) (* x (/ 1.0 (* y a))) (/ x (* a (* y b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -1.26e+34) {
tmp = b * (x / (y * -a));
} else if (b <= 3.5e+61) {
tmp = x * (1.0 / (y * a));
} else {
tmp = x / (a * (y * b));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (b <= (-1.26d+34)) then
tmp = b * (x / (y * -a))
else if (b <= 3.5d+61) then
tmp = x * (1.0d0 / (y * a))
else
tmp = x / (a * (y * b))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -1.26e+34) {
tmp = b * (x / (y * -a));
} else if (b <= 3.5e+61) {
tmp = x * (1.0 / (y * a));
} else {
tmp = x / (a * (y * b));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -1.26e+34: tmp = b * (x / (y * -a)) elif b <= 3.5e+61: tmp = x * (1.0 / (y * a)) else: tmp = x / (a * (y * b)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -1.26e+34) tmp = Float64(b * Float64(x / Float64(y * Float64(-a)))); elseif (b <= 3.5e+61) tmp = Float64(x * Float64(1.0 / Float64(y * a))); else tmp = Float64(x / Float64(a * Float64(y * b))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -1.26e+34) tmp = b * (x / (y * -a)); elseif (b <= 3.5e+61) tmp = x * (1.0 / (y * a)); else tmp = x / (a * (y * b)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -1.26e+34], N[(b * N[(x / N[(y * (-a)), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 3.5e+61], N[(x * N[(1.0 / N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(a * N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.26 \cdot 10^{+34}:\\
\;\;\;\;b \cdot \frac{x}{y \cdot \left(-a\right)}\\
\mathbf{elif}\;b \leq 3.5 \cdot 10^{+61}:\\
\;\;\;\;x \cdot \frac{1}{y \cdot a}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y \cdot b\right)}\\
\end{array}
\end{array}
if b < -1.2599999999999999e34Initial program 100.0%
Taylor expanded in t around 0 87.7%
+-commutative87.7%
mul-1-neg87.7%
unsub-neg87.7%
Simplified87.7%
Taylor expanded in y around 0 75.4%
exp-neg75.4%
exp-sum75.4%
rem-exp-log75.4%
associate-/l/75.4%
Simplified75.4%
Taylor expanded in b around 0 41.9%
Taylor expanded in b around inf 39.7%
mul-1-neg39.7%
associate-/l*43.7%
distribute-rgt-neg-in43.7%
distribute-frac-neg43.7%
Simplified43.7%
if -1.2599999999999999e34 < b < 3.50000000000000018e61Initial program 96.0%
Taylor expanded in y around 0 69.1%
associate-/l*70.9%
div-exp68.3%
exp-to-pow69.8%
sub-neg69.8%
metadata-eval69.8%
Simplified69.8%
Taylor expanded in b around 0 66.4%
exp-to-pow67.8%
sub-neg67.8%
metadata-eval67.8%
Simplified67.8%
Taylor expanded in t around 0 40.1%
*-commutative40.1%
Simplified40.1%
if 3.50000000000000018e61 < b Initial program 100.0%
Taylor expanded in y around 0 96.5%
associate-/l*96.5%
div-exp71.5%
exp-to-pow71.5%
sub-neg71.5%
metadata-eval71.5%
Simplified71.5%
Taylor expanded in t around 0 89.5%
Taylor expanded in b around 0 40.2%
Taylor expanded in b around inf 40.2%
*-commutative40.2%
Simplified40.2%
Final simplification40.8%
(FPCore (x y z t a b) :precision binary64 (if (<= b -1.25e+16) (* b (/ x (* y (- a)))) (/ x (* b (* a (+ y (/ y b)))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -1.25e+16) {
tmp = b * (x / (y * -a));
} else {
tmp = x / (b * (a * (y + (y / b))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (b <= (-1.25d+16)) then
tmp = b * (x / (y * -a))
else
tmp = x / (b * (a * (y + (y / b))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -1.25e+16) {
tmp = b * (x / (y * -a));
} else {
tmp = x / (b * (a * (y + (y / b))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -1.25e+16: tmp = b * (x / (y * -a)) else: tmp = x / (b * (a * (y + (y / b)))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -1.25e+16) tmp = Float64(b * Float64(x / Float64(y * Float64(-a)))); else tmp = Float64(x / Float64(b * Float64(a * Float64(y + Float64(y / b))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -1.25e+16) tmp = b * (x / (y * -a)); else tmp = x / (b * (a * (y + (y / b)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -1.25e+16], N[(b * N[(x / N[(y * (-a)), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(b * N[(a * N[(y + N[(y / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.25 \cdot 10^{+16}:\\
\;\;\;\;b \cdot \frac{x}{y \cdot \left(-a\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{b \cdot \left(a \cdot \left(y + \frac{y}{b}\right)\right)}\\
\end{array}
\end{array}
if b < -1.25e16Initial program 100.0%
Taylor expanded in t around 0 86.5%
+-commutative86.5%
mul-1-neg86.5%
unsub-neg86.5%
Simplified86.5%
Taylor expanded in y around 0 74.9%
exp-neg74.9%
exp-sum74.9%
rem-exp-log74.9%
associate-/l/74.9%
Simplified74.9%
Taylor expanded in b around 0 39.6%
Taylor expanded in b around inf 37.6%
mul-1-neg37.6%
associate-/l*41.3%
distribute-rgt-neg-in41.3%
distribute-frac-neg41.3%
Simplified41.3%
if -1.25e16 < b Initial program 97.0%
Taylor expanded in y around 0 76.2%
associate-/l*77.5%
div-exp69.2%
exp-to-pow70.3%
sub-neg70.3%
metadata-eval70.3%
Simplified70.3%
Taylor expanded in t around 0 56.6%
Taylor expanded in b around 0 41.6%
Taylor expanded in b around inf 39.0%
associate-/l*40.4%
distribute-lft-out43.3%
Simplified43.3%
Final simplification42.9%
(FPCore (x y z t a b) :precision binary64 (if (<= a 4.4e-164) (/ (* x (- (/ 1.0 a) (/ b a))) y) (/ x (* b (* a (+ y (/ y b)))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= 4.4e-164) {
tmp = (x * ((1.0 / a) - (b / a))) / y;
} else {
tmp = x / (b * (a * (y + (y / b))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (a <= 4.4d-164) then
tmp = (x * ((1.0d0 / a) - (b / a))) / y
else
tmp = x / (b * (a * (y + (y / b))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= 4.4e-164) {
tmp = (x * ((1.0 / a) - (b / a))) / y;
} else {
tmp = x / (b * (a * (y + (y / b))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if a <= 4.4e-164: tmp = (x * ((1.0 / a) - (b / a))) / y else: tmp = x / (b * (a * (y + (y / b)))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (a <= 4.4e-164) tmp = Float64(Float64(x * Float64(Float64(1.0 / a) - Float64(b / a))) / y); else tmp = Float64(x / Float64(b * Float64(a * Float64(y + Float64(y / b))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (a <= 4.4e-164) tmp = (x * ((1.0 / a) - (b / a))) / y; else tmp = x / (b * (a * (y + (y / b)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[a, 4.4e-164], N[(N[(x * N[(N[(1.0 / a), $MachinePrecision] - N[(b / a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(x / N[(b * N[(a * N[(y + N[(y / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq 4.4 \cdot 10^{-164}:\\
\;\;\;\;\frac{x \cdot \left(\frac{1}{a} - \frac{b}{a}\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{b \cdot \left(a \cdot \left(y + \frac{y}{b}\right)\right)}\\
\end{array}
\end{array}
if a < 4.39999999999999975e-164Initial program 99.6%
Taylor expanded in t around 0 81.7%
+-commutative81.7%
mul-1-neg81.7%
unsub-neg81.7%
Simplified81.7%
Taylor expanded in y around 0 62.4%
exp-neg62.4%
exp-sum62.4%
rem-exp-log62.8%
associate-/l/62.8%
Simplified62.8%
Taylor expanded in b around 0 43.2%
+-commutative43.2%
mul-1-neg43.2%
unsub-neg43.2%
Simplified43.2%
if 4.39999999999999975e-164 < a Initial program 97.0%
Taylor expanded in y around 0 77.2%
associate-/l*79.8%
div-exp66.1%
exp-to-pow67.3%
sub-neg67.3%
metadata-eval67.3%
Simplified67.3%
Taylor expanded in t around 0 61.3%
Taylor expanded in b around 0 39.1%
Taylor expanded in b around inf 36.9%
associate-/l*38.4%
distribute-lft-out40.5%
Simplified40.5%
Final simplification41.1%
(FPCore (x y z t a b) :precision binary64 (if (<= a 1.7e-162) (/ 1.0 (/ y (* (/ x a) (- 1.0 b)))) (/ x (* b (* a (+ y (/ y b)))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= 1.7e-162) {
tmp = 1.0 / (y / ((x / a) * (1.0 - b)));
} else {
tmp = x / (b * (a * (y + (y / b))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (a <= 1.7d-162) then
tmp = 1.0d0 / (y / ((x / a) * (1.0d0 - b)))
else
tmp = x / (b * (a * (y + (y / b))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= 1.7e-162) {
tmp = 1.0 / (y / ((x / a) * (1.0 - b)));
} else {
tmp = x / (b * (a * (y + (y / b))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if a <= 1.7e-162: tmp = 1.0 / (y / ((x / a) * (1.0 - b))) else: tmp = x / (b * (a * (y + (y / b)))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (a <= 1.7e-162) tmp = Float64(1.0 / Float64(y / Float64(Float64(x / a) * Float64(1.0 - b)))); else tmp = Float64(x / Float64(b * Float64(a * Float64(y + Float64(y / b))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (a <= 1.7e-162) tmp = 1.0 / (y / ((x / a) * (1.0 - b))); else tmp = x / (b * (a * (y + (y / b)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[a, 1.7e-162], N[(1.0 / N[(y / N[(N[(x / a), $MachinePrecision] * N[(1.0 - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(b * N[(a * N[(y + N[(y / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq 1.7 \cdot 10^{-162}:\\
\;\;\;\;\frac{1}{\frac{y}{\frac{x}{a} \cdot \left(1 - b\right)}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{b \cdot \left(a \cdot \left(y + \frac{y}{b}\right)\right)}\\
\end{array}
\end{array}
if a < 1.7e-162Initial program 99.6%
Taylor expanded in t around 0 81.7%
+-commutative81.7%
mul-1-neg81.7%
unsub-neg81.7%
Simplified81.7%
Taylor expanded in y around 0 62.4%
exp-neg62.4%
exp-sum62.4%
rem-exp-log62.8%
associate-/l/62.8%
Simplified62.8%
Taylor expanded in b around 0 39.7%
clear-num39.7%
inv-pow39.7%
fma-define39.7%
associate-/l*34.7%
Applied egg-rr34.7%
unpow-134.7%
fma-undefine34.7%
associate-*r*34.7%
distribute-lft1-in43.2%
mul-1-neg43.2%
Simplified43.2%
if 1.7e-162 < a Initial program 97.0%
Taylor expanded in y around 0 77.2%
associate-/l*79.8%
div-exp66.1%
exp-to-pow67.3%
sub-neg67.3%
metadata-eval67.3%
Simplified67.3%
Taylor expanded in t around 0 61.3%
Taylor expanded in b around 0 39.1%
Taylor expanded in b around inf 36.9%
associate-/l*38.4%
distribute-lft-out40.5%
Simplified40.5%
Final simplification41.1%
(FPCore (x y z t a b) :precision binary64 (if (<= b -1.25e+16) (* b (/ x (* y (- a)))) (/ x (* a (+ y (* y b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -1.25e+16) {
tmp = b * (x / (y * -a));
} else {
tmp = x / (a * (y + (y * b)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (b <= (-1.25d+16)) then
tmp = b * (x / (y * -a))
else
tmp = x / (a * (y + (y * b)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -1.25e+16) {
tmp = b * (x / (y * -a));
} else {
tmp = x / (a * (y + (y * b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -1.25e+16: tmp = b * (x / (y * -a)) else: tmp = x / (a * (y + (y * b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -1.25e+16) tmp = Float64(b * Float64(x / Float64(y * Float64(-a)))); else tmp = Float64(x / Float64(a * Float64(y + Float64(y * b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -1.25e+16) tmp = b * (x / (y * -a)); else tmp = x / (a * (y + (y * b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -1.25e+16], N[(b * N[(x / N[(y * (-a)), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(a * N[(y + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.25 \cdot 10^{+16}:\\
\;\;\;\;b \cdot \frac{x}{y \cdot \left(-a\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y + y \cdot b\right)}\\
\end{array}
\end{array}
if b < -1.25e16Initial program 100.0%
Taylor expanded in t around 0 86.5%
+-commutative86.5%
mul-1-neg86.5%
unsub-neg86.5%
Simplified86.5%
Taylor expanded in y around 0 74.9%
exp-neg74.9%
exp-sum74.9%
rem-exp-log74.9%
associate-/l/74.9%
Simplified74.9%
Taylor expanded in b around 0 39.6%
Taylor expanded in b around inf 37.6%
mul-1-neg37.6%
associate-/l*41.3%
distribute-rgt-neg-in41.3%
distribute-frac-neg41.3%
Simplified41.3%
if -1.25e16 < b Initial program 97.0%
Taylor expanded in y around 0 76.2%
associate-/l*77.5%
div-exp69.2%
exp-to-pow70.3%
sub-neg70.3%
metadata-eval70.3%
Simplified70.3%
Taylor expanded in t around 0 56.6%
Taylor expanded in b around 0 41.6%
Final simplification41.6%
(FPCore (x y z t a b) :precision binary64 (if (<= b -1.4e+127) (/ (/ (* x b) a) (- y)) (/ x (* a (+ y (* y b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -1.4e+127) {
tmp = ((x * b) / a) / -y;
} else {
tmp = x / (a * (y + (y * b)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (b <= (-1.4d+127)) then
tmp = ((x * b) / a) / -y
else
tmp = x / (a * (y + (y * b)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -1.4e+127) {
tmp = ((x * b) / a) / -y;
} else {
tmp = x / (a * (y + (y * b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -1.4e+127: tmp = ((x * b) / a) / -y else: tmp = x / (a * (y + (y * b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -1.4e+127) tmp = Float64(Float64(Float64(x * b) / a) / Float64(-y)); else tmp = Float64(x / Float64(a * Float64(y + Float64(y * b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -1.4e+127) tmp = ((x * b) / a) / -y; else tmp = x / (a * (y + (y * b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -1.4e+127], N[(N[(N[(x * b), $MachinePrecision] / a), $MachinePrecision] / (-y)), $MachinePrecision], N[(x / N[(a * N[(y + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.4 \cdot 10^{+127}:\\
\;\;\;\;\frac{\frac{x \cdot b}{a}}{-y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y + y \cdot b\right)}\\
\end{array}
\end{array}
if b < -1.4000000000000001e127Initial program 100.0%
Taylor expanded in t around 0 93.0%
+-commutative93.0%
mul-1-neg93.0%
unsub-neg93.0%
Simplified93.0%
Taylor expanded in y around 0 85.9%
exp-neg85.9%
exp-sum85.9%
rem-exp-log85.9%
associate-/l/85.9%
Simplified85.9%
Taylor expanded in b around 0 58.5%
Taylor expanded in b around inf 58.5%
if -1.4000000000000001e127 < b Initial program 97.3%
Taylor expanded in y around 0 77.7%
associate-/l*78.9%
div-exp68.4%
exp-to-pow69.4%
sub-neg69.4%
metadata-eval69.4%
Simplified69.4%
Taylor expanded in t around 0 57.0%
Taylor expanded in b around 0 39.8%
Final simplification41.8%
(FPCore (x y z t a b) :precision binary64 (if (<= x 1e-154) (/ 1.0 (* y (/ a x))) (* x (/ 1.0 (* y a)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (x <= 1e-154) {
tmp = 1.0 / (y * (a / x));
} else {
tmp = x * (1.0 / (y * a));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (x <= 1d-154) then
tmp = 1.0d0 / (y * (a / x))
else
tmp = x * (1.0d0 / (y * a))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (x <= 1e-154) {
tmp = 1.0 / (y * (a / x));
} else {
tmp = x * (1.0 / (y * a));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if x <= 1e-154: tmp = 1.0 / (y * (a / x)) else: tmp = x * (1.0 / (y * a)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (x <= 1e-154) tmp = Float64(1.0 / Float64(y * Float64(a / x))); else tmp = Float64(x * Float64(1.0 / Float64(y * a))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (x <= 1e-154) tmp = 1.0 / (y * (a / x)); else tmp = x * (1.0 / (y * a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[x, 1e-154], N[(1.0 / N[(y * N[(a / x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(1.0 / N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 10^{-154}:\\
\;\;\;\;\frac{1}{y \cdot \frac{a}{x}}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{1}{y \cdot a}\\
\end{array}
\end{array}
if x < 9.9999999999999997e-155Initial program 97.3%
Taylor expanded in y around 0 80.8%
associate-/l*80.8%
div-exp66.6%
exp-to-pow67.3%
sub-neg67.3%
metadata-eval67.3%
Simplified67.3%
Taylor expanded in t around 0 56.6%
Taylor expanded in b around 0 30.9%
*-commutative30.9%
Simplified30.9%
clear-num31.2%
inv-pow31.2%
Applied egg-rr31.2%
unpow-131.2%
associate-/l*32.4%
Simplified32.4%
if 9.9999999999999997e-155 < x Initial program 98.1%
Taylor expanded in y around 0 77.2%
associate-/l*79.8%
div-exp71.0%
exp-to-pow72.0%
sub-neg72.0%
metadata-eval72.0%
Simplified72.0%
Taylor expanded in b around 0 57.4%
exp-to-pow58.4%
sub-neg58.4%
metadata-eval58.4%
Simplified58.4%
Taylor expanded in t around 0 38.7%
*-commutative38.7%
Simplified38.7%
Final simplification34.9%
(FPCore (x y z t a b) :precision binary64 (if (<= b 2.6e+61) (* x (/ 1.0 (* y a))) (/ x (* a (* y b)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= 2.6e+61) {
tmp = x * (1.0 / (y * a));
} else {
tmp = x / (a * (y * b));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: tmp
if (b <= 2.6d+61) then
tmp = x * (1.0d0 / (y * a))
else
tmp = x / (a * (y * b))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= 2.6e+61) {
tmp = x * (1.0 / (y * a));
} else {
tmp = x / (a * (y * b));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= 2.6e+61: tmp = x * (1.0 / (y * a)) else: tmp = x / (a * (y * b)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= 2.6e+61) tmp = Float64(x * Float64(1.0 / Float64(y * a))); else tmp = Float64(x / Float64(a * Float64(y * b))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= 2.6e+61) tmp = x * (1.0 / (y * a)); else tmp = x / (a * (y * b)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, 2.6e+61], N[(x * N[(1.0 / N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(a * N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq 2.6 \cdot 10^{+61}:\\
\;\;\;\;x \cdot \frac{1}{y \cdot a}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y \cdot b\right)}\\
\end{array}
\end{array}
if b < 2.59999999999999973e61Initial program 97.0%
Taylor expanded in y around 0 74.6%
associate-/l*75.9%
div-exp67.4%
exp-to-pow68.6%
sub-neg68.6%
metadata-eval68.6%
Simplified68.6%
Taylor expanded in b around 0 64.2%
exp-to-pow65.3%
sub-neg65.3%
metadata-eval65.3%
Simplified65.3%
Taylor expanded in t around 0 38.6%
*-commutative38.6%
Simplified38.6%
if 2.59999999999999973e61 < b Initial program 100.0%
Taylor expanded in y around 0 96.5%
associate-/l*96.5%
div-exp71.5%
exp-to-pow71.5%
sub-neg71.5%
metadata-eval71.5%
Simplified71.5%
Taylor expanded in t around 0 89.5%
Taylor expanded in b around 0 40.2%
Taylor expanded in b around inf 40.2%
*-commutative40.2%
Simplified40.2%
Final simplification38.9%
(FPCore (x y z t a b) :precision binary64 (* x (/ 1.0 (* y a))))
double code(double x, double y, double z, double t, double a, double b) {
return x * (1.0 / (y * a));
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
code = x * (1.0d0 / (y * a))
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x * (1.0 / (y * a));
}
def code(x, y, z, t, a, b): return x * (1.0 / (y * a))
function code(x, y, z, t, a, b) return Float64(x * Float64(1.0 / Float64(y * a))) end
function tmp = code(x, y, z, t, a, b) tmp = x * (1.0 / (y * a)); end
code[x_, y_, z_, t_, a_, b_] := N[(x * N[(1.0 / N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot \frac{1}{y \cdot a}
\end{array}
Initial program 97.6%
Taylor expanded in y around 0 79.4%
associate-/l*80.4%
div-exp68.3%
exp-to-pow69.2%
sub-neg69.2%
metadata-eval69.2%
Simplified69.2%
Taylor expanded in b around 0 58.7%
exp-to-pow59.5%
sub-neg59.5%
metadata-eval59.5%
Simplified59.5%
Taylor expanded in t around 0 34.1%
*-commutative34.1%
Simplified34.1%
Final simplification34.1%
(FPCore (x y z t a b) :precision binary64 (/ 1.0 (/ (* y a) x)))
double code(double x, double y, double z, double t, double a, double b) {
return 1.0 / ((y * a) / x);
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
code = 1.0d0 / ((y * a) / x)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return 1.0 / ((y * a) / x);
}
def code(x, y, z, t, a, b): return 1.0 / ((y * a) / x)
function code(x, y, z, t, a, b) return Float64(1.0 / Float64(Float64(y * a) / x)) end
function tmp = code(x, y, z, t, a, b) tmp = 1.0 / ((y * a) / x); end
code[x_, y_, z_, t_, a_, b_] := N[(1.0 / N[(N[(y * a), $MachinePrecision] / x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{1}{\frac{y \cdot a}{x}}
\end{array}
Initial program 97.6%
Taylor expanded in y around 0 79.4%
associate-/l*80.4%
div-exp68.3%
exp-to-pow69.2%
sub-neg69.2%
metadata-eval69.2%
Simplified69.2%
Taylor expanded in t around 0 60.2%
Taylor expanded in b around 0 34.0%
*-commutative34.0%
Simplified34.0%
clear-num34.2%
inv-pow34.2%
Applied egg-rr34.2%
unpow-134.2%
*-commutative34.2%
Simplified34.2%
Final simplification34.2%
(FPCore (x y z t a b) :precision binary64 (/ x (* y a)))
double code(double x, double y, double z, double t, double a, double b) {
return x / (y * a);
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
code = x / (y * a)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x / (y * a);
}
def code(x, y, z, t, a, b): return x / (y * a)
function code(x, y, z, t, a, b) return Float64(x / Float64(y * a)) end
function tmp = code(x, y, z, t, a, b) tmp = x / (y * a); end
code[x_, y_, z_, t_, a_, b_] := N[(x / N[(y * a), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{y \cdot a}
\end{array}
Initial program 97.6%
Taylor expanded in y around 0 79.4%
associate-/l*80.4%
div-exp68.3%
exp-to-pow69.2%
sub-neg69.2%
metadata-eval69.2%
Simplified69.2%
Taylor expanded in t around 0 60.2%
Taylor expanded in b around 0 34.0%
*-commutative34.0%
Simplified34.0%
Final simplification34.0%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (pow a (- t 1.0)))
(t_2 (/ (* x (/ t_1 y)) (- (+ b 1.0) (* y (log z))))))
(if (< t -0.8845848504127471)
t_2
(if (< t 852031.2288374073)
(/ (* (/ x y) t_1) (exp (- b (* (log z) y))))
t_2))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = pow(a, (t - 1.0));
double t_2 = (x * (t_1 / y)) / ((b + 1.0) - (y * log(z)));
double tmp;
if (t < -0.8845848504127471) {
tmp = t_2;
} else if (t < 852031.2288374073) {
tmp = ((x / y) * t_1) / exp((b - (log(z) * y)));
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
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), intent (in) :: b
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = a ** (t - 1.0d0)
t_2 = (x * (t_1 / y)) / ((b + 1.0d0) - (y * log(z)))
if (t < (-0.8845848504127471d0)) then
tmp = t_2
else if (t < 852031.2288374073d0) then
tmp = ((x / y) * t_1) / exp((b - (log(z) * y)))
else
tmp = t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = Math.pow(a, (t - 1.0));
double t_2 = (x * (t_1 / y)) / ((b + 1.0) - (y * Math.log(z)));
double tmp;
if (t < -0.8845848504127471) {
tmp = t_2;
} else if (t < 852031.2288374073) {
tmp = ((x / y) * t_1) / Math.exp((b - (Math.log(z) * y)));
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = math.pow(a, (t - 1.0)) t_2 = (x * (t_1 / y)) / ((b + 1.0) - (y * math.log(z))) tmp = 0 if t < -0.8845848504127471: tmp = t_2 elif t < 852031.2288374073: tmp = ((x / y) * t_1) / math.exp((b - (math.log(z) * y))) else: tmp = t_2 return tmp
function code(x, y, z, t, a, b) t_1 = a ^ Float64(t - 1.0) t_2 = Float64(Float64(x * Float64(t_1 / y)) / Float64(Float64(b + 1.0) - Float64(y * log(z)))) tmp = 0.0 if (t < -0.8845848504127471) tmp = t_2; elseif (t < 852031.2288374073) tmp = Float64(Float64(Float64(x / y) * t_1) / exp(Float64(b - Float64(log(z) * y)))); else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = a ^ (t - 1.0); t_2 = (x * (t_1 / y)) / ((b + 1.0) - (y * log(z))); tmp = 0.0; if (t < -0.8845848504127471) tmp = t_2; elseif (t < 852031.2288374073) tmp = ((x / y) * t_1) / exp((b - (log(z) * y))); else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$2 = N[(N[(x * N[(t$95$1 / y), $MachinePrecision]), $MachinePrecision] / N[(N[(b + 1.0), $MachinePrecision] - N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[t, -0.8845848504127471], t$95$2, If[Less[t, 852031.2288374073], N[(N[(N[(x / y), $MachinePrecision] * t$95$1), $MachinePrecision] / N[Exp[N[(b - N[(N[Log[z], $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], t$95$2]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := {a}^{\left(t - 1\right)}\\
t_2 := \frac{x \cdot \frac{t\_1}{y}}{\left(b + 1\right) - y \cdot \log z}\\
\mathbf{if}\;t < -0.8845848504127471:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t < 852031.2288374073:\\
\;\;\;\;\frac{\frac{x}{y} \cdot t\_1}{e^{b - \log z \cdot y}}\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
herbie shell --seed 2024055
(FPCore (x y z t a b)
:name "Numeric.SpecFunctions:incompleteBetaWorker from math-functions-0.1.5.2, A"
:precision binary64
:alt
(if (< t -0.8845848504127471) (/ (* x (/ (pow a (- t 1.0)) y)) (- (+ b 1.0) (* y (log z)))) (if (< t 852031.2288374073) (/ (* (/ x y) (pow a (- t 1.0))) (exp (- b (* (log z) y)))) (/ (* x (/ (pow a (- t 1.0)) y)) (- (+ b 1.0) (* y (log z))))))
(/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y))