
(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 23 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 98.3%
Final simplification98.3%
(FPCore (x y z t a b)
:precision binary64
(if (<= (+ t -1.0) -5e+67)
(/ (* x (exp (- (* (+ t -1.0) (log a)) b))) y)
(if (<= (+ t -1.0) 4e+105)
(* x (/ (exp (- (- (* y (log z)) (log a)) b)) y))
(/ (* x (pow a (+ t -1.0))) y))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t + -1.0) <= -5e+67) {
tmp = (x * exp((((t + -1.0) * log(a)) - b))) / y;
} else if ((t + -1.0) <= 4e+105) {
tmp = x * (exp((((y * log(z)) - log(a)) - b)) / y);
} else {
tmp = (x * pow(a, (t + -1.0))) / 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 ((t + (-1.0d0)) <= (-5d+67)) then
tmp = (x * exp((((t + (-1.0d0)) * log(a)) - b))) / y
else if ((t + (-1.0d0)) <= 4d+105) then
tmp = x * (exp((((y * log(z)) - log(a)) - b)) / y)
else
tmp = (x * (a ** (t + (-1.0d0)))) / 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 ((t + -1.0) <= -5e+67) {
tmp = (x * Math.exp((((t + -1.0) * Math.log(a)) - b))) / y;
} else if ((t + -1.0) <= 4e+105) {
tmp = x * (Math.exp((((y * Math.log(z)) - Math.log(a)) - b)) / y);
} else {
tmp = (x * Math.pow(a, (t + -1.0))) / y;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t + -1.0) <= -5e+67: tmp = (x * math.exp((((t + -1.0) * math.log(a)) - b))) / y elif (t + -1.0) <= 4e+105: tmp = x * (math.exp((((y * math.log(z)) - math.log(a)) - b)) / y) else: tmp = (x * math.pow(a, (t + -1.0))) / y return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (Float64(t + -1.0) <= -5e+67) tmp = Float64(Float64(x * exp(Float64(Float64(Float64(t + -1.0) * log(a)) - b))) / y); elseif (Float64(t + -1.0) <= 4e+105) tmp = Float64(x * Float64(exp(Float64(Float64(Float64(y * log(z)) - log(a)) - b)) / y)); else tmp = Float64(Float64(x * (a ^ Float64(t + -1.0))) / y); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((t + -1.0) <= -5e+67) tmp = (x * exp((((t + -1.0) * log(a)) - b))) / y; elseif ((t + -1.0) <= 4e+105) tmp = x * (exp((((y * log(z)) - log(a)) - b)) / y); else tmp = (x * (a ^ (t + -1.0))) / y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[N[(t + -1.0), $MachinePrecision], -5e+67], N[(N[(x * N[Exp[N[(N[(N[(t + -1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[N[(t + -1.0), $MachinePrecision], 4e+105], N[(x * N[(N[Exp[N[(N[(N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision] - N[Log[a], $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t + -1 \leq -5 \cdot 10^{+67}:\\
\;\;\;\;\frac{x \cdot e^{\left(t + -1\right) \cdot \log a - b}}{y}\\
\mathbf{elif}\;t + -1 \leq 4 \cdot 10^{+105}:\\
\;\;\;\;x \cdot \frac{e^{\left(y \cdot \log z - \log a\right) - b}}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x \cdot {a}^{\left(t + -1\right)}}{y}\\
\end{array}
\end{array}
if (-.f64 t 1) < -4.99999999999999976e67Initial program 100.0%
*-commutative100.0%
associate-/l*89.1%
associate--l+89.1%
fma-define89.1%
sub-neg89.1%
metadata-eval89.1%
Simplified89.1%
Taylor expanded in y around 0 95.7%
if -4.99999999999999976e67 < (-.f64 t 1) < 3.9999999999999998e105Initial program 97.5%
*-commutative97.5%
associate-/l*89.2%
associate--l+89.2%
fma-define89.2%
sub-neg89.2%
metadata-eval89.2%
Simplified89.2%
Taylor expanded in t around 0 95.6%
associate-/l*95.7%
+-commutative95.7%
mul-1-neg95.7%
unsub-neg95.7%
Simplified95.7%
if 3.9999999999999998e105 < (-.f64 t 1) Initial program 100.0%
associate-/l*100.0%
associate--l+100.0%
exp-sum78.0%
associate-/l*78.0%
*-commutative78.0%
exp-to-pow78.0%
exp-diff75.6%
*-commutative75.6%
exp-to-pow75.6%
sub-neg75.6%
metadata-eval75.6%
Simplified75.6%
Taylor expanded in y around 0 92.7%
associate-/r*92.7%
exp-to-pow92.7%
sub-neg92.7%
metadata-eval92.7%
Simplified92.7%
Taylor expanded in b around 0 97.6%
Simplified97.6%
Final simplification96.0%
(FPCore (x y z t a b)
:precision binary64
(if (<= (+ t -1.0) -5e+55)
(/ (* x (pow a t)) (* y a))
(if (<= (+ t -1.0) 2e+79)
(/ (* x (pow z y)) (* a (* y (exp b))))
(/ (* x (pow a (+ t -1.0))) y))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t + -1.0) <= -5e+55) {
tmp = (x * pow(a, t)) / (y * a);
} else if ((t + -1.0) <= 2e+79) {
tmp = (x * pow(z, y)) / (a * (y * exp(b)));
} else {
tmp = (x * pow(a, (t + -1.0))) / 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 ((t + (-1.0d0)) <= (-5d+55)) then
tmp = (x * (a ** t)) / (y * a)
else if ((t + (-1.0d0)) <= 2d+79) then
tmp = (x * (z ** y)) / (a * (y * exp(b)))
else
tmp = (x * (a ** (t + (-1.0d0)))) / 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 ((t + -1.0) <= -5e+55) {
tmp = (x * Math.pow(a, t)) / (y * a);
} else if ((t + -1.0) <= 2e+79) {
tmp = (x * Math.pow(z, y)) / (a * (y * Math.exp(b)));
} else {
tmp = (x * Math.pow(a, (t + -1.0))) / y;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t + -1.0) <= -5e+55: tmp = (x * math.pow(a, t)) / (y * a) elif (t + -1.0) <= 2e+79: tmp = (x * math.pow(z, y)) / (a * (y * math.exp(b))) else: tmp = (x * math.pow(a, (t + -1.0))) / y return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (Float64(t + -1.0) <= -5e+55) tmp = Float64(Float64(x * (a ^ t)) / Float64(y * a)); elseif (Float64(t + -1.0) <= 2e+79) tmp = Float64(Float64(x * (z ^ y)) / Float64(a * Float64(y * exp(b)))); else tmp = Float64(Float64(x * (a ^ Float64(t + -1.0))) / y); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((t + -1.0) <= -5e+55) tmp = (x * (a ^ t)) / (y * a); elseif ((t + -1.0) <= 2e+79) tmp = (x * (z ^ y)) / (a * (y * exp(b))); else tmp = (x * (a ^ (t + -1.0))) / y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[N[(t + -1.0), $MachinePrecision], -5e+55], N[(N[(x * N[Power[a, t], $MachinePrecision]), $MachinePrecision] / N[(y * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(t + -1.0), $MachinePrecision], 2e+79], N[(N[(x * N[Power[z, y], $MachinePrecision]), $MachinePrecision] / N[(a * N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t + -1 \leq -5 \cdot 10^{+55}:\\
\;\;\;\;\frac{x \cdot {a}^{t}}{y \cdot a}\\
\mathbf{elif}\;t + -1 \leq 2 \cdot 10^{+79}:\\
\;\;\;\;\frac{x \cdot {z}^{y}}{a \cdot \left(y \cdot e^{b}\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{x \cdot {a}^{\left(t + -1\right)}}{y}\\
\end{array}
\end{array}
if (-.f64 t 1) < -5.00000000000000046e55Initial program 100.0%
associate-/l*100.0%
associate--l+100.0%
exp-sum76.5%
associate-/l*76.5%
*-commutative76.5%
exp-to-pow76.5%
exp-diff70.6%
*-commutative70.6%
exp-to-pow70.6%
sub-neg70.6%
metadata-eval70.6%
Simplified70.6%
Taylor expanded in y around 0 82.4%
associate-/r*82.4%
exp-to-pow82.4%
sub-neg82.4%
metadata-eval82.4%
Simplified82.4%
unpow-prod-up82.4%
unpow-182.4%
Applied egg-rr82.4%
associate-*r/82.4%
*-rgt-identity82.4%
Simplified82.4%
Taylor expanded in b around 0 92.3%
if -5.00000000000000046e55 < (-.f64 t 1) < 1.99999999999999993e79Initial program 97.3%
associate-/l*97.9%
associate--l+97.9%
exp-sum82.9%
associate-/l*81.0%
*-commutative81.0%
exp-to-pow81.0%
exp-diff76.7%
*-commutative76.7%
exp-to-pow77.4%
sub-neg77.4%
metadata-eval77.4%
Simplified77.4%
Taylor expanded in t around 0 82.5%
if 1.99999999999999993e79 < (-.f64 t 1) Initial program 100.0%
associate-/l*100.0%
associate--l+100.0%
exp-sum73.3%
associate-/l*73.3%
*-commutative73.3%
exp-to-pow73.3%
exp-diff71.1%
*-commutative71.1%
exp-to-pow71.1%
sub-neg71.1%
metadata-eval71.1%
Simplified71.1%
Taylor expanded in y around 0 89.0%
associate-/r*89.0%
exp-to-pow89.0%
sub-neg89.0%
metadata-eval89.0%
Simplified89.0%
Taylor expanded in b around 0 93.4%
Simplified93.4%
Final simplification86.4%
(FPCore (x y z t a b) :precision binary64 (if (or (<= b -6.8e+80) (not (<= b 0.95))) (/ x (* y (exp b))) (* x (* (pow a (+ t -1.0)) (/ (pow z y) y)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -6.8e+80) || !(b <= 0.95)) {
tmp = x / (y * exp(b));
} else {
tmp = x * (pow(a, (t + -1.0)) * (pow(z, y) / 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 ((b <= (-6.8d+80)) .or. (.not. (b <= 0.95d0))) then
tmp = x / (y * exp(b))
else
tmp = x * ((a ** (t + (-1.0d0))) * ((z ** y) / 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 ((b <= -6.8e+80) || !(b <= 0.95)) {
tmp = x / (y * Math.exp(b));
} else {
tmp = x * (Math.pow(a, (t + -1.0)) * (Math.pow(z, y) / y));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (b <= -6.8e+80) or not (b <= 0.95): tmp = x / (y * math.exp(b)) else: tmp = x * (math.pow(a, (t + -1.0)) * (math.pow(z, y) / y)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -6.8e+80) || !(b <= 0.95)) tmp = Float64(x / Float64(y * exp(b))); else tmp = Float64(x * Float64((a ^ Float64(t + -1.0)) * Float64((z ^ y) / y))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((b <= -6.8e+80) || ~((b <= 0.95))) tmp = x / (y * exp(b)); else tmp = x * ((a ^ (t + -1.0)) * ((z ^ y) / y)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -6.8e+80], N[Not[LessEqual[b, 0.95]], $MachinePrecision]], N[(x / N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision] * N[(N[Power[z, y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -6.8 \cdot 10^{+80} \lor \neg \left(b \leq 0.95\right):\\
\;\;\;\;\frac{x}{y \cdot e^{b}}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left({a}^{\left(t + -1\right)} \cdot \frac{{z}^{y}}{y}\right)\\
\end{array}
\end{array}
if b < -6.79999999999999984e80 or 0.94999999999999996 < b Initial program 100.0%
*-commutative100.0%
associate-/l*89.8%
associate--l+89.8%
fma-define89.8%
sub-neg89.8%
metadata-eval89.8%
Simplified89.8%
Taylor expanded in b around inf 77.1%
neg-mul-177.1%
Simplified77.1%
Taylor expanded in b around inf 84.5%
associate-*l/77.1%
exp-neg77.1%
times-frac84.5%
*-rgt-identity84.5%
Simplified84.5%
if -6.79999999999999984e80 < b < 0.94999999999999996Initial program 97.1%
associate-/l*97.8%
associate--l+97.8%
exp-sum86.9%
associate-/l*84.9%
*-commutative84.9%
exp-to-pow84.9%
exp-diff84.2%
*-commutative84.2%
exp-to-pow85.1%
sub-neg85.1%
metadata-eval85.1%
Simplified85.1%
Taylor expanded in b around 0 87.0%
associate-/l*87.0%
exp-to-pow87.8%
sub-neg87.8%
metadata-eval87.8%
Simplified87.8%
Final simplification86.4%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -8e+16) (not (<= y 2.6e+95))) (* 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 <= -8e+16) || !(y <= 2.6e+95)) {
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 <= (-8d+16)) .or. (.not. (y <= 2.6d+95))) 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 <= -8e+16) || !(y <= 2.6e+95)) {
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 <= -8e+16) or not (y <= 2.6e+95): 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 <= -8e+16) || !(y <= 2.6e+95)) tmp = Float64(x * Float64(Float64((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 <= -8e+16) || ~((y <= 2.6e+95))) 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, -8e+16], N[Not[LessEqual[y, 2.6e+95]], $MachinePrecision]], N[(x * N[(N[(N[Power[z, y], $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision]), $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 -8 \cdot 10^{+16} \lor \neg \left(y \leq 2.6 \cdot 10^{+95}\right):\\
\;\;\;\;x \cdot \frac{\frac{{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 < -8e16 or 2.5999999999999999e95 < y Initial program 100.0%
*-commutative100.0%
associate-/l*87.1%
associate--l+87.1%
fma-define87.1%
sub-neg87.1%
metadata-eval87.1%
Simplified87.1%
Taylor expanded in t around 0 91.2%
associate-/l*91.2%
+-commutative91.2%
mul-1-neg91.2%
unsub-neg91.2%
Simplified91.2%
Taylor expanded in b around 0 81.5%
div-exp81.5%
*-commutative81.5%
exp-to-pow81.5%
rem-exp-log81.5%
Simplified81.5%
if -8e16 < y < 2.5999999999999999e95Initial program 97.2%
*-commutative97.2%
associate-/l*90.8%
associate--l+90.8%
fma-define90.8%
sub-neg90.8%
metadata-eval90.8%
Simplified90.8%
Taylor expanded in y around 0 95.4%
Final simplification89.9%
(FPCore (x y z t a b)
:precision binary64
(if (<= b -1.05e+79)
(* (exp (- (* (+ t -1.0) (log a)) b)) (/ x y))
(if (<= b 0.95)
(* x (* (pow a (+ t -1.0)) (/ (pow z y) y)))
(/ x (* y (exp b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -1.05e+79) {
tmp = exp((((t + -1.0) * log(a)) - b)) * (x / y);
} else if (b <= 0.95) {
tmp = x * (pow(a, (t + -1.0)) * (pow(z, y) / y));
} else {
tmp = x / (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 (b <= (-1.05d+79)) then
tmp = exp((((t + (-1.0d0)) * log(a)) - b)) * (x / y)
else if (b <= 0.95d0) then
tmp = x * ((a ** (t + (-1.0d0))) * ((z ** y) / y))
else
tmp = x / (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 (b <= -1.05e+79) {
tmp = Math.exp((((t + -1.0) * Math.log(a)) - b)) * (x / y);
} else if (b <= 0.95) {
tmp = x * (Math.pow(a, (t + -1.0)) * (Math.pow(z, y) / y));
} else {
tmp = x / (y * Math.exp(b));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -1.05e+79: tmp = math.exp((((t + -1.0) * math.log(a)) - b)) * (x / y) elif b <= 0.95: tmp = x * (math.pow(a, (t + -1.0)) * (math.pow(z, y) / y)) else: tmp = x / (y * math.exp(b)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -1.05e+79) tmp = Float64(exp(Float64(Float64(Float64(t + -1.0) * log(a)) - b)) * Float64(x / y)); elseif (b <= 0.95) tmp = Float64(x * Float64((a ^ Float64(t + -1.0)) * Float64((z ^ y) / y))); else tmp = Float64(x / Float64(y * exp(b))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -1.05e+79) tmp = exp((((t + -1.0) * log(a)) - b)) * (x / y); elseif (b <= 0.95) tmp = x * ((a ^ (t + -1.0)) * ((z ^ y) / y)); else tmp = x / (y * exp(b)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -1.05e+79], N[(N[Exp[N[(N[(N[(t + -1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision] * N[(x / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 0.95], N[(x * N[(N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision] * N[(N[Power[z, y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.05 \cdot 10^{+79}:\\
\;\;\;\;e^{\left(t + -1\right) \cdot \log a - b} \cdot \frac{x}{y}\\
\mathbf{elif}\;b \leq 0.95:\\
\;\;\;\;x \cdot \left({a}^{\left(t + -1\right)} \cdot \frac{{z}^{y}}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot e^{b}}\\
\end{array}
\end{array}
if b < -1.05000000000000004e79Initial program 100.0%
*-commutative100.0%
associate-/l*94.0%
associate--l+94.0%
fma-define94.0%
sub-neg94.0%
metadata-eval94.0%
Simplified94.0%
Taylor expanded in y around 0 84.1%
if -1.05000000000000004e79 < b < 0.94999999999999996Initial program 97.1%
associate-/l*97.8%
associate--l+97.8%
exp-sum86.9%
associate-/l*84.9%
*-commutative84.9%
exp-to-pow84.9%
exp-diff84.2%
*-commutative84.2%
exp-to-pow85.1%
sub-neg85.1%
metadata-eval85.1%
Simplified85.1%
Taylor expanded in b around 0 87.0%
associate-/l*87.0%
exp-to-pow87.8%
sub-neg87.8%
metadata-eval87.8%
Simplified87.8%
if 0.94999999999999996 < b Initial program 100.0%
*-commutative100.0%
associate-/l*86.2%
associate--l+86.2%
fma-define86.2%
sub-neg86.2%
metadata-eval86.2%
Simplified86.2%
Taylor expanded in b around inf 77.8%
neg-mul-177.8%
Simplified77.8%
Taylor expanded in b around inf 86.4%
associate-*l/77.8%
exp-neg77.8%
times-frac86.4%
*-rgt-identity86.4%
Simplified86.4%
Final simplification86.8%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -9.5e+16) (not (<= y 5.2e+94))) (* x (/ (/ (pow z y) a) y)) (* x (/ (/ (/ (pow a t) a) y) (exp b)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -9.5e+16) || !(y <= 5.2e+94)) {
tmp = x * ((pow(z, y) / a) / y);
} else {
tmp = x * (((pow(a, t) / 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 <= (-9.5d+16)) .or. (.not. (y <= 5.2d+94))) then
tmp = x * (((z ** y) / a) / y)
else
tmp = x * ((((a ** t) / 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 <= -9.5e+16) || !(y <= 5.2e+94)) {
tmp = x * ((Math.pow(z, y) / a) / y);
} else {
tmp = x * (((Math.pow(a, t) / a) / y) / Math.exp(b));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -9.5e+16) or not (y <= 5.2e+94): tmp = x * ((math.pow(z, y) / a) / y) else: tmp = x * (((math.pow(a, t) / a) / y) / math.exp(b)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -9.5e+16) || !(y <= 5.2e+94)) tmp = Float64(x * Float64(Float64((z ^ y) / a) / y)); else tmp = Float64(x * Float64(Float64(Float64((a ^ t) / a) / y) / exp(b))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -9.5e+16) || ~((y <= 5.2e+94))) tmp = x * (((z ^ y) / a) / y); else tmp = x * ((((a ^ t) / a) / y) / exp(b)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -9.5e+16], N[Not[LessEqual[y, 5.2e+94]], $MachinePrecision]], N[(x * N[(N[(N[Power[z, y], $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(N[(N[Power[a, t], $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision] / N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -9.5 \cdot 10^{+16} \lor \neg \left(y \leq 5.2 \cdot 10^{+94}\right):\\
\;\;\;\;x \cdot \frac{\frac{{z}^{y}}{a}}{y}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{\frac{\frac{{a}^{t}}{a}}{y}}{e^{b}}\\
\end{array}
\end{array}
if y < -9.5e16 or 5.1999999999999998e94 < y Initial program 100.0%
*-commutative100.0%
associate-/l*87.3%
associate--l+87.3%
fma-define87.3%
sub-neg87.3%
metadata-eval87.3%
Simplified87.3%
Taylor expanded in t around 0 91.3%
associate-/l*91.3%
+-commutative91.3%
mul-1-neg91.3%
unsub-neg91.3%
Simplified91.3%
Taylor expanded in b around 0 80.7%
div-exp80.7%
*-commutative80.7%
exp-to-pow80.7%
rem-exp-log80.7%
Simplified80.7%
if -9.5e16 < y < 5.1999999999999998e94Initial program 97.2%
associate-/l*97.8%
associate--l+97.8%
exp-sum92.0%
associate-/l*92.0%
*-commutative92.0%
exp-to-pow92.0%
exp-diff86.8%
*-commutative86.8%
exp-to-pow87.6%
sub-neg87.6%
metadata-eval87.6%
Simplified87.6%
Taylor expanded in y around 0 90.8%
associate-/r*88.2%
exp-to-pow89.0%
sub-neg89.0%
metadata-eval89.0%
Simplified89.0%
unpow-prod-up89.1%
unpow-189.1%
Applied egg-rr89.1%
associate-*r/89.1%
*-rgt-identity89.1%
Simplified89.1%
Final simplification85.7%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ x (* y (exp b)))))
(if (<= b -1.3e+48)
t_1
(if (<= b 1.9e-257)
(* (pow a (+ t -1.0)) (/ x y))
(if (<= b 0.95) (* x (/ (/ (pow z y) a) y)) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (y * exp(b));
double tmp;
if (b <= -1.3e+48) {
tmp = t_1;
} else if (b <= 1.9e-257) {
tmp = pow(a, (t + -1.0)) * (x / y);
} else if (b <= 0.95) {
tmp = x * ((pow(z, y) / a) / 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 / (y * exp(b))
if (b <= (-1.3d+48)) then
tmp = t_1
else if (b <= 1.9d-257) then
tmp = (a ** (t + (-1.0d0))) * (x / y)
else if (b <= 0.95d0) then
tmp = x * (((z ** y) / a) / 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 / (y * Math.exp(b));
double tmp;
if (b <= -1.3e+48) {
tmp = t_1;
} else if (b <= 1.9e-257) {
tmp = Math.pow(a, (t + -1.0)) * (x / y);
} else if (b <= 0.95) {
tmp = x * ((Math.pow(z, y) / a) / y);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x / (y * math.exp(b)) tmp = 0 if b <= -1.3e+48: tmp = t_1 elif b <= 1.9e-257: tmp = math.pow(a, (t + -1.0)) * (x / y) elif b <= 0.95: tmp = x * ((math.pow(z, y) / a) / y) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x / Float64(y * exp(b))) tmp = 0.0 if (b <= -1.3e+48) tmp = t_1; elseif (b <= 1.9e-257) tmp = Float64((a ^ Float64(t + -1.0)) * Float64(x / y)); elseif (b <= 0.95) tmp = Float64(x * Float64(Float64((z ^ y) / a) / y)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x / (y * exp(b)); tmp = 0.0; if (b <= -1.3e+48) tmp = t_1; elseif (b <= 1.9e-257) tmp = (a ^ (t + -1.0)) * (x / y); elseif (b <= 0.95) tmp = x * (((z ^ y) / a) / y); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x / N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -1.3e+48], t$95$1, If[LessEqual[b, 1.9e-257], N[(N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision] * N[(x / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 0.95], N[(x * N[(N[(N[Power[z, y], $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{y \cdot e^{b}}\\
\mathbf{if}\;b \leq -1.3 \cdot 10^{+48}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq 1.9 \cdot 10^{-257}:\\
\;\;\;\;{a}^{\left(t + -1\right)} \cdot \frac{x}{y}\\
\mathbf{elif}\;b \leq 0.95:\\
\;\;\;\;x \cdot \frac{\frac{{z}^{y}}{a}}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -1.29999999999999998e48 or 0.94999999999999996 < b Initial program 100.0%
*-commutative100.0%
associate-/l*87.8%
associate--l+87.8%
fma-define87.8%
sub-neg87.8%
metadata-eval87.8%
Simplified87.8%
Taylor expanded in b around inf 74.1%
neg-mul-174.1%
Simplified74.1%
Taylor expanded in b around inf 83.7%
associate-*l/74.1%
exp-neg74.1%
times-frac83.7%
*-rgt-identity83.7%
Simplified83.7%
if -1.29999999999999998e48 < b < 1.9000000000000002e-257Initial program 95.8%
*-commutative95.8%
associate-/l*96.5%
associate--l+96.5%
fma-define96.5%
sub-neg96.5%
metadata-eval96.5%
Simplified96.5%
Taylor expanded in y around 0 80.9%
Taylor expanded in b around 0 78.5%
exp-to-pow79.2%
sub-neg79.2%
metadata-eval79.2%
+-commutative79.2%
Simplified79.2%
if 1.9000000000000002e-257 < b < 0.94999999999999996Initial program 98.5%
*-commutative98.5%
associate-/l*82.9%
associate--l+82.9%
fma-define82.9%
sub-neg82.9%
metadata-eval82.9%
Simplified82.9%
Taylor expanded in t around 0 78.9%
associate-/l*77.6%
+-commutative77.6%
mul-1-neg77.6%
unsub-neg77.6%
Simplified77.6%
Taylor expanded in b around 0 77.6%
div-exp77.6%
*-commutative77.6%
exp-to-pow77.6%
rem-exp-log78.7%
Simplified78.7%
Final simplification81.1%
(FPCore (x y z t a b)
:precision binary64
(if (<= (+ t -1.0) -5e+55)
(/ (* x (pow a t)) (* y a))
(if (<= (+ t -1.0) 4e+105)
(/ x (* a (* y (exp b))))
(/ (* x (pow a (+ t -1.0))) y))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t + -1.0) <= -5e+55) {
tmp = (x * pow(a, t)) / (y * a);
} else if ((t + -1.0) <= 4e+105) {
tmp = x / (a * (y * exp(b)));
} else {
tmp = (x * pow(a, (t + -1.0))) / 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 ((t + (-1.0d0)) <= (-5d+55)) then
tmp = (x * (a ** t)) / (y * a)
else if ((t + (-1.0d0)) <= 4d+105) then
tmp = x / (a * (y * exp(b)))
else
tmp = (x * (a ** (t + (-1.0d0)))) / 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 ((t + -1.0) <= -5e+55) {
tmp = (x * Math.pow(a, t)) / (y * a);
} else if ((t + -1.0) <= 4e+105) {
tmp = x / (a * (y * Math.exp(b)));
} else {
tmp = (x * Math.pow(a, (t + -1.0))) / y;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t + -1.0) <= -5e+55: tmp = (x * math.pow(a, t)) / (y * a) elif (t + -1.0) <= 4e+105: tmp = x / (a * (y * math.exp(b))) else: tmp = (x * math.pow(a, (t + -1.0))) / y return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (Float64(t + -1.0) <= -5e+55) tmp = Float64(Float64(x * (a ^ t)) / Float64(y * a)); elseif (Float64(t + -1.0) <= 4e+105) tmp = Float64(x / Float64(a * Float64(y * exp(b)))); else tmp = Float64(Float64(x * (a ^ Float64(t + -1.0))) / y); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((t + -1.0) <= -5e+55) tmp = (x * (a ^ t)) / (y * a); elseif ((t + -1.0) <= 4e+105) tmp = x / (a * (y * exp(b))); else tmp = (x * (a ^ (t + -1.0))) / y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[N[(t + -1.0), $MachinePrecision], -5e+55], N[(N[(x * N[Power[a, t], $MachinePrecision]), $MachinePrecision] / N[(y * a), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(t + -1.0), $MachinePrecision], 4e+105], N[(x / N[(a * N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x * N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t + -1 \leq -5 \cdot 10^{+55}:\\
\;\;\;\;\frac{x \cdot {a}^{t}}{y \cdot a}\\
\mathbf{elif}\;t + -1 \leq 4 \cdot 10^{+105}:\\
\;\;\;\;\frac{x}{a \cdot \left(y \cdot e^{b}\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{x \cdot {a}^{\left(t + -1\right)}}{y}\\
\end{array}
\end{array}
if (-.f64 t 1) < -5.00000000000000046e55Initial program 100.0%
associate-/l*100.0%
associate--l+100.0%
exp-sum76.5%
associate-/l*76.5%
*-commutative76.5%
exp-to-pow76.5%
exp-diff70.6%
*-commutative70.6%
exp-to-pow70.6%
sub-neg70.6%
metadata-eval70.6%
Simplified70.6%
Taylor expanded in y around 0 82.4%
associate-/r*82.4%
exp-to-pow82.4%
sub-neg82.4%
metadata-eval82.4%
Simplified82.4%
unpow-prod-up82.4%
unpow-182.4%
Applied egg-rr82.4%
associate-*r/82.4%
*-rgt-identity82.4%
Simplified82.4%
Taylor expanded in b around 0 92.3%
if -5.00000000000000046e55 < (-.f64 t 1) < 3.9999999999999998e105Initial program 97.4%
*-commutative97.4%
associate-/l*88.9%
associate--l+88.9%
fma-define88.9%
sub-neg88.9%
metadata-eval88.9%
Simplified88.9%
Taylor expanded in t around 0 95.5%
associate-/l*95.6%
+-commutative95.6%
mul-1-neg95.6%
unsub-neg95.6%
Simplified95.6%
Taylor expanded in y around 0 70.7%
exp-neg70.7%
associate-*r/70.7%
*-rgt-identity70.7%
+-commutative70.7%
exp-sum70.7%
rem-exp-log71.5%
associate-/r*66.0%
associate-/r*66.0%
*-commutative66.0%
associate-/r*72.1%
Simplified72.1%
if 3.9999999999999998e105 < (-.f64 t 1) Initial program 100.0%
associate-/l*100.0%
associate--l+100.0%
exp-sum78.0%
associate-/l*78.0%
*-commutative78.0%
exp-to-pow78.0%
exp-diff75.6%
*-commutative75.6%
exp-to-pow75.6%
sub-neg75.6%
metadata-eval75.6%
Simplified75.6%
Taylor expanded in y around 0 92.7%
associate-/r*92.7%
exp-to-pow92.7%
sub-neg92.7%
metadata-eval92.7%
Simplified92.7%
Taylor expanded in b around 0 97.6%
Simplified97.6%
Final simplification80.2%
(FPCore (x y z t a b) :precision binary64 (if (or (<= b -780.0) (not (<= b 0.95))) (/ x (* y (exp b))) (* x (/ (/ (pow z y) a) y))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -780.0) || !(b <= 0.95)) {
tmp = x / (y * exp(b));
} else {
tmp = x * ((pow(z, y) / a) / 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 ((b <= (-780.0d0)) .or. (.not. (b <= 0.95d0))) then
tmp = x / (y * exp(b))
else
tmp = x * (((z ** y) / a) / 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 ((b <= -780.0) || !(b <= 0.95)) {
tmp = x / (y * Math.exp(b));
} else {
tmp = x * ((Math.pow(z, y) / a) / y);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (b <= -780.0) or not (b <= 0.95): tmp = x / (y * math.exp(b)) else: tmp = x * ((math.pow(z, y) / a) / y) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -780.0) || !(b <= 0.95)) tmp = Float64(x / Float64(y * exp(b))); else tmp = Float64(x * Float64(Float64((z ^ y) / a) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((b <= -780.0) || ~((b <= 0.95))) tmp = x / (y * exp(b)); else tmp = x * (((z ^ y) / a) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -780.0], N[Not[LessEqual[b, 0.95]], $MachinePrecision]], N[(x / N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(N[Power[z, y], $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -780 \lor \neg \left(b \leq 0.95\right):\\
\;\;\;\;\frac{x}{y \cdot e^{b}}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{\frac{{z}^{y}}{a}}{y}\\
\end{array}
\end{array}
if b < -780 or 0.94999999999999996 < b Initial program 100.0%
*-commutative100.0%
associate-/l*88.6%
associate--l+88.6%
fma-define88.6%
sub-neg88.6%
metadata-eval88.6%
Simplified88.6%
Taylor expanded in b around inf 74.2%
neg-mul-174.2%
Simplified74.2%
Taylor expanded in b around inf 83.2%
associate-*l/74.2%
exp-neg74.2%
times-frac83.2%
*-rgt-identity83.2%
Simplified83.2%
if -780 < b < 0.94999999999999996Initial program 96.8%
*-commutative96.8%
associate-/l*90.1%
associate--l+90.1%
fma-define90.1%
sub-neg90.1%
metadata-eval90.1%
Simplified90.1%
Taylor expanded in t around 0 69.5%
associate-/l*70.4%
+-commutative70.4%
mul-1-neg70.4%
unsub-neg70.4%
Simplified70.4%
Taylor expanded in b around 0 70.4%
div-exp70.4%
*-commutative70.4%
exp-to-pow70.4%
rem-exp-log71.3%
Simplified71.3%
Final simplification77.0%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -4e+217) (not (<= y -1.06e+136))) (/ x (* a (* y (exp b)))) (* x (/ (exp b) y))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -4e+217) || !(y <= -1.06e+136)) {
tmp = x / (a * (y * exp(b)));
} else {
tmp = x * (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 <= (-4d+217)) .or. (.not. (y <= (-1.06d+136)))) then
tmp = x / (a * (y * exp(b)))
else
tmp = x * (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 <= -4e+217) || !(y <= -1.06e+136)) {
tmp = x / (a * (y * Math.exp(b)));
} else {
tmp = x * (Math.exp(b) / y);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -4e+217) or not (y <= -1.06e+136): tmp = x / (a * (y * math.exp(b))) else: tmp = x * (math.exp(b) / y) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -4e+217) || !(y <= -1.06e+136)) tmp = Float64(x / Float64(a * Float64(y * exp(b)))); else tmp = Float64(x * Float64(exp(b) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -4e+217) || ~((y <= -1.06e+136))) tmp = x / (a * (y * exp(b))); else tmp = x * (exp(b) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -4e+217], N[Not[LessEqual[y, -1.06e+136]], $MachinePrecision]], N[(x / N[(a * N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[Exp[b], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4 \cdot 10^{+217} \lor \neg \left(y \leq -1.06 \cdot 10^{+136}\right):\\
\;\;\;\;\frac{x}{a \cdot \left(y \cdot e^{b}\right)}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{e^{b}}{y}\\
\end{array}
\end{array}
if y < -3.99999999999999984e217 or -1.06000000000000003e136 < y Initial program 98.2%
*-commutative98.2%
associate-/l*88.9%
associate--l+88.9%
fma-define88.9%
sub-neg88.9%
metadata-eval88.9%
Simplified88.9%
Taylor expanded in t around 0 81.6%
associate-/l*82.1%
+-commutative82.1%
mul-1-neg82.1%
unsub-neg82.1%
Simplified82.1%
Taylor expanded in y around 0 63.9%
exp-neg63.9%
associate-*r/63.9%
*-rgt-identity63.9%
+-commutative63.9%
exp-sum63.9%
rem-exp-log64.5%
associate-/r*59.8%
associate-/r*59.8%
*-commutative59.8%
associate-/r*65.7%
Simplified65.7%
if -3.99999999999999984e217 < y < -1.06000000000000003e136Initial program 100.0%
*-commutative100.0%
associate-/l*95.0%
associate--l+95.0%
fma-define95.0%
sub-neg95.0%
metadata-eval95.0%
Simplified95.0%
Taylor expanded in b around inf 26.6%
neg-mul-126.6%
Simplified26.6%
Taylor expanded in b around inf 26.6%
associate-*r/26.6%
Simplified26.6%
associate-*r/26.6%
add-sqr-sqrt10.7%
sqrt-unprod41.4%
sqr-neg41.4%
sqrt-unprod30.7%
add-sqr-sqrt70.9%
Applied egg-rr70.9%
associate-*r/70.9%
Simplified70.9%
Final simplification66.1%
(FPCore (x y z t a b) :precision binary64 (if (or (<= b -7.2e-19) (not (<= b 0.0005))) (/ x (* y (exp b))) (/ x (* y (+ a (* b (+ a (* 0.5 (* a b)))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -7.2e-19) || !(b <= 0.0005)) {
tmp = x / (y * exp(b));
} else {
tmp = x / (y * (a + (b * (a + (0.5 * (a * 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 <= (-7.2d-19)) .or. (.not. (b <= 0.0005d0))) then
tmp = x / (y * exp(b))
else
tmp = x / (y * (a + (b * (a + (0.5d0 * (a * 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 <= -7.2e-19) || !(b <= 0.0005)) {
tmp = x / (y * Math.exp(b));
} else {
tmp = x / (y * (a + (b * (a + (0.5 * (a * b))))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (b <= -7.2e-19) or not (b <= 0.0005): tmp = x / (y * math.exp(b)) else: tmp = x / (y * (a + (b * (a + (0.5 * (a * b)))))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -7.2e-19) || !(b <= 0.0005)) tmp = Float64(x / Float64(y * exp(b))); else tmp = Float64(x / Float64(y * Float64(a + Float64(b * Float64(a + Float64(0.5 * Float64(a * b))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((b <= -7.2e-19) || ~((b <= 0.0005))) tmp = x / (y * exp(b)); else tmp = x / (y * (a + (b * (a + (0.5 * (a * b)))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -7.2e-19], N[Not[LessEqual[b, 0.0005]], $MachinePrecision]], N[(x / N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * N[(a + N[(b * N[(a + N[(0.5 * N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -7.2 \cdot 10^{-19} \lor \neg \left(b \leq 0.0005\right):\\
\;\;\;\;\frac{x}{y \cdot e^{b}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot \left(a + b \cdot \left(a + 0.5 \cdot \left(a \cdot b\right)\right)\right)}\\
\end{array}
\end{array}
if b < -7.2000000000000002e-19 or 5.0000000000000001e-4 < b Initial program 100.0%
*-commutative100.0%
associate-/l*89.1%
associate--l+89.1%
fma-define89.1%
sub-neg89.1%
metadata-eval89.1%
Simplified89.1%
Taylor expanded in b around inf 72.4%
neg-mul-172.4%
Simplified72.4%
Taylor expanded in b around inf 81.0%
associate-*l/72.4%
exp-neg72.4%
times-frac81.0%
*-rgt-identity81.0%
Simplified81.0%
if -7.2000000000000002e-19 < b < 5.0000000000000001e-4Initial program 96.6%
associate-/l*97.4%
associate--l+97.4%
exp-sum87.9%
associate-/l*86.4%
*-commutative86.4%
exp-to-pow86.4%
exp-diff86.4%
*-commutative86.4%
exp-to-pow87.3%
sub-neg87.3%
metadata-eval87.3%
Simplified87.3%
Taylor expanded in y around 0 76.8%
associate-/r*76.8%
exp-to-pow77.8%
sub-neg77.8%
metadata-eval77.8%
Simplified77.8%
unpow-prod-up77.9%
unpow-177.9%
Applied egg-rr77.9%
associate-*r/77.9%
*-rgt-identity77.9%
Simplified77.9%
Taylor expanded in t around 0 44.1%
associate-*r*44.1%
*-commutative44.1%
associate-*l*44.1%
Simplified44.1%
Taylor expanded in b around 0 44.1%
Final simplification62.7%
(FPCore (x y z t a b)
:precision binary64
(if (<= b -7.2e-19)
(*
x
(+
(/ 1.0 y)
(*
b
(+
(* b (+ (* -0.16666666666666666 (/ b y)) (* 0.5 (/ 1.0 y))))
(/ -1.0 y)))))
(/
x
(*
y
(+ a (* b (+ a (* b (+ (* (* a b) 0.16666666666666666) (* a 0.5))))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -7.2e-19) {
tmp = x * ((1.0 / y) + (b * ((b * ((-0.16666666666666666 * (b / y)) + (0.5 * (1.0 / y)))) + (-1.0 / y))));
} else {
tmp = x / (y * (a + (b * (a + (b * (((a * b) * 0.16666666666666666) + (a * 0.5)))))));
}
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 <= (-7.2d-19)) then
tmp = x * ((1.0d0 / y) + (b * ((b * (((-0.16666666666666666d0) * (b / y)) + (0.5d0 * (1.0d0 / y)))) + ((-1.0d0) / y))))
else
tmp = x / (y * (a + (b * (a + (b * (((a * b) * 0.16666666666666666d0) + (a * 0.5d0)))))))
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 <= -7.2e-19) {
tmp = x * ((1.0 / y) + (b * ((b * ((-0.16666666666666666 * (b / y)) + (0.5 * (1.0 / y)))) + (-1.0 / y))));
} else {
tmp = x / (y * (a + (b * (a + (b * (((a * b) * 0.16666666666666666) + (a * 0.5)))))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -7.2e-19: tmp = x * ((1.0 / y) + (b * ((b * ((-0.16666666666666666 * (b / y)) + (0.5 * (1.0 / y)))) + (-1.0 / y)))) else: tmp = x / (y * (a + (b * (a + (b * (((a * b) * 0.16666666666666666) + (a * 0.5))))))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -7.2e-19) tmp = Float64(x * Float64(Float64(1.0 / y) + Float64(b * Float64(Float64(b * Float64(Float64(-0.16666666666666666 * Float64(b / y)) + Float64(0.5 * Float64(1.0 / y)))) + Float64(-1.0 / y))))); else tmp = Float64(x / Float64(y * Float64(a + Float64(b * Float64(a + Float64(b * Float64(Float64(Float64(a * b) * 0.16666666666666666) + Float64(a * 0.5)))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -7.2e-19) tmp = x * ((1.0 / y) + (b * ((b * ((-0.16666666666666666 * (b / y)) + (0.5 * (1.0 / y)))) + (-1.0 / y)))); else tmp = x / (y * (a + (b * (a + (b * (((a * b) * 0.16666666666666666) + (a * 0.5))))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -7.2e-19], N[(x * N[(N[(1.0 / y), $MachinePrecision] + N[(b * N[(N[(b * N[(N[(-0.16666666666666666 * N[(b / y), $MachinePrecision]), $MachinePrecision] + N[(0.5 * N[(1.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-1.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * N[(a + N[(b * N[(a + N[(b * N[(N[(N[(a * b), $MachinePrecision] * 0.16666666666666666), $MachinePrecision] + N[(a * 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -7.2 \cdot 10^{-19}:\\
\;\;\;\;x \cdot \left(\frac{1}{y} + b \cdot \left(b \cdot \left(-0.16666666666666666 \cdot \frac{b}{y} + 0.5 \cdot \frac{1}{y}\right) + \frac{-1}{y}\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot \left(a + b \cdot \left(a + b \cdot \left(\left(a \cdot b\right) \cdot 0.16666666666666666 + a \cdot 0.5\right)\right)\right)}\\
\end{array}
\end{array}
if b < -7.2000000000000002e-19Initial program 100.0%
*-commutative100.0%
associate-/l*91.4%
associate--l+91.4%
fma-define91.4%
sub-neg91.4%
metadata-eval91.4%
Simplified91.4%
Taylor expanded in b around inf 68.9%
neg-mul-168.9%
Simplified68.9%
Taylor expanded in b around 0 58.7%
Taylor expanded in x around 0 65.2%
if -7.2000000000000002e-19 < b Initial program 97.7%
associate-/l*98.2%
associate--l+98.2%
exp-sum83.7%
associate-/l*82.6%
*-commutative82.6%
exp-to-pow82.6%
exp-diff81.5%
*-commutative81.5%
exp-to-pow82.2%
sub-neg82.2%
metadata-eval82.2%
Simplified82.2%
Taylor expanded in y around 0 77.2%
associate-/r*75.1%
exp-to-pow75.8%
sub-neg75.8%
metadata-eval75.8%
Simplified75.8%
unpow-prod-up75.8%
unpow-175.8%
Applied egg-rr75.8%
associate-*r/75.8%
*-rgt-identity75.8%
Simplified75.8%
Taylor expanded in t around 0 57.1%
associate-*r*55.5%
*-commutative55.5%
associate-*l*57.1%
Simplified57.1%
Taylor expanded in b around 0 53.0%
Final simplification56.3%
(FPCore (x y z t a b)
:precision binary64
(if (<= b -3.3e+120)
(/ (+ x (* b (* x (+ -1.0 (* b (+ 0.5 (* b -0.16666666666666666))))))) y)
(/
x
(*
y
(+ a (* b (+ a (* b (+ (* (* a b) 0.16666666666666666) (* a 0.5))))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -3.3e+120) {
tmp = (x + (b * (x * (-1.0 + (b * (0.5 + (b * -0.16666666666666666))))))) / y;
} else {
tmp = x / (y * (a + (b * (a + (b * (((a * b) * 0.16666666666666666) + (a * 0.5)))))));
}
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 <= (-3.3d+120)) then
tmp = (x + (b * (x * ((-1.0d0) + (b * (0.5d0 + (b * (-0.16666666666666666d0)))))))) / y
else
tmp = x / (y * (a + (b * (a + (b * (((a * b) * 0.16666666666666666d0) + (a * 0.5d0)))))))
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 <= -3.3e+120) {
tmp = (x + (b * (x * (-1.0 + (b * (0.5 + (b * -0.16666666666666666))))))) / y;
} else {
tmp = x / (y * (a + (b * (a + (b * (((a * b) * 0.16666666666666666) + (a * 0.5)))))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -3.3e+120: tmp = (x + (b * (x * (-1.0 + (b * (0.5 + (b * -0.16666666666666666))))))) / y else: tmp = x / (y * (a + (b * (a + (b * (((a * b) * 0.16666666666666666) + (a * 0.5))))))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -3.3e+120) tmp = Float64(Float64(x + Float64(b * Float64(x * Float64(-1.0 + Float64(b * Float64(0.5 + Float64(b * -0.16666666666666666))))))) / y); else tmp = Float64(x / Float64(y * Float64(a + Float64(b * Float64(a + Float64(b * Float64(Float64(Float64(a * b) * 0.16666666666666666) + Float64(a * 0.5)))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -3.3e+120) tmp = (x + (b * (x * (-1.0 + (b * (0.5 + (b * -0.16666666666666666))))))) / y; else tmp = x / (y * (a + (b * (a + (b * (((a * b) * 0.16666666666666666) + (a * 0.5))))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -3.3e+120], N[(N[(x + N[(b * N[(x * N[(-1.0 + N[(b * N[(0.5 + N[(b * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(x / N[(y * N[(a + N[(b * N[(a + N[(b * N[(N[(N[(a * b), $MachinePrecision] * 0.16666666666666666), $MachinePrecision] + N[(a * 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -3.3 \cdot 10^{+120}:\\
\;\;\;\;\frac{x + b \cdot \left(x \cdot \left(-1 + b \cdot \left(0.5 + b \cdot -0.16666666666666666\right)\right)\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot \left(a + b \cdot \left(a + b \cdot \left(\left(a \cdot b\right) \cdot 0.16666666666666666 + a \cdot 0.5\right)\right)\right)}\\
\end{array}
\end{array}
if b < -3.29999999999999991e120Initial program 100.0%
*-commutative100.0%
associate-/l*92.1%
associate--l+92.1%
fma-define92.1%
sub-neg92.1%
metadata-eval92.1%
Simplified92.1%
Taylor expanded in b around inf 84.3%
neg-mul-184.3%
Simplified84.3%
Taylor expanded in b around 0 85.0%
Taylor expanded in y around 0 89.8%
Taylor expanded in x around 0 92.2%
if -3.29999999999999991e120 < b Initial program 98.0%
associate-/l*98.5%
associate--l+98.5%
exp-sum82.0%
associate-/l*80.6%
*-commutative80.6%
exp-to-pow80.6%
exp-diff77.8%
*-commutative77.8%
exp-to-pow78.4%
sub-neg78.4%
metadata-eval78.4%
Simplified78.4%
Taylor expanded in y around 0 74.2%
associate-/r*71.9%
exp-to-pow72.5%
sub-neg72.5%
metadata-eval72.5%
Simplified72.5%
unpow-prod-up72.6%
unpow-172.6%
Applied egg-rr72.6%
associate-*r/72.6%
*-rgt-identity72.6%
Simplified72.6%
Taylor expanded in t around 0 57.1%
associate-*r*54.8%
*-commutative54.8%
associate-*l*57.1%
Simplified57.1%
Taylor expanded in b around 0 49.5%
Final simplification55.8%
(FPCore (x y z t a b) :precision binary64 (if (<= b -2.9e+120) (/ (+ x (* b (* x (+ -1.0 (* b (+ 0.5 (* b -0.16666666666666666))))))) y) (/ x (* y (+ a (* b (+ a (* 0.5 (* a b)))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -2.9e+120) {
tmp = (x + (b * (x * (-1.0 + (b * (0.5 + (b * -0.16666666666666666))))))) / y;
} else {
tmp = x / (y * (a + (b * (a + (0.5 * (a * 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.9d+120)) then
tmp = (x + (b * (x * ((-1.0d0) + (b * (0.5d0 + (b * (-0.16666666666666666d0)))))))) / y
else
tmp = x / (y * (a + (b * (a + (0.5d0 * (a * 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.9e+120) {
tmp = (x + (b * (x * (-1.0 + (b * (0.5 + (b * -0.16666666666666666))))))) / y;
} else {
tmp = x / (y * (a + (b * (a + (0.5 * (a * b))))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -2.9e+120: tmp = (x + (b * (x * (-1.0 + (b * (0.5 + (b * -0.16666666666666666))))))) / y else: tmp = x / (y * (a + (b * (a + (0.5 * (a * b)))))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -2.9e+120) tmp = Float64(Float64(x + Float64(b * Float64(x * Float64(-1.0 + Float64(b * Float64(0.5 + Float64(b * -0.16666666666666666))))))) / y); else tmp = Float64(x / Float64(y * Float64(a + Float64(b * Float64(a + Float64(0.5 * Float64(a * b))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -2.9e+120) tmp = (x + (b * (x * (-1.0 + (b * (0.5 + (b * -0.16666666666666666))))))) / y; else tmp = x / (y * (a + (b * (a + (0.5 * (a * b)))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -2.9e+120], N[(N[(x + N[(b * N[(x * N[(-1.0 + N[(b * N[(0.5 + N[(b * -0.16666666666666666), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(x / N[(y * N[(a + N[(b * N[(a + N[(0.5 * N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -2.9 \cdot 10^{+120}:\\
\;\;\;\;\frac{x + b \cdot \left(x \cdot \left(-1 + b \cdot \left(0.5 + b \cdot -0.16666666666666666\right)\right)\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot \left(a + b \cdot \left(a + 0.5 \cdot \left(a \cdot b\right)\right)\right)}\\
\end{array}
\end{array}
if b < -2.9000000000000001e120Initial program 100.0%
*-commutative100.0%
associate-/l*92.1%
associate--l+92.1%
fma-define92.1%
sub-neg92.1%
metadata-eval92.1%
Simplified92.1%
Taylor expanded in b around inf 84.3%
neg-mul-184.3%
Simplified84.3%
Taylor expanded in b around 0 85.0%
Taylor expanded in y around 0 89.8%
Taylor expanded in x around 0 92.2%
if -2.9000000000000001e120 < b Initial program 98.0%
associate-/l*98.5%
associate--l+98.5%
exp-sum82.0%
associate-/l*80.6%
*-commutative80.6%
exp-to-pow80.6%
exp-diff77.8%
*-commutative77.8%
exp-to-pow78.4%
sub-neg78.4%
metadata-eval78.4%
Simplified78.4%
Taylor expanded in y around 0 74.2%
associate-/r*71.9%
exp-to-pow72.5%
sub-neg72.5%
metadata-eval72.5%
Simplified72.5%
unpow-prod-up72.6%
unpow-172.6%
Applied egg-rr72.6%
associate-*r/72.6%
*-rgt-identity72.6%
Simplified72.6%
Taylor expanded in t around 0 57.1%
associate-*r*54.8%
*-commutative54.8%
associate-*l*57.1%
Simplified57.1%
Taylor expanded in b around 0 47.0%
Final simplification53.7%
(FPCore (x y z t a b) :precision binary64 (if (<= b -3e+120) (/ (* x (+ 1.0 (* b (+ -1.0 (* b 0.5))))) y) (/ x (* y (+ a (* b (+ a (* 0.5 (* a b)))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -3e+120) {
tmp = (x * (1.0 + (b * (-1.0 + (b * 0.5))))) / y;
} else {
tmp = x / (y * (a + (b * (a + (0.5 * (a * 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 <= (-3d+120)) then
tmp = (x * (1.0d0 + (b * ((-1.0d0) + (b * 0.5d0))))) / y
else
tmp = x / (y * (a + (b * (a + (0.5d0 * (a * 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 <= -3e+120) {
tmp = (x * (1.0 + (b * (-1.0 + (b * 0.5))))) / y;
} else {
tmp = x / (y * (a + (b * (a + (0.5 * (a * b))))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -3e+120: tmp = (x * (1.0 + (b * (-1.0 + (b * 0.5))))) / y else: tmp = x / (y * (a + (b * (a + (0.5 * (a * b)))))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -3e+120) tmp = Float64(Float64(x * Float64(1.0 + Float64(b * Float64(-1.0 + Float64(b * 0.5))))) / y); else tmp = Float64(x / Float64(y * Float64(a + Float64(b * Float64(a + Float64(0.5 * Float64(a * b))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -3e+120) tmp = (x * (1.0 + (b * (-1.0 + (b * 0.5))))) / y; else tmp = x / (y * (a + (b * (a + (0.5 * (a * b)))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -3e+120], N[(N[(x * N[(1.0 + N[(b * N[(-1.0 + N[(b * 0.5), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(x / N[(y * N[(a + N[(b * N[(a + N[(0.5 * N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -3 \cdot 10^{+120}:\\
\;\;\;\;\frac{x \cdot \left(1 + b \cdot \left(-1 + b \cdot 0.5\right)\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot \left(a + b \cdot \left(a + 0.5 \cdot \left(a \cdot b\right)\right)\right)}\\
\end{array}
\end{array}
if b < -3e120Initial program 100.0%
*-commutative100.0%
associate-/l*92.1%
associate--l+92.1%
fma-define92.1%
sub-neg92.1%
metadata-eval92.1%
Simplified92.1%
Taylor expanded in b around inf 84.3%
neg-mul-184.3%
Simplified84.3%
Taylor expanded in b around inf 92.2%
associate-*r/92.2%
Simplified92.2%
Taylor expanded in b around 0 79.7%
Taylor expanded in y around 0 84.9%
if -3e120 < b Initial program 98.0%
associate-/l*98.5%
associate--l+98.5%
exp-sum82.0%
associate-/l*80.6%
*-commutative80.6%
exp-to-pow80.6%
exp-diff77.8%
*-commutative77.8%
exp-to-pow78.4%
sub-neg78.4%
metadata-eval78.4%
Simplified78.4%
Taylor expanded in y around 0 74.2%
associate-/r*71.9%
exp-to-pow72.5%
sub-neg72.5%
metadata-eval72.5%
Simplified72.5%
unpow-prod-up72.6%
unpow-172.6%
Applied egg-rr72.6%
associate-*r/72.6%
*-rgt-identity72.6%
Simplified72.6%
Taylor expanded in t around 0 57.1%
associate-*r*54.8%
*-commutative54.8%
associate-*l*57.1%
Simplified57.1%
Taylor expanded in b around 0 47.0%
Final simplification52.6%
(FPCore (x y z t a b) :precision binary64 (if (<= b -7.2e-19) (* x (+ (/ 1.0 y) (* b (* b (/ 0.5 y))))) (/ x (* y (+ a (* a b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -7.2e-19) {
tmp = x * ((1.0 / y) + (b * (b * (0.5 / y))));
} else {
tmp = x / (y * (a + (a * 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 <= (-7.2d-19)) then
tmp = x * ((1.0d0 / y) + (b * (b * (0.5d0 / y))))
else
tmp = x / (y * (a + (a * 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 <= -7.2e-19) {
tmp = x * ((1.0 / y) + (b * (b * (0.5 / y))));
} else {
tmp = x / (y * (a + (a * b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -7.2e-19: tmp = x * ((1.0 / y) + (b * (b * (0.5 / y)))) else: tmp = x / (y * (a + (a * b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -7.2e-19) tmp = Float64(x * Float64(Float64(1.0 / y) + Float64(b * Float64(b * Float64(0.5 / y))))); else tmp = Float64(x / Float64(y * Float64(a + Float64(a * b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -7.2e-19) tmp = x * ((1.0 / y) + (b * (b * (0.5 / y)))); else tmp = x / (y * (a + (a * b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -7.2e-19], N[(x * N[(N[(1.0 / y), $MachinePrecision] + N[(b * N[(b * N[(0.5 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * N[(a + N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -7.2 \cdot 10^{-19}:\\
\;\;\;\;x \cdot \left(\frac{1}{y} + b \cdot \left(b \cdot \frac{0.5}{y}\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot \left(a + a \cdot b\right)}\\
\end{array}
\end{array}
if b < -7.2000000000000002e-19Initial program 100.0%
*-commutative100.0%
associate-/l*91.4%
associate--l+91.4%
fma-define91.4%
sub-neg91.4%
metadata-eval91.4%
Simplified91.4%
Taylor expanded in b around inf 68.9%
neg-mul-168.9%
Simplified68.9%
Taylor expanded in b around inf 77.6%
associate-*r/77.6%
Simplified77.6%
Taylor expanded in b around 0 57.1%
Taylor expanded in b around inf 57.1%
associate-*r/57.1%
*-commutative57.1%
associate-/l*57.1%
Simplified57.1%
if -7.2000000000000002e-19 < b Initial program 97.7%
associate-/l*98.2%
associate--l+98.2%
exp-sum83.7%
associate-/l*82.6%
*-commutative82.6%
exp-to-pow82.6%
exp-diff81.5%
*-commutative81.5%
exp-to-pow82.2%
sub-neg82.2%
metadata-eval82.2%
Simplified82.2%
Taylor expanded in y around 0 77.2%
associate-/r*75.1%
exp-to-pow75.8%
sub-neg75.8%
metadata-eval75.8%
Simplified75.8%
unpow-prod-up75.8%
unpow-175.8%
Applied egg-rr75.8%
associate-*r/75.8%
*-rgt-identity75.8%
Simplified75.8%
Taylor expanded in t around 0 57.1%
associate-*r*55.5%
*-commutative55.5%
associate-*l*57.1%
Simplified57.1%
Taylor expanded in b around 0 45.2%
Final simplification48.4%
(FPCore (x y z t a b) :precision binary64 (if (<= b -6.7e+106) (* x (- (/ 1.0 y) (/ b y))) (/ x (* y a))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -6.7e+106) {
tmp = x * ((1.0 / y) - (b / y));
} else {
tmp = x / (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 (b <= (-6.7d+106)) then
tmp = x * ((1.0d0 / y) - (b / y))
else
tmp = x / (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 (b <= -6.7e+106) {
tmp = x * ((1.0 / y) - (b / y));
} else {
tmp = x / (y * a);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -6.7e+106: tmp = x * ((1.0 / y) - (b / y)) else: tmp = x / (y * a) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -6.7e+106) tmp = Float64(x * Float64(Float64(1.0 / y) - Float64(b / y))); else tmp = Float64(x / Float64(y * a)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -6.7e+106) tmp = x * ((1.0 / y) - (b / y)); else tmp = x / (y * a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -6.7e+106], N[(x * N[(N[(1.0 / y), $MachinePrecision] - N[(b / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * a), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -6.7 \cdot 10^{+106}:\\
\;\;\;\;x \cdot \left(\frac{1}{y} - \frac{b}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot a}\\
\end{array}
\end{array}
if b < -6.7e106Initial program 100.0%
*-commutative100.0%
associate-/l*93.2%
associate--l+93.2%
fma-define93.2%
sub-neg93.2%
metadata-eval93.2%
Simplified93.2%
Taylor expanded in b around inf 77.5%
neg-mul-177.5%
Simplified77.5%
Taylor expanded in b around inf 84.3%
associate-*r/84.3%
Simplified84.3%
Taylor expanded in b around 0 58.4%
+-commutative58.4%
mul-1-neg58.4%
unsub-neg58.4%
Simplified58.4%
if -6.7e106 < b Initial program 98.0%
*-commutative98.0%
associate-/l*88.6%
associate--l+88.6%
fma-define88.6%
sub-neg88.6%
metadata-eval88.6%
Simplified88.6%
Taylor expanded in y around 0 71.2%
Taylor expanded in b around 0 57.6%
exp-to-pow58.2%
sub-neg58.2%
metadata-eval58.2%
+-commutative58.2%
Simplified58.2%
Taylor expanded in t around 0 37.2%
Final simplification40.9%
(FPCore (x y z t a b) :precision binary64 (if (<= b -7.2e-19) (* x (- (/ 1.0 y) (/ b y))) (/ x (* a (+ y (* y b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -7.2e-19) {
tmp = x * ((1.0 / y) - (b / 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 <= (-7.2d-19)) then
tmp = x * ((1.0d0 / y) - (b / 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 <= -7.2e-19) {
tmp = x * ((1.0 / y) - (b / y));
} else {
tmp = x / (a * (y + (y * b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -7.2e-19: tmp = x * ((1.0 / y) - (b / y)) else: tmp = x / (a * (y + (y * b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -7.2e-19) tmp = Float64(x * Float64(Float64(1.0 / y) - Float64(b / 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 <= -7.2e-19) tmp = x * ((1.0 / y) - (b / y)); else tmp = x / (a * (y + (y * b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -7.2e-19], N[(x * N[(N[(1.0 / y), $MachinePrecision] - N[(b / y), $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 -7.2 \cdot 10^{-19}:\\
\;\;\;\;x \cdot \left(\frac{1}{y} - \frac{b}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y + y \cdot b\right)}\\
\end{array}
\end{array}
if b < -7.2000000000000002e-19Initial program 100.0%
*-commutative100.0%
associate-/l*91.4%
associate--l+91.4%
fma-define91.4%
sub-neg91.4%
metadata-eval91.4%
Simplified91.4%
Taylor expanded in b around inf 68.9%
neg-mul-168.9%
Simplified68.9%
Taylor expanded in b around inf 77.6%
associate-*r/77.6%
Simplified77.6%
Taylor expanded in b around 0 44.8%
+-commutative44.8%
mul-1-neg44.8%
unsub-neg44.8%
Simplified44.8%
if -7.2000000000000002e-19 < b Initial program 97.7%
associate-/l*98.2%
associate--l+98.2%
exp-sum83.7%
associate-/l*82.6%
*-commutative82.6%
exp-to-pow82.6%
exp-diff81.5%
*-commutative81.5%
exp-to-pow82.2%
sub-neg82.2%
metadata-eval82.2%
Simplified82.2%
Taylor expanded in y around 0 77.2%
associate-/r*75.1%
exp-to-pow75.8%
sub-neg75.8%
metadata-eval75.8%
Simplified75.8%
unpow-prod-up75.8%
unpow-175.8%
Applied egg-rr75.8%
associate-*r/75.8%
*-rgt-identity75.8%
Simplified75.8%
Taylor expanded in t around 0 57.1%
associate-*r*55.5%
*-commutative55.5%
associate-*l*57.1%
Simplified57.1%
Taylor expanded in b around 0 42.0%
distribute-lft-out44.7%
*-commutative44.7%
Simplified44.7%
Final simplification44.7%
(FPCore (x y z t a b) :precision binary64 (if (<= b -7.2e-19) (* x (- (/ 1.0 y) (/ b y))) (/ x (* y (+ a (* a b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -7.2e-19) {
tmp = x * ((1.0 / y) - (b / y));
} else {
tmp = x / (y * (a + (a * 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 <= (-7.2d-19)) then
tmp = x * ((1.0d0 / y) - (b / y))
else
tmp = x / (y * (a + (a * 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 <= -7.2e-19) {
tmp = x * ((1.0 / y) - (b / y));
} else {
tmp = x / (y * (a + (a * b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -7.2e-19: tmp = x * ((1.0 / y) - (b / y)) else: tmp = x / (y * (a + (a * b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -7.2e-19) tmp = Float64(x * Float64(Float64(1.0 / y) - Float64(b / y))); else tmp = Float64(x / Float64(y * Float64(a + Float64(a * b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -7.2e-19) tmp = x * ((1.0 / y) - (b / y)); else tmp = x / (y * (a + (a * b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -7.2e-19], N[(x * N[(N[(1.0 / y), $MachinePrecision] - N[(b / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * N[(a + N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -7.2 \cdot 10^{-19}:\\
\;\;\;\;x \cdot \left(\frac{1}{y} - \frac{b}{y}\right)\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot \left(a + a \cdot b\right)}\\
\end{array}
\end{array}
if b < -7.2000000000000002e-19Initial program 100.0%
*-commutative100.0%
associate-/l*91.4%
associate--l+91.4%
fma-define91.4%
sub-neg91.4%
metadata-eval91.4%
Simplified91.4%
Taylor expanded in b around inf 68.9%
neg-mul-168.9%
Simplified68.9%
Taylor expanded in b around inf 77.6%
associate-*r/77.6%
Simplified77.6%
Taylor expanded in b around 0 44.8%
+-commutative44.8%
mul-1-neg44.8%
unsub-neg44.8%
Simplified44.8%
if -7.2000000000000002e-19 < b Initial program 97.7%
associate-/l*98.2%
associate--l+98.2%
exp-sum83.7%
associate-/l*82.6%
*-commutative82.6%
exp-to-pow82.6%
exp-diff81.5%
*-commutative81.5%
exp-to-pow82.2%
sub-neg82.2%
metadata-eval82.2%
Simplified82.2%
Taylor expanded in y around 0 77.2%
associate-/r*75.1%
exp-to-pow75.8%
sub-neg75.8%
metadata-eval75.8%
Simplified75.8%
unpow-prod-up75.8%
unpow-175.8%
Applied egg-rr75.8%
associate-*r/75.8%
*-rgt-identity75.8%
Simplified75.8%
Taylor expanded in t around 0 57.1%
associate-*r*55.5%
*-commutative55.5%
associate-*l*57.1%
Simplified57.1%
Taylor expanded in b around 0 45.2%
Final simplification45.1%
(FPCore (x y z t a b) :precision binary64 (if (<= b -2e+107) (/ (- x (* x b)) y) (/ x (* y a))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -2e+107) {
tmp = (x - (x * b)) / y;
} else {
tmp = x / (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 (b <= (-2d+107)) then
tmp = (x - (x * b)) / y
else
tmp = x / (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 (b <= -2e+107) {
tmp = (x - (x * b)) / y;
} else {
tmp = x / (y * a);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -2e+107: tmp = (x - (x * b)) / y else: tmp = x / (y * a) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -2e+107) tmp = Float64(Float64(x - Float64(x * b)) / y); else tmp = Float64(x / Float64(y * a)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -2e+107) tmp = (x - (x * b)) / y; else tmp = x / (y * a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -2e+107], N[(N[(x - N[(x * b), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(x / N[(y * a), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -2 \cdot 10^{+107}:\\
\;\;\;\;\frac{x - x \cdot b}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot a}\\
\end{array}
\end{array}
if b < -1.9999999999999999e107Initial program 100.0%
*-commutative100.0%
associate-/l*93.2%
associate--l+93.2%
fma-define93.2%
sub-neg93.2%
metadata-eval93.2%
Simplified93.2%
Taylor expanded in b around inf 77.5%
neg-mul-177.5%
Simplified77.5%
Taylor expanded in b around 0 78.2%
Taylor expanded in y around 0 82.2%
Taylor expanded in b around 0 51.8%
associate-*r*51.8%
neg-mul-151.8%
Simplified51.8%
if -1.9999999999999999e107 < b Initial program 98.0%
*-commutative98.0%
associate-/l*88.6%
associate--l+88.6%
fma-define88.6%
sub-neg88.6%
metadata-eval88.6%
Simplified88.6%
Taylor expanded in y around 0 71.2%
Taylor expanded in b around 0 57.6%
exp-to-pow58.2%
sub-neg58.2%
metadata-eval58.2%
+-commutative58.2%
Simplified58.2%
Taylor expanded in t around 0 37.2%
Final simplification39.7%
(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 98.3%
*-commutative98.3%
associate-/l*89.4%
associate--l+89.4%
fma-define89.4%
sub-neg89.4%
metadata-eval89.4%
Simplified89.4%
Taylor expanded in y around 0 73.4%
Taylor expanded in b around 0 55.8%
exp-to-pow56.2%
sub-neg56.2%
metadata-eval56.2%
+-commutative56.2%
Simplified56.2%
Taylor expanded in t around 0 34.8%
Final simplification34.8%
(FPCore (x y z t a b) :precision binary64 (/ x y))
double code(double x, double y, double z, double t, double a, double b) {
return x / 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 / y
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x / y;
}
def code(x, y, z, t, a, b): return x / y
function code(x, y, z, t, a, b) return Float64(x / y) end
function tmp = code(x, y, z, t, a, b) tmp = x / y; end
code[x_, y_, z_, t_, a_, b_] := N[(x / y), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{y}
\end{array}
Initial program 98.3%
*-commutative98.3%
associate-/l*89.4%
associate--l+89.4%
fma-define89.4%
sub-neg89.4%
metadata-eval89.4%
Simplified89.4%
Taylor expanded in b around inf 46.1%
neg-mul-146.1%
Simplified46.1%
Taylor expanded in b around 0 17.1%
Final simplification17.1%
(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 2024096
(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))