
(FPCore (x y z t a b c)
:precision binary64
(/
x
(+
x
(*
y
(exp
(*
2.0
(-
(/ (* z (sqrt (+ t a))) t)
(* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0)))))))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
return x / (x + (y * exp((2.0 * (((z * sqrt((t + a))) / t) - ((b - c) * ((a + (5.0 / 6.0)) - (2.0 / (t * 3.0)))))))));
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
code = x / (x + (y * exp((2.0d0 * (((z * sqrt((t + a))) / t) - ((b - c) * ((a + (5.0d0 / 6.0d0)) - (2.0d0 / (t * 3.0d0)))))))))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
return x / (x + (y * Math.exp((2.0 * (((z * Math.sqrt((t + a))) / t) - ((b - c) * ((a + (5.0 / 6.0)) - (2.0 / (t * 3.0)))))))));
}
def code(x, y, z, t, a, b, c): return x / (x + (y * math.exp((2.0 * (((z * math.sqrt((t + a))) / t) - ((b - c) * ((a + (5.0 / 6.0)) - (2.0 / (t * 3.0)))))))))
function code(x, y, z, t, a, b, c) return Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(Float64(Float64(z * sqrt(Float64(t + a))) / t) - Float64(Float64(b - c) * Float64(Float64(a + Float64(5.0 / 6.0)) - Float64(2.0 / Float64(t * 3.0)))))))))) end
function tmp = code(x, y, z, t, a, b, c) tmp = x / (x + (y * exp((2.0 * (((z * sqrt((t + a))) / t) - ((b - c) * ((a + (5.0 / 6.0)) - (2.0 / (t * 3.0))))))))); end
code[x_, y_, z_, t_, a_, b_, c_] := N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(N[(N[(z * N[Sqrt[N[(t + a), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision] - N[(N[(b - c), $MachinePrecision] * N[(N[(a + N[(5.0 / 6.0), $MachinePrecision]), $MachinePrecision] - N[(2.0 / N[(t * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{x + y \cdot e^{2 \cdot \left(\frac{z \cdot \sqrt{t + a}}{t} - \left(b - c\right) \cdot \left(\left(a + \frac{5}{6}\right) - \frac{2}{t \cdot 3}\right)\right)}}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 18 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b c)
:precision binary64
(/
x
(+
x
(*
y
(exp
(*
2.0
(-
(/ (* z (sqrt (+ t a))) t)
(* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0)))))))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
return x / (x + (y * exp((2.0 * (((z * sqrt((t + a))) / t) - ((b - c) * ((a + (5.0 / 6.0)) - (2.0 / (t * 3.0)))))))));
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
code = x / (x + (y * exp((2.0d0 * (((z * sqrt((t + a))) / t) - ((b - c) * ((a + (5.0d0 / 6.0d0)) - (2.0d0 / (t * 3.0d0)))))))))
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
return x / (x + (y * Math.exp((2.0 * (((z * Math.sqrt((t + a))) / t) - ((b - c) * ((a + (5.0 / 6.0)) - (2.0 / (t * 3.0)))))))));
}
def code(x, y, z, t, a, b, c): return x / (x + (y * math.exp((2.0 * (((z * math.sqrt((t + a))) / t) - ((b - c) * ((a + (5.0 / 6.0)) - (2.0 / (t * 3.0)))))))))
function code(x, y, z, t, a, b, c) return Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(Float64(Float64(z * sqrt(Float64(t + a))) / t) - Float64(Float64(b - c) * Float64(Float64(a + Float64(5.0 / 6.0)) - Float64(2.0 / Float64(t * 3.0)))))))))) end
function tmp = code(x, y, z, t, a, b, c) tmp = x / (x + (y * exp((2.0 * (((z * sqrt((t + a))) / t) - ((b - c) * ((a + (5.0 / 6.0)) - (2.0 / (t * 3.0))))))))); end
code[x_, y_, z_, t_, a_, b_, c_] := N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(N[(N[(z * N[Sqrt[N[(t + a), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision] - N[(N[(b - c), $MachinePrecision] * N[(N[(a + N[(5.0 / 6.0), $MachinePrecision]), $MachinePrecision] - N[(2.0 / N[(t * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{x + y \cdot e^{2 \cdot \left(\frac{z \cdot \sqrt{t + a}}{t} - \left(b - c\right) \cdot \left(\left(a + \frac{5}{6}\right) - \frac{2}{t \cdot 3}\right)\right)}}
\end{array}
(FPCore (x y z t a b c)
:precision binary64
(let* ((t_1
(+
(/ (* z (sqrt (+ t a))) t)
(* (- (+ a 0.8333333333333334) (/ 2.0 (* t 3.0))) (- c b)))))
(if (<= t_1 INFINITY)
(/ x (+ x (* y (exp (* 2.0 t_1)))))
(/
x
(+
x
(*
y
(exp
(*
2.0
(/ (+ (* z (sqrt a)) (* -0.6666666666666666 (- c b))) t)))))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = ((z * sqrt((t + a))) / t) + (((a + 0.8333333333333334) - (2.0 / (t * 3.0))) * (c - b));
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = x / (x + (y * exp((2.0 * t_1))));
} else {
tmp = x / (x + (y * exp((2.0 * (((z * sqrt(a)) + (-0.6666666666666666 * (c - b))) / t)))));
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = ((z * Math.sqrt((t + a))) / t) + (((a + 0.8333333333333334) - (2.0 / (t * 3.0))) * (c - b));
double tmp;
if (t_1 <= Double.POSITIVE_INFINITY) {
tmp = x / (x + (y * Math.exp((2.0 * t_1))));
} else {
tmp = x / (x + (y * Math.exp((2.0 * (((z * Math.sqrt(a)) + (-0.6666666666666666 * (c - b))) / t)))));
}
return tmp;
}
def code(x, y, z, t, a, b, c): t_1 = ((z * math.sqrt((t + a))) / t) + (((a + 0.8333333333333334) - (2.0 / (t * 3.0))) * (c - b)) tmp = 0 if t_1 <= math.inf: tmp = x / (x + (y * math.exp((2.0 * t_1)))) else: tmp = x / (x + (y * math.exp((2.0 * (((z * math.sqrt(a)) + (-0.6666666666666666 * (c - b))) / t))))) return tmp
function code(x, y, z, t, a, b, c) t_1 = Float64(Float64(Float64(z * sqrt(Float64(t + a))) / t) + Float64(Float64(Float64(a + 0.8333333333333334) - Float64(2.0 / Float64(t * 3.0))) * Float64(c - b))) tmp = 0.0 if (t_1 <= Inf) tmp = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * t_1))))); else tmp = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(Float64(Float64(z * sqrt(a)) + Float64(-0.6666666666666666 * Float64(c - b))) / t)))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) t_1 = ((z * sqrt((t + a))) / t) + (((a + 0.8333333333333334) - (2.0 / (t * 3.0))) * (c - b)); tmp = 0.0; if (t_1 <= Inf) tmp = x / (x + (y * exp((2.0 * t_1)))); else tmp = x / (x + (y * exp((2.0 * (((z * sqrt(a)) + (-0.6666666666666666 * (c - b))) / t))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(N[(N[(z * N[Sqrt[N[(t + a), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision] + N[(N[(N[(a + 0.8333333333333334), $MachinePrecision] - N[(2.0 / N[(t * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(c - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], N[(x / N[(x + N[(y * N[Exp[N[(2.0 * t$95$1), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(N[(N[(z * N[Sqrt[a], $MachinePrecision]), $MachinePrecision] + N[(-0.6666666666666666 * N[(c - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{z \cdot \sqrt{t + a}}{t} + \left(\left(a + 0.8333333333333334\right) - \frac{2}{t \cdot 3}\right) \cdot \left(c - b\right)\\
\mathbf{if}\;t\_1 \leq \infty:\\
\;\;\;\;\frac{x}{x + y \cdot e^{2 \cdot t\_1}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{2 \cdot \frac{z \cdot \sqrt{a} + -0.6666666666666666 \cdot \left(c - b\right)}{t}}}\\
\end{array}
\end{array}
if (-.f64 (/.f64 (*.f64 z (sqrt.f64 (+.f64 t a))) t) (*.f64 (-.f64 b c) (-.f64 (+.f64 a (/.f64 #s(literal 5 binary64) #s(literal 6 binary64))) (/.f64 #s(literal 2 binary64) (*.f64 t #s(literal 3 binary64)))))) < +inf.0Initial program 99.2%
if +inf.0 < (-.f64 (/.f64 (*.f64 z (sqrt.f64 (+.f64 t a))) t) (*.f64 (-.f64 b c) (-.f64 (+.f64 a (/.f64 #s(literal 5 binary64) #s(literal 6 binary64))) (/.f64 #s(literal 2 binary64) (*.f64 t #s(literal 3 binary64)))))) Initial program 0.0%
Taylor expanded in t around 0 72.1%
Final simplification97.7%
(FPCore (x y z t a b c)
:precision binary64
(/
x
(fma
y
(pow
(exp 2.0)
(fma
z
(/ (sqrt (+ t a)) t)
(* (- b c) (- (- (/ 0.6666666666666666 t) 0.8333333333333334) a))))
x)))
double code(double x, double y, double z, double t, double a, double b, double c) {
return x / fma(y, pow(exp(2.0), fma(z, (sqrt((t + a)) / t), ((b - c) * (((0.6666666666666666 / t) - 0.8333333333333334) - a)))), x);
}
function code(x, y, z, t, a, b, c) return Float64(x / fma(y, (exp(2.0) ^ fma(z, Float64(sqrt(Float64(t + a)) / t), Float64(Float64(b - c) * Float64(Float64(Float64(0.6666666666666666 / t) - 0.8333333333333334) - a)))), x)) end
code[x_, y_, z_, t_, a_, b_, c_] := N[(x / N[(y * N[Power[N[Exp[2.0], $MachinePrecision], N[(z * N[(N[Sqrt[N[(t + a), $MachinePrecision]], $MachinePrecision] / t), $MachinePrecision] + N[(N[(b - c), $MachinePrecision] * N[(N[(N[(0.6666666666666666 / t), $MachinePrecision] - 0.8333333333333334), $MachinePrecision] - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] + x), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{\mathsf{fma}\left(y, {\left(e^{2}\right)}^{\left(\mathsf{fma}\left(z, \frac{\sqrt{t + a}}{t}, \left(b - c\right) \cdot \left(\left(\frac{0.6666666666666666}{t} - 0.8333333333333334\right) - a\right)\right)\right)}, x\right)}
\end{array}
Initial program 93.8%
Simplified96.5%
Final simplification96.5%
(FPCore (x y z t a b c)
:precision binary64
(if (or (<= b -8e+32) (not (<= b 1.75e+75)))
(/
x
(+
x
(*
y
(exp
(* 2.0 (* b (- (/ 0.6666666666666666 t) (+ a 0.8333333333333334))))))))
(/
x
(+ x (* y (exp (* 2.0 (+ (/ (* z (sqrt (+ t a))) t) (* a (- c b))))))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((b <= -8e+32) || !(b <= 1.75e+75)) {
tmp = x / (x + (y * exp((2.0 * (b * ((0.6666666666666666 / t) - (a + 0.8333333333333334)))))));
} else {
tmp = x / (x + (y * exp((2.0 * (((z * sqrt((t + a))) / t) + (a * (c - b)))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if ((b <= (-8d+32)) .or. (.not. (b <= 1.75d+75))) then
tmp = x / (x + (y * exp((2.0d0 * (b * ((0.6666666666666666d0 / t) - (a + 0.8333333333333334d0)))))))
else
tmp = x / (x + (y * exp((2.0d0 * (((z * sqrt((t + a))) / t) + (a * (c - b)))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((b <= -8e+32) || !(b <= 1.75e+75)) {
tmp = x / (x + (y * Math.exp((2.0 * (b * ((0.6666666666666666 / t) - (a + 0.8333333333333334)))))));
} else {
tmp = x / (x + (y * Math.exp((2.0 * (((z * Math.sqrt((t + a))) / t) + (a * (c - b)))))));
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if (b <= -8e+32) or not (b <= 1.75e+75): tmp = x / (x + (y * math.exp((2.0 * (b * ((0.6666666666666666 / t) - (a + 0.8333333333333334))))))) else: tmp = x / (x + (y * math.exp((2.0 * (((z * math.sqrt((t + a))) / t) + (a * (c - b))))))) return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if ((b <= -8e+32) || !(b <= 1.75e+75)) tmp = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(b * Float64(Float64(0.6666666666666666 / t) - Float64(a + 0.8333333333333334)))))))); else tmp = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(Float64(Float64(z * sqrt(Float64(t + a))) / t) + Float64(a * Float64(c - b)))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if ((b <= -8e+32) || ~((b <= 1.75e+75))) tmp = x / (x + (y * exp((2.0 * (b * ((0.6666666666666666 / t) - (a + 0.8333333333333334))))))); else tmp = x / (x + (y * exp((2.0 * (((z * sqrt((t + a))) / t) + (a * (c - b))))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[b, -8e+32], N[Not[LessEqual[b, 1.75e+75]], $MachinePrecision]], N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(b * N[(N[(0.6666666666666666 / t), $MachinePrecision] - N[(a + 0.8333333333333334), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(N[(N[(z * N[Sqrt[N[(t + a), $MachinePrecision]], $MachinePrecision]), $MachinePrecision] / t), $MachinePrecision] + N[(a * N[(c - b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -8 \cdot 10^{+32} \lor \neg \left(b \leq 1.75 \cdot 10^{+75}\right):\\
\;\;\;\;\frac{x}{x + y \cdot e^{2 \cdot \left(b \cdot \left(\frac{0.6666666666666666}{t} - \left(a + 0.8333333333333334\right)\right)\right)}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{2 \cdot \left(\frac{z \cdot \sqrt{t + a}}{t} + a \cdot \left(c - b\right)\right)}}\\
\end{array}
\end{array}
if b < -8.00000000000000043e32 or 1.7499999999999999e75 < b Initial program 90.4%
Taylor expanded in b around inf 89.0%
associate-*r/89.0%
metadata-eval89.0%
+-commutative89.0%
Simplified89.0%
if -8.00000000000000043e32 < b < 1.7499999999999999e75Initial program 96.5%
Taylor expanded in a around inf 82.9%
Final simplification85.6%
(FPCore (x y z t a b c)
:precision binary64
(let* ((t_1 (/ x (+ x (* y (exp (* 2.0 (* b (- -0.8333333333333334 a)))))))))
(if (<= b -7e+188)
t_1
(if (<= b -410000.0)
(/ x (+ x (* y (exp (* 1.3333333333333333 (/ b t))))))
(if (<= b 0.024)
(/ x (+ x (* y (exp (* 2.0 (* c (+ a 0.8333333333333334)))))))
t_1)))))
double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = x / (x + (y * exp((2.0 * (b * (-0.8333333333333334 - a))))));
double tmp;
if (b <= -7e+188) {
tmp = t_1;
} else if (b <= -410000.0) {
tmp = x / (x + (y * exp((1.3333333333333333 * (b / t)))));
} else if (b <= 0.024) {
tmp = x / (x + (y * exp((2.0 * (c * (a + 0.8333333333333334))))));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: t_1
real(8) :: tmp
t_1 = x / (x + (y * exp((2.0d0 * (b * ((-0.8333333333333334d0) - a))))))
if (b <= (-7d+188)) then
tmp = t_1
else if (b <= (-410000.0d0)) then
tmp = x / (x + (y * exp((1.3333333333333333d0 * (b / t)))))
else if (b <= 0.024d0) then
tmp = x / (x + (y * exp((2.0d0 * (c * (a + 0.8333333333333334d0))))))
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 c) {
double t_1 = x / (x + (y * Math.exp((2.0 * (b * (-0.8333333333333334 - a))))));
double tmp;
if (b <= -7e+188) {
tmp = t_1;
} else if (b <= -410000.0) {
tmp = x / (x + (y * Math.exp((1.3333333333333333 * (b / t)))));
} else if (b <= 0.024) {
tmp = x / (x + (y * Math.exp((2.0 * (c * (a + 0.8333333333333334))))));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b, c): t_1 = x / (x + (y * math.exp((2.0 * (b * (-0.8333333333333334 - a)))))) tmp = 0 if b <= -7e+188: tmp = t_1 elif b <= -410000.0: tmp = x / (x + (y * math.exp((1.3333333333333333 * (b / t))))) elif b <= 0.024: tmp = x / (x + (y * math.exp((2.0 * (c * (a + 0.8333333333333334)))))) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b, c) t_1 = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(b * Float64(-0.8333333333333334 - a))))))) tmp = 0.0 if (b <= -7e+188) tmp = t_1; elseif (b <= -410000.0) tmp = Float64(x / Float64(x + Float64(y * exp(Float64(1.3333333333333333 * Float64(b / t)))))); elseif (b <= 0.024) tmp = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(c * Float64(a + 0.8333333333333334))))))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) t_1 = x / (x + (y * exp((2.0 * (b * (-0.8333333333333334 - a)))))); tmp = 0.0; if (b <= -7e+188) tmp = t_1; elseif (b <= -410000.0) tmp = x / (x + (y * exp((1.3333333333333333 * (b / t))))); elseif (b <= 0.024) tmp = x / (x + (y * exp((2.0 * (c * (a + 0.8333333333333334)))))); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(b * N[(-0.8333333333333334 - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[b, -7e+188], t$95$1, If[LessEqual[b, -410000.0], N[(x / N[(x + N[(y * N[Exp[N[(1.3333333333333333 * N[(b / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 0.024], N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(c * N[(a + 0.8333333333333334), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{x + y \cdot e^{2 \cdot \left(b \cdot \left(-0.8333333333333334 - a\right)\right)}}\\
\mathbf{if}\;b \leq -7 \cdot 10^{+188}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;b \leq -410000:\\
\;\;\;\;\frac{x}{x + y \cdot e^{1.3333333333333333 \cdot \frac{b}{t}}}\\
\mathbf{elif}\;b \leq 0.024:\\
\;\;\;\;\frac{x}{x + y \cdot e^{2 \cdot \left(c \cdot \left(a + 0.8333333333333334\right)\right)}}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if b < -7.00000000000000016e188 or 0.024 < b Initial program 88.3%
Taylor expanded in b around inf 84.5%
associate-*r/84.5%
metadata-eval84.5%
+-commutative84.5%
Simplified84.5%
Taylor expanded in t around inf 71.1%
mul-1-neg71.1%
+-commutative71.1%
distribute-rgt-neg-in71.1%
+-commutative71.1%
distribute-neg-in71.1%
unsub-neg71.1%
metadata-eval71.1%
Simplified71.1%
if -7.00000000000000016e188 < b < -4.1e5Initial program 92.1%
Taylor expanded in t around 0 58.5%
Taylor expanded in b around inf 79.7%
*-commutative79.7%
Simplified79.7%
Taylor expanded in b around inf 79.7%
if -4.1e5 < b < 0.024Initial program 98.4%
Taylor expanded in c around inf 76.7%
+-commutative76.7%
associate-*r/76.7%
metadata-eval76.7%
associate-+r-76.7%
Simplified76.7%
Taylor expanded in t around inf 68.1%
+-commutative68.1%
Simplified68.1%
(FPCore (x y z t a b c)
:precision binary64
(if (or (<= b -255000.0) (not (<= b 2e+89)))
(/
x
(+
x
(*
y
(exp
(* 2.0 (* b (- (/ 0.6666666666666666 t) (+ a 0.8333333333333334))))))))
(/
x
(+
x
(*
y
(exp
(*
2.0
(* (+ a (- 0.8333333333333334 (/ 0.6666666666666666 t))) c))))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((b <= -255000.0) || !(b <= 2e+89)) {
tmp = x / (x + (y * exp((2.0 * (b * ((0.6666666666666666 / t) - (a + 0.8333333333333334)))))));
} else {
tmp = x / (x + (y * exp((2.0 * ((a + (0.8333333333333334 - (0.6666666666666666 / t))) * c)))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if ((b <= (-255000.0d0)) .or. (.not. (b <= 2d+89))) then
tmp = x / (x + (y * exp((2.0d0 * (b * ((0.6666666666666666d0 / t) - (a + 0.8333333333333334d0)))))))
else
tmp = x / (x + (y * exp((2.0d0 * ((a + (0.8333333333333334d0 - (0.6666666666666666d0 / t))) * c)))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((b <= -255000.0) || !(b <= 2e+89)) {
tmp = x / (x + (y * Math.exp((2.0 * (b * ((0.6666666666666666 / t) - (a + 0.8333333333333334)))))));
} else {
tmp = x / (x + (y * Math.exp((2.0 * ((a + (0.8333333333333334 - (0.6666666666666666 / t))) * c)))));
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if (b <= -255000.0) or not (b <= 2e+89): tmp = x / (x + (y * math.exp((2.0 * (b * ((0.6666666666666666 / t) - (a + 0.8333333333333334))))))) else: tmp = x / (x + (y * math.exp((2.0 * ((a + (0.8333333333333334 - (0.6666666666666666 / t))) * c))))) return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if ((b <= -255000.0) || !(b <= 2e+89)) tmp = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(b * Float64(Float64(0.6666666666666666 / t) - Float64(a + 0.8333333333333334)))))))); else tmp = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(Float64(a + Float64(0.8333333333333334 - Float64(0.6666666666666666 / t))) * c)))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if ((b <= -255000.0) || ~((b <= 2e+89))) tmp = x / (x + (y * exp((2.0 * (b * ((0.6666666666666666 / t) - (a + 0.8333333333333334))))))); else tmp = x / (x + (y * exp((2.0 * ((a + (0.8333333333333334 - (0.6666666666666666 / t))) * c))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[b, -255000.0], N[Not[LessEqual[b, 2e+89]], $MachinePrecision]], N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(b * N[(N[(0.6666666666666666 / t), $MachinePrecision] - N[(a + 0.8333333333333334), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(N[(a + N[(0.8333333333333334 - N[(0.6666666666666666 / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * c), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -255000 \lor \neg \left(b \leq 2 \cdot 10^{+89}\right):\\
\;\;\;\;\frac{x}{x + y \cdot e^{2 \cdot \left(b \cdot \left(\frac{0.6666666666666666}{t} - \left(a + 0.8333333333333334\right)\right)\right)}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{2 \cdot \left(\left(a + \left(0.8333333333333334 - \frac{0.6666666666666666}{t}\right)\right) \cdot c\right)}}\\
\end{array}
\end{array}
if b < -255000 or 1.99999999999999999e89 < b Initial program 91.4%
Taylor expanded in b around inf 89.1%
associate-*r/89.1%
metadata-eval89.1%
+-commutative89.1%
Simplified89.1%
if -255000 < b < 1.99999999999999999e89Initial program 95.7%
Taylor expanded in c around inf 75.9%
+-commutative75.9%
associate-*r/75.9%
metadata-eval75.9%
associate-+r-75.9%
Simplified75.9%
Final simplification81.9%
(FPCore (x y z t a b c)
:precision binary64
(if (or (<= b -1.55e-12) (not (<= b 1.8e+89)))
(/
x
(+
x
(*
y
(exp
(* 2.0 (* b (- (/ 0.6666666666666666 t) (+ a 0.8333333333333334))))))))
(/ x (+ x (* y (exp (* 2.0 (* c (+ a 0.8333333333333334)))))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((b <= -1.55e-12) || !(b <= 1.8e+89)) {
tmp = x / (x + (y * exp((2.0 * (b * ((0.6666666666666666 / t) - (a + 0.8333333333333334)))))));
} else {
tmp = x / (x + (y * exp((2.0 * (c * (a + 0.8333333333333334))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if ((b <= (-1.55d-12)) .or. (.not. (b <= 1.8d+89))) then
tmp = x / (x + (y * exp((2.0d0 * (b * ((0.6666666666666666d0 / t) - (a + 0.8333333333333334d0)))))))
else
tmp = x / (x + (y * exp((2.0d0 * (c * (a + 0.8333333333333334d0))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if ((b <= -1.55e-12) || !(b <= 1.8e+89)) {
tmp = x / (x + (y * Math.exp((2.0 * (b * ((0.6666666666666666 / t) - (a + 0.8333333333333334)))))));
} else {
tmp = x / (x + (y * Math.exp((2.0 * (c * (a + 0.8333333333333334))))));
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if (b <= -1.55e-12) or not (b <= 1.8e+89): tmp = x / (x + (y * math.exp((2.0 * (b * ((0.6666666666666666 / t) - (a + 0.8333333333333334))))))) else: tmp = x / (x + (y * math.exp((2.0 * (c * (a + 0.8333333333333334)))))) return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if ((b <= -1.55e-12) || !(b <= 1.8e+89)) tmp = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(b * Float64(Float64(0.6666666666666666 / t) - Float64(a + 0.8333333333333334)))))))); else tmp = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(c * Float64(a + 0.8333333333333334))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if ((b <= -1.55e-12) || ~((b <= 1.8e+89))) tmp = x / (x + (y * exp((2.0 * (b * ((0.6666666666666666 / t) - (a + 0.8333333333333334))))))); else tmp = x / (x + (y * exp((2.0 * (c * (a + 0.8333333333333334)))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[Or[LessEqual[b, -1.55e-12], N[Not[LessEqual[b, 1.8e+89]], $MachinePrecision]], N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(b * N[(N[(0.6666666666666666 / t), $MachinePrecision] - N[(a + 0.8333333333333334), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(c * N[(a + 0.8333333333333334), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.55 \cdot 10^{-12} \lor \neg \left(b \leq 1.8 \cdot 10^{+89}\right):\\
\;\;\;\;\frac{x}{x + y \cdot e^{2 \cdot \left(b \cdot \left(\frac{0.6666666666666666}{t} - \left(a + 0.8333333333333334\right)\right)\right)}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{2 \cdot \left(c \cdot \left(a + 0.8333333333333334\right)\right)}}\\
\end{array}
\end{array}
if b < -1.5500000000000001e-12 or 1.8e89 < b Initial program 91.6%
Taylor expanded in b around inf 87.8%
associate-*r/87.8%
metadata-eval87.8%
+-commutative87.8%
Simplified87.8%
if -1.5500000000000001e-12 < b < 1.8e89Initial program 95.6%
Taylor expanded in c around inf 76.1%
+-commutative76.1%
associate-*r/76.1%
metadata-eval76.1%
associate-+r-76.1%
Simplified76.1%
Taylor expanded in t around inf 68.3%
+-commutative68.3%
Simplified68.3%
Final simplification77.3%
(FPCore (x y z t a b c)
:precision binary64
(if (<= t 2e-6)
(/ x (+ x (* y (exp (* 1.3333333333333333 (/ b t))))))
(if (<= t 1.1e+139)
(/ x (+ x (* y (exp (* b -1.6666666666666667)))))
(/ x (+ x (* y (exp (* c 1.6666666666666667))))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (t <= 2e-6) {
tmp = x / (x + (y * exp((1.3333333333333333 * (b / t)))));
} else if (t <= 1.1e+139) {
tmp = x / (x + (y * exp((b * -1.6666666666666667))));
} else {
tmp = x / (x + (y * exp((c * 1.6666666666666667))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if (t <= 2d-6) then
tmp = x / (x + (y * exp((1.3333333333333333d0 * (b / t)))))
else if (t <= 1.1d+139) then
tmp = x / (x + (y * exp((b * (-1.6666666666666667d0)))))
else
tmp = x / (x + (y * exp((c * 1.6666666666666667d0))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (t <= 2e-6) {
tmp = x / (x + (y * Math.exp((1.3333333333333333 * (b / t)))));
} else if (t <= 1.1e+139) {
tmp = x / (x + (y * Math.exp((b * -1.6666666666666667))));
} else {
tmp = x / (x + (y * Math.exp((c * 1.6666666666666667))));
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if t <= 2e-6: tmp = x / (x + (y * math.exp((1.3333333333333333 * (b / t))))) elif t <= 1.1e+139: tmp = x / (x + (y * math.exp((b * -1.6666666666666667)))) else: tmp = x / (x + (y * math.exp((c * 1.6666666666666667)))) return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if (t <= 2e-6) tmp = Float64(x / Float64(x + Float64(y * exp(Float64(1.3333333333333333 * Float64(b / t)))))); elseif (t <= 1.1e+139) tmp = Float64(x / Float64(x + Float64(y * exp(Float64(b * -1.6666666666666667))))); else tmp = Float64(x / Float64(x + Float64(y * exp(Float64(c * 1.6666666666666667))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if (t <= 2e-6) tmp = x / (x + (y * exp((1.3333333333333333 * (b / t))))); elseif (t <= 1.1e+139) tmp = x / (x + (y * exp((b * -1.6666666666666667)))); else tmp = x / (x + (y * exp((c * 1.6666666666666667)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[t, 2e-6], N[(x / N[(x + N[(y * N[Exp[N[(1.3333333333333333 * N[(b / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 1.1e+139], N[(x / N[(x + N[(y * N[Exp[N[(b * -1.6666666666666667), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(x + N[(y * N[Exp[N[(c * 1.6666666666666667), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq 2 \cdot 10^{-6}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{1.3333333333333333 \cdot \frac{b}{t}}}\\
\mathbf{elif}\;t \leq 1.1 \cdot 10^{+139}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{b \cdot -1.6666666666666667}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{c \cdot 1.6666666666666667}}\\
\end{array}
\end{array}
if t < 1.99999999999999991e-6Initial program 91.3%
Taylor expanded in t around 0 70.5%
Taylor expanded in b around inf 64.9%
*-commutative64.9%
Simplified64.9%
Taylor expanded in b around inf 64.9%
if 1.99999999999999991e-6 < t < 1.1e139Initial program 100.0%
Taylor expanded in b around inf 75.8%
associate-*r/75.8%
metadata-eval75.8%
+-commutative75.8%
Simplified75.8%
Taylor expanded in t around inf 75.8%
mul-1-neg75.8%
+-commutative75.8%
distribute-rgt-neg-in75.8%
+-commutative75.8%
distribute-neg-in75.8%
unsub-neg75.8%
metadata-eval75.8%
Simplified75.8%
Taylor expanded in a around 0 70.7%
*-commutative70.7%
Simplified70.7%
if 1.1e139 < t Initial program 94.4%
Taylor expanded in c around inf 68.6%
+-commutative68.6%
associate-*r/68.6%
metadata-eval68.6%
associate-+r-68.6%
Simplified68.6%
Taylor expanded in t around inf 68.6%
+-commutative68.6%
Simplified68.6%
Taylor expanded in a around 0 65.8%
Final simplification66.2%
(FPCore (x y z t a b c)
:precision binary64
(if (<= c -2e+90)
1.0
(if (<= c 3.1e+122)
(/ x (+ x (* y (exp (* b -1.6666666666666667)))))
(/ x (+ x (* y (exp (* c 1.6666666666666667))))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (c <= -2e+90) {
tmp = 1.0;
} else if (c <= 3.1e+122) {
tmp = x / (x + (y * exp((b * -1.6666666666666667))));
} else {
tmp = x / (x + (y * exp((c * 1.6666666666666667))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if (c <= (-2d+90)) then
tmp = 1.0d0
else if (c <= 3.1d+122) then
tmp = x / (x + (y * exp((b * (-1.6666666666666667d0)))))
else
tmp = x / (x + (y * exp((c * 1.6666666666666667d0))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (c <= -2e+90) {
tmp = 1.0;
} else if (c <= 3.1e+122) {
tmp = x / (x + (y * Math.exp((b * -1.6666666666666667))));
} else {
tmp = x / (x + (y * Math.exp((c * 1.6666666666666667))));
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if c <= -2e+90: tmp = 1.0 elif c <= 3.1e+122: tmp = x / (x + (y * math.exp((b * -1.6666666666666667)))) else: tmp = x / (x + (y * math.exp((c * 1.6666666666666667)))) return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if (c <= -2e+90) tmp = 1.0; elseif (c <= 3.1e+122) tmp = Float64(x / Float64(x + Float64(y * exp(Float64(b * -1.6666666666666667))))); else tmp = Float64(x / Float64(x + Float64(y * exp(Float64(c * 1.6666666666666667))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if (c <= -2e+90) tmp = 1.0; elseif (c <= 3.1e+122) tmp = x / (x + (y * exp((b * -1.6666666666666667)))); else tmp = x / (x + (y * exp((c * 1.6666666666666667)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[c, -2e+90], 1.0, If[LessEqual[c, 3.1e+122], N[(x / N[(x + N[(y * N[Exp[N[(b * -1.6666666666666667), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(x + N[(y * N[Exp[N[(c * 1.6666666666666667), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;c \leq -2 \cdot 10^{+90}:\\
\;\;\;\;1\\
\mathbf{elif}\;c \leq 3.1 \cdot 10^{+122}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{b \cdot -1.6666666666666667}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{c \cdot 1.6666666666666667}}\\
\end{array}
\end{array}
if c < -1.99999999999999993e90Initial program 93.2%
Simplified93.3%
Taylor expanded in x around inf 69.2%
if -1.99999999999999993e90 < c < 3.09999999999999999e122Initial program 95.4%
Taylor expanded in b around inf 76.1%
associate-*r/76.1%
metadata-eval76.1%
+-commutative76.1%
Simplified76.1%
Taylor expanded in t around inf 64.8%
mul-1-neg64.8%
+-commutative64.8%
distribute-rgt-neg-in64.8%
+-commutative64.8%
distribute-neg-in64.8%
unsub-neg64.8%
metadata-eval64.8%
Simplified64.8%
Taylor expanded in a around 0 60.7%
*-commutative60.7%
Simplified60.7%
if 3.09999999999999999e122 < c Initial program 87.8%
Taylor expanded in c around inf 85.8%
+-commutative85.8%
associate-*r/85.8%
metadata-eval85.8%
associate-+r-85.8%
Simplified85.8%
Taylor expanded in t around inf 66.9%
+-commutative66.9%
Simplified66.9%
Taylor expanded in a around 0 69.3%
Final simplification63.5%
(FPCore (x y z t a b c) :precision binary64 (if (<= b -6.4e+47) (/ x (* y (exp (* b -1.6666666666666667)))) (if (<= b 0.024) (/ x (+ x (* y (exp (* c 1.6666666666666667))))) 1.0)))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (b <= -6.4e+47) {
tmp = x / (y * exp((b * -1.6666666666666667)));
} else if (b <= 0.024) {
tmp = x / (x + (y * exp((c * 1.6666666666666667))));
} else {
tmp = 1.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if (b <= (-6.4d+47)) then
tmp = x / (y * exp((b * (-1.6666666666666667d0))))
else if (b <= 0.024d0) then
tmp = x / (x + (y * exp((c * 1.6666666666666667d0))))
else
tmp = 1.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (b <= -6.4e+47) {
tmp = x / (y * Math.exp((b * -1.6666666666666667)));
} else if (b <= 0.024) {
tmp = x / (x + (y * Math.exp((c * 1.6666666666666667))));
} else {
tmp = 1.0;
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if b <= -6.4e+47: tmp = x / (y * math.exp((b * -1.6666666666666667))) elif b <= 0.024: tmp = x / (x + (y * math.exp((c * 1.6666666666666667)))) else: tmp = 1.0 return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if (b <= -6.4e+47) tmp = Float64(x / Float64(y * exp(Float64(b * -1.6666666666666667)))); elseif (b <= 0.024) tmp = Float64(x / Float64(x + Float64(y * exp(Float64(c * 1.6666666666666667))))); else tmp = 1.0; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if (b <= -6.4e+47) tmp = x / (y * exp((b * -1.6666666666666667))); elseif (b <= 0.024) tmp = x / (x + (y * exp((c * 1.6666666666666667)))); else tmp = 1.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[b, -6.4e+47], N[(x / N[(y * N[Exp[N[(b * -1.6666666666666667), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 0.024], N[(x / N[(x + N[(y * N[Exp[N[(c * 1.6666666666666667), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 1.0]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -6.4 \cdot 10^{+47}:\\
\;\;\;\;\frac{x}{y \cdot e^{b \cdot -1.6666666666666667}}\\
\mathbf{elif}\;b \leq 0.024:\\
\;\;\;\;\frac{x}{x + y \cdot e^{c \cdot 1.6666666666666667}}\\
\mathbf{else}:\\
\;\;\;\;1\\
\end{array}
\end{array}
if b < -6.4e47Initial program 95.2%
Taylor expanded in b around inf 92.3%
associate-*r/92.3%
metadata-eval92.3%
+-commutative92.3%
Simplified92.3%
Taylor expanded in t around inf 73.9%
mul-1-neg73.9%
+-commutative73.9%
distribute-rgt-neg-in73.9%
+-commutative73.9%
distribute-neg-in73.9%
unsub-neg73.9%
metadata-eval73.9%
Simplified73.9%
Taylor expanded in a around 0 69.2%
*-commutative69.2%
Simplified69.2%
Taylor expanded in x around 0 69.2%
if -6.4e47 < b < 0.024Initial program 97.8%
Taylor expanded in c around inf 75.4%
+-commutative75.4%
associate-*r/75.4%
metadata-eval75.4%
associate-+r-75.4%
Simplified75.4%
Taylor expanded in t around inf 68.1%
+-commutative68.1%
Simplified68.1%
Taylor expanded in a around 0 59.6%
if 0.024 < b Initial program 83.4%
Simplified93.5%
Taylor expanded in x around inf 64.5%
Final simplification63.1%
(FPCore (x y z t a b c) :precision binary64 (if (<= t 1.8e-5) (/ x (+ x (* y (exp (* 1.3333333333333333 (/ b t)))))) (/ x (+ x (* y (exp (* 2.0 (* b (- -0.8333333333333334 a)))))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (t <= 1.8e-5) {
tmp = x / (x + (y * exp((1.3333333333333333 * (b / t)))));
} else {
tmp = x / (x + (y * exp((2.0 * (b * (-0.8333333333333334 - a))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if (t <= 1.8d-5) then
tmp = x / (x + (y * exp((1.3333333333333333d0 * (b / t)))))
else
tmp = x / (x + (y * exp((2.0d0 * (b * ((-0.8333333333333334d0) - a))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (t <= 1.8e-5) {
tmp = x / (x + (y * Math.exp((1.3333333333333333 * (b / t)))));
} else {
tmp = x / (x + (y * Math.exp((2.0 * (b * (-0.8333333333333334 - a))))));
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if t <= 1.8e-5: tmp = x / (x + (y * math.exp((1.3333333333333333 * (b / t))))) else: tmp = x / (x + (y * math.exp((2.0 * (b * (-0.8333333333333334 - a)))))) return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if (t <= 1.8e-5) tmp = Float64(x / Float64(x + Float64(y * exp(Float64(1.3333333333333333 * Float64(b / t)))))); else tmp = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(b * Float64(-0.8333333333333334 - a))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if (t <= 1.8e-5) tmp = x / (x + (y * exp((1.3333333333333333 * (b / t))))); else tmp = x / (x + (y * exp((2.0 * (b * (-0.8333333333333334 - a)))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[t, 1.8e-5], N[(x / N[(x + N[(y * N[Exp[N[(1.3333333333333333 * N[(b / t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(b * N[(-0.8333333333333334 - a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq 1.8 \cdot 10^{-5}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{1.3333333333333333 \cdot \frac{b}{t}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{2 \cdot \left(b \cdot \left(-0.8333333333333334 - a\right)\right)}}\\
\end{array}
\end{array}
if t < 1.80000000000000005e-5Initial program 91.3%
Taylor expanded in t around 0 70.5%
Taylor expanded in b around inf 64.9%
*-commutative64.9%
Simplified64.9%
Taylor expanded in b around inf 64.9%
if 1.80000000000000005e-5 < t Initial program 96.7%
Taylor expanded in b around inf 68.9%
associate-*r/68.9%
metadata-eval68.9%
+-commutative68.9%
Simplified68.9%
Taylor expanded in t around inf 68.9%
mul-1-neg68.9%
+-commutative68.9%
distribute-rgt-neg-in68.9%
+-commutative68.9%
distribute-neg-in68.9%
unsub-neg68.9%
metadata-eval68.9%
Simplified68.9%
(FPCore (x y z t a b c)
:precision binary64
(if (<= b -1.35e+70)
(/
x
(+
x
(*
y
(-
1.0
(*
b
(-
1.6666666666666667
(* b (+ 1.3888888888888888 (* b -0.7716049382716049)))))))))
1.0))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (b <= -1.35e+70) {
tmp = x / (x + (y * (1.0 - (b * (1.6666666666666667 - (b * (1.3888888888888888 + (b * -0.7716049382716049))))))));
} else {
tmp = 1.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if (b <= (-1.35d+70)) then
tmp = x / (x + (y * (1.0d0 - (b * (1.6666666666666667d0 - (b * (1.3888888888888888d0 + (b * (-0.7716049382716049d0)))))))))
else
tmp = 1.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (b <= -1.35e+70) {
tmp = x / (x + (y * (1.0 - (b * (1.6666666666666667 - (b * (1.3888888888888888 + (b * -0.7716049382716049))))))));
} else {
tmp = 1.0;
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if b <= -1.35e+70: tmp = x / (x + (y * (1.0 - (b * (1.6666666666666667 - (b * (1.3888888888888888 + (b * -0.7716049382716049)))))))) else: tmp = 1.0 return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if (b <= -1.35e+70) tmp = Float64(x / Float64(x + Float64(y * Float64(1.0 - Float64(b * Float64(1.6666666666666667 - Float64(b * Float64(1.3888888888888888 + Float64(b * -0.7716049382716049))))))))); else tmp = 1.0; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if (b <= -1.35e+70) tmp = x / (x + (y * (1.0 - (b * (1.6666666666666667 - (b * (1.3888888888888888 + (b * -0.7716049382716049)))))))); else tmp = 1.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[b, -1.35e+70], N[(x / N[(x + N[(y * N[(1.0 - N[(b * N[(1.6666666666666667 - N[(b * N[(1.3888888888888888 + N[(b * -0.7716049382716049), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 1.0]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.35 \cdot 10^{+70}:\\
\;\;\;\;\frac{x}{x + y \cdot \left(1 - b \cdot \left(1.6666666666666667 - b \cdot \left(1.3888888888888888 + b \cdot -0.7716049382716049\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;1\\
\end{array}
\end{array}
if b < -1.35e70Initial program 94.9%
Taylor expanded in b around inf 91.8%
associate-*r/91.8%
metadata-eval91.8%
+-commutative91.8%
Simplified91.8%
Taylor expanded in t around inf 73.7%
mul-1-neg73.7%
+-commutative73.7%
distribute-rgt-neg-in73.7%
+-commutative73.7%
distribute-neg-in73.7%
unsub-neg73.7%
metadata-eval73.7%
Simplified73.7%
Taylor expanded in a around 0 70.4%
*-commutative70.4%
Simplified70.4%
Taylor expanded in b around 0 70.5%
if -1.35e70 < b Initial program 93.4%
Simplified96.5%
Taylor expanded in x around inf 55.3%
Final simplification58.8%
(FPCore (x y z t a b c)
:precision binary64
(if (<= t -7.5e-46)
1.0
(if (<= t -8.8e-302)
(/ x (+ x (* y (+ (* 1.3333333333333333 (/ b t)) 1.0))))
1.0)))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (t <= -7.5e-46) {
tmp = 1.0;
} else if (t <= -8.8e-302) {
tmp = x / (x + (y * ((1.3333333333333333 * (b / t)) + 1.0)));
} else {
tmp = 1.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if (t <= (-7.5d-46)) then
tmp = 1.0d0
else if (t <= (-8.8d-302)) then
tmp = x / (x + (y * ((1.3333333333333333d0 * (b / t)) + 1.0d0)))
else
tmp = 1.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (t <= -7.5e-46) {
tmp = 1.0;
} else if (t <= -8.8e-302) {
tmp = x / (x + (y * ((1.3333333333333333 * (b / t)) + 1.0)));
} else {
tmp = 1.0;
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if t <= -7.5e-46: tmp = 1.0 elif t <= -8.8e-302: tmp = x / (x + (y * ((1.3333333333333333 * (b / t)) + 1.0))) else: tmp = 1.0 return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if (t <= -7.5e-46) tmp = 1.0; elseif (t <= -8.8e-302) tmp = Float64(x / Float64(x + Float64(y * Float64(Float64(1.3333333333333333 * Float64(b / t)) + 1.0)))); else tmp = 1.0; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if (t <= -7.5e-46) tmp = 1.0; elseif (t <= -8.8e-302) tmp = x / (x + (y * ((1.3333333333333333 * (b / t)) + 1.0))); else tmp = 1.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[t, -7.5e-46], 1.0, If[LessEqual[t, -8.8e-302], N[(x / N[(x + N[(y * N[(N[(1.3333333333333333 * N[(b / t), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 1.0]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -7.5 \cdot 10^{-46}:\\
\;\;\;\;1\\
\mathbf{elif}\;t \leq -8.8 \cdot 10^{-302}:\\
\;\;\;\;\frac{x}{x + y \cdot \left(1.3333333333333333 \cdot \frac{b}{t} + 1\right)}\\
\mathbf{else}:\\
\;\;\;\;1\\
\end{array}
\end{array}
if t < -7.50000000000000027e-46 or -8.8000000000000003e-302 < t Initial program 95.9%
Simplified98.2%
Taylor expanded in x around inf 54.7%
if -7.50000000000000027e-46 < t < -8.8000000000000003e-302Initial program 80.6%
Taylor expanded in t around 0 97.3%
Taylor expanded in b around inf 62.6%
*-commutative62.6%
Simplified62.6%
Taylor expanded in b around 0 67.0%
Final simplification56.4%
(FPCore (x y z t a b c)
:precision binary64
(if (<= b -1e+167)
(/
x
(- x (* y (- -1.0 (* b (- (* b 1.3888888888888888) 1.6666666666666667))))))
1.0))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (b <= -1e+167) {
tmp = x / (x - (y * (-1.0 - (b * ((b * 1.3888888888888888) - 1.6666666666666667)))));
} else {
tmp = 1.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if (b <= (-1d+167)) then
tmp = x / (x - (y * ((-1.0d0) - (b * ((b * 1.3888888888888888d0) - 1.6666666666666667d0)))))
else
tmp = 1.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (b <= -1e+167) {
tmp = x / (x - (y * (-1.0 - (b * ((b * 1.3888888888888888) - 1.6666666666666667)))));
} else {
tmp = 1.0;
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if b <= -1e+167: tmp = x / (x - (y * (-1.0 - (b * ((b * 1.3888888888888888) - 1.6666666666666667))))) else: tmp = 1.0 return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if (b <= -1e+167) tmp = Float64(x / Float64(x - Float64(y * Float64(-1.0 - Float64(b * Float64(Float64(b * 1.3888888888888888) - 1.6666666666666667)))))); else tmp = 1.0; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if (b <= -1e+167) tmp = x / (x - (y * (-1.0 - (b * ((b * 1.3888888888888888) - 1.6666666666666667))))); else tmp = 1.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[b, -1e+167], N[(x / N[(x - N[(y * N[(-1.0 - N[(b * N[(N[(b * 1.3888888888888888), $MachinePrecision] - 1.6666666666666667), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 1.0]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1 \cdot 10^{+167}:\\
\;\;\;\;\frac{x}{x - y \cdot \left(-1 - b \cdot \left(b \cdot 1.3888888888888888 - 1.6666666666666667\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;1\\
\end{array}
\end{array}
if b < -1e167Initial program 94.7%
Taylor expanded in b around inf 97.5%
associate-*r/97.5%
metadata-eval97.5%
+-commutative97.5%
Simplified97.5%
Taylor expanded in t around inf 79.6%
mul-1-neg79.6%
+-commutative79.6%
distribute-rgt-neg-in79.6%
+-commutative79.6%
distribute-neg-in79.6%
unsub-neg79.6%
metadata-eval79.6%
Simplified79.6%
Taylor expanded in a around 0 77.1%
*-commutative77.1%
Simplified77.1%
Taylor expanded in b around 0 77.1%
if -1e167 < b Initial program 93.6%
Simplified95.9%
Taylor expanded in x around inf 54.2%
Final simplification57.6%
(FPCore (x y z t a b c) :precision binary64 (if (<= y -2.1e+54) (/ x (+ x (- y (* 2.0 (* b (* y a)))))) 1.0))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (y <= -2.1e+54) {
tmp = x / (x + (y - (2.0 * (b * (y * a)))));
} else {
tmp = 1.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if (y <= (-2.1d+54)) then
tmp = x / (x + (y - (2.0d0 * (b * (y * a)))))
else
tmp = 1.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (y <= -2.1e+54) {
tmp = x / (x + (y - (2.0 * (b * (y * a)))));
} else {
tmp = 1.0;
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if y <= -2.1e+54: tmp = x / (x + (y - (2.0 * (b * (y * a))))) else: tmp = 1.0 return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if (y <= -2.1e+54) tmp = Float64(x / Float64(x + Float64(y - Float64(2.0 * Float64(b * Float64(y * a)))))); else tmp = 1.0; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if (y <= -2.1e+54) tmp = x / (x + (y - (2.0 * (b * (y * a))))); else tmp = 1.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[y, -2.1e+54], N[(x / N[(x + N[(y - N[(2.0 * N[(b * N[(y * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 1.0]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.1 \cdot 10^{+54}:\\
\;\;\;\;\frac{x}{x + \left(y - 2 \cdot \left(b \cdot \left(y \cdot a\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;1\\
\end{array}
\end{array}
if y < -2.09999999999999986e54Initial program 89.9%
Taylor expanded in b around inf 67.4%
associate-*r/67.4%
metadata-eval67.4%
+-commutative67.4%
Simplified67.4%
Taylor expanded in b around 0 59.7%
Taylor expanded in a around inf 57.6%
associate-*r*57.6%
neg-mul-157.6%
Simplified57.6%
if -2.09999999999999986e54 < y Initial program 94.9%
Simplified97.5%
Taylor expanded in x around inf 54.8%
Final simplification55.4%
(FPCore (x y z t a b c) :precision binary64 (if (<= y -4.5e+181) (+ (+ 1.0 (/ x y)) -1.0) 1.0))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (y <= -4.5e+181) {
tmp = (1.0 + (x / y)) + -1.0;
} else {
tmp = 1.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if (y <= (-4.5d+181)) then
tmp = (1.0d0 + (x / y)) + (-1.0d0)
else
tmp = 1.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (y <= -4.5e+181) {
tmp = (1.0 + (x / y)) + -1.0;
} else {
tmp = 1.0;
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if y <= -4.5e+181: tmp = (1.0 + (x / y)) + -1.0 else: tmp = 1.0 return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if (y <= -4.5e+181) tmp = Float64(Float64(1.0 + Float64(x / y)) + -1.0); else tmp = 1.0; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if (y <= -4.5e+181) tmp = (1.0 + (x / y)) + -1.0; else tmp = 1.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[y, -4.5e+181], N[(N[(1.0 + N[(x / y), $MachinePrecision]), $MachinePrecision] + -1.0), $MachinePrecision], 1.0]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.5 \cdot 10^{+181}:\\
\;\;\;\;\left(1 + \frac{x}{y}\right) + -1\\
\mathbf{else}:\\
\;\;\;\;1\\
\end{array}
\end{array}
if y < -4.5e181Initial program 86.3%
Taylor expanded in b around inf 66.6%
associate-*r/66.6%
metadata-eval66.6%
+-commutative66.6%
Simplified66.6%
Taylor expanded in b around 0 43.9%
Taylor expanded in x around 0 40.5%
expm1-log1p-u40.3%
log1p-define66.3%
expm1-undefine66.3%
add-exp-log66.6%
+-commutative66.6%
Applied egg-rr66.6%
if -4.5e181 < y Initial program 94.7%
Simplified97.4%
Taylor expanded in x around inf 53.1%
Final simplification54.6%
(FPCore (x y z t a b c) :precision binary64 (if (<= y -9.6e+174) (/ x (+ x y)) 1.0))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (y <= -9.6e+174) {
tmp = x / (x + y);
} else {
tmp = 1.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if (y <= (-9.6d+174)) then
tmp = x / (x + y)
else
tmp = 1.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (y <= -9.6e+174) {
tmp = x / (x + y);
} else {
tmp = 1.0;
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if y <= -9.6e+174: tmp = x / (x + y) else: tmp = 1.0 return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if (y <= -9.6e+174) tmp = Float64(x / Float64(x + y)); else tmp = 1.0; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if (y <= -9.6e+174) tmp = x / (x + y); else tmp = 1.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[y, -9.6e+174], N[(x / N[(x + y), $MachinePrecision]), $MachinePrecision], 1.0]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -9.6 \cdot 10^{+174}:\\
\;\;\;\;\frac{x}{x + y}\\
\mathbf{else}:\\
\;\;\;\;1\\
\end{array}
\end{array}
if y < -9.5999999999999993e174Initial program 87.2%
Taylor expanded in b around inf 65.6%
associate-*r/65.6%
metadata-eval65.6%
+-commutative65.6%
Simplified65.6%
Taylor expanded in b around 0 44.6%
if -9.5999999999999993e174 < y Initial program 94.7%
Simplified97.4%
Taylor expanded in x around inf 53.1%
(FPCore (x y z t a b c) :precision binary64 (if (<= y -9.5e+174) (/ x y) 1.0))
double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (y <= -9.5e+174) {
tmp = x / y;
} else {
tmp = 1.0;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: tmp
if (y <= (-9.5d+174)) then
tmp = x / y
else
tmp = 1.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double tmp;
if (y <= -9.5e+174) {
tmp = x / y;
} else {
tmp = 1.0;
}
return tmp;
}
def code(x, y, z, t, a, b, c): tmp = 0 if y <= -9.5e+174: tmp = x / y else: tmp = 1.0 return tmp
function code(x, y, z, t, a, b, c) tmp = 0.0 if (y <= -9.5e+174) tmp = Float64(x / y); else tmp = 1.0; end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) tmp = 0.0; if (y <= -9.5e+174) tmp = x / y; else tmp = 1.0; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := If[LessEqual[y, -9.5e+174], N[(x / y), $MachinePrecision], 1.0]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -9.5 \cdot 10^{+174}:\\
\;\;\;\;\frac{x}{y}\\
\mathbf{else}:\\
\;\;\;\;1\\
\end{array}
\end{array}
if y < -9.4999999999999992e174Initial program 87.2%
Taylor expanded in b around inf 65.6%
associate-*r/65.6%
metadata-eval65.6%
+-commutative65.6%
Simplified65.6%
Taylor expanded in b around 0 44.6%
Taylor expanded in x around 0 41.4%
if -9.4999999999999992e174 < y Initial program 94.7%
Simplified97.4%
Taylor expanded in x around inf 53.1%
(FPCore (x y z t a b c) :precision binary64 1.0)
double code(double x, double y, double z, double t, double a, double b, double c) {
return 1.0;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
code = 1.0d0
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
return 1.0;
}
def code(x, y, z, t, a, b, c): return 1.0
function code(x, y, z, t, a, b, c) return 1.0 end
function tmp = code(x, y, z, t, a, b, c) tmp = 1.0; end
code[x_, y_, z_, t_, a_, b_, c_] := 1.0
\begin{array}{l}
\\
1
\end{array}
Initial program 93.8%
Simplified96.5%
Taylor expanded in x around inf 50.1%
(FPCore (x y z t a b c)
:precision binary64
(let* ((t_1 (* z (sqrt (+ t a)))) (t_2 (- a (/ 5.0 6.0))))
(if (< t -2.118326644891581e-50)
(/
x
(+
x
(* y (exp (* 2.0 (- (+ (* a c) (* 0.8333333333333334 c)) (* a b)))))))
(if (< t 5.196588770651547e-123)
(/
x
(+
x
(*
y
(exp
(*
2.0
(/
(-
(* t_1 (* (* 3.0 t) t_2))
(*
(- (* (+ (/ 5.0 6.0) a) (* 3.0 t)) 2.0)
(* t_2 (* (- b c) t))))
(* (* (* t t) 3.0) t_2)))))))
(/
x
(+
x
(*
y
(exp
(*
2.0
(-
(/ t_1 t)
(* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0))))))))))))))
double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = z * sqrt((t + a));
double t_2 = a - (5.0 / 6.0);
double tmp;
if (t < -2.118326644891581e-50) {
tmp = x / (x + (y * exp((2.0 * (((a * c) + (0.8333333333333334 * c)) - (a * b))))));
} else if (t < 5.196588770651547e-123) {
tmp = x / (x + (y * exp((2.0 * (((t_1 * ((3.0 * t) * t_2)) - (((((5.0 / 6.0) + a) * (3.0 * t)) - 2.0) * (t_2 * ((b - c) * t)))) / (((t * t) * 3.0) * t_2))))));
} else {
tmp = x / (x + (y * exp((2.0 * ((t_1 / t) - ((b - c) * ((a + (5.0 / 6.0)) - (2.0 / (t * 3.0)))))))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b, c)
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), intent (in) :: c
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_1 = z * sqrt((t + a))
t_2 = a - (5.0d0 / 6.0d0)
if (t < (-2.118326644891581d-50)) then
tmp = x / (x + (y * exp((2.0d0 * (((a * c) + (0.8333333333333334d0 * c)) - (a * b))))))
else if (t < 5.196588770651547d-123) then
tmp = x / (x + (y * exp((2.0d0 * (((t_1 * ((3.0d0 * t) * t_2)) - (((((5.0d0 / 6.0d0) + a) * (3.0d0 * t)) - 2.0d0) * (t_2 * ((b - c) * t)))) / (((t * t) * 3.0d0) * t_2))))))
else
tmp = x / (x + (y * exp((2.0d0 * ((t_1 / t) - ((b - c) * ((a + (5.0d0 / 6.0d0)) - (2.0d0 / (t * 3.0d0)))))))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b, double c) {
double t_1 = z * Math.sqrt((t + a));
double t_2 = a - (5.0 / 6.0);
double tmp;
if (t < -2.118326644891581e-50) {
tmp = x / (x + (y * Math.exp((2.0 * (((a * c) + (0.8333333333333334 * c)) - (a * b))))));
} else if (t < 5.196588770651547e-123) {
tmp = x / (x + (y * Math.exp((2.0 * (((t_1 * ((3.0 * t) * t_2)) - (((((5.0 / 6.0) + a) * (3.0 * t)) - 2.0) * (t_2 * ((b - c) * t)))) / (((t * t) * 3.0) * t_2))))));
} else {
tmp = x / (x + (y * Math.exp((2.0 * ((t_1 / t) - ((b - c) * ((a + (5.0 / 6.0)) - (2.0 / (t * 3.0)))))))));
}
return tmp;
}
def code(x, y, z, t, a, b, c): t_1 = z * math.sqrt((t + a)) t_2 = a - (5.0 / 6.0) tmp = 0 if t < -2.118326644891581e-50: tmp = x / (x + (y * math.exp((2.0 * (((a * c) + (0.8333333333333334 * c)) - (a * b)))))) elif t < 5.196588770651547e-123: tmp = x / (x + (y * math.exp((2.0 * (((t_1 * ((3.0 * t) * t_2)) - (((((5.0 / 6.0) + a) * (3.0 * t)) - 2.0) * (t_2 * ((b - c) * t)))) / (((t * t) * 3.0) * t_2)))))) else: tmp = x / (x + (y * math.exp((2.0 * ((t_1 / t) - ((b - c) * ((a + (5.0 / 6.0)) - (2.0 / (t * 3.0))))))))) return tmp
function code(x, y, z, t, a, b, c) t_1 = Float64(z * sqrt(Float64(t + a))) t_2 = Float64(a - Float64(5.0 / 6.0)) tmp = 0.0 if (t < -2.118326644891581e-50) tmp = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(Float64(Float64(a * c) + Float64(0.8333333333333334 * c)) - Float64(a * b))))))); elseif (t < 5.196588770651547e-123) tmp = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(Float64(Float64(t_1 * Float64(Float64(3.0 * t) * t_2)) - Float64(Float64(Float64(Float64(Float64(5.0 / 6.0) + a) * Float64(3.0 * t)) - 2.0) * Float64(t_2 * Float64(Float64(b - c) * t)))) / Float64(Float64(Float64(t * t) * 3.0) * t_2))))))); else tmp = Float64(x / Float64(x + Float64(y * exp(Float64(2.0 * Float64(Float64(t_1 / t) - Float64(Float64(b - c) * Float64(Float64(a + Float64(5.0 / 6.0)) - Float64(2.0 / Float64(t * 3.0)))))))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b, c) t_1 = z * sqrt((t + a)); t_2 = a - (5.0 / 6.0); tmp = 0.0; if (t < -2.118326644891581e-50) tmp = x / (x + (y * exp((2.0 * (((a * c) + (0.8333333333333334 * c)) - (a * b)))))); elseif (t < 5.196588770651547e-123) tmp = x / (x + (y * exp((2.0 * (((t_1 * ((3.0 * t) * t_2)) - (((((5.0 / 6.0) + a) * (3.0 * t)) - 2.0) * (t_2 * ((b - c) * t)))) / (((t * t) * 3.0) * t_2)))))); else tmp = x / (x + (y * exp((2.0 * ((t_1 / t) - ((b - c) * ((a + (5.0 / 6.0)) - (2.0 / (t * 3.0))))))))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_, c_] := Block[{t$95$1 = N[(z * N[Sqrt[N[(t + a), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(a - N[(5.0 / 6.0), $MachinePrecision]), $MachinePrecision]}, If[Less[t, -2.118326644891581e-50], N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(N[(N[(a * c), $MachinePrecision] + N[(0.8333333333333334 * c), $MachinePrecision]), $MachinePrecision] - N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[Less[t, 5.196588770651547e-123], N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(N[(N[(t$95$1 * N[(N[(3.0 * t), $MachinePrecision] * t$95$2), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(N[(N[(5.0 / 6.0), $MachinePrecision] + a), $MachinePrecision] * N[(3.0 * t), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision] * N[(t$95$2 * N[(N[(b - c), $MachinePrecision] * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(t * t), $MachinePrecision] * 3.0), $MachinePrecision] * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x / N[(x + N[(y * N[Exp[N[(2.0 * N[(N[(t$95$1 / t), $MachinePrecision] - N[(N[(b - c), $MachinePrecision] * N[(N[(a + N[(5.0 / 6.0), $MachinePrecision]), $MachinePrecision] - N[(2.0 / N[(t * 3.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := z \cdot \sqrt{t + a}\\
t_2 := a - \frac{5}{6}\\
\mathbf{if}\;t < -2.118326644891581 \cdot 10^{-50}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{2 \cdot \left(\left(a \cdot c + 0.8333333333333334 \cdot c\right) - a \cdot b\right)}}\\
\mathbf{elif}\;t < 5.196588770651547 \cdot 10^{-123}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{2 \cdot \frac{t\_1 \cdot \left(\left(3 \cdot t\right) \cdot t\_2\right) - \left(\left(\frac{5}{6} + a\right) \cdot \left(3 \cdot t\right) - 2\right) \cdot \left(t\_2 \cdot \left(\left(b - c\right) \cdot t\right)\right)}{\left(\left(t \cdot t\right) \cdot 3\right) \cdot t\_2}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{x + y \cdot e^{2 \cdot \left(\frac{t\_1}{t} - \left(b - c\right) \cdot \left(\left(a + \frac{5}{6}\right) - \frac{2}{t \cdot 3}\right)\right)}}\\
\end{array}
\end{array}
herbie shell --seed 2024137
(FPCore (x y z t a b c)
:name "Numeric.SpecFunctions:invIncompleteBetaWorker from math-functions-0.1.5.2, I"
:precision binary64
:alt
(! :herbie-platform default (if (< t -2118326644891581/100000000000000000000000000000000000000000000000000000000000000000) (/ x (+ x (* y (exp (* 2 (- (+ (* a c) (* 4166666666666667/5000000000000000 c)) (* a b))))))) (if (< t 5196588770651547/1000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (/ x (+ x (* y (exp (* 2 (/ (- (* (* z (sqrt (+ t a))) (* (* 3 t) (- a (/ 5 6)))) (* (- (* (+ (/ 5 6) a) (* 3 t)) 2) (* (- a (/ 5 6)) (* (- b c) t)))) (* (* (* t t) 3) (- a (/ 5 6))))))))) (/ x (+ x (* y (exp (* 2 (- (/ (* z (sqrt (+ t a))) t) (* (- b c) (- (+ a (/ 5 6)) (/ 2 (* t 3)))))))))))))
(/ x (+ x (* y (exp (* 2.0 (- (/ (* z (sqrt (+ t a))) t) (* (- b c) (- (+ a (/ 5.0 6.0)) (/ 2.0 (* t 3.0)))))))))))