
(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 (+ (+ a 1.0) (/ (* y b) t)))
(t_2 (+ x (/ (* y z) t)))
(t_3 (/ t_2 t_1)))
(if (<= t_3 1e+246)
(/ t_2 (+ (+ a 1.0) (* y (/ b t))))
(if (<= t_3 INFINITY)
(* z (+ (/ (/ x z) t_1) (/ (/ y t) t_1)))
(/ z b)))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (a + 1.0) + ((y * b) / t);
double t_2 = x + ((y * z) / t);
double t_3 = t_2 / t_1;
double tmp;
if (t_3 <= 1e+246) {
tmp = t_2 / ((a + 1.0) + (y * (b / t)));
} else if (t_3 <= ((double) INFINITY)) {
tmp = z * (((x / z) / t_1) + ((y / t) / t_1));
} 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 = (a + 1.0) + ((y * b) / t);
double t_2 = x + ((y * z) / t);
double t_3 = t_2 / t_1;
double tmp;
if (t_3 <= 1e+246) {
tmp = t_2 / ((a + 1.0) + (y * (b / t)));
} else if (t_3 <= Double.POSITIVE_INFINITY) {
tmp = z * (((x / z) / t_1) + ((y / t) / t_1));
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (a + 1.0) + ((y * b) / t) t_2 = x + ((y * z) / t) t_3 = t_2 / t_1 tmp = 0 if t_3 <= 1e+246: tmp = t_2 / ((a + 1.0) + (y * (b / t))) elif t_3 <= math.inf: tmp = z * (((x / z) / t_1) + ((y / t) / t_1)) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(a + 1.0) + Float64(Float64(y * b) / t)) t_2 = Float64(x + Float64(Float64(y * z) / t)) t_3 = Float64(t_2 / t_1) tmp = 0.0 if (t_3 <= 1e+246) tmp = Float64(t_2 / Float64(Float64(a + 1.0) + Float64(y * Float64(b / t)))); elseif (t_3 <= Inf) tmp = Float64(z * Float64(Float64(Float64(x / z) / t_1) + Float64(Float64(y / t) / t_1))); else tmp = Float64(z / b); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (a + 1.0) + ((y * b) / t); t_2 = x + ((y * z) / t); t_3 = t_2 / t_1; tmp = 0.0; if (t_3 <= 1e+246) tmp = t_2 / ((a + 1.0) + (y * (b / t))); elseif (t_3 <= Inf) tmp = z * (((x / z) / t_1) + ((y / t) / t_1)); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$2 / t$95$1), $MachinePrecision]}, If[LessEqual[t$95$3, 1e+246], N[(t$95$2 / N[(N[(a + 1.0), $MachinePrecision] + N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, Infinity], N[(z * N[(N[(N[(x / z), $MachinePrecision] / t$95$1), $MachinePrecision] + N[(N[(y / t), $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(a + 1\right) + \frac{y \cdot b}{t}\\
t_2 := x + \frac{y \cdot z}{t}\\
t_3 := \frac{t\_2}{t\_1}\\
\mathbf{if}\;t\_3 \leq 10^{+246}:\\
\;\;\;\;\frac{t\_2}{\left(a + 1\right) + y \cdot \frac{b}{t}}\\
\mathbf{elif}\;t\_3 \leq \infty:\\
\;\;\;\;z \cdot \left(\frac{\frac{x}{z}}{t\_1} + \frac{\frac{y}{t}}{t\_1}\right)\\
\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))) < 1.00000000000000007e246Initial program 90.2%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6491.1%
Applied egg-rr91.1%
if 1.00000000000000007e246 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a #s(literal 1 binary64)) (/.f64 (*.f64 y b) t))) < +inf.0Initial program 33.1%
Taylor expanded in z around inf
*-lowering-*.f64N/A
+-lowering-+.f64N/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
associate-+r+N/A
+-commutativeN/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
associate-/r*N/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
associate-+r+N/A
+-commutativeN/A
+-lowering-+.f64N/A
Simplified90.2%
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%
Taylor expanded in y around inf
/-lowering-/.f6496.7%
Simplified96.7%
Final simplification91.7%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (+ x (/ (* y z) t))))
(if (<= (/ t_1 (+ (+ a 1.0) (/ (* y b) t))) 4e+287)
(/ t_1 (+ (+ a 1.0) (* y (/ b t))))
(/ z b))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x + ((y * z) / t);
double tmp;
if ((t_1 / ((a + 1.0) + ((y * b) / t))) <= 4e+287) {
tmp = t_1 / ((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) :: t_1
real(8) :: tmp
t_1 = x + ((y * z) / t)
if ((t_1 / ((a + 1.0d0) + ((y * b) / t))) <= 4d+287) then
tmp = t_1 / ((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 t_1 = x + ((y * z) / t);
double tmp;
if ((t_1 / ((a + 1.0) + ((y * b) / t))) <= 4e+287) {
tmp = t_1 / ((a + 1.0) + (y * (b / t)));
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x + ((y * z) / t) tmp = 0 if (t_1 / ((a + 1.0) + ((y * b) / t))) <= 4e+287: tmp = t_1 / ((a + 1.0) + (y * (b / t))) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x + Float64(Float64(y * z) / t)) tmp = 0.0 if (Float64(t_1 / Float64(Float64(a + 1.0) + Float64(Float64(y * b) / t))) <= 4e+287) tmp = Float64(t_1 / 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) t_1 = x + ((y * z) / t); tmp = 0.0; if ((t_1 / ((a + 1.0) + ((y * b) / t))) <= 4e+287) tmp = t_1 / ((a + 1.0) + (y * (b / t))); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(t$95$1 / N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 4e+287], N[(t$95$1 / 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}
t_1 := x + \frac{y \cdot z}{t}\\
\mathbf{if}\;\frac{t\_1}{\left(a + 1\right) + \frac{y \cdot b}{t}} \leq 4 \cdot 10^{+287}:\\
\;\;\;\;\frac{t\_1}{\left(a + 1\right) + y \cdot \frac{b}{t}}\\
\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))) < 4.0000000000000003e287Initial program 90.3%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6491.1%
Applied egg-rr91.1%
if 4.0000000000000003e287 < (/.f64 (+.f64 x (/.f64 (*.f64 y z) t)) (+.f64 (+.f64 a #s(literal 1 binary64)) (/.f64 (*.f64 y b) t))) Initial program 3.5%
Taylor expanded in y around inf
/-lowering-/.f6484.3%
Simplified84.3%
Final simplification90.1%
(FPCore (x y z t a b)
:precision binary64
(if (<= y -2.4e+86)
(/ z b)
(if (<= y 165.0)
(/ (+ x (/ (* y z) t)) (+ a 1.0))
(if (<= y 1.78e+106)
(/ (* y z) (* t (+ (+ a 1.0) (/ (* y b) t))))
(if (<= y 9e+179) (/ x (+ (+ 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 (y <= -2.4e+86) {
tmp = z / b;
} else if (y <= 165.0) {
tmp = (x + ((y * z) / t)) / (a + 1.0);
} else if (y <= 1.78e+106) {
tmp = (y * z) / (t * ((a + 1.0) + ((y * b) / t)));
} else if (y <= 9e+179) {
tmp = x / ((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 (y <= (-2.4d+86)) then
tmp = z / b
else if (y <= 165.0d0) then
tmp = (x + ((y * z) / t)) / (a + 1.0d0)
else if (y <= 1.78d+106) then
tmp = (y * z) / (t * ((a + 1.0d0) + ((y * b) / t)))
else if (y <= 9d+179) then
tmp = x / ((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 (y <= -2.4e+86) {
tmp = z / b;
} else if (y <= 165.0) {
tmp = (x + ((y * z) / t)) / (a + 1.0);
} else if (y <= 1.78e+106) {
tmp = (y * z) / (t * ((a + 1.0) + ((y * b) / t)));
} else if (y <= 9e+179) {
tmp = x / ((a + 1.0) + (y * (b / t)));
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -2.4e+86: tmp = z / b elif y <= 165.0: tmp = (x + ((y * z) / t)) / (a + 1.0) elif y <= 1.78e+106: tmp = (y * z) / (t * ((a + 1.0) + ((y * b) / t))) elif y <= 9e+179: tmp = x / ((a + 1.0) + (y * (b / t))) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -2.4e+86) tmp = Float64(z / b); elseif (y <= 165.0) tmp = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(a + 1.0)); elseif (y <= 1.78e+106) tmp = Float64(Float64(y * z) / Float64(t * Float64(Float64(a + 1.0) + Float64(Float64(y * b) / t)))); elseif (y <= 9e+179) tmp = Float64(x / 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 (y <= -2.4e+86) tmp = z / b; elseif (y <= 165.0) tmp = (x + ((y * z) / t)) / (a + 1.0); elseif (y <= 1.78e+106) tmp = (y * z) / (t * ((a + 1.0) + ((y * b) / t))); elseif (y <= 9e+179) tmp = x / ((a + 1.0) + (y * (b / t))); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -2.4e+86], N[(z / b), $MachinePrecision], If[LessEqual[y, 165.0], N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.78e+106], N[(N[(y * z), $MachinePrecision] / N[(t * N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 9e+179], N[(x / 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}\;y \leq -2.4 \cdot 10^{+86}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;y \leq 165:\\
\;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\
\mathbf{elif}\;y \leq 1.78 \cdot 10^{+106}:\\
\;\;\;\;\frac{y \cdot z}{t \cdot \left(\left(a + 1\right) + \frac{y \cdot b}{t}\right)}\\
\mathbf{elif}\;y \leq 9 \cdot 10^{+179}:\\
\;\;\;\;\frac{x}{\left(a + 1\right) + y \cdot \frac{b}{t}}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if y < -2.4e86 or 9.0000000000000005e179 < y Initial program 47.4%
Taylor expanded in y around inf
/-lowering-/.f6466.4%
Simplified66.4%
if -2.4e86 < y < 165Initial program 92.1%
Taylor expanded in b around 0
/-lowering-/.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f6479.4%
Simplified79.4%
if 165 < y < 1.77999999999999995e106Initial program 86.2%
Taylor expanded in x around 0
/-lowering-/.f64N/A
*-lowering-*.f64N/A
*-lowering-*.f64N/A
associate-+r+N/A
+-commutativeN/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f6460.4%
Simplified60.4%
if 1.77999999999999995e106 < y < 9.0000000000000005e179Initial program 88.0%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6493.9%
Applied egg-rr93.9%
Taylor expanded in x around inf
Simplified76.1%
Final simplification73.5%
(FPCore (x y z t a b)
:precision binary64
(if (<= y -5.8e+86)
(/ z b)
(if (<= y 9e-97)
(/ (+ x (/ (* y z) t)) (+ a 1.0))
(if (<= y 1.75e+179)
(/ (+ x (* y (/ z t))) (+ 1.0 (* y (/ b t))))
(/ z b)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -5.8e+86) {
tmp = z / b;
} else if (y <= 9e-97) {
tmp = (x + ((y * z) / t)) / (a + 1.0);
} else if (y <= 1.75e+179) {
tmp = (x + (y * (z / t))) / (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 (y <= (-5.8d+86)) then
tmp = z / b
else if (y <= 9d-97) then
tmp = (x + ((y * z) / t)) / (a + 1.0d0)
else if (y <= 1.75d+179) then
tmp = (x + (y * (z / t))) / (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 (y <= -5.8e+86) {
tmp = z / b;
} else if (y <= 9e-97) {
tmp = (x + ((y * z) / t)) / (a + 1.0);
} else if (y <= 1.75e+179) {
tmp = (x + (y * (z / t))) / (1.0 + (y * (b / t)));
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -5.8e+86: tmp = z / b elif y <= 9e-97: tmp = (x + ((y * z) / t)) / (a + 1.0) elif y <= 1.75e+179: tmp = (x + (y * (z / t))) / (1.0 + (y * (b / t))) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -5.8e+86) tmp = Float64(z / b); elseif (y <= 9e-97) tmp = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(a + 1.0)); elseif (y <= 1.75e+179) tmp = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(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 (y <= -5.8e+86) tmp = z / b; elseif (y <= 9e-97) tmp = (x + ((y * z) / t)) / (a + 1.0); elseif (y <= 1.75e+179) tmp = (x + (y * (z / t))) / (1.0 + (y * (b / t))); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -5.8e+86], N[(z / b), $MachinePrecision], If[LessEqual[y, 9e-97], N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.75e+179], N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(1.0 + N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.8 \cdot 10^{+86}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;y \leq 9 \cdot 10^{-97}:\\
\;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\
\mathbf{elif}\;y \leq 1.75 \cdot 10^{+179}:\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{1 + y \cdot \frac{b}{t}}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if y < -5.79999999999999981e86 or 1.75000000000000007e179 < y Initial program 48.1%
Taylor expanded in y around inf
/-lowering-/.f6465.7%
Simplified65.7%
if -5.79999999999999981e86 < y < 9.0000000000000002e-97Initial program 92.9%
Taylor expanded in b around 0
/-lowering-/.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f6482.8%
Simplified82.8%
if 9.0000000000000002e-97 < y < 1.75000000000000007e179Initial program 86.2%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6486.3%
Applied egg-rr86.3%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f6488.2%
Applied egg-rr88.2%
Taylor expanded in a around 0
Simplified71.6%
clear-numN/A
associate-/r/N/A
clear-numN/A
*-lowering-*.f64N/A
/-lowering-/.f6471.7%
Applied egg-rr71.7%
Final simplification75.2%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (/ (+ x (* y (/ z t))) (+ a (/ y (/ t b))))))
(if (<= (+ a 1.0) -50.0)
t_1
(if (<= (+ a 1.0) 2.0)
(/ (+ x (/ (* y z) t)) (+ 1.0 (/ (* y b) t)))
t_1))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + (y * (z / t))) / (a + (y / (t / b)));
double tmp;
if ((a + 1.0) <= -50.0) {
tmp = t_1;
} else if ((a + 1.0) <= 2.0) {
tmp = (x + ((y * z) / t)) / (1.0 + ((y * b) / 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 + (y * (z / t))) / (a + (y / (t / b)))
if ((a + 1.0d0) <= (-50.0d0)) then
tmp = t_1
else if ((a + 1.0d0) <= 2.0d0) then
tmp = (x + ((y * z) / t)) / (1.0d0 + ((y * b) / 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 + (y * (z / t))) / (a + (y / (t / b)));
double tmp;
if ((a + 1.0) <= -50.0) {
tmp = t_1;
} else if ((a + 1.0) <= 2.0) {
tmp = (x + ((y * z) / t)) / (1.0 + ((y * b) / t));
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (x + (y * (z / t))) / (a + (y / (t / b))) tmp = 0 if (a + 1.0) <= -50.0: tmp = t_1 elif (a + 1.0) <= 2.0: tmp = (x + ((y * z) / t)) / (1.0 + ((y * b) / t)) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(a + Float64(y / Float64(t / b)))) tmp = 0.0 if (Float64(a + 1.0) <= -50.0) tmp = t_1; elseif (Float64(a + 1.0) <= 2.0) tmp = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(1.0 + Float64(Float64(y * b) / t))); 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 + (y / (t / b))); tmp = 0.0; if ((a + 1.0) <= -50.0) tmp = t_1; elseif ((a + 1.0) <= 2.0) tmp = (x + ((y * z) / t)) / (1.0 + ((y * b) / 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[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(a + N[(y / N[(t / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(a + 1.0), $MachinePrecision], -50.0], t$95$1, If[LessEqual[N[(a + 1.0), $MachinePrecision], 2.0], N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(1.0 + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x + y \cdot \frac{z}{t}}{a + \frac{y}{\frac{t}{b}}}\\
\mathbf{if}\;a + 1 \leq -50:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;a + 1 \leq 2:\\
\;\;\;\;\frac{x + \frac{y \cdot z}{t}}{1 + \frac{y \cdot b}{t}}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if (+.f64 a #s(literal 1 binary64)) < -50 or 2 < (+.f64 a #s(literal 1 binary64)) Initial program 75.4%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6477.1%
Applied egg-rr77.1%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f6478.8%
Applied egg-rr78.8%
Taylor expanded in a around inf
Simplified77.4%
if -50 < (+.f64 a #s(literal 1 binary64)) < 2Initial program 79.1%
Taylor expanded in a around 0
/-lowering-/.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f6478.6%
Simplified78.6%
Final simplification78.0%
(FPCore (x y z t a b) :precision binary64 (let* ((t_1 (/ (+ x (* y (/ z t))) (+ (+ a 1.0) (/ y (/ t b)))))) (if (<= t -8.5e-206) t_1 (if (<= t 5.8e-173) (/ z b) t_1))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (x + (y * (z / t))) / ((a + 1.0) + (y / (t / b)));
double tmp;
if (t <= -8.5e-206) {
tmp = t_1;
} else if (t <= 5.8e-173) {
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 = (x + (y * (z / t))) / ((a + 1.0d0) + (y / (t / b)))
if (t <= (-8.5d-206)) then
tmp = t_1
else if (t <= 5.8d-173) 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 = (x + (y * (z / t))) / ((a + 1.0) + (y / (t / b)));
double tmp;
if (t <= -8.5e-206) {
tmp = t_1;
} else if (t <= 5.8e-173) {
tmp = z / b;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (x + (y * (z / t))) / ((a + 1.0) + (y / (t / b))) tmp = 0 if t <= -8.5e-206: tmp = t_1 elif t <= 5.8e-173: tmp = z / b else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(Float64(a + 1.0) + Float64(y / Float64(t / b)))) tmp = 0.0 if (t <= -8.5e-206) tmp = t_1; elseif (t <= 5.8e-173) tmp = Float64(z / b); 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 + 1.0) + (y / (t / b))); tmp = 0.0; if (t <= -8.5e-206) tmp = t_1; elseif (t <= 5.8e-173) tmp = z / b; 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] / N[(N[(a + 1.0), $MachinePrecision] + N[(y / N[(t / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -8.5e-206], t$95$1, If[LessEqual[t, 5.8e-173], N[(z / b), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{x + y \cdot \frac{z}{t}}{\left(a + 1\right) + \frac{y}{\frac{t}{b}}}\\
\mathbf{if}\;t \leq -8.5 \cdot 10^{-206}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;t \leq 5.8 \cdot 10^{-173}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if t < -8.5000000000000005e-206 or 5.7999999999999997e-173 < t Initial program 85.8%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6484.6%
Applied egg-rr84.6%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f6487.9%
Applied egg-rr87.9%
if -8.5000000000000005e-206 < t < 5.7999999999999997e-173Initial program 34.3%
Taylor expanded in y around inf
/-lowering-/.f6470.2%
Simplified70.2%
Final simplification85.0%
(FPCore (x y z t a b)
:precision binary64
(if (<= y -4.7e+86)
(/ z b)
(if (<= y 1.35e+76)
(/ (+ x (/ 1.0 (/ t (* y z)))) (+ a 1.0))
(if (<= y 1.25e+180) (/ x (+ (+ 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 (y <= -4.7e+86) {
tmp = z / b;
} else if (y <= 1.35e+76) {
tmp = (x + (1.0 / (t / (y * z)))) / (a + 1.0);
} else if (y <= 1.25e+180) {
tmp = x / ((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 (y <= (-4.7d+86)) then
tmp = z / b
else if (y <= 1.35d+76) then
tmp = (x + (1.0d0 / (t / (y * z)))) / (a + 1.0d0)
else if (y <= 1.25d+180) then
tmp = x / ((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 (y <= -4.7e+86) {
tmp = z / b;
} else if (y <= 1.35e+76) {
tmp = (x + (1.0 / (t / (y * z)))) / (a + 1.0);
} else if (y <= 1.25e+180) {
tmp = x / ((a + 1.0) + (y * (b / t)));
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -4.7e+86: tmp = z / b elif y <= 1.35e+76: tmp = (x + (1.0 / (t / (y * z)))) / (a + 1.0) elif y <= 1.25e+180: tmp = x / ((a + 1.0) + (y * (b / t))) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -4.7e+86) tmp = Float64(z / b); elseif (y <= 1.35e+76) tmp = Float64(Float64(x + Float64(1.0 / Float64(t / Float64(y * z)))) / Float64(a + 1.0)); elseif (y <= 1.25e+180) tmp = Float64(x / 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 (y <= -4.7e+86) tmp = z / b; elseif (y <= 1.35e+76) tmp = (x + (1.0 / (t / (y * z)))) / (a + 1.0); elseif (y <= 1.25e+180) tmp = x / ((a + 1.0) + (y * (b / t))); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -4.7e+86], N[(z / b), $MachinePrecision], If[LessEqual[y, 1.35e+76], N[(N[(x + N[(1.0 / N[(t / N[(y * z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.25e+180], N[(x / 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}\;y \leq -4.7 \cdot 10^{+86}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;y \leq 1.35 \cdot 10^{+76}:\\
\;\;\;\;\frac{x + \frac{1}{\frac{t}{y \cdot z}}}{a + 1}\\
\mathbf{elif}\;y \leq 1.25 \cdot 10^{+180}:\\
\;\;\;\;\frac{x}{\left(a + 1\right) + y \cdot \frac{b}{t}}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if y < -4.7000000000000002e86 or 1.2499999999999999e180 < y Initial program 47.4%
Taylor expanded in y around inf
/-lowering-/.f6466.4%
Simplified66.4%
if -4.7000000000000002e86 < y < 1.34999999999999995e76Initial program 91.2%
Taylor expanded in b around 0
/-lowering-/.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f6475.0%
Simplified75.0%
clear-numN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f6475.0%
Applied egg-rr75.0%
if 1.34999999999999995e76 < y < 1.2499999999999999e180Initial program 89.7%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6494.7%
Applied egg-rr94.7%
Taylor expanded in x around inf
Simplified69.7%
Final simplification71.9%
(FPCore (x y z t a b)
:precision binary64
(if (<= y -5.1e+85)
(/ z b)
(if (<= y 1.5e+74)
(/ (+ x (/ (* y z) t)) (+ a 1.0))
(if (<= y 8e+179) (/ x (+ (+ 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 (y <= -5.1e+85) {
tmp = z / b;
} else if (y <= 1.5e+74) {
tmp = (x + ((y * z) / t)) / (a + 1.0);
} else if (y <= 8e+179) {
tmp = x / ((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 (y <= (-5.1d+85)) then
tmp = z / b
else if (y <= 1.5d+74) then
tmp = (x + ((y * z) / t)) / (a + 1.0d0)
else if (y <= 8d+179) then
tmp = x / ((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 (y <= -5.1e+85) {
tmp = z / b;
} else if (y <= 1.5e+74) {
tmp = (x + ((y * z) / t)) / (a + 1.0);
} else if (y <= 8e+179) {
tmp = x / ((a + 1.0) + (y * (b / t)));
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -5.1e+85: tmp = z / b elif y <= 1.5e+74: tmp = (x + ((y * z) / t)) / (a + 1.0) elif y <= 8e+179: tmp = x / ((a + 1.0) + (y * (b / t))) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -5.1e+85) tmp = Float64(z / b); elseif (y <= 1.5e+74) tmp = Float64(Float64(x + Float64(Float64(y * z) / t)) / Float64(a + 1.0)); elseif (y <= 8e+179) tmp = Float64(x / 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 (y <= -5.1e+85) tmp = z / b; elseif (y <= 1.5e+74) tmp = (x + ((y * z) / t)) / (a + 1.0); elseif (y <= 8e+179) tmp = x / ((a + 1.0) + (y * (b / t))); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -5.1e+85], N[(z / b), $MachinePrecision], If[LessEqual[y, 1.5e+74], N[(N[(x + N[(N[(y * z), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 8e+179], N[(x / 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}\;y \leq -5.1 \cdot 10^{+85}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;y \leq 1.5 \cdot 10^{+74}:\\
\;\;\;\;\frac{x + \frac{y \cdot z}{t}}{a + 1}\\
\mathbf{elif}\;y \leq 8 \cdot 10^{+179}:\\
\;\;\;\;\frac{x}{\left(a + 1\right) + y \cdot \frac{b}{t}}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if y < -5.0999999999999998e85 or 7.99999999999999984e179 < y Initial program 47.4%
Taylor expanded in y around inf
/-lowering-/.f6466.4%
Simplified66.4%
if -5.0999999999999998e85 < y < 1.5e74Initial program 91.2%
Taylor expanded in b around 0
/-lowering-/.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f6475.0%
Simplified75.0%
if 1.5e74 < y < 7.99999999999999984e179Initial program 89.7%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6494.7%
Applied egg-rr94.7%
Taylor expanded in x around inf
Simplified69.7%
Final simplification71.9%
(FPCore (x y z t a b)
:precision binary64
(if (<= y -4.1e+85)
(/ z b)
(if (<= y -1.22e-262)
(/ (+ x (* y (/ z t))) (+ a 1.0))
(if (<= y 8.5e+179) (/ x (+ (+ 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 (y <= -4.1e+85) {
tmp = z / b;
} else if (y <= -1.22e-262) {
tmp = (x + (y * (z / t))) / (a + 1.0);
} else if (y <= 8.5e+179) {
tmp = x / ((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 (y <= (-4.1d+85)) then
tmp = z / b
else if (y <= (-1.22d-262)) then
tmp = (x + (y * (z / t))) / (a + 1.0d0)
else if (y <= 8.5d+179) then
tmp = x / ((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 (y <= -4.1e+85) {
tmp = z / b;
} else if (y <= -1.22e-262) {
tmp = (x + (y * (z / t))) / (a + 1.0);
} else if (y <= 8.5e+179) {
tmp = x / ((a + 1.0) + ((y * b) / t));
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -4.1e+85: tmp = z / b elif y <= -1.22e-262: tmp = (x + (y * (z / t))) / (a + 1.0) elif y <= 8.5e+179: tmp = x / ((a + 1.0) + ((y * b) / t)) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -4.1e+85) tmp = Float64(z / b); elseif (y <= -1.22e-262) tmp = Float64(Float64(x + Float64(y * Float64(z / t))) / Float64(a + 1.0)); elseif (y <= 8.5e+179) tmp = Float64(x / Float64(Float64(a + 1.0) + Float64(Float64(y * 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 (y <= -4.1e+85) tmp = z / b; elseif (y <= -1.22e-262) tmp = (x + (y * (z / t))) / (a + 1.0); elseif (y <= 8.5e+179) tmp = x / ((a + 1.0) + ((y * b) / t)); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -4.1e+85], N[(z / b), $MachinePrecision], If[LessEqual[y, -1.22e-262], N[(N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 8.5e+179], N[(x / N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -4.1 \cdot 10^{+85}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;y \leq -1.22 \cdot 10^{-262}:\\
\;\;\;\;\frac{x + y \cdot \frac{z}{t}}{a + 1}\\
\mathbf{elif}\;y \leq 8.5 \cdot 10^{+179}:\\
\;\;\;\;\frac{x}{\left(a + 1\right) + \frac{y \cdot b}{t}}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if y < -4.09999999999999978e85 or 8.49999999999999962e179 < y Initial program 47.4%
Taylor expanded in y around inf
/-lowering-/.f6466.4%
Simplified66.4%
if -4.09999999999999978e85 < y < -1.2199999999999999e-262Initial program 87.3%
Taylor expanded in b around 0
/-lowering-/.f64N/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-lowering-*.f64N/A
+-lowering-+.f6480.9%
Simplified80.9%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6479.5%
Applied egg-rr79.5%
if -1.2199999999999999e-262 < y < 8.49999999999999962e179Initial program 93.0%
Taylor expanded in x around inf
/-lowering-/.f64N/A
associate-+r+N/A
+-commutativeN/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f6468.9%
Simplified68.9%
Final simplification70.7%
(FPCore (x y z t a b) :precision binary64 (let* ((t_1 (+ x (* y (/ z t)))) (t_2 (/ t_1 (+ a (/ y (/ t b)))))) (if (<= a -1.0) t_2 (if (<= a 0.43) (/ t_1 (+ 1.0 (* y (/ b t)))) t_2))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = x + (y * (z / t));
double t_2 = t_1 / (a + (y / (t / b)));
double tmp;
if (a <= -1.0) {
tmp = t_2;
} else if (a <= 0.43) {
tmp = t_1 / (1.0 + (y * (b / t)));
} 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))
t_2 = t_1 / (a + (y / (t / b)))
if (a <= (-1.0d0)) then
tmp = t_2
else if (a <= 0.43d0) then
tmp = t_1 / (1.0d0 + (y * (b / t)))
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));
double t_2 = t_1 / (a + (y / (t / b)));
double tmp;
if (a <= -1.0) {
tmp = t_2;
} else if (a <= 0.43) {
tmp = t_1 / (1.0 + (y * (b / t)));
} else {
tmp = t_2;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = x + (y * (z / t)) t_2 = t_1 / (a + (y / (t / b))) tmp = 0 if a <= -1.0: tmp = t_2 elif a <= 0.43: tmp = t_1 / (1.0 + (y * (b / t))) else: tmp = t_2 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(x + Float64(y * Float64(z / t))) t_2 = Float64(t_1 / Float64(a + Float64(y / Float64(t / b)))) tmp = 0.0 if (a <= -1.0) tmp = t_2; elseif (a <= 0.43) tmp = Float64(t_1 / Float64(1.0 + Float64(y * Float64(b / t)))); else tmp = t_2; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = x + (y * (z / t)); t_2 = t_1 / (a + (y / (t / b))); tmp = 0.0; if (a <= -1.0) tmp = t_2; elseif (a <= 0.43) tmp = t_1 / (1.0 + (y * (b / t))); else tmp = t_2; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(x + N[(y * N[(z / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t$95$1 / N[(a + N[(y / N[(t / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[a, -1.0], t$95$2, If[LessEqual[a, 0.43], N[(t$95$1 / N[(1.0 + N[(y * N[(b / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], t$95$2]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := x + y \cdot \frac{z}{t}\\
t_2 := \frac{t\_1}{a + \frac{y}{\frac{t}{b}}}\\
\mathbf{if}\;a \leq -1:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;a \leq 0.43:\\
\;\;\;\;\frac{t\_1}{1 + y \cdot \frac{b}{t}}\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if a < -1 or 0.429999999999999993 < a Initial program 75.6%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6477.3%
Applied egg-rr77.3%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f6479.0%
Applied egg-rr79.0%
Taylor expanded in a around inf
Simplified77.6%
if -1 < a < 0.429999999999999993Initial program 79.0%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6474.1%
Applied egg-rr74.1%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f6477.0%
Applied egg-rr77.0%
Taylor expanded in a around 0
Simplified76.5%
clear-numN/A
associate-/r/N/A
clear-numN/A
*-lowering-*.f64N/A
/-lowering-/.f6476.6%
Applied egg-rr76.6%
Final simplification77.0%
(FPCore (x y z t a b)
:precision binary64
(if (<= a -4e+54)
(/ x a)
(if (<= a -4.4e-198)
(/ z b)
(if (<= a 2.85e-108) x (if (<= a 450000000000.0) (/ z b) (/ x a))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= -4e+54) {
tmp = x / a;
} else if (a <= -4.4e-198) {
tmp = z / b;
} else if (a <= 2.85e-108) {
tmp = x;
} else if (a <= 450000000000.0) {
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 (a <= (-4d+54)) then
tmp = x / a
else if (a <= (-4.4d-198)) then
tmp = z / b
else if (a <= 2.85d-108) then
tmp = x
else if (a <= 450000000000.0d0) 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 (a <= -4e+54) {
tmp = x / a;
} else if (a <= -4.4e-198) {
tmp = z / b;
} else if (a <= 2.85e-108) {
tmp = x;
} else if (a <= 450000000000.0) {
tmp = z / b;
} else {
tmp = x / a;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if a <= -4e+54: tmp = x / a elif a <= -4.4e-198: tmp = z / b elif a <= 2.85e-108: tmp = x elif a <= 450000000000.0: tmp = z / b else: tmp = x / a return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (a <= -4e+54) tmp = Float64(x / a); elseif (a <= -4.4e-198) tmp = Float64(z / b); elseif (a <= 2.85e-108) tmp = x; elseif (a <= 450000000000.0) 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 (a <= -4e+54) tmp = x / a; elseif (a <= -4.4e-198) tmp = z / b; elseif (a <= 2.85e-108) tmp = x; elseif (a <= 450000000000.0) tmp = z / b; else tmp = x / a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[a, -4e+54], N[(x / a), $MachinePrecision], If[LessEqual[a, -4.4e-198], N[(z / b), $MachinePrecision], If[LessEqual[a, 2.85e-108], x, If[LessEqual[a, 450000000000.0], N[(z / b), $MachinePrecision], N[(x / a), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -4 \cdot 10^{+54}:\\
\;\;\;\;\frac{x}{a}\\
\mathbf{elif}\;a \leq -4.4 \cdot 10^{-198}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;a \leq 2.85 \cdot 10^{-108}:\\
\;\;\;\;x\\
\mathbf{elif}\;a \leq 450000000000:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a}\\
\end{array}
\end{array}
if a < -4.0000000000000003e54 or 4.5e11 < a Initial program 76.6%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6477.6%
Applied egg-rr77.6%
Taylor expanded in x around inf
Simplified63.4%
Taylor expanded in a around inf
/-lowering-/.f6457.2%
Simplified57.2%
if -4.0000000000000003e54 < a < -4.4000000000000001e-198 or 2.85e-108 < a < 4.5e11Initial program 74.0%
Taylor expanded in y around inf
/-lowering-/.f6449.8%
Simplified49.8%
if -4.4000000000000001e-198 < a < 2.85e-108Initial program 83.8%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6477.5%
Applied egg-rr77.5%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f6479.2%
Applied egg-rr79.2%
Taylor expanded in a around 0
Simplified79.2%
Taylor expanded in t around inf
Simplified49.1%
(FPCore (x y z t a b) :precision binary64 (if (<= y -5.7e+20) (/ z b) (if (<= y 8.2e+179) (/ x (+ (+ 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 (y <= -5.7e+20) {
tmp = z / b;
} else if (y <= 8.2e+179) {
tmp = x / ((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 (y <= (-5.7d+20)) then
tmp = z / b
else if (y <= 8.2d+179) then
tmp = x / ((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 (y <= -5.7e+20) {
tmp = z / b;
} else if (y <= 8.2e+179) {
tmp = x / ((a + 1.0) + ((y * b) / t));
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -5.7e+20: tmp = z / b elif y <= 8.2e+179: tmp = x / ((a + 1.0) + ((y * b) / t)) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -5.7e+20) tmp = Float64(z / b); elseif (y <= 8.2e+179) tmp = Float64(x / Float64(Float64(a + 1.0) + Float64(Float64(y * 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 (y <= -5.7e+20) tmp = z / b; elseif (y <= 8.2e+179) tmp = x / ((a + 1.0) + ((y * b) / t)); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -5.7e+20], N[(z / b), $MachinePrecision], If[LessEqual[y, 8.2e+179], N[(x / N[(N[(a + 1.0), $MachinePrecision] + N[(N[(y * b), $MachinePrecision] / t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -5.7 \cdot 10^{+20}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;y \leq 8.2 \cdot 10^{+179}:\\
\;\;\;\;\frac{x}{\left(a + 1\right) + \frac{y \cdot b}{t}}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if y < -5.7e20 or 8.20000000000000021e179 < y Initial program 47.1%
Taylor expanded in y around inf
/-lowering-/.f6464.7%
Simplified64.7%
if -5.7e20 < y < 8.20000000000000021e179Initial program 93.0%
Taylor expanded in x around inf
/-lowering-/.f64N/A
associate-+r+N/A
+-commutativeN/A
+-lowering-+.f64N/A
/-lowering-/.f64N/A
*-commutativeN/A
*-lowering-*.f64N/A
+-lowering-+.f6468.9%
Simplified68.9%
Final simplification67.4%
(FPCore (x y z t a b) :precision binary64 (if (<= y -6.5e+86) (/ z b) (if (<= y 8e+179) (/ x (+ (+ a 1.0) (/ y (/ t b)))) (/ z b))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -6.5e+86) {
tmp = z / b;
} else if (y <= 8e+179) {
tmp = x / ((a + 1.0) + (y / (t / b)));
} 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 (y <= (-6.5d+86)) then
tmp = z / b
else if (y <= 8d+179) then
tmp = x / ((a + 1.0d0) + (y / (t / b)))
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 (y <= -6.5e+86) {
tmp = z / b;
} else if (y <= 8e+179) {
tmp = x / ((a + 1.0) + (y / (t / b)));
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -6.5e+86: tmp = z / b elif y <= 8e+179: tmp = x / ((a + 1.0) + (y / (t / b))) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -6.5e+86) tmp = Float64(z / b); elseif (y <= 8e+179) tmp = Float64(x / Float64(Float64(a + 1.0) + Float64(y / Float64(t / b)))); else tmp = Float64(z / b); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (y <= -6.5e+86) tmp = z / b; elseif (y <= 8e+179) tmp = x / ((a + 1.0) + (y / (t / b))); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -6.5e+86], N[(z / b), $MachinePrecision], If[LessEqual[y, 8e+179], N[(x / N[(N[(a + 1.0), $MachinePrecision] + N[(y / N[(t / b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -6.5 \cdot 10^{+86}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;y \leq 8 \cdot 10^{+179}:\\
\;\;\;\;\frac{x}{\left(a + 1\right) + \frac{y}{\frac{t}{b}}}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if y < -6.49999999999999996e86 or 7.99999999999999984e179 < y Initial program 47.4%
Taylor expanded in y around inf
/-lowering-/.f6466.4%
Simplified66.4%
if -6.49999999999999996e86 < y < 7.99999999999999984e179Initial program 91.0%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6489.4%
Applied egg-rr89.4%
Taylor expanded in x around inf
Simplified65.8%
+-commutativeN/A
+-lowering-+.f64N/A
*-commutativeN/A
clear-numN/A
div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f64N/A
+-lowering-+.f6465.8%
Applied egg-rr65.8%
Final simplification66.0%
(FPCore (x y z t a b) :precision binary64 (if (<= y -2.45e+86) (/ z b) (if (<= y 1.95e+180) (/ x (+ (+ 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 (y <= -2.45e+86) {
tmp = z / b;
} else if (y <= 1.95e+180) {
tmp = x / ((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 (y <= (-2.45d+86)) then
tmp = z / b
else if (y <= 1.95d+180) then
tmp = x / ((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 (y <= -2.45e+86) {
tmp = z / b;
} else if (y <= 1.95e+180) {
tmp = x / ((a + 1.0) + (y * (b / t)));
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -2.45e+86: tmp = z / b elif y <= 1.95e+180: tmp = x / ((a + 1.0) + (y * (b / t))) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -2.45e+86) tmp = Float64(z / b); elseif (y <= 1.95e+180) tmp = Float64(x / 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 (y <= -2.45e+86) tmp = z / b; elseif (y <= 1.95e+180) tmp = x / ((a + 1.0) + (y * (b / t))); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -2.45e+86], N[(z / b), $MachinePrecision], If[LessEqual[y, 1.95e+180], N[(x / 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}\;y \leq -2.45 \cdot 10^{+86}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;y \leq 1.95 \cdot 10^{+180}:\\
\;\;\;\;\frac{x}{\left(a + 1\right) + y \cdot \frac{b}{t}}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if y < -2.45e86 or 1.95e180 < y Initial program 47.4%
Taylor expanded in y around inf
/-lowering-/.f6466.4%
Simplified66.4%
if -2.45e86 < y < 1.95e180Initial program 91.0%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6489.4%
Applied egg-rr89.4%
Taylor expanded in x around inf
Simplified65.8%
Final simplification66.0%
(FPCore (x y z t a b) :precision binary64 (if (<= y -1.25e+86) (/ z b) (if (<= y 47.0) (/ x (+ a 1.0)) (/ z b))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (y <= -1.25e+86) {
tmp = z / b;
} else if (y <= 47.0) {
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 (y <= (-1.25d+86)) then
tmp = z / b
else if (y <= 47.0d0) 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 (y <= -1.25e+86) {
tmp = z / b;
} else if (y <= 47.0) {
tmp = x / (a + 1.0);
} else {
tmp = z / b;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if y <= -1.25e+86: tmp = z / b elif y <= 47.0: tmp = x / (a + 1.0) else: tmp = z / b return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (y <= -1.25e+86) tmp = Float64(z / b); elseif (y <= 47.0) 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 (y <= -1.25e+86) tmp = z / b; elseif (y <= 47.0) tmp = x / (a + 1.0); else tmp = z / b; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[y, -1.25e+86], N[(z / b), $MachinePrecision], If[LessEqual[y, 47.0], N[(x / N[(a + 1.0), $MachinePrecision]), $MachinePrecision], N[(z / b), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.25 \cdot 10^{+86}:\\
\;\;\;\;\frac{z}{b}\\
\mathbf{elif}\;y \leq 47:\\
\;\;\;\;\frac{x}{a + 1}\\
\mathbf{else}:\\
\;\;\;\;\frac{z}{b}\\
\end{array}
\end{array}
if y < -1.2499999999999999e86 or 47 < y Initial program 60.1%
Taylor expanded in y around inf
/-lowering-/.f6456.9%
Simplified56.9%
if -1.2499999999999999e86 < y < 47Initial program 92.1%
Taylor expanded in y around 0
/-lowering-/.f64N/A
+-lowering-+.f6464.7%
Simplified64.7%
Final simplification61.1%
(FPCore (x y z t a b) :precision binary64 (if (<= a -1.0) (/ x a) (if (<= a 4.8e-15) x (/ x a))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= -1.0) {
tmp = x / a;
} else if (a <= 4.8e-15) {
tmp = x;
} 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 (a <= (-1.0d0)) then
tmp = x / a
else if (a <= 4.8d-15) then
tmp = x
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 (a <= -1.0) {
tmp = x / a;
} else if (a <= 4.8e-15) {
tmp = x;
} else {
tmp = x / a;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if a <= -1.0: tmp = x / a elif a <= 4.8e-15: tmp = x else: tmp = x / a return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (a <= -1.0) tmp = Float64(x / a); elseif (a <= 4.8e-15) tmp = x; else tmp = Float64(x / a); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (a <= -1.0) tmp = x / a; elseif (a <= 4.8e-15) tmp = x; else tmp = x / a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[a, -1.0], N[(x / a), $MachinePrecision], If[LessEqual[a, 4.8e-15], x, N[(x / a), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1:\\
\;\;\;\;\frac{x}{a}\\
\mathbf{elif}\;a \leq 4.8 \cdot 10^{-15}:\\
\;\;\;\;x\\
\mathbf{else}:\\
\;\;\;\;\frac{x}{a}\\
\end{array}
\end{array}
if a < -1 or 4.7999999999999999e-15 < a Initial program 75.8%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6477.4%
Applied egg-rr77.4%
Taylor expanded in x around inf
Simplified58.7%
Taylor expanded in a around inf
/-lowering-/.f6451.2%
Simplified51.2%
if -1 < a < 4.7999999999999999e-15Initial program 78.8%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6473.9%
Applied egg-rr73.9%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f6476.8%
Applied egg-rr76.8%
Taylor expanded in a around 0
Simplified76.3%
Taylor expanded in t around inf
Simplified35.4%
(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 77.4%
associate-/l*N/A
*-commutativeN/A
*-lowering-*.f64N/A
/-lowering-/.f6475.6%
Applied egg-rr75.6%
associate-/l*N/A
clear-numN/A
un-div-invN/A
/-lowering-/.f64N/A
/-lowering-/.f6477.9%
Applied egg-rr77.9%
Taylor expanded in a around 0
Simplified49.5%
Taylor expanded in t around inf
Simplified20.3%
(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 2024161
(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))))