
(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 17 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 (/ (* (exp (- (+ (* (log a) (- t 1.0)) (* (log z) y)) b)) x) y))
double code(double x, double y, double z, double t, double a, double b) {
return (exp((((log(a) * (t - 1.0)) + (log(z) * y)) - b)) * 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 = (exp((((log(a) * (t - 1.0d0)) + (log(z) * y)) - b)) * x) / y
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return (Math.exp((((Math.log(a) * (t - 1.0)) + (Math.log(z) * y)) - b)) * x) / y;
}
def code(x, y, z, t, a, b): return (math.exp((((math.log(a) * (t - 1.0)) + (math.log(z) * y)) - b)) * x) / y
function code(x, y, z, t, a, b) return Float64(Float64(exp(Float64(Float64(Float64(log(a) * Float64(t - 1.0)) + Float64(log(z) * y)) - b)) * x) / y) end
function tmp = code(x, y, z, t, a, b) tmp = (exp((((log(a) * (t - 1.0)) + (log(z) * y)) - b)) * x) / y; end
code[x_, y_, z_, t_, a_, b_] := N[(N[(N[Exp[N[(N[(N[(N[Log[a], $MachinePrecision] * N[(t - 1.0), $MachinePrecision]), $MachinePrecision] + N[(N[Log[z], $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision]
\begin{array}{l}
\\
\frac{e^{\left(\log a \cdot \left(t - 1\right) + \log z \cdot y\right) - b} \cdot x}{y}
\end{array}
Initial program 98.1%
Final simplification98.1%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (log a) (- t 1.0))) (t_2 (* (/ (pow a (- t 1.0)) y) x)))
(if (<= t_1 -2e+41)
t_2
(if (<= t_1 -570.0)
(/ (/ (* (pow z y) x) y) a)
(if (<= t_1 4e+53) (/ (* (/ (exp (- b)) a) x) y) t_2)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = log(a) * (t - 1.0);
double t_2 = (pow(a, (t - 1.0)) / y) * x;
double tmp;
if (t_1 <= -2e+41) {
tmp = t_2;
} else if (t_1 <= -570.0) {
tmp = ((pow(z, y) * x) / y) / a;
} else if (t_1 <= 4e+53) {
tmp = ((exp(-b) / a) * x) / 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 = log(a) * (t - 1.0d0)
t_2 = ((a ** (t - 1.0d0)) / y) * x
if (t_1 <= (-2d+41)) then
tmp = t_2
else if (t_1 <= (-570.0d0)) then
tmp = (((z ** y) * x) / y) / a
else if (t_1 <= 4d+53) then
tmp = ((exp(-b) / a) * x) / 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.log(a) * (t - 1.0);
double t_2 = (Math.pow(a, (t - 1.0)) / y) * x;
double tmp;
if (t_1 <= -2e+41) {
tmp = t_2;
} else if (t_1 <= -570.0) {
tmp = ((Math.pow(z, y) * x) / y) / a;
} else if (t_1 <= 4e+53) {
tmp = ((Math.exp(-b) / a) * x) / y;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = math.log(a) * (t - 1.0) t_2 = (math.pow(a, (t - 1.0)) / y) * x tmp = 0 if t_1 <= -2e+41: tmp = t_2 elif t_1 <= -570.0: tmp = ((math.pow(z, y) * x) / y) / a elif t_1 <= 4e+53: tmp = ((math.exp(-b) / a) * x) / y else: tmp = t_2 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(log(a) * Float64(t - 1.0)) t_2 = Float64(Float64((a ^ Float64(t - 1.0)) / y) * x) tmp = 0.0 if (t_1 <= -2e+41) tmp = t_2; elseif (t_1 <= -570.0) tmp = Float64(Float64(Float64((z ^ y) * x) / y) / a); elseif (t_1 <= 4e+53) tmp = Float64(Float64(Float64(exp(Float64(-b)) / a) * x) / y); else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = log(a) * (t - 1.0); t_2 = ((a ^ (t - 1.0)) / y) * x; tmp = 0.0; if (t_1 <= -2e+41) tmp = t_2; elseif (t_1 <= -570.0) tmp = (((z ^ y) * x) / y) / a; elseif (t_1 <= 4e+53) tmp = ((exp(-b) / a) * x) / y; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[Log[a], $MachinePrecision] * N[(t - 1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision] / y), $MachinePrecision] * x), $MachinePrecision]}, If[LessEqual[t$95$1, -2e+41], t$95$2, If[LessEqual[t$95$1, -570.0], N[(N[(N[(N[Power[z, y], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[t$95$1, 4e+53], N[(N[(N[(N[Exp[(-b)], $MachinePrecision] / a), $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision], t$95$2]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \log a \cdot \left(t - 1\right)\\
t_2 := \frac{{a}^{\left(t - 1\right)}}{y} \cdot x\\
\mathbf{if}\;t\_1 \leq -2 \cdot 10^{+41}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t\_1 \leq -570:\\
\;\;\;\;\frac{\frac{{z}^{y} \cdot x}{y}}{a}\\
\mathbf{elif}\;t\_1 \leq 4 \cdot 10^{+53}:\\
\;\;\;\;\frac{\frac{e^{-b}}{a} \cdot x}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a)) < -2.00000000000000001e41 or 4e53 < (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a)) Initial program 100.0%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6472.9
Applied rewrites72.9%
Taylor expanded in y around 0
Applied rewrites83.8%
if -2.00000000000000001e41 < (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a)) < -570Initial program 90.3%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6452.1
Applied rewrites52.1%
Taylor expanded in t around 0
Applied rewrites59.7%
Applied rewrites77.0%
if -570 < (*.f64 (-.f64 t #s(literal 1 binary64)) (log.f64 a)) < 4e53Initial program 98.4%
Taylor expanded in t around 0
exp-diffN/A
lower-/.f64N/A
+-commutativeN/A
mul-1-negN/A
unsub-negN/A
exp-diffN/A
lower-/.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
rem-exp-logN/A
lower-exp.f6485.4
Applied rewrites85.4%
Taylor expanded in y around 0
Applied rewrites78.0%
Final simplification80.2%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (* (exp (- (fma (log z) y (- (log a))) b)) x) y)))
(if (<= y -1950000000.0)
t_1
(if (<= y 2e+52) (/ (* (exp (- (* (log a) (- t 1.0)) b)) x) y) t_1))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (exp((fma(log(z), y, -log(a)) - b)) * x) / y;
double tmp;
if (y <= -1950000000.0) {
tmp = t_1;
} else if (y <= 2e+52) {
tmp = (exp(((log(a) * (t - 1.0)) - b)) * x) / y;
} else {
tmp = t_1;
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = Float64(Float64(exp(Float64(fma(log(z), y, Float64(-log(a))) - b)) * x) / y) tmp = 0.0 if (y <= -1950000000.0) tmp = t_1; elseif (y <= 2e+52) tmp = Float64(Float64(exp(Float64(Float64(log(a) * Float64(t - 1.0)) - b)) * x) / y); else tmp = t_1; end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[Exp[N[(N[(N[Log[z], $MachinePrecision] * y + (-N[Log[a], $MachinePrecision])), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision]}, If[LessEqual[y, -1950000000.0], t$95$1, If[LessEqual[y, 2e+52], N[(N[(N[Exp[N[(N[(N[Log[a], $MachinePrecision] * N[(t - 1.0), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{e^{\mathsf{fma}\left(\log z, y, -\log a\right) - b} \cdot x}{y}\\
\mathbf{if}\;y \leq -1950000000:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;y \leq 2 \cdot 10^{+52}:\\
\;\;\;\;\frac{e^{\log a \cdot \left(t - 1\right) - b} \cdot x}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if y < -1.95e9 or 2e52 < y Initial program 100.0%
Taylor expanded in t around 0
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower-log.f64N/A
mul-1-negN/A
lower-neg.f64N/A
rem-exp-logN/A
lower-log.f64N/A
rem-exp-log93.9
Applied rewrites93.9%
if -1.95e9 < y < 2e52Initial program 96.6%
Taylor expanded in y around 0
*-commutativeN/A
lower-*.f64N/A
lower--.f64N/A
rem-exp-logN/A
lower-log.f64N/A
rem-exp-log95.9
Applied rewrites95.9%
Final simplification95.0%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (pow a (- t 1.0)))
(t_2 (* (pow z y) x))
(t_3 (/ (* (exp (- (* (log a) t) b)) x) y)))
(if (<= b -0.00044)
t_3
(if (<= b 5.6e-281)
(/ (/ t_2 y) a)
(if (<= b 5.8e-165)
(/ (* t_1 x) y)
(if (<= b 6.8e+21) (* (/ t_1 y) 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 = pow(z, y) * x;
double t_3 = (exp(((log(a) * t) - b)) * x) / y;
double tmp;
if (b <= -0.00044) {
tmp = t_3;
} else if (b <= 5.6e-281) {
tmp = (t_2 / y) / a;
} else if (b <= 5.8e-165) {
tmp = (t_1 * x) / y;
} else if (b <= 6.8e+21) {
tmp = (t_1 / y) * 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 = (z ** y) * x
t_3 = (exp(((log(a) * t) - b)) * x) / y
if (b <= (-0.00044d0)) then
tmp = t_3
else if (b <= 5.6d-281) then
tmp = (t_2 / y) / a
else if (b <= 5.8d-165) then
tmp = (t_1 * x) / y
else if (b <= 6.8d+21) then
tmp = (t_1 / y) * 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 = Math.pow(z, y) * x;
double t_3 = (Math.exp(((Math.log(a) * t) - b)) * x) / y;
double tmp;
if (b <= -0.00044) {
tmp = t_3;
} else if (b <= 5.6e-281) {
tmp = (t_2 / y) / a;
} else if (b <= 5.8e-165) {
tmp = (t_1 * x) / y;
} else if (b <= 6.8e+21) {
tmp = (t_1 / y) * 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 = math.pow(z, y) * x t_3 = (math.exp(((math.log(a) * t) - b)) * x) / y tmp = 0 if b <= -0.00044: tmp = t_3 elif b <= 5.6e-281: tmp = (t_2 / y) / a elif b <= 5.8e-165: tmp = (t_1 * x) / y elif b <= 6.8e+21: tmp = (t_1 / y) * 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((z ^ y) * x) t_3 = Float64(Float64(exp(Float64(Float64(log(a) * t) - b)) * x) / y) tmp = 0.0 if (b <= -0.00044) tmp = t_3; elseif (b <= 5.6e-281) tmp = Float64(Float64(t_2 / y) / a); elseif (b <= 5.8e-165) tmp = Float64(Float64(t_1 * x) / y); elseif (b <= 6.8e+21) tmp = Float64(Float64(t_1 / y) * 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 = (z ^ y) * x; t_3 = (exp(((log(a) * t) - b)) * x) / y; tmp = 0.0; if (b <= -0.00044) tmp = t_3; elseif (b <= 5.6e-281) tmp = (t_2 / y) / a; elseif (b <= 5.8e-165) tmp = (t_1 * x) / y; elseif (b <= 6.8e+21) tmp = (t_1 / y) * 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[Power[z, y], $MachinePrecision] * x), $MachinePrecision]}, Block[{t$95$3 = N[(N[(N[Exp[N[(N[(N[Log[a], $MachinePrecision] * t), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision]}, If[LessEqual[b, -0.00044], t$95$3, If[LessEqual[b, 5.6e-281], N[(N[(t$95$2 / y), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[b, 5.8e-165], N[(N[(t$95$1 * x), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, 6.8e+21], N[(N[(t$95$1 / y), $MachinePrecision] * t$95$2), $MachinePrecision], t$95$3]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := {a}^{\left(t - 1\right)}\\
t_2 := {z}^{y} \cdot x\\
t_3 := \frac{e^{\log a \cdot t - b} \cdot x}{y}\\
\mathbf{if}\;b \leq -0.00044:\\
\;\;\;\;t\_3\\
\mathbf{elif}\;b \leq 5.6 \cdot 10^{-281}:\\
\;\;\;\;\frac{\frac{t\_2}{y}}{a}\\
\mathbf{elif}\;b \leq 5.8 \cdot 10^{-165}:\\
\;\;\;\;\frac{t\_1 \cdot x}{y}\\
\mathbf{elif}\;b \leq 6.8 \cdot 10^{+21}:\\
\;\;\;\;\frac{t\_1}{y} \cdot t\_2\\
\mathbf{else}:\\
\;\;\;\;t\_3\\
\end{array}
\end{array}
if b < -4.40000000000000016e-4 or 6.8e21 < b Initial program 100.0%
Taylor expanded in t around inf
*-commutativeN/A
lower-*.f64N/A
rem-exp-logN/A
lower-log.f64N/A
rem-exp-log91.7
Applied rewrites91.7%
if -4.40000000000000016e-4 < b < 5.6000000000000001e-281Initial program 96.1%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6475.6
Applied rewrites75.6%
Taylor expanded in t around 0
Applied rewrites74.5%
Applied rewrites81.1%
if 5.6000000000000001e-281 < b < 5.8e-165Initial program 98.0%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6468.5
Applied rewrites68.5%
Taylor expanded in t around 0
Applied rewrites56.3%
Taylor expanded in y around 0
Applied rewrites90.9%
if 5.8e-165 < b < 6.8e21Initial program 97.1%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6480.9
Applied rewrites80.9%
Final simplification86.3%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (/ (* (pow z y) x) y) a))
(t_2 (/ (* (exp (- (* (log a) t) b)) x) y)))
(if (<= b -0.00044)
t_2
(if (<= b 5.6e-281)
t_1
(if (<= b 6.2e-173)
(/ (* (pow a (- t 1.0)) x) y)
(if (<= b 5.3e-14) t_1 t_2))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = ((pow(z, y) * x) / y) / a;
double t_2 = (exp(((log(a) * t) - b)) * x) / y;
double tmp;
if (b <= -0.00044) {
tmp = t_2;
} else if (b <= 5.6e-281) {
tmp = t_1;
} else if (b <= 6.2e-173) {
tmp = (pow(a, (t - 1.0)) * x) / y;
} else if (b <= 5.3e-14) {
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 = (((z ** y) * x) / y) / a
t_2 = (exp(((log(a) * t) - b)) * x) / y
if (b <= (-0.00044d0)) then
tmp = t_2
else if (b <= 5.6d-281) then
tmp = t_1
else if (b <= 6.2d-173) then
tmp = ((a ** (t - 1.0d0)) * x) / y
else if (b <= 5.3d-14) 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.pow(z, y) * x) / y) / a;
double t_2 = (Math.exp(((Math.log(a) * t) - b)) * x) / y;
double tmp;
if (b <= -0.00044) {
tmp = t_2;
} else if (b <= 5.6e-281) {
tmp = t_1;
} else if (b <= 6.2e-173) {
tmp = (Math.pow(a, (t - 1.0)) * x) / y;
} else if (b <= 5.3e-14) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = ((math.pow(z, y) * x) / y) / a t_2 = (math.exp(((math.log(a) * t) - b)) * x) / y tmp = 0 if b <= -0.00044: tmp = t_2 elif b <= 5.6e-281: tmp = t_1 elif b <= 6.2e-173: tmp = (math.pow(a, (t - 1.0)) * x) / y elif b <= 5.3e-14: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(Float64((z ^ y) * x) / y) / a) t_2 = Float64(Float64(exp(Float64(Float64(log(a) * t) - b)) * x) / y) tmp = 0.0 if (b <= -0.00044) tmp = t_2; elseif (b <= 5.6e-281) tmp = t_1; elseif (b <= 6.2e-173) tmp = Float64(Float64((a ^ Float64(t - 1.0)) * x) / y); elseif (b <= 5.3e-14) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (((z ^ y) * x) / y) / a; t_2 = (exp(((log(a) * t) - b)) * x) / y; tmp = 0.0; if (b <= -0.00044) tmp = t_2; elseif (b <= 5.6e-281) tmp = t_1; elseif (b <= 6.2e-173) tmp = ((a ^ (t - 1.0)) * x) / y; elseif (b <= 5.3e-14) 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[(N[(N[Power[z, y], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision] / a), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[Exp[N[(N[(N[Log[a], $MachinePrecision] * t), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision]}, If[LessEqual[b, -0.00044], t$95$2, If[LessEqual[b, 5.6e-281], t$95$1, If[LessEqual[b, 6.2e-173], N[(N[(N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision], If[LessEqual[b, 5.3e-14], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\frac{{z}^{y} \cdot x}{y}}{a}\\
t_2 := \frac{e^{\log a \cdot t - b} \cdot x}{y}\\
\mathbf{if}\;b \leq -0.00044:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;b \leq 5.6 \cdot 10^{-281}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq 6.2 \cdot 10^{-173}:\\
\;\;\;\;\frac{{a}^{\left(t - 1\right)} \cdot x}{y}\\
\mathbf{elif}\;b \leq 5.3 \cdot 10^{-14}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if b < -4.40000000000000016e-4 or 5.3000000000000001e-14 < b Initial program 99.9%
Taylor expanded in t around inf
*-commutativeN/A
lower-*.f64N/A
rem-exp-logN/A
lower-log.f64N/A
rem-exp-log90.0
Applied rewrites90.0%
if -4.40000000000000016e-4 < b < 5.6000000000000001e-281 or 6.20000000000000011e-173 < b < 5.3000000000000001e-14Initial program 96.3%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6477.0
Applied rewrites77.0%
Taylor expanded in t around 0
Applied rewrites75.5%
Applied rewrites81.3%
if 5.6000000000000001e-281 < b < 6.20000000000000011e-173Initial program 98.3%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6472.5
Applied rewrites72.5%
Taylor expanded in t around 0
Applied rewrites46.6%
Taylor expanded in y around 0
Applied rewrites94.4%
Final simplification86.3%
(FPCore (x y z t a b)
:precision binary64
(if (<= y -1e+54)
(/ (/ (* (pow z y) x) y) a)
(if (<= y 1.15e+66)
(/ (* (exp (- (* (log a) (- t 1.0)) b)) x) y)
(/ (* (exp (* (log z) y)) x) y))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -1e+54) {
tmp = ((pow(z, y) * x) / y) / a;
} else if (y <= 1.15e+66) {
tmp = (exp(((log(a) * (t - 1.0)) - b)) * x) / y;
} else {
tmp = (exp((log(z) * y)) * x) / 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 <= (-1d+54)) then
tmp = (((z ** y) * x) / y) / a
else if (y <= 1.15d+66) then
tmp = (exp(((log(a) * (t - 1.0d0)) - b)) * x) / y
else
tmp = (exp((log(z) * y)) * x) / 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 <= -1e+54) {
tmp = ((Math.pow(z, y) * x) / y) / a;
} else if (y <= 1.15e+66) {
tmp = (Math.exp(((Math.log(a) * (t - 1.0)) - b)) * x) / y;
} else {
tmp = (Math.exp((Math.log(z) * y)) * x) / y;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -1e+54: tmp = ((math.pow(z, y) * x) / y) / a elif y <= 1.15e+66: tmp = (math.exp(((math.log(a) * (t - 1.0)) - b)) * x) / y else: tmp = (math.exp((math.log(z) * y)) * x) / y return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -1e+54) tmp = Float64(Float64(Float64((z ^ y) * x) / y) / a); elseif (y <= 1.15e+66) tmp = Float64(Float64(exp(Float64(Float64(log(a) * Float64(t - 1.0)) - b)) * x) / y); else tmp = Float64(Float64(exp(Float64(log(z) * y)) * x) / y); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (y <= -1e+54) tmp = (((z ^ y) * x) / y) / a; elseif (y <= 1.15e+66) tmp = (exp(((log(a) * (t - 1.0)) - b)) * x) / y; else tmp = (exp((log(z) * y)) * x) / y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -1e+54], N[(N[(N[(N[Power[z, y], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[y, 1.15e+66], N[(N[(N[Exp[N[(N[(N[Log[a], $MachinePrecision] * N[(t - 1.0), $MachinePrecision]), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision], N[(N[(N[Exp[N[(N[Log[z], $MachinePrecision] * y), $MachinePrecision]], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1 \cdot 10^{+54}:\\
\;\;\;\;\frac{\frac{{z}^{y} \cdot x}{y}}{a}\\
\mathbf{elif}\;y \leq 1.15 \cdot 10^{+66}:\\
\;\;\;\;\frac{e^{\log a \cdot \left(t - 1\right) - b} \cdot x}{y}\\
\mathbf{else}:\\
\;\;\;\;\frac{e^{\log z \cdot y} \cdot x}{y}\\
\end{array}
\end{array}
if y < -1.0000000000000001e54Initial program 100.0%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6450.1
Applied rewrites50.1%
Taylor expanded in t around 0
Applied rewrites68.9%
Applied rewrites83.6%
if -1.0000000000000001e54 < y < 1.15e66Initial program 96.9%
Taylor expanded in y around 0
*-commutativeN/A
lower-*.f64N/A
lower--.f64N/A
rem-exp-logN/A
lower-log.f64N/A
rem-exp-log95.1
Applied rewrites95.1%
if 1.15e66 < y Initial program 100.0%
Taylor expanded in t around 0
+-commutativeN/A
*-commutativeN/A
lower-fma.f64N/A
lower-log.f64N/A
mul-1-negN/A
lower-neg.f64N/A
rem-exp-logN/A
lower-log.f64N/A
rem-exp-log96.2
Applied rewrites96.2%
Taylor expanded in y around inf
*-commutativeN/A
lower-*.f64N/A
lower-log.f6488.6
Applied rewrites88.6%
Final simplification91.6%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (* (exp (- (* (log a) t) b)) x) y)))
(if (<= b -3.3)
t_1
(if (<= b 6.8e+21) (/ (* (pow a (- t 1.0)) (* (pow z y) x)) y) t_1))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (exp(((log(a) * t) - b)) * x) / y;
double tmp;
if (b <= -3.3) {
tmp = t_1;
} else if (b <= 6.8e+21) {
tmp = (pow(a, (t - 1.0)) * (pow(z, y) * x)) / y;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = (exp(((log(a) * t) - b)) * x) / y
if (b <= (-3.3d0)) then
tmp = t_1
else if (b <= 6.8d+21) then
tmp = ((a ** (t - 1.0d0)) * ((z ** y) * x)) / y
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (Math.exp(((Math.log(a) * t) - b)) * x) / y;
double tmp;
if (b <= -3.3) {
tmp = t_1;
} else if (b <= 6.8e+21) {
tmp = (Math.pow(a, (t - 1.0)) * (Math.pow(z, y) * x)) / y;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (math.exp(((math.log(a) * t) - b)) * x) / y tmp = 0 if b <= -3.3: tmp = t_1 elif b <= 6.8e+21: tmp = (math.pow(a, (t - 1.0)) * (math.pow(z, y) * x)) / y else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(exp(Float64(Float64(log(a) * t) - b)) * x) / y) tmp = 0.0 if (b <= -3.3) tmp = t_1; elseif (b <= 6.8e+21) tmp = Float64(Float64((a ^ Float64(t - 1.0)) * Float64((z ^ y) * x)) / y); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (exp(((log(a) * t) - b)) * x) / y; tmp = 0.0; if (b <= -3.3) tmp = t_1; elseif (b <= 6.8e+21) tmp = ((a ^ (t - 1.0)) * ((z ^ y) * x)) / y; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[Exp[N[(N[(N[Log[a], $MachinePrecision] * t), $MachinePrecision] - b), $MachinePrecision]], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision]}, If[LessEqual[b, -3.3], t$95$1, If[LessEqual[b, 6.8e+21], N[(N[(N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision] * N[(N[Power[z, y], $MachinePrecision] * x), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{e^{\log a \cdot t - b} \cdot x}{y}\\
\mathbf{if}\;b \leq -3.3:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq 6.8 \cdot 10^{+21}:\\
\;\;\;\;\frac{{a}^{\left(t - 1\right)} \cdot \left({z}^{y} \cdot x\right)}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -3.2999999999999998 or 6.8e21 < b Initial program 100.0%
Taylor expanded in t around inf
*-commutativeN/A
lower-*.f64N/A
rem-exp-logN/A
lower-log.f64N/A
rem-exp-log91.7
Applied rewrites91.7%
if -3.2999999999999998 < b < 6.8e21Initial program 96.7%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6481.4
Applied rewrites81.4%
Final simplification85.7%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (/ (exp (- b)) y) x)))
(if (<= b -7e+111)
t_1
(if (<= b 5.6e-281)
(/ (/ (* (pow z y) x) y) a)
(if (<= b 2.15e+55) (/ (* (pow a (- t 1.0)) x) y) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (exp(-b) / y) * x;
double tmp;
if (b <= -7e+111) {
tmp = t_1;
} else if (b <= 5.6e-281) {
tmp = ((pow(z, y) * x) / y) / a;
} else if (b <= 2.15e+55) {
tmp = (pow(a, (t - 1.0)) * x) / y;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = (exp(-b) / y) * x
if (b <= (-7d+111)) then
tmp = t_1
else if (b <= 5.6d-281) then
tmp = (((z ** y) * x) / y) / a
else if (b <= 2.15d+55) then
tmp = ((a ** (t - 1.0d0)) * x) / y
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (Math.exp(-b) / y) * x;
double tmp;
if (b <= -7e+111) {
tmp = t_1;
} else if (b <= 5.6e-281) {
tmp = ((Math.pow(z, y) * x) / y) / a;
} else if (b <= 2.15e+55) {
tmp = (Math.pow(a, (t - 1.0)) * x) / y;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (math.exp(-b) / y) * x tmp = 0 if b <= -7e+111: tmp = t_1 elif b <= 5.6e-281: tmp = ((math.pow(z, y) * x) / y) / a elif b <= 2.15e+55: tmp = (math.pow(a, (t - 1.0)) * x) / y else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(exp(Float64(-b)) / y) * x) tmp = 0.0 if (b <= -7e+111) tmp = t_1; elseif (b <= 5.6e-281) tmp = Float64(Float64(Float64((z ^ y) * x) / y) / a); elseif (b <= 2.15e+55) tmp = Float64(Float64((a ^ Float64(t - 1.0)) * x) / y); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (exp(-b) / y) * x; tmp = 0.0; if (b <= -7e+111) tmp = t_1; elseif (b <= 5.6e-281) tmp = (((z ^ y) * x) / y) / a; elseif (b <= 2.15e+55) tmp = ((a ^ (t - 1.0)) * x) / y; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[Exp[(-b)], $MachinePrecision] / y), $MachinePrecision] * x), $MachinePrecision]}, If[LessEqual[b, -7e+111], t$95$1, If[LessEqual[b, 5.6e-281], N[(N[(N[(N[Power[z, y], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[b, 2.15e+55], N[(N[(N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{e^{-b}}{y} \cdot x\\
\mathbf{if}\;b \leq -7 \cdot 10^{+111}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq 5.6 \cdot 10^{-281}:\\
\;\;\;\;\frac{\frac{{z}^{y} \cdot x}{y}}{a}\\
\mathbf{elif}\;b \leq 2.15 \cdot 10^{+55}:\\
\;\;\;\;\frac{{a}^{\left(t - 1\right)} \cdot x}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -7.0000000000000004e111 or 2.1499999999999999e55 < b Initial program 100.0%
Taylor expanded in b around inf
mul-1-negN/A
lower-neg.f6485.4
Applied rewrites85.4%
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
lower-/.f6485.4
Applied rewrites85.4%
if -7.0000000000000004e111 < b < 5.6000000000000001e-281Initial program 96.9%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6474.0
Applied rewrites74.0%
Taylor expanded in t around 0
Applied rewrites71.2%
Applied rewrites76.5%
if 5.6000000000000001e-281 < b < 2.1499999999999999e55Initial program 97.7%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6477.0
Applied rewrites77.0%
Taylor expanded in t around 0
Applied rewrites63.9%
Taylor expanded in y around 0
Applied rewrites77.1%
Final simplification79.5%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (/ (exp (- b)) y) x)))
(if (<= b -2.16e+111)
t_1
(if (<= b 5.6e-281)
(* (/ (pow z y) a) (/ x y))
(if (<= b 2.15e+55) (/ (* (pow a (- t 1.0)) x) y) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (exp(-b) / y) * x;
double tmp;
if (b <= -2.16e+111) {
tmp = t_1;
} else if (b <= 5.6e-281) {
tmp = (pow(z, y) / a) * (x / y);
} else if (b <= 2.15e+55) {
tmp = (pow(a, (t - 1.0)) * x) / y;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = (exp(-b) / y) * x
if (b <= (-2.16d+111)) then
tmp = t_1
else if (b <= 5.6d-281) then
tmp = ((z ** y) / a) * (x / y)
else if (b <= 2.15d+55) then
tmp = ((a ** (t - 1.0d0)) * x) / y
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (Math.exp(-b) / y) * x;
double tmp;
if (b <= -2.16e+111) {
tmp = t_1;
} else if (b <= 5.6e-281) {
tmp = (Math.pow(z, y) / a) * (x / y);
} else if (b <= 2.15e+55) {
tmp = (Math.pow(a, (t - 1.0)) * x) / y;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (math.exp(-b) / y) * x tmp = 0 if b <= -2.16e+111: tmp = t_1 elif b <= 5.6e-281: tmp = (math.pow(z, y) / a) * (x / y) elif b <= 2.15e+55: tmp = (math.pow(a, (t - 1.0)) * x) / y else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(exp(Float64(-b)) / y) * x) tmp = 0.0 if (b <= -2.16e+111) tmp = t_1; elseif (b <= 5.6e-281) tmp = Float64(Float64((z ^ y) / a) * Float64(x / y)); elseif (b <= 2.15e+55) tmp = Float64(Float64((a ^ Float64(t - 1.0)) * x) / y); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (exp(-b) / y) * x; tmp = 0.0; if (b <= -2.16e+111) tmp = t_1; elseif (b <= 5.6e-281) tmp = ((z ^ y) / a) * (x / y); elseif (b <= 2.15e+55) tmp = ((a ^ (t - 1.0)) * x) / y; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[Exp[(-b)], $MachinePrecision] / y), $MachinePrecision] * x), $MachinePrecision]}, If[LessEqual[b, -2.16e+111], t$95$1, If[LessEqual[b, 5.6e-281], N[(N[(N[Power[z, y], $MachinePrecision] / a), $MachinePrecision] * N[(x / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 2.15e+55], N[(N[(N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{e^{-b}}{y} \cdot x\\
\mathbf{if}\;b \leq -2.16 \cdot 10^{+111}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq 5.6 \cdot 10^{-281}:\\
\;\;\;\;\frac{{z}^{y}}{a} \cdot \frac{x}{y}\\
\mathbf{elif}\;b \leq 2.15 \cdot 10^{+55}:\\
\;\;\;\;\frac{{a}^{\left(t - 1\right)} \cdot x}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -2.16000000000000008e111 or 2.1499999999999999e55 < b Initial program 100.0%
Taylor expanded in b around inf
mul-1-negN/A
lower-neg.f6485.4
Applied rewrites85.4%
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
lower-/.f6485.4
Applied rewrites85.4%
if -2.16000000000000008e111 < b < 5.6000000000000001e-281Initial program 96.9%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6474.0
Applied rewrites74.0%
Taylor expanded in t around 0
Applied rewrites71.2%
if 5.6000000000000001e-281 < b < 2.1499999999999999e55Initial program 97.7%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6477.0
Applied rewrites77.0%
Taylor expanded in t around 0
Applied rewrites63.9%
Taylor expanded in y around 0
Applied rewrites77.1%
Final simplification77.6%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (/ (exp (- b)) y) x)))
(if (<= b -2.16e+111)
t_1
(if (<= b -2.2e-191)
(/ (* (pow z y) x) (* a y))
(if (<= b 2.15e+55) (/ (* (pow a (- t 1.0)) x) y) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (exp(-b) / y) * x;
double tmp;
if (b <= -2.16e+111) {
tmp = t_1;
} else if (b <= -2.2e-191) {
tmp = (pow(z, y) * x) / (a * y);
} else if (b <= 2.15e+55) {
tmp = (pow(a, (t - 1.0)) * x) / y;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = (exp(-b) / y) * x
if (b <= (-2.16d+111)) then
tmp = t_1
else if (b <= (-2.2d-191)) then
tmp = ((z ** y) * x) / (a * y)
else if (b <= 2.15d+55) then
tmp = ((a ** (t - 1.0d0)) * x) / y
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (Math.exp(-b) / y) * x;
double tmp;
if (b <= -2.16e+111) {
tmp = t_1;
} else if (b <= -2.2e-191) {
tmp = (Math.pow(z, y) * x) / (a * y);
} else if (b <= 2.15e+55) {
tmp = (Math.pow(a, (t - 1.0)) * x) / y;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (math.exp(-b) / y) * x tmp = 0 if b <= -2.16e+111: tmp = t_1 elif b <= -2.2e-191: tmp = (math.pow(z, y) * x) / (a * y) elif b <= 2.15e+55: tmp = (math.pow(a, (t - 1.0)) * x) / y else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(exp(Float64(-b)) / y) * x) tmp = 0.0 if (b <= -2.16e+111) tmp = t_1; elseif (b <= -2.2e-191) tmp = Float64(Float64((z ^ y) * x) / Float64(a * y)); elseif (b <= 2.15e+55) tmp = Float64(Float64((a ^ Float64(t - 1.0)) * x) / y); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (exp(-b) / y) * x; tmp = 0.0; if (b <= -2.16e+111) tmp = t_1; elseif (b <= -2.2e-191) tmp = ((z ^ y) * x) / (a * y); elseif (b <= 2.15e+55) tmp = ((a ^ (t - 1.0)) * x) / y; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[Exp[(-b)], $MachinePrecision] / y), $MachinePrecision] * x), $MachinePrecision]}, If[LessEqual[b, -2.16e+111], t$95$1, If[LessEqual[b, -2.2e-191], N[(N[(N[Power[z, y], $MachinePrecision] * x), $MachinePrecision] / N[(a * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 2.15e+55], N[(N[(N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{e^{-b}}{y} \cdot x\\
\mathbf{if}\;b \leq -2.16 \cdot 10^{+111}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq -2.2 \cdot 10^{-191}:\\
\;\;\;\;\frac{{z}^{y} \cdot x}{a \cdot y}\\
\mathbf{elif}\;b \leq 2.15 \cdot 10^{+55}:\\
\;\;\;\;\frac{{a}^{\left(t - 1\right)} \cdot x}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -2.16000000000000008e111 or 2.1499999999999999e55 < b Initial program 100.0%
Taylor expanded in b around inf
mul-1-negN/A
lower-neg.f6485.4
Applied rewrites85.4%
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
lower-/.f6485.4
Applied rewrites85.4%
if -2.16000000000000008e111 < b < -2.19999999999999998e-191Initial program 97.3%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6470.8
Applied rewrites70.8%
Taylor expanded in t around 0
Applied rewrites68.1%
Applied rewrites73.0%
if -2.19999999999999998e-191 < b < 2.1499999999999999e55Initial program 97.2%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6477.6
Applied rewrites77.6%
Taylor expanded in t around 0
Applied rewrites67.8%
Taylor expanded in y around 0
Applied rewrites74.4%
Final simplification77.6%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (/ (exp (- b)) y) x)))
(if (<= b -1.55e+111)
t_1
(if (<= b 2.15e+55) (/ (* (pow a (- t 1.0)) x) y) t_1))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (exp(-b) / y) * x;
double tmp;
if (b <= -1.55e+111) {
tmp = t_1;
} else if (b <= 2.15e+55) {
tmp = (pow(a, (t - 1.0)) * x) / y;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = (exp(-b) / y) * x
if (b <= (-1.55d+111)) then
tmp = t_1
else if (b <= 2.15d+55) then
tmp = ((a ** (t - 1.0d0)) * x) / y
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (Math.exp(-b) / y) * x;
double tmp;
if (b <= -1.55e+111) {
tmp = t_1;
} else if (b <= 2.15e+55) {
tmp = (Math.pow(a, (t - 1.0)) * x) / y;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (math.exp(-b) / y) * x tmp = 0 if b <= -1.55e+111: tmp = t_1 elif b <= 2.15e+55: tmp = (math.pow(a, (t - 1.0)) * x) / y else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(exp(Float64(-b)) / y) * x) tmp = 0.0 if (b <= -1.55e+111) tmp = t_1; elseif (b <= 2.15e+55) tmp = Float64(Float64((a ^ Float64(t - 1.0)) * x) / y); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (exp(-b) / y) * x; tmp = 0.0; if (b <= -1.55e+111) tmp = t_1; elseif (b <= 2.15e+55) tmp = ((a ^ (t - 1.0)) * x) / y; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[Exp[(-b)], $MachinePrecision] / y), $MachinePrecision] * x), $MachinePrecision]}, If[LessEqual[b, -1.55e+111], t$95$1, If[LessEqual[b, 2.15e+55], N[(N[(N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision] * x), $MachinePrecision] / y), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{e^{-b}}{y} \cdot x\\
\mathbf{if}\;b \leq -1.55 \cdot 10^{+111}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq 2.15 \cdot 10^{+55}:\\
\;\;\;\;\frac{{a}^{\left(t - 1\right)} \cdot x}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -1.55e111 or 2.1499999999999999e55 < b Initial program 100.0%
Taylor expanded in b around inf
mul-1-negN/A
lower-neg.f6485.4
Applied rewrites85.4%
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
lower-/.f6485.4
Applied rewrites85.4%
if -1.55e111 < b < 2.1499999999999999e55Initial program 97.2%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6475.3
Applied rewrites75.3%
Taylor expanded in t around 0
Applied rewrites67.9%
Taylor expanded in y around 0
Applied rewrites71.2%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* (/ (exp (- b)) y) x)))
(if (<= b -1.6e+111)
t_1
(if (<= b 2.1e+55) (* (/ (pow a (- t 1.0)) y) x) t_1))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (exp(-b) / y) * x;
double tmp;
if (b <= -1.6e+111) {
tmp = t_1;
} else if (b <= 2.1e+55) {
tmp = (pow(a, (t - 1.0)) / y) * x;
} 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 = (exp(-b) / y) * x
if (b <= (-1.6d+111)) then
tmp = t_1
else if (b <= 2.1d+55) then
tmp = ((a ** (t - 1.0d0)) / y) * x
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 = (Math.exp(-b) / y) * x;
double tmp;
if (b <= -1.6e+111) {
tmp = t_1;
} else if (b <= 2.1e+55) {
tmp = (Math.pow(a, (t - 1.0)) / y) * x;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (math.exp(-b) / y) * x tmp = 0 if b <= -1.6e+111: tmp = t_1 elif b <= 2.1e+55: tmp = (math.pow(a, (t - 1.0)) / y) * x else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(exp(Float64(-b)) / y) * x) tmp = 0.0 if (b <= -1.6e+111) tmp = t_1; elseif (b <= 2.1e+55) tmp = Float64(Float64((a ^ Float64(t - 1.0)) / y) * x); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (exp(-b) / y) * x; tmp = 0.0; if (b <= -1.6e+111) tmp = t_1; elseif (b <= 2.1e+55) tmp = ((a ^ (t - 1.0)) / y) * x; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[Exp[(-b)], $MachinePrecision] / y), $MachinePrecision] * x), $MachinePrecision]}, If[LessEqual[b, -1.6e+111], t$95$1, If[LessEqual[b, 2.1e+55], N[(N[(N[Power[a, N[(t - 1.0), $MachinePrecision]], $MachinePrecision] / y), $MachinePrecision] * x), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{e^{-b}}{y} \cdot x\\
\mathbf{if}\;b \leq -1.6 \cdot 10^{+111}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq 2.1 \cdot 10^{+55}:\\
\;\;\;\;\frac{{a}^{\left(t - 1\right)}}{y} \cdot x\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -1.6e111 or 2.1000000000000001e55 < b Initial program 100.0%
Taylor expanded in b around inf
mul-1-negN/A
lower-neg.f6485.4
Applied rewrites85.4%
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
lower-/.f6485.4
Applied rewrites85.4%
if -1.6e111 < b < 2.1000000000000001e55Initial program 97.2%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6475.3
Applied rewrites75.3%
Taylor expanded in y around 0
Applied rewrites66.4%
(FPCore (x y z t a b) :precision binary64 (let* ((t_1 (* (/ (exp (- b)) y) x))) (if (<= b -3.3) t_1 (if (<= b 1.25e+36) (/ (/ x a) y) t_1))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (exp(-b) / y) * x;
double tmp;
if (b <= -3.3) {
tmp = t_1;
} else if (b <= 1.25e+36) {
tmp = (x / a) / y;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = (exp(-b) / y) * x
if (b <= (-3.3d0)) then
tmp = t_1
else if (b <= 1.25d+36) then
tmp = (x / a) / y
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (Math.exp(-b) / y) * x;
double tmp;
if (b <= -3.3) {
tmp = t_1;
} else if (b <= 1.25e+36) {
tmp = (x / a) / y;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (math.exp(-b) / y) * x tmp = 0 if b <= -3.3: tmp = t_1 elif b <= 1.25e+36: tmp = (x / a) / y else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(exp(Float64(-b)) / y) * x) tmp = 0.0 if (b <= -3.3) tmp = t_1; elseif (b <= 1.25e+36) tmp = Float64(Float64(x / a) / y); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (exp(-b) / y) * x; tmp = 0.0; if (b <= -3.3) tmp = t_1; elseif (b <= 1.25e+36) tmp = (x / a) / y; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[Exp[(-b)], $MachinePrecision] / y), $MachinePrecision] * x), $MachinePrecision]}, If[LessEqual[b, -3.3], t$95$1, If[LessEqual[b, 1.25e+36], N[(N[(x / a), $MachinePrecision] / y), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{e^{-b}}{y} \cdot x\\
\mathbf{if}\;b \leq -3.3:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq 1.25 \cdot 10^{+36}:\\
\;\;\;\;\frac{\frac{x}{a}}{y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -3.2999999999999998 or 1.24999999999999994e36 < b Initial program 100.0%
Taylor expanded in b around inf
mul-1-negN/A
lower-neg.f6477.8
Applied rewrites77.8%
lift-/.f64N/A
lift-*.f64N/A
associate-/l*N/A
*-commutativeN/A
lower-*.f64N/A
lower-/.f6477.8
Applied rewrites77.8%
if -3.2999999999999998 < b < 1.24999999999999994e36Initial program 96.9%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6476.5
Applied rewrites76.5%
Taylor expanded in t around 0
Applied rewrites70.4%
Taylor expanded in y around 0
Applied rewrites72.3%
Taylor expanded in t around 0
Applied rewrites44.5%
(FPCore (x y z t a b) :precision binary64 (if (<= x 1e-47) (/ 1.0 (* (/ y x) a)) (/ (/ x a) y)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (x <= 1e-47) {
tmp = 1.0 / ((y / x) * a);
} else {
tmp = (x / a) / y;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (x <= 1d-47) then
tmp = 1.0d0 / ((y / x) * a)
else
tmp = (x / a) / y
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (x <= 1e-47) {
tmp = 1.0 / ((y / x) * a);
} else {
tmp = (x / a) / y;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if x <= 1e-47: tmp = 1.0 / ((y / x) * a) else: tmp = (x / a) / y return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (x <= 1e-47) tmp = Float64(1.0 / Float64(Float64(y / x) * a)); else tmp = Float64(Float64(x / a) / y); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (x <= 1e-47) tmp = 1.0 / ((y / x) * a); else tmp = (x / a) / y; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[x, 1e-47], N[(1.0 / N[(N[(y / x), $MachinePrecision] * a), $MachinePrecision]), $MachinePrecision], N[(N[(x / a), $MachinePrecision] / y), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq 10^{-47}:\\
\;\;\;\;\frac{1}{\frac{y}{x} \cdot a}\\
\mathbf{else}:\\
\;\;\;\;\frac{\frac{x}{a}}{y}\\
\end{array}
\end{array}
if x < 9.9999999999999997e-48Initial program 97.5%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6462.8
Applied rewrites62.8%
Taylor expanded in t around 0
Applied rewrites50.5%
Applied rewrites47.2%
Taylor expanded in y around 0
Applied rewrites36.6%
if 9.9999999999999997e-48 < x Initial program 99.5%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6465.8
Applied rewrites65.8%
Taylor expanded in t around 0
Applied rewrites65.0%
Taylor expanded in y around 0
Applied rewrites50.7%
Taylor expanded in t around 0
Applied rewrites30.3%
(FPCore (x y z t a b) :precision binary64 (/ (/ x a) y))
double code(double x, double y, double z, double t, double a, double b) {
return (x / a) / 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 / a) / y
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return (x / a) / y;
}
def code(x, y, z, t, a, b): return (x / a) / y
function code(x, y, z, t, a, b) return Float64(Float64(x / a) / y) end
function tmp = code(x, y, z, t, a, b) tmp = (x / a) / y; end
code[x_, y_, z_, t_, a_, b_] := N[(N[(x / a), $MachinePrecision] / y), $MachinePrecision]
\begin{array}{l}
\\
\frac{\frac{x}{a}}{y}
\end{array}
Initial program 98.1%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6463.6
Applied rewrites63.6%
Taylor expanded in t around 0
Applied rewrites54.8%
Taylor expanded in y around 0
Applied rewrites60.6%
Taylor expanded in t around 0
Applied rewrites35.6%
(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(Float64(x / 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[(N[(x / y), $MachinePrecision] / a), $MachinePrecision]
\begin{array}{l}
\\
\frac{\frac{x}{y}}{a}
\end{array}
Initial program 98.1%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6463.6
Applied rewrites63.6%
Taylor expanded in t around 0
Applied rewrites54.8%
Taylor expanded in y around 0
Applied rewrites30.7%
Applied rewrites33.8%
(FPCore (x y z t a b) :precision binary64 (/ x (* a y)))
double code(double x, double y, double z, double t, double a, double b) {
return x / (a * 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 / (a * y)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x / (a * y);
}
def code(x, y, z, t, a, b): return x / (a * y)
function code(x, y, z, t, a, b) return Float64(x / Float64(a * y)) end
function tmp = code(x, y, z, t, a, b) tmp = x / (a * y); end
code[x_, y_, z_, t_, a_, b_] := N[(x / N[(a * y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{a \cdot y}
\end{array}
Initial program 98.1%
Taylor expanded in b around 0
exp-sumN/A
associate-*r*N/A
associate-/l*N/A
lower-*.f64N/A
lower-*.f64N/A
*-commutativeN/A
exp-to-powN/A
lower-pow.f64N/A
lower-/.f64N/A
exp-prodN/A
lower-pow.f64N/A
rem-exp-logN/A
lower--.f6463.6
Applied rewrites63.6%
Taylor expanded in t around 0
Applied rewrites54.8%
Taylor expanded in y around 0
Applied rewrites30.7%
(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 2024332
(FPCore (x y z t a b)
:name "Numeric.SpecFunctions:incompleteBetaWorker from math-functions-0.1.5.2, A"
:precision binary64
:alt
(! :herbie-platform default (if (< t -8845848504127471/10000000000000000) (/ (* x (/ (pow a (- t 1)) y)) (- (+ b 1) (* y (log z)))) (if (< t 8520312288374073/10000000000) (/ (* (/ x y) (pow a (- t 1))) (exp (- b (* (log z) y)))) (/ (* x (/ (pow a (- t 1)) y)) (- (+ b 1) (* y (log z)))))))
(/ (* x (exp (- (+ (* y (log z)) (* (- t 1.0) (log a))) b))) y))