
(FPCore (x y z) :precision binary64 (+ x (* (* (- y x) 6.0) (- (/ 2.0 3.0) z))))
double code(double x, double y, double z) {
return x + (((y - x) * 6.0) * ((2.0 / 3.0) - z));
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = x + (((y - x) * 6.0d0) * ((2.0d0 / 3.0d0) - z))
end function
public static double code(double x, double y, double z) {
return x + (((y - x) * 6.0) * ((2.0 / 3.0) - z));
}
def code(x, y, z): return x + (((y - x) * 6.0) * ((2.0 / 3.0) - z))
function code(x, y, z) return Float64(x + Float64(Float64(Float64(y - x) * 6.0) * Float64(Float64(2.0 / 3.0) - z))) end
function tmp = code(x, y, z) tmp = x + (((y - x) * 6.0) * ((2.0 / 3.0) - z)); end
code[x_, y_, z_] := N[(x + N[(N[(N[(y - x), $MachinePrecision] * 6.0), $MachinePrecision] * N[(N[(2.0 / 3.0), $MachinePrecision] - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(\left(y - x\right) \cdot 6\right) \cdot \left(\frac{2}{3} - z\right)
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 16 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z) :precision binary64 (+ x (* (* (- y x) 6.0) (- (/ 2.0 3.0) z))))
double code(double x, double y, double z) {
return x + (((y - x) * 6.0) * ((2.0 / 3.0) - z));
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = x + (((y - x) * 6.0d0) * ((2.0d0 / 3.0d0) - z))
end function
public static double code(double x, double y, double z) {
return x + (((y - x) * 6.0) * ((2.0 / 3.0) - z));
}
def code(x, y, z): return x + (((y - x) * 6.0) * ((2.0 / 3.0) - z))
function code(x, y, z) return Float64(x + Float64(Float64(Float64(y - x) * 6.0) * Float64(Float64(2.0 / 3.0) - z))) end
function tmp = code(x, y, z) tmp = x + (((y - x) * 6.0) * ((2.0 / 3.0) - z)); end
code[x_, y_, z_] := N[(x + N[(N[(N[(y - x), $MachinePrecision] * 6.0), $MachinePrecision] * N[(N[(2.0 / 3.0), $MachinePrecision] - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(\left(y - x\right) \cdot 6\right) \cdot \left(\frac{2}{3} - z\right)
\end{array}
(FPCore (x y z) :precision binary64 (fma (- y x) (+ 4.0 (* z -6.0)) x))
double code(double x, double y, double z) {
return fma((y - x), (4.0 + (z * -6.0)), x);
}
function code(x, y, z) return fma(Float64(y - x), Float64(4.0 + Float64(z * -6.0)), x) end
code[x_, y_, z_] := N[(N[(y - x), $MachinePrecision] * N[(4.0 + N[(z * -6.0), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision]
\begin{array}{l}
\\
\mathsf{fma}\left(y - x, 4 + z \cdot -6, x\right)
\end{array}
Initial program 99.7%
+-commutative99.7%
associate-*l*99.8%
fma-define99.8%
sub-neg99.8%
distribute-rgt-in99.8%
metadata-eval99.8%
metadata-eval99.8%
distribute-lft-neg-out99.8%
distribute-rgt-neg-in99.8%
metadata-eval99.8%
Simplified99.8%
Final simplification99.8%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* -6.0 (* y z))) (t_1 (* 6.0 (* x z))))
(if (<= z -8e+241)
t_0
(if (<= z -1.8e+130)
t_1
(if (<= z -6.5e+70)
t_0
(if (<= z -3700.0)
t_1
(if (<= z -1.75e-159)
(* x -3.0)
(if (<= z -3.3e-193)
(* y 4.0)
(if (<= z 5.5e-299)
(* x -3.0)
(if (<= z 1.8e-182)
(* y 4.0)
(if (<= z 0.5)
(* x -3.0)
(if (<= z 1.3e+216) t_0 t_1))))))))))))
double code(double x, double y, double z) {
double t_0 = -6.0 * (y * z);
double t_1 = 6.0 * (x * z);
double tmp;
if (z <= -8e+241) {
tmp = t_0;
} else if (z <= -1.8e+130) {
tmp = t_1;
} else if (z <= -6.5e+70) {
tmp = t_0;
} else if (z <= -3700.0) {
tmp = t_1;
} else if (z <= -1.75e-159) {
tmp = x * -3.0;
} else if (z <= -3.3e-193) {
tmp = y * 4.0;
} else if (z <= 5.5e-299) {
tmp = x * -3.0;
} else if (z <= 1.8e-182) {
tmp = y * 4.0;
} else if (z <= 0.5) {
tmp = x * -3.0;
} else if (z <= 1.3e+216) {
tmp = t_0;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = (-6.0d0) * (y * z)
t_1 = 6.0d0 * (x * z)
if (z <= (-8d+241)) then
tmp = t_0
else if (z <= (-1.8d+130)) then
tmp = t_1
else if (z <= (-6.5d+70)) then
tmp = t_0
else if (z <= (-3700.0d0)) then
tmp = t_1
else if (z <= (-1.75d-159)) then
tmp = x * (-3.0d0)
else if (z <= (-3.3d-193)) then
tmp = y * 4.0d0
else if (z <= 5.5d-299) then
tmp = x * (-3.0d0)
else if (z <= 1.8d-182) then
tmp = y * 4.0d0
else if (z <= 0.5d0) then
tmp = x * (-3.0d0)
else if (z <= 1.3d+216) then
tmp = t_0
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = -6.0 * (y * z);
double t_1 = 6.0 * (x * z);
double tmp;
if (z <= -8e+241) {
tmp = t_0;
} else if (z <= -1.8e+130) {
tmp = t_1;
} else if (z <= -6.5e+70) {
tmp = t_0;
} else if (z <= -3700.0) {
tmp = t_1;
} else if (z <= -1.75e-159) {
tmp = x * -3.0;
} else if (z <= -3.3e-193) {
tmp = y * 4.0;
} else if (z <= 5.5e-299) {
tmp = x * -3.0;
} else if (z <= 1.8e-182) {
tmp = y * 4.0;
} else if (z <= 0.5) {
tmp = x * -3.0;
} else if (z <= 1.3e+216) {
tmp = t_0;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z): t_0 = -6.0 * (y * z) t_1 = 6.0 * (x * z) tmp = 0 if z <= -8e+241: tmp = t_0 elif z <= -1.8e+130: tmp = t_1 elif z <= -6.5e+70: tmp = t_0 elif z <= -3700.0: tmp = t_1 elif z <= -1.75e-159: tmp = x * -3.0 elif z <= -3.3e-193: tmp = y * 4.0 elif z <= 5.5e-299: tmp = x * -3.0 elif z <= 1.8e-182: tmp = y * 4.0 elif z <= 0.5: tmp = x * -3.0 elif z <= 1.3e+216: tmp = t_0 else: tmp = t_1 return tmp
function code(x, y, z) t_0 = Float64(-6.0 * Float64(y * z)) t_1 = Float64(6.0 * Float64(x * z)) tmp = 0.0 if (z <= -8e+241) tmp = t_0; elseif (z <= -1.8e+130) tmp = t_1; elseif (z <= -6.5e+70) tmp = t_0; elseif (z <= -3700.0) tmp = t_1; elseif (z <= -1.75e-159) tmp = Float64(x * -3.0); elseif (z <= -3.3e-193) tmp = Float64(y * 4.0); elseif (z <= 5.5e-299) tmp = Float64(x * -3.0); elseif (z <= 1.8e-182) tmp = Float64(y * 4.0); elseif (z <= 0.5) tmp = Float64(x * -3.0); elseif (z <= 1.3e+216) tmp = t_0; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z) t_0 = -6.0 * (y * z); t_1 = 6.0 * (x * z); tmp = 0.0; if (z <= -8e+241) tmp = t_0; elseif (z <= -1.8e+130) tmp = t_1; elseif (z <= -6.5e+70) tmp = t_0; elseif (z <= -3700.0) tmp = t_1; elseif (z <= -1.75e-159) tmp = x * -3.0; elseif (z <= -3.3e-193) tmp = y * 4.0; elseif (z <= 5.5e-299) tmp = x * -3.0; elseif (z <= 1.8e-182) tmp = y * 4.0; elseif (z <= 0.5) tmp = x * -3.0; elseif (z <= 1.3e+216) tmp = t_0; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(-6.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(6.0 * N[(x * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -8e+241], t$95$0, If[LessEqual[z, -1.8e+130], t$95$1, If[LessEqual[z, -6.5e+70], t$95$0, If[LessEqual[z, -3700.0], t$95$1, If[LessEqual[z, -1.75e-159], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, -3.3e-193], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 5.5e-299], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 1.8e-182], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 0.5], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 1.3e+216], t$95$0, t$95$1]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := -6 \cdot \left(y \cdot z\right)\\
t_1 := 6 \cdot \left(x \cdot z\right)\\
\mathbf{if}\;z \leq -8 \cdot 10^{+241}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -1.8 \cdot 10^{+130}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -6.5 \cdot 10^{+70}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -3700:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -1.75 \cdot 10^{-159}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq -3.3 \cdot 10^{-193}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 5.5 \cdot 10^{-299}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 1.8 \cdot 10^{-182}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 0.5:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 1.3 \cdot 10^{+216}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -8.0000000000000004e241 or -1.8000000000000001e130 < z < -6.49999999999999978e70 or 0.5 < z < 1.2999999999999999e216Initial program 99.8%
+-commutative99.8%
associate-*l*99.8%
fma-define99.8%
sub-neg99.8%
distribute-rgt-in99.8%
metadata-eval99.8%
metadata-eval99.8%
distribute-lft-neg-out99.8%
distribute-rgt-neg-in99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around inf 64.5%
Taylor expanded in z around inf 64.4%
*-commutative64.4%
Simplified64.4%
if -8.0000000000000004e241 < z < -1.8000000000000001e130 or -6.49999999999999978e70 < z < -3700 or 1.2999999999999999e216 < z Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in x around inf 68.5%
sub-neg68.5%
distribute-rgt-in68.5%
metadata-eval68.5%
neg-mul-168.5%
associate-*r*68.5%
*-commutative68.5%
associate-+r+68.5%
metadata-eval68.5%
associate-*r*68.5%
metadata-eval68.5%
*-commutative68.5%
Simplified68.5%
Taylor expanded in z around inf 65.6%
if -3700 < z < -1.75000000000000001e-159 or -3.2999999999999999e-193 < z < 5.5e-299 or 1.79999999999999988e-182 < z < 0.5Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around inf 65.9%
sub-neg65.9%
distribute-rgt-in65.9%
metadata-eval65.9%
neg-mul-165.9%
associate-*r*65.9%
*-commutative65.9%
associate-+r+65.9%
metadata-eval65.9%
associate-*r*65.9%
metadata-eval65.9%
*-commutative65.9%
Simplified65.9%
Taylor expanded in z around 0 64.0%
*-commutative64.0%
Simplified64.0%
if -1.75000000000000001e-159 < z < -3.2999999999999999e-193 or 5.5e-299 < z < 1.79999999999999988e-182Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 99.9%
Taylor expanded in x around 0 72.3%
Final simplification65.2%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* -6.0 (* y z))) (t_1 (* x (* z 6.0))))
(if (<= z -1.1e+242)
t_0
(if (<= z -6.5e+130)
(* 6.0 (* x z))
(if (<= z -2.1e+70)
t_0
(if (<= z -3700.0)
t_1
(if (<= z -2.6e-159)
(* x -3.0)
(if (<= z -6e-191)
(* y 4.0)
(if (<= z 6e-298)
(* x -3.0)
(if (<= z 2.4e-182)
(* y 4.0)
(if (<= z 0.55)
(* x -3.0)
(if (<= z 2.25e+222) t_0 t_1))))))))))))
double code(double x, double y, double z) {
double t_0 = -6.0 * (y * z);
double t_1 = x * (z * 6.0);
double tmp;
if (z <= -1.1e+242) {
tmp = t_0;
} else if (z <= -6.5e+130) {
tmp = 6.0 * (x * z);
} else if (z <= -2.1e+70) {
tmp = t_0;
} else if (z <= -3700.0) {
tmp = t_1;
} else if (z <= -2.6e-159) {
tmp = x * -3.0;
} else if (z <= -6e-191) {
tmp = y * 4.0;
} else if (z <= 6e-298) {
tmp = x * -3.0;
} else if (z <= 2.4e-182) {
tmp = y * 4.0;
} else if (z <= 0.55) {
tmp = x * -3.0;
} else if (z <= 2.25e+222) {
tmp = t_0;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = (-6.0d0) * (y * z)
t_1 = x * (z * 6.0d0)
if (z <= (-1.1d+242)) then
tmp = t_0
else if (z <= (-6.5d+130)) then
tmp = 6.0d0 * (x * z)
else if (z <= (-2.1d+70)) then
tmp = t_0
else if (z <= (-3700.0d0)) then
tmp = t_1
else if (z <= (-2.6d-159)) then
tmp = x * (-3.0d0)
else if (z <= (-6d-191)) then
tmp = y * 4.0d0
else if (z <= 6d-298) then
tmp = x * (-3.0d0)
else if (z <= 2.4d-182) then
tmp = y * 4.0d0
else if (z <= 0.55d0) then
tmp = x * (-3.0d0)
else if (z <= 2.25d+222) then
tmp = t_0
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = -6.0 * (y * z);
double t_1 = x * (z * 6.0);
double tmp;
if (z <= -1.1e+242) {
tmp = t_0;
} else if (z <= -6.5e+130) {
tmp = 6.0 * (x * z);
} else if (z <= -2.1e+70) {
tmp = t_0;
} else if (z <= -3700.0) {
tmp = t_1;
} else if (z <= -2.6e-159) {
tmp = x * -3.0;
} else if (z <= -6e-191) {
tmp = y * 4.0;
} else if (z <= 6e-298) {
tmp = x * -3.0;
} else if (z <= 2.4e-182) {
tmp = y * 4.0;
} else if (z <= 0.55) {
tmp = x * -3.0;
} else if (z <= 2.25e+222) {
tmp = t_0;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z): t_0 = -6.0 * (y * z) t_1 = x * (z * 6.0) tmp = 0 if z <= -1.1e+242: tmp = t_0 elif z <= -6.5e+130: tmp = 6.0 * (x * z) elif z <= -2.1e+70: tmp = t_0 elif z <= -3700.0: tmp = t_1 elif z <= -2.6e-159: tmp = x * -3.0 elif z <= -6e-191: tmp = y * 4.0 elif z <= 6e-298: tmp = x * -3.0 elif z <= 2.4e-182: tmp = y * 4.0 elif z <= 0.55: tmp = x * -3.0 elif z <= 2.25e+222: tmp = t_0 else: tmp = t_1 return tmp
function code(x, y, z) t_0 = Float64(-6.0 * Float64(y * z)) t_1 = Float64(x * Float64(z * 6.0)) tmp = 0.0 if (z <= -1.1e+242) tmp = t_0; elseif (z <= -6.5e+130) tmp = Float64(6.0 * Float64(x * z)); elseif (z <= -2.1e+70) tmp = t_0; elseif (z <= -3700.0) tmp = t_1; elseif (z <= -2.6e-159) tmp = Float64(x * -3.0); elseif (z <= -6e-191) tmp = Float64(y * 4.0); elseif (z <= 6e-298) tmp = Float64(x * -3.0); elseif (z <= 2.4e-182) tmp = Float64(y * 4.0); elseif (z <= 0.55) tmp = Float64(x * -3.0); elseif (z <= 2.25e+222) tmp = t_0; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z) t_0 = -6.0 * (y * z); t_1 = x * (z * 6.0); tmp = 0.0; if (z <= -1.1e+242) tmp = t_0; elseif (z <= -6.5e+130) tmp = 6.0 * (x * z); elseif (z <= -2.1e+70) tmp = t_0; elseif (z <= -3700.0) tmp = t_1; elseif (z <= -2.6e-159) tmp = x * -3.0; elseif (z <= -6e-191) tmp = y * 4.0; elseif (z <= 6e-298) tmp = x * -3.0; elseif (z <= 2.4e-182) tmp = y * 4.0; elseif (z <= 0.55) tmp = x * -3.0; elseif (z <= 2.25e+222) tmp = t_0; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(-6.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x * N[(z * 6.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.1e+242], t$95$0, If[LessEqual[z, -6.5e+130], N[(6.0 * N[(x * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -2.1e+70], t$95$0, If[LessEqual[z, -3700.0], t$95$1, If[LessEqual[z, -2.6e-159], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, -6e-191], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 6e-298], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 2.4e-182], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 0.55], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 2.25e+222], t$95$0, t$95$1]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := -6 \cdot \left(y \cdot z\right)\\
t_1 := x \cdot \left(z \cdot 6\right)\\
\mathbf{if}\;z \leq -1.1 \cdot 10^{+242}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -6.5 \cdot 10^{+130}:\\
\;\;\;\;6 \cdot \left(x \cdot z\right)\\
\mathbf{elif}\;z \leq -2.1 \cdot 10^{+70}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -3700:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -2.6 \cdot 10^{-159}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq -6 \cdot 10^{-191}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 6 \cdot 10^{-298}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 2.4 \cdot 10^{-182}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 0.55:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 2.25 \cdot 10^{+222}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.1e242 or -6.5e130 < z < -2.10000000000000008e70 or 0.55000000000000004 < z < 2.24999999999999994e222Initial program 99.8%
+-commutative99.8%
associate-*l*99.8%
fma-define99.8%
sub-neg99.8%
distribute-rgt-in99.8%
metadata-eval99.8%
metadata-eval99.8%
distribute-lft-neg-out99.8%
distribute-rgt-neg-in99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around inf 64.5%
Taylor expanded in z around inf 64.4%
*-commutative64.4%
Simplified64.4%
if -1.1e242 < z < -6.5e130Initial program 99.9%
metadata-eval99.9%
Simplified99.9%
Taylor expanded in x around inf 70.6%
sub-neg70.6%
distribute-rgt-in70.6%
metadata-eval70.6%
neg-mul-170.6%
associate-*r*70.6%
*-commutative70.6%
associate-+r+70.6%
metadata-eval70.6%
associate-*r*70.6%
metadata-eval70.6%
*-commutative70.6%
Simplified70.6%
Taylor expanded in z around inf 70.7%
if -2.10000000000000008e70 < z < -3700 or 2.24999999999999994e222 < z Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in x around inf 67.3%
sub-neg67.3%
distribute-rgt-in67.3%
metadata-eval67.3%
neg-mul-167.3%
associate-*r*67.3%
*-commutative67.3%
associate-+r+67.3%
metadata-eval67.3%
associate-*r*67.3%
metadata-eval67.3%
*-commutative67.3%
Simplified67.3%
Taylor expanded in z around inf 62.7%
*-commutative62.7%
associate-*l*62.8%
Simplified62.8%
if -3700 < z < -2.5999999999999998e-159 or -6.0000000000000001e-191 < z < 5.9999999999999999e-298 or 2.3999999999999998e-182 < z < 0.55000000000000004Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around inf 65.9%
sub-neg65.9%
distribute-rgt-in65.9%
metadata-eval65.9%
neg-mul-165.9%
associate-*r*65.9%
*-commutative65.9%
associate-+r+65.9%
metadata-eval65.9%
associate-*r*65.9%
metadata-eval65.9%
*-commutative65.9%
Simplified65.9%
Taylor expanded in z around 0 64.0%
*-commutative64.0%
Simplified64.0%
if -2.5999999999999998e-159 < z < -6.0000000000000001e-191 or 5.9999999999999999e-298 < z < 2.3999999999999998e-182Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 99.9%
Taylor expanded in x around 0 72.3%
Final simplification65.2%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* y (* z -6.0))) (t_1 (* x (* z 6.0))))
(if (<= z -4.7e+241)
(* -6.0 (* y z))
(if (<= z -2e+130)
(* 6.0 (* x z))
(if (<= z -2.75e+73)
t_0
(if (<= z -3700.0)
t_1
(if (<= z -3.2e-160)
(* x -3.0)
(if (<= z -1.7e-190)
(* y 4.0)
(if (<= z 7e-299)
(* x -3.0)
(if (<= z 3e-182)
(* y 4.0)
(if (<= z 0.5)
(* x -3.0)
(if (<= z 1.3e+216) t_0 t_1))))))))))))
double code(double x, double y, double z) {
double t_0 = y * (z * -6.0);
double t_1 = x * (z * 6.0);
double tmp;
if (z <= -4.7e+241) {
tmp = -6.0 * (y * z);
} else if (z <= -2e+130) {
tmp = 6.0 * (x * z);
} else if (z <= -2.75e+73) {
tmp = t_0;
} else if (z <= -3700.0) {
tmp = t_1;
} else if (z <= -3.2e-160) {
tmp = x * -3.0;
} else if (z <= -1.7e-190) {
tmp = y * 4.0;
} else if (z <= 7e-299) {
tmp = x * -3.0;
} else if (z <= 3e-182) {
tmp = y * 4.0;
} else if (z <= 0.5) {
tmp = x * -3.0;
} else if (z <= 1.3e+216) {
tmp = t_0;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = y * (z * (-6.0d0))
t_1 = x * (z * 6.0d0)
if (z <= (-4.7d+241)) then
tmp = (-6.0d0) * (y * z)
else if (z <= (-2d+130)) then
tmp = 6.0d0 * (x * z)
else if (z <= (-2.75d+73)) then
tmp = t_0
else if (z <= (-3700.0d0)) then
tmp = t_1
else if (z <= (-3.2d-160)) then
tmp = x * (-3.0d0)
else if (z <= (-1.7d-190)) then
tmp = y * 4.0d0
else if (z <= 7d-299) then
tmp = x * (-3.0d0)
else if (z <= 3d-182) then
tmp = y * 4.0d0
else if (z <= 0.5d0) then
tmp = x * (-3.0d0)
else if (z <= 1.3d+216) then
tmp = t_0
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = y * (z * -6.0);
double t_1 = x * (z * 6.0);
double tmp;
if (z <= -4.7e+241) {
tmp = -6.0 * (y * z);
} else if (z <= -2e+130) {
tmp = 6.0 * (x * z);
} else if (z <= -2.75e+73) {
tmp = t_0;
} else if (z <= -3700.0) {
tmp = t_1;
} else if (z <= -3.2e-160) {
tmp = x * -3.0;
} else if (z <= -1.7e-190) {
tmp = y * 4.0;
} else if (z <= 7e-299) {
tmp = x * -3.0;
} else if (z <= 3e-182) {
tmp = y * 4.0;
} else if (z <= 0.5) {
tmp = x * -3.0;
} else if (z <= 1.3e+216) {
tmp = t_0;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z): t_0 = y * (z * -6.0) t_1 = x * (z * 6.0) tmp = 0 if z <= -4.7e+241: tmp = -6.0 * (y * z) elif z <= -2e+130: tmp = 6.0 * (x * z) elif z <= -2.75e+73: tmp = t_0 elif z <= -3700.0: tmp = t_1 elif z <= -3.2e-160: tmp = x * -3.0 elif z <= -1.7e-190: tmp = y * 4.0 elif z <= 7e-299: tmp = x * -3.0 elif z <= 3e-182: tmp = y * 4.0 elif z <= 0.5: tmp = x * -3.0 elif z <= 1.3e+216: tmp = t_0 else: tmp = t_1 return tmp
function code(x, y, z) t_0 = Float64(y * Float64(z * -6.0)) t_1 = Float64(x * Float64(z * 6.0)) tmp = 0.0 if (z <= -4.7e+241) tmp = Float64(-6.0 * Float64(y * z)); elseif (z <= -2e+130) tmp = Float64(6.0 * Float64(x * z)); elseif (z <= -2.75e+73) tmp = t_0; elseif (z <= -3700.0) tmp = t_1; elseif (z <= -3.2e-160) tmp = Float64(x * -3.0); elseif (z <= -1.7e-190) tmp = Float64(y * 4.0); elseif (z <= 7e-299) tmp = Float64(x * -3.0); elseif (z <= 3e-182) tmp = Float64(y * 4.0); elseif (z <= 0.5) tmp = Float64(x * -3.0); elseif (z <= 1.3e+216) tmp = t_0; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z) t_0 = y * (z * -6.0); t_1 = x * (z * 6.0); tmp = 0.0; if (z <= -4.7e+241) tmp = -6.0 * (y * z); elseif (z <= -2e+130) tmp = 6.0 * (x * z); elseif (z <= -2.75e+73) tmp = t_0; elseif (z <= -3700.0) tmp = t_1; elseif (z <= -3.2e-160) tmp = x * -3.0; elseif (z <= -1.7e-190) tmp = y * 4.0; elseif (z <= 7e-299) tmp = x * -3.0; elseif (z <= 3e-182) tmp = y * 4.0; elseif (z <= 0.5) tmp = x * -3.0; elseif (z <= 1.3e+216) tmp = t_0; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(y * N[(z * -6.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x * N[(z * 6.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -4.7e+241], N[(-6.0 * N[(y * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -2e+130], N[(6.0 * N[(x * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -2.75e+73], t$95$0, If[LessEqual[z, -3700.0], t$95$1, If[LessEqual[z, -3.2e-160], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, -1.7e-190], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 7e-299], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 3e-182], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 0.5], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 1.3e+216], t$95$0, t$95$1]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := y \cdot \left(z \cdot -6\right)\\
t_1 := x \cdot \left(z \cdot 6\right)\\
\mathbf{if}\;z \leq -4.7 \cdot 10^{+241}:\\
\;\;\;\;-6 \cdot \left(y \cdot z\right)\\
\mathbf{elif}\;z \leq -2 \cdot 10^{+130}:\\
\;\;\;\;6 \cdot \left(x \cdot z\right)\\
\mathbf{elif}\;z \leq -2.75 \cdot 10^{+73}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -3700:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -3.2 \cdot 10^{-160}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq -1.7 \cdot 10^{-190}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 7 \cdot 10^{-299}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 3 \cdot 10^{-182}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 0.5:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 1.3 \cdot 10^{+216}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -4.69999999999999982e241Initial program 99.8%
+-commutative99.8%
associate-*l*99.9%
fma-define99.9%
sub-neg99.9%
distribute-rgt-in99.9%
metadata-eval99.9%
metadata-eval99.9%
distribute-lft-neg-out99.9%
distribute-rgt-neg-in99.9%
metadata-eval99.9%
Simplified99.9%
Taylor expanded in y around inf 74.2%
Taylor expanded in z around inf 74.2%
*-commutative74.2%
Simplified74.2%
if -4.69999999999999982e241 < z < -2.0000000000000001e130Initial program 99.9%
metadata-eval99.9%
Simplified99.9%
Taylor expanded in x around inf 70.6%
sub-neg70.6%
distribute-rgt-in70.6%
metadata-eval70.6%
neg-mul-170.6%
associate-*r*70.6%
*-commutative70.6%
associate-+r+70.6%
metadata-eval70.6%
associate-*r*70.6%
metadata-eval70.6%
*-commutative70.6%
Simplified70.6%
Taylor expanded in z around inf 70.7%
if -2.0000000000000001e130 < z < -2.7500000000000001e73 or 0.5 < z < 1.2999999999999999e216Initial program 99.8%
+-commutative99.8%
associate-*l*99.8%
fma-define99.8%
sub-neg99.8%
distribute-rgt-in99.8%
metadata-eval99.8%
metadata-eval99.8%
distribute-lft-neg-out99.8%
distribute-rgt-neg-in99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around inf 61.8%
Taylor expanded in z around inf 61.8%
*-commutative61.8%
Simplified61.8%
if -2.7500000000000001e73 < z < -3700 or 1.2999999999999999e216 < z Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in x around inf 66.4%
sub-neg66.4%
distribute-rgt-in66.4%
metadata-eval66.4%
neg-mul-166.4%
associate-*r*66.4%
*-commutative66.4%
associate-+r+66.4%
metadata-eval66.4%
associate-*r*66.4%
metadata-eval66.4%
*-commutative66.4%
Simplified66.4%
Taylor expanded in z around inf 62.0%
*-commutative62.0%
associate-*l*62.1%
Simplified62.1%
if -3700 < z < -3.20000000000000009e-160 or -1.69999999999999991e-190 < z < 6.99999999999999981e-299 or 3.0000000000000001e-182 < z < 0.5Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around inf 65.9%
sub-neg65.9%
distribute-rgt-in65.9%
metadata-eval65.9%
neg-mul-165.9%
associate-*r*65.9%
*-commutative65.9%
associate-+r+65.9%
metadata-eval65.9%
associate-*r*65.9%
metadata-eval65.9%
*-commutative65.9%
Simplified65.9%
Taylor expanded in z around 0 64.0%
*-commutative64.0%
Simplified64.0%
if -3.20000000000000009e-160 < z < -1.69999999999999991e-190 or 6.99999999999999981e-299 < z < 3.0000000000000001e-182Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 99.9%
Taylor expanded in x around 0 72.3%
Final simplification65.3%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* x (* z 6.0))))
(if (<= z -2.1e+242)
(* -6.0 (* y z))
(if (<= z -1.65e+130)
(* 6.0 (* x z))
(if (<= z -5.8e+76)
(* y (* z -6.0))
(if (<= z -3700.0)
t_0
(if (<= z -2.8e-159)
(* x -3.0)
(if (<= z -8.6e-191)
(* y 4.0)
(if (<= z 2.85e-297)
(* x -3.0)
(if (<= z 8.8e-182)
(* y 4.0)
(if (<= z 0.66)
(* x -3.0)
(if (<= z 2.4e+222) (* z (* y -6.0)) t_0))))))))))))
double code(double x, double y, double z) {
double t_0 = x * (z * 6.0);
double tmp;
if (z <= -2.1e+242) {
tmp = -6.0 * (y * z);
} else if (z <= -1.65e+130) {
tmp = 6.0 * (x * z);
} else if (z <= -5.8e+76) {
tmp = y * (z * -6.0);
} else if (z <= -3700.0) {
tmp = t_0;
} else if (z <= -2.8e-159) {
tmp = x * -3.0;
} else if (z <= -8.6e-191) {
tmp = y * 4.0;
} else if (z <= 2.85e-297) {
tmp = x * -3.0;
} else if (z <= 8.8e-182) {
tmp = y * 4.0;
} else if (z <= 0.66) {
tmp = x * -3.0;
} else if (z <= 2.4e+222) {
tmp = z * (y * -6.0);
} else {
tmp = t_0;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: tmp
t_0 = x * (z * 6.0d0)
if (z <= (-2.1d+242)) then
tmp = (-6.0d0) * (y * z)
else if (z <= (-1.65d+130)) then
tmp = 6.0d0 * (x * z)
else if (z <= (-5.8d+76)) then
tmp = y * (z * (-6.0d0))
else if (z <= (-3700.0d0)) then
tmp = t_0
else if (z <= (-2.8d-159)) then
tmp = x * (-3.0d0)
else if (z <= (-8.6d-191)) then
tmp = y * 4.0d0
else if (z <= 2.85d-297) then
tmp = x * (-3.0d0)
else if (z <= 8.8d-182) then
tmp = y * 4.0d0
else if (z <= 0.66d0) then
tmp = x * (-3.0d0)
else if (z <= 2.4d+222) then
tmp = z * (y * (-6.0d0))
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = x * (z * 6.0);
double tmp;
if (z <= -2.1e+242) {
tmp = -6.0 * (y * z);
} else if (z <= -1.65e+130) {
tmp = 6.0 * (x * z);
} else if (z <= -5.8e+76) {
tmp = y * (z * -6.0);
} else if (z <= -3700.0) {
tmp = t_0;
} else if (z <= -2.8e-159) {
tmp = x * -3.0;
} else if (z <= -8.6e-191) {
tmp = y * 4.0;
} else if (z <= 2.85e-297) {
tmp = x * -3.0;
} else if (z <= 8.8e-182) {
tmp = y * 4.0;
} else if (z <= 0.66) {
tmp = x * -3.0;
} else if (z <= 2.4e+222) {
tmp = z * (y * -6.0);
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = x * (z * 6.0) tmp = 0 if z <= -2.1e+242: tmp = -6.0 * (y * z) elif z <= -1.65e+130: tmp = 6.0 * (x * z) elif z <= -5.8e+76: tmp = y * (z * -6.0) elif z <= -3700.0: tmp = t_0 elif z <= -2.8e-159: tmp = x * -3.0 elif z <= -8.6e-191: tmp = y * 4.0 elif z <= 2.85e-297: tmp = x * -3.0 elif z <= 8.8e-182: tmp = y * 4.0 elif z <= 0.66: tmp = x * -3.0 elif z <= 2.4e+222: tmp = z * (y * -6.0) else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(x * Float64(z * 6.0)) tmp = 0.0 if (z <= -2.1e+242) tmp = Float64(-6.0 * Float64(y * z)); elseif (z <= -1.65e+130) tmp = Float64(6.0 * Float64(x * z)); elseif (z <= -5.8e+76) tmp = Float64(y * Float64(z * -6.0)); elseif (z <= -3700.0) tmp = t_0; elseif (z <= -2.8e-159) tmp = Float64(x * -3.0); elseif (z <= -8.6e-191) tmp = Float64(y * 4.0); elseif (z <= 2.85e-297) tmp = Float64(x * -3.0); elseif (z <= 8.8e-182) tmp = Float64(y * 4.0); elseif (z <= 0.66) tmp = Float64(x * -3.0); elseif (z <= 2.4e+222) tmp = Float64(z * Float64(y * -6.0)); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = x * (z * 6.0); tmp = 0.0; if (z <= -2.1e+242) tmp = -6.0 * (y * z); elseif (z <= -1.65e+130) tmp = 6.0 * (x * z); elseif (z <= -5.8e+76) tmp = y * (z * -6.0); elseif (z <= -3700.0) tmp = t_0; elseif (z <= -2.8e-159) tmp = x * -3.0; elseif (z <= -8.6e-191) tmp = y * 4.0; elseif (z <= 2.85e-297) tmp = x * -3.0; elseif (z <= 8.8e-182) tmp = y * 4.0; elseif (z <= 0.66) tmp = x * -3.0; elseif (z <= 2.4e+222) tmp = z * (y * -6.0); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(x * N[(z * 6.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.1e+242], N[(-6.0 * N[(y * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.65e+130], N[(6.0 * N[(x * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -5.8e+76], N[(y * N[(z * -6.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -3700.0], t$95$0, If[LessEqual[z, -2.8e-159], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, -8.6e-191], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 2.85e-297], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 8.8e-182], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 0.66], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 2.4e+222], N[(z * N[(y * -6.0), $MachinePrecision]), $MachinePrecision], t$95$0]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(z \cdot 6\right)\\
\mathbf{if}\;z \leq -2.1 \cdot 10^{+242}:\\
\;\;\;\;-6 \cdot \left(y \cdot z\right)\\
\mathbf{elif}\;z \leq -1.65 \cdot 10^{+130}:\\
\;\;\;\;6 \cdot \left(x \cdot z\right)\\
\mathbf{elif}\;z \leq -5.8 \cdot 10^{+76}:\\
\;\;\;\;y \cdot \left(z \cdot -6\right)\\
\mathbf{elif}\;z \leq -3700:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -2.8 \cdot 10^{-159}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq -8.6 \cdot 10^{-191}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 2.85 \cdot 10^{-297}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 8.8 \cdot 10^{-182}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 0.66:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 2.4 \cdot 10^{+222}:\\
\;\;\;\;z \cdot \left(y \cdot -6\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if z < -2.0999999999999999e242Initial program 99.8%
+-commutative99.8%
associate-*l*99.9%
fma-define99.9%
sub-neg99.9%
distribute-rgt-in99.9%
metadata-eval99.9%
metadata-eval99.9%
distribute-lft-neg-out99.9%
distribute-rgt-neg-in99.9%
metadata-eval99.9%
Simplified99.9%
Taylor expanded in y around inf 74.2%
Taylor expanded in z around inf 74.2%
*-commutative74.2%
Simplified74.2%
if -2.0999999999999999e242 < z < -1.65e130Initial program 99.9%
metadata-eval99.9%
Simplified99.9%
Taylor expanded in x around inf 70.6%
sub-neg70.6%
distribute-rgt-in70.6%
metadata-eval70.6%
neg-mul-170.6%
associate-*r*70.6%
*-commutative70.6%
associate-+r+70.6%
metadata-eval70.6%
associate-*r*70.6%
metadata-eval70.6%
*-commutative70.6%
Simplified70.6%
Taylor expanded in z around inf 70.7%
if -1.65e130 < z < -5.8000000000000003e76Initial program 99.8%
+-commutative99.8%
associate-*l*99.8%
fma-define99.8%
sub-neg99.8%
distribute-rgt-in99.8%
metadata-eval99.8%
metadata-eval99.8%
distribute-lft-neg-out99.8%
distribute-rgt-neg-in99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around inf 68.0%
Taylor expanded in z around inf 68.0%
*-commutative68.0%
Simplified68.0%
if -5.8000000000000003e76 < z < -3700 or 2.4000000000000001e222 < z Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in x around inf 66.4%
sub-neg66.4%
distribute-rgt-in66.4%
metadata-eval66.4%
neg-mul-166.4%
associate-*r*66.4%
*-commutative66.4%
associate-+r+66.4%
metadata-eval66.4%
associate-*r*66.4%
metadata-eval66.4%
*-commutative66.4%
Simplified66.4%
Taylor expanded in z around inf 62.0%
*-commutative62.0%
associate-*l*62.1%
Simplified62.1%
if -3700 < z < -2.8000000000000002e-159 or -8.59999999999999966e-191 < z < 2.8499999999999999e-297 or 8.7999999999999999e-182 < z < 0.660000000000000031Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around inf 65.9%
sub-neg65.9%
distribute-rgt-in65.9%
metadata-eval65.9%
neg-mul-165.9%
associate-*r*65.9%
*-commutative65.9%
associate-+r+65.9%
metadata-eval65.9%
associate-*r*65.9%
metadata-eval65.9%
*-commutative65.9%
Simplified65.9%
Taylor expanded in z around 0 64.0%
*-commutative64.0%
Simplified64.0%
if -2.8000000000000002e-159 < z < -8.59999999999999966e-191 or 2.8499999999999999e-297 < z < 8.7999999999999999e-182Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 99.9%
Taylor expanded in x around 0 72.3%
if 0.660000000000000031 < z < 2.4000000000000001e222Initial program 99.8%
+-commutative99.8%
associate-*l*99.9%
fma-define99.9%
sub-neg99.9%
distribute-rgt-in99.9%
metadata-eval99.9%
metadata-eval99.9%
distribute-lft-neg-out99.9%
distribute-rgt-neg-in99.9%
metadata-eval99.9%
Simplified99.9%
Taylor expanded in y around inf 60.0%
Taylor expanded in z around inf 59.9%
associate-*r*60.1%
*-commutative60.1%
Simplified60.1%
Final simplification65.3%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* x (* z 6.0))))
(if (<= z -2.5e+242)
(* -6.0 (* y z))
(if (<= z -5.6e+130)
(* z (* x 6.0))
(if (<= z -3.6e+75)
(* y (* z -6.0))
(if (<= z -3700.0)
t_0
(if (<= z -1.6e-160)
(* x -3.0)
(if (<= z -7e-191)
(* y 4.0)
(if (<= z 3.2e-299)
(* x -3.0)
(if (<= z 1.22e-182)
(* y 4.0)
(if (<= z 0.66)
(* x -3.0)
(if (<= z 3.8e+215) (* z (* y -6.0)) t_0))))))))))))
double code(double x, double y, double z) {
double t_0 = x * (z * 6.0);
double tmp;
if (z <= -2.5e+242) {
tmp = -6.0 * (y * z);
} else if (z <= -5.6e+130) {
tmp = z * (x * 6.0);
} else if (z <= -3.6e+75) {
tmp = y * (z * -6.0);
} else if (z <= -3700.0) {
tmp = t_0;
} else if (z <= -1.6e-160) {
tmp = x * -3.0;
} else if (z <= -7e-191) {
tmp = y * 4.0;
} else if (z <= 3.2e-299) {
tmp = x * -3.0;
} else if (z <= 1.22e-182) {
tmp = y * 4.0;
} else if (z <= 0.66) {
tmp = x * -3.0;
} else if (z <= 3.8e+215) {
tmp = z * (y * -6.0);
} else {
tmp = t_0;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: tmp
t_0 = x * (z * 6.0d0)
if (z <= (-2.5d+242)) then
tmp = (-6.0d0) * (y * z)
else if (z <= (-5.6d+130)) then
tmp = z * (x * 6.0d0)
else if (z <= (-3.6d+75)) then
tmp = y * (z * (-6.0d0))
else if (z <= (-3700.0d0)) then
tmp = t_0
else if (z <= (-1.6d-160)) then
tmp = x * (-3.0d0)
else if (z <= (-7d-191)) then
tmp = y * 4.0d0
else if (z <= 3.2d-299) then
tmp = x * (-3.0d0)
else if (z <= 1.22d-182) then
tmp = y * 4.0d0
else if (z <= 0.66d0) then
tmp = x * (-3.0d0)
else if (z <= 3.8d+215) then
tmp = z * (y * (-6.0d0))
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = x * (z * 6.0);
double tmp;
if (z <= -2.5e+242) {
tmp = -6.0 * (y * z);
} else if (z <= -5.6e+130) {
tmp = z * (x * 6.0);
} else if (z <= -3.6e+75) {
tmp = y * (z * -6.0);
} else if (z <= -3700.0) {
tmp = t_0;
} else if (z <= -1.6e-160) {
tmp = x * -3.0;
} else if (z <= -7e-191) {
tmp = y * 4.0;
} else if (z <= 3.2e-299) {
tmp = x * -3.0;
} else if (z <= 1.22e-182) {
tmp = y * 4.0;
} else if (z <= 0.66) {
tmp = x * -3.0;
} else if (z <= 3.8e+215) {
tmp = z * (y * -6.0);
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = x * (z * 6.0) tmp = 0 if z <= -2.5e+242: tmp = -6.0 * (y * z) elif z <= -5.6e+130: tmp = z * (x * 6.0) elif z <= -3.6e+75: tmp = y * (z * -6.0) elif z <= -3700.0: tmp = t_0 elif z <= -1.6e-160: tmp = x * -3.0 elif z <= -7e-191: tmp = y * 4.0 elif z <= 3.2e-299: tmp = x * -3.0 elif z <= 1.22e-182: tmp = y * 4.0 elif z <= 0.66: tmp = x * -3.0 elif z <= 3.8e+215: tmp = z * (y * -6.0) else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(x * Float64(z * 6.0)) tmp = 0.0 if (z <= -2.5e+242) tmp = Float64(-6.0 * Float64(y * z)); elseif (z <= -5.6e+130) tmp = Float64(z * Float64(x * 6.0)); elseif (z <= -3.6e+75) tmp = Float64(y * Float64(z * -6.0)); elseif (z <= -3700.0) tmp = t_0; elseif (z <= -1.6e-160) tmp = Float64(x * -3.0); elseif (z <= -7e-191) tmp = Float64(y * 4.0); elseif (z <= 3.2e-299) tmp = Float64(x * -3.0); elseif (z <= 1.22e-182) tmp = Float64(y * 4.0); elseif (z <= 0.66) tmp = Float64(x * -3.0); elseif (z <= 3.8e+215) tmp = Float64(z * Float64(y * -6.0)); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = x * (z * 6.0); tmp = 0.0; if (z <= -2.5e+242) tmp = -6.0 * (y * z); elseif (z <= -5.6e+130) tmp = z * (x * 6.0); elseif (z <= -3.6e+75) tmp = y * (z * -6.0); elseif (z <= -3700.0) tmp = t_0; elseif (z <= -1.6e-160) tmp = x * -3.0; elseif (z <= -7e-191) tmp = y * 4.0; elseif (z <= 3.2e-299) tmp = x * -3.0; elseif (z <= 1.22e-182) tmp = y * 4.0; elseif (z <= 0.66) tmp = x * -3.0; elseif (z <= 3.8e+215) tmp = z * (y * -6.0); else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(x * N[(z * 6.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -2.5e+242], N[(-6.0 * N[(y * z), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -5.6e+130], N[(z * N[(x * 6.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -3.6e+75], N[(y * N[(z * -6.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -3700.0], t$95$0, If[LessEqual[z, -1.6e-160], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, -7e-191], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 3.2e-299], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 1.22e-182], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 0.66], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 3.8e+215], N[(z * N[(y * -6.0), $MachinePrecision]), $MachinePrecision], t$95$0]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(z \cdot 6\right)\\
\mathbf{if}\;z \leq -2.5 \cdot 10^{+242}:\\
\;\;\;\;-6 \cdot \left(y \cdot z\right)\\
\mathbf{elif}\;z \leq -5.6 \cdot 10^{+130}:\\
\;\;\;\;z \cdot \left(x \cdot 6\right)\\
\mathbf{elif}\;z \leq -3.6 \cdot 10^{+75}:\\
\;\;\;\;y \cdot \left(z \cdot -6\right)\\
\mathbf{elif}\;z \leq -3700:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -1.6 \cdot 10^{-160}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq -7 \cdot 10^{-191}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 3.2 \cdot 10^{-299}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 1.22 \cdot 10^{-182}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 0.66:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 3.8 \cdot 10^{+215}:\\
\;\;\;\;z \cdot \left(y \cdot -6\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if z < -2.5000000000000002e242Initial program 99.8%
+-commutative99.8%
associate-*l*99.9%
fma-define99.9%
sub-neg99.9%
distribute-rgt-in99.9%
metadata-eval99.9%
metadata-eval99.9%
distribute-lft-neg-out99.9%
distribute-rgt-neg-in99.9%
metadata-eval99.9%
Simplified99.9%
Taylor expanded in y around inf 74.2%
Taylor expanded in z around inf 74.2%
*-commutative74.2%
Simplified74.2%
if -2.5000000000000002e242 < z < -5.5999999999999997e130Initial program 99.9%
metadata-eval99.9%
Simplified99.9%
Taylor expanded in x around inf 70.6%
sub-neg70.6%
distribute-rgt-in70.6%
metadata-eval70.6%
neg-mul-170.6%
associate-*r*70.6%
*-commutative70.6%
associate-+r+70.6%
metadata-eval70.6%
associate-*r*70.6%
metadata-eval70.6%
*-commutative70.6%
Simplified70.6%
Taylor expanded in z around inf 70.7%
associate-*r*70.7%
*-commutative70.7%
*-commutative70.7%
Simplified70.7%
if -5.5999999999999997e130 < z < -3.6e75Initial program 99.8%
+-commutative99.8%
associate-*l*99.8%
fma-define99.8%
sub-neg99.8%
distribute-rgt-in99.8%
metadata-eval99.8%
metadata-eval99.8%
distribute-lft-neg-out99.8%
distribute-rgt-neg-in99.8%
metadata-eval99.8%
Simplified99.8%
Taylor expanded in y around inf 68.0%
Taylor expanded in z around inf 68.0%
*-commutative68.0%
Simplified68.0%
if -3.6e75 < z < -3700 or 3.79999999999999968e215 < z Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in x around inf 66.4%
sub-neg66.4%
distribute-rgt-in66.4%
metadata-eval66.4%
neg-mul-166.4%
associate-*r*66.4%
*-commutative66.4%
associate-+r+66.4%
metadata-eval66.4%
associate-*r*66.4%
metadata-eval66.4%
*-commutative66.4%
Simplified66.4%
Taylor expanded in z around inf 62.0%
*-commutative62.0%
associate-*l*62.1%
Simplified62.1%
if -3700 < z < -1.60000000000000004e-160 or -7.00000000000000013e-191 < z < 3.20000000000000008e-299 or 1.22e-182 < z < 0.660000000000000031Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around inf 65.9%
sub-neg65.9%
distribute-rgt-in65.9%
metadata-eval65.9%
neg-mul-165.9%
associate-*r*65.9%
*-commutative65.9%
associate-+r+65.9%
metadata-eval65.9%
associate-*r*65.9%
metadata-eval65.9%
*-commutative65.9%
Simplified65.9%
Taylor expanded in z around 0 64.0%
*-commutative64.0%
Simplified64.0%
if -1.60000000000000004e-160 < z < -7.00000000000000013e-191 or 3.20000000000000008e-299 < z < 1.22e-182Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 99.9%
Taylor expanded in x around 0 72.3%
if 0.660000000000000031 < z < 3.79999999999999968e215Initial program 99.8%
+-commutative99.8%
associate-*l*99.9%
fma-define99.9%
sub-neg99.9%
distribute-rgt-in99.9%
metadata-eval99.9%
metadata-eval99.9%
distribute-lft-neg-out99.9%
distribute-rgt-neg-in99.9%
metadata-eval99.9%
Simplified99.9%
Taylor expanded in y around inf 60.0%
Taylor expanded in z around inf 59.9%
associate-*r*60.1%
*-commutative60.1%
Simplified60.1%
Final simplification65.3%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* -6.0 (* (- y x) z))))
(if (<= z -0.018)
t_0
(if (<= z -5e-160)
(* x -3.0)
(if (<= z -3.45e-192)
(* y 4.0)
(if (<= z 7.2e-298)
(* x -3.0)
(if (<= z 1.5e-182) (* y 4.0) (if (<= z 0.5) (* x -3.0) t_0))))))))
double code(double x, double y, double z) {
double t_0 = -6.0 * ((y - x) * z);
double tmp;
if (z <= -0.018) {
tmp = t_0;
} else if (z <= -5e-160) {
tmp = x * -3.0;
} else if (z <= -3.45e-192) {
tmp = y * 4.0;
} else if (z <= 7.2e-298) {
tmp = x * -3.0;
} else if (z <= 1.5e-182) {
tmp = y * 4.0;
} else if (z <= 0.5) {
tmp = x * -3.0;
} else {
tmp = t_0;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: tmp
t_0 = (-6.0d0) * ((y - x) * z)
if (z <= (-0.018d0)) then
tmp = t_0
else if (z <= (-5d-160)) then
tmp = x * (-3.0d0)
else if (z <= (-3.45d-192)) then
tmp = y * 4.0d0
else if (z <= 7.2d-298) then
tmp = x * (-3.0d0)
else if (z <= 1.5d-182) then
tmp = y * 4.0d0
else if (z <= 0.5d0) then
tmp = x * (-3.0d0)
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = -6.0 * ((y - x) * z);
double tmp;
if (z <= -0.018) {
tmp = t_0;
} else if (z <= -5e-160) {
tmp = x * -3.0;
} else if (z <= -3.45e-192) {
tmp = y * 4.0;
} else if (z <= 7.2e-298) {
tmp = x * -3.0;
} else if (z <= 1.5e-182) {
tmp = y * 4.0;
} else if (z <= 0.5) {
tmp = x * -3.0;
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = -6.0 * ((y - x) * z) tmp = 0 if z <= -0.018: tmp = t_0 elif z <= -5e-160: tmp = x * -3.0 elif z <= -3.45e-192: tmp = y * 4.0 elif z <= 7.2e-298: tmp = x * -3.0 elif z <= 1.5e-182: tmp = y * 4.0 elif z <= 0.5: tmp = x * -3.0 else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(-6.0 * Float64(Float64(y - x) * z)) tmp = 0.0 if (z <= -0.018) tmp = t_0; elseif (z <= -5e-160) tmp = Float64(x * -3.0); elseif (z <= -3.45e-192) tmp = Float64(y * 4.0); elseif (z <= 7.2e-298) tmp = Float64(x * -3.0); elseif (z <= 1.5e-182) tmp = Float64(y * 4.0); elseif (z <= 0.5) tmp = Float64(x * -3.0); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = -6.0 * ((y - x) * z); tmp = 0.0; if (z <= -0.018) tmp = t_0; elseif (z <= -5e-160) tmp = x * -3.0; elseif (z <= -3.45e-192) tmp = y * 4.0; elseif (z <= 7.2e-298) tmp = x * -3.0; elseif (z <= 1.5e-182) tmp = y * 4.0; elseif (z <= 0.5) tmp = x * -3.0; else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(-6.0 * N[(N[(y - x), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -0.018], t$95$0, If[LessEqual[z, -5e-160], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, -3.45e-192], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 7.2e-298], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 1.5e-182], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 0.5], N[(x * -3.0), $MachinePrecision], t$95$0]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := -6 \cdot \left(\left(y - x\right) \cdot z\right)\\
\mathbf{if}\;z \leq -0.018:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -5 \cdot 10^{-160}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq -3.45 \cdot 10^{-192}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 7.2 \cdot 10^{-298}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 1.5 \cdot 10^{-182}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 0.5:\\
\;\;\;\;x \cdot -3\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if z < -0.0179999999999999986 or 0.5 < z Initial program 99.8%
metadata-eval99.8%
Simplified99.8%
+-commutative99.8%
*-commutative99.8%
associate-*r*99.7%
fma-define99.7%
Applied egg-rr99.7%
Taylor expanded in z around inf 97.1%
if -0.0179999999999999986 < z < -4.99999999999999994e-160 or -3.45000000000000008e-192 < z < 7.20000000000000005e-298 or 1.5000000000000001e-182 < z < 0.5Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around inf 67.3%
sub-neg67.3%
distribute-rgt-in67.3%
metadata-eval67.3%
neg-mul-167.3%
associate-*r*67.3%
*-commutative67.3%
associate-+r+67.3%
metadata-eval67.3%
associate-*r*67.3%
metadata-eval67.3%
*-commutative67.3%
Simplified67.3%
Taylor expanded in z around 0 65.4%
*-commutative65.4%
Simplified65.4%
if -4.99999999999999994e-160 < z < -3.45000000000000008e-192 or 7.20000000000000005e-298 < z < 1.5000000000000001e-182Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 99.9%
Taylor expanded in x around 0 72.3%
Final simplification83.6%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* x (+ -3.0 (* z 6.0)))) (t_1 (* -6.0 (* (- y x) z))))
(if (<= z -1150000000000.0)
t_1
(if (<= z -4.6e-160)
t_0
(if (<= z -7.5e-192)
(* y 4.0)
(if (<= z 3e-299)
(* x -3.0)
(if (<= z 1.2e-182) (* y 4.0) (if (<= z 2.4e+16) t_0 t_1))))))))
double code(double x, double y, double z) {
double t_0 = x * (-3.0 + (z * 6.0));
double t_1 = -6.0 * ((y - x) * z);
double tmp;
if (z <= -1150000000000.0) {
tmp = t_1;
} else if (z <= -4.6e-160) {
tmp = t_0;
} else if (z <= -7.5e-192) {
tmp = y * 4.0;
} else if (z <= 3e-299) {
tmp = x * -3.0;
} else if (z <= 1.2e-182) {
tmp = y * 4.0;
} else if (z <= 2.4e+16) {
tmp = t_0;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = x * ((-3.0d0) + (z * 6.0d0))
t_1 = (-6.0d0) * ((y - x) * z)
if (z <= (-1150000000000.0d0)) then
tmp = t_1
else if (z <= (-4.6d-160)) then
tmp = t_0
else if (z <= (-7.5d-192)) then
tmp = y * 4.0d0
else if (z <= 3d-299) then
tmp = x * (-3.0d0)
else if (z <= 1.2d-182) then
tmp = y * 4.0d0
else if (z <= 2.4d+16) then
tmp = t_0
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = x * (-3.0 + (z * 6.0));
double t_1 = -6.0 * ((y - x) * z);
double tmp;
if (z <= -1150000000000.0) {
tmp = t_1;
} else if (z <= -4.6e-160) {
tmp = t_0;
} else if (z <= -7.5e-192) {
tmp = y * 4.0;
} else if (z <= 3e-299) {
tmp = x * -3.0;
} else if (z <= 1.2e-182) {
tmp = y * 4.0;
} else if (z <= 2.4e+16) {
tmp = t_0;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z): t_0 = x * (-3.0 + (z * 6.0)) t_1 = -6.0 * ((y - x) * z) tmp = 0 if z <= -1150000000000.0: tmp = t_1 elif z <= -4.6e-160: tmp = t_0 elif z <= -7.5e-192: tmp = y * 4.0 elif z <= 3e-299: tmp = x * -3.0 elif z <= 1.2e-182: tmp = y * 4.0 elif z <= 2.4e+16: tmp = t_0 else: tmp = t_1 return tmp
function code(x, y, z) t_0 = Float64(x * Float64(-3.0 + Float64(z * 6.0))) t_1 = Float64(-6.0 * Float64(Float64(y - x) * z)) tmp = 0.0 if (z <= -1150000000000.0) tmp = t_1; elseif (z <= -4.6e-160) tmp = t_0; elseif (z <= -7.5e-192) tmp = Float64(y * 4.0); elseif (z <= 3e-299) tmp = Float64(x * -3.0); elseif (z <= 1.2e-182) tmp = Float64(y * 4.0); elseif (z <= 2.4e+16) tmp = t_0; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z) t_0 = x * (-3.0 + (z * 6.0)); t_1 = -6.0 * ((y - x) * z); tmp = 0.0; if (z <= -1150000000000.0) tmp = t_1; elseif (z <= -4.6e-160) tmp = t_0; elseif (z <= -7.5e-192) tmp = y * 4.0; elseif (z <= 3e-299) tmp = x * -3.0; elseif (z <= 1.2e-182) tmp = y * 4.0; elseif (z <= 2.4e+16) tmp = t_0; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(x * N[(-3.0 + N[(z * 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(-6.0 * N[(N[(y - x), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1150000000000.0], t$95$1, If[LessEqual[z, -4.6e-160], t$95$0, If[LessEqual[z, -7.5e-192], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 3e-299], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 1.2e-182], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 2.4e+16], t$95$0, t$95$1]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(-3 + z \cdot 6\right)\\
t_1 := -6 \cdot \left(\left(y - x\right) \cdot z\right)\\
\mathbf{if}\;z \leq -1150000000000:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -4.6 \cdot 10^{-160}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -7.5 \cdot 10^{-192}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 3 \cdot 10^{-299}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 1.2 \cdot 10^{-182}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 2.4 \cdot 10^{+16}:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.15e12 or 2.4e16 < z Initial program 99.8%
metadata-eval99.8%
Simplified99.8%
+-commutative99.8%
*-commutative99.8%
associate-*r*99.7%
fma-define99.7%
Applied egg-rr99.7%
Taylor expanded in z around inf 99.6%
if -1.15e12 < z < -4.5999999999999997e-160 or 1.1999999999999999e-182 < z < 2.4e16Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in x around inf 68.0%
sub-neg68.0%
distribute-rgt-in68.0%
metadata-eval68.0%
neg-mul-168.0%
associate-*r*68.0%
*-commutative68.0%
associate-+r+68.0%
metadata-eval68.0%
associate-*r*68.0%
metadata-eval68.0%
*-commutative68.0%
Simplified68.0%
if -4.5999999999999997e-160 < z < -7.5000000000000001e-192 or 2.99999999999999984e-299 < z < 1.1999999999999999e-182Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 99.9%
Taylor expanded in x around 0 72.3%
if -7.5000000000000001e-192 < z < 2.99999999999999984e-299Initial program 99.6%
metadata-eval99.6%
Simplified99.6%
Taylor expanded in x around inf 64.3%
sub-neg64.3%
distribute-rgt-in64.3%
metadata-eval64.3%
neg-mul-164.3%
associate-*r*64.3%
*-commutative64.3%
associate-+r+64.3%
metadata-eval64.3%
associate-*r*64.3%
metadata-eval64.3%
*-commutative64.3%
Simplified64.3%
Taylor expanded in z around 0 64.3%
*-commutative64.3%
Simplified64.3%
Final simplification84.5%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* x (+ -3.0 (* z 6.0)))) (t_1 (* (- y x) (* z -6.0))))
(if (<= z -1150000000000.0)
t_1
(if (<= z -2.9e-158)
t_0
(if (<= z -4.6e-190)
(* y 4.0)
(if (<= z 2e-298)
(* x -3.0)
(if (<= z 1.2e-182) (* y 4.0) (if (<= z 2600000.0) t_0 t_1))))))))
double code(double x, double y, double z) {
double t_0 = x * (-3.0 + (z * 6.0));
double t_1 = (y - x) * (z * -6.0);
double tmp;
if (z <= -1150000000000.0) {
tmp = t_1;
} else if (z <= -2.9e-158) {
tmp = t_0;
} else if (z <= -4.6e-190) {
tmp = y * 4.0;
} else if (z <= 2e-298) {
tmp = x * -3.0;
} else if (z <= 1.2e-182) {
tmp = y * 4.0;
} else if (z <= 2600000.0) {
tmp = t_0;
} else {
tmp = t_1;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = x * ((-3.0d0) + (z * 6.0d0))
t_1 = (y - x) * (z * (-6.0d0))
if (z <= (-1150000000000.0d0)) then
tmp = t_1
else if (z <= (-2.9d-158)) then
tmp = t_0
else if (z <= (-4.6d-190)) then
tmp = y * 4.0d0
else if (z <= 2d-298) then
tmp = x * (-3.0d0)
else if (z <= 1.2d-182) then
tmp = y * 4.0d0
else if (z <= 2600000.0d0) then
tmp = t_0
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = x * (-3.0 + (z * 6.0));
double t_1 = (y - x) * (z * -6.0);
double tmp;
if (z <= -1150000000000.0) {
tmp = t_1;
} else if (z <= -2.9e-158) {
tmp = t_0;
} else if (z <= -4.6e-190) {
tmp = y * 4.0;
} else if (z <= 2e-298) {
tmp = x * -3.0;
} else if (z <= 1.2e-182) {
tmp = y * 4.0;
} else if (z <= 2600000.0) {
tmp = t_0;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z): t_0 = x * (-3.0 + (z * 6.0)) t_1 = (y - x) * (z * -6.0) tmp = 0 if z <= -1150000000000.0: tmp = t_1 elif z <= -2.9e-158: tmp = t_0 elif z <= -4.6e-190: tmp = y * 4.0 elif z <= 2e-298: tmp = x * -3.0 elif z <= 1.2e-182: tmp = y * 4.0 elif z <= 2600000.0: tmp = t_0 else: tmp = t_1 return tmp
function code(x, y, z) t_0 = Float64(x * Float64(-3.0 + Float64(z * 6.0))) t_1 = Float64(Float64(y - x) * Float64(z * -6.0)) tmp = 0.0 if (z <= -1150000000000.0) tmp = t_1; elseif (z <= -2.9e-158) tmp = t_0; elseif (z <= -4.6e-190) tmp = Float64(y * 4.0); elseif (z <= 2e-298) tmp = Float64(x * -3.0); elseif (z <= 1.2e-182) tmp = Float64(y * 4.0); elseif (z <= 2600000.0) tmp = t_0; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z) t_0 = x * (-3.0 + (z * 6.0)); t_1 = (y - x) * (z * -6.0); tmp = 0.0; if (z <= -1150000000000.0) tmp = t_1; elseif (z <= -2.9e-158) tmp = t_0; elseif (z <= -4.6e-190) tmp = y * 4.0; elseif (z <= 2e-298) tmp = x * -3.0; elseif (z <= 1.2e-182) tmp = y * 4.0; elseif (z <= 2600000.0) tmp = t_0; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(x * N[(-3.0 + N[(z * 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[(y - x), $MachinePrecision] * N[(z * -6.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1150000000000.0], t$95$1, If[LessEqual[z, -2.9e-158], t$95$0, If[LessEqual[z, -4.6e-190], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 2e-298], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 1.2e-182], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 2600000.0], t$95$0, t$95$1]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := x \cdot \left(-3 + z \cdot 6\right)\\
t_1 := \left(y - x\right) \cdot \left(z \cdot -6\right)\\
\mathbf{if}\;z \leq -1150000000000:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -2.9 \cdot 10^{-158}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -4.6 \cdot 10^{-190}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 2 \cdot 10^{-298}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 1.2 \cdot 10^{-182}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 2600000:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.15e12 or 2.6e6 < z Initial program 99.8%
metadata-eval99.8%
Simplified99.8%
+-commutative99.8%
*-commutative99.8%
associate-*r*99.7%
fma-define99.7%
Applied egg-rr99.7%
Taylor expanded in z around inf 99.6%
associate-*r*99.8%
*-commutative99.8%
Simplified99.8%
if -1.15e12 < z < -2.8999999999999998e-158 or 1.1999999999999999e-182 < z < 2.6e6Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in x around inf 67.6%
sub-neg67.6%
distribute-rgt-in67.6%
metadata-eval67.6%
neg-mul-167.6%
associate-*r*67.6%
*-commutative67.6%
associate-+r+67.6%
metadata-eval67.6%
associate-*r*67.6%
metadata-eval67.6%
*-commutative67.6%
Simplified67.6%
if -2.8999999999999998e-158 < z < -4.59999999999999984e-190 or 1.99999999999999982e-298 < z < 1.1999999999999999e-182Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 99.9%
Taylor expanded in x around 0 72.3%
if -4.59999999999999984e-190 < z < 1.99999999999999982e-298Initial program 99.6%
metadata-eval99.6%
Simplified99.6%
Taylor expanded in x around inf 64.3%
sub-neg64.3%
distribute-rgt-in64.3%
metadata-eval64.3%
neg-mul-164.3%
associate-*r*64.3%
*-commutative64.3%
associate-+r+64.3%
metadata-eval64.3%
associate-*r*64.3%
metadata-eval64.3%
*-commutative64.3%
Simplified64.3%
Taylor expanded in z around 0 64.3%
*-commutative64.3%
Simplified64.3%
Final simplification84.6%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* -6.0 (* y z))))
(if (<= z -0.43)
t_0
(if (<= z -1.6e-160)
(* x -3.0)
(if (<= z -4.6e-193)
(* y 4.0)
(if (<= z 2.3e-297)
(* x -3.0)
(if (<= z 4.6e-182) (* y 4.0) (if (<= z 0.58) (* x -3.0) t_0))))))))
double code(double x, double y, double z) {
double t_0 = -6.0 * (y * z);
double tmp;
if (z <= -0.43) {
tmp = t_0;
} else if (z <= -1.6e-160) {
tmp = x * -3.0;
} else if (z <= -4.6e-193) {
tmp = y * 4.0;
} else if (z <= 2.3e-297) {
tmp = x * -3.0;
} else if (z <= 4.6e-182) {
tmp = y * 4.0;
} else if (z <= 0.58) {
tmp = x * -3.0;
} else {
tmp = t_0;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: t_0
real(8) :: tmp
t_0 = (-6.0d0) * (y * z)
if (z <= (-0.43d0)) then
tmp = t_0
else if (z <= (-1.6d-160)) then
tmp = x * (-3.0d0)
else if (z <= (-4.6d-193)) then
tmp = y * 4.0d0
else if (z <= 2.3d-297) then
tmp = x * (-3.0d0)
else if (z <= 4.6d-182) then
tmp = y * 4.0d0
else if (z <= 0.58d0) then
tmp = x * (-3.0d0)
else
tmp = t_0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = -6.0 * (y * z);
double tmp;
if (z <= -0.43) {
tmp = t_0;
} else if (z <= -1.6e-160) {
tmp = x * -3.0;
} else if (z <= -4.6e-193) {
tmp = y * 4.0;
} else if (z <= 2.3e-297) {
tmp = x * -3.0;
} else if (z <= 4.6e-182) {
tmp = y * 4.0;
} else if (z <= 0.58) {
tmp = x * -3.0;
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = -6.0 * (y * z) tmp = 0 if z <= -0.43: tmp = t_0 elif z <= -1.6e-160: tmp = x * -3.0 elif z <= -4.6e-193: tmp = y * 4.0 elif z <= 2.3e-297: tmp = x * -3.0 elif z <= 4.6e-182: tmp = y * 4.0 elif z <= 0.58: tmp = x * -3.0 else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(-6.0 * Float64(y * z)) tmp = 0.0 if (z <= -0.43) tmp = t_0; elseif (z <= -1.6e-160) tmp = Float64(x * -3.0); elseif (z <= -4.6e-193) tmp = Float64(y * 4.0); elseif (z <= 2.3e-297) tmp = Float64(x * -3.0); elseif (z <= 4.6e-182) tmp = Float64(y * 4.0); elseif (z <= 0.58) tmp = Float64(x * -3.0); else tmp = t_0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = -6.0 * (y * z); tmp = 0.0; if (z <= -0.43) tmp = t_0; elseif (z <= -1.6e-160) tmp = x * -3.0; elseif (z <= -4.6e-193) tmp = y * 4.0; elseif (z <= 2.3e-297) tmp = x * -3.0; elseif (z <= 4.6e-182) tmp = y * 4.0; elseif (z <= 0.58) tmp = x * -3.0; else tmp = t_0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(-6.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -0.43], t$95$0, If[LessEqual[z, -1.6e-160], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, -4.6e-193], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 2.3e-297], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 4.6e-182], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 0.58], N[(x * -3.0), $MachinePrecision], t$95$0]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := -6 \cdot \left(y \cdot z\right)\\
\mathbf{if}\;z \leq -0.43:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -1.6 \cdot 10^{-160}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq -4.6 \cdot 10^{-193}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 2.3 \cdot 10^{-297}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 4.6 \cdot 10^{-182}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 0.58:\\
\;\;\;\;x \cdot -3\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if z < -0.429999999999999993 or 0.57999999999999996 < z Initial program 99.8%
+-commutative99.8%
associate-*l*99.8%
fma-define99.9%
sub-neg99.9%
distribute-rgt-in99.9%
metadata-eval99.9%
metadata-eval99.9%
distribute-lft-neg-out99.9%
distribute-rgt-neg-in99.9%
metadata-eval99.9%
Simplified99.9%
Taylor expanded in y around inf 52.3%
Taylor expanded in z around inf 51.3%
*-commutative51.3%
Simplified51.3%
if -0.429999999999999993 < z < -1.60000000000000004e-160 or -4.60000000000000017e-193 < z < 2.2999999999999999e-297 or 4.5999999999999998e-182 < z < 0.57999999999999996Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around inf 67.3%
sub-neg67.3%
distribute-rgt-in67.3%
metadata-eval67.3%
neg-mul-167.3%
associate-*r*67.3%
*-commutative67.3%
associate-+r+67.3%
metadata-eval67.3%
associate-*r*67.3%
metadata-eval67.3%
*-commutative67.3%
Simplified67.3%
Taylor expanded in z around 0 65.4%
*-commutative65.4%
Simplified65.4%
if -1.60000000000000004e-160 < z < -4.60000000000000017e-193 or 2.2999999999999999e-297 < z < 4.5999999999999998e-182Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 99.9%
Taylor expanded in x around 0 72.3%
Final simplification58.2%
(FPCore (x y z) :precision binary64 (if (or (<= z -0.55) (not (<= z 0.5))) (* (- y x) (* z -6.0)) (+ x (* (- y x) 4.0))))
double code(double x, double y, double z) {
double tmp;
if ((z <= -0.55) || !(z <= 0.5)) {
tmp = (y - x) * (z * -6.0);
} else {
tmp = x + ((y - x) * 4.0);
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if ((z <= (-0.55d0)) .or. (.not. (z <= 0.5d0))) then
tmp = (y - x) * (z * (-6.0d0))
else
tmp = x + ((y - x) * 4.0d0)
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((z <= -0.55) || !(z <= 0.5)) {
tmp = (y - x) * (z * -6.0);
} else {
tmp = x + ((y - x) * 4.0);
}
return tmp;
}
def code(x, y, z): tmp = 0 if (z <= -0.55) or not (z <= 0.5): tmp = (y - x) * (z * -6.0) else: tmp = x + ((y - x) * 4.0) return tmp
function code(x, y, z) tmp = 0.0 if ((z <= -0.55) || !(z <= 0.5)) tmp = Float64(Float64(y - x) * Float64(z * -6.0)); else tmp = Float64(x + Float64(Float64(y - x) * 4.0)); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((z <= -0.55) || ~((z <= 0.5))) tmp = (y - x) * (z * -6.0); else tmp = x + ((y - x) * 4.0); end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[z, -0.55], N[Not[LessEqual[z, 0.5]], $MachinePrecision]], N[(N[(y - x), $MachinePrecision] * N[(z * -6.0), $MachinePrecision]), $MachinePrecision], N[(x + N[(N[(y - x), $MachinePrecision] * 4.0), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.55 \lor \neg \left(z \leq 0.5\right):\\
\;\;\;\;\left(y - x\right) \cdot \left(z \cdot -6\right)\\
\mathbf{else}:\\
\;\;\;\;x + \left(y - x\right) \cdot 4\\
\end{array}
\end{array}
if z < -0.55000000000000004 or 0.5 < z Initial program 99.8%
metadata-eval99.8%
Simplified99.8%
+-commutative99.8%
*-commutative99.8%
associate-*r*99.7%
fma-define99.7%
Applied egg-rr99.7%
Taylor expanded in z around inf 97.1%
associate-*r*97.2%
*-commutative97.2%
Simplified97.2%
if -0.55000000000000004 < z < 0.5Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 98.2%
Final simplification97.7%
(FPCore (x y z) :precision binary64 (if (or (<= z -0.58) (not (<= z 0.58))) (* (- y x) (* z -6.0)) (+ (* y 4.0) (* x -3.0))))
double code(double x, double y, double z) {
double tmp;
if ((z <= -0.58) || !(z <= 0.58)) {
tmp = (y - x) * (z * -6.0);
} else {
tmp = (y * 4.0) + (x * -3.0);
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if ((z <= (-0.58d0)) .or. (.not. (z <= 0.58d0))) then
tmp = (y - x) * (z * (-6.0d0))
else
tmp = (y * 4.0d0) + (x * (-3.0d0))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((z <= -0.58) || !(z <= 0.58)) {
tmp = (y - x) * (z * -6.0);
} else {
tmp = (y * 4.0) + (x * -3.0);
}
return tmp;
}
def code(x, y, z): tmp = 0 if (z <= -0.58) or not (z <= 0.58): tmp = (y - x) * (z * -6.0) else: tmp = (y * 4.0) + (x * -3.0) return tmp
function code(x, y, z) tmp = 0.0 if ((z <= -0.58) || !(z <= 0.58)) tmp = Float64(Float64(y - x) * Float64(z * -6.0)); else tmp = Float64(Float64(y * 4.0) + Float64(x * -3.0)); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((z <= -0.58) || ~((z <= 0.58))) tmp = (y - x) * (z * -6.0); else tmp = (y * 4.0) + (x * -3.0); end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[z, -0.58], N[Not[LessEqual[z, 0.58]], $MachinePrecision]], N[(N[(y - x), $MachinePrecision] * N[(z * -6.0), $MachinePrecision]), $MachinePrecision], N[(N[(y * 4.0), $MachinePrecision] + N[(x * -3.0), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -0.58 \lor \neg \left(z \leq 0.58\right):\\
\;\;\;\;\left(y - x\right) \cdot \left(z \cdot -6\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot 4 + x \cdot -3\\
\end{array}
\end{array}
if z < -0.57999999999999996 or 0.57999999999999996 < z Initial program 99.8%
metadata-eval99.8%
Simplified99.8%
+-commutative99.8%
*-commutative99.8%
associate-*r*99.7%
fma-define99.7%
Applied egg-rr99.7%
Taylor expanded in z around inf 97.1%
associate-*r*97.2%
*-commutative97.2%
Simplified97.2%
if -0.57999999999999996 < z < 0.57999999999999996Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 98.2%
Taylor expanded in x around 0 98.3%
Final simplification97.7%
(FPCore (x y z) :precision binary64 (if (or (<= x -1.05e-39) (not (<= x 8.8e+114))) (* x -3.0) (* y 4.0)))
double code(double x, double y, double z) {
double tmp;
if ((x <= -1.05e-39) || !(x <= 8.8e+114)) {
tmp = x * -3.0;
} else {
tmp = y * 4.0;
}
return tmp;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
real(8) :: tmp
if ((x <= (-1.05d-39)) .or. (.not. (x <= 8.8d+114))) then
tmp = x * (-3.0d0)
else
tmp = y * 4.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((x <= -1.05e-39) || !(x <= 8.8e+114)) {
tmp = x * -3.0;
} else {
tmp = y * 4.0;
}
return tmp;
}
def code(x, y, z): tmp = 0 if (x <= -1.05e-39) or not (x <= 8.8e+114): tmp = x * -3.0 else: tmp = y * 4.0 return tmp
function code(x, y, z) tmp = 0.0 if ((x <= -1.05e-39) || !(x <= 8.8e+114)) tmp = Float64(x * -3.0); else tmp = Float64(y * 4.0); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((x <= -1.05e-39) || ~((x <= 8.8e+114))) tmp = x * -3.0; else tmp = y * 4.0; end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[x, -1.05e-39], N[Not[LessEqual[x, 8.8e+114]], $MachinePrecision]], N[(x * -3.0), $MachinePrecision], N[(y * 4.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -1.05 \cdot 10^{-39} \lor \neg \left(x \leq 8.8 \cdot 10^{+114}\right):\\
\;\;\;\;x \cdot -3\\
\mathbf{else}:\\
\;\;\;\;y \cdot 4\\
\end{array}
\end{array}
if x < -1.04999999999999997e-39 or 8.8000000000000001e114 < x Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in x around inf 85.5%
sub-neg85.5%
distribute-rgt-in85.5%
metadata-eval85.5%
neg-mul-185.5%
associate-*r*85.5%
*-commutative85.5%
associate-+r+85.5%
metadata-eval85.5%
associate-*r*85.5%
metadata-eval85.5%
*-commutative85.5%
Simplified85.5%
Taylor expanded in z around 0 44.6%
*-commutative44.6%
Simplified44.6%
if -1.04999999999999997e-39 < x < 8.8000000000000001e114Initial program 99.6%
metadata-eval99.6%
Simplified99.6%
Taylor expanded in z around 0 43.4%
Taylor expanded in x around 0 32.6%
Final simplification38.2%
(FPCore (x y z) :precision binary64 (+ x (* (* (- y x) 6.0) (- 0.6666666666666666 z))))
double code(double x, double y, double z) {
return x + (((y - x) * 6.0) * (0.6666666666666666 - z));
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = x + (((y - x) * 6.0d0) * (0.6666666666666666d0 - z))
end function
public static double code(double x, double y, double z) {
return x + (((y - x) * 6.0) * (0.6666666666666666 - z));
}
def code(x, y, z): return x + (((y - x) * 6.0) * (0.6666666666666666 - z))
function code(x, y, z) return Float64(x + Float64(Float64(Float64(y - x) * 6.0) * Float64(0.6666666666666666 - z))) end
function tmp = code(x, y, z) tmp = x + (((y - x) * 6.0) * (0.6666666666666666 - z)); end
code[x_, y_, z_] := N[(x + N[(N[(N[(y - x), $MachinePrecision] * 6.0), $MachinePrecision] * N[(0.6666666666666666 - z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(\left(y - x\right) \cdot 6\right) \cdot \left(0.6666666666666666 - z\right)
\end{array}
Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Final simplification99.7%
(FPCore (x y z) :precision binary64 (* y 4.0))
double code(double x, double y, double z) {
return y * 4.0;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = y * 4.0d0
end function
public static double code(double x, double y, double z) {
return y * 4.0;
}
def code(x, y, z): return y * 4.0
function code(x, y, z) return Float64(y * 4.0) end
function tmp = code(x, y, z) tmp = y * 4.0; end
code[x_, y_, z_] := N[(y * 4.0), $MachinePrecision]
\begin{array}{l}
\\
y \cdot 4
\end{array}
Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in z around 0 45.8%
Taylor expanded in x around 0 19.9%
Final simplification19.9%
(FPCore (x y z) :precision binary64 x)
double code(double x, double y, double z) {
return x;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = x
end function
public static double code(double x, double y, double z) {
return x;
}
def code(x, y, z): return x
function code(x, y, z) return x end
function tmp = code(x, y, z) tmp = x; end
code[x_, y_, z_] := x
\begin{array}{l}
\\
x
\end{array}
Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in y around inf 46.6%
associate-*r*46.7%
Simplified46.7%
Taylor expanded in x around inf 2.4%
Final simplification2.4%
herbie shell --seed 2024040
(FPCore (x y z)
:name "Data.Colour.RGBSpace.HSL:hsl from colour-2.3.3, D"
:precision binary64
(+ x (* (* (- y x) 6.0) (- (/ 2.0 3.0) z))))