
(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 18 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)) (* (log a) (+ t -1.0))) b))) y))
double code(double x, double y, double z, double t, double a, double b) {
return (x * exp((((y * log(z)) + (log(a) * (t + -1.0))) - 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)) + (log(a) * (t + (-1.0d0)))) - 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)) + (Math.log(a) * (t + -1.0))) - b))) / y;
}
def code(x, y, z, t, a, b): return (x * math.exp((((y * math.log(z)) + (math.log(a) * (t + -1.0))) - b))) / y
function code(x, y, z, t, a, b) return Float64(Float64(x * exp(Float64(Float64(Float64(y * log(z)) + Float64(log(a) * Float64(t + -1.0))) - b))) / y) end
function tmp = code(x, y, z, t, a, b) tmp = (x * exp((((y * log(z)) + (log(a) * (t + -1.0))) - 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[Log[a], $MachinePrecision] * N[(t + -1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]
\begin{array}{l}
\\
\frac{x \cdot e^{\left(y \cdot \log z + \log a \cdot \left(t + -1\right)\right) - b}}{y}
\end{array}
Initial program 97.8%
Final simplification97.8%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -1.2e+32) (not (<= y 0.00019))) (/ (* x (exp (- (- (* y (log z)) (log a)) b))) y) (/ (* x (exp (- (* (log a) (+ t -1.0)) b))) y)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -1.2e+32) || !(y <= 0.00019)) {
tmp = (x * exp((((y * log(z)) - log(a)) - b))) / y;
} else {
tmp = (x * exp(((log(a) * (t + -1.0)) - b))) / y;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((y <= (-1.2d+32)) .or. (.not. (y <= 0.00019d0))) then
tmp = (x * exp((((y * log(z)) - log(a)) - b))) / y
else
tmp = (x * exp(((log(a) * (t + (-1.0d0))) - b))) / y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -1.2e+32) || !(y <= 0.00019)) {
tmp = (x * Math.exp((((y * Math.log(z)) - Math.log(a)) - b))) / y;
} else {
tmp = (x * Math.exp(((Math.log(a) * (t + -1.0)) - b))) / y;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -1.2e+32) or not (y <= 0.00019): tmp = (x * math.exp((((y * math.log(z)) - math.log(a)) - b))) / y else: tmp = (x * math.exp(((math.log(a) * (t + -1.0)) - b))) / y return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -1.2e+32) || !(y <= 0.00019)) tmp = Float64(Float64(x * exp(Float64(Float64(Float64(y * log(z)) - log(a)) - b))) / y); else tmp = Float64(Float64(x * exp(Float64(Float64(log(a) * Float64(t + -1.0)) - b))) / y); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -1.2e+32) || ~((y <= 0.00019))) tmp = (x * exp((((y * log(z)) - log(a)) - b))) / y; else tmp = (x * exp(((log(a) * (t + -1.0)) - b))) / y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -1.2e+32], N[Not[LessEqual[y, 0.00019]], $MachinePrecision]], N[(N[(x * N[Exp[N[(N[(N[(y * N[Log[z], $MachinePrecision]), $MachinePrecision] - N[Log[a], $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], N[(N[(x * N[Exp[N[(N[(N[Log[a], $MachinePrecision] * N[(t + -1.0), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.2 \cdot 10^{+32} \lor \neg \left(y \leq 0.00019\right):\\
\;\;\;\;\frac{x \cdot e^{\left(y \cdot \log z - \log a\right) - b}}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{x \cdot e^{\log a \cdot \left(t + -1\right) - b}}{y}\\
\end{array}
\end{array}
if y < -1.19999999999999996e32 or 1.9000000000000001e-4 < y Initial program 100.0%
Taylor expanded in t around 0 92.3%
+-commutative92.3%
mul-1-neg92.3%
log-rec92.3%
log-div92.3%
metadata-eval92.3%
associate-+r-92.3%
+-rgt-identity92.3%
Simplified92.3%
if -1.19999999999999996e32 < y < 1.9000000000000001e-4Initial program 95.9%
Taylor expanded in y around 0 95.9%
Final simplification94.3%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (pow a (+ t -1.0)))
(t_2 (* (/ t_1 (exp b)) (/ x y)))
(t_3 (/ (/ (* x (pow z y)) y) a)))
(if (<= y -42000000000000.0)
t_3
(if (<= y -3e-187)
t_2
(if (<= y 6.5e-240) (/ x (/ y t_1)) (if (<= y 1.6e+18) t_2 t_3))))))
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 = (t_1 / exp(b)) * (x / y);
double t_3 = ((x * pow(z, y)) / y) / a;
double tmp;
if (y <= -42000000000000.0) {
tmp = t_3;
} else if (y <= -3e-187) {
tmp = t_2;
} else if (y <= 6.5e-240) {
tmp = x / (y / t_1);
} else if (y <= 1.6e+18) {
tmp = t_2;
} else {
tmp = t_3;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: t_2
real(8) :: t_3
real(8) :: tmp
t_1 = a ** (t + (-1.0d0))
t_2 = (t_1 / exp(b)) * (x / y)
t_3 = ((x * (z ** y)) / y) / a
if (y <= (-42000000000000.0d0)) then
tmp = t_3
else if (y <= (-3d-187)) then
tmp = t_2
else if (y <= 6.5d-240) then
tmp = x / (y / t_1)
else if (y <= 1.6d+18) then
tmp = t_2
else
tmp = t_3
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 = (t_1 / Math.exp(b)) * (x / y);
double t_3 = ((x * Math.pow(z, y)) / y) / a;
double tmp;
if (y <= -42000000000000.0) {
tmp = t_3;
} else if (y <= -3e-187) {
tmp = t_2;
} else if (y <= 6.5e-240) {
tmp = x / (y / t_1);
} else if (y <= 1.6e+18) {
tmp = t_2;
} else {
tmp = t_3;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = math.pow(a, (t + -1.0)) t_2 = (t_1 / math.exp(b)) * (x / y) t_3 = ((x * math.pow(z, y)) / y) / a tmp = 0 if y <= -42000000000000.0: tmp = t_3 elif y <= -3e-187: tmp = t_2 elif y <= 6.5e-240: tmp = x / (y / t_1) elif y <= 1.6e+18: tmp = t_2 else: tmp = t_3 return tmp
function code(x, y, z, t, a, b) t_1 = a ^ Float64(t + -1.0) t_2 = Float64(Float64(t_1 / exp(b)) * Float64(x / y)) t_3 = Float64(Float64(Float64(x * (z ^ y)) / y) / a) tmp = 0.0 if (y <= -42000000000000.0) tmp = t_3; elseif (y <= -3e-187) tmp = t_2; elseif (y <= 6.5e-240) tmp = Float64(x / Float64(y / t_1)); elseif (y <= 1.6e+18) tmp = t_2; else tmp = t_3; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = a ^ (t + -1.0); t_2 = (t_1 / exp(b)) * (x / y); t_3 = ((x * (z ^ y)) / y) / a; tmp = 0.0; if (y <= -42000000000000.0) tmp = t_3; elseif (y <= -3e-187) tmp = t_2; elseif (y <= 6.5e-240) tmp = x / (y / t_1); elseif (y <= 1.6e+18) tmp = t_2; else tmp = t_3; 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[(t$95$1 / N[Exp[b], $MachinePrecision]), $MachinePrecision] * N[(x / y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(N[(x * N[Power[z, y], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision] / a), $MachinePrecision]}, If[LessEqual[y, -42000000000000.0], t$95$3, If[LessEqual[y, -3e-187], t$95$2, If[LessEqual[y, 6.5e-240], N[(x / N[(y / t$95$1), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.6e+18], t$95$2, t$95$3]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := {a}^{\left(t + -1\right)}\\
t_2 := \frac{t_1}{e^{b}} \cdot \frac{x}{y}\\
t_3 := \frac{\frac{x \cdot {z}^{y}}{y}}{a}\\
\mathbf{if}\;y \leq -42000000000000:\\
\;\;\;\;t_3\\
\mathbf{elif}\;y \leq -3 \cdot 10^{-187}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;y \leq 6.5 \cdot 10^{-240}:\\
\;\;\;\;\frac{x}{\frac{y}{t_1}}\\
\mathbf{elif}\;y \leq 1.6 \cdot 10^{+18}:\\
\;\;\;\;t_2\\
\mathbf{else}:\\
\;\;\;\;t_3\\
\end{array}
\end{array}
if y < -4.2e13 or 1.6e18 < y Initial program 100.0%
associate-*l/85.0%
*-commutative85.0%
associate--l+85.0%
exp-sum56.6%
exp-diff50.4%
*-commutative50.4%
exp-to-pow50.4%
*-commutative50.4%
exp-to-pow50.4%
sub-neg50.4%
metadata-eval50.4%
Simplified50.4%
Taylor expanded in t around 0 65.6%
times-frac69.1%
Simplified69.1%
associate-*l/75.3%
clear-num75.3%
un-div-inv75.3%
Applied egg-rr75.3%
Taylor expanded in b around 0 87.8%
if -4.2e13 < y < -3.00000000000000004e-187 or 6.50000000000000007e-240 < y < 1.6e18Initial program 98.3%
associate-*l/97.2%
*-commutative97.2%
associate--l+97.2%
exp-sum95.1%
exp-diff82.3%
*-commutative82.3%
exp-to-pow82.3%
*-commutative82.3%
exp-to-pow83.9%
sub-neg83.9%
metadata-eval83.9%
Simplified83.9%
Taylor expanded in y around 0 83.4%
associate-/l*83.8%
*-commutative83.8%
sub-neg83.8%
metadata-eval83.8%
*-commutative83.8%
exp-to-pow85.2%
associate-/l*85.2%
associate-/r/86.1%
*-commutative86.1%
Simplified86.1%
if -3.00000000000000004e-187 < y < 6.50000000000000007e-240Initial program 91.5%
Taylor expanded in y around 0 91.5%
Taylor expanded in b around 0 83.6%
associate-/l*90.5%
sub-neg90.5%
metadata-eval90.5%
exp-to-pow91.8%
+-commutative91.8%
Simplified91.8%
Final simplification87.9%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -1.1e+43) (not (<= y 6.6e+130))) (/ (/ (* x (pow z y)) y) a) (/ (* x (exp (- (* (log a) (+ t -1.0)) b))) y)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -1.1e+43) || !(y <= 6.6e+130)) {
tmp = ((x * pow(z, y)) / y) / a;
} else {
tmp = (x * exp(((log(a) * (t + -1.0)) - b))) / y;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((y <= (-1.1d+43)) .or. (.not. (y <= 6.6d+130))) then
tmp = ((x * (z ** y)) / y) / a
else
tmp = (x * exp(((log(a) * (t + (-1.0d0))) - b))) / y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -1.1e+43) || !(y <= 6.6e+130)) {
tmp = ((x * Math.pow(z, y)) / y) / a;
} else {
tmp = (x * Math.exp(((Math.log(a) * (t + -1.0)) - b))) / y;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -1.1e+43) or not (y <= 6.6e+130): tmp = ((x * math.pow(z, y)) / y) / a else: tmp = (x * math.exp(((math.log(a) * (t + -1.0)) - b))) / y return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -1.1e+43) || !(y <= 6.6e+130)) tmp = Float64(Float64(Float64(x * (z ^ y)) / y) / a); else tmp = Float64(Float64(x * exp(Float64(Float64(log(a) * Float64(t + -1.0)) - b))) / y); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -1.1e+43) || ~((y <= 6.6e+130))) tmp = ((x * (z ^ y)) / y) / a; else tmp = (x * exp(((log(a) * (t + -1.0)) - b))) / y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -1.1e+43], N[Not[LessEqual[y, 6.6e+130]], $MachinePrecision]], N[(N[(N[(x * N[Power[z, y], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision] / a), $MachinePrecision], N[(N[(x * N[Exp[N[(N[(N[Log[a], $MachinePrecision] * N[(t + -1.0), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.1 \cdot 10^{+43} \lor \neg \left(y \leq 6.6 \cdot 10^{+130}\right):\\
\;\;\;\;\frac{\frac{x \cdot {z}^{y}}{y}}{a}\\
\mathbf{else}:\\
\;\;\;\;\frac{x \cdot e^{\log a \cdot \left(t + -1\right) - b}}{y}\\
\end{array}
\end{array}
if y < -1.1e43 or 6.6e130 < y Initial program 100.0%
associate-*l/81.5%
*-commutative81.5%
associate--l+81.5%
exp-sum55.4%
exp-diff52.2%
*-commutative52.2%
exp-to-pow52.2%
*-commutative52.2%
exp-to-pow52.2%
sub-neg52.2%
metadata-eval52.2%
Simplified52.2%
Taylor expanded in t around 0 65.3%
times-frac71.8%
Simplified71.8%
associate-*l/77.3%
clear-num77.3%
un-div-inv77.3%
Applied egg-rr77.3%
Taylor expanded in b around 0 91.4%
if -1.1e43 < y < 6.6e130Initial program 96.5%
Taylor expanded in y around 0 93.5%
Final simplification92.8%
(FPCore (x y z t a b) :precision binary64 (if (or (<= t -1e+26) (not (<= t 69000000000000.0))) (/ x (/ y (pow a (+ t -1.0)))) (* (/ x a) (/ (pow z y) (* y (exp b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -1e+26) || !(t <= 69000000000000.0)) {
tmp = x / (y / pow(a, (t + -1.0)));
} else {
tmp = (x / a) * (pow(z, y) / (y * exp(b)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((t <= (-1d+26)) .or. (.not. (t <= 69000000000000.0d0))) then
tmp = x / (y / (a ** (t + (-1.0d0))))
else
tmp = (x / a) * ((z ** y) / (y * exp(b)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -1e+26) || !(t <= 69000000000000.0)) {
tmp = x / (y / Math.pow(a, (t + -1.0)));
} else {
tmp = (x / a) * (Math.pow(z, y) / (y * Math.exp(b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t <= -1e+26) or not (t <= 69000000000000.0): tmp = x / (y / math.pow(a, (t + -1.0))) else: tmp = (x / a) * (math.pow(z, y) / (y * math.exp(b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((t <= -1e+26) || !(t <= 69000000000000.0)) tmp = Float64(x / Float64(y / (a ^ Float64(t + -1.0)))); else tmp = Float64(Float64(x / a) * Float64((z ^ y) / Float64(y * exp(b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((t <= -1e+26) || ~((t <= 69000000000000.0))) tmp = x / (y / (a ^ (t + -1.0))); else tmp = (x / a) * ((z ^ y) / (y * exp(b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[t, -1e+26], N[Not[LessEqual[t, 69000000000000.0]], $MachinePrecision]], N[(x / N[(y / N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x / a), $MachinePrecision] * N[(N[Power[z, y], $MachinePrecision] / N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1 \cdot 10^{+26} \lor \neg \left(t \leq 69000000000000\right):\\
\;\;\;\;\frac{x}{\frac{y}{{a}^{\left(t + -1\right)}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a} \cdot \frac{{z}^{y}}{y \cdot e^{b}}\\
\end{array}
\end{array}
if t < -1.00000000000000005e26 or 6.9e13 < t Initial program 100.0%
Taylor expanded in y around 0 91.1%
Taylor expanded in b around 0 83.2%
associate-/l*83.2%
sub-neg83.2%
metadata-eval83.2%
exp-to-pow83.2%
+-commutative83.2%
Simplified83.2%
if -1.00000000000000005e26 < t < 6.9e13Initial program 96.0%
associate-*l/86.9%
*-commutative86.9%
associate--l+86.9%
exp-sum77.2%
exp-diff75.2%
*-commutative75.2%
exp-to-pow75.2%
*-commutative75.2%
exp-to-pow76.5%
sub-neg76.5%
metadata-eval76.5%
Simplified76.5%
Taylor expanded in t around 0 82.5%
times-frac83.5%
Simplified83.5%
Final simplification83.3%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -4.1e+14) (not (<= y 2.8e+17))) (/ (/ (* x (pow z y)) y) a) (/ (* 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.1e+14) || !(y <= 2.8e+17)) {
tmp = ((x * pow(z, y)) / y) / a;
} 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.1d+14)) .or. (.not. (y <= 2.8d+17))) then
tmp = ((x * (z ** y)) / y) / a
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.1e+14) || !(y <= 2.8e+17)) {
tmp = ((x * Math.pow(z, y)) / y) / a;
} 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.1e+14) or not (y <= 2.8e+17): tmp = ((x * math.pow(z, y)) / y) / a 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.1e+14) || !(y <= 2.8e+17)) tmp = Float64(Float64(Float64(x * (z ^ y)) / y) / a); else tmp = Float64(Float64(x * (a ^ t)) / Float64(a * Float64(y * exp(b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -4.1e+14) || ~((y <= 2.8e+17))) tmp = ((x * (z ^ y)) / y) / a; 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.1e+14], N[Not[LessEqual[y, 2.8e+17]], $MachinePrecision]], N[(N[(N[(x * N[Power[z, y], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision] / a), $MachinePrecision], N[(N[(x * N[Power[a, t], $MachinePrecision]), $MachinePrecision] / N[(a * N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.1 \cdot 10^{+14} \lor \neg \left(y \leq 2.8 \cdot 10^{+17}\right):\\
\;\;\;\;\frac{\frac{x \cdot {z}^{y}}{y}}{a}\\
\mathbf{else}:\\
\;\;\;\;\frac{x \cdot {a}^{t}}{a \cdot \left(y \cdot e^{b}\right)}\\
\end{array}
\end{array}
if y < -4.1e14 or 2.8e17 < y Initial program 100.0%
associate-*l/85.0%
*-commutative85.0%
associate--l+85.0%
exp-sum56.6%
exp-diff50.4%
*-commutative50.4%
exp-to-pow50.4%
*-commutative50.4%
exp-to-pow50.4%
sub-neg50.4%
metadata-eval50.4%
Simplified50.4%
Taylor expanded in t around 0 65.6%
times-frac69.1%
Simplified69.1%
associate-*l/75.3%
clear-num75.3%
un-div-inv75.3%
Applied egg-rr75.3%
Taylor expanded in b around 0 87.8%
if -4.1e14 < y < 2.8e17Initial program 96.0%
associate-*l/91.6%
*-commutative91.6%
associate--l+91.6%
exp-sum90.2%
exp-diff79.0%
*-commutative79.0%
exp-to-pow79.0%
*-commutative79.0%
exp-to-pow80.3%
sub-neg80.3%
metadata-eval80.3%
Simplified80.3%
metadata-eval80.3%
sub-neg80.3%
pow-sub80.4%
pow180.4%
Applied egg-rr80.4%
Taylor expanded in y around 0 86.0%
Final simplification86.8%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (/ x a) (/ (pow z y) y))))
(if (<= y -1.25e+26)
t_1
(if (<= y 2.3e-156)
(/ x (/ y (pow a (+ t -1.0))))
(if (<= y 3.7e+129) (/ (/ x (* y (exp b))) a) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x / a) * (pow(z, y) / y);
double tmp;
if (y <= -1.25e+26) {
tmp = t_1;
} else if (y <= 2.3e-156) {
tmp = x / (y / pow(a, (t + -1.0)));
} else if (y <= 3.7e+129) {
tmp = (x / (y * exp(b))) / 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 / a) * ((z ** y) / y)
if (y <= (-1.25d+26)) then
tmp = t_1
else if (y <= 2.3d-156) then
tmp = x / (y / (a ** (t + (-1.0d0))))
else if (y <= 3.7d+129) then
tmp = (x / (y * exp(b))) / 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 / a) * (Math.pow(z, y) / y);
double tmp;
if (y <= -1.25e+26) {
tmp = t_1;
} else if (y <= 2.3e-156) {
tmp = x / (y / Math.pow(a, (t + -1.0)));
} else if (y <= 3.7e+129) {
tmp = (x / (y * Math.exp(b))) / a;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (x / a) * (math.pow(z, y) / y) tmp = 0 if y <= -1.25e+26: tmp = t_1 elif y <= 2.3e-156: tmp = x / (y / math.pow(a, (t + -1.0))) elif y <= 3.7e+129: tmp = (x / (y * math.exp(b))) / a else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(x / a) * Float64((z ^ y) / y)) tmp = 0.0 if (y <= -1.25e+26) tmp = t_1; elseif (y <= 2.3e-156) tmp = Float64(x / Float64(y / (a ^ Float64(t + -1.0)))); elseif (y <= 3.7e+129) tmp = Float64(Float64(x / Float64(y * exp(b))) / a); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (x / a) * ((z ^ y) / y); tmp = 0.0; if (y <= -1.25e+26) tmp = t_1; elseif (y <= 2.3e-156) tmp = x / (y / (a ^ (t + -1.0))); elseif (y <= 3.7e+129) tmp = (x / (y * exp(b))) / a; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x / a), $MachinePrecision] * N[(N[Power[z, y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.25e+26], t$95$1, If[LessEqual[y, 2.3e-156], N[(x / N[(y / N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.7e+129], N[(N[(x / N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{a} \cdot \frac{{z}^{y}}{y}\\
\mathbf{if}\;y \leq -1.25 \cdot 10^{+26}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq 2.3 \cdot 10^{-156}:\\
\;\;\;\;\frac{x}{\frac{y}{{a}^{\left(t + -1\right)}}}\\
\mathbf{elif}\;y \leq 3.7 \cdot 10^{+129}:\\
\;\;\;\;\frac{\frac{x}{y \cdot e^{b}}}{a}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if y < -1.25e26 or 3.69999999999999978e129 < y Initial program 100.0%
associate-*l/81.7%
*-commutative81.7%
associate--l+81.7%
exp-sum55.9%
exp-diff51.6%
*-commutative51.6%
exp-to-pow51.6%
*-commutative51.6%
exp-to-pow51.6%
sub-neg51.6%
metadata-eval51.6%
Simplified51.6%
Taylor expanded in t around 0 65.7%
times-frac72.1%
Simplified72.1%
Taylor expanded in b around 0 73.2%
times-frac84.0%
*-commutative84.0%
Simplified84.0%
if -1.25e26 < y < 2.3e-156Initial program 95.4%
Taylor expanded in y around 0 95.4%
Taylor expanded in b around 0 78.1%
associate-/l*81.4%
sub-neg81.4%
metadata-eval81.4%
exp-to-pow82.5%
+-commutative82.5%
Simplified82.5%
if 2.3e-156 < y < 3.69999999999999978e129Initial program 98.5%
associate-*l/98.5%
*-commutative98.5%
associate--l+98.5%
exp-sum80.9%
exp-diff65.2%
*-commutative65.2%
exp-to-pow65.2%
*-commutative65.2%
exp-to-pow66.5%
sub-neg66.5%
metadata-eval66.5%
Simplified66.5%
Taylor expanded in t around 0 67.1%
times-frac65.2%
Simplified65.2%
associate-*l/68.7%
clear-num68.7%
un-div-inv68.8%
Applied egg-rr68.8%
Taylor expanded in y around 0 74.4%
Final simplification81.3%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (/ (* x (pow z y)) y) a)))
(if (<= y -3.6e-8)
t_1
(if (<= y 3.7e-156)
(/ x (/ y (pow a (+ t -1.0))))
(if (<= y 3.4e+33) (/ (/ x (* y (exp b))) a) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = ((x * pow(z, y)) / y) / a;
double tmp;
if (y <= -3.6e-8) {
tmp = t_1;
} else if (y <= 3.7e-156) {
tmp = x / (y / pow(a, (t + -1.0)));
} else if (y <= 3.4e+33) {
tmp = (x / (y * exp(b))) / 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 * (z ** y)) / y) / a
if (y <= (-3.6d-8)) then
tmp = t_1
else if (y <= 3.7d-156) then
tmp = x / (y / (a ** (t + (-1.0d0))))
else if (y <= 3.4d+33) then
tmp = (x / (y * exp(b))) / 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 * Math.pow(z, y)) / y) / a;
double tmp;
if (y <= -3.6e-8) {
tmp = t_1;
} else if (y <= 3.7e-156) {
tmp = x / (y / Math.pow(a, (t + -1.0)));
} else if (y <= 3.4e+33) {
tmp = (x / (y * Math.exp(b))) / a;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = ((x * math.pow(z, y)) / y) / a tmp = 0 if y <= -3.6e-8: tmp = t_1 elif y <= 3.7e-156: tmp = x / (y / math.pow(a, (t + -1.0))) elif y <= 3.4e+33: tmp = (x / (y * math.exp(b))) / a else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(Float64(x * (z ^ y)) / y) / a) tmp = 0.0 if (y <= -3.6e-8) tmp = t_1; elseif (y <= 3.7e-156) tmp = Float64(x / Float64(y / (a ^ Float64(t + -1.0)))); elseif (y <= 3.4e+33) tmp = Float64(Float64(x / Float64(y * exp(b))) / a); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = ((x * (z ^ y)) / y) / a; tmp = 0.0; if (y <= -3.6e-8) tmp = t_1; elseif (y <= 3.7e-156) tmp = x / (y / (a ^ (t + -1.0))); elseif (y <= 3.4e+33) tmp = (x / (y * exp(b))) / a; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[(x * N[Power[z, y], $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision] / a), $MachinePrecision]}, If[LessEqual[y, -3.6e-8], t$95$1, If[LessEqual[y, 3.7e-156], N[(x / N[(y / N[Power[a, N[(t + -1.0), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 3.4e+33], N[(N[(x / N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\frac{x \cdot {z}^{y}}{y}}{a}\\
\mathbf{if}\;y \leq -3.6 \cdot 10^{-8}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;y \leq 3.7 \cdot 10^{-156}:\\
\;\;\;\;\frac{x}{\frac{y}{{a}^{\left(t + -1\right)}}}\\
\mathbf{elif}\;y \leq 3.4 \cdot 10^{+33}:\\
\;\;\;\;\frac{\frac{x}{y \cdot e^{b}}}{a}\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
if y < -3.59999999999999981e-8 or 3.3999999999999999e33 < y Initial program 100.0%
associate-*l/85.0%
*-commutative85.0%
associate--l+85.0%
exp-sum57.5%
exp-diff52.2%
*-commutative52.2%
exp-to-pow52.2%
*-commutative52.2%
exp-to-pow52.2%
sub-neg52.2%
metadata-eval52.2%
Simplified52.2%
Taylor expanded in t around 0 66.5%
times-frac70.0%
Simplified70.0%
associate-*l/76.2%
clear-num76.2%
un-div-inv76.2%
Applied egg-rr76.2%
Taylor expanded in b around 0 87.8%
if -3.59999999999999981e-8 < y < 3.7e-156Initial program 95.3%
Taylor expanded in y around 0 95.3%
Taylor expanded in b around 0 79.4%
associate-/l*82.8%
sub-neg82.8%
metadata-eval82.8%
exp-to-pow83.9%
+-commutative83.9%
Simplified83.9%
if 3.7e-156 < y < 3.3999999999999999e33Initial program 97.8%
associate-*l/97.8%
*-commutative97.8%
associate--l+97.8%
exp-sum90.3%
exp-diff72.8%
*-commutative72.8%
exp-to-pow72.8%
*-commutative72.8%
exp-to-pow74.8%
sub-neg74.8%
metadata-eval74.8%
Simplified74.8%
Taylor expanded in t around 0 68.1%
times-frac67.9%
Simplified67.9%
associate-*l/70.4%
clear-num70.4%
un-div-inv70.5%
Applied egg-rr70.5%
Taylor expanded in y around 0 78.0%
Final simplification84.7%
(FPCore (x y z t a b) :precision binary64 (if (or (<= b -2.65e-28) (not (<= b 1.85e+15))) (/ x (* a (* y (exp b)))) (* (pow z y) (/ (/ x y) a))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -2.65e-28) || !(b <= 1.85e+15)) {
tmp = x / (a * (y * exp(b)));
} else {
tmp = pow(z, y) * ((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 <= (-2.65d-28)) .or. (.not. (b <= 1.85d+15))) then
tmp = x / (a * (y * exp(b)))
else
tmp = (z ** y) * ((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 <= -2.65e-28) || !(b <= 1.85e+15)) {
tmp = x / (a * (y * Math.exp(b)));
} else {
tmp = Math.pow(z, y) * ((x / y) / a);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (b <= -2.65e-28) or not (b <= 1.85e+15): tmp = x / (a * (y * math.exp(b))) else: tmp = math.pow(z, y) * ((x / y) / a) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -2.65e-28) || !(b <= 1.85e+15)) tmp = Float64(x / Float64(a * Float64(y * exp(b)))); else tmp = Float64((z ^ y) * Float64(Float64(x / y) / a)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((b <= -2.65e-28) || ~((b <= 1.85e+15))) tmp = x / (a * (y * exp(b))); else tmp = (z ^ y) * ((x / y) / a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -2.65e-28], N[Not[LessEqual[b, 1.85e+15]], $MachinePrecision]], N[(x / N[(a * N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Power[z, y], $MachinePrecision] * N[(N[(x / y), $MachinePrecision] / a), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -2.65 \cdot 10^{-28} \lor \neg \left(b \leq 1.85 \cdot 10^{+15}\right):\\
\;\;\;\;\frac{x}{a \cdot \left(y \cdot e^{b}\right)}\\
\mathbf{else}:\\
\;\;\;\;{z}^{y} \cdot \frac{\frac{x}{y}}{a}\\
\end{array}
\end{array}
if b < -2.64999999999999994e-28 or 1.85e15 < b Initial program 100.0%
associate-*l/92.0%
*-commutative92.0%
associate--l+92.0%
exp-sum73.6%
exp-diff55.2%
*-commutative55.2%
exp-to-pow55.2%
*-commutative55.2%
exp-to-pow55.2%
sub-neg55.2%
metadata-eval55.2%
Simplified55.2%
Taylor expanded in t around 0 69.8%
times-frac64.1%
Simplified64.1%
Taylor expanded in y around 0 78.0%
if -2.64999999999999994e-28 < b < 1.85e15Initial program 95.6%
associate-*l/85.5%
*-commutative85.5%
associate--l+85.5%
exp-sum77.1%
exp-diff77.1%
*-commutative77.1%
exp-to-pow77.1%
*-commutative77.1%
exp-to-pow78.5%
sub-neg78.5%
metadata-eval78.5%
Simplified78.5%
Taylor expanded in t around 0 65.2%
times-frac69.4%
Simplified69.4%
Taylor expanded in b around 0 66.7%
associate-/l*66.7%
associate-/r/65.2%
*-commutative65.2%
associate-/r*67.5%
Simplified67.5%
Final simplification72.6%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -1.35e+29) (not (<= y 1.8e+134))) (* (/ x a) (/ (pow z y) y)) (/ (/ x (* y (exp b))) a)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -1.35e+29) || !(y <= 1.8e+134)) {
tmp = (x / a) * (pow(z, y) / y);
} else {
tmp = (x / (y * exp(b))) / 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 ((y <= (-1.35d+29)) .or. (.not. (y <= 1.8d+134))) then
tmp = (x / a) * ((z ** y) / y)
else
tmp = (x / (y * exp(b))) / 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 ((y <= -1.35e+29) || !(y <= 1.8e+134)) {
tmp = (x / a) * (Math.pow(z, y) / y);
} else {
tmp = (x / (y * Math.exp(b))) / a;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -1.35e+29) or not (y <= 1.8e+134): tmp = (x / a) * (math.pow(z, y) / y) else: tmp = (x / (y * math.exp(b))) / a return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -1.35e+29) || !(y <= 1.8e+134)) tmp = Float64(Float64(x / a) * Float64((z ^ y) / y)); else tmp = Float64(Float64(x / Float64(y * exp(b))) / a); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -1.35e+29) || ~((y <= 1.8e+134))) tmp = (x / a) * ((z ^ y) / y); else tmp = (x / (y * exp(b))) / a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -1.35e+29], N[Not[LessEqual[y, 1.8e+134]], $MachinePrecision]], N[(N[(x / a), $MachinePrecision] * N[(N[Power[z, y], $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(N[(x / N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.35 \cdot 10^{+29} \lor \neg \left(y \leq 1.8 \cdot 10^{+134}\right):\\
\;\;\;\;\frac{x}{a} \cdot \frac{{z}^{y}}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{y \cdot e^{b}}}{a}\\
\end{array}
\end{array}
if y < -1.35e29 or 1.79999999999999994e134 < y Initial program 100.0%
associate-*l/81.5%
*-commutative81.5%
associate--l+81.5%
exp-sum55.4%
exp-diff52.2%
*-commutative52.2%
exp-to-pow52.2%
*-commutative52.2%
exp-to-pow52.2%
sub-neg52.2%
metadata-eval52.2%
Simplified52.2%
Taylor expanded in t around 0 65.3%
times-frac71.8%
Simplified71.8%
Taylor expanded in b around 0 72.9%
times-frac83.8%
*-commutative83.8%
Simplified83.8%
if -1.35e29 < y < 1.79999999999999994e134Initial program 96.5%
associate-*l/92.7%
*-commutative92.7%
associate--l+92.7%
exp-sum86.6%
exp-diff74.4%
*-commutative74.4%
exp-to-pow74.4%
*-commutative74.4%
exp-to-pow75.5%
sub-neg75.5%
metadata-eval75.5%
Simplified75.5%
Taylor expanded in t around 0 68.6%
times-frac64.0%
Simplified64.0%
associate-*l/69.8%
clear-num69.8%
un-div-inv69.8%
Applied egg-rr69.8%
Taylor expanded in y around 0 71.2%
Final simplification75.7%
(FPCore (x y z t a b) :precision binary64 (/ x (* a (* y (exp b)))))
double code(double x, double y, double z, double t, double a, double b) {
return x / (a * (y * exp(b)));
}
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 / (a * (y * exp(b)))
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x / (a * (y * Math.exp(b)));
}
def code(x, y, z, t, a, b): return x / (a * (y * math.exp(b)))
function code(x, y, z, t, a, b) return Float64(x / Float64(a * Float64(y * exp(b)))) end
function tmp = code(x, y, z, t, a, b) tmp = x / (a * (y * exp(b))); end
code[x_, y_, z_, t_, a_, b_] := N[(x / N[(a * N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{a \cdot \left(y \cdot e^{b}\right)}
\end{array}
Initial program 97.8%
associate-*l/88.7%
*-commutative88.7%
associate--l+88.7%
exp-sum75.4%
exp-diff66.4%
*-commutative66.4%
exp-to-pow66.4%
*-commutative66.4%
exp-to-pow67.1%
sub-neg67.1%
metadata-eval67.1%
Simplified67.1%
Taylor expanded in t around 0 67.4%
times-frac66.8%
Simplified66.8%
Taylor expanded in y around 0 59.8%
Final simplification59.8%
(FPCore (x y z t a b) :precision binary64 (/ (/ x (* y (exp b))) a))
double code(double x, double y, double z, double t, double a, double b) {
return (x / (y * exp(b))) / 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 * exp(b))) / a
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return (x / (y * Math.exp(b))) / a;
}
def code(x, y, z, t, a, b): return (x / (y * math.exp(b))) / a
function code(x, y, z, t, a, b) return Float64(Float64(x / Float64(y * exp(b))) / a) end
function tmp = code(x, y, z, t, a, b) tmp = (x / (y * exp(b))) / a; end
code[x_, y_, z_, t_, a_, b_] := N[(N[(x / N[(y * N[Exp[b], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]
\begin{array}{l}
\\
\frac{\frac{x}{y \cdot e^{b}}}{a}
\end{array}
Initial program 97.8%
associate-*l/88.7%
*-commutative88.7%
associate--l+88.7%
exp-sum75.4%
exp-diff66.4%
*-commutative66.4%
exp-to-pow66.4%
*-commutative66.4%
exp-to-pow67.1%
sub-neg67.1%
metadata-eval67.1%
Simplified67.1%
Taylor expanded in t around 0 67.4%
times-frac66.8%
Simplified66.8%
associate-*l/72.5%
clear-num72.5%
un-div-inv72.5%
Applied egg-rr72.5%
Taylor expanded in y around 0 61.7%
Final simplification61.7%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (+ y (* y b))))
(if (<= y -2.8e-55)
(/ x (* a t_1))
(if (<= y 1.6e-74) (/ (/ x y) a) (/ (/ x t_1) a)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = y + (y * b);
double tmp;
if (y <= -2.8e-55) {
tmp = x / (a * t_1);
} else if (y <= 1.6e-74) {
tmp = (x / y) / a;
} else {
tmp = (x / t_1) / 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) :: t_1
real(8) :: tmp
t_1 = y + (y * b)
if (y <= (-2.8d-55)) then
tmp = x / (a * t_1)
else if (y <= 1.6d-74) then
tmp = (x / y) / a
else
tmp = (x / t_1) / a
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 = y + (y * b);
double tmp;
if (y <= -2.8e-55) {
tmp = x / (a * t_1);
} else if (y <= 1.6e-74) {
tmp = (x / y) / a;
} else {
tmp = (x / t_1) / a;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = y + (y * b) tmp = 0 if y <= -2.8e-55: tmp = x / (a * t_1) elif y <= 1.6e-74: tmp = (x / y) / a else: tmp = (x / t_1) / a return tmp
function code(x, y, z, t, a, b) t_1 = Float64(y + Float64(y * b)) tmp = 0.0 if (y <= -2.8e-55) tmp = Float64(x / Float64(a * t_1)); elseif (y <= 1.6e-74) tmp = Float64(Float64(x / y) / a); else tmp = Float64(Float64(x / t_1) / a); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = y + (y * b); tmp = 0.0; if (y <= -2.8e-55) tmp = x / (a * t_1); elseif (y <= 1.6e-74) tmp = (x / y) / a; else tmp = (x / t_1) / a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(y + N[(y * b), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -2.8e-55], N[(x / N[(a * t$95$1), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.6e-74], N[(N[(x / y), $MachinePrecision] / a), $MachinePrecision], N[(N[(x / t$95$1), $MachinePrecision] / a), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := y + y \cdot b\\
\mathbf{if}\;y \leq -2.8 \cdot 10^{-55}:\\
\;\;\;\;\frac{x}{a \cdot t_1}\\
\mathbf{elif}\;y \leq 1.6 \cdot 10^{-74}:\\
\;\;\;\;\frac{\frac{x}{y}}{a}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{t_1}}{a}\\
\end{array}
\end{array}
if y < -2.79999999999999984e-55Initial program 99.9%
associate-*l/86.2%
*-commutative86.2%
associate--l+86.2%
exp-sum67.0%
exp-diff60.2%
*-commutative60.2%
exp-to-pow60.2%
*-commutative60.2%
exp-to-pow60.3%
sub-neg60.3%
metadata-eval60.3%
Simplified60.3%
Taylor expanded in t around 0 67.3%
times-frac71.4%
Simplified71.4%
Taylor expanded in y around 0 49.1%
Taylor expanded in b around 0 38.4%
if -2.79999999999999984e-55 < y < 1.5999999999999999e-74Initial program 95.4%
associate-*l/89.9%
*-commutative89.9%
associate--l+89.9%
exp-sum89.9%
exp-diff79.2%
*-commutative79.2%
exp-to-pow79.2%
*-commutative79.2%
exp-to-pow80.5%
sub-neg80.5%
metadata-eval80.5%
Simplified80.5%
Taylor expanded in t around 0 69.4%
times-frac66.3%
Simplified66.3%
associate-*l/71.0%
clear-num71.0%
un-div-inv71.1%
Applied egg-rr71.1%
Taylor expanded in y around 0 71.1%
Taylor expanded in b around 0 44.8%
if 1.5999999999999999e-74 < y Initial program 99.3%
associate-*l/89.3%
*-commutative89.3%
associate--l+89.3%
exp-sum60.7%
exp-diff52.2%
*-commutative52.2%
exp-to-pow52.2%
*-commutative52.2%
exp-to-pow52.8%
sub-neg52.8%
metadata-eval52.8%
Simplified52.8%
Taylor expanded in t around 0 64.5%
times-frac63.0%
Simplified63.0%
associate-*l/70.1%
clear-num70.1%
un-div-inv70.2%
Applied egg-rr70.2%
Taylor expanded in y around 0 61.0%
Taylor expanded in b around 0 48.7%
Final simplification44.0%
(FPCore (x y z t a b) :precision binary64 (if (<= b -9e-7) (/ (- (/ x y) (/ (* x b) y)) a) (/ (/ x (+ y (* y b))) a)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -9e-7) {
tmp = ((x / y) - ((x * b) / y)) / a;
} else {
tmp = (x / (y + (y * b))) / 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 <= (-9d-7)) then
tmp = ((x / y) - ((x * b) / y)) / a
else
tmp = (x / (y + (y * b))) / 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 <= -9e-7) {
tmp = ((x / y) - ((x * b) / y)) / a;
} else {
tmp = (x / (y + (y * b))) / a;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -9e-7: tmp = ((x / y) - ((x * b) / y)) / a else: tmp = (x / (y + (y * b))) / a return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -9e-7) tmp = Float64(Float64(Float64(x / y) - Float64(Float64(x * b) / y)) / a); else tmp = Float64(Float64(x / Float64(y + Float64(y * b))) / a); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -9e-7) tmp = ((x / y) - ((x * b) / y)) / a; else tmp = (x / (y + (y * b))) / a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -9e-7], N[(N[(N[(x / y), $MachinePrecision] - N[(N[(x * b), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision], N[(N[(x / N[(y + N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -9 \cdot 10^{-7}:\\
\;\;\;\;\frac{\frac{x}{y} - \frac{x \cdot b}{y}}{a}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{y + y \cdot b}}{a}\\
\end{array}
\end{array}
if b < -8.99999999999999959e-7Initial program 100.0%
associate-*l/91.3%
*-commutative91.3%
associate--l+91.3%
exp-sum69.6%
exp-diff55.1%
*-commutative55.1%
exp-to-pow55.1%
*-commutative55.1%
exp-to-pow55.1%
sub-neg55.1%
metadata-eval55.1%
Simplified55.1%
Taylor expanded in t around 0 68.3%
times-frac61.0%
Simplified61.0%
associate-*l/68.3%
clear-num68.3%
un-div-inv68.3%
Applied egg-rr68.3%
Taylor expanded in y around 0 77.2%
Taylor expanded in b around 0 48.2%
if -8.99999999999999959e-7 < b Initial program 96.9%
associate-*l/87.7%
*-commutative87.7%
associate--l+87.7%
exp-sum77.5%
exp-diff70.6%
*-commutative70.6%
exp-to-pow70.6%
*-commutative70.6%
exp-to-pow71.6%
sub-neg71.6%
metadata-eval71.6%
Simplified71.6%
Taylor expanded in t around 0 67.1%
times-frac69.0%
Simplified69.0%
associate-*l/74.0%
clear-num74.0%
un-div-inv74.1%
Applied egg-rr74.1%
Taylor expanded in y around 0 56.0%
Taylor expanded in b around 0 44.2%
Final simplification45.3%
(FPCore (x y z t a b) :precision binary64 (if (<= x 1.6e-178) (/ (/ x y) a) (* x (/ 1.0 (* y a)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (x <= 1.6e-178) {
tmp = (x / y) / a;
} else {
tmp = x * (1.0 / (y * a));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (x <= 1.6d-178) then
tmp = (x / y) / a
else
tmp = x * (1.0d0 / (y * a))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (x <= 1.6e-178) {
tmp = (x / y) / a;
} else {
tmp = x * (1.0 / (y * a));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if x <= 1.6e-178: tmp = (x / y) / a else: tmp = x * (1.0 / (y * a)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (x <= 1.6e-178) tmp = Float64(Float64(x / y) / a); else tmp = Float64(x * Float64(1.0 / Float64(y * a))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (x <= 1.6e-178) tmp = (x / y) / a; else tmp = x * (1.0 / (y * a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[x, 1.6e-178], N[(N[(x / y), $MachinePrecision] / a), $MachinePrecision], N[(x * N[(1.0 / N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 1.6 \cdot 10^{-178}:\\
\;\;\;\;\frac{\frac{x}{y}}{a}\\
\mathbf{else}:\\
\;\;\;\;x \cdot \frac{1}{y \cdot a}\\
\end{array}
\end{array}
if x < 1.6e-178Initial program 97.1%
associate-*l/86.9%
*-commutative86.9%
associate--l+86.9%
exp-sum73.4%
exp-diff64.1%
*-commutative64.1%
exp-to-pow64.1%
*-commutative64.1%
exp-to-pow64.8%
sub-neg64.8%
metadata-eval64.8%
Simplified64.8%
Taylor expanded in t around 0 65.7%
times-frac62.5%
Simplified62.5%
associate-*l/70.9%
clear-num70.9%
un-div-inv70.9%
Applied egg-rr70.9%
Taylor expanded in y around 0 62.6%
Taylor expanded in b around 0 41.0%
if 1.6e-178 < x Initial program 99.1%
associate-*l/92.3%
*-commutative92.3%
associate--l+92.3%
exp-sum79.3%
exp-diff71.1%
*-commutative71.1%
exp-to-pow71.1%
*-commutative71.1%
exp-to-pow71.8%
sub-neg71.8%
metadata-eval71.8%
Simplified71.8%
Taylor expanded in t around 0 70.9%
times-frac75.5%
Simplified75.5%
Taylor expanded in y around 0 62.0%
Taylor expanded in b around 0 37.1%
*-commutative37.1%
Simplified37.1%
div-inv38.2%
*-commutative38.2%
*-commutative38.2%
Applied egg-rr38.2%
Final simplification40.1%
(FPCore (x y z t a b) :precision binary64 (if (<= b 255000000.0) (/ (/ x y) a) (/ x (* a (* y b)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= 255000000.0) {
tmp = (x / y) / a;
} else {
tmp = x / (a * (y * b));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (b <= 255000000.0d0) then
tmp = (x / y) / a
else
tmp = x / (a * (y * b))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= 255000000.0) {
tmp = (x / y) / a;
} else {
tmp = x / (a * (y * b));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= 255000000.0: tmp = (x / y) / a else: tmp = x / (a * (y * b)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= 255000000.0) tmp = Float64(Float64(x / y) / a); else tmp = Float64(x / Float64(a * Float64(y * b))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= 255000000.0) tmp = (x / y) / a; else tmp = x / (a * (y * b)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, 255000000.0], N[(N[(x / y), $MachinePrecision] / a), $MachinePrecision], N[(x / N[(a * N[(y * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq 255000000:\\
\;\;\;\;\frac{\frac{x}{y}}{a}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a \cdot \left(y \cdot b\right)}\\
\end{array}
\end{array}
if b < 2.55e8Initial program 97.2%
associate-*l/87.6%
*-commutative87.6%
associate--l+87.6%
exp-sum74.7%
exp-diff69.8%
*-commutative69.8%
exp-to-pow69.8%
*-commutative69.8%
exp-to-pow70.7%
sub-neg70.7%
metadata-eval70.7%
Simplified70.7%
Taylor expanded in t around 0 66.1%
times-frac66.9%
Simplified66.9%
associate-*l/72.5%
clear-num72.5%
un-div-inv72.5%
Applied egg-rr72.5%
Taylor expanded in y around 0 56.8%
Taylor expanded in b around 0 41.3%
if 2.55e8 < b Initial program 100.0%
associate-*l/92.6%
*-commutative92.6%
associate--l+92.6%
exp-sum77.8%
exp-diff53.7%
*-commutative53.7%
exp-to-pow53.7%
*-commutative53.7%
exp-to-pow53.7%
sub-neg53.7%
metadata-eval53.7%
Simplified53.7%
Taylor expanded in t around 0 72.4%
times-frac66.8%
Simplified66.8%
Taylor expanded in y around 0 79.9%
Taylor expanded in b around 0 39.1%
Taylor expanded in b around inf 39.1%
*-commutative39.1%
Simplified39.1%
Final simplification40.9%
(FPCore (x y z t a b) :precision binary64 (if (<= x 1e-111) (/ (/ x y) a) (/ x (* y a))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (x <= 1e-111) {
tmp = (x / y) / a;
} 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 (x <= 1d-111) then
tmp = (x / y) / a
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 (x <= 1e-111) {
tmp = (x / y) / a;
} else {
tmp = x / (y * a);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if x <= 1e-111: tmp = (x / y) / a else: tmp = x / (y * a) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (x <= 1e-111) tmp = Float64(Float64(x / y) / a); 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 (x <= 1e-111) tmp = (x / y) / a; else tmp = x / (y * a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[x, 1e-111], N[(N[(x / y), $MachinePrecision] / a), $MachinePrecision], N[(x / N[(y * a), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 10^{-111}:\\
\;\;\;\;\frac{\frac{x}{y}}{a}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{y \cdot a}\\
\end{array}
\end{array}
if x < 1.00000000000000009e-111Initial program 97.2%
associate-*l/87.1%
*-commutative87.1%
associate--l+87.1%
exp-sum74.4%
exp-diff65.6%
*-commutative65.6%
exp-to-pow65.6%
*-commutative65.6%
exp-to-pow66.4%
sub-neg66.4%
metadata-eval66.4%
Simplified66.4%
Taylor expanded in t around 0 67.3%
times-frac64.2%
Simplified64.2%
associate-*l/72.1%
clear-num72.1%
un-div-inv72.2%
Applied egg-rr72.2%
Taylor expanded in y around 0 64.4%
Taylor expanded in b around 0 40.9%
if 1.00000000000000009e-111 < x Initial program 99.1%
associate-*l/92.6%
*-commutative92.6%
associate--l+92.6%
exp-sum77.7%
exp-diff68.3%
*-commutative68.3%
exp-to-pow68.3%
*-commutative68.3%
exp-to-pow68.9%
sub-neg68.9%
metadata-eval68.9%
Simplified68.9%
Taylor expanded in t around 0 67.9%
times-frac73.2%
Simplified73.2%
Taylor expanded in y around 0 57.7%
Taylor expanded in b around 0 36.9%
*-commutative36.9%
Simplified36.9%
Final simplification39.8%
(FPCore (x y z t a b) :precision binary64 (/ x (* y a)))
double code(double x, double y, double z, double t, double a, double b) {
return x / (y * a);
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = x / (y * a)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x / (y * a);
}
def code(x, y, z, t, a, b): return x / (y * a)
function code(x, y, z, t, a, b) return Float64(x / Float64(y * a)) end
function tmp = code(x, y, z, t, a, b) tmp = x / (y * a); end
code[x_, y_, z_, t_, a_, b_] := N[(x / N[(y * a), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{y \cdot a}
\end{array}
Initial program 97.8%
associate-*l/88.7%
*-commutative88.7%
associate--l+88.7%
exp-sum75.4%
exp-diff66.4%
*-commutative66.4%
exp-to-pow66.4%
*-commutative66.4%
exp-to-pow67.1%
sub-neg67.1%
metadata-eval67.1%
Simplified67.1%
Taylor expanded in t around 0 67.4%
times-frac66.8%
Simplified66.8%
Taylor expanded in y around 0 59.8%
Taylor expanded in b around 0 36.3%
*-commutative36.3%
Simplified36.3%
Final simplification36.3%
(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 2023301
(FPCore (x y z t a b)
:name "Numeric.SpecFunctions:incompleteBetaWorker from math-functions-0.1.5.2, A"
:precision binary64
:herbie-target
(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))