
(FPCore (x y z t a b) :precision binary64 (/ (+ x (/ (* y z) t)) (+ (+ a 1.0) (/ (* y b) t))))
double code(double x, double y, double z, double t, double a, double b) {
return (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t));
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = (x + ((y * z) / t)) / ((a + 1.0d0) + ((y * b) / t))
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t));
}
def code(x, y, z, t, a, b): return (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t))
function code(x, y, z, t, a, b) return Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(Float64(a + 1.0) + Float64(Float64(y * b) / t))) end
function tmp = code(x, y, z, t, a, b) tmp = (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t)); end
code[x_, y_, z_, t_, a_, b_] := N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 18 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b) :precision binary64 (/ (+ x (/ (* y z) t)) (+ (+ a 1.0) (/ (* y b) t))))
double code(double x, double y, double z, double t, double a, double b) {
return (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t));
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = (x + ((y * z) / t)) / ((a + 1.0d0) + ((y * b) / t))
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t));
}
def code(x, y, z, t, a, b): return (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t))
function code(x, y, z, t, a, b) return Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(Float64(a + 1.0) + Float64(Float64(y * b) / t))) end
function tmp = code(x, y, z, t, a, b) tmp = (x + ((y * z) / t)) / ((a + 1.0) + ((y * b) / t)); end
code[x_, y_, z_, t_, a_, b_] := N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\frac{x + \frac{y \cdot z}{t}}{\left(a + 1\right) + \frac{y \cdot b}{t}}
\end{array}
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (+ x (/ (* y z) t)) (+ (/ (* y b) t) (+ a 1.0))))
(t_2 (* z (/ y (* t (fma y (/ b t) (+ a 1.0)))))))
(if (<= t_1 (- INFINITY))
t_2
(if (<= t_1 -1e-307)
t_1
(if (<= t_1 0.0)
(+ (/ z b) (/ (* t (- (/ x b) (/ z (pow b 2.0)))) y))
(if (<= t_1 1e+294) t_1 (if (<= t_1 INFINITY) t_2 (/ z b))))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + ((y * z) / t)) / (((y * b) / t) + (a + 1.0));
double t_2 = z * (y / (t * fma(y, (b / t), (a + 1.0))));
double tmp;
if (t_1 <= -((double) INFINITY)) {
tmp = t_2;
} else if (t_1 <= -1e-307) {
tmp = t_1;
} else if (t_1 <= 0.0) {
tmp = (z / b) + ((t * ((x / b) - (z / pow(b, 2.0)))) / y);
} else if (t_1 <= 1e+294) {
tmp = t_1;
} else if (t_1 <= ((double) INFINITY)) {
tmp = t_2;
} else {
tmp = z / b;
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(Float64(Float64(y * b) / t) + Float64(a + 1.0))) t_2 = Float64(z * Float64(y / Float64(t * fma(y, Float64(b / t), Float64(a + 1.0))))) tmp = 0.0 if (t_1 <= Float64(-Inf)) tmp = t_2; elseif (t_1 <= -1e-307) tmp = t_1; elseif (t_1 <= 0.0) tmp = Float64(Float64(z / b) + Float64(Float64(t * Float64(Float64(x / b) - Float64(z / (b ^ 2.0)))) / y)); elseif (t_1 <= 1e+294) tmp = t_1; elseif (t_1 <= Inf) tmp = t_2; else tmp = Float64(z / b); end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision] + N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(z * N[(y / N[(t * N[(y * N[(b / t), $MachinePrecision] + N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], t$95$2, If[LessEqual[t$95$1, -1e-307], t$95$1, If[LessEqual[t$95$1, 0.0], N[(N[(z / b), $MachinePrecision] + N[(N[(t * N[(N[(x / b), $MachinePrecision] - N[(z / N[Power[b, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, 1e+294], t$95$1, If[LessEqual[t$95$1, Infinity], t$95$2, N[(z / b), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x + \frac{y \cdot z}{t}}{\frac{y \cdot b}{t} + \left(a + 1\right)}\\
t_2 := z \cdot \frac{y}{t \cdot \mathsf{fma}\left(y, \frac{b}{t}, a + 1\right)}\\
\mathbf{if}\;t\_1 \leq -\infty:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t\_1 \leq -1 \cdot 10^{-307}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t\_1 \leq 0:\\
\;\;\;\;\frac{z}{b} + \frac{t \cdot \left(\frac{x}{b} - \frac{z}{{b}^{2}}\right)}{y}\\
\mathbf{elif}\;t\_1 \leq 10^{+294}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t\_1 \leq \infty:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < -inf.0 or 1.00000000000000007e294 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < +inf.0Initial program 24.2%
associate-/l*44.8%
associate-/l*44.6%
Simplified44.6%
Taylor expanded in x around 0 49.9%
associate-/l*81.9%
associate-+r+81.9%
associate-*r/60.5%
*-commutative60.5%
associate-/r/81.9%
+-commutative81.9%
associate-/r/60.5%
*-commutative60.5%
associate-*r/81.9%
associate-*l/81.7%
*-commutative81.7%
fma-define81.7%
Simplified81.7%
clear-num81.6%
un-div-inv81.7%
fma-undefine81.7%
+-commutative81.7%
+-commutative81.7%
associate-+l+81.7%
associate-*r/81.9%
*-commutative81.9%
+-commutative81.9%
*-commutative81.9%
associate-*r/81.7%
fma-define81.7%
Applied egg-rr81.7%
associate-/r/84.5%
fma-undefine84.5%
*-commutative84.5%
associate-*l/87.5%
+-commutative87.5%
associate-*l/84.5%
*-commutative84.5%
associate-+l+84.5%
+-commutative84.5%
fma-define84.5%
+-commutative84.5%
Simplified84.5%
if -inf.0 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < -9.99999999999999909e-308 or -0.0 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < 1.00000000000000007e294Initial program 99.6%
if -9.99999999999999909e-308 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < -0.0Initial program 51.9%
associate-/l*51.7%
associate-/l*67.4%
Simplified67.4%
Taylor expanded in a around 0 33.8%
associate-/l*47.7%
Applied egg-rr47.7%
Taylor expanded in y around -inf 76.5%
+-commutative76.5%
mul-1-neg76.5%
unsub-neg76.5%
distribute-lft-out--76.5%
mul-1-neg76.5%
associate-/l*80.9%
associate-/l*80.9%
distribute-lft-out--80.9%
Simplified80.9%
if +inf.0 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) Initial program 0.0%
associate-/l*0.7%
associate-/l*14.2%
Simplified14.2%
Taylor expanded in y around inf 100.0%
Final simplification94.8%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (+ x (/ (* y z) t)) (+ (/ (* y b) t) (+ a 1.0))))
(t_2 (* z (/ y (* t (fma y (/ b t) (+ a 1.0)))))))
(if (<= t_1 (- INFINITY))
t_2
(if (<= t_1 1e+294) t_1 (if (<= t_1 INFINITY) t_2 (/ z b))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + ((y * z) / t)) / (((y * b) / t) + (a + 1.0));
double t_2 = z * (y / (t * fma(y, (b / t), (a + 1.0))));
double tmp;
if (t_1 <= -((double) INFINITY)) {
tmp = t_2;
} else if (t_1 <= 1e+294) {
tmp = t_1;
} else if (t_1 <= ((double) INFINITY)) {
tmp = t_2;
} else {
tmp = z / b;
}
return tmp;
}
function code(x, y, z, t, a, b) t_1 = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(Float64(Float64(y * b) / t) + Float64(a + 1.0))) t_2 = Float64(z * Float64(y / Float64(t * fma(y, Float64(b / t), Float64(a + 1.0))))) tmp = 0.0 if (t_1 <= Float64(-Inf)) tmp = t_2; elseif (t_1 <= 1e+294) tmp = t_1; elseif (t_1 <= Inf) tmp = t_2; else tmp = Float64(z / b); end return tmp end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision] + N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(z * N[(y / N[(t * N[(y * N[(b / t), $MachinePrecision] + N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], t$95$2, If[LessEqual[t$95$1, 1e+294], t$95$1, If[LessEqual[t$95$1, Infinity], t$95$2, N[(z / b), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x + \frac{y \cdot z}{t}}{\frac{y \cdot b}{t} + \left(a + 1\right)}\\
t_2 := z \cdot \frac{y}{t \cdot \mathsf{fma}\left(y, \frac{b}{t}, a + 1\right)}\\
\mathbf{if}\;t\_1 \leq -\infty:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t\_1 \leq 10^{+294}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t\_1 \leq \infty:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < -inf.0 or 1.00000000000000007e294 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < +inf.0Initial program 24.2%
associate-/l*44.8%
associate-/l*44.6%
Simplified44.6%
Taylor expanded in x around 0 49.9%
associate-/l*81.9%
associate-+r+81.9%
associate-*r/60.5%
*-commutative60.5%
associate-/r/81.9%
+-commutative81.9%
associate-/r/60.5%
*-commutative60.5%
associate-*r/81.9%
associate-*l/81.7%
*-commutative81.7%
fma-define81.7%
Simplified81.7%
clear-num81.6%
un-div-inv81.7%
fma-undefine81.7%
+-commutative81.7%
+-commutative81.7%
associate-+l+81.7%
associate-*r/81.9%
*-commutative81.9%
+-commutative81.9%
*-commutative81.9%
associate-*r/81.7%
fma-define81.7%
Applied egg-rr81.7%
associate-/r/84.5%
fma-undefine84.5%
*-commutative84.5%
associate-*l/87.5%
+-commutative87.5%
associate-*l/84.5%
*-commutative84.5%
associate-+l+84.5%
+-commutative84.5%
fma-define84.5%
+-commutative84.5%
Simplified84.5%
if -inf.0 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < 1.00000000000000007e294Initial program 89.6%
if +inf.0 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) Initial program 0.0%
associate-/l*0.7%
associate-/l*14.2%
Simplified14.2%
Taylor expanded in y around inf 100.0%
Final simplification90.1%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (+ x (/ (* y z) t)) (+ (/ (* y b) t) (+ a 1.0))))
(t_2 (* y (/ z (+ (* y b) (* t (+ a 1.0)))))))
(if (<= t_1 (- INFINITY))
t_2
(if (<= t_1 1e+294) t_1 (if (<= t_1 INFINITY) t_2 (/ z b))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + ((y * z) / t)) / (((y * b) / t) + (a + 1.0));
double t_2 = y * (z / ((y * b) + (t * (a + 1.0))));
double tmp;
if (t_1 <= -((double) INFINITY)) {
tmp = t_2;
} else if (t_1 <= 1e+294) {
tmp = t_1;
} else if (t_1 <= ((double) INFINITY)) {
tmp = t_2;
} else {
tmp = z / b;
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + ((y * z) / t)) / (((y * b) / t) + (a + 1.0));
double t_2 = y * (z / ((y * b) + (t * (a + 1.0))));
double tmp;
if (t_1 <= -Double.POSITIVE_INFINITY) {
tmp = t_2;
} else if (t_1 <= 1e+294) {
tmp = t_1;
} else if (t_1 <= Double.POSITIVE_INFINITY) {
tmp = t_2;
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (x + ((y * z) / t)) / (((y * b) / t) + (a + 1.0)) t_2 = y * (z / ((y * b) + (t * (a + 1.0)))) tmp = 0 if t_1 <= -math.inf: tmp = t_2 elif t_1 <= 1e+294: tmp = t_1 elif t_1 <= math.inf: tmp = t_2 else: tmp = z / b return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(Float64(Float64(y * b) / t) + Float64(a + 1.0))) t_2 = Float64(y * Float64(z / Float64(Float64(y * b) + Float64(t * Float64(a + 1.0))))) tmp = 0.0 if (t_1 <= Float64(-Inf)) tmp = t_2; elseif (t_1 <= 1e+294) tmp = t_1; elseif (t_1 <= Inf) tmp = t_2; else tmp = Float64(z / b); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (x + ((y * z) / t)) / (((y * b) / t) + (a + 1.0)); t_2 = y * (z / ((y * b) + (t * (a + 1.0)))); tmp = 0.0; if (t_1 <= -Inf) tmp = t_2; elseif (t_1 <= 1e+294) tmp = t_1; elseif (t_1 <= Inf) tmp = t_2; else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision] + N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(y * N[(z / N[(N[(y * b), $MachinePrecision] + N[(t * N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, (-Infinity)], t$95$2, If[LessEqual[t$95$1, 1e+294], t$95$1, If[LessEqual[t$95$1, Infinity], t$95$2, N[(z / b), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x + \frac{y \cdot z}{t}}{\frac{y \cdot b}{t} + \left(a + 1\right)}\\
t_2 := y \cdot \frac{z}{y \cdot b + t \cdot \left(a + 1\right)}\\
\mathbf{if}\;t\_1 \leq -\infty:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t\_1 \leq 10^{+294}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t\_1 \leq \infty:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < -inf.0 or 1.00000000000000007e294 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < +inf.0Initial program 24.2%
associate-/l*44.8%
associate-/l*44.6%
Simplified44.6%
Taylor expanded in x around 0 49.9%
associate-/l*81.9%
associate-+r+81.9%
associate-*r/60.5%
*-commutative60.5%
associate-/r/81.9%
+-commutative81.9%
associate-/r/60.5%
*-commutative60.5%
associate-*r/81.9%
associate-*l/81.7%
*-commutative81.7%
fma-define81.7%
Simplified81.7%
Taylor expanded in t around 0 82.0%
if -inf.0 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) < 1.00000000000000007e294Initial program 89.6%
if +inf.0 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a 1) (/.f64 (*.f64 y b) t))) Initial program 0.0%
associate-/l*0.7%
associate-/l*14.2%
Simplified14.2%
Taylor expanded in y around inf 100.0%
Final simplification89.8%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (+ x (* y (/ z t))) a)))
(if (<= a -7.5e+23)
t_1
(if (<= a -4.5e-189)
(/ z b)
(if (<= a 8.5e-165)
(+ x (* z (/ y t)))
(if (<= a 6.2e-41)
(/ z b)
(if (<= a 5.8e-6)
(/ x (+ (/ (* y b) t) 1.0))
(if (<= a 8.2e+18) (/ x (+ a 1.0)) t_1))))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + (y * (z / t))) / a;
double tmp;
if (a <= -7.5e+23) {
tmp = t_1;
} else if (a <= -4.5e-189) {
tmp = z / b;
} else if (a <= 8.5e-165) {
tmp = x + (z * (y / t));
} else if (a <= 6.2e-41) {
tmp = z / b;
} else if (a <= 5.8e-6) {
tmp = x / (((y * b) / t) + 1.0);
} else if (a <= 8.2e+18) {
tmp = x / (a + 1.0);
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = (x + (y * (z / t))) / a
if (a <= (-7.5d+23)) then
tmp = t_1
else if (a <= (-4.5d-189)) then
tmp = z / b
else if (a <= 8.5d-165) then
tmp = x + (z * (y / t))
else if (a <= 6.2d-41) then
tmp = z / b
else if (a <= 5.8d-6) then
tmp = x / (((y * b) / t) + 1.0d0)
else if (a <= 8.2d+18) then
tmp = x / (a + 1.0d0)
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + (y * (z / t))) / a;
double tmp;
if (a <= -7.5e+23) {
tmp = t_1;
} else if (a <= -4.5e-189) {
tmp = z / b;
} else if (a <= 8.5e-165) {
tmp = x + (z * (y / t));
} else if (a <= 6.2e-41) {
tmp = z / b;
} else if (a <= 5.8e-6) {
tmp = x / (((y * b) / t) + 1.0);
} else if (a <= 8.2e+18) {
tmp = x / (a + 1.0);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (x + (y * (z / t))) / a tmp = 0 if a <= -7.5e+23: tmp = t_1 elif a <= -4.5e-189: tmp = z / b elif a <= 8.5e-165: tmp = x + (z * (y / t)) elif a <= 6.2e-41: tmp = z / b elif a <= 5.8e-6: tmp = x / (((y * b) / t) + 1.0) elif a <= 8.2e+18: tmp = x / (a + 1.0) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(x + Float64(y * Float64(z / t))) / a) tmp = 0.0 if (a <= -7.5e+23) tmp = t_1; elseif (a <= -4.5e-189) tmp = Float64(z / b); elseif (a <= 8.5e-165) tmp = Float64(x + Float64(z * Float64(y / t))); elseif (a <= 6.2e-41) tmp = Float64(z / b); elseif (a <= 5.8e-6) tmp = Float64(x / Float64(Float64(Float64(y * b) / t) + 1.0)); elseif (a <= 8.2e+18) tmp = Float64(x / Float64(a + 1.0)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (x + (y * (z / t))) / a; tmp = 0.0; if (a <= -7.5e+23) tmp = t_1; elseif (a <= -4.5e-189) tmp = z / b; elseif (a <= 8.5e-165) tmp = x + (z * (y / t)); elseif (a <= 6.2e-41) tmp = z / b; elseif (a <= 5.8e-6) tmp = x / (((y * b) / t) + 1.0); elseif (a <= 8.2e+18) tmp = x / (a + 1.0); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]}, If[LessEqual[a, -7.5e+23], t$95$1, If[LessEqual[a, -4.5e-189], N[(z / b), $MachinePrecision], If[LessEqual[a, 8.5e-165], N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 6.2e-41], N[(z / b), $MachinePrecision], If[LessEqual[a, 5.8e-6], N[(x / N[(N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 8.2e+18], N[(x / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x + y \cdot \frac{z}{t}}{a}\\
\mathbf{if}\;a \leq -7.5 \cdot 10^{+23}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq -4.5 \cdot 10^{-189}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;a \leq 8.5 \cdot 10^{-165}:\\
\;\;\;\;x + z \cdot \frac{y}{t}\\
\mathbf{elif}\;a \leq 6.2 \cdot 10^{-41}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;a \leq 5.8 \cdot 10^{-6}:\\
\;\;\;\;\frac{x}{\frac{y \cdot b}{t} + 1}\\
\mathbf{elif}\;a \leq 8.2 \cdot 10^{+18}:\\
\;\;\;\;\frac{x}{a + 1}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if a < -7.49999999999999987e23 or 8.2e18 < a Initial program 75.2%
associate-/l*71.2%
associate-/l*71.1%
Simplified71.1%
Taylor expanded in a around inf 60.7%
if -7.49999999999999987e23 < a < -4.4999999999999996e-189 or 8.5e-165 < a < 6.20000000000000001e-41Initial program 57.4%
associate-/l*55.8%
associate-/l*64.9%
Simplified64.9%
Taylor expanded in y around inf 65.0%
if -4.4999999999999996e-189 < a < 8.5e-165Initial program 74.1%
associate-/l*75.3%
associate-/l*78.4%
Simplified78.4%
Taylor expanded in y around 0 58.4%
Taylor expanded in a around 0 55.9%
*-commutative55.9%
associate-/l*60.4%
Applied egg-rr60.4%
if 6.20000000000000001e-41 < a < 5.8000000000000004e-6Initial program 99.8%
associate-/l*99.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in a around 0 94.2%
Taylor expanded in x around inf 69.9%
if 5.8000000000000004e-6 < a < 8.2e18Initial program 66.7%
associate-/l*66.7%
associate-/l*66.7%
Simplified66.7%
Taylor expanded in y around 0 52.2%
Final simplification61.7%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (+ x (/ y (/ t z))) a)))
(if (<= a -4.9e+23)
t_1
(if (<= a -5.7e-189)
(/ z b)
(if (<= a 1.55e-164)
(+ x (* z (/ y t)))
(if (<= a 2.15e-41)
(/ z b)
(if (<= a 3.5e-7)
(/ x (+ (/ (* y b) t) 1.0))
(if (<= a 8.2e+18) (/ x (+ a 1.0)) t_1))))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + (y / (t / z))) / a;
double tmp;
if (a <= -4.9e+23) {
tmp = t_1;
} else if (a <= -5.7e-189) {
tmp = z / b;
} else if (a <= 1.55e-164) {
tmp = x + (z * (y / t));
} else if (a <= 2.15e-41) {
tmp = z / b;
} else if (a <= 3.5e-7) {
tmp = x / (((y * b) / t) + 1.0);
} else if (a <= 8.2e+18) {
tmp = x / (a + 1.0);
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = (x + (y / (t / z))) / a
if (a <= (-4.9d+23)) then
tmp = t_1
else if (a <= (-5.7d-189)) then
tmp = z / b
else if (a <= 1.55d-164) then
tmp = x + (z * (y / t))
else if (a <= 2.15d-41) then
tmp = z / b
else if (a <= 3.5d-7) then
tmp = x / (((y * b) / t) + 1.0d0)
else if (a <= 8.2d+18) then
tmp = x / (a + 1.0d0)
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + (y / (t / z))) / a;
double tmp;
if (a <= -4.9e+23) {
tmp = t_1;
} else if (a <= -5.7e-189) {
tmp = z / b;
} else if (a <= 1.55e-164) {
tmp = x + (z * (y / t));
} else if (a <= 2.15e-41) {
tmp = z / b;
} else if (a <= 3.5e-7) {
tmp = x / (((y * b) / t) + 1.0);
} else if (a <= 8.2e+18) {
tmp = x / (a + 1.0);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (x + (y / (t / z))) / a tmp = 0 if a <= -4.9e+23: tmp = t_1 elif a <= -5.7e-189: tmp = z / b elif a <= 1.55e-164: tmp = x + (z * (y / t)) elif a <= 2.15e-41: tmp = z / b elif a <= 3.5e-7: tmp = x / (((y * b) / t) + 1.0) elif a <= 8.2e+18: tmp = x / (a + 1.0) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(x + Float64(y / Float64(t / z))) / a) tmp = 0.0 if (a <= -4.9e+23) tmp = t_1; elseif (a <= -5.7e-189) tmp = Float64(z / b); elseif (a <= 1.55e-164) tmp = Float64(x + Float64(z * Float64(y / t))); elseif (a <= 2.15e-41) tmp = Float64(z / b); elseif (a <= 3.5e-7) tmp = Float64(x / Float64(Float64(Float64(y * b) / t) + 1.0)); elseif (a <= 8.2e+18) tmp = Float64(x / Float64(a + 1.0)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (x + (y / (t / z))) / a; tmp = 0.0; if (a <= -4.9e+23) tmp = t_1; elseif (a <= -5.7e-189) tmp = z / b; elseif (a <= 1.55e-164) tmp = x + (z * (y / t)); elseif (a <= 2.15e-41) tmp = z / b; elseif (a <= 3.5e-7) tmp = x / (((y * b) / t) + 1.0); elseif (a <= 8.2e+18) tmp = x / (a + 1.0); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x + N[(y / N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]}, If[LessEqual[a, -4.9e+23], t$95$1, If[LessEqual[a, -5.7e-189], N[(z / b), $MachinePrecision], If[LessEqual[a, 1.55e-164], N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 2.15e-41], N[(z / b), $MachinePrecision], If[LessEqual[a, 3.5e-7], N[(x / N[(N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 8.2e+18], N[(x / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x + \frac{y}{\frac{t}{z}}}{a}\\
\mathbf{if}\;a \leq -4.9 \cdot 10^{+23}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq -5.7 \cdot 10^{-189}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;a \leq 1.55 \cdot 10^{-164}:\\
\;\;\;\;x + z \cdot \frac{y}{t}\\
\mathbf{elif}\;a \leq 2.15 \cdot 10^{-41}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;a \leq 3.5 \cdot 10^{-7}:\\
\;\;\;\;\frac{x}{\frac{y \cdot b}{t} + 1}\\
\mathbf{elif}\;a \leq 8.2 \cdot 10^{+18}:\\
\;\;\;\;\frac{x}{a + 1}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if a < -4.9000000000000003e23 or 8.2e18 < a Initial program 75.2%
associate-/l*71.2%
associate-/l*71.1%
Simplified71.1%
clear-num71.1%
un-div-inv72.3%
Applied egg-rr72.3%
Taylor expanded in a around inf 61.9%
if -4.9000000000000003e23 < a < -5.6999999999999999e-189 or 1.55e-164 < a < 2.1499999999999999e-41Initial program 57.4%
associate-/l*55.8%
associate-/l*64.9%
Simplified64.9%
Taylor expanded in y around inf 65.0%
if -5.6999999999999999e-189 < a < 1.55e-164Initial program 74.1%
associate-/l*75.3%
associate-/l*78.4%
Simplified78.4%
Taylor expanded in y around 0 58.4%
Taylor expanded in a around 0 55.9%
*-commutative55.9%
associate-/l*60.4%
Applied egg-rr60.4%
if 2.1499999999999999e-41 < a < 3.49999999999999984e-7Initial program 99.8%
associate-/l*99.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in a around 0 94.2%
Taylor expanded in x around inf 69.9%
if 3.49999999999999984e-7 < a < 8.2e18Initial program 66.7%
associate-/l*66.7%
associate-/l*66.7%
Simplified66.7%
Taylor expanded in y around 0 52.2%
Final simplification62.3%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (+ x (/ (* y z) t)) a)))
(if (<= a -1.14e+26)
t_1
(if (<= a -5.4e-188)
(/ z b)
(if (<= a 9e-165)
(+ x (* z (/ y t)))
(if (<= a 7.5e-42)
(/ z b)
(if (<= a 2.9e-7)
(/ x (+ (/ (* y b) t) 1.0))
(if (<= a 8.2e+18) (/ x (+ a 1.0)) t_1))))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + ((y * z) / t)) / a;
double tmp;
if (a <= -1.14e+26) {
tmp = t_1;
} else if (a <= -5.4e-188) {
tmp = z / b;
} else if (a <= 9e-165) {
tmp = x + (z * (y / t));
} else if (a <= 7.5e-42) {
tmp = z / b;
} else if (a <= 2.9e-7) {
tmp = x / (((y * b) / t) + 1.0);
} else if (a <= 8.2e+18) {
tmp = x / (a + 1.0);
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = (x + ((y * z) / t)) / a
if (a <= (-1.14d+26)) then
tmp = t_1
else if (a <= (-5.4d-188)) then
tmp = z / b
else if (a <= 9d-165) then
tmp = x + (z * (y / t))
else if (a <= 7.5d-42) then
tmp = z / b
else if (a <= 2.9d-7) then
tmp = x / (((y * b) / t) + 1.0d0)
else if (a <= 8.2d+18) then
tmp = x / (a + 1.0d0)
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + ((y * z) / t)) / a;
double tmp;
if (a <= -1.14e+26) {
tmp = t_1;
} else if (a <= -5.4e-188) {
tmp = z / b;
} else if (a <= 9e-165) {
tmp = x + (z * (y / t));
} else if (a <= 7.5e-42) {
tmp = z / b;
} else if (a <= 2.9e-7) {
tmp = x / (((y * b) / t) + 1.0);
} else if (a <= 8.2e+18) {
tmp = x / (a + 1.0);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (x + ((y * z) / t)) / a tmp = 0 if a <= -1.14e+26: tmp = t_1 elif a <= -5.4e-188: tmp = z / b elif a <= 9e-165: tmp = x + (z * (y / t)) elif a <= 7.5e-42: tmp = z / b elif a <= 2.9e-7: tmp = x / (((y * b) / t) + 1.0) elif a <= 8.2e+18: tmp = x / (a + 1.0) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(x + Float64(Float64(y * z) / t)) / a) tmp = 0.0 if (a <= -1.14e+26) tmp = t_1; elseif (a <= -5.4e-188) tmp = Float64(z / b); elseif (a <= 9e-165) tmp = Float64(x + Float64(z * Float64(y / t))); elseif (a <= 7.5e-42) tmp = Float64(z / b); elseif (a <= 2.9e-7) tmp = Float64(x / Float64(Float64(Float64(y * b) / t) + 1.0)); elseif (a <= 8.2e+18) tmp = Float64(x / Float64(a + 1.0)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (x + ((y * z) / t)) / a; tmp = 0.0; if (a <= -1.14e+26) tmp = t_1; elseif (a <= -5.4e-188) tmp = z / b; elseif (a <= 9e-165) tmp = x + (z * (y / t)); elseif (a <= 7.5e-42) tmp = z / b; elseif (a <= 2.9e-7) tmp = x / (((y * b) / t) + 1.0); elseif (a <= 8.2e+18) tmp = x / (a + 1.0); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]}, If[LessEqual[a, -1.14e+26], t$95$1, If[LessEqual[a, -5.4e-188], N[(z / b), $MachinePrecision], If[LessEqual[a, 9e-165], N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 7.5e-42], N[(z / b), $MachinePrecision], If[LessEqual[a, 2.9e-7], N[(x / N[(N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 8.2e+18], N[(x / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], t$95$1]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x + \frac{y \cdot z}{t}}{a}\\
\mathbf{if}\;a \leq -1.14 \cdot 10^{+26}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq -5.4 \cdot 10^{-188}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;a \leq 9 \cdot 10^{-165}:\\
\;\;\;\;x + z \cdot \frac{y}{t}\\
\mathbf{elif}\;a \leq 7.5 \cdot 10^{-42}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;a \leq 2.9 \cdot 10^{-7}:\\
\;\;\;\;\frac{x}{\frac{y \cdot b}{t} + 1}\\
\mathbf{elif}\;a \leq 8.2 \cdot 10^{+18}:\\
\;\;\;\;\frac{x}{a + 1}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if a < -1.1399999999999999e26 or 8.2e18 < a Initial program 75.2%
associate-/l*71.2%
associate-/l*71.1%
Simplified71.1%
Taylor expanded in a around inf 64.8%
if -1.1399999999999999e26 < a < -5.4000000000000002e-188 or 8.99999999999999985e-165 < a < 7.49999999999999972e-42Initial program 57.4%
associate-/l*55.8%
associate-/l*64.9%
Simplified64.9%
Taylor expanded in y around inf 65.0%
if -5.4000000000000002e-188 < a < 8.99999999999999985e-165Initial program 74.1%
associate-/l*75.3%
associate-/l*78.4%
Simplified78.4%
Taylor expanded in y around 0 58.4%
Taylor expanded in a around 0 55.9%
*-commutative55.9%
associate-/l*60.4%
Applied egg-rr60.4%
if 7.49999999999999972e-42 < a < 2.8999999999999998e-7Initial program 99.8%
associate-/l*99.8%
associate-/l*99.8%
Simplified99.8%
Taylor expanded in a around 0 94.2%
Taylor expanded in x around inf 69.9%
if 2.8999999999999998e-7 < a < 8.2e18Initial program 66.7%
associate-/l*66.7%
associate-/l*66.7%
Simplified66.7%
Taylor expanded in y around 0 52.2%
Final simplification63.6%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (+ x (* y (/ z t))) (+ (* y (/ b t)) 1.0)))
(t_2 (/ (+ x (* z (/ y t))) (+ a 1.0))))
(if (<= a -6e+20)
t_2
(if (<= a 1.55e-164)
t_1
(if (<= a 7.2e-42) (/ z b) (if (<= a 0.25) t_1 t_2))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + (y * (z / t))) / ((y * (b / t)) + 1.0);
double t_2 = (x + (z * (y / t))) / (a + 1.0);
double tmp;
if (a <= -6e+20) {
tmp = t_2;
} else if (a <= 1.55e-164) {
tmp = t_1;
} else if (a <= 7.2e-42) {
tmp = z / b;
} else if (a <= 0.25) {
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 + (y * (z / t))) / ((y * (b / t)) + 1.0d0)
t_2 = (x + (z * (y / t))) / (a + 1.0d0)
if (a <= (-6d+20)) then
tmp = t_2
else if (a <= 1.55d-164) then
tmp = t_1
else if (a <= 7.2d-42) then
tmp = z / b
else if (a <= 0.25d0) 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 + (y * (z / t))) / ((y * (b / t)) + 1.0);
double t_2 = (x + (z * (y / t))) / (a + 1.0);
double tmp;
if (a <= -6e+20) {
tmp = t_2;
} else if (a <= 1.55e-164) {
tmp = t_1;
} else if (a <= 7.2e-42) {
tmp = z / b;
} else if (a <= 0.25) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (x + (y * (z / t))) / ((y * (b / t)) + 1.0) t_2 = (x + (z * (y / t))) / (a + 1.0) tmp = 0 if a <= -6e+20: tmp = t_2 elif a <= 1.55e-164: tmp = t_1 elif a <= 7.2e-42: tmp = z / b elif a <= 0.25: tmp = t_1 else: tmp = t_2 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(Float64(y * Float64(b / t)) + 1.0)) t_2 = Float64(Float64(x + Float64(z * Float64(y / t))) / Float64(a + 1.0)) tmp = 0.0 if (a <= -6e+20) tmp = t_2; elseif (a <= 1.55e-164) tmp = t_1; elseif (a <= 7.2e-42) tmp = Float64(z / b); elseif (a <= 0.25) tmp = t_1; else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (x + (y * (z / t))) / ((y * (b / t)) + 1.0); t_2 = (x + (z * (y / t))) / (a + 1.0); tmp = 0.0; if (a <= -6e+20) tmp = t_2; elseif (a <= 1.55e-164) tmp = t_1; elseif (a <= 7.2e-42) tmp = z / b; elseif (a <= 0.25) tmp = t_1; else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -6e+20], t$95$2, If[LessEqual[a, 1.55e-164], t$95$1, If[LessEqual[a, 7.2e-42], N[(z / b), $MachinePrecision], If[LessEqual[a, 0.25], t$95$1, t$95$2]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x + y \cdot \frac{z}{t}}{y \cdot \frac{b}{t} + 1}\\
t_2 := \frac{x + z \cdot \frac{y}{t}}{a + 1}\\
\mathbf{if}\;a \leq -6 \cdot 10^{+20}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;a \leq 1.55 \cdot 10^{-164}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq 7.2 \cdot 10^{-42}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;a \leq 0.25:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if a < -6e20 or 0.25 < a Initial program 75.2%
associate-/l*71.4%
associate-/l*71.2%
Simplified71.2%
clear-num71.2%
un-div-inv72.4%
Applied egg-rr72.4%
Taylor expanded in y around 0 62.4%
associate-/r/66.7%
Applied egg-rr66.7%
if -6e20 < a < 1.55e-164 or 7.2000000000000004e-42 < a < 0.25Initial program 71.8%
associate-/l*71.5%
associate-/l*75.7%
Simplified75.7%
Taylor expanded in a around 0 70.9%
associate-*l/75.1%
*-commutative75.1%
Simplified75.1%
if 1.55e-164 < a < 7.2000000000000004e-42Initial program 45.3%
associate-/l*45.7%
associate-/l*59.1%
Simplified59.1%
Taylor expanded in y around inf 81.3%
Final simplification71.6%
(FPCore (x y z t a b)
:precision binary64
(if (<= b -1.4e+180)
(/ z b)
(if (<= b -3.3e+61)
(/ x (+ (+ a (* b (/ y t))) 1.0))
(if (or (<= b -1.15e+37) (not (<= b 1.35e+34)))
(/ z b)
(/ (+ x (* y (/ z t))) (+ a 1.0))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -1.4e+180) {
tmp = z / b;
} else if (b <= -3.3e+61) {
tmp = x / ((a + (b * (y / t))) + 1.0);
} else if ((b <= -1.15e+37) || !(b <= 1.35e+34)) {
tmp = z / b;
} else {
tmp = (x + (y * (z / t))) / (a + 1.0);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (b <= (-1.4d+180)) then
tmp = z / b
else if (b <= (-3.3d+61)) then
tmp = x / ((a + (b * (y / t))) + 1.0d0)
else if ((b <= (-1.15d+37)) .or. (.not. (b <= 1.35d+34))) then
tmp = z / b
else
tmp = (x + (y * (z / t))) / (a + 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 tmp;
if (b <= -1.4e+180) {
tmp = z / b;
} else if (b <= -3.3e+61) {
tmp = x / ((a + (b * (y / t))) + 1.0);
} else if ((b <= -1.15e+37) || !(b <= 1.35e+34)) {
tmp = z / b;
} else {
tmp = (x + (y * (z / t))) / (a + 1.0);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -1.4e+180: tmp = z / b elif b <= -3.3e+61: tmp = x / ((a + (b * (y / t))) + 1.0) elif (b <= -1.15e+37) or not (b <= 1.35e+34): tmp = z / b else: tmp = (x + (y * (z / t))) / (a + 1.0) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -1.4e+180) tmp = Float64(z / b); elseif (b <= -3.3e+61) tmp = Float64(x / Float64(Float64(a + Float64(b * Float64(y / t))) + 1.0)); elseif ((b <= -1.15e+37) || !(b <= 1.35e+34)) tmp = Float64(z / b); else tmp = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(a + 1.0)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -1.4e+180) tmp = z / b; elseif (b <= -3.3e+61) tmp = x / ((a + (b * (y / t))) + 1.0); elseif ((b <= -1.15e+37) || ~((b <= 1.35e+34))) tmp = z / b; else tmp = (x + (y * (z / t))) / (a + 1.0); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -1.4e+180], N[(z / b), $MachinePrecision], If[LessEqual[b, -3.3e+61], N[(x / N[(N[(a + N[(b * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[b, -1.15e+37], N[Not[LessEqual[b, 1.35e+34]], $MachinePrecision]], N[(z / b), $MachinePrecision], N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -1.4 \cdot 10^{+180}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;b \leq -3.3 \cdot 10^{+61}:\\
\;\;\;\;\frac{x}{\left(a + b \cdot \frac{y}{t}\right) + 1}\\
\mathbf{elif}\;b \leq -1.15 \cdot 10^{+37} \lor \neg \left(b \leq 1.35 \cdot 10^{+34}\right):\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{a + 1}\\
\end{array}
\end{array}
if b < -1.40000000000000006e180 or -3.2999999999999998e61 < b < -1.15000000000000001e37 or 1.35e34 < b Initial program 56.1%
associate-/l*53.2%
associate-/l*58.9%
Simplified58.9%
Taylor expanded in y around inf 63.2%
if -1.40000000000000006e180 < b < -3.2999999999999998e61Initial program 70.0%
associate-*r/70.1%
*-commutative70.1%
div-inv70.1%
associate-*l*69.9%
Applied egg-rr69.9%
*-commutative69.9%
associate-*l/69.9%
*-un-lft-identity69.9%
associate-/r/70.1%
clear-num70.0%
Applied egg-rr70.0%
Taylor expanded in x around inf 55.0%
associate-/l*60.0%
Simplified60.0%
if -1.15000000000000001e37 < b < 1.35e34Initial program 81.7%
associate-/l*80.2%
associate-/l*80.9%
Simplified80.9%
Taylor expanded in y around 0 73.2%
Final simplification68.5%
(FPCore (x y z t a b)
:precision binary64
(if (<= b -3.7e+179)
(/ z b)
(if (<= b -6.5e+61)
(/ x (+ (+ a (* b (/ y t))) 1.0))
(if (or (<= b -1.46e+47) (not (<= b 1.45e+34)))
(/ z b)
(/ (+ x (* z (/ y t))) (+ a 1.0))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -3.7e+179) {
tmp = z / b;
} else if (b <= -6.5e+61) {
tmp = x / ((a + (b * (y / t))) + 1.0);
} else if ((b <= -1.46e+47) || !(b <= 1.45e+34)) {
tmp = z / b;
} else {
tmp = (x + (z * (y / t))) / (a + 1.0);
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (b <= (-3.7d+179)) then
tmp = z / b
else if (b <= (-6.5d+61)) then
tmp = x / ((a + (b * (y / t))) + 1.0d0)
else if ((b <= (-1.46d+47)) .or. (.not. (b <= 1.45d+34))) then
tmp = z / b
else
tmp = (x + (z * (y / t))) / (a + 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 tmp;
if (b <= -3.7e+179) {
tmp = z / b;
} else if (b <= -6.5e+61) {
tmp = x / ((a + (b * (y / t))) + 1.0);
} else if ((b <= -1.46e+47) || !(b <= 1.45e+34)) {
tmp = z / b;
} else {
tmp = (x + (z * (y / t))) / (a + 1.0);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -3.7e+179: tmp = z / b elif b <= -6.5e+61: tmp = x / ((a + (b * (y / t))) + 1.0) elif (b <= -1.46e+47) or not (b <= 1.45e+34): tmp = z / b else: tmp = (x + (z * (y / t))) / (a + 1.0) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -3.7e+179) tmp = Float64(z / b); elseif (b <= -6.5e+61) tmp = Float64(x / Float64(Float64(a + Float64(b * Float64(y / t))) + 1.0)); elseif ((b <= -1.46e+47) || !(b <= 1.45e+34)) tmp = Float64(z / b); else tmp = Float64(Float64(x + Float64(z * Float64(y / t))) / Float64(a + 1.0)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -3.7e+179) tmp = z / b; elseif (b <= -6.5e+61) tmp = x / ((a + (b * (y / t))) + 1.0); elseif ((b <= -1.46e+47) || ~((b <= 1.45e+34))) tmp = z / b; else tmp = (x + (z * (y / t))) / (a + 1.0); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -3.7e+179], N[(z / b), $MachinePrecision], If[LessEqual[b, -6.5e+61], N[(x / N[(N[(a + N[(b * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[b, -1.46e+47], N[Not[LessEqual[b, 1.45e+34]], $MachinePrecision]], N[(z / b), $MachinePrecision], N[(N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -3.7 \cdot 10^{+179}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;b \leq -6.5 \cdot 10^{+61}:\\
\;\;\;\;\frac{x}{\left(a + b \cdot \frac{y}{t}\right) + 1}\\
\mathbf{elif}\;b \leq -1.46 \cdot 10^{+47} \lor \neg \left(b \leq 1.45 \cdot 10^{+34}\right):\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;\frac{x + z \cdot \frac{y}{t}}{a + 1}\\
\end{array}
\end{array}
if b < -3.6999999999999999e179 or -6.4999999999999996e61 < b < -1.46000000000000006e47 or 1.4500000000000001e34 < b Initial program 56.1%
associate-/l*53.2%
associate-/l*58.9%
Simplified58.9%
Taylor expanded in y around inf 63.2%
if -3.6999999999999999e179 < b < -6.4999999999999996e61Initial program 70.0%
associate-*r/70.1%
*-commutative70.1%
div-inv70.1%
associate-*l*69.9%
Applied egg-rr69.9%
*-commutative69.9%
associate-*l/69.9%
*-un-lft-identity69.9%
associate-/r/70.1%
clear-num70.0%
Applied egg-rr70.0%
Taylor expanded in x around inf 55.0%
associate-/l*60.0%
Simplified60.0%
if -1.46000000000000006e47 < b < 1.4500000000000001e34Initial program 81.7%
associate-/l*80.2%
associate-/l*80.9%
Simplified80.9%
clear-num80.9%
un-div-inv81.9%
Applied egg-rr81.9%
Taylor expanded in y around 0 74.2%
associate-/r/78.1%
Applied egg-rr78.1%
Final simplification71.2%
(FPCore (x y z t a b)
:precision binary64
(if (<= b -9e+179)
(/ z b)
(if (<= b -5.6e+82)
(/ x (+ (+ a (* b (/ y t))) 1.0))
(if (<= b -5.5e+41)
(* y (/ z (+ (* y b) (* t (+ a 1.0)))))
(if (<= b 1.05e+34) (/ (+ x (* z (/ y t))) (+ a 1.0)) (/ z b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (b <= -9e+179) {
tmp = z / b;
} else if (b <= -5.6e+82) {
tmp = x / ((a + (b * (y / t))) + 1.0);
} else if (b <= -5.5e+41) {
tmp = y * (z / ((y * b) + (t * (a + 1.0))));
} else if (b <= 1.05e+34) {
tmp = (x + (z * (y / t))) / (a + 1.0);
} else {
tmp = 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 (b <= (-9d+179)) then
tmp = z / b
else if (b <= (-5.6d+82)) then
tmp = x / ((a + (b * (y / t))) + 1.0d0)
else if (b <= (-5.5d+41)) then
tmp = y * (z / ((y * b) + (t * (a + 1.0d0))))
else if (b <= 1.05d+34) then
tmp = (x + (z * (y / t))) / (a + 1.0d0)
else
tmp = 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 (b <= -9e+179) {
tmp = z / b;
} else if (b <= -5.6e+82) {
tmp = x / ((a + (b * (y / t))) + 1.0);
} else if (b <= -5.5e+41) {
tmp = y * (z / ((y * b) + (t * (a + 1.0))));
} else if (b <= 1.05e+34) {
tmp = (x + (z * (y / t))) / (a + 1.0);
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if b <= -9e+179: tmp = z / b elif b <= -5.6e+82: tmp = x / ((a + (b * (y / t))) + 1.0) elif b <= -5.5e+41: tmp = y * (z / ((y * b) + (t * (a + 1.0)))) elif b <= 1.05e+34: tmp = (x + (z * (y / t))) / (a + 1.0) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (b <= -9e+179) tmp = Float64(z / b); elseif (b <= -5.6e+82) tmp = Float64(x / Float64(Float64(a + Float64(b * Float64(y / t))) + 1.0)); elseif (b <= -5.5e+41) tmp = Float64(y * Float64(z / Float64(Float64(y * b) + Float64(t * Float64(a + 1.0))))); elseif (b <= 1.05e+34) tmp = Float64(Float64(x + Float64(z * Float64(y / t))) / Float64(a + 1.0)); else tmp = Float64(z / b); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (b <= -9e+179) tmp = z / b; elseif (b <= -5.6e+82) tmp = x / ((a + (b * (y / t))) + 1.0); elseif (b <= -5.5e+41) tmp = y * (z / ((y * b) + (t * (a + 1.0)))); elseif (b <= 1.05e+34) tmp = (x + (z * (y / t))) / (a + 1.0); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[b, -9e+179], N[(z / b), $MachinePrecision], If[LessEqual[b, -5.6e+82], N[(x / N[(N[(a + N[(b * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, -5.5e+41], N[(y * N[(z / N[(N[(y * b), $MachinePrecision] + N[(t * N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[b, 1.05e+34], N[(N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;b \leq -9 \cdot 10^{+179}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;b \leq -5.6 \cdot 10^{+82}:\\
\;\;\;\;\frac{x}{\left(a + b \cdot \frac{y}{t}\right) + 1}\\
\mathbf{elif}\;b \leq -5.5 \cdot 10^{+41}:\\
\;\;\;\;y \cdot \frac{z}{y \cdot b + t \cdot \left(a + 1\right)}\\
\mathbf{elif}\;b \leq 1.05 \cdot 10^{+34}:\\
\;\;\;\;\frac{x + z \cdot \frac{y}{t}}{a + 1}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if b < -9.0000000000000005e179 or 1.05000000000000009e34 < b Initial program 57.8%
associate-/l*54.8%
associate-/l*60.6%
Simplified60.6%
Taylor expanded in y around inf 62.0%
if -9.0000000000000005e179 < b < -5.6000000000000001e82Initial program 78.5%
associate-*r/78.6%
*-commutative78.6%
div-inv78.6%
associate-*l*78.3%
Applied egg-rr78.3%
*-commutative78.3%
associate-*l/78.3%
*-un-lft-identity78.3%
associate-/r/78.6%
clear-num78.5%
Applied egg-rr78.5%
Taylor expanded in x around inf 63.8%
associate-/l*71.1%
Simplified71.1%
if -5.6000000000000001e82 < b < -5.5000000000000003e41Initial program 35.9%
associate-/l*35.9%
associate-/l*36.0%
Simplified36.0%
Taylor expanded in x around 0 46.0%
associate-/l*56.5%
associate-+r+56.5%
associate-*r/56.5%
*-commutative56.5%
associate-/r/56.6%
+-commutative56.6%
associate-/r/56.5%
*-commutative56.5%
associate-*r/56.5%
associate-*l/56.7%
*-commutative56.7%
fma-define56.7%
Simplified56.7%
Taylor expanded in t around 0 67.6%
if -5.5000000000000003e41 < b < 1.05000000000000009e34Initial program 81.7%
associate-/l*80.2%
associate-/l*80.9%
Simplified80.9%
clear-num80.9%
un-div-inv81.9%
Applied egg-rr81.9%
Taylor expanded in y around 0 74.2%
associate-/r/78.1%
Applied egg-rr78.1%
Final simplification71.5%
(FPCore (x y z t a b) :precision binary64 (if (or (<= t -2.6e-174) (not (<= t 5.5e-212))) (/ (+ x (* y (/ z t))) (+ (+ a 1.0) (* y (/ b t)))) (/ z b)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -2.6e-174) || !(t <= 5.5e-212)) {
tmp = (x + (y * (z / t))) / ((a + 1.0) + (y * (b / t)));
} else {
tmp = 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 ((t <= (-2.6d-174)) .or. (.not. (t <= 5.5d-212))) then
tmp = (x + (y * (z / t))) / ((a + 1.0d0) + (y * (b / t)))
else
tmp = 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 ((t <= -2.6e-174) || !(t <= 5.5e-212)) {
tmp = (x + (y * (z / t))) / ((a + 1.0) + (y * (b / t)));
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t <= -2.6e-174) or not (t <= 5.5e-212): tmp = (x + (y * (z / t))) / ((a + 1.0) + (y * (b / t))) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((t <= -2.6e-174) || !(t <= 5.5e-212)) tmp = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(Float64(a + 1.0) + Float64(y * Float64(b / t)))); else tmp = Float64(z / b); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((t <= -2.6e-174) || ~((t <= 5.5e-212))) tmp = (x + (y * (z / t))) / ((a + 1.0) + (y * (b / t))); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[t, -2.6e-174], N[Not[LessEqual[t, 5.5e-212]], $MachinePrecision]], N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(a + 1.0), $MachinePrecision] + N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.6 \cdot 10^{-174} \lor \neg \left(t \leq 5.5 \cdot 10^{-212}\right):\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if t < -2.6000000000000002e-174 or 5.49999999999999995e-212 < t Initial program 80.0%
associate-/l*80.0%
associate-/l*84.8%
Simplified84.8%
if -2.6000000000000002e-174 < t < 5.49999999999999995e-212Initial program 42.0%
associate-/l*33.7%
associate-/l*30.2%
Simplified30.2%
Taylor expanded in y around inf 72.1%
Final simplification81.9%
(FPCore (x y z t a b)
:precision binary64
(if (<= t -2.6e-174)
(/ (+ x (* y (/ z t))) (+ (+ a 1.0) (* y (/ b t))))
(if (<= t 5.8e-212)
(/ z b)
(/ (+ x (* z (/ y t))) (+ (/ (* y b) t) (+ a 1.0))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= -2.6e-174) {
tmp = (x + (y * (z / t))) / ((a + 1.0) + (y * (b / t)));
} else if (t <= 5.8e-212) {
tmp = z / b;
} else {
tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 1.0));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (t <= (-2.6d-174)) then
tmp = (x + (y * (z / t))) / ((a + 1.0d0) + (y * (b / t)))
else if (t <= 5.8d-212) then
tmp = z / b
else
tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 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 tmp;
if (t <= -2.6e-174) {
tmp = (x + (y * (z / t))) / ((a + 1.0) + (y * (b / t)));
} else if (t <= 5.8e-212) {
tmp = z / b;
} else {
tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 1.0));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if t <= -2.6e-174: tmp = (x + (y * (z / t))) / ((a + 1.0) + (y * (b / t))) elif t <= 5.8e-212: tmp = z / b else: tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 1.0)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (t <= -2.6e-174) tmp = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(Float64(a + 1.0) + Float64(y * Float64(b / t)))); elseif (t <= 5.8e-212) tmp = Float64(z / b); else tmp = Float64(Float64(x + Float64(z * Float64(y / t))) / Float64(Float64(Float64(y * b) / t) + Float64(a + 1.0))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (t <= -2.6e-174) tmp = (x + (y * (z / t))) / ((a + 1.0) + (y * (b / t))); elseif (t <= 5.8e-212) tmp = z / b; else tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 1.0)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, -2.6e-174], N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(a + 1.0), $MachinePrecision] + N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 5.8e-212], N[(z / b), $MachinePrecision], N[(N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision] + N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.6 \cdot 10^{-174}:\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}\\
\mathbf{elif}\;t \leq 5.8 \cdot 10^{-212}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;\frac{x + z \cdot \frac{y}{t}}{\frac{y \cdot b}{t} + \left(a + 1\right)}\\
\end{array}
\end{array}
if t < -2.6000000000000002e-174Initial program 74.8%
associate-/l*77.6%
associate-/l*86.2%
Simplified86.2%
if -2.6000000000000002e-174 < t < 5.7999999999999999e-212Initial program 42.0%
associate-/l*33.7%
associate-/l*30.2%
Simplified30.2%
Taylor expanded in y around inf 72.1%
if 5.7999999999999999e-212 < t Initial program 85.2%
*-commutative25.9%
associate-/l*25.9%
Applied egg-rr85.3%
Final simplification82.6%
(FPCore (x y z t a b)
:precision binary64
(if (<= t -2.6e-174)
(/ (+ x (/ y (/ t z))) (+ (+ a 1.0) (* y (/ b t))))
(if (<= t 5.5e-212)
(/ z b)
(/ (+ x (* z (/ y t))) (+ (/ (* y b) t) (+ a 1.0))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= -2.6e-174) {
tmp = (x + (y / (t / z))) / ((a + 1.0) + (y * (b / t)));
} else if (t <= 5.5e-212) {
tmp = z / b;
} else {
tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 1.0));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (t <= (-2.6d-174)) then
tmp = (x + (y / (t / z))) / ((a + 1.0d0) + (y * (b / t)))
else if (t <= 5.5d-212) then
tmp = z / b
else
tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 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 tmp;
if (t <= -2.6e-174) {
tmp = (x + (y / (t / z))) / ((a + 1.0) + (y * (b / t)));
} else if (t <= 5.5e-212) {
tmp = z / b;
} else {
tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 1.0));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if t <= -2.6e-174: tmp = (x + (y / (t / z))) / ((a + 1.0) + (y * (b / t))) elif t <= 5.5e-212: tmp = z / b else: tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 1.0)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (t <= -2.6e-174) tmp = Float64(Float64(x + Float64(y / Float64(t / z))) / Float64(Float64(a + 1.0) + Float64(y * Float64(b / t)))); elseif (t <= 5.5e-212) tmp = Float64(z / b); else tmp = Float64(Float64(x + Float64(z * Float64(y / t))) / Float64(Float64(Float64(y * b) / t) + Float64(a + 1.0))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (t <= -2.6e-174) tmp = (x + (y / (t / z))) / ((a + 1.0) + (y * (b / t))); elseif (t <= 5.5e-212) tmp = z / b; else tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 1.0)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, -2.6e-174], N[(N[(x + N[(y / N[(t / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(a + 1.0), $MachinePrecision] + N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t, 5.5e-212], N[(z / b), $MachinePrecision], N[(N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision] + N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.6 \cdot 10^{-174}:\\
\;\;\;\;\frac{x + \frac{y}{\frac{t}{z}}}{\left(a + 1\right) + y \cdot \frac{b}{t}}\\
\mathbf{elif}\;t \leq 5.5 \cdot 10^{-212}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;\frac{x + z \cdot \frac{y}{t}}{\frac{y \cdot b}{t} + \left(a + 1\right)}\\
\end{array}
\end{array}
if t < -2.6000000000000002e-174Initial program 74.8%
associate-/l*77.6%
associate-/l*86.2%
Simplified86.2%
clear-num86.2%
un-div-inv86.7%
Applied egg-rr86.7%
if -2.6000000000000002e-174 < t < 5.49999999999999995e-212Initial program 42.0%
associate-/l*33.7%
associate-/l*30.2%
Simplified30.2%
Taylor expanded in y around inf 72.1%
if 5.49999999999999995e-212 < t Initial program 85.2%
*-commutative25.9%
associate-/l*25.9%
Applied egg-rr85.3%
Final simplification82.8%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ x (+ a 1.0))))
(if (<= t -3.7e+68)
t_1
(if (<= t -1.55e-49)
(/ x (+ (/ (* y b) t) 1.0))
(if (or (<= t -9.5e-100) (not (<= t 4.3e-41))) t_1 (/ z b))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x / (a + 1.0);
double tmp;
if (t <= -3.7e+68) {
tmp = t_1;
} else if (t <= -1.55e-49) {
tmp = x / (((y * b) / t) + 1.0);
} else if ((t <= -9.5e-100) || !(t <= 4.3e-41)) {
tmp = t_1;
} else {
tmp = 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) :: t_1
real(8) :: tmp
t_1 = x / (a + 1.0d0)
if (t <= (-3.7d+68)) then
tmp = t_1
else if (t <= (-1.55d-49)) then
tmp = x / (((y * b) / t) + 1.0d0)
else if ((t <= (-9.5d-100)) .or. (.not. (t <= 4.3d-41))) then
tmp = t_1
else
tmp = 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 t_1 = x / (a + 1.0);
double tmp;
if (t <= -3.7e+68) {
tmp = t_1;
} else if (t <= -1.55e-49) {
tmp = x / (((y * b) / t) + 1.0);
} else if ((t <= -9.5e-100) || !(t <= 4.3e-41)) {
tmp = t_1;
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x / (a + 1.0) tmp = 0 if t <= -3.7e+68: tmp = t_1 elif t <= -1.55e-49: tmp = x / (((y * b) / t) + 1.0) elif (t <= -9.5e-100) or not (t <= 4.3e-41): tmp = t_1 else: tmp = z / b return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x / Float64(a + 1.0)) tmp = 0.0 if (t <= -3.7e+68) tmp = t_1; elseif (t <= -1.55e-49) tmp = Float64(x / Float64(Float64(Float64(y * b) / t) + 1.0)); elseif ((t <= -9.5e-100) || !(t <= 4.3e-41)) tmp = t_1; else tmp = Float64(z / b); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x / (a + 1.0); tmp = 0.0; if (t <= -3.7e+68) tmp = t_1; elseif (t <= -1.55e-49) tmp = x / (((y * b) / t) + 1.0); elseif ((t <= -9.5e-100) || ~((t <= 4.3e-41))) tmp = t_1; else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x / N[(a + 1.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -3.7e+68], t$95$1, If[LessEqual[t, -1.55e-49], N[(x / N[(N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], If[Or[LessEqual[t, -9.5e-100], N[Not[LessEqual[t, 4.3e-41]], $MachinePrecision]], t$95$1, N[(z / b), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x}{a + 1}\\
\mathbf{if}\;t \leq -3.7 \cdot 10^{+68}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq -1.55 \cdot 10^{-49}:\\
\;\;\;\;\frac{x}{\frac{y \cdot b}{t} + 1}\\
\mathbf{elif}\;t \leq -9.5 \cdot 10^{-100} \lor \neg \left(t \leq 4.3 \cdot 10^{-41}\right):\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if t < -3.69999999999999998e68 or -1.55e-49 < t < -9.4999999999999992e-100 or 4.2999999999999999e-41 < t Initial program 83.8%
associate-/l*88.6%
associate-/l*95.7%
Simplified95.7%
Taylor expanded in y around 0 60.0%
if -3.69999999999999998e68 < t < -1.55e-49Initial program 60.9%
associate-/l*65.8%
associate-/l*75.2%
Simplified75.2%
Taylor expanded in a around 0 53.7%
Taylor expanded in x around inf 46.1%
if -9.4999999999999992e-100 < t < 4.2999999999999999e-41Initial program 60.1%
associate-/l*50.2%
associate-/l*47.6%
Simplified47.6%
Taylor expanded in y around inf 57.0%
Final simplification57.6%
(FPCore (x y z t a b) :precision binary64 (if (or (<= t -2.7e-174) (not (<= t 7e-159))) (/ x (+ (+ a (* b (/ y t))) 1.0)) (/ z b)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -2.7e-174) || !(t <= 7e-159)) {
tmp = x / ((a + (b * (y / t))) + 1.0);
} else {
tmp = 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 ((t <= (-2.7d-174)) .or. (.not. (t <= 7d-159))) then
tmp = x / ((a + (b * (y / t))) + 1.0d0)
else
tmp = 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 ((t <= -2.7e-174) || !(t <= 7e-159)) {
tmp = x / ((a + (b * (y / t))) + 1.0);
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t <= -2.7e-174) or not (t <= 7e-159): tmp = x / ((a + (b * (y / t))) + 1.0) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((t <= -2.7e-174) || !(t <= 7e-159)) tmp = Float64(x / Float64(Float64(a + Float64(b * Float64(y / t))) + 1.0)); else tmp = Float64(z / b); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((t <= -2.7e-174) || ~((t <= 7e-159))) tmp = x / ((a + (b * (y / t))) + 1.0); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[t, -2.7e-174], N[Not[LessEqual[t, 7e-159]], $MachinePrecision]], N[(x / N[(N[(a + N[(b * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + 1.0), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.7 \cdot 10^{-174} \lor \neg \left(t \leq 7 \cdot 10^{-159}\right):\\
\;\;\;\;\frac{x}{\left(a + b \cdot \frac{y}{t}\right) + 1}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if t < -2.69999999999999988e-174 or 7.00000000000000005e-159 < t Initial program 79.5%
associate-*r/80.4%
*-commutative80.4%
div-inv80.4%
associate-*l*81.6%
Applied egg-rr81.6%
*-commutative81.6%
associate-*l/81.6%
*-un-lft-identity81.6%
associate-/r/81.2%
clear-num81.2%
Applied egg-rr81.2%
Taylor expanded in x around inf 57.8%
associate-/l*60.3%
Simplified60.3%
if -2.69999999999999988e-174 < t < 7.00000000000000005e-159Initial program 49.0%
associate-/l*39.2%
associate-/l*36.2%
Simplified36.2%
Taylor expanded in y around inf 71.3%
Final simplification63.3%
(FPCore (x y z t a b) :precision binary64 (if (or (<= t -8.2e-100) (not (<= t 4.7e-41))) (/ x (+ a 1.0)) (/ z b)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -8.2e-100) || !(t <= 4.7e-41)) {
tmp = x / (a + 1.0);
} else {
tmp = 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 ((t <= (-8.2d-100)) .or. (.not. (t <= 4.7d-41))) then
tmp = x / (a + 1.0d0)
else
tmp = 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 ((t <= -8.2e-100) || !(t <= 4.7e-41)) {
tmp = x / (a + 1.0);
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t <= -8.2e-100) or not (t <= 4.7e-41): tmp = x / (a + 1.0) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((t <= -8.2e-100) || !(t <= 4.7e-41)) tmp = Float64(x / Float64(a + 1.0)); else tmp = Float64(z / b); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((t <= -8.2e-100) || ~((t <= 4.7e-41))) tmp = x / (a + 1.0); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[t, -8.2e-100], N[Not[LessEqual[t, 4.7e-41]], $MachinePrecision]], N[(x / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -8.2 \cdot 10^{-100} \lor \neg \left(t \leq 4.7 \cdot 10^{-41}\right):\\
\;\;\;\;\frac{x}{a + 1}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if t < -8.1999999999999998e-100 or 4.7000000000000003e-41 < t Initial program 80.7%
associate-/l*85.4%
associate-/l*92.9%
Simplified92.9%
Taylor expanded in y around 0 54.9%
if -8.1999999999999998e-100 < t < 4.7000000000000003e-41Initial program 60.1%
associate-/l*50.2%
associate-/l*47.6%
Simplified47.6%
Taylor expanded in y around inf 57.0%
Final simplification55.9%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -9e-27) (not (<= y 5.5e-182))) (/ z b) x))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -9e-27) || !(y <= 5.5e-182)) {
tmp = z / b;
} 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 <= (-9d-27)) .or. (.not. (y <= 5.5d-182))) then
tmp = z / b
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 <= -9e-27) || !(y <= 5.5e-182)) {
tmp = z / b;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -9e-27) or not (y <= 5.5e-182): tmp = z / b else: tmp = x return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -9e-27) || !(y <= 5.5e-182)) tmp = Float64(z / b); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -9e-27) || ~((y <= 5.5e-182))) tmp = z / b; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -9e-27], N[Not[LessEqual[y, 5.5e-182]], $MachinePrecision]], N[(z / b), $MachinePrecision], x]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -9 \cdot 10^{-27} \lor \neg \left(y \leq 5.5 \cdot 10^{-182}\right):\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if y < -9.0000000000000003e-27 or 5.49999999999999993e-182 < y Initial program 59.6%
associate-/l*62.8%
associate-/l*68.1%
Simplified68.1%
Taylor expanded in y around inf 47.0%
if -9.0000000000000003e-27 < y < 5.49999999999999993e-182Initial program 97.3%
associate-/l*83.9%
associate-/l*81.4%
Simplified81.4%
Taylor expanded in a around 0 50.1%
Taylor expanded in y around 0 32.2%
Final simplification42.5%
(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 71.3%
associate-/l*69.3%
associate-/l*72.2%
Simplified72.2%
Taylor expanded in a around 0 42.1%
Taylor expanded in y around 0 18.5%
Final simplification18.5%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1
(* 1.0 (* (+ x (* (/ y t) z)) (/ 1.0 (+ (+ a 1.0) (* (/ y t) b)))))))
(if (< t -1.3659085366310088e-271)
t_1
(if (< t 3.036967103737246e-130) (/ z b) t_1))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = 1.0 * ((x + ((y / t) * z)) * (1.0 / ((a + 1.0) + ((y / t) * b))));
double tmp;
if (t < -1.3659085366310088e-271) {
tmp = t_1;
} else if (t < 3.036967103737246e-130) {
tmp = z / b;
} 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 = 1.0d0 * ((x + ((y / t) * z)) * (1.0d0 / ((a + 1.0d0) + ((y / t) * b))))
if (t < (-1.3659085366310088d-271)) then
tmp = t_1
else if (t < 3.036967103737246d-130) then
tmp = z / b
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 = 1.0 * ((x + ((y / t) * z)) * (1.0 / ((a + 1.0) + ((y / t) * b))));
double tmp;
if (t < -1.3659085366310088e-271) {
tmp = t_1;
} else if (t < 3.036967103737246e-130) {
tmp = z / b;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = 1.0 * ((x + ((y / t) * z)) * (1.0 / ((a + 1.0) + ((y / t) * b)))) tmp = 0 if t < -1.3659085366310088e-271: tmp = t_1 elif t < 3.036967103737246e-130: tmp = z / b else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(1.0 * Float64(Float64(x + Float64(Float64(y / t) * z)) * Float64(1.0 / Float64(Float64(a + 1.0) + Float64(Float64(y / t) * b))))) tmp = 0.0 if (t < -1.3659085366310088e-271) tmp = t_1; elseif (t < 3.036967103737246e-130) tmp = Float64(z / b); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = 1.0 * ((x + ((y / t) * z)) * (1.0 / ((a + 1.0) + ((y / t) * b)))); tmp = 0.0; if (t < -1.3659085366310088e-271) tmp = t_1; elseif (t < 3.036967103737246e-130) tmp = z / b; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(1.0 * N[(N[(x + N[(N[(y / t), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision] * N[(1.0 / N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y / t), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[t, -1.3659085366310088e-271], t$95$1, If[Less[t, 3.036967103737246e-130], N[(z / b), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := 1 \cdot \left(\left(x + \frac{y}{t} \cdot z\right) \cdot \frac{1}{\left(a + 1\right) + \frac{y}{t} \cdot b}\right)\\
\mathbf{if}\;t < -1.3659085366310088 \cdot 10^{-271}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t < 3.036967103737246 \cdot 10^{-130}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
herbie shell --seed 2024040
(FPCore (x y z t a b)
:name "Diagrams.Solve.Tridiagonal:solveCyclicTriDiagonal from diagrams-solve-0.1, B"
:precision binary64
:herbie-target
(if (< t -1.3659085366310088e-271) (* 1.0 (* (+ x (* (/ y t) z)) (/ 1.0 (+ (+ a 1.0) (* (/ y t) b))))) (if (< t 3.036967103737246e-130) (/ z b) (* 1.0 (* (+ x (* (/ y t) z)) (/ 1.0 (+ (+ a 1.0) (* (/ y t) b)))))))
(/ (+ x (/ (* y z) t)) (+ (+ a 1.0) (/ (* y b) t))))