
(FPCore (x y z t a b) :precision binary64 (+ (+ (+ x (* y z)) (* t a)) (* (* a z) b)))
double code(double x, double y, double z, double t, double a, double b) {
return ((x + (y * z)) + (t * a)) + ((a * z) * b);
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = ((x + (y * z)) + (t * a)) + ((a * z) * b)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return ((x + (y * z)) + (t * a)) + ((a * z) * b);
}
def code(x, y, z, t, a, b): return ((x + (y * z)) + (t * a)) + ((a * z) * b)
function code(x, y, z, t, a, b) return Float64(Float64(Float64(x + Float64(y * z)) + Float64(t * a)) + Float64(Float64(a * z) * b)) end
function tmp = code(x, y, z, t, a, b) tmp = ((x + (y * z)) + (t * a)) + ((a * z) * b); end
code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(x + N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(t * a), $MachinePrecision]), $MachinePrecision] + N[(N[(a * z), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(x + y \cdot z\right) + t \cdot a\right) + \left(a \cdot z\right) \cdot b
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 14 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z t a b) :precision binary64 (+ (+ (+ x (* y z)) (* t a)) (* (* a z) b)))
double code(double x, double y, double z, double t, double a, double b) {
return ((x + (y * z)) + (t * a)) + ((a * z) * b);
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
code = ((x + (y * z)) + (t * a)) + ((a * z) * b)
end function
public static double code(double x, double y, double z, double t, double a, double b) {
return ((x + (y * z)) + (t * a)) + ((a * z) * b);
}
def code(x, y, z, t, a, b): return ((x + (y * z)) + (t * a)) + ((a * z) * b)
function code(x, y, z, t, a, b) return Float64(Float64(Float64(x + Float64(y * z)) + Float64(t * a)) + Float64(Float64(a * z) * b)) end
function tmp = code(x, y, z, t, a, b) tmp = ((x + (y * z)) + (t * a)) + ((a * z) * b); end
code[x_, y_, z_, t_, a_, b_] := N[(N[(N[(x + N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(t * a), $MachinePrecision]), $MachinePrecision] + N[(N[(a * z), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
\left(\left(x + y \cdot z\right) + t \cdot a\right) + \left(a \cdot z\right) \cdot b
\end{array}
(FPCore (x y z t a b) :precision binary64 (let* ((t_1 (+ (+ (+ x (* y z)) (* t a)) (* (* z a) b)))) (if (<= t_1 INFINITY) t_1 (* z (+ y (* a b))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = ((x + (y * z)) + (t * a)) + ((z * a) * b);
double tmp;
if (t_1 <= ((double) INFINITY)) {
tmp = t_1;
} else {
tmp = z * (y + (a * b));
}
return tmp;
}
public static double code(double x, double y, double z, double t, double a, double b) {
double t_1 = ((x + (y * z)) + (t * a)) + ((z * a) * b);
double tmp;
if (t_1 <= Double.POSITIVE_INFINITY) {
tmp = t_1;
} else {
tmp = z * (y + (a * b));
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = ((x + (y * z)) + (t * a)) + ((z * a) * b) tmp = 0 if t_1 <= math.inf: tmp = t_1 else: tmp = z * (y + (a * b)) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(Float64(x + Float64(y * z)) + Float64(t * a)) + Float64(Float64(z * a) * b)) tmp = 0.0 if (t_1 <= Inf) tmp = t_1; else tmp = Float64(z * Float64(y + Float64(a * b))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = ((x + (y * z)) + (t * a)) + ((z * a) * b); tmp = 0.0; if (t_1 <= Inf) tmp = t_1; else tmp = z * (y + (a * b)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(N[(x + N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(t * a), $MachinePrecision]), $MachinePrecision] + N[(N[(z * a), $MachinePrecision] * b), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, Infinity], t$95$1, N[(z * N[(y + N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(\left(x + y \cdot z\right) + t \cdot a\right) + \left(z \cdot a\right) \cdot b\\
\mathbf{if}\;t\_1 \leq \infty:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;z \cdot \left(y + a \cdot b\right)\\
\end{array}
\end{array}
if (+.f64 (+.f64 (+.f64 x (*.f64 y z)) (*.f64 t a)) (*.f64 (*.f64 a z) b)) < +inf.0Initial program 97.6%
if +inf.0 < (+.f64 (+.f64 (+.f64 x (*.f64 y z)) (*.f64 t a)) (*.f64 (*.f64 a z) b)) Initial program 0.0%
associate-+l+0.0%
associate-*l*8.3%
Simplified8.3%
Taylor expanded in z around inf 91.7%
Final simplification97.4%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (* z (+ y (* a b)))))
(if (<= z -2.3e+204)
t_1
(if (<= z 1e-40)
(+ (+ x (* y z)) (+ (* a (* z b)) (* t a)))
(+ x (+ t_1 (* t a)))))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = z * (y + (a * b));
double tmp;
if (z <= -2.3e+204) {
tmp = t_1;
} else if (z <= 1e-40) {
tmp = (x + (y * z)) + ((a * (z * b)) + (t * a));
} else {
tmp = x + (t_1 + (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) :: t_1
real(8) :: tmp
t_1 = z * (y + (a * b))
if (z <= (-2.3d+204)) then
tmp = t_1
else if (z <= 1d-40) then
tmp = (x + (y * z)) + ((a * (z * b)) + (t * a))
else
tmp = x + (t_1 + (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 t_1 = z * (y + (a * b));
double tmp;
if (z <= -2.3e+204) {
tmp = t_1;
} else if (z <= 1e-40) {
tmp = (x + (y * z)) + ((a * (z * b)) + (t * a));
} else {
tmp = x + (t_1 + (t * a));
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = z * (y + (a * b)) tmp = 0 if z <= -2.3e+204: tmp = t_1 elif z <= 1e-40: tmp = (x + (y * z)) + ((a * (z * b)) + (t * a)) else: tmp = x + (t_1 + (t * a)) return tmp
function code(x, y, z, t, a, b) t_1 = Float64(z * Float64(y + Float64(a * b))) tmp = 0.0 if (z <= -2.3e+204) tmp = t_1; elseif (z <= 1e-40) tmp = Float64(Float64(x + Float64(y * z)) + Float64(Float64(a * Float64(z * b)) + Float64(t * a))); else tmp = Float64(x + Float64(t_1 + Float64(t * a))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = z * (y + (a * b)); tmp = 0.0; if (z <= -2.3e+204) tmp = t_1; elseif (z <= 1e-40) tmp = (x + (y * z)) + ((a * (z * b)) + (t * a)); else tmp = x + (t_1 + (t * a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(z * N[(y + N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.3e+204], t$95$1, If[LessEqual[z, 1e-40], N[(N[(x + N[(y * z), $MachinePrecision]), $MachinePrecision] + N[(N[(a * N[(z * b), $MachinePrecision]), $MachinePrecision] + N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(t$95$1 + N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := z \cdot \left(y + a \cdot b\right)\\
\mathbf{if}\;z \leq -2.3 \cdot 10^{+204}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq 10^{-40}:\\
\;\;\;\;\left(x + y \cdot z\right) + \left(a \cdot \left(z \cdot b\right) + t \cdot a\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(t\_1 + t \cdot a\right)\\
\end{array}
\end{array}
if z < -2.2999999999999999e204Initial program 76.4%
associate-+l+76.4%
associate-*l*54.3%
Simplified54.3%
Taylor expanded in z around inf 83.2%
if -2.2999999999999999e204 < z < 9.9999999999999993e-41Initial program 98.7%
associate-+l+98.7%
associate-*l*99.4%
Simplified99.4%
if 9.9999999999999993e-41 < z Initial program 84.1%
associate-+l+84.1%
associate-*l*86.6%
Simplified86.6%
Taylor expanded in z around 0 95.8%
Final simplification97.3%
(FPCore (x y z t a b) :precision binary64 (if (or (<= z -2e+70) (not (<= z 4.5e-11))) (+ (* z (+ y (* a b))) (* t a)) (+ x (+ (* y z) (* t a)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -2e+70) || !(z <= 4.5e-11)) {
tmp = (z * (y + (a * b))) + (t * a);
} else {
tmp = x + ((y * z) + (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 ((z <= (-2d+70)) .or. (.not. (z <= 4.5d-11))) then
tmp = (z * (y + (a * b))) + (t * a)
else
tmp = x + ((y * z) + (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 ((z <= -2e+70) || !(z <= 4.5e-11)) {
tmp = (z * (y + (a * b))) + (t * a);
} else {
tmp = x + ((y * z) + (t * a));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -2e+70) or not (z <= 4.5e-11): tmp = (z * (y + (a * b))) + (t * a) else: tmp = x + ((y * z) + (t * a)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -2e+70) || !(z <= 4.5e-11)) tmp = Float64(Float64(z * Float64(y + Float64(a * b))) + Float64(t * a)); else tmp = Float64(x + Float64(Float64(y * z) + Float64(t * a))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -2e+70) || ~((z <= 4.5e-11))) tmp = (z * (y + (a * b))) + (t * a); else tmp = x + ((y * z) + (t * a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -2e+70], N[Not[LessEqual[z, 4.5e-11]], $MachinePrecision]], N[(N[(z * N[(y + N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t * a), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y * z), $MachinePrecision] + N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2 \cdot 10^{+70} \lor \neg \left(z \leq 4.5 \cdot 10^{-11}\right):\\
\;\;\;\;z \cdot \left(y + a \cdot b\right) + t \cdot a\\
\mathbf{else}:\\
\;\;\;\;x + \left(y \cdot z + t \cdot a\right)\\
\end{array}
\end{array}
if z < -2.00000000000000015e70 or 4.5e-11 < z Initial program 84.5%
associate-+l+84.5%
associate-*l*83.7%
Simplified83.7%
Taylor expanded in z around 0 94.4%
Taylor expanded in x around 0 87.9%
if -2.00000000000000015e70 < z < 4.5e-11Initial program 99.3%
associate-+l+99.3%
associate-*l*99.3%
Simplified99.3%
Taylor expanded in b around 0 90.5%
Final simplification89.4%
(FPCore (x y z t a b) :precision binary64 (if (or (<= a -9.2e+37) (not (<= a 2.65e+47))) (+ x (* a (+ t (* z b)))) (+ x (+ (* y z) (* t a)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((a <= -9.2e+37) || !(a <= 2.65e+47)) {
tmp = x + (a * (t + (z * b)));
} else {
tmp = x + ((y * z) + (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 <= (-9.2d+37)) .or. (.not. (a <= 2.65d+47))) then
tmp = x + (a * (t + (z * b)))
else
tmp = x + ((y * z) + (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 <= -9.2e+37) || !(a <= 2.65e+47)) {
tmp = x + (a * (t + (z * b)));
} else {
tmp = x + ((y * z) + (t * a));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (a <= -9.2e+37) or not (a <= 2.65e+47): tmp = x + (a * (t + (z * b))) else: tmp = x + ((y * z) + (t * a)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((a <= -9.2e+37) || !(a <= 2.65e+47)) tmp = Float64(x + Float64(a * Float64(t + Float64(z * b)))); else tmp = Float64(x + Float64(Float64(y * z) + Float64(t * a))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((a <= -9.2e+37) || ~((a <= 2.65e+47))) tmp = x + (a * (t + (z * b))); else tmp = x + ((y * z) + (t * a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[a, -9.2e+37], N[Not[LessEqual[a, 2.65e+47]], $MachinePrecision]], N[(x + N[(a * N[(t + N[(z * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y * z), $MachinePrecision] + N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -9.2 \cdot 10^{+37} \lor \neg \left(a \leq 2.65 \cdot 10^{+47}\right):\\
\;\;\;\;x + a \cdot \left(t + z \cdot b\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(y \cdot z + t \cdot a\right)\\
\end{array}
\end{array}
if a < -9.2000000000000001e37 or 2.65e47 < a Initial program 85.7%
associate-+l+85.7%
+-commutative85.7%
fma-define85.7%
associate-*l*91.4%
*-commutative91.4%
*-commutative91.4%
distribute-rgt-out94.8%
*-commutative94.8%
Simplified94.8%
Taylor expanded in y around 0 86.3%
if -9.2000000000000001e37 < a < 2.65e47Initial program 99.2%
associate-+l+99.2%
associate-*l*93.8%
Simplified93.8%
Taylor expanded in b around 0 90.9%
Final simplification88.8%
(FPCore (x y z t a b) :precision binary64 (if (or (<= z -1.6e-32) (not (<= z 3.1e+33))) (* z (+ y (* a b))) (+ x (* a (+ t (* z b))))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -1.6e-32) || !(z <= 3.1e+33)) {
tmp = z * (y + (a * b));
} else {
tmp = x + (a * (t + (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 ((z <= (-1.6d-32)) .or. (.not. (z <= 3.1d+33))) then
tmp = z * (y + (a * b))
else
tmp = x + (a * (t + (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 ((z <= -1.6e-32) || !(z <= 3.1e+33)) {
tmp = z * (y + (a * b));
} else {
tmp = x + (a * (t + (z * b)));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -1.6e-32) or not (z <= 3.1e+33): tmp = z * (y + (a * b)) else: tmp = x + (a * (t + (z * b))) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -1.6e-32) || !(z <= 3.1e+33)) tmp = Float64(z * Float64(y + Float64(a * b))); else tmp = Float64(x + Float64(a * Float64(t + Float64(z * b)))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -1.6e-32) || ~((z <= 3.1e+33))) tmp = z * (y + (a * b)); else tmp = x + (a * (t + (z * b))); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -1.6e-32], N[Not[LessEqual[z, 3.1e+33]], $MachinePrecision]], N[(z * N[(y + N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(a * N[(t + N[(z * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.6 \cdot 10^{-32} \lor \neg \left(z \leq 3.1 \cdot 10^{+33}\right):\\
\;\;\;\;z \cdot \left(y + a \cdot b\right)\\
\mathbf{else}:\\
\;\;\;\;x + a \cdot \left(t + z \cdot b\right)\\
\end{array}
\end{array}
if z < -1.6000000000000001e-32 or 3.1e33 < z Initial program 87.0%
associate-+l+87.0%
associate-*l*86.3%
Simplified86.3%
Taylor expanded in z around inf 80.8%
if -1.6000000000000001e-32 < z < 3.1e33Initial program 99.2%
associate-+l+99.2%
+-commutative99.2%
fma-define99.2%
associate-*l*99.2%
*-commutative99.2%
*-commutative99.2%
distribute-rgt-out100.0%
*-commutative100.0%
Simplified100.0%
Taylor expanded in y around 0 88.6%
Final simplification84.7%
(FPCore (x y z t a b) :precision binary64 (if (<= z -1.15e+129) (* (* z a) b) (if (or (<= z -1.02e-33) (not (<= z 2.75e-63))) (* y z) x)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -1.15e+129) {
tmp = (z * a) * b;
} else if ((z <= -1.02e-33) || !(z <= 2.75e-63)) {
tmp = y * z;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (z <= (-1.15d+129)) then
tmp = (z * a) * b
else if ((z <= (-1.02d-33)) .or. (.not. (z <= 2.75d-63))) then
tmp = y * z
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (z <= -1.15e+129) {
tmp = (z * a) * b;
} else if ((z <= -1.02e-33) || !(z <= 2.75e-63)) {
tmp = y * z;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if z <= -1.15e+129: tmp = (z * a) * b elif (z <= -1.02e-33) or not (z <= 2.75e-63): tmp = y * z else: tmp = x return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (z <= -1.15e+129) tmp = Float64(Float64(z * a) * b); elseif ((z <= -1.02e-33) || !(z <= 2.75e-63)) tmp = Float64(y * z); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (z <= -1.15e+129) tmp = (z * a) * b; elseif ((z <= -1.02e-33) || ~((z <= 2.75e-63))) tmp = y * z; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[z, -1.15e+129], N[(N[(z * a), $MachinePrecision] * b), $MachinePrecision], If[Or[LessEqual[z, -1.02e-33], N[Not[LessEqual[z, 2.75e-63]], $MachinePrecision]], N[(y * z), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.15 \cdot 10^{+129}:\\
\;\;\;\;\left(z \cdot a\right) \cdot b\\
\mathbf{elif}\;z \leq -1.02 \cdot 10^{-33} \lor \neg \left(z \leq 2.75 \cdot 10^{-63}\right):\\
\;\;\;\;y \cdot z\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -1.14999999999999995e129Initial program 84.7%
associate-+l+84.7%
+-commutative84.7%
fma-define84.7%
associate-*l*76.4%
*-commutative76.4%
*-commutative76.4%
distribute-rgt-out79.5%
*-commutative79.5%
Simplified79.5%
Taylor expanded in y around 0 63.1%
Taylor expanded in b around inf 47.5%
associate-*r*53.0%
*-commutative53.0%
associate-*r*58.7%
Simplified58.7%
if -1.14999999999999995e129 < z < -1.02e-33 or 2.75000000000000022e-63 < z Initial program 89.9%
associate-+l+89.9%
associate-*l*91.5%
Simplified91.5%
Taylor expanded in y around inf 53.2%
*-commutative53.2%
Simplified53.2%
if -1.02e-33 < z < 2.75000000000000022e-63Initial program 99.0%
associate-+l+99.0%
associate-*l*99.0%
Simplified99.0%
Taylor expanded in x around inf 48.1%
Final simplification51.8%
(FPCore (x y z t a b) :precision binary64 (if (<= a -5e+173) (+ (* y z) (* a (+ t (* z b)))) (+ x (+ (* z (+ y (* a b))) (* t a)))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= -5e+173) {
tmp = (y * z) + (a * (t + (z * b)));
} else {
tmp = x + ((z * (y + (a * b))) + (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 <= (-5d+173)) then
tmp = (y * z) + (a * (t + (z * b)))
else
tmp = x + ((z * (y + (a * b))) + (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 <= -5e+173) {
tmp = (y * z) + (a * (t + (z * b)));
} else {
tmp = x + ((z * (y + (a * b))) + (t * a));
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if a <= -5e+173: tmp = (y * z) + (a * (t + (z * b))) else: tmp = x + ((z * (y + (a * b))) + (t * a)) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (a <= -5e+173) tmp = Float64(Float64(y * z) + Float64(a * Float64(t + Float64(z * b)))); else tmp = Float64(x + Float64(Float64(z * Float64(y + Float64(a * b))) + Float64(t * a))); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (a <= -5e+173) tmp = (y * z) + (a * (t + (z * b))); else tmp = x + ((z * (y + (a * b))) + (t * a)); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[a, -5e+173], N[(N[(y * z), $MachinePrecision] + N[(a * N[(t + N[(z * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(z * N[(y + N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -5 \cdot 10^{+173}:\\
\;\;\;\;y \cdot z + a \cdot \left(t + z \cdot b\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(z \cdot \left(y + a \cdot b\right) + t \cdot a\right)\\
\end{array}
\end{array}
if a < -5.00000000000000034e173Initial program 80.5%
associate-+l+80.5%
+-commutative80.5%
fma-define80.5%
associate-*l*89.9%
*-commutative89.9%
*-commutative89.9%
distribute-rgt-out96.6%
*-commutative96.6%
Simplified96.6%
Taylor expanded in x around 0 93.3%
if -5.00000000000000034e173 < a Initial program 94.7%
associate-+l+94.7%
associate-*l*93.1%
Simplified93.1%
Taylor expanded in z around 0 94.8%
Final simplification94.6%
(FPCore (x y z t a b) :precision binary64 (if (or (<= z -2e-33) (not (<= z 1.36e-42))) (* z (+ y (* a b))) (+ x (* t a))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -2e-33) || !(z <= 1.36e-42)) {
tmp = z * (y + (a * b));
} else {
tmp = x + (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 ((z <= (-2d-33)) .or. (.not. (z <= 1.36d-42))) then
tmp = z * (y + (a * b))
else
tmp = x + (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 ((z <= -2e-33) || !(z <= 1.36e-42)) {
tmp = z * (y + (a * b));
} else {
tmp = x + (t * a);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -2e-33) or not (z <= 1.36e-42): tmp = z * (y + (a * b)) else: tmp = x + (t * a) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -2e-33) || !(z <= 1.36e-42)) tmp = Float64(z * Float64(y + Float64(a * b))); else tmp = Float64(x + Float64(t * a)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -2e-33) || ~((z <= 1.36e-42))) tmp = z * (y + (a * b)); else tmp = x + (t * a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -2e-33], N[Not[LessEqual[z, 1.36e-42]], $MachinePrecision]], N[(z * N[(y + N[(a * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(t * a), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -2 \cdot 10^{-33} \lor \neg \left(z \leq 1.36 \cdot 10^{-42}\right):\\
\;\;\;\;z \cdot \left(y + a \cdot b\right)\\
\mathbf{else}:\\
\;\;\;\;x + t \cdot a\\
\end{array}
\end{array}
if z < -2.0000000000000001e-33 or 1.36e-42 < z Initial program 88.6%
associate-+l+88.6%
associate-*l*88.0%
Simplified88.0%
Taylor expanded in z around inf 78.1%
if -2.0000000000000001e-33 < z < 1.36e-42Initial program 99.0%
associate-+l+99.0%
associate-*l*99.1%
Simplified99.1%
Taylor expanded in z around 0 83.7%
+-commutative83.7%
Simplified83.7%
Final simplification80.5%
(FPCore (x y z t a b) :precision binary64 (if (or (<= a -5.5e+30) (not (<= a 5.5e+40))) (* a (+ t (* z b))) (+ x (* y z))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((a <= -5.5e+30) || !(a <= 5.5e+40)) {
tmp = a * (t + (z * b));
} else {
tmp = x + (y * z);
}
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 <= (-5.5d+30)) .or. (.not. (a <= 5.5d+40))) then
tmp = a * (t + (z * b))
else
tmp = x + (y * z)
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 <= -5.5e+30) || !(a <= 5.5e+40)) {
tmp = a * (t + (z * b));
} else {
tmp = x + (y * z);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (a <= -5.5e+30) or not (a <= 5.5e+40): tmp = a * (t + (z * b)) else: tmp = x + (y * z) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((a <= -5.5e+30) || !(a <= 5.5e+40)) tmp = Float64(a * Float64(t + Float64(z * b))); else tmp = Float64(x + Float64(y * z)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((a <= -5.5e+30) || ~((a <= 5.5e+40))) tmp = a * (t + (z * b)); else tmp = x + (y * z); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[a, -5.5e+30], N[Not[LessEqual[a, 5.5e+40]], $MachinePrecision]], N[(a * N[(t + N[(z * b), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(x + N[(y * z), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -5.5 \cdot 10^{+30} \lor \neg \left(a \leq 5.5 \cdot 10^{+40}\right):\\
\;\;\;\;a \cdot \left(t + z \cdot b\right)\\
\mathbf{else}:\\
\;\;\;\;x + y \cdot z\\
\end{array}
\end{array}
if a < -5.50000000000000025e30 or 5.49999999999999974e40 < a Initial program 86.2%
associate-+l+86.2%
associate-*l*91.7%
Simplified91.7%
Taylor expanded in a around inf 70.8%
if -5.50000000000000025e30 < a < 5.49999999999999974e40Initial program 99.2%
associate-+l+99.2%
associate-*l*93.6%
Simplified93.6%
Taylor expanded in a around 0 79.4%
Final simplification75.3%
(FPCore (x y z t a b) :precision binary64 (if (or (<= z -1.55e-55) (not (<= z 4.2e-40))) (+ x (* y z)) (+ x (* t a))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -1.55e-55) || !(z <= 4.2e-40)) {
tmp = x + (y * z);
} else {
tmp = x + (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 ((z <= (-1.55d-55)) .or. (.not. (z <= 4.2d-40))) then
tmp = x + (y * z)
else
tmp = x + (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 ((z <= -1.55e-55) || !(z <= 4.2e-40)) {
tmp = x + (y * z);
} else {
tmp = x + (t * a);
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -1.55e-55) or not (z <= 4.2e-40): tmp = x + (y * z) else: tmp = x + (t * a) return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -1.55e-55) || !(z <= 4.2e-40)) tmp = Float64(x + Float64(y * z)); else tmp = Float64(x + Float64(t * a)); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -1.55e-55) || ~((z <= 4.2e-40))) tmp = x + (y * z); else tmp = x + (t * a); end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -1.55e-55], N[Not[LessEqual[z, 4.2e-40]], $MachinePrecision]], N[(x + N[(y * z), $MachinePrecision]), $MachinePrecision], N[(x + N[(t * a), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.55 \cdot 10^{-55} \lor \neg \left(z \leq 4.2 \cdot 10^{-40}\right):\\
\;\;\;\;x + y \cdot z\\
\mathbf{else}:\\
\;\;\;\;x + t \cdot a\\
\end{array}
\end{array}
if z < -1.54999999999999998e-55 or 4.20000000000000036e-40 < z Initial program 88.8%
associate-+l+88.8%
associate-*l*88.2%
Simplified88.2%
Taylor expanded in a around 0 61.2%
if -1.54999999999999998e-55 < z < 4.20000000000000036e-40Initial program 99.0%
associate-+l+99.0%
associate-*l*99.0%
Simplified99.0%
Taylor expanded in z around 0 83.3%
+-commutative83.3%
Simplified83.3%
Final simplification70.5%
(FPCore (x y z t a b) :precision binary64 (if (<= a -1.55e+136) (* (* z a) b) (if (<= a 1.6e+202) (+ x (* y z)) (* t a))))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (a <= -1.55e+136) {
tmp = (z * a) * b;
} else if (a <= 1.6e+202) {
tmp = x + (y * z);
} else {
tmp = 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 <= (-1.55d+136)) then
tmp = (z * a) * b
else if (a <= 1.6d+202) then
tmp = x + (y * z)
else
tmp = 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 <= -1.55e+136) {
tmp = (z * a) * b;
} else if (a <= 1.6e+202) {
tmp = x + (y * z);
} else {
tmp = t * a;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if a <= -1.55e+136: tmp = (z * a) * b elif a <= 1.6e+202: tmp = x + (y * z) else: tmp = t * a return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (a <= -1.55e+136) tmp = Float64(Float64(z * a) * b); elseif (a <= 1.6e+202) tmp = Float64(x + Float64(y * z)); else tmp = Float64(t * a); end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (a <= -1.55e+136) tmp = (z * a) * b; elseif (a <= 1.6e+202) tmp = x + (y * z); else tmp = t * a; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[a, -1.55e+136], N[(N[(z * a), $MachinePrecision] * b), $MachinePrecision], If[LessEqual[a, 1.6e+202], N[(x + N[(y * z), $MachinePrecision]), $MachinePrecision], N[(t * a), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;a \leq -1.55 \cdot 10^{+136}:\\
\;\;\;\;\left(z \cdot a\right) \cdot b\\
\mathbf{elif}\;a \leq 1.6 \cdot 10^{+202}:\\
\;\;\;\;x + y \cdot z\\
\mathbf{else}:\\
\;\;\;\;t \cdot a\\
\end{array}
\end{array}
if a < -1.54999999999999992e136Initial program 84.2%
associate-+l+84.2%
+-commutative84.2%
fma-define84.2%
associate-*l*91.8%
*-commutative91.8%
*-commutative91.8%
distribute-rgt-out97.3%
*-commutative97.3%
Simplified97.3%
Taylor expanded in y around 0 84.6%
Taylor expanded in b around inf 46.4%
associate-*r*45.8%
*-commutative45.8%
associate-*r*49.0%
Simplified49.0%
if -1.54999999999999992e136 < a < 1.60000000000000006e202Initial program 96.0%
associate-+l+96.0%
associate-*l*93.2%
Simplified93.2%
Taylor expanded in a around 0 68.1%
if 1.60000000000000006e202 < a Initial program 78.1%
associate-+l+78.1%
associate-*l*88.9%
Simplified88.9%
Taylor expanded in t around inf 53.0%
Final simplification64.3%
(FPCore (x y z t a b) :precision binary64 (if (or (<= z -1.92e-32) (not (<= z 1.96e-63))) (* y z) x))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -1.92e-32) || !(z <= 1.96e-63)) {
tmp = y * z;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if ((z <= (-1.92d-32)) .or. (.not. (z <= 1.96d-63))) then
tmp = y * z
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if ((z <= -1.92e-32) || !(z <= 1.96e-63)) {
tmp = y * z;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if (z <= -1.92e-32) or not (z <= 1.96e-63): tmp = y * z else: tmp = x return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if ((z <= -1.92e-32) || !(z <= 1.96e-63)) tmp = Float64(y * z); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if ((z <= -1.92e-32) || ~((z <= 1.96e-63))) tmp = y * z; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[Or[LessEqual[z, -1.92e-32], N[Not[LessEqual[z, 1.96e-63]], $MachinePrecision]], N[(y * z), $MachinePrecision], x]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -1.92 \cdot 10^{-32} \lor \neg \left(z \leq 1.96 \cdot 10^{-63}\right):\\
\;\;\;\;y \cdot z\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if z < -1.92e-32 or 1.9600000000000001e-63 < z Initial program 88.7%
associate-+l+88.7%
associate-*l*88.1%
Simplified88.1%
Taylor expanded in y around inf 49.3%
*-commutative49.3%
Simplified49.3%
if -1.92e-32 < z < 1.9600000000000001e-63Initial program 99.0%
associate-+l+99.0%
associate-*l*99.0%
Simplified99.0%
Taylor expanded in x around inf 48.1%
Final simplification48.8%
(FPCore (x y z t a b) :precision binary64 (if (<= x -4.8e+42) x (if (<= x 3.1e+117) (* t a) x)))
double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (x <= -4.8e+42) {
tmp = x;
} else if (x <= 3.1e+117) {
tmp = t * a;
} else {
tmp = x;
}
return tmp;
}
real(8) function code(x, y, z, t, a, b)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8), intent (in) :: t
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8) :: tmp
if (x <= (-4.8d+42)) then
tmp = x
else if (x <= 3.1d+117) then
tmp = t * a
else
tmp = x
end if
code = tmp
end function
public static double code(double x, double y, double z, double t, double a, double b) {
double tmp;
if (x <= -4.8e+42) {
tmp = x;
} else if (x <= 3.1e+117) {
tmp = t * a;
} else {
tmp = x;
}
return tmp;
}
def code(x, y, z, t, a, b): tmp = 0 if x <= -4.8e+42: tmp = x elif x <= 3.1e+117: tmp = t * a else: tmp = x return tmp
function code(x, y, z, t, a, b) tmp = 0.0 if (x <= -4.8e+42) tmp = x; elseif (x <= 3.1e+117) tmp = Float64(t * a); else tmp = x; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) tmp = 0.0; if (x <= -4.8e+42) tmp = x; elseif (x <= 3.1e+117) tmp = t * a; else tmp = x; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := If[LessEqual[x, -4.8e+42], x, If[LessEqual[x, 3.1e+117], N[(t * a), $MachinePrecision], x]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -4.8 \cdot 10^{+42}:\\
\;\;\;\;x\\
\mathbf{elif}\;x \leq 3.1 \cdot 10^{+117}:\\
\;\;\;\;t \cdot a\\
\mathbf{else}:\\
\;\;\;\;x\\
\end{array}
\end{array}
if x < -4.7999999999999997e42 or 3.09999999999999975e117 < x Initial program 96.2%
associate-+l+96.2%
associate-*l*94.5%
Simplified94.5%
Taylor expanded in x around inf 53.7%
if -4.7999999999999997e42 < x < 3.09999999999999975e117Initial program 90.9%
associate-+l+90.9%
associate-*l*91.5%
Simplified91.5%
Taylor expanded in t around inf 30.3%
Final simplification40.0%
(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 93.1%
associate-+l+93.1%
associate-*l*92.7%
Simplified92.7%
Taylor expanded in x around inf 27.8%
(FPCore (x y z t a b)
:precision binary64
(let* ((t_1 (+ (* z (+ (* b a) y)) (+ x (* t a)))))
(if (< z -11820553527347888000.0)
t_1
(if (< z 4.7589743188364287e-122)
(+ (* (+ (* b z) t) a) (+ (* z y) x))
t_1))))
double code(double x, double y, double z, double t, double a, double b) {
double t_1 = (z * ((b * a) + y)) + (x + (t * a));
double tmp;
if (z < -11820553527347888000.0) {
tmp = t_1;
} else if (z < 4.7589743188364287e-122) {
tmp = (((b * z) + t) * a) + ((z * y) + x);
} 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 = (z * ((b * a) + y)) + (x + (t * a))
if (z < (-11820553527347888000.0d0)) then
tmp = t_1
else if (z < 4.7589743188364287d-122) then
tmp = (((b * z) + t) * a) + ((z * y) + x)
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 = (z * ((b * a) + y)) + (x + (t * a));
double tmp;
if (z < -11820553527347888000.0) {
tmp = t_1;
} else if (z < 4.7589743188364287e-122) {
tmp = (((b * z) + t) * a) + ((z * y) + x);
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z, t, a, b): t_1 = (z * ((b * a) + y)) + (x + (t * a)) tmp = 0 if z < -11820553527347888000.0: tmp = t_1 elif z < 4.7589743188364287e-122: tmp = (((b * z) + t) * a) + ((z * y) + x) else: tmp = t_1 return tmp
function code(x, y, z, t, a, b) t_1 = Float64(Float64(z * Float64(Float64(b * a) + y)) + Float64(x + Float64(t * a))) tmp = 0.0 if (z < -11820553527347888000.0) tmp = t_1; elseif (z < 4.7589743188364287e-122) tmp = Float64(Float64(Float64(Float64(b * z) + t) * a) + Float64(Float64(z * y) + x)); else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z, t, a, b) t_1 = (z * ((b * a) + y)) + (x + (t * a)); tmp = 0.0; if (z < -11820553527347888000.0) tmp = t_1; elseif (z < 4.7589743188364287e-122) tmp = (((b * z) + t) * a) + ((z * y) + x); else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_, t_, a_, b_] := Block[{t$95$1 = N[(N[(z * N[(N[(b * a), $MachinePrecision] + y), $MachinePrecision]), $MachinePrecision] + N[(x + N[(t * a), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[z, -11820553527347888000.0], t$95$1, If[Less[z, 4.7589743188364287e-122], N[(N[(N[(N[(b * z), $MachinePrecision] + t), $MachinePrecision] * a), $MachinePrecision] + N[(N[(z * y), $MachinePrecision] + x), $MachinePrecision]), $MachinePrecision], t$95$1]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := z \cdot \left(b \cdot a + y\right) + \left(x + t \cdot a\right)\\
\mathbf{if}\;z < -11820553527347888000:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z < 4.7589743188364287 \cdot 10^{-122}:\\
\;\;\;\;\left(b \cdot z + t\right) \cdot a + \left(z \cdot y + x\right)\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
herbie shell --seed 2024119
(FPCore (x y z t a b)
:name "Graphics.Rasterific.CubicBezier:cachedBezierAt from Rasterific-0.6.1"
:precision binary64
:alt
(! :herbie-platform default (if (< z -11820553527347888000) (+ (* z (+ (* b a) y)) (+ x (* t a))) (if (< z 47589743188364287/1000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000) (+ (* (+ (* b z) t) a) (+ (* z y) x)) (+ (* z (+ (* b a) y)) (+ x (* t a))))))
(+ (+ (+ x (* y z)) (* t a)) (* (* a z) b)))