
(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 16 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.6%
Final simplification98.6%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* x (/ (/ (pow a t) a) y))))
(if (<= (+ t -1.0) -5e+230)
t_1
(if (<= (+ t -1.0) 2e+31)
(* x (/ (exp (- (- (* y (log z)) (log a)) b)) y))
(if (or (<= (+ t -1.0) 2e+102) (not (<= (+ t -1.0) 4e+117)))
t_1
(* x (/ (/ (pow z y) a) y)))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * ((pow(a, t) / a) / y);
double tmp;
if ((t + -1.0) <= -5e+230) {
tmp = t_1;
} else if ((t + -1.0) <= 2e+31) {
tmp = x * (exp((((y * log(z)) - log(a)) - b)) / y);
} else if (((t + -1.0) <= 2e+102) || !((t + -1.0) <= 4e+117)) {
tmp = t_1;
} 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) :: t_1
real(8) :: tmp
t_1 = x * (((a ** t) / a) / y)
if ((t + (-1.0d0)) <= (-5d+230)) then
tmp = t_1
else if ((t + (-1.0d0)) <= 2d+31) then
tmp = x * (exp((((y * log(z)) - log(a)) - b)) / y)
else if (((t + (-1.0d0)) <= 2d+102) .or. (.not. ((t + (-1.0d0)) <= 4d+117))) then
tmp = t_1
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 t_1 = x * ((Math.pow(a, t) / a) / y);
double tmp;
if ((t + -1.0) <= -5e+230) {
tmp = t_1;
} else if ((t + -1.0) <= 2e+31) {
tmp = x * (Math.exp((((y * Math.log(z)) - Math.log(a)) - b)) / y);
} else if (((t + -1.0) <= 2e+102) || !((t + -1.0) <= 4e+117)) {
tmp = t_1;
} else {
tmp = x * ((Math.pow(z, y) / a) / y);
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x * ((math.pow(a, t) / a) / y) tmp = 0 if (t + -1.0) <= -5e+230: tmp = t_1 elif (t + -1.0) <= 2e+31: tmp = x * (math.exp((((y * math.log(z)) - math.log(a)) - b)) / y) elif ((t + -1.0) <= 2e+102) or not ((t + -1.0) <= 4e+117): tmp = t_1 else: tmp = x * ((math.pow(z, y) / a) / y) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x * Float64(Float64((a ^ t) / a) / y)) tmp = 0.0 if (Float64(t + -1.0) <= -5e+230) tmp = t_1; elseif (Float64(t + -1.0) <= 2e+31) tmp = Float64(x * Float64(exp(Float64(Float64(Float64(y * log(z)) - log(a)) - b)) / y)); elseif ((Float64(t + -1.0) <= 2e+102) || !(Float64(t + -1.0) <= 4e+117)) tmp = t_1; else tmp = Float64(x * Float64(Float64((z ^ y) / a) / y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x * (((a ^ t) / a) / y); tmp = 0.0; if ((t + -1.0) <= -5e+230) tmp = t_1; elseif ((t + -1.0) <= 2e+31) tmp = x * (exp((((y * log(z)) - log(a)) - b)) / y); elseif (((t + -1.0) <= 2e+102) || ~(((t + -1.0) <= 4e+117))) tmp = t_1; else tmp = x * (((z ^ y) / a) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x * N[(N[(N[Power[a, t], $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(t + -1.0), $MachinePrecision], -5e+230], t$95$1, If[LessEqual[N[(t + -1.0), $MachinePrecision], 2e+31], 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], If[Or[LessEqual[N[(t + -1.0), $MachinePrecision], 2e+102], N[Not[LessEqual[N[(t + -1.0), $MachinePrecision], 4e+117]], $MachinePrecision]], t$95$1, N[(x * N[(N[(N[Power[z, y], $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{\frac{{a}^{t}}{a}}{y}\\
\mathbf{if}\;t + -1 \leq -5 \cdot 10^{+230}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t + -1 \leq 2 \cdot 10^{+31}:\\
\;\;\;\;x \cdot \frac{e^{\left(y \cdot \log z - \log a\right) - b}}{y}\\
\mathbf{elif}\;t + -1 \leq 2 \cdot 10^{+102} \lor \neg \left(t + -1 \leq 4 \cdot 10^{+117}\right):\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{\frac{{z}^{y}}{a}}{y}\\
\end{array}
\end{array}
if (-.f64 t 1) < -5.0000000000000003e230 or 1.9999999999999999e31 < (-.f64 t 1) < 1.99999999999999995e102 or 4.0000000000000002e117 < (-.f64 t 1) Initial program 100.0%
associate-/l*100.0%
exp-diff77.5%
associate-/l/77.5%
exp-sum57.5%
times-frac57.5%
*-commutative57.5%
exp-to-pow57.5%
*-commutative57.5%
exp-to-pow57.5%
sub-neg57.5%
metadata-eval57.5%
Simplified57.5%
Taylor expanded in y around 0 76.3%
associate-/l*76.3%
exp-to-pow76.3%
sub-neg76.3%
metadata-eval76.3%
Simplified76.3%
unpow-prod-up76.3%
unpow-176.3%
Applied egg-rr76.3%
associate-*r/76.3%
*-rgt-identity76.3%
Simplified76.3%
Taylor expanded in b around 0 92.6%
if -5.0000000000000003e230 < (-.f64 t 1) < 1.9999999999999999e31Initial program 97.8%
*-commutative97.8%
associate-/l*88.1%
associate--l+88.1%
fma-define88.1%
sub-neg88.1%
metadata-eval88.1%
Simplified88.1%
Taylor expanded in t around 0 91.9%
associate-/l*92.4%
+-commutative92.4%
mul-1-neg92.4%
unsub-neg92.4%
Simplified92.4%
if 1.99999999999999995e102 < (-.f64 t 1) < 4.0000000000000002e117Initial program 100.0%
*-commutative100.0%
associate-/l*100.0%
associate--l+100.0%
fma-define100.0%
sub-neg100.0%
metadata-eval100.0%
Simplified100.0%
Taylor expanded in t around 0 100.0%
associate-/l*100.0%
+-commutative100.0%
mul-1-neg100.0%
unsub-neg100.0%
Simplified100.0%
Taylor expanded in b around 0 100.0%
div-exp100.0%
*-commutative100.0%
exp-to-pow100.0%
rem-exp-log100.0%
Simplified100.0%
Final simplification92.7%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (exp (- (* (+ t -1.0) (log a)) b)) (/ x y)))
(t_2 (* x (/ (/ (pow z y) a) y))))
(if (<= y -3.2e+77)
t_2
(if (<= y -8.2e-219)
t_1
(if (<= y 2.7e-70)
(* x (/ (/ (pow a t) a) (* y (exp b))))
(if (<= y 5.5e+100) t_1 t_2))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = exp((((t + -1.0) * log(a)) - b)) * (x / y);
double t_2 = x * ((pow(z, y) / a) / y);
double tmp;
if (y <= -3.2e+77) {
tmp = t_2;
} else if (y <= -8.2e-219) {
tmp = t_1;
} else if (y <= 2.7e-70) {
tmp = x * ((pow(a, t) / a) / (y * exp(b)));
} else if (y <= 5.5e+100) {
tmp = t_1;
} 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 = exp((((t + (-1.0d0)) * log(a)) - b)) * (x / y)
t_2 = x * (((z ** y) / a) / y)
if (y <= (-3.2d+77)) then
tmp = t_2
else if (y <= (-8.2d-219)) then
tmp = t_1
else if (y <= 2.7d-70) then
tmp = x * (((a ** t) / a) / (y * exp(b)))
else if (y <= 5.5d+100) then
tmp = t_1
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.exp((((t + -1.0) * Math.log(a)) - b)) * (x / y);
double t_2 = x * ((Math.pow(z, y) / a) / y);
double tmp;
if (y <= -3.2e+77) {
tmp = t_2;
} else if (y <= -8.2e-219) {
tmp = t_1;
} else if (y <= 2.7e-70) {
tmp = x * ((Math.pow(a, t) / a) / (y * Math.exp(b)));
} else if (y <= 5.5e+100) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = math.exp((((t + -1.0) * math.log(a)) - b)) * (x / y) t_2 = x * ((math.pow(z, y) / a) / y) tmp = 0 if y <= -3.2e+77: tmp = t_2 elif y <= -8.2e-219: tmp = t_1 elif y <= 2.7e-70: tmp = x * ((math.pow(a, t) / a) / (y * math.exp(b))) elif y <= 5.5e+100: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(exp(Float64(Float64(Float64(t + -1.0) * log(a)) - b)) * Float64(x / y)) t_2 = Float64(x * Float64(Float64((z ^ y) / a) / y)) tmp = 0.0 if (y <= -3.2e+77) tmp = t_2; elseif (y <= -8.2e-219) tmp = t_1; elseif (y <= 2.7e-70) tmp = Float64(x * Float64(Float64((a ^ t) / a) / Float64(y * exp(b)))); elseif (y <= 5.5e+100) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = exp((((t + -1.0) * log(a)) - b)) * (x / y); t_2 = x * (((z ^ y) / a) / y); tmp = 0.0; if (y <= -3.2e+77) tmp = t_2; elseif (y <= -8.2e-219) tmp = t_1; elseif (y <= 2.7e-70) tmp = x * (((a ^ t) / a) / (y * exp(b))); elseif (y <= 5.5e+100) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[Exp[N[(N[(N[(t + -1.0), $MachinePrecision] * N[Log[a], $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision] * N[(x / y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(N[(N[Power[z, y], $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -3.2e+77], t$95$2, If[LessEqual[y, -8.2e-219], t$95$1, If[LessEqual[y, 2.7e-70], N[(x * N[(N[(N[Power[a, t], $MachinePrecision] / a), $MachinePrecision] / N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 5.5e+100], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := e^{\left(t + -1\right) \cdot \log a - b} \cdot \frac{x}{y}\\
t_2 := x \cdot \frac{\frac{{z}^{y}}{a}}{y}\\
\mathbf{if}\;y \leq -3.2 \cdot 10^{+77}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;y \leq -8.2 \cdot 10^{-219}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 2.7 \cdot 10^{-70}:\\
\;\;\;\;x \cdot \frac{\frac{{a}^{t}}{a}}{y \cdot e^{b}}\\
\mathbf{elif}\;y \leq 5.5 \cdot 10^{+100}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if y < -3.2000000000000002e77 or 5.5000000000000002e100 < y Initial program 100.0%
*-commutative100.0%
associate-/l*90.3%
associate--l+90.3%
fma-define90.3%
sub-neg90.3%
metadata-eval90.3%
Simplified90.3%
Taylor expanded in t around 0 92.6%
associate-/l*92.6%
+-commutative92.6%
mul-1-neg92.6%
unsub-neg92.6%
Simplified92.6%
Taylor expanded in b around 0 88.4%
div-exp88.4%
*-commutative88.4%
exp-to-pow88.4%
rem-exp-log88.4%
Simplified88.4%
if -3.2000000000000002e77 < y < -8.2e-219 or 2.7000000000000001e-70 < y < 5.5000000000000002e100Initial program 98.8%
*-commutative98.8%
associate-/l*95.7%
associate--l+95.7%
fma-define95.7%
sub-neg95.7%
metadata-eval95.7%
Simplified95.7%
Taylor expanded in y around 0 87.4%
if -8.2e-219 < y < 2.7000000000000001e-70Initial program 95.8%
associate-/l*97.1%
exp-diff88.6%
associate-/l/88.6%
exp-sum88.6%
times-frac88.6%
*-commutative88.6%
exp-to-pow88.6%
*-commutative88.6%
exp-to-pow89.6%
sub-neg89.6%
metadata-eval89.6%
Simplified89.6%
Taylor expanded in y around 0 85.7%
associate-/l*88.6%
exp-to-pow89.6%
sub-neg89.6%
metadata-eval89.6%
Simplified89.6%
unpow-prod-up89.8%
unpow-189.8%
Applied egg-rr89.8%
associate-*r/89.8%
*-rgt-identity89.8%
Simplified89.8%
Final simplification88.3%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -4.2e+57) (not (<= y 5.4e+103))) (* 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 <= -4.2e+57) || !(y <= 5.4e+103)) {
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 <= (-4.2d+57)) .or. (.not. (y <= 5.4d+103))) 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 <= -4.2e+57) || !(y <= 5.4e+103)) {
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 <= -4.2e+57) or not (y <= 5.4e+103): 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 <= -4.2e+57) || !(y <= 5.4e+103)) tmp = Float64(x * Float64(Float64((z ^ y) / a) / y)); else tmp = Float64(x * Float64(Float64((a ^ t) / 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.2e+57) || ~((y <= 5.4e+103))) 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, -4.2e+57], N[Not[LessEqual[y, 5.4e+103]], $MachinePrecision]], N[(x * N[(N[(N[Power[z, y], $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[(N[Power[a, t], $MachinePrecision] / a), $MachinePrecision] / N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.2 \cdot 10^{+57} \lor \neg \left(y \leq 5.4 \cdot 10^{+103}\right):\\
\;\;\;\;x \cdot \frac{\frac{{z}^{y}}{a}}{y}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{\frac{{a}^{t}}{a}}{y \cdot e^{b}}\\
\end{array}
\end{array}
if y < -4.19999999999999982e57 or 5.39999999999999985e103 < y Initial program 100.0%
*-commutative100.0%
associate-/l*90.9%
associate--l+90.9%
fma-define90.9%
sub-neg90.9%
metadata-eval90.9%
Simplified90.9%
Taylor expanded in t around 0 92.0%
associate-/l*92.0%
+-commutative92.0%
mul-1-neg92.0%
unsub-neg92.0%
Simplified92.0%
Taylor expanded in b around 0 88.1%
div-exp88.1%
*-commutative88.1%
exp-to-pow88.1%
rem-exp-log88.1%
Simplified88.1%
if -4.19999999999999982e57 < y < 5.39999999999999985e103Initial program 97.6%
associate-/l*98.0%
exp-diff82.7%
associate-/l/82.7%
exp-sum77.0%
times-frac77.0%
*-commutative77.0%
exp-to-pow77.0%
*-commutative77.0%
exp-to-pow77.7%
sub-neg77.7%
metadata-eval77.7%
Simplified77.7%
Taylor expanded in y around 0 78.1%
associate-/l*80.4%
exp-to-pow81.0%
sub-neg81.0%
metadata-eval81.0%
Simplified81.0%
unpow-prod-up81.1%
unpow-181.1%
Applied egg-rr81.1%
associate-*r/81.1%
*-rgt-identity81.1%
Simplified81.1%
Final simplification83.8%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* x (/ (/ (pow z y) a) y))) (t_2 (* x (/ (/ (pow a t) a) y))))
(if (<= t -5.7e+134)
t_2
(if (<= t -5.9e-292)
t_1
(if (<= t 6e-160)
(/ x (* y (* a (exp b))))
(if (or (<= t 3.9e+36) (and (not (<= t 4.4e+103)) (<= t 3.9e+117)))
t_1
t_2))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * ((pow(z, y) / a) / y);
double t_2 = x * ((pow(a, t) / a) / y);
double tmp;
if (t <= -5.7e+134) {
tmp = t_2;
} else if (t <= -5.9e-292) {
tmp = t_1;
} else if (t <= 6e-160) {
tmp = x / (y * (a * exp(b)));
} else if ((t <= 3.9e+36) || (!(t <= 4.4e+103) && (t <= 3.9e+117))) {
tmp = t_1;
} 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 = x * (((z ** y) / a) / y)
t_2 = x * (((a ** t) / a) / y)
if (t <= (-5.7d+134)) then
tmp = t_2
else if (t <= (-5.9d-292)) then
tmp = t_1
else if (t <= 6d-160) then
tmp = x / (y * (a * exp(b)))
else if ((t <= 3.9d+36) .or. (.not. (t <= 4.4d+103)) .and. (t <= 3.9d+117)) then
tmp = t_1
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 = x * ((Math.pow(z, y) / a) / y);
double t_2 = x * ((Math.pow(a, t) / a) / y);
double tmp;
if (t <= -5.7e+134) {
tmp = t_2;
} else if (t <= -5.9e-292) {
tmp = t_1;
} else if (t <= 6e-160) {
tmp = x / (y * (a * Math.exp(b)));
} else if ((t <= 3.9e+36) || (!(t <= 4.4e+103) && (t <= 3.9e+117))) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x * ((math.pow(z, y) / a) / y) t_2 = x * ((math.pow(a, t) / a) / y) tmp = 0 if t <= -5.7e+134: tmp = t_2 elif t <= -5.9e-292: tmp = t_1 elif t <= 6e-160: tmp = x / (y * (a * math.exp(b))) elif (t <= 3.9e+36) or (not (t <= 4.4e+103) and (t <= 3.9e+117)): tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x * Float64(Float64((z ^ y) / a) / y)) t_2 = Float64(x * Float64(Float64((a ^ t) / a) / y)) tmp = 0.0 if (t <= -5.7e+134) tmp = t_2; elseif (t <= -5.9e-292) tmp = t_1; elseif (t <= 6e-160) tmp = Float64(x / Float64(y * Float64(a * exp(b)))); elseif ((t <= 3.9e+36) || (!(t <= 4.4e+103) && (t <= 3.9e+117))) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x * (((z ^ y) / a) / y); t_2 = x * (((a ^ t) / a) / y); tmp = 0.0; if (t <= -5.7e+134) tmp = t_2; elseif (t <= -5.9e-292) tmp = t_1; elseif (t <= 6e-160) tmp = x / (y * (a * exp(b))); elseif ((t <= 3.9e+36) || (~((t <= 4.4e+103)) && (t <= 3.9e+117))) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x * N[(N[(N[Power[z, y], $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[(N[(N[Power[a, t], $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -5.7e+134], t$95$2, If[LessEqual[t, -5.9e-292], t$95$1, If[LessEqual[t, 6e-160], N[(x / N[(y * N[(a * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[t, 3.9e+36], And[N[Not[LessEqual[t, 4.4e+103]], $MachinePrecision], LessEqual[t, 3.9e+117]]], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \frac{\frac{{z}^{y}}{a}}{y}\\
t_2 := x \cdot \frac{\frac{{a}^{t}}{a}}{y}\\
\mathbf{if}\;t \leq -5.7 \cdot 10^{+134}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t \leq -5.9 \cdot 10^{-292}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 6 \cdot 10^{-160}:\\
\;\;\;\;\frac{x}{y \cdot \left(a \cdot e^{b}\right)}\\
\mathbf{elif}\;t \leq 3.9 \cdot 10^{+36} \lor \neg \left(t \leq 4.4 \cdot 10^{+103}\right) \land t \leq 3.9 \cdot 10^{+117}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if t < -5.70000000000000038e134 or 3.90000000000000021e36 < t < 4.39999999999999985e103 or 3.8999999999999999e117 < t Initial program 100.0%
associate-/l*100.0%
exp-diff79.0%
associate-/l/79.0%
exp-sum61.0%
times-frac61.0%
*-commutative61.0%
exp-to-pow61.0%
*-commutative61.0%
exp-to-pow61.0%
sub-neg61.0%
metadata-eval61.0%
Simplified61.0%
Taylor expanded in y around 0 76.1%
associate-/l*76.1%
exp-to-pow76.1%
sub-neg76.1%
metadata-eval76.1%
Simplified76.1%
unpow-prod-up76.1%
unpow-176.1%
Applied egg-rr76.1%
associate-*r/76.1%
*-rgt-identity76.1%
Simplified76.1%
Taylor expanded in b around 0 90.2%
if -5.70000000000000038e134 < t < -5.9000000000000001e-292 or 5.99999999999999993e-160 < t < 3.90000000000000021e36 or 4.39999999999999985e103 < t < 3.8999999999999999e117Initial program 97.6%
*-commutative97.6%
associate-/l*90.7%
associate--l+90.7%
fma-define90.7%
sub-neg90.7%
metadata-eval90.7%
Simplified90.7%
Taylor expanded in t around 0 93.1%
associate-/l*92.4%
+-commutative92.4%
mul-1-neg92.4%
unsub-neg92.4%
Simplified92.4%
Taylor expanded in b around 0 79.6%
div-exp79.6%
*-commutative79.6%
exp-to-pow79.6%
rem-exp-log80.3%
Simplified80.3%
if -5.9000000000000001e-292 < t < 5.99999999999999993e-160Initial program 97.8%
associate-/l*97.2%
exp-diff73.5%
associate-/l/73.5%
exp-sum73.5%
times-frac73.5%
*-commutative73.5%
exp-to-pow73.5%
*-commutative73.5%
exp-to-pow73.8%
sub-neg73.8%
metadata-eval73.8%
Simplified73.8%
Taylor expanded in y around 0 82.5%
associate-/l*84.3%
exp-to-pow84.6%
sub-neg84.6%
metadata-eval84.6%
Simplified84.6%
Taylor expanded in t around 0 84.6%
*-commutative84.6%
associate-*l*84.6%
*-commutative84.6%
Simplified84.6%
Final simplification84.8%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ x (* y (exp b)))))
(if (<= b -8e+43)
t_1
(if (<= b -100.0)
(* x (/ (exp b) y))
(if (<= b 6.6e-40) (* 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 / (y * exp(b));
double tmp;
if (b <= -8e+43) {
tmp = t_1;
} else if (b <= -100.0) {
tmp = x * (exp(b) / y);
} else if (b <= 6.6e-40) {
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 / (y * exp(b))
if (b <= (-8d+43)) then
tmp = t_1
else if (b <= (-100.0d0)) then
tmp = x * (exp(b) / y)
else if (b <= 6.6d-40) 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 / (y * Math.exp(b));
double tmp;
if (b <= -8e+43) {
tmp = t_1;
} else if (b <= -100.0) {
tmp = x * (Math.exp(b) / y);
} else if (b <= 6.6e-40) {
tmp = x * ((1.0 / y) / a);
} 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 <= -8e+43: tmp = t_1 elif b <= -100.0: tmp = x * (math.exp(b) / y) elif b <= 6.6e-40: 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(y * exp(b))) tmp = 0.0 if (b <= -8e+43) tmp = t_1; elseif (b <= -100.0) tmp = Float64(x * Float64(exp(b) / y)); elseif (b <= 6.6e-40) tmp = Float64(x * Float64(Float64(1.0 / y) / a)); 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 <= -8e+43) tmp = t_1; elseif (b <= -100.0) tmp = x * (exp(b) / y); elseif (b <= 6.6e-40) 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[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -8e+43], t$95$1, If[LessEqual[b, -100.0], N[(x * N[(N[Exp[b], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 6.6e-40], N[(x * N[(N[(1.0 / y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{y \cdot e^{b}}\\
\mathbf{if}\;b \leq -8 \cdot 10^{+43}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq -100:\\
\;\;\;\;x \cdot \frac{e^{b}}{y}\\
\mathbf{elif}\;b \leq 6.6 \cdot 10^{-40}:\\
\;\;\;\;x \cdot \frac{\frac{1}{y}}{a}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -8.00000000000000011e43 or 6.59999999999999986e-40 < b Initial program 100.0%
*-commutative100.0%
associate-/l*89.3%
associate--l+89.3%
fma-define89.3%
sub-neg89.3%
metadata-eval89.3%
Simplified89.3%
Taylor expanded in b around inf 66.8%
neg-mul-166.8%
Simplified66.8%
exp-neg66.8%
frac-times74.3%
*-un-lft-identity74.3%
*-commutative74.3%
Applied egg-rr74.3%
if -8.00000000000000011e43 < b < -100Initial program 100.0%
*-commutative100.0%
associate-/l*83.3%
associate--l+83.3%
fma-define83.3%
sub-neg83.3%
metadata-eval83.3%
Simplified83.3%
Taylor expanded in b around inf 1.6%
neg-mul-11.6%
Simplified1.6%
exp-neg1.6%
frac-times1.6%
*-un-lft-identity1.6%
*-commutative1.6%
Applied egg-rr1.6%
div-inv1.6%
*-commutative1.6%
associate-/l/1.6%
exp-neg1.6%
add-sqr-sqrt1.6%
sqrt-unprod1.6%
sqr-neg1.6%
sqrt-unprod0.0%
add-sqr-sqrt100.0%
Applied egg-rr100.0%
if -100 < b < 6.59999999999999986e-40Initial program 97.1%
associate-/l*97.6%
exp-diff97.6%
associate-/l/97.6%
exp-sum81.9%
times-frac82.0%
*-commutative82.0%
exp-to-pow82.0%
*-commutative82.0%
exp-to-pow82.8%
sub-neg82.8%
metadata-eval82.8%
Simplified82.8%
Taylor expanded in y around 0 72.1%
associate-/l*73.3%
exp-to-pow74.1%
sub-neg74.1%
metadata-eval74.1%
Simplified74.1%
unpow-prod-up74.2%
unpow-174.2%
Applied egg-rr74.2%
associate-*r/74.2%
*-rgt-identity74.2%
Simplified74.2%
Taylor expanded in b around 0 73.6%
Taylor expanded in t around 0 38.7%
*-commutative38.7%
associate-/r*38.7%
Simplified38.7%
Final simplification57.1%
(FPCore (x y z t a b) :precision binary64 (if (or (<= t -7.5e+19) (not (<= t 550000000.0))) (* x (/ (/ (pow a t) a) y)) (/ x (* y (* a (exp b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -7.5e+19) || !(t <= 550000000.0)) {
tmp = x * ((pow(a, t) / a) / y);
} else {
tmp = x / (y * (a * 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 <= (-7.5d+19)) .or. (.not. (t <= 550000000.0d0))) then
tmp = x * (((a ** t) / a) / y)
else
tmp = x / (y * (a * 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 <= -7.5e+19) || !(t <= 550000000.0)) {
tmp = x * ((Math.pow(a, t) / a) / y);
} else {
tmp = x / (y * (a * Math.exp(b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t <= -7.5e+19) or not (t <= 550000000.0): tmp = x * ((math.pow(a, t) / a) / y) else: tmp = x / (y * (a * math.exp(b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((t <= -7.5e+19) || !(t <= 550000000.0)) tmp = Float64(x * Float64(Float64((a ^ t) / a) / y)); else tmp = Float64(x / Float64(y * Float64(a * exp(b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((t <= -7.5e+19) || ~((t <= 550000000.0))) tmp = x * (((a ^ t) / a) / y); else tmp = x / (y * (a * exp(b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[t, -7.5e+19], N[Not[LessEqual[t, 550000000.0]], $MachinePrecision]], N[(x * N[(N[(N[Power[a, t], $MachinePrecision] / a), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * N[(a * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -7.5 \cdot 10^{+19} \lor \neg \left(t \leq 550000000\right):\\
\;\;\;\;x \cdot \frac{\frac{{a}^{t}}{a}}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot \left(a \cdot e^{b}\right)}\\
\end{array}
\end{array}
if t < -7.5e19 or 5.5e8 < t Initial program 100.0%
associate-/l*100.0%
exp-diff78.0%
associate-/l/78.0%
exp-sum57.5%
times-frac57.5%
*-commutative57.5%
exp-to-pow57.5%
*-commutative57.5%
exp-to-pow57.5%
sub-neg57.5%
metadata-eval57.5%
Simplified57.5%
Taylor expanded in y around 0 69.4%
associate-/l*69.4%
exp-to-pow69.4%
sub-neg69.4%
metadata-eval69.4%
Simplified69.4%
unpow-prod-up69.4%
unpow-169.4%
Applied egg-rr69.4%
associate-*r/69.4%
*-rgt-identity69.4%
Simplified69.4%
Taylor expanded in b around 0 83.7%
if -7.5e19 < t < 5.5e8Initial program 97.1%
associate-/l*97.6%
exp-diff81.3%
associate-/l/81.3%
exp-sum79.8%
times-frac79.8%
*-commutative79.8%
exp-to-pow79.8%
*-commutative79.8%
exp-to-pow80.6%
sub-neg80.6%
metadata-eval80.6%
Simplified80.6%
Taylor expanded in y around 0 64.6%
associate-/l*68.1%
exp-to-pow68.9%
sub-neg68.9%
metadata-eval68.9%
Simplified68.9%
Taylor expanded in t around 0 70.4%
*-commutative70.4%
associate-*l*70.4%
*-commutative70.4%
Simplified70.4%
Final simplification77.0%
(FPCore (x y z t a b)
:precision binary64
(if (<= t 4.6e-61)
(* x (/ (/ 1.0 y) a))
(if (<= t 8e+150)
(/ (- (* x y) (* y (* x b))) (* y y))
(* x (/ (exp b) y)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= 4.6e-61) {
tmp = x * ((1.0 / y) / a);
} else if (t <= 8e+150) {
tmp = ((x * y) - (y * (x * b))) / (y * y);
} 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 (t <= 4.6d-61) then
tmp = x * ((1.0d0 / y) / a)
else if (t <= 8d+150) then
tmp = ((x * y) - (y * (x * b))) / (y * y)
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 (t <= 4.6e-61) {
tmp = x * ((1.0 / y) / a);
} else if (t <= 8e+150) {
tmp = ((x * y) - (y * (x * b))) / (y * y);
} else {
tmp = x * (Math.exp(b) / y);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if t <= 4.6e-61: tmp = x * ((1.0 / y) / a) elif t <= 8e+150: tmp = ((x * y) - (y * (x * b))) / (y * y) else: tmp = x * (math.exp(b) / y) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (t <= 4.6e-61) tmp = Float64(x * Float64(Float64(1.0 / y) / a)); elseif (t <= 8e+150) tmp = Float64(Float64(Float64(x * y) - Float64(y * Float64(x * b))) / Float64(y * y)); 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 (t <= 4.6e-61) tmp = x * ((1.0 / y) / a); elseif (t <= 8e+150) tmp = ((x * y) - (y * (x * b))) / (y * y); else tmp = x * (exp(b) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, 4.6e-61], N[(x * N[(N[(1.0 / y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 8e+150], N[(N[(N[(x * y), $MachinePrecision] - N[(y * N[(x * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y * y), $MachinePrecision]), $MachinePrecision], N[(x * N[(N[Exp[b], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq 4.6 \cdot 10^{-61}:\\
\;\;\;\;x \cdot \frac{\frac{1}{y}}{a}\\
\mathbf{elif}\;t \leq 8 \cdot 10^{+150}:\\
\;\;\;\;\frac{x \cdot y - y \cdot \left(x \cdot b\right)}{y \cdot y}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{e^{b}}{y}\\
\end{array}
\end{array}
if t < 4.59999999999999984e-61Initial program 98.4%
associate-/l*98.3%
exp-diff79.4%
associate-/l/79.4%
exp-sum74.4%
times-frac74.4%
*-commutative74.4%
exp-to-pow74.4%
*-commutative74.4%
exp-to-pow75.0%
sub-neg75.0%
metadata-eval75.0%
Simplified75.0%
Taylor expanded in y around 0 67.3%
associate-/l*69.4%
exp-to-pow70.0%
sub-neg70.0%
metadata-eval70.0%
Simplified70.0%
unpow-prod-up70.0%
unpow-170.0%
Applied egg-rr70.0%
associate-*r/70.0%
*-rgt-identity70.0%
Simplified70.0%
Taylor expanded in b around 0 58.0%
Taylor expanded in t around 0 41.7%
*-commutative41.7%
associate-/r*41.8%
Simplified41.8%
if 4.59999999999999984e-61 < t < 7.99999999999999985e150Initial program 98.2%
*-commutative98.2%
associate-/l*95.3%
associate--l+95.3%
fma-define95.3%
sub-neg95.3%
metadata-eval95.3%
Simplified95.3%
Taylor expanded in b around inf 42.8%
neg-mul-142.8%
Simplified42.8%
exp-neg42.8%
frac-times42.8%
*-un-lft-identity42.8%
*-commutative42.8%
Applied egg-rr42.8%
Taylor expanded in b around 0 16.5%
+-commutative16.5%
mul-1-neg16.5%
unsub-neg16.5%
*-commutative16.5%
associate-/l*22.9%
Simplified22.9%
frac-2neg22.9%
associate-*r/16.5%
frac-sub33.0%
Applied egg-rr33.0%
if 7.99999999999999985e150 < t Initial program 100.0%
*-commutative100.0%
associate-/l*93.8%
associate--l+93.8%
fma-define93.8%
sub-neg93.8%
metadata-eval93.8%
Simplified93.8%
Taylor expanded in b around inf 26.2%
neg-mul-126.2%
Simplified26.2%
exp-neg26.2%
frac-times26.2%
*-un-lft-identity26.2%
*-commutative26.2%
Applied egg-rr26.2%
div-inv26.2%
*-commutative26.2%
associate-/l/26.2%
exp-neg26.2%
add-sqr-sqrt16.8%
sqrt-unprod35.4%
sqr-neg35.4%
sqrt-unprod18.6%
add-sqr-sqrt38.5%
Applied egg-rr38.5%
Final simplification39.8%
(FPCore (x y z t a b) :precision binary64 (if (<= t 5.2e+172) (/ x (* y (* a (exp b)))) (* x (/ (exp b) y))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= 5.2e+172) {
tmp = x / (y * (a * 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 (t <= 5.2d+172) then
tmp = x / (y * (a * 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 (t <= 5.2e+172) {
tmp = x / (y * (a * Math.exp(b)));
} else {
tmp = x * (Math.exp(b) / y);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if t <= 5.2e+172: tmp = x / (y * (a * math.exp(b))) else: tmp = x * (math.exp(b) / y) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (t <= 5.2e+172) tmp = Float64(x / Float64(y * Float64(a * 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 (t <= 5.2e+172) tmp = x / (y * (a * exp(b))); else tmp = x * (exp(b) / y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, 5.2e+172], N[(x / N[(y * N[(a * 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}\;t \leq 5.2 \cdot 10^{+172}:\\
\;\;\;\;\frac{x}{y \cdot \left(a \cdot e^{b}\right)}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{e^{b}}{y}\\
\end{array}
\end{array}
if t < 5.2e172Initial program 98.4%
associate-/l*98.6%
exp-diff80.0%
associate-/l/80.0%
exp-sum72.1%
times-frac72.1%
*-commutative72.1%
exp-to-pow72.1%
*-commutative72.1%
exp-to-pow72.6%
sub-neg72.6%
metadata-eval72.6%
Simplified72.6%
Taylor expanded in y around 0 65.9%
associate-/l*67.8%
exp-to-pow68.3%
sub-neg68.3%
metadata-eval68.3%
Simplified68.3%
Taylor expanded in t around 0 59.7%
*-commutative59.7%
associate-*l*59.7%
*-commutative59.7%
Simplified59.7%
if 5.2e172 < t Initial program 100.0%
*-commutative100.0%
associate-/l*92.3%
associate--l+92.3%
fma-define92.3%
sub-neg92.3%
metadata-eval92.3%
Simplified92.3%
Taylor expanded in b around inf 20.4%
neg-mul-120.4%
Simplified20.4%
exp-neg20.4%
frac-times20.4%
*-un-lft-identity20.4%
*-commutative20.4%
Applied egg-rr20.4%
div-inv20.4%
*-commutative20.4%
associate-/l/20.4%
exp-neg20.4%
add-sqr-sqrt8.9%
sqrt-unprod27.9%
sqr-neg27.9%
sqrt-unprod19.0%
add-sqr-sqrt39.3%
Applied egg-rr39.3%
Final simplification57.6%
(FPCore (x y z t a b) :precision binary64 (if (or (<= b 3.4e-283) (and (not (<= b 2.3e-147)) (<= b 7.5e+159))) (/ x (* y a)) (/ x (* y b))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= 3.4e-283) || (!(b <= 2.3e-147) && (b <= 7.5e+159))) {
tmp = x / (y * a);
} else {
tmp = x / (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 <= 3.4d-283) .or. (.not. (b <= 2.3d-147)) .and. (b <= 7.5d+159)) then
tmp = x / (y * a)
else
tmp = x / (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 <= 3.4e-283) || (!(b <= 2.3e-147) && (b <= 7.5e+159))) {
tmp = x / (y * a);
} else {
tmp = x / (y * b);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (b <= 3.4e-283) or (not (b <= 2.3e-147) and (b <= 7.5e+159)): tmp = x / (y * a) else: tmp = x / (y * b) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= 3.4e-283) || (!(b <= 2.3e-147) && (b <= 7.5e+159))) tmp = Float64(x / Float64(y * a)); else tmp = Float64(x / Float64(y * b)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((b <= 3.4e-283) || (~((b <= 2.3e-147)) && (b <= 7.5e+159))) tmp = x / (y * a); else tmp = x / (y * b); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, 3.4e-283], And[N[Not[LessEqual[b, 2.3e-147]], $MachinePrecision], LessEqual[b, 7.5e+159]]], N[(x / N[(y * a), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * b), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq 3.4 \cdot 10^{-283} \lor \neg \left(b \leq 2.3 \cdot 10^{-147}\right) \land b \leq 7.5 \cdot 10^{+159}:\\
\;\;\;\;\frac{x}{y \cdot a}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot b}\\
\end{array}
\end{array}
if b < 3.3999999999999998e-283 or 2.2999999999999999e-147 < b < 7.4999999999999997e159Initial program 98.2%
*-commutative98.2%
associate-/l*88.8%
associate--l+88.8%
fma-define88.8%
sub-neg88.8%
metadata-eval88.8%
Simplified88.8%
Taylor expanded in t around 0 74.1%
associate-/l*75.5%
+-commutative75.5%
mul-1-neg75.5%
unsub-neg75.5%
Simplified75.5%
Taylor expanded in b around 0 64.3%
div-exp64.3%
*-commutative64.3%
exp-to-pow64.3%
rem-exp-log64.8%
Simplified64.8%
Taylor expanded in y around 0 37.5%
if 3.3999999999999998e-283 < b < 2.2999999999999999e-147 or 7.4999999999999997e159 < b Initial program 99.7%
*-commutative99.7%
associate-/l*92.3%
associate--l+92.3%
fma-define92.3%
sub-neg92.3%
metadata-eval92.3%
Simplified92.3%
Taylor expanded in b around inf 46.9%
neg-mul-146.9%
Simplified46.9%
exp-neg46.9%
frac-times51.3%
*-un-lft-identity51.3%
*-commutative51.3%
Applied egg-rr51.3%
Taylor expanded in b around 0 33.4%
distribute-rgt1-in33.4%
Simplified33.4%
Taylor expanded in b around inf 43.7%
*-commutative43.7%
Simplified43.7%
Final simplification39.2%
(FPCore (x y z t a b) :precision binary64 (if (<= t 2.25e-58) (* x (/ (/ 1.0 y) a)) (/ (- (* x y) (* y (* x b))) (* y y))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= 2.25e-58) {
tmp = x * ((1.0 / y) / a);
} else {
tmp = ((x * y) - (y * (x * b))) / (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 (t <= 2.25d-58) then
tmp = x * ((1.0d0 / y) / a)
else
tmp = ((x * y) - (y * (x * b))) / (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 (t <= 2.25e-58) {
tmp = x * ((1.0 / y) / a);
} else {
tmp = ((x * y) - (y * (x * b))) / (y * y);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if t <= 2.25e-58: tmp = x * ((1.0 / y) / a) else: tmp = ((x * y) - (y * (x * b))) / (y * y) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (t <= 2.25e-58) tmp = Float64(x * Float64(Float64(1.0 / y) / a)); else tmp = Float64(Float64(Float64(x * y) - Float64(y * Float64(x * b))) / Float64(y * y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (t <= 2.25e-58) tmp = x * ((1.0 / y) / a); else tmp = ((x * y) - (y * (x * b))) / (y * y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, 2.25e-58], N[(x * N[(N[(1.0 / y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], N[(N[(N[(x * y), $MachinePrecision] - N[(y * N[(x * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(y * y), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq 2.25 \cdot 10^{-58}:\\
\;\;\;\;x \cdot \frac{\frac{1}{y}}{a}\\
\mathbf{else}:\\
\;\;\;\;\frac{x \cdot y - y \cdot \left(x \cdot b\right)}{y \cdot y}\\
\end{array}
\end{array}
if t < 2.2500000000000001e-58Initial program 98.4%
associate-/l*98.3%
exp-diff79.4%
associate-/l/79.4%
exp-sum74.4%
times-frac74.4%
*-commutative74.4%
exp-to-pow74.4%
*-commutative74.4%
exp-to-pow75.0%
sub-neg75.0%
metadata-eval75.0%
Simplified75.0%
Taylor expanded in y around 0 67.3%
associate-/l*69.4%
exp-to-pow70.0%
sub-neg70.0%
metadata-eval70.0%
Simplified70.0%
unpow-prod-up70.0%
unpow-170.0%
Applied egg-rr70.0%
associate-*r/70.0%
*-rgt-identity70.0%
Simplified70.0%
Taylor expanded in b around 0 58.0%
Taylor expanded in t around 0 41.7%
*-commutative41.7%
associate-/r*41.8%
Simplified41.8%
if 2.2500000000000001e-58 < t Initial program 99.0%
*-commutative99.0%
associate-/l*94.6%
associate--l+94.6%
fma-define94.6%
sub-neg94.6%
metadata-eval94.6%
Simplified94.6%
Taylor expanded in b around inf 35.8%
neg-mul-135.8%
Simplified35.8%
exp-neg35.8%
frac-times35.8%
*-un-lft-identity35.8%
*-commutative35.8%
Applied egg-rr35.8%
Taylor expanded in b around 0 16.7%
+-commutative16.7%
mul-1-neg16.7%
unsub-neg16.7%
*-commutative16.7%
associate-/l*20.4%
Simplified20.4%
frac-2neg20.4%
associate-*r/16.7%
frac-sub29.8%
Applied egg-rr29.8%
Final simplification38.2%
(FPCore (x y z t a b) :precision binary64 (if (<= b -1.06e+95) (* x (/ b (- y))) (if (<= b 1.25e+161) (* x (/ 1.0 (* y a))) (/ x (* y b)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -1.06e+95) {
tmp = x * (b / -y);
} else if (b <= 1.25e+161) {
tmp = x * (1.0 / (y * a));
} else {
tmp = x / (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.06d+95)) then
tmp = x * (b / -y)
else if (b <= 1.25d+161) then
tmp = x * (1.0d0 / (y * a))
else
tmp = x / (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.06e+95) {
tmp = x * (b / -y);
} else if (b <= 1.25e+161) {
tmp = x * (1.0 / (y * a));
} else {
tmp = x / (y * b);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -1.06e+95: tmp = x * (b / -y) elif b <= 1.25e+161: tmp = x * (1.0 / (y * a)) else: tmp = x / (y * b) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -1.06e+95) tmp = Float64(x * Float64(b / Float64(-y))); elseif (b <= 1.25e+161) tmp = Float64(x * Float64(1.0 / Float64(y * a))); else tmp = Float64(x / Float64(y * b)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -1.06e+95) tmp = x * (b / -y); elseif (b <= 1.25e+161) tmp = x * (1.0 / (y * a)); else tmp = x / (y * b); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -1.06e+95], N[(x * N[(b / (-y)), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 1.25e+161], N[(x * N[(1.0 / N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * b), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.06 \cdot 10^{+95}:\\
\;\;\;\;x \cdot \frac{b}{-y}\\
\mathbf{elif}\;b \leq 1.25 \cdot 10^{+161}:\\
\;\;\;\;x \cdot \frac{1}{y \cdot a}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot b}\\
\end{array}
\end{array}
if b < -1.06000000000000001e95Initial 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 75.2%
neg-mul-175.2%
Simplified75.2%
exp-neg75.2%
frac-times80.3%
*-un-lft-identity80.3%
*-commutative80.3%
Applied egg-rr80.3%
Taylor expanded in b around 0 30.8%
+-commutative30.8%
mul-1-neg30.8%
unsub-neg30.8%
*-commutative30.8%
associate-/l*42.7%
Simplified42.7%
Taylor expanded in b around inf 30.8%
mul-1-neg30.8%
*-commutative30.8%
distribute-frac-neg230.8%
associate-*r/42.7%
Simplified42.7%
if -1.06000000000000001e95 < b < 1.2499999999999999e161Initial program 98.0%
*-commutative98.0%
associate-/l*89.0%
associate--l+89.0%
fma-define89.0%
sub-neg89.0%
metadata-eval89.0%
Simplified89.0%
Taylor expanded in t around 0 67.9%
associate-/l*68.9%
+-commutative68.9%
mul-1-neg68.9%
unsub-neg68.9%
Simplified68.9%
Taylor expanded in b around 0 64.4%
div-exp64.4%
*-commutative64.4%
exp-to-pow64.4%
rem-exp-log64.9%
Simplified64.9%
Taylor expanded in y around 0 36.4%
if 1.2499999999999999e161 < b Initial program 100.0%
*-commutative100.0%
associate-/l*87.9%
associate--l+87.9%
fma-define87.9%
sub-neg87.9%
metadata-eval87.9%
Simplified87.9%
Taylor expanded in b around inf 79.0%
neg-mul-179.0%
Simplified79.0%
exp-neg79.0%
frac-times88.1%
*-un-lft-identity88.1%
*-commutative88.1%
Applied egg-rr88.1%
Taylor expanded in b around 0 51.2%
distribute-rgt1-in51.2%
Simplified51.2%
Taylor expanded in b around inf 51.2%
*-commutative51.2%
Simplified51.2%
Final simplification39.3%
(FPCore (x y z t a b) :precision binary64 (if (<= b -3.3e+89) (* x (/ b (- y))) (if (<= b 3.5e+159) (* x (/ (/ 1.0 y) a)) (/ x (* y b)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -3.3e+89) {
tmp = x * (b / -y);
} else if (b <= 3.5e+159) {
tmp = x * ((1.0 / y) / a);
} else {
tmp = x / (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 <= (-3.3d+89)) then
tmp = x * (b / -y)
else if (b <= 3.5d+159) then
tmp = x * ((1.0d0 / y) / a)
else
tmp = x / (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 <= -3.3e+89) {
tmp = x * (b / -y);
} else if (b <= 3.5e+159) {
tmp = x * ((1.0 / y) / a);
} else {
tmp = x / (y * b);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -3.3e+89: tmp = x * (b / -y) elif b <= 3.5e+159: tmp = x * ((1.0 / y) / a) else: tmp = x / (y * b) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -3.3e+89) tmp = Float64(x * Float64(b / Float64(-y))); elseif (b <= 3.5e+159) tmp = Float64(x * Float64(Float64(1.0 / y) / a)); else tmp = Float64(x / Float64(y * b)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -3.3e+89) tmp = x * (b / -y); elseif (b <= 3.5e+159) tmp = x * ((1.0 / y) / a); else tmp = x / (y * b); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -3.3e+89], N[(x * N[(b / (-y)), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 3.5e+159], N[(x * N[(N[(1.0 / y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision], N[(x / N[(y * b), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -3.3 \cdot 10^{+89}:\\
\;\;\;\;x \cdot \frac{b}{-y}\\
\mathbf{elif}\;b \leq 3.5 \cdot 10^{+159}:\\
\;\;\;\;x \cdot \frac{\frac{1}{y}}{a}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot b}\\
\end{array}
\end{array}
if b < -3.29999999999999974e89Initial 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 75.2%
neg-mul-175.2%
Simplified75.2%
exp-neg75.2%
frac-times80.3%
*-un-lft-identity80.3%
*-commutative80.3%
Applied egg-rr80.3%
Taylor expanded in b around 0 30.8%
+-commutative30.8%
mul-1-neg30.8%
unsub-neg30.8%
*-commutative30.8%
associate-/l*42.7%
Simplified42.7%
Taylor expanded in b around inf 30.8%
mul-1-neg30.8%
*-commutative30.8%
distribute-frac-neg230.8%
associate-*r/42.7%
Simplified42.7%
if -3.29999999999999974e89 < b < 3.4999999999999999e159Initial program 98.0%
associate-/l*98.3%
exp-diff86.3%
associate-/l/86.3%
exp-sum73.7%
times-frac73.7%
*-commutative73.7%
exp-to-pow73.7%
*-commutative73.7%
exp-to-pow74.3%
sub-neg74.3%
metadata-eval74.3%
Simplified74.3%
Taylor expanded in y around 0 66.9%
associate-/l*67.7%
exp-to-pow68.3%
sub-neg68.3%
metadata-eval68.3%
Simplified68.3%
unpow-prod-up68.4%
unpow-168.4%
Applied egg-rr68.4%
associate-*r/68.4%
*-rgt-identity68.4%
Simplified68.4%
Taylor expanded in b around 0 71.5%
Taylor expanded in t around 0 36.4%
*-commutative36.4%
associate-/r*36.4%
Simplified36.4%
if 3.4999999999999999e159 < b Initial program 100.0%
*-commutative100.0%
associate-/l*87.9%
associate--l+87.9%
fma-define87.9%
sub-neg87.9%
metadata-eval87.9%
Simplified87.9%
Taylor expanded in b around inf 79.0%
neg-mul-179.0%
Simplified79.0%
exp-neg79.0%
frac-times88.1%
*-un-lft-identity88.1%
*-commutative88.1%
Applied egg-rr88.1%
Taylor expanded in b around 0 51.2%
distribute-rgt1-in51.2%
Simplified51.2%
Taylor expanded in b around inf 51.2%
*-commutative51.2%
Simplified51.2%
Final simplification39.3%
(FPCore (x y z t a b) :precision binary64 (if (<= t 2.25e-58) (/ x (* y a)) (* x (/ b (- y)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= 2.25e-58) {
tmp = x / (y * a);
} else {
tmp = x * (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 (t <= 2.25d-58) then
tmp = x / (y * a)
else
tmp = x * (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 (t <= 2.25e-58) {
tmp = x / (y * a);
} else {
tmp = x * (b / -y);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if t <= 2.25e-58: tmp = x / (y * a) else: tmp = x * (b / -y) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (t <= 2.25e-58) tmp = Float64(x / Float64(y * a)); else tmp = Float64(x * Float64(b / Float64(-y))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (t <= 2.25e-58) tmp = x / (y * a); else tmp = x * (b / -y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, 2.25e-58], N[(x / N[(y * a), $MachinePrecision]), $MachinePrecision], N[(x * N[(b / (-y)), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq 2.25 \cdot 10^{-58}:\\
\;\;\;\;\frac{x}{y \cdot a}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{b}{-y}\\
\end{array}
\end{array}
if t < 2.2500000000000001e-58Initial program 98.4%
*-commutative98.4%
associate-/l*87.7%
associate--l+87.7%
fma-define87.7%
sub-neg87.7%
metadata-eval87.7%
Simplified87.7%
Taylor expanded in t around 0 85.8%
associate-/l*86.8%
+-commutative86.8%
mul-1-neg86.8%
unsub-neg86.8%
Simplified86.8%
Taylor expanded in b around 0 69.0%
div-exp69.0%
*-commutative69.0%
exp-to-pow69.0%
rem-exp-log69.6%
Simplified69.6%
Taylor expanded in y around 0 41.2%
if 2.2500000000000001e-58 < t Initial program 99.0%
*-commutative99.0%
associate-/l*94.6%
associate--l+94.6%
fma-define94.6%
sub-neg94.6%
metadata-eval94.6%
Simplified94.6%
Taylor expanded in b around inf 35.8%
neg-mul-135.8%
Simplified35.8%
exp-neg35.8%
frac-times35.8%
*-un-lft-identity35.8%
*-commutative35.8%
Applied egg-rr35.8%
Taylor expanded in b around 0 16.7%
+-commutative16.7%
mul-1-neg16.7%
unsub-neg16.7%
*-commutative16.7%
associate-/l*20.4%
Simplified20.4%
Taylor expanded in b around inf 20.7%
mul-1-neg20.7%
*-commutative20.7%
distribute-frac-neg220.7%
associate-*r/24.4%
Simplified24.4%
Final simplification36.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 98.6%
*-commutative98.6%
associate-/l*89.8%
associate--l+89.8%
fma-define89.8%
sub-neg89.8%
metadata-eval89.8%
Simplified89.8%
Taylor expanded in t around 0 76.3%
associate-/l*77.0%
+-commutative77.0%
mul-1-neg77.0%
unsub-neg77.0%
Simplified77.0%
Taylor expanded in b around 0 60.8%
div-exp60.8%
*-commutative60.8%
exp-to-pow60.8%
rem-exp-log61.2%
Simplified61.2%
Taylor expanded in y around 0 33.7%
Final simplification33.7%
(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.6%
*-commutative98.6%
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 40.2%
neg-mul-140.2%
Simplified40.2%
Taylor expanded in b around 0 16.4%
Final simplification16.4%
(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 2024053
(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))