
(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 17 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 (/ (* y b) t))
(t_2 (/ (+ x (/ (* y z) t)) (+ t_1 (+ a 1.0))))
(t_3 (+ 1.0 (+ a t_1)))
(t_4 (* z (+ (/ x (* z t_3)) (/ y (* t t_3))))))
(if (<= t_2 (- INFINITY))
t_4
(if (<= t_2 5e+250) t_2 (if (<= t_2 INFINITY) t_4 (/ z b))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (y * b) / t;
double t_2 = (x + ((y * z) / t)) / (t_1 + (a + 1.0));
double t_3 = 1.0 + (a + t_1);
double t_4 = z * ((x / (z * t_3)) + (y / (t * t_3)));
double tmp;
if (t_2 <= -((double) INFINITY)) {
tmp = t_4;
} else if (t_2 <= 5e+250) {
tmp = t_2;
} else if (t_2 <= ((double) INFINITY)) {
tmp = t_4;
} 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 = (y * b) / t;
double t_2 = (x + ((y * z) / t)) / (t_1 + (a + 1.0));
double t_3 = 1.0 + (a + t_1);
double t_4 = z * ((x / (z * t_3)) + (y / (t * t_3)));
double tmp;
if (t_2 <= -Double.POSITIVE_INFINITY) {
tmp = t_4;
} else if (t_2 <= 5e+250) {
tmp = t_2;
} else if (t_2 <= Double.POSITIVE_INFINITY) {
tmp = t_4;
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (y * b) / t t_2 = (x + ((y * z) / t)) / (t_1 + (a + 1.0)) t_3 = 1.0 + (a + t_1) t_4 = z * ((x / (z * t_3)) + (y / (t * t_3))) tmp = 0 if t_2 <= -math.inf: tmp = t_4 elif t_2 <= 5e+250: tmp = t_2 elif t_2 <= math.inf: tmp = t_4 else: tmp = z / b return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(y * b) / t) t_2 = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(t_1 + Float64(a + 1.0))) t_3 = Float64(1.0 + Float64(a + t_1)) t_4 = Float64(z * Float64(Float64(x / Float64(z * t_3)) + Float64(y / Float64(t * t_3)))) tmp = 0.0 if (t_2 <= Float64(-Inf)) tmp = t_4; elseif (t_2 <= 5e+250) tmp = t_2; elseif (t_2 <= Inf) tmp = t_4; else tmp = Float64(z / b); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (y * b) / t; t_2 = (x + ((y * z) / t)) / (t_1 + (a + 1.0)); t_3 = 1.0 + (a + t_1); t_4 = z * ((x / (z * t_3)) + (y / (t * t_3))); tmp = 0.0; if (t_2 <= -Inf) tmp = t_4; elseif (t_2 <= 5e+250) tmp = t_2; elseif (t_2 <= Inf) tmp = t_4; else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(t$95$1 + N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(1.0 + N[(a + t$95$1), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[(z * N[(N[(x / N[(z * t$95$3), $MachinePrecision]), $MachinePrecision] + N[(y / N[(t * t$95$3), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, (-Infinity)], t$95$4, If[LessEqual[t$95$2, 5e+250], t$95$2, If[LessEqual[t$95$2, Infinity], t$95$4, N[(z / b), $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{y \cdot b}{t}\\
t_2 := \frac{x + \frac{y \cdot z}{t}}{t\_1 + \left(a + 1\right)}\\
t_3 := 1 + \left(a + t\_1\right)\\
t_4 := z \cdot \left(\frac{x}{z \cdot t\_3} + \frac{y}{t \cdot t\_3}\right)\\
\mathbf{if}\;t\_2 \leq -\infty:\\
\;\;\;\;t\_4\\
\mathbf{elif}\;t\_2 \leq 5 \cdot 10^{+250}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;t\_2 \leq \infty:\\
\;\;\;\;t\_4\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a #s(literal 1 binary64)) (/.f64 (*.f64 y b) t))) < -inf.0 or 5.0000000000000002e250 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a #s(literal 1 binary64)) (/.f64 (*.f64 y b) t))) < +inf.0Initial program 42.4%
associate-/l*60.7%
associate-/l*60.7%
Simplified60.7%
Taylor expanded in z around inf 92.6%
if -inf.0 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a #s(literal 1 binary64)) (/.f64 (*.f64 y b) t))) < 5.0000000000000002e250Initial program 92.3%
if +inf.0 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a #s(literal 1 binary64)) (/.f64 (*.f64 y b) t))) Initial program 0.0%
associate-/l*0.4%
associate-/l*5.3%
Simplified5.3%
Taylor expanded in y around inf 100.0%
Final simplification92.9%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (+ (/ (* y b) t) (+ a 1.0))) (t_2 (/ (+ x (/ (* y z) t)) t_1)))
(if (<= t_2 -1e+31)
(/ (+ x (* z (/ y t))) t_1)
(if (<= t_2 2e+283) t_2 (/ z b)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = ((y * b) / t) + (a + 1.0);
double t_2 = (x + ((y * z) / t)) / t_1;
double tmp;
if (t_2 <= -1e+31) {
tmp = (x + (z * (y / t))) / t_1;
} else if (t_2 <= 2e+283) {
tmp = t_2;
} 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) :: t_2
real(8) :: tmp
t_1 = ((y * b) / t) + (a + 1.0d0)
t_2 = (x + ((y * z) / t)) / t_1
if (t_2 <= (-1d+31)) then
tmp = (x + (z * (y / t))) / t_1
else if (t_2 <= 2d+283) then
tmp = t_2
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 = ((y * b) / t) + (a + 1.0);
double t_2 = (x + ((y * z) / t)) / t_1;
double tmp;
if (t_2 <= -1e+31) {
tmp = (x + (z * (y / t))) / t_1;
} else if (t_2 <= 2e+283) {
tmp = t_2;
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = ((y * b) / t) + (a + 1.0) t_2 = (x + ((y * z) / t)) / t_1 tmp = 0 if t_2 <= -1e+31: tmp = (x + (z * (y / t))) / t_1 elif t_2 <= 2e+283: tmp = t_2 else: tmp = z / b return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(Float64(y * b) / t) + Float64(a + 1.0)) t_2 = Float64(Float64(x + Float64(Float64(y * z) / t)) / t_1) tmp = 0.0 if (t_2 <= -1e+31) tmp = Float64(Float64(x + Float64(z * Float64(y / t))) / t_1); elseif (t_2 <= 2e+283) tmp = t_2; else tmp = Float64(z / b); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = ((y * b) / t) + (a + 1.0); t_2 = (x + ((y * z) / t)) / t_1; tmp = 0.0; if (t_2 <= -1e+31) tmp = (x + (z * (y / t))) / t_1; elseif (t_2 <= 2e+283) 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[(N[(y * b), $MachinePrecision] / t), $MachinePrecision] + N[(a + 1.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision]}, If[LessEqual[t$95$2, -1e+31], N[(N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / t$95$1), $MachinePrecision], If[LessEqual[t$95$2, 2e+283], t$95$2, N[(z / b), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{y \cdot b}{t} + \left(a + 1\right)\\
t_2 := \frac{x + \frac{y \cdot z}{t}}{t\_1}\\
\mathbf{if}\;t\_2 \leq -1 \cdot 10^{+31}:\\
\;\;\;\;\frac{x + z \cdot \frac{y}{t}}{t\_1}\\
\mathbf{elif}\;t\_2 \leq 2 \cdot 10^{+283}:\\
\;\;\;\;t\_2\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a #s(literal 1 binary64)) (/.f64 (*.f64 y b) t))) < -9.9999999999999996e30Initial program 75.3%
*-commutative75.3%
associate-/l*87.7%
Applied egg-rr87.7%
if -9.9999999999999996e30 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a #s(literal 1 binary64)) (/.f64 (*.f64 y b) t))) < 1.99999999999999991e283Initial program 91.3%
if 1.99999999999999991e283 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a #s(literal 1 binary64)) (/.f64 (*.f64 y b) t))) Initial program 14.8%
associate-/l*22.5%
associate-/l*25.1%
Simplified25.1%
Taylor expanded in y around inf 79.4%
Final simplification88.9%
(FPCore (x y z t a b) :precision binary64 (if (or (<= t -2.65e-112) (not (<= t 2.15e-97))) (/ (+ x (* y (/ z t))) (+ (+ a 1.0) (/ y (/ t b)))) (/ (* y z) (+ (* 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.65e-112) || !(t <= 2.15e-97)) {
tmp = (x + (y * (z / t))) / ((a + 1.0) + (y / (t / b)));
} else {
tmp = (y * z) / ((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.65d-112)) .or. (.not. (t <= 2.15d-97))) then
tmp = (x + (y * (z / t))) / ((a + 1.0d0) + (y / (t / b)))
else
tmp = (y * z) / ((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.65e-112) || !(t <= 2.15e-97)) {
tmp = (x + (y * (z / t))) / ((a + 1.0) + (y / (t / b)));
} else {
tmp = (y * z) / ((y * b) + (t * (a + 1.0)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t <= -2.65e-112) or not (t <= 2.15e-97): tmp = (x + (y * (z / t))) / ((a + 1.0) + (y / (t / b))) else: tmp = (y * z) / ((y * b) + (t * (a + 1.0))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((t <= -2.65e-112) || !(t <= 2.15e-97)) tmp = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(Float64(a + 1.0) + Float64(y / Float64(t / b)))); else tmp = Float64(Float64(y * z) / Float64(Float64(y * b) + Float64(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.65e-112) || ~((t <= 2.15e-97))) tmp = (x + (y * (z / t))) / ((a + 1.0) + (y / (t / b))); else tmp = (y * z) / ((y * b) + (t * (a + 1.0))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[t, -2.65e-112], N[Not[LessEqual[t, 2.15e-97]], $MachinePrecision]], N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(a + 1.0), $MachinePrecision] + N[(y / N[(t / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(y * z), $MachinePrecision] / N[(N[(y * b), $MachinePrecision] + N[(t * N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.65 \cdot 10^{-112} \lor \neg \left(t \leq 2.15 \cdot 10^{-97}\right):\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \frac{y}{\frac{t}{b}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{y \cdot z}{y \cdot b + t \cdot \left(a + 1\right)}\\
\end{array}
\end{array}
if t < -2.6500000000000002e-112 or 2.15e-97 < t Initial program 83.4%
associate-/l*87.4%
associate-/l*88.5%
Simplified88.5%
clear-num88.5%
un-div-inv88.5%
Applied egg-rr88.5%
if -2.6500000000000002e-112 < t < 2.15e-97Initial program 64.9%
associate-/l*54.0%
associate-/l*49.6%
Simplified49.6%
Taylor expanded in x around 0 58.5%
Taylor expanded in t around 0 68.5%
Final simplification81.7%
(FPCore (x y z t a b) :precision binary64 (if (or (<= t -2.8e-112) (not (<= t 1.9e-95))) (/ (+ x (* y (/ z t))) (+ (+ a 1.0) (* y (/ b t)))) (/ (* y z) (+ (* 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.8e-112) || !(t <= 1.9e-95)) {
tmp = (x + (y * (z / t))) / ((a + 1.0) + (y * (b / t)));
} else {
tmp = (y * z) / ((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.8d-112)) .or. (.not. (t <= 1.9d-95))) then
tmp = (x + (y * (z / t))) / ((a + 1.0d0) + (y * (b / t)))
else
tmp = (y * z) / ((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.8e-112) || !(t <= 1.9e-95)) {
tmp = (x + (y * (z / t))) / ((a + 1.0) + (y * (b / t)));
} else {
tmp = (y * z) / ((y * b) + (t * (a + 1.0)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t <= -2.8e-112) or not (t <= 1.9e-95): tmp = (x + (y * (z / t))) / ((a + 1.0) + (y * (b / t))) else: tmp = (y * z) / ((y * b) + (t * (a + 1.0))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((t <= -2.8e-112) || !(t <= 1.9e-95)) tmp = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(Float64(a + 1.0) + Float64(y * Float64(b / t)))); else tmp = Float64(Float64(y * z) / Float64(Float64(y * b) + Float64(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.8e-112) || ~((t <= 1.9e-95))) tmp = (x + (y * (z / t))) / ((a + 1.0) + (y * (b / t))); else tmp = (y * z) / ((y * b) + (t * (a + 1.0))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[t, -2.8e-112], N[Not[LessEqual[t, 1.9e-95]], $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[(N[(y * z), $MachinePrecision] / N[(N[(y * b), $MachinePrecision] + N[(t * N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.8 \cdot 10^{-112} \lor \neg \left(t \leq 1.9 \cdot 10^{-95}\right):\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + y \cdot \frac{b}{t}}\\
\mathbf{else}:\\
\;\;\;\;\frac{y \cdot z}{y \cdot b + t \cdot \left(a + 1\right)}\\
\end{array}
\end{array}
if t < -2.80000000000000023e-112 or 1.8999999999999999e-95 < t Initial program 83.4%
associate-/l*87.4%
associate-/l*88.5%
Simplified88.5%
if -2.80000000000000023e-112 < t < 1.8999999999999999e-95Initial program 64.9%
associate-/l*54.0%
associate-/l*49.6%
Simplified49.6%
Taylor expanded in x around 0 58.5%
Taylor expanded in t around 0 68.5%
Final simplification81.7%
(FPCore (x y z t a b)
:precision binary64
(if (<= t -9.5e-204)
(/ (+ x (* z (/ y t))) (+ (/ (* y b) t) (+ a 1.0)))
(if (<= t 9.5e-96)
(/ (* y z) (+ (* y b) (* t (+ a 1.0))))
(/ (+ x (* y (/ z t))) (+ (+ a 1.0) (/ y (/ t b)))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (t <= -9.5e-204) {
tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 1.0));
} else if (t <= 9.5e-96) {
tmp = (y * z) / ((y * b) + (t * (a + 1.0)));
} else {
tmp = (x + (y * (z / t))) / ((a + 1.0) + (y / (t / 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 <= (-9.5d-204)) then
tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 1.0d0))
else if (t <= 9.5d-96) then
tmp = (y * z) / ((y * b) + (t * (a + 1.0d0)))
else
tmp = (x + (y * (z / t))) / ((a + 1.0d0) + (y / (t / 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 <= -9.5e-204) {
tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 1.0));
} else if (t <= 9.5e-96) {
tmp = (y * z) / ((y * b) + (t * (a + 1.0)));
} else {
tmp = (x + (y * (z / t))) / ((a + 1.0) + (y / (t / b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if t <= -9.5e-204: tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 1.0)) elif t <= 9.5e-96: tmp = (y * z) / ((y * b) + (t * (a + 1.0))) else: tmp = (x + (y * (z / t))) / ((a + 1.0) + (y / (t / b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (t <= -9.5e-204) tmp = Float64(Float64(x + Float64(z * Float64(y / t))) / Float64(Float64(Float64(y * b) / t) + Float64(a + 1.0))); elseif (t <= 9.5e-96) tmp = Float64(Float64(y * z) / Float64(Float64(y * b) + Float64(t * Float64(a + 1.0)))); else tmp = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(Float64(a + 1.0) + Float64(y / Float64(t / b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (t <= -9.5e-204) tmp = (x + (z * (y / t))) / (((y * b) / t) + (a + 1.0)); elseif (t <= 9.5e-96) tmp = (y * z) / ((y * b) + (t * (a + 1.0))); else tmp = (x + (y * (z / t))) / ((a + 1.0) + (y / (t / b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[t, -9.5e-204], 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], If[LessEqual[t, 9.5e-96], N[(N[(y * z), $MachinePrecision] / N[(N[(y * b), $MachinePrecision] + N[(t * N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(N[(a + 1.0), $MachinePrecision] + N[(y / N[(t / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -9.5 \cdot 10^{-204}:\\
\;\;\;\;\frac{x + z \cdot \frac{y}{t}}{\frac{y \cdot b}{t} + \left(a + 1\right)}\\
\mathbf{elif}\;t \leq 9.5 \cdot 10^{-96}:\\
\;\;\;\;\frac{y \cdot z}{y \cdot b + t \cdot \left(a + 1\right)}\\
\mathbf{else}:\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \frac{y}{\frac{t}{b}}}\\
\end{array}
\end{array}
if t < -9.50000000000000063e-204Initial program 81.2%
*-commutative81.2%
associate-/l*86.7%
Applied egg-rr86.7%
if -9.50000000000000063e-204 < t < 9.4999999999999993e-96Initial program 61.5%
associate-/l*52.8%
associate-/l*48.5%
Simplified48.5%
Taylor expanded in x around 0 59.9%
Taylor expanded in t around 0 71.6%
if 9.4999999999999993e-96 < t Initial program 84.1%
associate-/l*86.3%
associate-/l*87.4%
Simplified87.4%
clear-num87.5%
un-div-inv87.5%
Applied egg-rr87.5%
Final simplification83.0%
(FPCore (x y z t a b)
:precision binary64
(if (<= a -1650000000.0)
(/ (+ x (/ (* y z) t)) a)
(if (<= a 100000000.0)
(/ (+ x (* y (/ z t))) (+ 1.0 (* y (/ b t))))
(/ (+ x (* z (/ y t))) (+ a 1.0)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= -1650000000.0) {
tmp = (x + ((y * z) / t)) / a;
} else if (a <= 100000000.0) {
tmp = (x + (y * (z / t))) / (1.0 + (y * (b / t)));
} 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 (a <= (-1650000000.0d0)) then
tmp = (x + ((y * z) / t)) / a
else if (a <= 100000000.0d0) then
tmp = (x + (y * (z / t))) / (1.0d0 + (y * (b / t)))
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 (a <= -1650000000.0) {
tmp = (x + ((y * z) / t)) / a;
} else if (a <= 100000000.0) {
tmp = (x + (y * (z / t))) / (1.0 + (y * (b / t)));
} else {
tmp = (x + (z * (y / t))) / (a + 1.0);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if a <= -1650000000.0: tmp = (x + ((y * z) / t)) / a elif a <= 100000000.0: tmp = (x + (y * (z / t))) / (1.0 + (y * (b / t))) else: tmp = (x + (z * (y / t))) / (a + 1.0) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (a <= -1650000000.0) tmp = Float64(Float64(x + Float64(Float64(y * z) / t)) / a); elseif (a <= 100000000.0) tmp = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(1.0 + Float64(y * Float64(b / t)))); 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 (a <= -1650000000.0) tmp = (x + ((y * z) / t)) / a; elseif (a <= 100000000.0) tmp = (x + (y * (z / t))) / (1.0 + (y * (b / t))); else tmp = (x + (z * (y / t))) / (a + 1.0); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[a, -1650000000.0], N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[a, 100000000.0], N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(1.0 + N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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}\;a \leq -1650000000:\\
\;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a}\\
\mathbf{elif}\;a \leq 100000000:\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{1 + y \cdot \frac{b}{t}}\\
\mathbf{else}:\\
\;\;\;\;\frac{x + z \cdot \frac{y}{t}}{a + 1}\\
\end{array}
\end{array}
if a < -1.65e9Initial program 81.7%
associate-/l*74.8%
associate-/l*72.1%
Simplified72.1%
Taylor expanded in a around inf 64.5%
if -1.65e9 < a < 1e8Initial program 78.0%
associate-/l*79.6%
associate-/l*79.6%
Simplified79.6%
Taylor expanded in a around 0 79.6%
associate-*l/79.6%
*-commutative79.6%
Simplified79.6%
if 1e8 < a Initial program 70.0%
associate-/l*70.0%
associate-/l*70.0%
Simplified70.0%
Taylor expanded in b around 0 64.0%
*-commutative70.0%
associate-/l*71.3%
Applied egg-rr67.7%
Final simplification72.6%
(FPCore (x y z t a b)
:precision binary64
(if (<= a -1020000000.0)
(/ (+ x (/ (* y z) t)) a)
(if (<= a -3.8e-289)
(/ x (+ 1.0 (/ (* y b) t)))
(if (<= a 1.25e-15) (+ x (* y (/ z t))) (/ (+ x (* z (/ y t))) a)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= -1020000000.0) {
tmp = (x + ((y * z) / t)) / a;
} else if (a <= -3.8e-289) {
tmp = x / (1.0 + ((y * b) / t));
} else if (a <= 1.25e-15) {
tmp = x + (y * (z / t));
} else {
tmp = (x + (z * (y / t))) / a;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (a <= (-1020000000.0d0)) then
tmp = (x + ((y * z) / t)) / a
else if (a <= (-3.8d-289)) then
tmp = x / (1.0d0 + ((y * b) / t))
else if (a <= 1.25d-15) then
tmp = x + (y * (z / t))
else
tmp = (x + (z * (y / t))) / a
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= -1020000000.0) {
tmp = (x + ((y * z) / t)) / a;
} else if (a <= -3.8e-289) {
tmp = x / (1.0 + ((y * b) / t));
} else if (a <= 1.25e-15) {
tmp = x + (y * (z / t));
} else {
tmp = (x + (z * (y / t))) / a;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if a <= -1020000000.0: tmp = (x + ((y * z) / t)) / a elif a <= -3.8e-289: tmp = x / (1.0 + ((y * b) / t)) elif a <= 1.25e-15: tmp = x + (y * (z / t)) else: tmp = (x + (z * (y / t))) / a return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (a <= -1020000000.0) tmp = Float64(Float64(x + Float64(Float64(y * z) / t)) / a); elseif (a <= -3.8e-289) tmp = Float64(x / Float64(1.0 + Float64(Float64(y * b) / t))); elseif (a <= 1.25e-15) tmp = Float64(x + Float64(y * Float64(z / t))); else tmp = Float64(Float64(x + Float64(z * Float64(y / t))) / a); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (a <= -1020000000.0) tmp = (x + ((y * z) / t)) / a; elseif (a <= -3.8e-289) tmp = x / (1.0 + ((y * b) / t)); elseif (a <= 1.25e-15) tmp = x + (y * (z / t)); else tmp = (x + (z * (y / t))) / a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[a, -1020000000.0], N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision], If[LessEqual[a, -3.8e-289], N[(x / N[(1.0 + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.25e-15], N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1020000000:\\
\;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a}\\
\mathbf{elif}\;a \leq -3.8 \cdot 10^{-289}:\\
\;\;\;\;\frac{x}{1 + \frac{y \cdot b}{t}}\\
\mathbf{elif}\;a \leq 1.25 \cdot 10^{-15}:\\
\;\;\;\;x + y \cdot \frac{z}{t}\\
\mathbf{else}:\\
\;\;\;\;\frac{x + z \cdot \frac{y}{t}}{a}\\
\end{array}
\end{array}
if a < -1.02e9Initial program 81.7%
associate-/l*74.8%
associate-/l*72.1%
Simplified72.1%
Taylor expanded in a around inf 64.5%
if -1.02e9 < a < -3.80000000000000009e-289Initial program 76.5%
associate-/l*77.9%
associate-/l*76.3%
Simplified76.3%
Taylor expanded in x around inf 58.9%
Taylor expanded in a around 0 58.9%
if -3.80000000000000009e-289 < a < 1.25e-15Initial program 80.5%
associate-/l*82.4%
associate-/l*84.0%
Simplified84.0%
Taylor expanded in b around 0 56.8%
*-commutative80.5%
associate-/l*80.3%
Applied egg-rr58.2%
Taylor expanded in a around 0 56.8%
associate-/l*58.7%
Simplified58.7%
if 1.25e-15 < a Initial program 69.4%
associate-/l*69.3%
associate-/l*69.3%
Simplified69.3%
Taylor expanded in b around 0 62.1%
*-commutative69.4%
associate-/l*70.7%
Applied egg-rr65.7%
Taylor expanded in a around inf 65.1%
Final simplification61.9%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (+ x (* z (/ y t))) a)))
(if (<= a -980000000.0)
t_1
(if (<= a -4.6e-289)
(/ x (+ 1.0 (/ (* y b) t)))
(if (<= a 1.25e-15) (+ x (* y (/ z t))) t_1)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + (z * (y / t))) / a;
double tmp;
if (a <= -980000000.0) {
tmp = t_1;
} else if (a <= -4.6e-289) {
tmp = x / (1.0 + ((y * b) / t));
} else if (a <= 1.25e-15) {
tmp = x + (y * (z / t));
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: t_1
real(8) :: tmp
t_1 = (x + (z * (y / t))) / a
if (a <= (-980000000.0d0)) then
tmp = t_1
else if (a <= (-4.6d-289)) then
tmp = x / (1.0d0 + ((y * b) / t))
else if (a <= 1.25d-15) then
tmp = x + (y * (z / t))
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 + (z * (y / t))) / a;
double tmp;
if (a <= -980000000.0) {
tmp = t_1;
} else if (a <= -4.6e-289) {
tmp = x / (1.0 + ((y * b) / t));
} else if (a <= 1.25e-15) {
tmp = x + (y * (z / t));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (x + (z * (y / t))) / a tmp = 0 if a <= -980000000.0: tmp = t_1 elif a <= -4.6e-289: tmp = x / (1.0 + ((y * b) / t)) elif a <= 1.25e-15: tmp = x + (y * (z / t)) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(x + Float64(z * Float64(y / t))) / a) tmp = 0.0 if (a <= -980000000.0) tmp = t_1; elseif (a <= -4.6e-289) tmp = Float64(x / Float64(1.0 + Float64(Float64(y * b) / t))); elseif (a <= 1.25e-15) tmp = Float64(x + Float64(y * Float64(z / t))); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (x + (z * (y / t))) / a; tmp = 0.0; if (a <= -980000000.0) tmp = t_1; elseif (a <= -4.6e-289) tmp = x / (1.0 + ((y * b) / t)); elseif (a <= 1.25e-15) tmp = x + (y * (z / t)); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(x + N[(z * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / a), $MachinePrecision]}, If[LessEqual[a, -980000000.0], t$95$1, If[LessEqual[a, -4.6e-289], N[(x / N[(1.0 + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[a, 1.25e-15], N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x + z \cdot \frac{y}{t}}{a}\\
\mathbf{if}\;a \leq -980000000:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a \leq -4.6 \cdot 10^{-289}:\\
\;\;\;\;\frac{x}{1 + \frac{y \cdot b}{t}}\\
\mathbf{elif}\;a \leq 1.25 \cdot 10^{-15}:\\
\;\;\;\;x + y \cdot \frac{z}{t}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if a < -9.8e8 or 1.25e-15 < a Initial program 75.9%
associate-/l*72.2%
associate-/l*70.8%
Simplified70.8%
Taylor expanded in b around 0 63.3%
*-commutative75.9%
associate-/l*76.4%
Applied egg-rr65.0%
Taylor expanded in a around inf 64.8%
if -9.8e8 < a < -4.6000000000000004e-289Initial program 76.5%
associate-/l*77.9%
associate-/l*76.3%
Simplified76.3%
Taylor expanded in x around inf 58.9%
Taylor expanded in a around 0 58.9%
if -4.6000000000000004e-289 < a < 1.25e-15Initial program 80.5%
associate-/l*82.4%
associate-/l*84.0%
Simplified84.0%
Taylor expanded in b around 0 56.8%
*-commutative80.5%
associate-/l*80.3%
Applied egg-rr58.2%
Taylor expanded in a around 0 56.8%
associate-/l*58.7%
Simplified58.7%
Final simplification61.9%
(FPCore (x y z t a b) :precision binary64 (if (or (<= t -1.56e-78) (not (<= t 6.5e-73))) (/ (+ x (* y (/ z t))) (+ a 1.0)) (/ (* y z) (+ (* y b) (* t (+ a 1.0))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((t <= -1.56e-78) || !(t <= 6.5e-73)) {
tmp = (x + (y * (z / t))) / (a + 1.0);
} else {
tmp = (y * z) / ((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 <= (-1.56d-78)) .or. (.not. (t <= 6.5d-73))) then
tmp = (x + (y * (z / t))) / (a + 1.0d0)
else
tmp = (y * z) / ((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 <= -1.56e-78) || !(t <= 6.5e-73)) {
tmp = (x + (y * (z / t))) / (a + 1.0);
} else {
tmp = (y * z) / ((y * b) + (t * (a + 1.0)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (t <= -1.56e-78) or not (t <= 6.5e-73): tmp = (x + (y * (z / t))) / (a + 1.0) else: tmp = (y * z) / ((y * b) + (t * (a + 1.0))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((t <= -1.56e-78) || !(t <= 6.5e-73)) tmp = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(a + 1.0)); else tmp = Float64(Float64(y * z) / Float64(Float64(y * b) + Float64(t * Float64(a + 1.0)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((t <= -1.56e-78) || ~((t <= 6.5e-73))) tmp = (x + (y * (z / t))) / (a + 1.0); else tmp = (y * z) / ((y * b) + (t * (a + 1.0))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[t, -1.56e-78], N[Not[LessEqual[t, 6.5e-73]], $MachinePrecision]], N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], N[(N[(y * z), $MachinePrecision] / N[(N[(y * b), $MachinePrecision] + N[(t * N[(a + 1.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.56 \cdot 10^{-78} \lor \neg \left(t \leq 6.5 \cdot 10^{-73}\right):\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{a + 1}\\
\mathbf{else}:\\
\;\;\;\;\frac{y \cdot z}{y \cdot b + t \cdot \left(a + 1\right)}\\
\end{array}
\end{array}
if t < -1.56000000000000002e-78 or 6.4999999999999999e-73 < t Initial program 83.4%
associate-/l*87.7%
associate-/l*88.9%
Simplified88.9%
Taylor expanded in y around 0 73.3%
if -1.56000000000000002e-78 < t < 6.4999999999999999e-73Initial program 66.9%
associate-/l*57.2%
associate-/l*53.3%
Simplified53.3%
Taylor expanded in x around 0 58.3%
Taylor expanded in t around 0 68.1%
Final simplification71.3%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -2.3e+36) (not (<= y 1.65e+184))) (/ 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 ((y <= -2.3e+36) || !(y <= 1.65e+184)) {
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 ((y <= (-2.3d+36)) .or. (.not. (y <= 1.65d+184))) 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 ((y <= -2.3e+36) || !(y <= 1.65e+184)) {
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 (y <= -2.3e+36) or not (y <= 1.65e+184): 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 ((y <= -2.3e+36) || !(y <= 1.65e+184)) 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 ((y <= -2.3e+36) || ~((y <= 1.65e+184))) 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[Or[LessEqual[y, -2.3e+36], N[Not[LessEqual[y, 1.65e+184]], $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}\;y \leq -2.3 \cdot 10^{+36} \lor \neg \left(y \leq 1.65 \cdot 10^{+184}\right):\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;\frac{x + z \cdot \frac{y}{t}}{a + 1}\\
\end{array}
\end{array}
if y < -2.29999999999999996e36 or 1.6499999999999999e184 < y Initial program 55.5%
associate-/l*62.1%
associate-/l*63.2%
Simplified63.2%
Taylor expanded in y around inf 64.5%
if -2.29999999999999996e36 < y < 1.6499999999999999e184Initial program 87.8%
associate-/l*82.9%
associate-/l*81.2%
Simplified81.2%
Taylor expanded in b around 0 70.9%
*-commutative87.8%
associate-/l*89.5%
Applied egg-rr73.1%
Final simplification70.2%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -9e+34) (not (<= y 5.5e+183))) (/ 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 ((y <= -9e+34) || !(y <= 5.5e+183)) {
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 ((y <= (-9d+34)) .or. (.not. (y <= 5.5d+183))) 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 ((y <= -9e+34) || !(y <= 5.5e+183)) {
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 (y <= -9e+34) or not (y <= 5.5e+183): 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 ((y <= -9e+34) || !(y <= 5.5e+183)) 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 ((y <= -9e+34) || ~((y <= 5.5e+183))) 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[Or[LessEqual[y, -9e+34], N[Not[LessEqual[y, 5.5e+183]], $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}\;y \leq -9 \cdot 10^{+34} \lor \neg \left(y \leq 5.5 \cdot 10^{+183}\right):\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{a + 1}\\
\end{array}
\end{array}
if y < -9.0000000000000001e34 or 5.5e183 < y Initial program 55.5%
associate-/l*62.1%
associate-/l*63.2%
Simplified63.2%
Taylor expanded in y around inf 64.5%
if -9.0000000000000001e34 < y < 5.5e183Initial program 87.8%
associate-/l*82.9%
associate-/l*81.2%
Simplified81.2%
Taylor expanded in y around 0 67.9%
Final simplification66.8%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -3.1e+34) (not (<= y 2.4e+144))) (/ z b) (/ x (+ 1.0 (+ a (/ (* y b) t))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -3.1e+34) || !(y <= 2.4e+144)) {
tmp = z / b;
} else {
tmp = x / (1.0 + (a + ((y * b) / t)));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((y <= (-3.1d+34)) .or. (.not. (y <= 2.4d+144))) then
tmp = z / b
else
tmp = x / (1.0d0 + (a + ((y * b) / t)))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -3.1e+34) || !(y <= 2.4e+144)) {
tmp = z / b;
} else {
tmp = x / (1.0 + (a + ((y * b) / t)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -3.1e+34) or not (y <= 2.4e+144): tmp = z / b else: tmp = x / (1.0 + (a + ((y * b) / t))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -3.1e+34) || !(y <= 2.4e+144)) tmp = Float64(z / b); else tmp = Float64(x / Float64(1.0 + Float64(a + Float64(Float64(y * b) / t)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -3.1e+34) || ~((y <= 2.4e+144))) tmp = z / b; else tmp = x / (1.0 + (a + ((y * b) / t))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -3.1e+34], N[Not[LessEqual[y, 2.4e+144]], $MachinePrecision]], N[(z / b), $MachinePrecision], N[(x / N[(1.0 + N[(a + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3.1 \cdot 10^{+34} \lor \neg \left(y \leq 2.4 \cdot 10^{+144}\right):\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{1 + \left(a + \frac{y \cdot b}{t}\right)}\\
\end{array}
\end{array}
if y < -3.09999999999999977e34 or 2.4000000000000001e144 < y Initial program 55.6%
associate-/l*61.6%
associate-/l*62.6%
Simplified62.6%
Taylor expanded in y around inf 62.7%
if -3.09999999999999977e34 < y < 2.4000000000000001e144Initial program 89.6%
associate-/l*84.4%
associate-/l*82.6%
Simplified82.6%
Taylor expanded in x around inf 62.3%
Final simplification62.5%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -2.55e+36) (not (<= y 4e+94))) (/ z b) (/ x (+ 1.0 (+ a (/ b (/ t y)))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -2.55e+36) || !(y <= 4e+94)) {
tmp = z / b;
} else {
tmp = x / (1.0 + (a + (b / (t / y))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((y <= (-2.55d+36)) .or. (.not. (y <= 4d+94))) then
tmp = z / b
else
tmp = x / (1.0d0 + (a + (b / (t / y))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -2.55e+36) || !(y <= 4e+94)) {
tmp = z / b;
} else {
tmp = x / (1.0 + (a + (b / (t / y))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -2.55e+36) or not (y <= 4e+94): tmp = z / b else: tmp = x / (1.0 + (a + (b / (t / y)))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -2.55e+36) || !(y <= 4e+94)) tmp = Float64(z / b); else tmp = Float64(x / Float64(1.0 + Float64(a + Float64(b / Float64(t / y))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -2.55e+36) || ~((y <= 4e+94))) tmp = z / b; else tmp = x / (1.0 + (a + (b / (t / y)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -2.55e+36], N[Not[LessEqual[y, 4e+94]], $MachinePrecision]], N[(z / b), $MachinePrecision], N[(x / N[(1.0 + N[(a + N[(b / N[(t / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.55 \cdot 10^{+36} \lor \neg \left(y \leq 4 \cdot 10^{+94}\right):\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{1 + \left(a + \frac{b}{\frac{t}{y}}\right)}\\
\end{array}
\end{array}
if y < -2.54999999999999986e36 or 4.0000000000000001e94 < y Initial program 54.8%
associate-/l*61.4%
associate-/l*63.3%
Simplified63.3%
Taylor expanded in y around inf 60.7%
if -2.54999999999999986e36 < y < 4.0000000000000001e94Initial program 91.6%
associate-/l*85.5%
associate-/l*83.1%
Simplified83.1%
Taylor expanded in x around inf 63.2%
*-commutative63.2%
clear-num63.2%
inv-pow63.2%
Applied egg-rr63.2%
unpow-163.2%
associate-/r*63.2%
Simplified63.2%
clear-num63.2%
add-cube-cbrt63.1%
*-un-lft-identity63.1%
times-frac63.1%
pow263.1%
Applied egg-rr63.1%
times-frac63.1%
*-lft-identity63.1%
unpow263.1%
rem-3cbrt-lft63.2%
Simplified63.2%
Final simplification62.2%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -6e+35) (not (<= y 4.5e+94))) (/ z b) (/ x (+ 1.0 (+ a (* b (/ y t)))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -6e+35) || !(y <= 4.5e+94)) {
tmp = z / b;
} else {
tmp = x / (1.0 + (a + (b * (y / t))));
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((y <= (-6d+35)) .or. (.not. (y <= 4.5d+94))) then
tmp = z / b
else
tmp = x / (1.0d0 + (a + (b * (y / t))))
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -6e+35) || !(y <= 4.5e+94)) {
tmp = z / b;
} else {
tmp = x / (1.0 + (a + (b * (y / t))));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -6e+35) or not (y <= 4.5e+94): tmp = z / b else: tmp = x / (1.0 + (a + (b * (y / t)))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -6e+35) || !(y <= 4.5e+94)) tmp = Float64(z / b); else tmp = Float64(x / Float64(1.0 + Float64(a + Float64(b * Float64(y / t))))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -6e+35) || ~((y <= 4.5e+94))) tmp = z / b; else tmp = x / (1.0 + (a + (b * (y / t)))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -6e+35], N[Not[LessEqual[y, 4.5e+94]], $MachinePrecision]], N[(z / b), $MachinePrecision], N[(x / N[(1.0 + N[(a + N[(b * N[(y / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -6 \cdot 10^{+35} \lor \neg \left(y \leq 4.5 \cdot 10^{+94}\right):\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{1 + \left(a + b \cdot \frac{y}{t}\right)}\\
\end{array}
\end{array}
if y < -5.99999999999999981e35 or 4.49999999999999972e94 < y Initial program 54.8%
associate-/l*61.4%
associate-/l*63.3%
Simplified63.3%
Taylor expanded in y around inf 60.7%
if -5.99999999999999981e35 < y < 4.49999999999999972e94Initial program 91.6%
associate-/l*85.5%
associate-/l*83.1%
Simplified83.1%
Taylor expanded in x around inf 63.2%
associate-/l*63.2%
Applied egg-rr63.2%
Final simplification62.2%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -2.1e-55) (not (<= y 4.7e+94))) (/ z b) (/ x (+ a 1.0))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -2.1e-55) || !(y <= 4.7e+94)) {
tmp = z / b;
} else {
tmp = x / (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 ((y <= (-2.1d-55)) .or. (.not. (y <= 4.7d+94))) then
tmp = z / b
else
tmp = x / (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 ((y <= -2.1e-55) || !(y <= 4.7e+94)) {
tmp = z / b;
} else {
tmp = x / (a + 1.0);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -2.1e-55) or not (y <= 4.7e+94): tmp = z / b else: tmp = x / (a + 1.0) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -2.1e-55) || !(y <= 4.7e+94)) tmp = Float64(z / b); else tmp = Float64(x / Float64(a + 1.0)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -2.1e-55) || ~((y <= 4.7e+94))) tmp = z / b; else tmp = x / (a + 1.0); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -2.1e-55], N[Not[LessEqual[y, 4.7e+94]], $MachinePrecision]], N[(z / b), $MachinePrecision], N[(x / N[(a + 1.0), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.1 \cdot 10^{-55} \lor \neg \left(y \leq 4.7 \cdot 10^{+94}\right):\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a + 1}\\
\end{array}
\end{array}
if y < -2.1000000000000002e-55 or 4.70000000000000017e94 < y Initial program 61.1%
associate-/l*65.9%
associate-/l*67.5%
Simplified67.5%
Taylor expanded in y around inf 55.6%
if -2.1000000000000002e-55 < y < 4.70000000000000017e94Initial program 91.2%
associate-/l*85.0%
associate-/l*82.1%
Simplified82.1%
Taylor expanded in y around 0 59.5%
Final simplification57.7%
(FPCore (x y z t a b) :precision binary64 (if (or (<= y -3e-56) (not (<= y 1.2e+78))) (/ z b) (/ x a)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -3e-56) || !(y <= 1.2e+78)) {
tmp = z / b;
} else {
tmp = x / a;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((y <= (-3d-56)) .or. (.not. (y <= 1.2d+78))) then
tmp = z / b
else
tmp = x / a
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((y <= -3e-56) || !(y <= 1.2e+78)) {
tmp = z / b;
} else {
tmp = x / a;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (y <= -3e-56) or not (y <= 1.2e+78): tmp = z / b else: tmp = x / a return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((y <= -3e-56) || !(y <= 1.2e+78)) tmp = Float64(z / b); else tmp = Float64(x / a); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((y <= -3e-56) || ~((y <= 1.2e+78))) tmp = z / b; else tmp = x / a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[y, -3e-56], N[Not[LessEqual[y, 1.2e+78]], $MachinePrecision]], N[(z / b), $MachinePrecision], N[(x / a), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -3 \cdot 10^{-56} \lor \neg \left(y \leq 1.2 \cdot 10^{+78}\right):\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a}\\
\end{array}
\end{array}
if y < -2.99999999999999989e-56 or 1.1999999999999999e78 < y Initial program 61.8%
associate-/l*66.3%
associate-/l*67.7%
Simplified67.7%
Taylor expanded in y around inf 54.2%
if -2.99999999999999989e-56 < y < 1.1999999999999999e78Initial program 92.2%
associate-/l*85.6%
associate-/l*82.7%
Simplified82.7%
Taylor expanded in x around inf 68.4%
Taylor expanded in a around inf 35.0%
Final simplification44.5%
(FPCore (x y z t a b) :precision binary64 (/ x a))
double code(double x, double y, double z, double t, double a, double b) {
return x / a;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = x / a
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return x / a;
}
def code(x, y, z, t, a, b): return x / a
function code(x, y, z, t, a, b) return Float64(x / a) end
function tmp = code(x, y, z, t, a, b) tmp = x / a; end
code[x_, y_, z_, t_, a_, b_] := N[(x / a), $MachinePrecision]
\begin{array}{l}
\\
\frac{x}{a}
\end{array}
Initial program 77.1%
associate-/l*76.0%
associate-/l*75.3%
Simplified75.3%
Taylor expanded in x around inf 49.4%
Taylor expanded in a around inf 25.0%
(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 2024135
(FPCore (x y z t a b)
:name "Diagrams.Solve.Tridiagonal:solveCyclicTriDiagonal from diagrams-solve-0.1, B"
:precision binary64
:alt
(! :herbie-platform default (if (< t -1707385670788761/12500000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (* 1 (* (+ x (* (/ y t) z)) (/ 1 (+ (+ a 1) (* (/ y t) b))))) (if (< t 1518483551868623/5000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (/ z b) (* 1 (* (+ x (* (/ y t) z)) (/ 1 (+ (+ a 1) (* (/ y t) b))))))))
(/ (+ x (/ (* y z) t)) (+ (+ a 1.0) (/ (* y b) t))))