
(FPCore (x y z t a b) :precision binary64 (* x (exp (+ (* y (- (log z) t)) (* a (- (log (- 1.0 z)) b))))))
double code(double x, double y, double z, double t, double a, double b) {
return x * exp(((y * (log(z) - t)) + (a * (log((1.0 - z)) - 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 * exp(((y * (log(z) - t)) + (a * (log((1.0d0 - z)) - b))))
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)) + (a * (Math.log((1.0 - z)) - b))));
}
def code(x, y, z, t, a, b): return x * math.exp(((y * (math.log(z) - t)) + (a * (math.log((1.0 - z)) - b))))
function code(x, y, z, t, a, b) return Float64(x * exp(Float64(Float64(y * Float64(log(z) - t)) + Float64(a * Float64(log(Float64(1.0 - z)) - b))))) end
function tmp = code(x, y, z, t, a, b) tmp = x * exp(((y * (log(z) - t)) + (a * (log((1.0 - z)) - b)))); end
code[x_, y_, z_, t_, a_, b_] := N[(x * N[Exp[N[(N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] + N[(a * N[(N[Log[N[(1.0 - z), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot e^{y \cdot \left(\log z - t\right) + a \cdot \left(\log \left(1 - z\right) - b\right)}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 21 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b) :precision binary64 (* x (exp (+ (* y (- (log z) t)) (* a (- (log (- 1.0 z)) b))))))
double code(double x, double y, double z, double t, double a, double b) {
return x * exp(((y * (log(z) - t)) + (a * (log((1.0 - z)) - 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 * exp(((y * (log(z) - t)) + (a * (log((1.0d0 - z)) - b))))
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)) + (a * (Math.log((1.0 - z)) - b))));
}
def code(x, y, z, t, a, b): return x * math.exp(((y * (math.log(z) - t)) + (a * (math.log((1.0 - z)) - b))))
function code(x, y, z, t, a, b) return Float64(x * exp(Float64(Float64(y * Float64(log(z) - t)) + Float64(a * Float64(log(Float64(1.0 - z)) - b))))) end
function tmp = code(x, y, z, t, a, b) tmp = x * exp(((y * (log(z) - t)) + (a * (log((1.0 - z)) - b)))); end
code[x_, y_, z_, t_, a_, b_] := N[(x * N[Exp[N[(N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] + N[(a * N[(N[Log[N[(1.0 - z), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot e^{y \cdot \left(\log z - t\right) + a \cdot \left(\log \left(1 - z\right) - b\right)}
\end{array}
(FPCore (x y z t a b) :precision binary64 (* x (exp (fma y (- (log z) t) (* a (- (log1p (- z)) b))))))
double code(double x, double y, double z, double t, double a, double b) {
return x * exp(fma(y, (log(z) - t), (a * (log1p(-z) - b))));
}
function code(x, y, z, t, a, b) return Float64(x * exp(fma(y, Float64(log(z) - t), Float64(a * Float64(log1p(Float64(-z)) - b))))) end
code[x_, y_, z_, t_, a_, b_] := N[(x * N[Exp[N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision] + N[(a * N[(N[Log[1 + (-z)], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot e^{\mathsf{fma}\left(y, \log z - t, a \cdot \left(\mathsf{log1p}\left(-z\right) - b\right)\right)}
\end{array}
Initial program 95.7%
fma-define95.7%
sub-neg95.7%
log1p-define99.2%
Simplified99.2%
Final simplification99.2%
(FPCore (x y z t a b) :precision binary64 (* x (exp (- (* a (- (log (- 1.0 z)) b)) (* y (- t (log z)))))))
double code(double x, double y, double z, double t, double a, double b) {
return x * exp(((a * (log((1.0 - z)) - b)) - (y * (t - log(z)))));
}
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(((a * (log((1.0d0 - z)) - b)) - (y * (t - log(z)))))
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x * Math.exp(((a * (Math.log((1.0 - z)) - b)) - (y * (t - Math.log(z)))));
}
def code(x, y, z, t, a, b): return x * math.exp(((a * (math.log((1.0 - z)) - b)) - (y * (t - math.log(z)))))
function code(x, y, z, t, a, b) return Float64(x * exp(Float64(Float64(a * Float64(log(Float64(1.0 - z)) - b)) - Float64(y * Float64(t - log(z)))))) end
function tmp = code(x, y, z, t, a, b) tmp = x * exp(((a * (log((1.0 - z)) - b)) - (y * (t - log(z))))); end
code[x_, y_, z_, t_, a_, b_] := N[(x * N[Exp[N[(N[(a * N[(N[Log[N[(1.0 - z), $MachinePrecision]], $MachinePrecision] - b), $MachinePrecision]), $MachinePrecision] - N[(y * N[(t - N[Log[z], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x \cdot e^{a \cdot \left(\log \left(1 - z\right) - b\right) - y \cdot \left(t - \log z\right)}
\end{array}
Initial program 95.7%
Final simplification95.7%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -1.45e-41) (not (<= y 8.4e-19))) (* x (exp (* y (- (log z) t)))) (* x (exp (* (- a) (+ z b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -1.45e-41) || !(y <= 8.4e-19)) {
tmp = x * exp((y * (log(z) - t)));
} else {
tmp = x * exp((-a * (z + 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 <= (-1.45d-41)) .or. (.not. (y <= 8.4d-19))) then
tmp = x * exp((y * (log(z) - t)))
else
tmp = x * exp((-a * (z + 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 <= -1.45e-41) || !(y <= 8.4e-19)) {
tmp = x * Math.exp((y * (Math.log(z) - t)));
} else {
tmp = x * Math.exp((-a * (z + b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -1.45e-41) or not (y <= 8.4e-19): tmp = x * math.exp((y * (math.log(z) - t))) else: tmp = x * math.exp((-a * (z + b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -1.45e-41) || !(y <= 8.4e-19)) tmp = Float64(x * exp(Float64(y * Float64(log(z) - t)))); else tmp = Float64(x * exp(Float64(Float64(-a) * Float64(z + b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -1.45e-41) || ~((y <= 8.4e-19))) tmp = x * exp((y * (log(z) - t))); else tmp = x * exp((-a * (z + b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -1.45e-41], N[Not[LessEqual[y, 8.4e-19]], $MachinePrecision]], N[(x * N[Exp[N[(y * N[(N[Log[z], $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(x * N[Exp[N[((-a) * N[(z + b), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.45 \cdot 10^{-41} \lor \neg \left(y \leq 8.4 \cdot 10^{-19}\right):\\
\;\;\;\;x \cdot e^{y \cdot \left(\log z - t\right)}\\
\mathbf{else}:\\
\;\;\;\;x \cdot e^{\left(-a\right) \cdot \left(z + b\right)}\\
\end{array}
\end{array}
if y < -1.44999999999999989e-41 or 8.3999999999999996e-19 < y Initial program 97.4%
Taylor expanded in y around inf 87.3%
if -1.44999999999999989e-41 < y < 8.3999999999999996e-19Initial program 93.3%
Taylor expanded in y around 0 83.1%
sub-neg83.1%
log1p-define90.8%
Simplified90.8%
Taylor expanded in z around 0 90.8%
associate-*r*90.8%
associate-*r*90.8%
distribute-lft-out90.8%
mul-1-neg90.8%
Simplified90.8%
Final simplification88.7%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* x (exp (* (- a) (+ z b))))) (t_2 (* x (exp (* y (- t))))))
(if (<= t -2.45e+114)
t_2
(if (<= t -1.1e-285)
t_1
(if (<= t 2.9e-190) (* x (pow z y)) (if (<= t 5.8e+35) t_1 t_2))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * exp((-a * (z + b)));
double t_2 = x * exp((y * -t));
double tmp;
if (t <= -2.45e+114) {
tmp = t_2;
} else if (t <= -1.1e-285) {
tmp = t_1;
} else if (t <= 2.9e-190) {
tmp = x * pow(z, y);
} else if (t <= 5.8e+35) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = x * exp((-a * (z + b)))
t_2 = x * exp((y * -t))
if (t <= (-2.45d+114)) then
tmp = t_2
else if (t <= (-1.1d-285)) then
tmp = t_1
else if (t <= 2.9d-190) then
tmp = x * (z ** y)
else if (t <= 5.8d+35) then
tmp = t_1
else
tmp = t_2
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * Math.exp((-a * (z + b)));
double t_2 = x * Math.exp((y * -t));
double tmp;
if (t <= -2.45e+114) {
tmp = t_2;
} else if (t <= -1.1e-285) {
tmp = t_1;
} else if (t <= 2.9e-190) {
tmp = x * Math.pow(z, y);
} else if (t <= 5.8e+35) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x * math.exp((-a * (z + b))) t_2 = x * math.exp((y * -t)) tmp = 0 if t <= -2.45e+114: tmp = t_2 elif t <= -1.1e-285: tmp = t_1 elif t <= 2.9e-190: tmp = x * math.pow(z, y) elif t <= 5.8e+35: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x * exp(Float64(Float64(-a) * Float64(z + b)))) t_2 = Float64(x * exp(Float64(y * Float64(-t)))) tmp = 0.0 if (t <= -2.45e+114) tmp = t_2; elseif (t <= -1.1e-285) tmp = t_1; elseif (t <= 2.9e-190) tmp = Float64(x * (z ^ y)); elseif (t <= 5.8e+35) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x * exp((-a * (z + b))); t_2 = x * exp((y * -t)); tmp = 0.0; if (t <= -2.45e+114) tmp = t_2; elseif (t <= -1.1e-285) tmp = t_1; elseif (t <= 2.9e-190) tmp = x * (z ^ y); elseif (t <= 5.8e+35) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x * N[Exp[N[((-a) * N[(z + b), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x * N[Exp[N[(y * (-t)), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -2.45e+114], t$95$2, If[LessEqual[t, -1.1e-285], t$95$1, If[LessEqual[t, 2.9e-190], N[(x * N[Power[z, y], $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 5.8e+35], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot e^{\left(-a\right) \cdot \left(z + b\right)}\\
t_2 := x \cdot e^{y \cdot \left(-t\right)}\\
\mathbf{if}\;t \leq -2.45 \cdot 10^{+114}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t \leq -1.1 \cdot 10^{-285}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 2.9 \cdot 10^{-190}:\\
\;\;\;\;x \cdot {z}^{y}\\
\mathbf{elif}\;t \leq 5.8 \cdot 10^{+35}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if t < -2.45e114 or 5.79999999999999989e35 < t Initial program 95.5%
Taylor expanded in t around inf 83.0%
mul-1-neg83.0%
distribute-lft-neg-out83.0%
*-commutative83.0%
Simplified83.0%
if -2.45e114 < t < -1.1e-285 or 2.9000000000000002e-190 < t < 5.79999999999999989e35Initial program 95.6%
Taylor expanded in y around 0 73.8%
sub-neg73.8%
log1p-define79.8%
Simplified79.8%
Taylor expanded in z around 0 79.8%
associate-*r*79.8%
associate-*r*79.8%
distribute-lft-out79.8%
mul-1-neg79.8%
Simplified79.8%
if -1.1e-285 < t < 2.9000000000000002e-190Initial program 96.8%
Taylor expanded in y around inf 82.0%
Taylor expanded in t around 0 82.0%
Final simplification81.4%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* x (exp (* y (- t))))))
(if (<= t -1.95e+116)
t_1
(if (<= t -1.5e-285)
(* x (exp (* a (- b))))
(if (<= t 5.5e-89) (* x (pow z y)) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * exp((y * -t));
double tmp;
if (t <= -1.95e+116) {
tmp = t_1;
} else if (t <= -1.5e-285) {
tmp = x * exp((a * -b));
} else if (t <= 5.5e-89) {
tmp = x * pow(z, y);
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = x * exp((y * -t))
if (t <= (-1.95d+116)) then
tmp = t_1
else if (t <= (-1.5d-285)) then
tmp = x * exp((a * -b))
else if (t <= 5.5d-89) then
tmp = x * (z ** y)
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * Math.exp((y * -t));
double tmp;
if (t <= -1.95e+116) {
tmp = t_1;
} else if (t <= -1.5e-285) {
tmp = x * Math.exp((a * -b));
} else if (t <= 5.5e-89) {
tmp = x * Math.pow(z, y);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x * math.exp((y * -t)) tmp = 0 if t <= -1.95e+116: tmp = t_1 elif t <= -1.5e-285: tmp = x * math.exp((a * -b)) elif t <= 5.5e-89: tmp = x * math.pow(z, y) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x * exp(Float64(y * Float64(-t)))) tmp = 0.0 if (t <= -1.95e+116) tmp = t_1; elseif (t <= -1.5e-285) tmp = Float64(x * exp(Float64(a * Float64(-b)))); elseif (t <= 5.5e-89) tmp = Float64(x * (z ^ y)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x * exp((y * -t)); tmp = 0.0; if (t <= -1.95e+116) tmp = t_1; elseif (t <= -1.5e-285) tmp = x * exp((a * -b)); elseif (t <= 5.5e-89) tmp = x * (z ^ y); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x * N[Exp[N[(y * (-t)), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.95e+116], t$95$1, If[LessEqual[t, -1.5e-285], N[(x * N[Exp[N[(a * (-b)), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 5.5e-89], N[(x * N[Power[z, y], $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot e^{y \cdot \left(-t\right)}\\
\mathbf{if}\;t \leq -1.95 \cdot 10^{+116}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq -1.5 \cdot 10^{-285}:\\
\;\;\;\;x \cdot e^{a \cdot \left(-b\right)}\\
\mathbf{elif}\;t \leq 5.5 \cdot 10^{-89}:\\
\;\;\;\;x \cdot {z}^{y}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -1.95000000000000016e116 or 5.50000000000000012e-89 < t Initial program 94.7%
Taylor expanded in t around inf 79.6%
mul-1-neg79.6%
distribute-lft-neg-out79.6%
*-commutative79.6%
Simplified79.6%
if -1.95000000000000016e116 < t < -1.50000000000000002e-285Initial program 96.9%
Taylor expanded in b around inf 79.1%
mul-1-neg79.1%
distribute-rgt-neg-out79.1%
Simplified79.1%
if -1.50000000000000002e-285 < t < 5.50000000000000012e-89Initial program 96.4%
Taylor expanded in y around inf 73.8%
Taylor expanded in t around 0 73.8%
Final simplification78.2%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -55000000000000.0) (not (<= y 8.4e-19))) (* x (pow z y)) (* x (exp (* a (- b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -55000000000000.0) || !(y <= 8.4e-19)) {
tmp = x * pow(z, y);
} else {
tmp = x * exp((a * -b));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((y <= (-55000000000000.0d0)) .or. (.not. (y <= 8.4d-19))) then
tmp = x * (z ** y)
else
tmp = x * exp((a * -b))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -55000000000000.0) || !(y <= 8.4e-19)) {
tmp = x * Math.pow(z, y);
} else {
tmp = x * Math.exp((a * -b));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -55000000000000.0) or not (y <= 8.4e-19): tmp = x * math.pow(z, y) else: tmp = x * math.exp((a * -b)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -55000000000000.0) || !(y <= 8.4e-19)) tmp = Float64(x * (z ^ y)); else tmp = Float64(x * exp(Float64(a * Float64(-b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -55000000000000.0) || ~((y <= 8.4e-19))) tmp = x * (z ^ y); else tmp = x * exp((a * -b)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -55000000000000.0], N[Not[LessEqual[y, 8.4e-19]], $MachinePrecision]], N[(x * N[Power[z, y], $MachinePrecision]), $MachinePrecision], N[(x * N[Exp[N[(a * (-b)), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -55000000000000 \lor \neg \left(y \leq 8.4 \cdot 10^{-19}\right):\\
\;\;\;\;x \cdot {z}^{y}\\
\mathbf{else}:\\
\;\;\;\;x \cdot e^{a \cdot \left(-b\right)}\\
\end{array}
\end{array}
if y < -5.5e13 or 8.3999999999999996e-19 < y Initial program 97.1%
Taylor expanded in y around inf 89.9%
Taylor expanded in t around 0 66.7%
if -5.5e13 < y < 8.3999999999999996e-19Initial program 94.1%
Taylor expanded in b around inf 79.9%
mul-1-neg79.9%
distribute-rgt-neg-out79.9%
Simplified79.9%
Final simplification72.9%
(FPCore (x y z t a b) :precision binary64 (if (<= t -5.1e+41) (* x (- 1.0 (* y t))) (* x (pow z y))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= -5.1e+41) {
tmp = x * (1.0 - (y * t));
} else {
tmp = x * pow(z, y);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (t <= (-5.1d+41)) then
tmp = x * (1.0d0 - (y * t))
else
tmp = x * (z ** y)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= -5.1e+41) {
tmp = x * (1.0 - (y * t));
} else {
tmp = x * Math.pow(z, y);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if t <= -5.1e+41: tmp = x * (1.0 - (y * t)) else: tmp = x * math.pow(z, y) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (t <= -5.1e+41) tmp = Float64(x * Float64(1.0 - Float64(y * t))); else tmp = Float64(x * (z ^ y)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (t <= -5.1e+41) tmp = x * (1.0 - (y * t)); else tmp = x * (z ^ y); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, -5.1e+41], N[(x * N[(1.0 - N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[Power[z, y], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -5.1 \cdot 10^{+41}:\\
\;\;\;\;x \cdot \left(1 - y \cdot t\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot {z}^{y}\\
\end{array}
\end{array}
if t < -5.09999999999999978e41Initial program 93.8%
Taylor expanded in t around inf 79.7%
mul-1-neg79.7%
distribute-lft-neg-out79.7%
*-commutative79.7%
Simplified79.7%
Taylor expanded in y around 0 36.3%
mul-1-neg36.3%
unsub-neg36.3%
Simplified36.3%
Taylor expanded in x around 0 42.4%
if -5.09999999999999978e41 < t Initial program 96.3%
Taylor expanded in y around inf 71.0%
Taylor expanded in t around 0 65.1%
Final simplification59.6%
(FPCore (x y z t a b)
:precision binary64
(if (<= t -4.8e+40)
(* x (- 1.0 (* y t)))
(if (<= t 2.7e-178)
(* x (- 1.0 (* z (+ a (* a (/ b z))))))
(if (<= t 8.2e-111)
(* x (* y t))
(if (<= t 7.6e+158)
(+ x (* b (* a (- (* (* a 0.5) (* x b)) x))))
(* t (* y (- x))))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= -4.8e+40) {
tmp = x * (1.0 - (y * t));
} else if (t <= 2.7e-178) {
tmp = x * (1.0 - (z * (a + (a * (b / z)))));
} else if (t <= 8.2e-111) {
tmp = x * (y * t);
} else if (t <= 7.6e+158) {
tmp = x + (b * (a * (((a * 0.5) * (x * b)) - x)));
} else {
tmp = t * (y * -x);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (t <= (-4.8d+40)) then
tmp = x * (1.0d0 - (y * t))
else if (t <= 2.7d-178) then
tmp = x * (1.0d0 - (z * (a + (a * (b / z)))))
else if (t <= 8.2d-111) then
tmp = x * (y * t)
else if (t <= 7.6d+158) then
tmp = x + (b * (a * (((a * 0.5d0) * (x * b)) - x)))
else
tmp = t * (y * -x)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= -4.8e+40) {
tmp = x * (1.0 - (y * t));
} else if (t <= 2.7e-178) {
tmp = x * (1.0 - (z * (a + (a * (b / z)))));
} else if (t <= 8.2e-111) {
tmp = x * (y * t);
} else if (t <= 7.6e+158) {
tmp = x + (b * (a * (((a * 0.5) * (x * b)) - x)));
} else {
tmp = t * (y * -x);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if t <= -4.8e+40: tmp = x * (1.0 - (y * t)) elif t <= 2.7e-178: tmp = x * (1.0 - (z * (a + (a * (b / z))))) elif t <= 8.2e-111: tmp = x * (y * t) elif t <= 7.6e+158: tmp = x + (b * (a * (((a * 0.5) * (x * b)) - x))) else: tmp = t * (y * -x) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (t <= -4.8e+40) tmp = Float64(x * Float64(1.0 - Float64(y * t))); elseif (t <= 2.7e-178) tmp = Float64(x * Float64(1.0 - Float64(z * Float64(a + Float64(a * Float64(b / z)))))); elseif (t <= 8.2e-111) tmp = Float64(x * Float64(y * t)); elseif (t <= 7.6e+158) tmp = Float64(x + Float64(b * Float64(a * Float64(Float64(Float64(a * 0.5) * Float64(x * b)) - x)))); else tmp = Float64(t * Float64(y * Float64(-x))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (t <= -4.8e+40) tmp = x * (1.0 - (y * t)); elseif (t <= 2.7e-178) tmp = x * (1.0 - (z * (a + (a * (b / z))))); elseif (t <= 8.2e-111) tmp = x * (y * t); elseif (t <= 7.6e+158) tmp = x + (b * (a * (((a * 0.5) * (x * b)) - x))); else tmp = t * (y * -x); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, -4.8e+40], N[(x * N[(1.0 - N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.7e-178], N[(x * N[(1.0 - N[(z * N[(a + N[(a * N[(b / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 8.2e-111], N[(x * N[(y * t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 7.6e+158], N[(x + N[(b * N[(a * N[(N[(N[(a * 0.5), $MachinePrecision] * N[(x * b), $MachinePrecision]), $MachinePrecision] - x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(t * N[(y * (-x)), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.8 \cdot 10^{+40}:\\
\;\;\;\;x \cdot \left(1 - y \cdot t\right)\\
\mathbf{elif}\;t \leq 2.7 \cdot 10^{-178}:\\
\;\;\;\;x \cdot \left(1 - z \cdot \left(a + a \cdot \frac{b}{z}\right)\right)\\
\mathbf{elif}\;t \leq 8.2 \cdot 10^{-111}:\\
\;\;\;\;x \cdot \left(y \cdot t\right)\\
\mathbf{elif}\;t \leq 7.6 \cdot 10^{+158}:\\
\;\;\;\;x + b \cdot \left(a \cdot \left(\left(a \cdot 0.5\right) \cdot \left(x \cdot b\right) - x\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t \cdot \left(y \cdot \left(-x\right)\right)\\
\end{array}
\end{array}
if t < -4.8e40Initial program 93.8%
Taylor expanded in t around inf 79.7%
mul-1-neg79.7%
distribute-lft-neg-out79.7%
*-commutative79.7%
Simplified79.7%
Taylor expanded in y around 0 36.3%
mul-1-neg36.3%
unsub-neg36.3%
Simplified36.3%
Taylor expanded in x around 0 42.4%
if -4.8e40 < t < 2.70000000000000009e-178Initial program 96.5%
Taylor expanded in y around 0 74.2%
sub-neg74.2%
log1p-define77.6%
Simplified77.6%
Taylor expanded in z around 0 77.6%
associate-*r*77.6%
associate-*r*77.6%
distribute-lft-out77.6%
mul-1-neg77.6%
Simplified77.6%
Taylor expanded in a around 0 34.6%
neg-mul-134.6%
distribute-rgt-neg-in34.6%
Simplified34.6%
Taylor expanded in z around inf 44.8%
distribute-lft-out44.8%
associate-/l*48.8%
Simplified48.8%
if 2.70000000000000009e-178 < t < 8.19999999999999936e-111Initial program 94.8%
Taylor expanded in t around inf 23.9%
mul-1-neg23.9%
distribute-lft-neg-out23.9%
*-commutative23.9%
Simplified23.9%
Taylor expanded in y around 0 18.7%
mul-1-neg18.7%
unsub-neg18.7%
Simplified18.7%
Taylor expanded in t around inf 40.5%
mul-1-neg40.5%
distribute-rgt-neg-out40.5%
distribute-rgt-neg-in40.5%
Simplified40.5%
pow140.5%
add-sqr-sqrt27.3%
sqrt-unprod55.9%
sqr-neg55.9%
sqrt-unprod18.5%
add-sqr-sqrt40.2%
Applied egg-rr40.2%
unpow140.2%
associate-*r*40.2%
*-commutative40.2%
associate-*r*45.3%
Simplified45.3%
if 8.19999999999999936e-111 < t < 7.5999999999999997e158Initial program 96.0%
Taylor expanded in b around inf 64.6%
mul-1-neg64.6%
distribute-rgt-neg-out64.6%
Simplified64.6%
Taylor expanded in b around 0 40.5%
+-commutative40.5%
mul-1-neg40.5%
unsub-neg40.5%
Simplified40.5%
Taylor expanded in a around 0 46.8%
associate-*r*46.8%
Simplified46.8%
if 7.5999999999999997e158 < t Initial program 97.0%
Taylor expanded in t around inf 82.5%
mul-1-neg82.5%
distribute-lft-neg-out82.5%
*-commutative82.5%
Simplified82.5%
Taylor expanded in y around 0 23.5%
mul-1-neg23.5%
unsub-neg23.5%
Simplified23.5%
Taylor expanded in t around inf 32.0%
mul-1-neg32.0%
distribute-rgt-neg-out32.0%
distribute-rgt-neg-in32.0%
Simplified32.0%
Final simplification44.4%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* x (* z (- (/ (- 1.0 (* a b)) z) a)))))
(if (<= t -7.4e+39)
(* x (- 1.0 (* y t)))
(if (<= t 2.1e-180)
t_1
(if (<= t 4.6e-109)
(* x (* y t))
(if (<= t 7.2e+154) t_1 (* t (* y (- x)))))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * (z * (((1.0 - (a * b)) / z) - a));
double tmp;
if (t <= -7.4e+39) {
tmp = x * (1.0 - (y * t));
} else if (t <= 2.1e-180) {
tmp = t_1;
} else if (t <= 4.6e-109) {
tmp = x * (y * t);
} else if (t <= 7.2e+154) {
tmp = t_1;
} else {
tmp = t * (y * -x);
}
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 * (((1.0d0 - (a * b)) / z) - a))
if (t <= (-7.4d+39)) then
tmp = x * (1.0d0 - (y * t))
else if (t <= 2.1d-180) then
tmp = t_1
else if (t <= 4.6d-109) then
tmp = x * (y * t)
else if (t <= 7.2d+154) then
tmp = t_1
else
tmp = t * (y * -x)
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 * (z * (((1.0 - (a * b)) / z) - a));
double tmp;
if (t <= -7.4e+39) {
tmp = x * (1.0 - (y * t));
} else if (t <= 2.1e-180) {
tmp = t_1;
} else if (t <= 4.6e-109) {
tmp = x * (y * t);
} else if (t <= 7.2e+154) {
tmp = t_1;
} else {
tmp = t * (y * -x);
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x * (z * (((1.0 - (a * b)) / z) - a)) tmp = 0 if t <= -7.4e+39: tmp = x * (1.0 - (y * t)) elif t <= 2.1e-180: tmp = t_1 elif t <= 4.6e-109: tmp = x * (y * t) elif t <= 7.2e+154: tmp = t_1 else: tmp = t * (y * -x) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x * Float64(z * Float64(Float64(Float64(1.0 - Float64(a * b)) / z) - a))) tmp = 0.0 if (t <= -7.4e+39) tmp = Float64(x * Float64(1.0 - Float64(y * t))); elseif (t <= 2.1e-180) tmp = t_1; elseif (t <= 4.6e-109) tmp = Float64(x * Float64(y * t)); elseif (t <= 7.2e+154) tmp = t_1; else tmp = Float64(t * Float64(y * Float64(-x))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x * (z * (((1.0 - (a * b)) / z) - a)); tmp = 0.0; if (t <= -7.4e+39) tmp = x * (1.0 - (y * t)); elseif (t <= 2.1e-180) tmp = t_1; elseif (t <= 4.6e-109) tmp = x * (y * t); elseif (t <= 7.2e+154) tmp = t_1; else tmp = t * (y * -x); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x * N[(z * N[(N[(N[(1.0 - N[(a * b), $MachinePrecision]), $MachinePrecision] / z), $MachinePrecision] - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -7.4e+39], N[(x * N[(1.0 - N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.1e-180], t$95$1, If[LessEqual[t, 4.6e-109], N[(x * N[(y * t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 7.2e+154], t$95$1, N[(t * N[(y * (-x)), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(z \cdot \left(\frac{1 - a \cdot b}{z} - a\right)\right)\\
\mathbf{if}\;t \leq -7.4 \cdot 10^{+39}:\\
\;\;\;\;x \cdot \left(1 - y \cdot t\right)\\
\mathbf{elif}\;t \leq 2.1 \cdot 10^{-180}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 4.6 \cdot 10^{-109}:\\
\;\;\;\;x \cdot \left(y \cdot t\right)\\
\mathbf{elif}\;t \leq 7.2 \cdot 10^{+154}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t \cdot \left(y \cdot \left(-x\right)\right)\\
\end{array}
\end{array}
if t < -7.40000000000000025e39Initial program 93.8%
Taylor expanded in t around inf 79.7%
mul-1-neg79.7%
distribute-lft-neg-out79.7%
*-commutative79.7%
Simplified79.7%
Taylor expanded in y around 0 36.3%
mul-1-neg36.3%
unsub-neg36.3%
Simplified36.3%
Taylor expanded in x around 0 42.4%
if -7.40000000000000025e39 < t < 2.0999999999999999e-180 or 4.6000000000000003e-109 < t < 7.2000000000000001e154Initial program 96.3%
Taylor expanded in y around 0 71.3%
sub-neg71.3%
log1p-define75.0%
Simplified75.0%
Taylor expanded in z around 0 75.0%
associate-*r*75.0%
associate-*r*75.0%
distribute-lft-out75.0%
mul-1-neg75.0%
Simplified75.0%
Taylor expanded in a around 0 35.0%
neg-mul-135.0%
distribute-rgt-neg-in35.0%
Simplified35.0%
Taylor expanded in z around -inf 43.0%
mul-1-neg43.0%
*-commutative43.0%
distribute-rgt-neg-in43.0%
mul-1-neg43.0%
unsub-neg43.0%
mul-1-neg43.0%
unsub-neg43.0%
Simplified43.0%
if 2.0999999999999999e-180 < t < 4.6000000000000003e-109Initial program 94.8%
Taylor expanded in t around inf 23.9%
mul-1-neg23.9%
distribute-lft-neg-out23.9%
*-commutative23.9%
Simplified23.9%
Taylor expanded in y around 0 18.7%
mul-1-neg18.7%
unsub-neg18.7%
Simplified18.7%
Taylor expanded in t around inf 40.5%
mul-1-neg40.5%
distribute-rgt-neg-out40.5%
distribute-rgt-neg-in40.5%
Simplified40.5%
pow140.5%
add-sqr-sqrt27.3%
sqrt-unprod55.9%
sqr-neg55.9%
sqrt-unprod18.5%
add-sqr-sqrt40.2%
Applied egg-rr40.2%
unpow140.2%
associate-*r*40.2%
*-commutative40.2%
associate-*r*45.3%
Simplified45.3%
if 7.2000000000000001e154 < t Initial program 97.1%
Taylor expanded in t around inf 83.0%
mul-1-neg83.0%
distribute-lft-neg-out83.0%
*-commutative83.0%
Simplified83.0%
Taylor expanded in y around 0 23.0%
mul-1-neg23.0%
unsub-neg23.0%
Simplified23.0%
Taylor expanded in t around inf 31.2%
mul-1-neg31.2%
distribute-rgt-neg-out31.2%
distribute-rgt-neg-in31.2%
Simplified31.2%
Final simplification41.4%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* x (- 1.0 (* z (+ a (* a (/ b z))))))))
(if (<= t -1.8e+43)
(* x (- 1.0 (* y t)))
(if (<= t 2.45e-179)
t_1
(if (<= t 8.2e-111)
(* x (* y t))
(if (<= t 7.5e+154) t_1 (* t (* y (- x)))))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x * (1.0 - (z * (a + (a * (b / z)))));
double tmp;
if (t <= -1.8e+43) {
tmp = x * (1.0 - (y * t));
} else if (t <= 2.45e-179) {
tmp = t_1;
} else if (t <= 8.2e-111) {
tmp = x * (y * t);
} else if (t <= 7.5e+154) {
tmp = t_1;
} else {
tmp = t * (y * -x);
}
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 * (1.0d0 - (z * (a + (a * (b / z)))))
if (t <= (-1.8d+43)) then
tmp = x * (1.0d0 - (y * t))
else if (t <= 2.45d-179) then
tmp = t_1
else if (t <= 8.2d-111) then
tmp = x * (y * t)
else if (t <= 7.5d+154) then
tmp = t_1
else
tmp = t * (y * -x)
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 * (1.0 - (z * (a + (a * (b / z)))));
double tmp;
if (t <= -1.8e+43) {
tmp = x * (1.0 - (y * t));
} else if (t <= 2.45e-179) {
tmp = t_1;
} else if (t <= 8.2e-111) {
tmp = x * (y * t);
} else if (t <= 7.5e+154) {
tmp = t_1;
} else {
tmp = t * (y * -x);
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x * (1.0 - (z * (a + (a * (b / z))))) tmp = 0 if t <= -1.8e+43: tmp = x * (1.0 - (y * t)) elif t <= 2.45e-179: tmp = t_1 elif t <= 8.2e-111: tmp = x * (y * t) elif t <= 7.5e+154: tmp = t_1 else: tmp = t * (y * -x) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x * Float64(1.0 - Float64(z * Float64(a + Float64(a * Float64(b / z)))))) tmp = 0.0 if (t <= -1.8e+43) tmp = Float64(x * Float64(1.0 - Float64(y * t))); elseif (t <= 2.45e-179) tmp = t_1; elseif (t <= 8.2e-111) tmp = Float64(x * Float64(y * t)); elseif (t <= 7.5e+154) tmp = t_1; else tmp = Float64(t * Float64(y * Float64(-x))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x * (1.0 - (z * (a + (a * (b / z))))); tmp = 0.0; if (t <= -1.8e+43) tmp = x * (1.0 - (y * t)); elseif (t <= 2.45e-179) tmp = t_1; elseif (t <= 8.2e-111) tmp = x * (y * t); elseif (t <= 7.5e+154) tmp = t_1; else tmp = t * (y * -x); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x * N[(1.0 - N[(z * N[(a + N[(a * N[(b / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -1.8e+43], N[(x * N[(1.0 - N[(y * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 2.45e-179], t$95$1, If[LessEqual[t, 8.2e-111], N[(x * N[(y * t), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 7.5e+154], t$95$1, N[(t * N[(y * (-x)), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x \cdot \left(1 - z \cdot \left(a + a \cdot \frac{b}{z}\right)\right)\\
\mathbf{if}\;t \leq -1.8 \cdot 10^{+43}:\\
\;\;\;\;x \cdot \left(1 - y \cdot t\right)\\
\mathbf{elif}\;t \leq 2.45 \cdot 10^{-179}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 8.2 \cdot 10^{-111}:\\
\;\;\;\;x \cdot \left(y \cdot t\right)\\
\mathbf{elif}\;t \leq 7.5 \cdot 10^{+154}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t \cdot \left(y \cdot \left(-x\right)\right)\\
\end{array}
\end{array}
if t < -1.80000000000000005e43Initial program 93.8%
Taylor expanded in t around inf 79.7%
mul-1-neg79.7%
distribute-lft-neg-out79.7%
*-commutative79.7%
Simplified79.7%
Taylor expanded in y around 0 36.3%
mul-1-neg36.3%
unsub-neg36.3%
Simplified36.3%
Taylor expanded in x around 0 42.4%
if -1.80000000000000005e43 < t < 2.45e-179 or 8.19999999999999936e-111 < t < 7.5000000000000004e154Initial program 96.3%
Taylor expanded in y around 0 71.3%
sub-neg71.3%
log1p-define75.0%
Simplified75.0%
Taylor expanded in z around 0 75.0%
associate-*r*75.0%
associate-*r*75.0%
distribute-lft-out75.0%
mul-1-neg75.0%
Simplified75.0%
Taylor expanded in a around 0 35.0%
neg-mul-135.0%
distribute-rgt-neg-in35.0%
Simplified35.0%
Taylor expanded in z around inf 43.1%
distribute-lft-out43.1%
associate-/l*47.0%
Simplified47.0%
if 2.45e-179 < t < 8.19999999999999936e-111Initial program 94.8%
Taylor expanded in t around inf 23.9%
mul-1-neg23.9%
distribute-lft-neg-out23.9%
*-commutative23.9%
Simplified23.9%
Taylor expanded in y around 0 18.7%
mul-1-neg18.7%
unsub-neg18.7%
Simplified18.7%
Taylor expanded in t around inf 40.5%
mul-1-neg40.5%
distribute-rgt-neg-out40.5%
distribute-rgt-neg-in40.5%
Simplified40.5%
pow140.5%
add-sqr-sqrt27.3%
sqrt-unprod55.9%
sqr-neg55.9%
sqrt-unprod18.5%
add-sqr-sqrt40.2%
Applied egg-rr40.2%
unpow140.2%
associate-*r*40.2%
*-commutative40.2%
associate-*r*45.3%
Simplified45.3%
if 7.5000000000000004e154 < t Initial program 97.1%
Taylor expanded in t around inf 83.0%
mul-1-neg83.0%
distribute-lft-neg-out83.0%
*-commutative83.0%
Simplified83.0%
Taylor expanded in y around 0 23.0%
mul-1-neg23.0%
unsub-neg23.0%
Simplified23.0%
Taylor expanded in t around inf 31.2%
mul-1-neg31.2%
distribute-rgt-neg-out31.2%
distribute-rgt-neg-in31.2%
Simplified31.2%
Final simplification43.6%
(FPCore (x y z t a b)
:precision binary64
(if (<= y -4.3e-42)
(* t (- (/ x t) (* x y)))
(if (<= y 0.0135)
(* x (* b (- (/ (- 1.0 (* z a)) b) a)))
(* x (* y (- t))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -4.3e-42) {
tmp = t * ((x / t) - (x * y));
} else if (y <= 0.0135) {
tmp = x * (b * (((1.0 - (z * a)) / b) - a));
} else {
tmp = x * (y * -t);
}
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.3d-42)) then
tmp = t * ((x / t) - (x * y))
else if (y <= 0.0135d0) then
tmp = x * (b * (((1.0d0 - (z * a)) / b) - a))
else
tmp = x * (y * -t)
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.3e-42) {
tmp = t * ((x / t) - (x * y));
} else if (y <= 0.0135) {
tmp = x * (b * (((1.0 - (z * a)) / b) - a));
} else {
tmp = x * (y * -t);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -4.3e-42: tmp = t * ((x / t) - (x * y)) elif y <= 0.0135: tmp = x * (b * (((1.0 - (z * a)) / b) - a)) else: tmp = x * (y * -t) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -4.3e-42) tmp = Float64(t * Float64(Float64(x / t) - Float64(x * y))); elseif (y <= 0.0135) tmp = Float64(x * Float64(b * Float64(Float64(Float64(1.0 - Float64(z * a)) / b) - a))); else tmp = Float64(x * Float64(y * Float64(-t))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (y <= -4.3e-42) tmp = t * ((x / t) - (x * y)); elseif (y <= 0.0135) tmp = x * (b * (((1.0 - (z * a)) / b) - a)); else tmp = x * (y * -t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -4.3e-42], N[(t * N[(N[(x / t), $MachinePrecision] - N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 0.0135], N[(x * N[(b * N[(N[(N[(1.0 - N[(z * a), $MachinePrecision]), $MachinePrecision] / b), $MachinePrecision] - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(y * (-t)), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.3 \cdot 10^{-42}:\\
\;\;\;\;t \cdot \left(\frac{x}{t} - x \cdot y\right)\\
\mathbf{elif}\;y \leq 0.0135:\\
\;\;\;\;x \cdot \left(b \cdot \left(\frac{1 - z \cdot a}{b} - a\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(y \cdot \left(-t\right)\right)\\
\end{array}
\end{array}
if y < -4.3000000000000001e-42Initial program 98.6%
Taylor expanded in t around inf 57.6%
mul-1-neg57.6%
distribute-lft-neg-out57.6%
*-commutative57.6%
Simplified57.6%
Taylor expanded in y around 0 26.5%
mul-1-neg26.5%
unsub-neg26.5%
Simplified26.5%
Taylor expanded in t around inf 29.0%
if -4.3000000000000001e-42 < y < 0.0134999999999999998Initial program 93.3%
Taylor expanded in y around 0 83.1%
sub-neg83.1%
log1p-define90.8%
Simplified90.8%
Taylor expanded in z around 0 90.8%
associate-*r*90.8%
associate-*r*90.8%
distribute-lft-out90.8%
mul-1-neg90.8%
Simplified90.8%
Taylor expanded in a around 0 47.5%
neg-mul-147.5%
distribute-rgt-neg-in47.5%
Simplified47.5%
Taylor expanded in b around -inf 50.1%
mul-1-neg50.1%
distribute-rgt-neg-in50.1%
mul-1-neg50.1%
unsub-neg50.1%
mul-1-neg50.1%
unsub-neg50.1%
Simplified50.1%
if 0.0134999999999999998 < y Initial program 96.4%
Taylor expanded in t around inf 59.8%
mul-1-neg59.8%
distribute-lft-neg-out59.8%
*-commutative59.8%
Simplified59.8%
Taylor expanded in y around 0 22.0%
mul-1-neg22.0%
unsub-neg22.0%
Simplified22.0%
Taylor expanded in t around inf 26.6%
*-commutative26.6%
associate-*r*31.2%
neg-mul-131.2%
distribute-rgt-neg-in31.2%
*-commutative31.2%
distribute-rgt-neg-in31.2%
Simplified31.2%
Final simplification38.4%
(FPCore (x y z t a b) :precision binary64 (if (<= y -1.16e-42) (* t (- (/ x t) (* x y))) (if (<= y 1.15e-5) (- x (* a (* x (+ z b)))) (* x (* y (- t))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -1.16e-42) {
tmp = t * ((x / t) - (x * y));
} else if (y <= 1.15e-5) {
tmp = x - (a * (x * (z + b)));
} else {
tmp = x * (y * -t);
}
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.16d-42)) then
tmp = t * ((x / t) - (x * y))
else if (y <= 1.15d-5) then
tmp = x - (a * (x * (z + b)))
else
tmp = x * (y * -t)
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.16e-42) {
tmp = t * ((x / t) - (x * y));
} else if (y <= 1.15e-5) {
tmp = x - (a * (x * (z + b)));
} else {
tmp = x * (y * -t);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -1.16e-42: tmp = t * ((x / t) - (x * y)) elif y <= 1.15e-5: tmp = x - (a * (x * (z + b))) else: tmp = x * (y * -t) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -1.16e-42) tmp = Float64(t * Float64(Float64(x / t) - Float64(x * y))); elseif (y <= 1.15e-5) tmp = Float64(x - Float64(a * Float64(x * Float64(z + b)))); else tmp = Float64(x * Float64(y * Float64(-t))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (y <= -1.16e-42) tmp = t * ((x / t) - (x * y)); elseif (y <= 1.15e-5) tmp = x - (a * (x * (z + b))); else tmp = x * (y * -t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -1.16e-42], N[(t * N[(N[(x / t), $MachinePrecision] - N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.15e-5], N[(x - N[(a * N[(x * N[(z + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(y * (-t)), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.16 \cdot 10^{-42}:\\
\;\;\;\;t \cdot \left(\frac{x}{t} - x \cdot y\right)\\
\mathbf{elif}\;y \leq 1.15 \cdot 10^{-5}:\\
\;\;\;\;x - a \cdot \left(x \cdot \left(z + b\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(y \cdot \left(-t\right)\right)\\
\end{array}
\end{array}
if y < -1.1600000000000001e-42Initial program 98.6%
Taylor expanded in t around inf 57.6%
mul-1-neg57.6%
distribute-lft-neg-out57.6%
*-commutative57.6%
Simplified57.6%
Taylor expanded in y around 0 26.5%
mul-1-neg26.5%
unsub-neg26.5%
Simplified26.5%
Taylor expanded in t around inf 29.0%
if -1.1600000000000001e-42 < y < 1.15e-5Initial program 93.3%
Taylor expanded in y around 0 83.1%
sub-neg83.1%
log1p-define90.8%
Simplified90.8%
Taylor expanded in z around 0 90.8%
associate-*r*90.8%
associate-*r*90.8%
distribute-lft-out90.8%
mul-1-neg90.8%
Simplified90.8%
Taylor expanded in a around 0 47.2%
mul-1-neg47.2%
unsub-neg47.2%
*-commutative47.2%
Simplified47.2%
if 1.15e-5 < y Initial program 96.4%
Taylor expanded in t around inf 59.8%
mul-1-neg59.8%
distribute-lft-neg-out59.8%
*-commutative59.8%
Simplified59.8%
Taylor expanded in y around 0 22.0%
mul-1-neg22.0%
unsub-neg22.0%
Simplified22.0%
Taylor expanded in t around inf 26.6%
*-commutative26.6%
associate-*r*31.2%
neg-mul-131.2%
distribute-rgt-neg-in31.2%
*-commutative31.2%
distribute-rgt-neg-in31.2%
Simplified31.2%
Final simplification37.2%
(FPCore (x y z t a b) :precision binary64 (if (<= y -4.8e-42) (* t (- (/ x t) (* x y))) (if (<= y 0.28) (* x (- 1.0 (* a (+ z b)))) (* x (* y (- t))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -4.8e-42) {
tmp = t * ((x / t) - (x * y));
} else if (y <= 0.28) {
tmp = x * (1.0 - (a * (z + b)));
} else {
tmp = x * (y * -t);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (y <= (-4.8d-42)) then
tmp = t * ((x / t) - (x * y))
else if (y <= 0.28d0) then
tmp = x * (1.0d0 - (a * (z + b)))
else
tmp = x * (y * -t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -4.8e-42) {
tmp = t * ((x / t) - (x * y));
} else if (y <= 0.28) {
tmp = x * (1.0 - (a * (z + b)));
} else {
tmp = x * (y * -t);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -4.8e-42: tmp = t * ((x / t) - (x * y)) elif y <= 0.28: tmp = x * (1.0 - (a * (z + b))) else: tmp = x * (y * -t) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -4.8e-42) tmp = Float64(t * Float64(Float64(x / t) - Float64(x * y))); elseif (y <= 0.28) tmp = Float64(x * Float64(1.0 - Float64(a * Float64(z + b)))); else tmp = Float64(x * Float64(y * Float64(-t))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (y <= -4.8e-42) tmp = t * ((x / t) - (x * y)); elseif (y <= 0.28) tmp = x * (1.0 - (a * (z + b))); else tmp = x * (y * -t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -4.8e-42], N[(t * N[(N[(x / t), $MachinePrecision] - N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 0.28], N[(x * N[(1.0 - N[(a * N[(z + b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(y * (-t)), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.8 \cdot 10^{-42}:\\
\;\;\;\;t \cdot \left(\frac{x}{t} - x \cdot y\right)\\
\mathbf{elif}\;y \leq 0.28:\\
\;\;\;\;x \cdot \left(1 - a \cdot \left(z + b\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(y \cdot \left(-t\right)\right)\\
\end{array}
\end{array}
if y < -4.80000000000000005e-42Initial program 98.6%
Taylor expanded in t around inf 57.6%
mul-1-neg57.6%
distribute-lft-neg-out57.6%
*-commutative57.6%
Simplified57.6%
Taylor expanded in y around 0 26.5%
mul-1-neg26.5%
unsub-neg26.5%
Simplified26.5%
Taylor expanded in t around inf 29.0%
if -4.80000000000000005e-42 < y < 0.28000000000000003Initial program 93.3%
Taylor expanded in y around 0 83.1%
sub-neg83.1%
log1p-define90.8%
Simplified90.8%
Taylor expanded in z around 0 90.8%
associate-*r*90.8%
associate-*r*90.8%
distribute-lft-out90.8%
mul-1-neg90.8%
Simplified90.8%
Taylor expanded in a around 0 47.5%
neg-mul-147.5%
distribute-rgt-neg-in47.5%
Simplified47.5%
if 0.28000000000000003 < y Initial program 96.4%
Taylor expanded in t around inf 59.8%
mul-1-neg59.8%
distribute-lft-neg-out59.8%
*-commutative59.8%
Simplified59.8%
Taylor expanded in y around 0 22.0%
mul-1-neg22.0%
unsub-neg22.0%
Simplified22.0%
Taylor expanded in t around inf 26.6%
*-commutative26.6%
associate-*r*31.2%
neg-mul-131.2%
distribute-rgt-neg-in31.2%
*-commutative31.2%
distribute-rgt-neg-in31.2%
Simplified31.2%
Final simplification37.3%
(FPCore (x y z t a b) :precision binary64 (if (<= y -1.1e+22) (* t (* y (- x))) (if (<= y 1.25e-7) (* x (- 1.0 (* a b))) (* x (* y (- t))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -1.1e+22) {
tmp = t * (y * -x);
} else if (y <= 1.25e-7) {
tmp = x * (1.0 - (a * b));
} else {
tmp = x * (y * -t);
}
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+22)) then
tmp = t * (y * -x)
else if (y <= 1.25d-7) then
tmp = x * (1.0d0 - (a * b))
else
tmp = x * (y * -t)
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+22) {
tmp = t * (y * -x);
} else if (y <= 1.25e-7) {
tmp = x * (1.0 - (a * b));
} else {
tmp = x * (y * -t);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -1.1e+22: tmp = t * (y * -x) elif y <= 1.25e-7: tmp = x * (1.0 - (a * b)) else: tmp = x * (y * -t) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -1.1e+22) tmp = Float64(t * Float64(y * Float64(-x))); elseif (y <= 1.25e-7) tmp = Float64(x * Float64(1.0 - Float64(a * b))); else tmp = Float64(x * Float64(y * Float64(-t))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (y <= -1.1e+22) tmp = t * (y * -x); elseif (y <= 1.25e-7) tmp = x * (1.0 - (a * b)); else tmp = x * (y * -t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -1.1e+22], N[(t * N[(y * (-x)), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.25e-7], N[(x * N[(1.0 - N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(y * (-t)), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.1 \cdot 10^{+22}:\\
\;\;\;\;t \cdot \left(y \cdot \left(-x\right)\right)\\
\mathbf{elif}\;y \leq 1.25 \cdot 10^{-7}:\\
\;\;\;\;x \cdot \left(1 - a \cdot b\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(y \cdot \left(-t\right)\right)\\
\end{array}
\end{array}
if y < -1.1e22Initial program 98.1%
Taylor expanded in t around inf 61.2%
mul-1-neg61.2%
distribute-lft-neg-out61.2%
*-commutative61.2%
Simplified61.2%
Taylor expanded in y around 0 27.4%
mul-1-neg27.4%
unsub-neg27.4%
Simplified27.4%
Taylor expanded in t around inf 30.3%
mul-1-neg30.3%
distribute-rgt-neg-out30.3%
distribute-rgt-neg-in30.3%
Simplified30.3%
if -1.1e22 < y < 1.24999999999999994e-7Initial program 94.2%
Taylor expanded in y around 0 79.4%
sub-neg79.4%
log1p-define86.8%
Simplified86.8%
Taylor expanded in z around 0 86.8%
associate-*r*86.8%
associate-*r*86.8%
distribute-lft-out86.8%
mul-1-neg86.8%
Simplified86.8%
Taylor expanded in a around 0 43.8%
neg-mul-143.8%
distribute-rgt-neg-in43.8%
Simplified43.8%
Taylor expanded in z around 0 42.7%
mul-1-neg42.7%
unsub-neg42.7%
Simplified42.7%
if 1.24999999999999994e-7 < y Initial program 96.4%
Taylor expanded in t around inf 59.8%
mul-1-neg59.8%
distribute-lft-neg-out59.8%
*-commutative59.8%
Simplified59.8%
Taylor expanded in y around 0 22.0%
mul-1-neg22.0%
unsub-neg22.0%
Simplified22.0%
Taylor expanded in t around inf 26.6%
*-commutative26.6%
associate-*r*31.2%
neg-mul-131.2%
distribute-rgt-neg-in31.2%
*-commutative31.2%
distribute-rgt-neg-in31.2%
Simplified31.2%
Final simplification36.5%
(FPCore (x y z t a b) :precision binary64 (if (<= y -4.8e-42) (* t (- (/ x t) (* x y))) (if (<= y 0.044) (* x (- 1.0 (* a b))) (* x (* y (- t))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -4.8e-42) {
tmp = t * ((x / t) - (x * y));
} else if (y <= 0.044) {
tmp = x * (1.0 - (a * b));
} else {
tmp = x * (y * -t);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (y <= (-4.8d-42)) then
tmp = t * ((x / t) - (x * y))
else if (y <= 0.044d0) then
tmp = x * (1.0d0 - (a * b))
else
tmp = x * (y * -t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -4.8e-42) {
tmp = t * ((x / t) - (x * y));
} else if (y <= 0.044) {
tmp = x * (1.0 - (a * b));
} else {
tmp = x * (y * -t);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -4.8e-42: tmp = t * ((x / t) - (x * y)) elif y <= 0.044: tmp = x * (1.0 - (a * b)) else: tmp = x * (y * -t) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -4.8e-42) tmp = Float64(t * Float64(Float64(x / t) - Float64(x * y))); elseif (y <= 0.044) tmp = Float64(x * Float64(1.0 - Float64(a * b))); else tmp = Float64(x * Float64(y * Float64(-t))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (y <= -4.8e-42) tmp = t * ((x / t) - (x * y)); elseif (y <= 0.044) tmp = x * (1.0 - (a * b)); else tmp = x * (y * -t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -4.8e-42], N[(t * N[(N[(x / t), $MachinePrecision] - N[(x * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 0.044], N[(x * N[(1.0 - N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x * N[(y * (-t)), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.8 \cdot 10^{-42}:\\
\;\;\;\;t \cdot \left(\frac{x}{t} - x \cdot y\right)\\
\mathbf{elif}\;y \leq 0.044:\\
\;\;\;\;x \cdot \left(1 - a \cdot b\right)\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(y \cdot \left(-t\right)\right)\\
\end{array}
\end{array}
if y < -4.80000000000000005e-42Initial program 98.6%
Taylor expanded in t around inf 57.6%
mul-1-neg57.6%
distribute-lft-neg-out57.6%
*-commutative57.6%
Simplified57.6%
Taylor expanded in y around 0 26.5%
mul-1-neg26.5%
unsub-neg26.5%
Simplified26.5%
Taylor expanded in t around inf 29.0%
if -4.80000000000000005e-42 < y < 0.043999999999999997Initial program 93.3%
Taylor expanded in y around 0 83.1%
sub-neg83.1%
log1p-define90.8%
Simplified90.8%
Taylor expanded in z around 0 90.8%
associate-*r*90.8%
associate-*r*90.8%
distribute-lft-out90.8%
mul-1-neg90.8%
Simplified90.8%
Taylor expanded in a around 0 47.5%
neg-mul-147.5%
distribute-rgt-neg-in47.5%
Simplified47.5%
Taylor expanded in z around 0 46.2%
mul-1-neg46.2%
unsub-neg46.2%
Simplified46.2%
if 0.043999999999999997 < y Initial program 96.4%
Taylor expanded in t around inf 59.8%
mul-1-neg59.8%
distribute-lft-neg-out59.8%
*-commutative59.8%
Simplified59.8%
Taylor expanded in y around 0 22.0%
mul-1-neg22.0%
unsub-neg22.0%
Simplified22.0%
Taylor expanded in t around inf 26.6%
*-commutative26.6%
associate-*r*31.2%
neg-mul-131.2%
distribute-rgt-neg-in31.2%
*-commutative31.2%
distribute-rgt-neg-in31.2%
Simplified31.2%
Final simplification36.8%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -5.4e-42) (not (<= y 5.5e-5))) (* t (* y (- x))) x))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -5.4e-42) || !(y <= 5.5e-5)) {
tmp = t * (y * -x);
} else {
tmp = x;
}
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 <= (-5.4d-42)) .or. (.not. (y <= 5.5d-5))) then
tmp = t * (y * -x)
else
tmp = x
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 <= -5.4e-42) || !(y <= 5.5e-5)) {
tmp = t * (y * -x);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -5.4e-42) or not (y <= 5.5e-5): tmp = t * (y * -x) else: tmp = x return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -5.4e-42) || !(y <= 5.5e-5)) tmp = Float64(t * Float64(y * Float64(-x))); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -5.4e-42) || ~((y <= 5.5e-5))) tmp = t * (y * -x); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -5.4e-42], N[Not[LessEqual[y, 5.5e-5]], $MachinePrecision]], N[(t * N[(y * (-x)), $MachinePrecision]), $MachinePrecision], x]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.4 \cdot 10^{-42} \lor \neg \left(y \leq 5.5 \cdot 10^{-5}\right):\\
\;\;\;\;t \cdot \left(y \cdot \left(-x\right)\right)\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -5.39999999999999998e-42 or 5.5000000000000002e-5 < y Initial program 97.4%
Taylor expanded in t around inf 58.8%
mul-1-neg58.8%
distribute-lft-neg-out58.8%
*-commutative58.8%
Simplified58.8%
Taylor expanded in y around 0 24.1%
mul-1-neg24.1%
unsub-neg24.1%
Simplified24.1%
Taylor expanded in t around inf 27.2%
mul-1-neg27.2%
distribute-rgt-neg-out27.2%
distribute-rgt-neg-in27.2%
Simplified27.2%
if -5.39999999999999998e-42 < y < 5.5000000000000002e-5Initial program 93.3%
Taylor expanded in y around inf 53.7%
Taylor expanded in y around 0 37.3%
Final simplification31.3%
(FPCore (x y z t a b) :precision binary64 (if (<= y -5.4e-42) (* t (* y (- x))) (if (<= y 0.00032) x (* x (* y (- t))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -5.4e-42) {
tmp = t * (y * -x);
} else if (y <= 0.00032) {
tmp = x;
} else {
tmp = x * (y * -t);
}
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 <= (-5.4d-42)) then
tmp = t * (y * -x)
else if (y <= 0.00032d0) then
tmp = x
else
tmp = x * (y * -t)
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 <= -5.4e-42) {
tmp = t * (y * -x);
} else if (y <= 0.00032) {
tmp = x;
} else {
tmp = x * (y * -t);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -5.4e-42: tmp = t * (y * -x) elif y <= 0.00032: tmp = x else: tmp = x * (y * -t) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -5.4e-42) tmp = Float64(t * Float64(y * Float64(-x))); elseif (y <= 0.00032) tmp = x; else tmp = Float64(x * Float64(y * Float64(-t))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (y <= -5.4e-42) tmp = t * (y * -x); elseif (y <= 0.00032) tmp = x; else tmp = x * (y * -t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -5.4e-42], N[(t * N[(y * (-x)), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 0.00032], x, N[(x * N[(y * (-t)), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.4 \cdot 10^{-42}:\\
\;\;\;\;t \cdot \left(y \cdot \left(-x\right)\right)\\
\mathbf{elif}\;y \leq 0.00032:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(y \cdot \left(-t\right)\right)\\
\end{array}
\end{array}
if y < -5.39999999999999998e-42Initial program 98.6%
Taylor expanded in t around inf 57.6%
mul-1-neg57.6%
distribute-lft-neg-out57.6%
*-commutative57.6%
Simplified57.6%
Taylor expanded in y around 0 26.5%
mul-1-neg26.5%
unsub-neg26.5%
Simplified26.5%
Taylor expanded in t around inf 27.8%
mul-1-neg27.8%
distribute-rgt-neg-out27.8%
distribute-rgt-neg-in27.8%
Simplified27.8%
if -5.39999999999999998e-42 < y < 3.20000000000000026e-4Initial program 93.3%
Taylor expanded in y around inf 53.7%
Taylor expanded in y around 0 37.3%
if 3.20000000000000026e-4 < y Initial program 96.4%
Taylor expanded in t around inf 59.8%
mul-1-neg59.8%
distribute-lft-neg-out59.8%
*-commutative59.8%
Simplified59.8%
Taylor expanded in y around 0 22.0%
mul-1-neg22.0%
unsub-neg22.0%
Simplified22.0%
Taylor expanded in t around inf 26.6%
*-commutative26.6%
associate-*r*31.2%
neg-mul-131.2%
distribute-rgt-neg-in31.2%
*-commutative31.2%
distribute-rgt-neg-in31.2%
Simplified31.2%
Final simplification32.8%
(FPCore (x y z t a b) :precision binary64 (if (or (<= b -3e+133) (not (<= b 4.6e+184))) (* t (* x y)) x))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -3e+133) || !(b <= 4.6e+184)) {
tmp = t * (x * y);
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((b <= (-3d+133)) .or. (.not. (b <= 4.6d+184))) then
tmp = t * (x * y)
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((b <= -3e+133) || !(b <= 4.6e+184)) {
tmp = t * (x * y);
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (b <= -3e+133) or not (b <= 4.6e+184): tmp = t * (x * y) else: tmp = x return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((b <= -3e+133) || !(b <= 4.6e+184)) tmp = Float64(t * Float64(x * y)); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((b <= -3e+133) || ~((b <= 4.6e+184))) tmp = t * (x * y); else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[b, -3e+133], N[Not[LessEqual[b, 4.6e+184]], $MachinePrecision]], N[(t * N[(x * y), $MachinePrecision]), $MachinePrecision], x]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -3 \cdot 10^{+133} \lor \neg \left(b \leq 4.6 \cdot 10^{+184}\right):\\
\;\;\;\;t \cdot \left(x \cdot y\right)\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if b < -3.00000000000000007e133 or 4.6e184 < b Initial program 96.6%
Taylor expanded in t around inf 36.9%
mul-1-neg36.9%
distribute-lft-neg-out36.9%
*-commutative36.9%
Simplified36.9%
Taylor expanded in y around 0 13.4%
mul-1-neg13.4%
unsub-neg13.4%
Simplified13.4%
Taylor expanded in t around inf 26.9%
mul-1-neg26.9%
distribute-rgt-neg-out26.9%
distribute-rgt-neg-in26.9%
Simplified26.9%
pow126.9%
add-sqr-sqrt16.3%
sqrt-unprod33.1%
sqr-neg33.1%
sqrt-unprod8.6%
add-sqr-sqrt23.0%
Applied egg-rr23.0%
unpow123.0%
Simplified23.0%
if -3.00000000000000007e133 < b < 4.6e184Initial program 95.4%
Taylor expanded in y around inf 78.5%
Taylor expanded in y around 0 21.8%
Final simplification22.1%
(FPCore (x y z t a b) :precision binary64 (if (<= b -6.8e+127) (* t (* x y)) (if (<= b 1.35e+181) x (* x (* y t)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -6.8e+127) {
tmp = t * (x * y);
} else if (b <= 1.35e+181) {
tmp = x;
} else {
tmp = x * (y * t);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (b <= (-6.8d+127)) then
tmp = t * (x * y)
else if (b <= 1.35d+181) then
tmp = x
else
tmp = x * (y * t)
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -6.8e+127) {
tmp = t * (x * y);
} else if (b <= 1.35e+181) {
tmp = x;
} else {
tmp = x * (y * t);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -6.8e+127: tmp = t * (x * y) elif b <= 1.35e+181: tmp = x else: tmp = x * (y * t) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -6.8e+127) tmp = Float64(t * Float64(x * y)); elseif (b <= 1.35e+181) tmp = x; else tmp = Float64(x * Float64(y * t)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -6.8e+127) tmp = t * (x * y); elseif (b <= 1.35e+181) tmp = x; else tmp = x * (y * t); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -6.8e+127], N[(t * N[(x * y), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 1.35e+181], x, N[(x * N[(y * t), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -6.8 \cdot 10^{+127}:\\
\;\;\;\;t \cdot \left(x \cdot y\right)\\
\mathbf{elif}\;b \leq 1.35 \cdot 10^{+181}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;x \cdot \left(y \cdot t\right)\\
\end{array}
\end{array}
if b < -6.79999999999999955e127Initial program 97.0%
Taylor expanded in t around inf 41.5%
mul-1-neg41.5%
distribute-lft-neg-out41.5%
*-commutative41.5%
Simplified41.5%
Taylor expanded in y around 0 12.4%
mul-1-neg12.4%
unsub-neg12.4%
Simplified12.4%
Taylor expanded in t around inf 26.7%
mul-1-neg26.7%
distribute-rgt-neg-out26.7%
distribute-rgt-neg-in26.7%
Simplified26.7%
pow126.7%
add-sqr-sqrt19.3%
sqrt-unprod34.9%
sqr-neg34.9%
sqrt-unprod4.0%
add-sqr-sqrt23.0%
Applied egg-rr23.0%
unpow123.0%
Simplified23.0%
if -6.79999999999999955e127 < b < 1.35000000000000004e181Initial program 95.4%
Taylor expanded in y around inf 78.5%
Taylor expanded in y around 0 21.8%
if 1.35000000000000004e181 < b Initial program 96.0%
Taylor expanded in t around inf 30.8%
mul-1-neg30.8%
distribute-lft-neg-out30.8%
*-commutative30.8%
Simplified30.8%
Taylor expanded in y around 0 14.6%
mul-1-neg14.6%
unsub-neg14.6%
Simplified14.6%
Taylor expanded in t around inf 27.1%
mul-1-neg27.1%
distribute-rgt-neg-out27.1%
distribute-rgt-neg-in27.1%
Simplified27.1%
pow127.1%
add-sqr-sqrt12.4%
sqrt-unprod30.7%
sqr-neg30.7%
sqrt-unprod14.7%
add-sqr-sqrt23.0%
Applied egg-rr23.0%
unpow123.0%
associate-*r*26.9%
*-commutative26.9%
associate-*r*23.1%
Simplified23.1%
Final simplification22.1%
(FPCore (x y z t a b) :precision binary64 (* y (/ x y)))
double code(double x, double y, double z, double t, double a, double b) {
return y * (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 = y * (x / y)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return y * (x / y);
}
def code(x, y, z, t, a, b): return y * (x / y)
function code(x, y, z, t, a, b) return Float64(y * Float64(x / y)) end
function tmp = code(x, y, z, t, a, b) tmp = y * (x / y); end
code[x_, y_, z_, t_, a_, b_] := N[(y * N[(x / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
y \cdot \frac{x}{y}
\end{array}
Initial program 95.7%
Taylor expanded in t around inf 56.7%
mul-1-neg56.7%
distribute-lft-neg-out56.7%
*-commutative56.7%
Simplified56.7%
Taylor expanded in y around 0 29.8%
mul-1-neg29.8%
unsub-neg29.8%
Simplified29.8%
Taylor expanded in y around inf 28.7%
*-commutative28.7%
Simplified28.7%
Taylor expanded in y around 0 22.2%
Final simplification22.2%
(FPCore (x y z t a b) :precision binary64 x)
double code(double x, double y, double z, double t, double a, double b) {
return x;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = x
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x;
}
def code(x, y, z, t, a, b): return x
function code(x, y, z, t, a, b) return x end
function tmp = code(x, y, z, t, a, b) tmp = x; end
code[x_, y_, z_, t_, a_, b_] := x
\begin{array}{l}
\\
x
\end{array}
Initial program 95.7%
Taylor expanded in y around inf 73.1%
Taylor expanded in y around 0 18.2%
Final simplification18.2%
herbie shell --seed 2024055
(FPCore (x y z t a b)
:name "Numeric.SpecFunctions:incompleteBetaApprox from math-functions-0.1.5.2, B"
:precision binary64
(* x (exp (+ (* y (- (log z) t)) (* a (- (log (- 1.0 z)) b))))))