
(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.5%
+-commutative99.5%
associate-*l*99.7%
fma-define99.7%
sub-neg99.7%
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 (fma (- y x) (* 6.0 (- 0.6666666666666666 z)) x))
double code(double x, double y, double z) {
return fma((y - x), (6.0 * (0.6666666666666666 - z)), x);
}
function code(x, y, z) return fma(Float64(y - x), Float64(6.0 * Float64(0.6666666666666666 - z)), x) end
code[x_, y_, z_] := N[(N[(y - x), $MachinePrecision] * N[(6.0 * N[(0.6666666666666666 - z), $MachinePrecision]), $MachinePrecision] + x), $MachinePrecision]
\begin{array}{l}
\\
\mathsf{fma}\left(y - x, 6 \cdot \left(0.6666666666666666 - z\right), x\right)
\end{array}
Initial program 99.5%
+-commutative99.5%
associate-*l*99.7%
fma-define99.7%
metadata-eval99.7%
Simplified99.7%
Final simplification99.7%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* 6.0 (* x z))) (t_1 (* -6.0 (* y z))))
(if (<= z -1.45e+218)
t_0
(if (<= z -1.3e+107)
t_1
(if (<= z -0.115)
t_0
(if (<= z -1.8e-101)
(* y 4.0)
(if (<= z -3.55e-161)
(* x -3.0)
(if (<= z -1.1e-204)
(* y 4.0)
(if (<= z -1.15e-292)
(* x -3.0)
(if (<= z 8.5e-174)
(* y 4.0)
(if (<= z 1.2e-152)
(* x -3.0)
(if (<= z 0.52)
(* y 4.0)
(if (or (<= z 1.5e+60) (not (<= z 6.5e+148)))
t_0
t_1)))))))))))))
double code(double x, double y, double z) {
double t_0 = 6.0 * (x * z);
double t_1 = -6.0 * (y * z);
double tmp;
if (z <= -1.45e+218) {
tmp = t_0;
} else if (z <= -1.3e+107) {
tmp = t_1;
} else if (z <= -0.115) {
tmp = t_0;
} else if (z <= -1.8e-101) {
tmp = y * 4.0;
} else if (z <= -3.55e-161) {
tmp = x * -3.0;
} else if (z <= -1.1e-204) {
tmp = y * 4.0;
} else if (z <= -1.15e-292) {
tmp = x * -3.0;
} else if (z <= 8.5e-174) {
tmp = y * 4.0;
} else if (z <= 1.2e-152) {
tmp = x * -3.0;
} else if (z <= 0.52) {
tmp = y * 4.0;
} else if ((z <= 1.5e+60) || !(z <= 6.5e+148)) {
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 * (x * z)
t_1 = (-6.0d0) * (y * z)
if (z <= (-1.45d+218)) then
tmp = t_0
else if (z <= (-1.3d+107)) then
tmp = t_1
else if (z <= (-0.115d0)) then
tmp = t_0
else if (z <= (-1.8d-101)) then
tmp = y * 4.0d0
else if (z <= (-3.55d-161)) then
tmp = x * (-3.0d0)
else if (z <= (-1.1d-204)) then
tmp = y * 4.0d0
else if (z <= (-1.15d-292)) then
tmp = x * (-3.0d0)
else if (z <= 8.5d-174) then
tmp = y * 4.0d0
else if (z <= 1.2d-152) then
tmp = x * (-3.0d0)
else if (z <= 0.52d0) then
tmp = y * 4.0d0
else if ((z <= 1.5d+60) .or. (.not. (z <= 6.5d+148))) 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 * (x * z);
double t_1 = -6.0 * (y * z);
double tmp;
if (z <= -1.45e+218) {
tmp = t_0;
} else if (z <= -1.3e+107) {
tmp = t_1;
} else if (z <= -0.115) {
tmp = t_0;
} else if (z <= -1.8e-101) {
tmp = y * 4.0;
} else if (z <= -3.55e-161) {
tmp = x * -3.0;
} else if (z <= -1.1e-204) {
tmp = y * 4.0;
} else if (z <= -1.15e-292) {
tmp = x * -3.0;
} else if (z <= 8.5e-174) {
tmp = y * 4.0;
} else if (z <= 1.2e-152) {
tmp = x * -3.0;
} else if (z <= 0.52) {
tmp = y * 4.0;
} else if ((z <= 1.5e+60) || !(z <= 6.5e+148)) {
tmp = t_0;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z): t_0 = 6.0 * (x * z) t_1 = -6.0 * (y * z) tmp = 0 if z <= -1.45e+218: tmp = t_0 elif z <= -1.3e+107: tmp = t_1 elif z <= -0.115: tmp = t_0 elif z <= -1.8e-101: tmp = y * 4.0 elif z <= -3.55e-161: tmp = x * -3.0 elif z <= -1.1e-204: tmp = y * 4.0 elif z <= -1.15e-292: tmp = x * -3.0 elif z <= 8.5e-174: tmp = y * 4.0 elif z <= 1.2e-152: tmp = x * -3.0 elif z <= 0.52: tmp = y * 4.0 elif (z <= 1.5e+60) or not (z <= 6.5e+148): tmp = t_0 else: tmp = t_1 return tmp
function code(x, y, z) t_0 = Float64(6.0 * Float64(x * z)) t_1 = Float64(-6.0 * Float64(y * z)) tmp = 0.0 if (z <= -1.45e+218) tmp = t_0; elseif (z <= -1.3e+107) tmp = t_1; elseif (z <= -0.115) tmp = t_0; elseif (z <= -1.8e-101) tmp = Float64(y * 4.0); elseif (z <= -3.55e-161) tmp = Float64(x * -3.0); elseif (z <= -1.1e-204) tmp = Float64(y * 4.0); elseif (z <= -1.15e-292) tmp = Float64(x * -3.0); elseif (z <= 8.5e-174) tmp = Float64(y * 4.0); elseif (z <= 1.2e-152) tmp = Float64(x * -3.0); elseif (z <= 0.52) tmp = Float64(y * 4.0); elseif ((z <= 1.5e+60) || !(z <= 6.5e+148)) tmp = t_0; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z) t_0 = 6.0 * (x * z); t_1 = -6.0 * (y * z); tmp = 0.0; if (z <= -1.45e+218) tmp = t_0; elseif (z <= -1.3e+107) tmp = t_1; elseif (z <= -0.115) tmp = t_0; elseif (z <= -1.8e-101) tmp = y * 4.0; elseif (z <= -3.55e-161) tmp = x * -3.0; elseif (z <= -1.1e-204) tmp = y * 4.0; elseif (z <= -1.15e-292) tmp = x * -3.0; elseif (z <= 8.5e-174) tmp = y * 4.0; elseif (z <= 1.2e-152) tmp = x * -3.0; elseif (z <= 0.52) tmp = y * 4.0; elseif ((z <= 1.5e+60) || ~((z <= 6.5e+148))) tmp = t_0; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(6.0 * N[(x * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(-6.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -1.45e+218], t$95$0, If[LessEqual[z, -1.3e+107], t$95$1, If[LessEqual[z, -0.115], t$95$0, If[LessEqual[z, -1.8e-101], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, -3.55e-161], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, -1.1e-204], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, -1.15e-292], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 8.5e-174], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 1.2e-152], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 0.52], N[(y * 4.0), $MachinePrecision], If[Or[LessEqual[z, 1.5e+60], N[Not[LessEqual[z, 6.5e+148]], $MachinePrecision]], t$95$0, t$95$1]]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 6 \cdot \left(x \cdot z\right)\\
t_1 := -6 \cdot \left(y \cdot z\right)\\
\mathbf{if}\;z \leq -1.45 \cdot 10^{+218}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -1.3 \cdot 10^{+107}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -0.115:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -1.8 \cdot 10^{-101}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq -3.55 \cdot 10^{-161}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq -1.1 \cdot 10^{-204}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq -1.15 \cdot 10^{-292}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 8.5 \cdot 10^{-174}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 1.2 \cdot 10^{-152}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 0.52:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 1.5 \cdot 10^{+60} \lor \neg \left(z \leq 6.5 \cdot 10^{+148}\right):\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -1.45e218 or -1.3000000000000001e107 < z < -0.115000000000000005 or 0.52000000000000002 < z < 1.4999999999999999e60 or 6.49999999999999947e148 < z Initial program 99.6%
metadata-eval99.6%
Simplified99.6%
Taylor expanded in x around inf 70.6%
metadata-eval70.6%
cancel-sign-sub-inv70.6%
*-commutative70.6%
cancel-sign-sub-inv70.6%
distribute-lft-neg-in70.6%
*-commutative70.6%
distribute-lft-neg-in70.6%
metadata-eval70.6%
sub-neg70.6%
distribute-lft-in70.6%
metadata-eval70.6%
neg-mul-170.6%
*-commutative70.6%
associate-*l*70.6%
associate-+r+70.6%
metadata-eval70.6%
*-commutative70.6%
associate-*l*70.6%
metadata-eval70.6%
Simplified70.6%
Taylor expanded in z around inf 65.1%
*-commutative65.1%
Simplified65.1%
if -1.45e218 < z < -1.3000000000000001e107 or 1.4999999999999999e60 < z < 6.49999999999999947e148Initial program 99.6%
metadata-eval99.6%
Simplified99.6%
Taylor expanded in z around inf 99.6%
Taylor expanded in z around inf 99.7%
Taylor expanded in y around inf 67.5%
*-commutative67.5%
Simplified67.5%
if -0.115000000000000005 < z < -1.8e-101 or -3.55e-161 < z < -1.0999999999999999e-204 or -1.1499999999999999e-292 < z < 8.4999999999999996e-174 or 1.2e-152 < z < 0.52000000000000002Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in z around 0 95.7%
Taylor expanded in y around inf 84.0%
distribute-lft1-in84.8%
metadata-eval84.8%
Simplified84.8%
Taylor expanded in y around inf 59.7%
*-commutative59.7%
Simplified59.7%
if -1.8e-101 < z < -3.55e-161 or -1.0999999999999999e-204 < z < -1.1499999999999999e-292 or 8.4999999999999996e-174 < z < 1.2e-152Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in x around inf 87.7%
metadata-eval87.7%
cancel-sign-sub-inv87.7%
*-commutative87.7%
cancel-sign-sub-inv87.7%
distribute-lft-neg-in87.7%
*-commutative87.7%
distribute-lft-neg-in87.7%
metadata-eval87.7%
sub-neg87.7%
distribute-lft-in87.7%
metadata-eval87.7%
neg-mul-187.7%
*-commutative87.7%
associate-*l*87.7%
associate-+r+87.7%
metadata-eval87.7%
*-commutative87.7%
associate-*l*87.7%
metadata-eval87.7%
Simplified87.7%
Taylor expanded in z around 0 87.7%
*-commutative87.7%
Simplified87.7%
Final simplification65.4%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* 6.0 (* x z))) (t_1 (* -6.0 (* y z))))
(if (<= z -6.5e+212)
t_0
(if (<= z -4.7e+142)
t_1
(if (<= z -0.062)
(* x (* z 6.0))
(if (<= z -1.55e-104)
(* y 4.0)
(if (<= z -2.25e-161)
(* x -3.0)
(if (<= z -2.3e-204)
(* y 4.0)
(if (<= z -1.85e-293)
(* x -3.0)
(if (<= z 3e-174)
(* y 4.0)
(if (<= z 7.5e-147)
(* x -3.0)
(if (<= z 0.52)
(* y 4.0)
(if (or (<= z 3.3e+56) (not (<= z 4.4e+149)))
t_0
t_1)))))))))))))
double code(double x, double y, double z) {
double t_0 = 6.0 * (x * z);
double t_1 = -6.0 * (y * z);
double tmp;
if (z <= -6.5e+212) {
tmp = t_0;
} else if (z <= -4.7e+142) {
tmp = t_1;
} else if (z <= -0.062) {
tmp = x * (z * 6.0);
} else if (z <= -1.55e-104) {
tmp = y * 4.0;
} else if (z <= -2.25e-161) {
tmp = x * -3.0;
} else if (z <= -2.3e-204) {
tmp = y * 4.0;
} else if (z <= -1.85e-293) {
tmp = x * -3.0;
} else if (z <= 3e-174) {
tmp = y * 4.0;
} else if (z <= 7.5e-147) {
tmp = x * -3.0;
} else if (z <= 0.52) {
tmp = y * 4.0;
} else if ((z <= 3.3e+56) || !(z <= 4.4e+149)) {
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 * (x * z)
t_1 = (-6.0d0) * (y * z)
if (z <= (-6.5d+212)) then
tmp = t_0
else if (z <= (-4.7d+142)) then
tmp = t_1
else if (z <= (-0.062d0)) then
tmp = x * (z * 6.0d0)
else if (z <= (-1.55d-104)) then
tmp = y * 4.0d0
else if (z <= (-2.25d-161)) then
tmp = x * (-3.0d0)
else if (z <= (-2.3d-204)) then
tmp = y * 4.0d0
else if (z <= (-1.85d-293)) then
tmp = x * (-3.0d0)
else if (z <= 3d-174) then
tmp = y * 4.0d0
else if (z <= 7.5d-147) then
tmp = x * (-3.0d0)
else if (z <= 0.52d0) then
tmp = y * 4.0d0
else if ((z <= 3.3d+56) .or. (.not. (z <= 4.4d+149))) 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 * (x * z);
double t_1 = -6.0 * (y * z);
double tmp;
if (z <= -6.5e+212) {
tmp = t_0;
} else if (z <= -4.7e+142) {
tmp = t_1;
} else if (z <= -0.062) {
tmp = x * (z * 6.0);
} else if (z <= -1.55e-104) {
tmp = y * 4.0;
} else if (z <= -2.25e-161) {
tmp = x * -3.0;
} else if (z <= -2.3e-204) {
tmp = y * 4.0;
} else if (z <= -1.85e-293) {
tmp = x * -3.0;
} else if (z <= 3e-174) {
tmp = y * 4.0;
} else if (z <= 7.5e-147) {
tmp = x * -3.0;
} else if (z <= 0.52) {
tmp = y * 4.0;
} else if ((z <= 3.3e+56) || !(z <= 4.4e+149)) {
tmp = t_0;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z): t_0 = 6.0 * (x * z) t_1 = -6.0 * (y * z) tmp = 0 if z <= -6.5e+212: tmp = t_0 elif z <= -4.7e+142: tmp = t_1 elif z <= -0.062: tmp = x * (z * 6.0) elif z <= -1.55e-104: tmp = y * 4.0 elif z <= -2.25e-161: tmp = x * -3.0 elif z <= -2.3e-204: tmp = y * 4.0 elif z <= -1.85e-293: tmp = x * -3.0 elif z <= 3e-174: tmp = y * 4.0 elif z <= 7.5e-147: tmp = x * -3.0 elif z <= 0.52: tmp = y * 4.0 elif (z <= 3.3e+56) or not (z <= 4.4e+149): tmp = t_0 else: tmp = t_1 return tmp
function code(x, y, z) t_0 = Float64(6.0 * Float64(x * z)) t_1 = Float64(-6.0 * Float64(y * z)) tmp = 0.0 if (z <= -6.5e+212) tmp = t_0; elseif (z <= -4.7e+142) tmp = t_1; elseif (z <= -0.062) tmp = Float64(x * Float64(z * 6.0)); elseif (z <= -1.55e-104) tmp = Float64(y * 4.0); elseif (z <= -2.25e-161) tmp = Float64(x * -3.0); elseif (z <= -2.3e-204) tmp = Float64(y * 4.0); elseif (z <= -1.85e-293) tmp = Float64(x * -3.0); elseif (z <= 3e-174) tmp = Float64(y * 4.0); elseif (z <= 7.5e-147) tmp = Float64(x * -3.0); elseif (z <= 0.52) tmp = Float64(y * 4.0); elseif ((z <= 3.3e+56) || !(z <= 4.4e+149)) tmp = t_0; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z) t_0 = 6.0 * (x * z); t_1 = -6.0 * (y * z); tmp = 0.0; if (z <= -6.5e+212) tmp = t_0; elseif (z <= -4.7e+142) tmp = t_1; elseif (z <= -0.062) tmp = x * (z * 6.0); elseif (z <= -1.55e-104) tmp = y * 4.0; elseif (z <= -2.25e-161) tmp = x * -3.0; elseif (z <= -2.3e-204) tmp = y * 4.0; elseif (z <= -1.85e-293) tmp = x * -3.0; elseif (z <= 3e-174) tmp = y * 4.0; elseif (z <= 7.5e-147) tmp = x * -3.0; elseif (z <= 0.52) tmp = y * 4.0; elseif ((z <= 3.3e+56) || ~((z <= 4.4e+149))) tmp = t_0; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(6.0 * N[(x * z), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(-6.0 * N[(y * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -6.5e+212], t$95$0, If[LessEqual[z, -4.7e+142], t$95$1, If[LessEqual[z, -0.062], N[(x * N[(z * 6.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.55e-104], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, -2.25e-161], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, -2.3e-204], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, -1.85e-293], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 3e-174], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 7.5e-147], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 0.52], N[(y * 4.0), $MachinePrecision], If[Or[LessEqual[z, 3.3e+56], N[Not[LessEqual[z, 4.4e+149]], $MachinePrecision]], t$95$0, t$95$1]]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 6 \cdot \left(x \cdot z\right)\\
t_1 := -6 \cdot \left(y \cdot z\right)\\
\mathbf{if}\;z \leq -6.5 \cdot 10^{+212}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -4.7 \cdot 10^{+142}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -0.062:\\
\;\;\;\;x \cdot \left(z \cdot 6\right)\\
\mathbf{elif}\;z \leq -1.55 \cdot 10^{-104}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq -2.25 \cdot 10^{-161}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq -2.3 \cdot 10^{-204}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq -1.85 \cdot 10^{-293}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 3 \cdot 10^{-174}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 7.5 \cdot 10^{-147}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 0.52:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 3.3 \cdot 10^{+56} \lor \neg \left(z \leq 4.4 \cdot 10^{+149}\right):\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -6.49999999999999997e212 or 0.52000000000000002 < z < 3.30000000000000002e56 or 4.4e149 < z Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in x around inf 72.1%
metadata-eval72.1%
cancel-sign-sub-inv72.1%
*-commutative72.1%
cancel-sign-sub-inv72.1%
distribute-lft-neg-in72.1%
*-commutative72.1%
distribute-lft-neg-in72.1%
metadata-eval72.1%
sub-neg72.1%
distribute-lft-in72.1%
metadata-eval72.1%
neg-mul-172.1%
*-commutative72.1%
associate-*l*72.1%
associate-+r+72.1%
metadata-eval72.1%
*-commutative72.1%
associate-*l*72.1%
metadata-eval72.1%
Simplified72.1%
Taylor expanded in z around inf 68.1%
*-commutative68.1%
Simplified68.1%
if -6.49999999999999997e212 < z < -4.7e142 or 3.30000000000000002e56 < z < 4.4e149Initial program 99.6%
metadata-eval99.6%
Simplified99.6%
Taylor expanded in z around inf 99.6%
Taylor expanded in z around inf 99.7%
Taylor expanded in y around inf 69.1%
*-commutative69.1%
Simplified69.1%
if -4.7e142 < z < -0.062Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around inf 63.5%
metadata-eval63.5%
cancel-sign-sub-inv63.5%
*-commutative63.5%
cancel-sign-sub-inv63.5%
distribute-lft-neg-in63.5%
*-commutative63.5%
distribute-lft-neg-in63.5%
metadata-eval63.5%
sub-neg63.5%
distribute-lft-in63.6%
metadata-eval63.6%
neg-mul-163.6%
*-commutative63.6%
associate-*l*63.6%
associate-+r+63.6%
metadata-eval63.6%
*-commutative63.6%
associate-*l*63.6%
metadata-eval63.6%
Simplified63.6%
Taylor expanded in z around inf 55.4%
if -0.062 < z < -1.54999999999999988e-104 or -2.2499999999999998e-161 < z < -2.2999999999999999e-204 or -1.85000000000000004e-293 < z < 3.00000000000000021e-174 or 7.50000000000000047e-147 < z < 0.52000000000000002Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in z around 0 95.7%
Taylor expanded in y around inf 84.0%
distribute-lft1-in84.8%
metadata-eval84.8%
Simplified84.8%
Taylor expanded in y around inf 59.7%
*-commutative59.7%
Simplified59.7%
if -1.54999999999999988e-104 < z < -2.2499999999999998e-161 or -2.2999999999999999e-204 < z < -1.85000000000000004e-293 or 3.00000000000000021e-174 < z < 7.50000000000000047e-147Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in x around inf 87.7%
metadata-eval87.7%
cancel-sign-sub-inv87.7%
*-commutative87.7%
cancel-sign-sub-inv87.7%
distribute-lft-neg-in87.7%
*-commutative87.7%
distribute-lft-neg-in87.7%
metadata-eval87.7%
sub-neg87.7%
distribute-lft-in87.7%
metadata-eval87.7%
neg-mul-187.7%
*-commutative87.7%
associate-*l*87.7%
associate-+r+87.7%
metadata-eval87.7%
*-commutative87.7%
associate-*l*87.7%
metadata-eval87.7%
Simplified87.7%
Taylor expanded in z around 0 87.7%
*-commutative87.7%
Simplified87.7%
Final simplification65.4%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* -6.0 (* y z))))
(if (<= z -4.2e+215)
(* z (* x 6.0))
(if (<= z -1.26e+144)
t_0
(if (<= z -2.1)
(* x (* z 6.0))
(if (<= z -2.4e-101)
(* y 4.0)
(if (<= z -8.8e-160)
(* x -3.0)
(if (<= z -1.26e-204)
(* y 4.0)
(if (<= z -1.6e-293)
(* x -3.0)
(if (<= z 8.8e-174)
(* y 4.0)
(if (<= z 6.5e-141)
(* x -3.0)
(if (<= z 0.52)
(* y 4.0)
(if (or (<= z 1.1e+60) (not (<= z 9.2e+151)))
(* 6.0 (* x z))
t_0)))))))))))))
double code(double x, double y, double z) {
double t_0 = -6.0 * (y * z);
double tmp;
if (z <= -4.2e+215) {
tmp = z * (x * 6.0);
} else if (z <= -1.26e+144) {
tmp = t_0;
} else if (z <= -2.1) {
tmp = x * (z * 6.0);
} else if (z <= -2.4e-101) {
tmp = y * 4.0;
} else if (z <= -8.8e-160) {
tmp = x * -3.0;
} else if (z <= -1.26e-204) {
tmp = y * 4.0;
} else if (z <= -1.6e-293) {
tmp = x * -3.0;
} else if (z <= 8.8e-174) {
tmp = y * 4.0;
} else if (z <= 6.5e-141) {
tmp = x * -3.0;
} else if (z <= 0.52) {
tmp = y * 4.0;
} else if ((z <= 1.1e+60) || !(z <= 9.2e+151)) {
tmp = 6.0 * (x * z);
} 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 <= (-4.2d+215)) then
tmp = z * (x * 6.0d0)
else if (z <= (-1.26d+144)) then
tmp = t_0
else if (z <= (-2.1d0)) then
tmp = x * (z * 6.0d0)
else if (z <= (-2.4d-101)) then
tmp = y * 4.0d0
else if (z <= (-8.8d-160)) then
tmp = x * (-3.0d0)
else if (z <= (-1.26d-204)) then
tmp = y * 4.0d0
else if (z <= (-1.6d-293)) then
tmp = x * (-3.0d0)
else if (z <= 8.8d-174) then
tmp = y * 4.0d0
else if (z <= 6.5d-141) then
tmp = x * (-3.0d0)
else if (z <= 0.52d0) then
tmp = y * 4.0d0
else if ((z <= 1.1d+60) .or. (.not. (z <= 9.2d+151))) then
tmp = 6.0d0 * (x * z)
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 <= -4.2e+215) {
tmp = z * (x * 6.0);
} else if (z <= -1.26e+144) {
tmp = t_0;
} else if (z <= -2.1) {
tmp = x * (z * 6.0);
} else if (z <= -2.4e-101) {
tmp = y * 4.0;
} else if (z <= -8.8e-160) {
tmp = x * -3.0;
} else if (z <= -1.26e-204) {
tmp = y * 4.0;
} else if (z <= -1.6e-293) {
tmp = x * -3.0;
} else if (z <= 8.8e-174) {
tmp = y * 4.0;
} else if (z <= 6.5e-141) {
tmp = x * -3.0;
} else if (z <= 0.52) {
tmp = y * 4.0;
} else if ((z <= 1.1e+60) || !(z <= 9.2e+151)) {
tmp = 6.0 * (x * z);
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = -6.0 * (y * z) tmp = 0 if z <= -4.2e+215: tmp = z * (x * 6.0) elif z <= -1.26e+144: tmp = t_0 elif z <= -2.1: tmp = x * (z * 6.0) elif z <= -2.4e-101: tmp = y * 4.0 elif z <= -8.8e-160: tmp = x * -3.0 elif z <= -1.26e-204: tmp = y * 4.0 elif z <= -1.6e-293: tmp = x * -3.0 elif z <= 8.8e-174: tmp = y * 4.0 elif z <= 6.5e-141: tmp = x * -3.0 elif z <= 0.52: tmp = y * 4.0 elif (z <= 1.1e+60) or not (z <= 9.2e+151): tmp = 6.0 * (x * z) else: tmp = t_0 return tmp
function code(x, y, z) t_0 = Float64(-6.0 * Float64(y * z)) tmp = 0.0 if (z <= -4.2e+215) tmp = Float64(z * Float64(x * 6.0)); elseif (z <= -1.26e+144) tmp = t_0; elseif (z <= -2.1) tmp = Float64(x * Float64(z * 6.0)); elseif (z <= -2.4e-101) tmp = Float64(y * 4.0); elseif (z <= -8.8e-160) tmp = Float64(x * -3.0); elseif (z <= -1.26e-204) tmp = Float64(y * 4.0); elseif (z <= -1.6e-293) tmp = Float64(x * -3.0); elseif (z <= 8.8e-174) tmp = Float64(y * 4.0); elseif (z <= 6.5e-141) tmp = Float64(x * -3.0); elseif (z <= 0.52) tmp = Float64(y * 4.0); elseif ((z <= 1.1e+60) || !(z <= 9.2e+151)) tmp = Float64(6.0 * Float64(x * z)); 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 <= -4.2e+215) tmp = z * (x * 6.0); elseif (z <= -1.26e+144) tmp = t_0; elseif (z <= -2.1) tmp = x * (z * 6.0); elseif (z <= -2.4e-101) tmp = y * 4.0; elseif (z <= -8.8e-160) tmp = x * -3.0; elseif (z <= -1.26e-204) tmp = y * 4.0; elseif (z <= -1.6e-293) tmp = x * -3.0; elseif (z <= 8.8e-174) tmp = y * 4.0; elseif (z <= 6.5e-141) tmp = x * -3.0; elseif (z <= 0.52) tmp = y * 4.0; elseif ((z <= 1.1e+60) || ~((z <= 9.2e+151))) tmp = 6.0 * (x * z); 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, -4.2e+215], N[(z * N[(x * 6.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -1.26e+144], t$95$0, If[LessEqual[z, -2.1], N[(x * N[(z * 6.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, -2.4e-101], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, -8.8e-160], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, -1.26e-204], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, -1.6e-293], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 8.8e-174], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 6.5e-141], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 0.52], N[(y * 4.0), $MachinePrecision], If[Or[LessEqual[z, 1.1e+60], N[Not[LessEqual[z, 9.2e+151]], $MachinePrecision]], N[(6.0 * N[(x * z), $MachinePrecision]), $MachinePrecision], t$95$0]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := -6 \cdot \left(y \cdot z\right)\\
\mathbf{if}\;z \leq -4.2 \cdot 10^{+215}:\\
\;\;\;\;z \cdot \left(x \cdot 6\right)\\
\mathbf{elif}\;z \leq -1.26 \cdot 10^{+144}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -2.1:\\
\;\;\;\;x \cdot \left(z \cdot 6\right)\\
\mathbf{elif}\;z \leq -2.4 \cdot 10^{-101}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq -8.8 \cdot 10^{-160}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq -1.26 \cdot 10^{-204}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq -1.6 \cdot 10^{-293}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 8.8 \cdot 10^{-174}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 6.5 \cdot 10^{-141}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 0.52:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 1.1 \cdot 10^{+60} \lor \neg \left(z \leq 9.2 \cdot 10^{+151}\right):\\
\;\;\;\;6 \cdot \left(x \cdot z\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if z < -4.2000000000000003e215Initial program 100.0%
metadata-eval100.0%
Simplified100.0%
Taylor expanded in x around inf 80.2%
metadata-eval80.2%
cancel-sign-sub-inv80.2%
*-commutative80.2%
cancel-sign-sub-inv80.2%
distribute-lft-neg-in80.2%
*-commutative80.2%
distribute-lft-neg-in80.2%
metadata-eval80.2%
sub-neg80.2%
distribute-lft-in80.2%
metadata-eval80.2%
neg-mul-180.2%
*-commutative80.2%
associate-*l*80.2%
associate-+r+80.2%
metadata-eval80.2%
*-commutative80.2%
associate-*l*80.2%
metadata-eval80.2%
Simplified80.2%
Taylor expanded in z around inf 80.2%
Taylor expanded in x around 0 80.2%
*-commutative80.2%
*-commutative80.2%
associate-*r*80.3%
*-commutative80.3%
Simplified80.3%
if -4.2000000000000003e215 < z < -1.26000000000000001e144 or 1.09999999999999998e60 < z < 9.2000000000000003e151Initial program 99.6%
metadata-eval99.6%
Simplified99.6%
Taylor expanded in z around inf 99.6%
Taylor expanded in z around inf 99.7%
Taylor expanded in y around inf 69.1%
*-commutative69.1%
Simplified69.1%
if -1.26000000000000001e144 < z < -2.10000000000000009Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around inf 63.5%
metadata-eval63.5%
cancel-sign-sub-inv63.5%
*-commutative63.5%
cancel-sign-sub-inv63.5%
distribute-lft-neg-in63.5%
*-commutative63.5%
distribute-lft-neg-in63.5%
metadata-eval63.5%
sub-neg63.5%
distribute-lft-in63.6%
metadata-eval63.6%
neg-mul-163.6%
*-commutative63.6%
associate-*l*63.6%
associate-+r+63.6%
metadata-eval63.6%
*-commutative63.6%
associate-*l*63.6%
metadata-eval63.6%
Simplified63.6%
Taylor expanded in z around inf 55.4%
if -2.10000000000000009 < z < -2.4e-101 or -8.8e-160 < z < -1.26e-204 or -1.60000000000000003e-293 < z < 8.80000000000000086e-174 or 6.4999999999999995e-141 < z < 0.52000000000000002Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in z around 0 95.7%
Taylor expanded in y around inf 84.0%
distribute-lft1-in84.8%
metadata-eval84.8%
Simplified84.8%
Taylor expanded in y around inf 59.7%
*-commutative59.7%
Simplified59.7%
if -2.4e-101 < z < -8.8e-160 or -1.26e-204 < z < -1.60000000000000003e-293 or 8.80000000000000086e-174 < z < 6.4999999999999995e-141Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in x around inf 87.7%
metadata-eval87.7%
cancel-sign-sub-inv87.7%
*-commutative87.7%
cancel-sign-sub-inv87.7%
distribute-lft-neg-in87.7%
*-commutative87.7%
distribute-lft-neg-in87.7%
metadata-eval87.7%
sub-neg87.7%
distribute-lft-in87.7%
metadata-eval87.7%
neg-mul-187.7%
*-commutative87.7%
associate-*l*87.7%
associate-+r+87.7%
metadata-eval87.7%
*-commutative87.7%
associate-*l*87.7%
metadata-eval87.7%
Simplified87.7%
Taylor expanded in z around 0 87.7%
*-commutative87.7%
Simplified87.7%
if 0.52000000000000002 < z < 1.09999999999999998e60 or 9.2000000000000003e151 < z Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around inf 68.1%
metadata-eval68.1%
cancel-sign-sub-inv68.1%
*-commutative68.1%
cancel-sign-sub-inv68.1%
distribute-lft-neg-in68.1%
*-commutative68.1%
distribute-lft-neg-in68.1%
metadata-eval68.1%
sub-neg68.1%
distribute-lft-in68.1%
metadata-eval68.1%
neg-mul-168.1%
*-commutative68.1%
associate-*l*68.1%
associate-+r+68.1%
metadata-eval68.1%
*-commutative68.1%
associate-*l*68.1%
metadata-eval68.1%
Simplified68.1%
Taylor expanded in z around inf 62.0%
*-commutative62.0%
Simplified62.0%
Final simplification65.4%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* x (+ -3.0 (* z 6.0)))) (t_1 (* -6.0 (* (- y x) z))))
(if (<= z -480000.0)
t_1
(if (<= z -1.76e-42)
t_0
(if (<= z -2.75e-102)
(* y 4.0)
(if (<= z -1.15e-161)
(* x -3.0)
(if (<= z -1.8e-204)
(* y 4.0)
(if (<= z -5.1e-294)
(* x -3.0)
(if (<= z 2.95e-173)
(* y 4.0)
(if (<= z 9.2e-151)
(* x -3.0)
(if (<= z 1.8e-32)
(* y 4.0)
(if (<= z 12000000000000.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 = -6.0 * ((y - x) * z);
double tmp;
if (z <= -480000.0) {
tmp = t_1;
} else if (z <= -1.76e-42) {
tmp = t_0;
} else if (z <= -2.75e-102) {
tmp = y * 4.0;
} else if (z <= -1.15e-161) {
tmp = x * -3.0;
} else if (z <= -1.8e-204) {
tmp = y * 4.0;
} else if (z <= -5.1e-294) {
tmp = x * -3.0;
} else if (z <= 2.95e-173) {
tmp = y * 4.0;
} else if (z <= 9.2e-151) {
tmp = x * -3.0;
} else if (z <= 1.8e-32) {
tmp = y * 4.0;
} else if (z <= 12000000000000.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 = (-6.0d0) * ((y - x) * z)
if (z <= (-480000.0d0)) then
tmp = t_1
else if (z <= (-1.76d-42)) then
tmp = t_0
else if (z <= (-2.75d-102)) then
tmp = y * 4.0d0
else if (z <= (-1.15d-161)) then
tmp = x * (-3.0d0)
else if (z <= (-1.8d-204)) then
tmp = y * 4.0d0
else if (z <= (-5.1d-294)) then
tmp = x * (-3.0d0)
else if (z <= 2.95d-173) then
tmp = y * 4.0d0
else if (z <= 9.2d-151) then
tmp = x * (-3.0d0)
else if (z <= 1.8d-32) then
tmp = y * 4.0d0
else if (z <= 12000000000000.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 = -6.0 * ((y - x) * z);
double tmp;
if (z <= -480000.0) {
tmp = t_1;
} else if (z <= -1.76e-42) {
tmp = t_0;
} else if (z <= -2.75e-102) {
tmp = y * 4.0;
} else if (z <= -1.15e-161) {
tmp = x * -3.0;
} else if (z <= -1.8e-204) {
tmp = y * 4.0;
} else if (z <= -5.1e-294) {
tmp = x * -3.0;
} else if (z <= 2.95e-173) {
tmp = y * 4.0;
} else if (z <= 9.2e-151) {
tmp = x * -3.0;
} else if (z <= 1.8e-32) {
tmp = y * 4.0;
} else if (z <= 12000000000000.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 = -6.0 * ((y - x) * z) tmp = 0 if z <= -480000.0: tmp = t_1 elif z <= -1.76e-42: tmp = t_0 elif z <= -2.75e-102: tmp = y * 4.0 elif z <= -1.15e-161: tmp = x * -3.0 elif z <= -1.8e-204: tmp = y * 4.0 elif z <= -5.1e-294: tmp = x * -3.0 elif z <= 2.95e-173: tmp = y * 4.0 elif z <= 9.2e-151: tmp = x * -3.0 elif z <= 1.8e-32: tmp = y * 4.0 elif z <= 12000000000000.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(-6.0 * Float64(Float64(y - x) * z)) tmp = 0.0 if (z <= -480000.0) tmp = t_1; elseif (z <= -1.76e-42) tmp = t_0; elseif (z <= -2.75e-102) tmp = Float64(y * 4.0); elseif (z <= -1.15e-161) tmp = Float64(x * -3.0); elseif (z <= -1.8e-204) tmp = Float64(y * 4.0); elseif (z <= -5.1e-294) tmp = Float64(x * -3.0); elseif (z <= 2.95e-173) tmp = Float64(y * 4.0); elseif (z <= 9.2e-151) tmp = Float64(x * -3.0); elseif (z <= 1.8e-32) tmp = Float64(y * 4.0); elseif (z <= 12000000000000.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 = -6.0 * ((y - x) * z); tmp = 0.0; if (z <= -480000.0) tmp = t_1; elseif (z <= -1.76e-42) tmp = t_0; elseif (z <= -2.75e-102) tmp = y * 4.0; elseif (z <= -1.15e-161) tmp = x * -3.0; elseif (z <= -1.8e-204) tmp = y * 4.0; elseif (z <= -5.1e-294) tmp = x * -3.0; elseif (z <= 2.95e-173) tmp = y * 4.0; elseif (z <= 9.2e-151) tmp = x * -3.0; elseif (z <= 1.8e-32) tmp = y * 4.0; elseif (z <= 12000000000000.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[(-6.0 * N[(N[(y - x), $MachinePrecision] * z), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[z, -480000.0], t$95$1, If[LessEqual[z, -1.76e-42], t$95$0, If[LessEqual[z, -2.75e-102], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, -1.15e-161], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, -1.8e-204], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, -5.1e-294], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 2.95e-173], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 9.2e-151], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 1.8e-32], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 12000000000000.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 := -6 \cdot \left(\left(y - x\right) \cdot z\right)\\
\mathbf{if}\;z \leq -480000:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;z \leq -1.76 \cdot 10^{-42}:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -2.75 \cdot 10^{-102}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq -1.15 \cdot 10^{-161}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq -1.8 \cdot 10^{-204}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq -5.1 \cdot 10^{-294}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 2.95 \cdot 10^{-173}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 9.2 \cdot 10^{-151}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 1.8 \cdot 10^{-32}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 12000000000000:\\
\;\;\;\;t\_0\\
\mathbf{else}:\\
\;\;\;\;t\_1\\
\end{array}
\end{array}
if z < -4.8e5 or 1.2e13 < z Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in z around inf 99.7%
Taylor expanded in z around inf 99.8%
if -4.8e5 < z < -1.75999999999999998e-42 or 1.79999999999999996e-32 < z < 1.2e13Initial program 98.9%
metadata-eval98.9%
Simplified98.9%
Taylor expanded in x around inf 82.3%
metadata-eval82.3%
cancel-sign-sub-inv82.3%
*-commutative82.3%
cancel-sign-sub-inv82.3%
distribute-lft-neg-in82.3%
*-commutative82.3%
distribute-lft-neg-in82.3%
metadata-eval82.3%
sub-neg82.3%
distribute-lft-in82.5%
metadata-eval82.5%
neg-mul-182.5%
*-commutative82.5%
associate-*l*82.5%
associate-+r+82.5%
metadata-eval82.5%
*-commutative82.5%
associate-*l*82.5%
metadata-eval82.5%
Simplified82.5%
if -1.75999999999999998e-42 < z < -2.7499999999999999e-102 or -1.15e-161 < z < -1.79999999999999982e-204 or -5.10000000000000007e-294 < z < 2.94999999999999998e-173 or 9.19999999999999984e-151 < z < 1.79999999999999996e-32Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 99.5%
Taylor expanded in y around inf 89.0%
distribute-lft1-in89.8%
metadata-eval89.8%
Simplified89.8%
Taylor expanded in y around inf 66.1%
*-commutative66.1%
Simplified66.1%
if -2.7499999999999999e-102 < z < -1.15e-161 or -1.79999999999999982e-204 < z < -5.10000000000000007e-294 or 2.94999999999999998e-173 < z < 9.19999999999999984e-151Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in x around inf 87.7%
metadata-eval87.7%
cancel-sign-sub-inv87.7%
*-commutative87.7%
cancel-sign-sub-inv87.7%
distribute-lft-neg-in87.7%
*-commutative87.7%
distribute-lft-neg-in87.7%
metadata-eval87.7%
sub-neg87.7%
distribute-lft-in87.7%
metadata-eval87.7%
neg-mul-187.7%
*-commutative87.7%
associate-*l*87.7%
associate-+r+87.7%
metadata-eval87.7%
*-commutative87.7%
associate-*l*87.7%
metadata-eval87.7%
Simplified87.7%
Taylor expanded in z around 0 87.7%
*-commutative87.7%
Simplified87.7%
Final simplification84.9%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* -6.0 (* (- y x) z))))
(if (<= z -0.023)
t_0
(if (<= z -1.25e-101)
(* y 4.0)
(if (<= z -5.2e-162)
(* x -3.0)
(if (<= z -1.18e-204)
(* y 4.0)
(if (<= z -5.2e-293)
(* x -3.0)
(if (<= z 1.6e-173)
(* y 4.0)
(if (<= z 2.2e-143)
(* x -3.0)
(if (<= z 0.52) (* y 4.0) t_0))))))))))
double code(double x, double y, double z) {
double t_0 = -6.0 * ((y - x) * z);
double tmp;
if (z <= -0.023) {
tmp = t_0;
} else if (z <= -1.25e-101) {
tmp = y * 4.0;
} else if (z <= -5.2e-162) {
tmp = x * -3.0;
} else if (z <= -1.18e-204) {
tmp = y * 4.0;
} else if (z <= -5.2e-293) {
tmp = x * -3.0;
} else if (z <= 1.6e-173) {
tmp = y * 4.0;
} else if (z <= 2.2e-143) {
tmp = x * -3.0;
} else if (z <= 0.52) {
tmp = y * 4.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.023d0)) then
tmp = t_0
else if (z <= (-1.25d-101)) then
tmp = y * 4.0d0
else if (z <= (-5.2d-162)) then
tmp = x * (-3.0d0)
else if (z <= (-1.18d-204)) then
tmp = y * 4.0d0
else if (z <= (-5.2d-293)) then
tmp = x * (-3.0d0)
else if (z <= 1.6d-173) then
tmp = y * 4.0d0
else if (z <= 2.2d-143) then
tmp = x * (-3.0d0)
else if (z <= 0.52d0) then
tmp = y * 4.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.023) {
tmp = t_0;
} else if (z <= -1.25e-101) {
tmp = y * 4.0;
} else if (z <= -5.2e-162) {
tmp = x * -3.0;
} else if (z <= -1.18e-204) {
tmp = y * 4.0;
} else if (z <= -5.2e-293) {
tmp = x * -3.0;
} else if (z <= 1.6e-173) {
tmp = y * 4.0;
} else if (z <= 2.2e-143) {
tmp = x * -3.0;
} else if (z <= 0.52) {
tmp = y * 4.0;
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = -6.0 * ((y - x) * z) tmp = 0 if z <= -0.023: tmp = t_0 elif z <= -1.25e-101: tmp = y * 4.0 elif z <= -5.2e-162: tmp = x * -3.0 elif z <= -1.18e-204: tmp = y * 4.0 elif z <= -5.2e-293: tmp = x * -3.0 elif z <= 1.6e-173: tmp = y * 4.0 elif z <= 2.2e-143: tmp = x * -3.0 elif z <= 0.52: tmp = y * 4.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.023) tmp = t_0; elseif (z <= -1.25e-101) tmp = Float64(y * 4.0); elseif (z <= -5.2e-162) tmp = Float64(x * -3.0); elseif (z <= -1.18e-204) tmp = Float64(y * 4.0); elseif (z <= -5.2e-293) tmp = Float64(x * -3.0); elseif (z <= 1.6e-173) tmp = Float64(y * 4.0); elseif (z <= 2.2e-143) tmp = Float64(x * -3.0); elseif (z <= 0.52) tmp = Float64(y * 4.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.023) tmp = t_0; elseif (z <= -1.25e-101) tmp = y * 4.0; elseif (z <= -5.2e-162) tmp = x * -3.0; elseif (z <= -1.18e-204) tmp = y * 4.0; elseif (z <= -5.2e-293) tmp = x * -3.0; elseif (z <= 1.6e-173) tmp = y * 4.0; elseif (z <= 2.2e-143) tmp = x * -3.0; elseif (z <= 0.52) tmp = y * 4.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.023], t$95$0, If[LessEqual[z, -1.25e-101], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, -5.2e-162], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, -1.18e-204], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, -5.2e-293], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 1.6e-173], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 2.2e-143], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 0.52], N[(y * 4.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.023:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -1.25 \cdot 10^{-101}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq -5.2 \cdot 10^{-162}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq -1.18 \cdot 10^{-204}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq -5.2 \cdot 10^{-293}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 1.6 \cdot 10^{-173}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 2.2 \cdot 10^{-143}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 0.52:\\
\;\;\;\;y \cdot 4\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if z < -0.023 or 0.52000000000000002 < z Initial program 99.6%
metadata-eval99.6%
Simplified99.6%
Taylor expanded in z around inf 99.6%
Taylor expanded in z around inf 96.1%
if -0.023 < z < -1.25e-101 or -5.1999999999999999e-162 < z < -1.17999999999999995e-204 or -5.1999999999999996e-293 < z < 1.6e-173 or 2.19999999999999989e-143 < z < 0.52000000000000002Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in z around 0 95.7%
Taylor expanded in y around inf 84.0%
distribute-lft1-in84.8%
metadata-eval84.8%
Simplified84.8%
Taylor expanded in y around inf 59.7%
*-commutative59.7%
Simplified59.7%
if -1.25e-101 < z < -5.1999999999999999e-162 or -1.17999999999999995e-204 < z < -5.1999999999999996e-293 or 1.6e-173 < z < 2.19999999999999989e-143Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in x around inf 87.7%
metadata-eval87.7%
cancel-sign-sub-inv87.7%
*-commutative87.7%
cancel-sign-sub-inv87.7%
distribute-lft-neg-in87.7%
*-commutative87.7%
distribute-lft-neg-in87.7%
metadata-eval87.7%
sub-neg87.7%
distribute-lft-in87.7%
metadata-eval87.7%
neg-mul-187.7%
*-commutative87.7%
associate-*l*87.7%
associate-+r+87.7%
metadata-eval87.7%
*-commutative87.7%
associate-*l*87.7%
metadata-eval87.7%
Simplified87.7%
Taylor expanded in z around 0 87.7%
*-commutative87.7%
Simplified87.7%
Final simplification80.1%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* -6.0 (* y z))))
(if (<= z -0.66)
t_0
(if (<= z -2.9e-103)
(* y 4.0)
(if (<= z -1.65e-160)
(* x -3.0)
(if (<= z -1.9e-204)
(* y 4.0)
(if (<= z -1.15e-292)
(* x -3.0)
(if (<= z 1.9e-174)
(* y 4.0)
(if (<= z 8e-145)
(* x -3.0)
(if (<= z 0.66) (* y 4.0) t_0))))))))))
double code(double x, double y, double z) {
double t_0 = -6.0 * (y * z);
double tmp;
if (z <= -0.66) {
tmp = t_0;
} else if (z <= -2.9e-103) {
tmp = y * 4.0;
} else if (z <= -1.65e-160) {
tmp = x * -3.0;
} else if (z <= -1.9e-204) {
tmp = y * 4.0;
} else if (z <= -1.15e-292) {
tmp = x * -3.0;
} else if (z <= 1.9e-174) {
tmp = y * 4.0;
} else if (z <= 8e-145) {
tmp = x * -3.0;
} else if (z <= 0.66) {
tmp = y * 4.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.66d0)) then
tmp = t_0
else if (z <= (-2.9d-103)) then
tmp = y * 4.0d0
else if (z <= (-1.65d-160)) then
tmp = x * (-3.0d0)
else if (z <= (-1.9d-204)) then
tmp = y * 4.0d0
else if (z <= (-1.15d-292)) then
tmp = x * (-3.0d0)
else if (z <= 1.9d-174) then
tmp = y * 4.0d0
else if (z <= 8d-145) then
tmp = x * (-3.0d0)
else if (z <= 0.66d0) then
tmp = y * 4.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.66) {
tmp = t_0;
} else if (z <= -2.9e-103) {
tmp = y * 4.0;
} else if (z <= -1.65e-160) {
tmp = x * -3.0;
} else if (z <= -1.9e-204) {
tmp = y * 4.0;
} else if (z <= -1.15e-292) {
tmp = x * -3.0;
} else if (z <= 1.9e-174) {
tmp = y * 4.0;
} else if (z <= 8e-145) {
tmp = x * -3.0;
} else if (z <= 0.66) {
tmp = y * 4.0;
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = -6.0 * (y * z) tmp = 0 if z <= -0.66: tmp = t_0 elif z <= -2.9e-103: tmp = y * 4.0 elif z <= -1.65e-160: tmp = x * -3.0 elif z <= -1.9e-204: tmp = y * 4.0 elif z <= -1.15e-292: tmp = x * -3.0 elif z <= 1.9e-174: tmp = y * 4.0 elif z <= 8e-145: tmp = x * -3.0 elif z <= 0.66: tmp = y * 4.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.66) tmp = t_0; elseif (z <= -2.9e-103) tmp = Float64(y * 4.0); elseif (z <= -1.65e-160) tmp = Float64(x * -3.0); elseif (z <= -1.9e-204) tmp = Float64(y * 4.0); elseif (z <= -1.15e-292) tmp = Float64(x * -3.0); elseif (z <= 1.9e-174) tmp = Float64(y * 4.0); elseif (z <= 8e-145) tmp = Float64(x * -3.0); elseif (z <= 0.66) tmp = Float64(y * 4.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.66) tmp = t_0; elseif (z <= -2.9e-103) tmp = y * 4.0; elseif (z <= -1.65e-160) tmp = x * -3.0; elseif (z <= -1.9e-204) tmp = y * 4.0; elseif (z <= -1.15e-292) tmp = x * -3.0; elseif (z <= 1.9e-174) tmp = y * 4.0; elseif (z <= 8e-145) tmp = x * -3.0; elseif (z <= 0.66) tmp = y * 4.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.66], t$95$0, If[LessEqual[z, -2.9e-103], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, -1.65e-160], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, -1.9e-204], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, -1.15e-292], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 1.9e-174], N[(y * 4.0), $MachinePrecision], If[LessEqual[z, 8e-145], N[(x * -3.0), $MachinePrecision], If[LessEqual[z, 0.66], N[(y * 4.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.66:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq -2.9 \cdot 10^{-103}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq -1.65 \cdot 10^{-160}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq -1.9 \cdot 10^{-204}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq -1.15 \cdot 10^{-292}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 1.9 \cdot 10^{-174}:\\
\;\;\;\;y \cdot 4\\
\mathbf{elif}\;z \leq 8 \cdot 10^{-145}:\\
\;\;\;\;x \cdot -3\\
\mathbf{elif}\;z \leq 0.66:\\
\;\;\;\;y \cdot 4\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if z < -0.660000000000000031 or 0.660000000000000031 < z Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in z around inf 99.6%
Taylor expanded in z around inf 96.8%
Taylor expanded in y around inf 44.7%
*-commutative44.7%
Simplified44.7%
if -0.660000000000000031 < z < -2.8999999999999999e-103 or -1.65e-160 < z < -1.89999999999999991e-204 or -1.1499999999999999e-292 < z < 1.9000000000000001e-174 or 7.99999999999999932e-145 < z < 0.660000000000000031Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in z around 0 94.8%
Taylor expanded in y around inf 83.2%
distribute-lft1-in84.0%
metadata-eval84.0%
Simplified84.0%
Taylor expanded in y around inf 59.2%
*-commutative59.2%
Simplified59.2%
if -2.8999999999999999e-103 < z < -1.65e-160 or -1.89999999999999991e-204 < z < -1.1499999999999999e-292 or 1.9000000000000001e-174 < z < 7.99999999999999932e-145Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in x around inf 87.7%
metadata-eval87.7%
cancel-sign-sub-inv87.7%
*-commutative87.7%
cancel-sign-sub-inv87.7%
distribute-lft-neg-in87.7%
*-commutative87.7%
distribute-lft-neg-in87.7%
metadata-eval87.7%
sub-neg87.7%
distribute-lft-in87.7%
metadata-eval87.7%
neg-mul-187.7%
*-commutative87.7%
associate-*l*87.7%
associate-+r+87.7%
metadata-eval87.7%
*-commutative87.7%
associate-*l*87.7%
metadata-eval87.7%
Simplified87.7%
Taylor expanded in z around 0 87.7%
*-commutative87.7%
Simplified87.7%
Final simplification54.8%
(FPCore (x y z)
:precision binary64
(if (or (<= x -8.5e+39)
(not
(or (<= x 5.6e-74)
(and (not (<= x 24000000000.0)) (<= x 9.8e+104)))))
(* x (+ -3.0 (* z 6.0)))
(* y (+ 4.0 (* z -6.0)))))
double code(double x, double y, double z) {
double tmp;
if ((x <= -8.5e+39) || !((x <= 5.6e-74) || (!(x <= 24000000000.0) && (x <= 9.8e+104)))) {
tmp = x * (-3.0 + (z * 6.0));
} else {
tmp = y * (4.0 + (z * -6.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 <= (-8.5d+39)) .or. (.not. (x <= 5.6d-74) .or. (.not. (x <= 24000000000.0d0)) .and. (x <= 9.8d+104))) then
tmp = x * ((-3.0d0) + (z * 6.0d0))
else
tmp = y * (4.0d0 + (z * (-6.0d0)))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((x <= -8.5e+39) || !((x <= 5.6e-74) || (!(x <= 24000000000.0) && (x <= 9.8e+104)))) {
tmp = x * (-3.0 + (z * 6.0));
} else {
tmp = y * (4.0 + (z * -6.0));
}
return tmp;
}
def code(x, y, z): tmp = 0 if (x <= -8.5e+39) or not ((x <= 5.6e-74) or (not (x <= 24000000000.0) and (x <= 9.8e+104))): tmp = x * (-3.0 + (z * 6.0)) else: tmp = y * (4.0 + (z * -6.0)) return tmp
function code(x, y, z) tmp = 0.0 if ((x <= -8.5e+39) || !((x <= 5.6e-74) || (!(x <= 24000000000.0) && (x <= 9.8e+104)))) tmp = Float64(x * Float64(-3.0 + Float64(z * 6.0))); else tmp = Float64(y * Float64(4.0 + Float64(z * -6.0))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((x <= -8.5e+39) || ~(((x <= 5.6e-74) || (~((x <= 24000000000.0)) && (x <= 9.8e+104))))) tmp = x * (-3.0 + (z * 6.0)); else tmp = y * (4.0 + (z * -6.0)); end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[x, -8.5e+39], N[Not[Or[LessEqual[x, 5.6e-74], And[N[Not[LessEqual[x, 24000000000.0]], $MachinePrecision], LessEqual[x, 9.8e+104]]]], $MachinePrecision]], N[(x * N[(-3.0 + N[(z * 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(y * N[(4.0 + N[(z * -6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -8.5 \cdot 10^{+39} \lor \neg \left(x \leq 5.6 \cdot 10^{-74} \lor \neg \left(x \leq 24000000000\right) \land x \leq 9.8 \cdot 10^{+104}\right):\\
\;\;\;\;x \cdot \left(-3 + z \cdot 6\right)\\
\mathbf{else}:\\
\;\;\;\;y \cdot \left(4 + z \cdot -6\right)\\
\end{array}
\end{array}
if x < -8.49999999999999971e39 or 5.59999999999999976e-74 < x < 2.4e10 or 9.7999999999999997e104 < x Initial program 99.4%
metadata-eval99.4%
Simplified99.4%
Taylor expanded in x around inf 86.2%
metadata-eval86.2%
cancel-sign-sub-inv86.2%
*-commutative86.2%
cancel-sign-sub-inv86.2%
distribute-lft-neg-in86.2%
*-commutative86.2%
distribute-lft-neg-in86.2%
metadata-eval86.2%
sub-neg86.2%
distribute-lft-in86.3%
metadata-eval86.3%
neg-mul-186.3%
*-commutative86.3%
associate-*l*86.3%
associate-+r+86.3%
metadata-eval86.3%
*-commutative86.3%
associate-*l*86.3%
metadata-eval86.3%
Simplified86.3%
if -8.49999999999999971e39 < x < 5.59999999999999976e-74 or 2.4e10 < x < 9.7999999999999997e104Initial program 99.6%
+-commutative99.6%
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 78.7%
Final simplification82.4%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* -6.0 (* (- y x) z))))
(if (<= z -0.58)
t_0
(if (<= z 1.02e-8)
(+ (* y 4.0) (* x -3.0))
(if (<= z 12000000000000.0) (* z (* x (- 6.0 (/ 3.0 z)))) t_0)))))
double code(double x, double y, double z) {
double t_0 = -6.0 * ((y - x) * z);
double tmp;
if (z <= -0.58) {
tmp = t_0;
} else if (z <= 1.02e-8) {
tmp = (y * 4.0) + (x * -3.0);
} else if (z <= 12000000000000.0) {
tmp = z * (x * (6.0 - (3.0 / z)));
} 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.58d0)) then
tmp = t_0
else if (z <= 1.02d-8) then
tmp = (y * 4.0d0) + (x * (-3.0d0))
else if (z <= 12000000000000.0d0) then
tmp = z * (x * (6.0d0 - (3.0d0 / z)))
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.58) {
tmp = t_0;
} else if (z <= 1.02e-8) {
tmp = (y * 4.0) + (x * -3.0);
} else if (z <= 12000000000000.0) {
tmp = z * (x * (6.0 - (3.0 / z)));
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = -6.0 * ((y - x) * z) tmp = 0 if z <= -0.58: tmp = t_0 elif z <= 1.02e-8: tmp = (y * 4.0) + (x * -3.0) elif z <= 12000000000000.0: tmp = z * (x * (6.0 - (3.0 / z))) 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.58) tmp = t_0; elseif (z <= 1.02e-8) tmp = Float64(Float64(y * 4.0) + Float64(x * -3.0)); elseif (z <= 12000000000000.0) tmp = Float64(z * Float64(x * Float64(6.0 - Float64(3.0 / z)))); 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.58) tmp = t_0; elseif (z <= 1.02e-8) tmp = (y * 4.0) + (x * -3.0); elseif (z <= 12000000000000.0) tmp = z * (x * (6.0 - (3.0 / z))); 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.58], t$95$0, If[LessEqual[z, 1.02e-8], N[(N[(y * 4.0), $MachinePrecision] + N[(x * -3.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 12000000000000.0], N[(z * N[(x * N[(6.0 - N[(3.0 / z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $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.58:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq 1.02 \cdot 10^{-8}:\\
\;\;\;\;y \cdot 4 + x \cdot -3\\
\mathbf{elif}\;z \leq 12000000000000:\\
\;\;\;\;z \cdot \left(x \cdot \left(6 - \frac{3}{z}\right)\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if z < -0.57999999999999996 or 1.2e13 < z Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in z around inf 99.7%
Taylor expanded in z around inf 98.1%
if -0.57999999999999996 < z < 1.02000000000000003e-8Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 98.4%
Taylor expanded in x around 0 98.8%
if 1.02000000000000003e-8 < z < 1.2e13Initial program 98.4%
metadata-eval98.4%
Simplified98.4%
Taylor expanded in z around inf 99.0%
Taylor expanded in x around inf 90.2%
associate-*r/90.4%
metadata-eval90.4%
Simplified90.4%
Final simplification98.1%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* -6.0 (* (- y x) z))))
(if (<= z -0.54)
t_0
(if (<= z 2.4e-9)
(+ x (* (- y x) 4.0))
(if (<= z 12000000000000.0) (* x (+ -3.0 (* z 6.0))) t_0)))))
double code(double x, double y, double z) {
double t_0 = -6.0 * ((y - x) * z);
double tmp;
if (z <= -0.54) {
tmp = t_0;
} else if (z <= 2.4e-9) {
tmp = x + ((y - x) * 4.0);
} else if (z <= 12000000000000.0) {
tmp = x * (-3.0 + (z * 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 = (-6.0d0) * ((y - x) * z)
if (z <= (-0.54d0)) then
tmp = t_0
else if (z <= 2.4d-9) then
tmp = x + ((y - x) * 4.0d0)
else if (z <= 12000000000000.0d0) then
tmp = x * ((-3.0d0) + (z * 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 = -6.0 * ((y - x) * z);
double tmp;
if (z <= -0.54) {
tmp = t_0;
} else if (z <= 2.4e-9) {
tmp = x + ((y - x) * 4.0);
} else if (z <= 12000000000000.0) {
tmp = x * (-3.0 + (z * 6.0));
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = -6.0 * ((y - x) * z) tmp = 0 if z <= -0.54: tmp = t_0 elif z <= 2.4e-9: tmp = x + ((y - x) * 4.0) elif z <= 12000000000000.0: tmp = x * (-3.0 + (z * 6.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.54) tmp = t_0; elseif (z <= 2.4e-9) tmp = Float64(x + Float64(Float64(y - x) * 4.0)); elseif (z <= 12000000000000.0) tmp = Float64(x * Float64(-3.0 + Float64(z * 6.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.54) tmp = t_0; elseif (z <= 2.4e-9) tmp = x + ((y - x) * 4.0); elseif (z <= 12000000000000.0) tmp = x * (-3.0 + (z * 6.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.54], t$95$0, If[LessEqual[z, 2.4e-9], N[(x + N[(N[(y - x), $MachinePrecision] * 4.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 12000000000000.0], N[(x * N[(-3.0 + N[(z * 6.0), $MachinePrecision]), $MachinePrecision]), $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.54:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq 2.4 \cdot 10^{-9}:\\
\;\;\;\;x + \left(y - x\right) \cdot 4\\
\mathbf{elif}\;z \leq 12000000000000:\\
\;\;\;\;x \cdot \left(-3 + z \cdot 6\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if z < -0.54000000000000004 or 1.2e13 < z Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in z around inf 99.7%
Taylor expanded in z around inf 98.1%
if -0.54000000000000004 < z < 2.4e-9Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 98.8%
if 2.4e-9 < z < 1.2e13Initial program 98.4%
metadata-eval98.4%
Simplified98.4%
Taylor expanded in x around inf 89.9%
metadata-eval89.9%
cancel-sign-sub-inv89.9%
*-commutative89.9%
cancel-sign-sub-inv89.9%
distribute-lft-neg-in89.9%
*-commutative89.9%
distribute-lft-neg-in89.9%
metadata-eval89.9%
sub-neg89.9%
distribute-lft-in90.3%
metadata-eval90.3%
neg-mul-190.3%
*-commutative90.3%
associate-*l*90.3%
associate-+r+90.3%
metadata-eval90.3%
*-commutative90.3%
associate-*l*90.3%
metadata-eval90.3%
Simplified90.3%
Final simplification98.1%
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* -6.0 (* (- y x) z))))
(if (<= z -0.58)
t_0
(if (<= z 4e-9)
(+ (* y 4.0) (* x -3.0))
(if (<= z 12000000000000.0) (* x (+ -3.0 (* z 6.0))) t_0)))))
double code(double x, double y, double z) {
double t_0 = -6.0 * ((y - x) * z);
double tmp;
if (z <= -0.58) {
tmp = t_0;
} else if (z <= 4e-9) {
tmp = (y * 4.0) + (x * -3.0);
} else if (z <= 12000000000000.0) {
tmp = x * (-3.0 + (z * 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 = (-6.0d0) * ((y - x) * z)
if (z <= (-0.58d0)) then
tmp = t_0
else if (z <= 4d-9) then
tmp = (y * 4.0d0) + (x * (-3.0d0))
else if (z <= 12000000000000.0d0) then
tmp = x * ((-3.0d0) + (z * 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 = -6.0 * ((y - x) * z);
double tmp;
if (z <= -0.58) {
tmp = t_0;
} else if (z <= 4e-9) {
tmp = (y * 4.0) + (x * -3.0);
} else if (z <= 12000000000000.0) {
tmp = x * (-3.0 + (z * 6.0));
} else {
tmp = t_0;
}
return tmp;
}
def code(x, y, z): t_0 = -6.0 * ((y - x) * z) tmp = 0 if z <= -0.58: tmp = t_0 elif z <= 4e-9: tmp = (y * 4.0) + (x * -3.0) elif z <= 12000000000000.0: tmp = x * (-3.0 + (z * 6.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.58) tmp = t_0; elseif (z <= 4e-9) tmp = Float64(Float64(y * 4.0) + Float64(x * -3.0)); elseif (z <= 12000000000000.0) tmp = Float64(x * Float64(-3.0 + Float64(z * 6.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.58) tmp = t_0; elseif (z <= 4e-9) tmp = (y * 4.0) + (x * -3.0); elseif (z <= 12000000000000.0) tmp = x * (-3.0 + (z * 6.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.58], t$95$0, If[LessEqual[z, 4e-9], N[(N[(y * 4.0), $MachinePrecision] + N[(x * -3.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[z, 12000000000000.0], N[(x * N[(-3.0 + N[(z * 6.0), $MachinePrecision]), $MachinePrecision]), $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.58:\\
\;\;\;\;t\_0\\
\mathbf{elif}\;z \leq 4 \cdot 10^{-9}:\\
\;\;\;\;y \cdot 4 + x \cdot -3\\
\mathbf{elif}\;z \leq 12000000000000:\\
\;\;\;\;x \cdot \left(-3 + z \cdot 6\right)\\
\mathbf{else}:\\
\;\;\;\;t\_0\\
\end{array}
\end{array}
if z < -0.57999999999999996 or 1.2e13 < z Initial program 99.7%
metadata-eval99.7%
Simplified99.7%
Taylor expanded in z around inf 99.7%
Taylor expanded in z around inf 98.1%
if -0.57999999999999996 < z < 4.00000000000000025e-9Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in z around 0 98.4%
Taylor expanded in x around 0 98.8%
if 4.00000000000000025e-9 < z < 1.2e13Initial program 98.4%
metadata-eval98.4%
Simplified98.4%
Taylor expanded in x around inf 89.9%
metadata-eval89.9%
cancel-sign-sub-inv89.9%
*-commutative89.9%
cancel-sign-sub-inv89.9%
distribute-lft-neg-in89.9%
*-commutative89.9%
distribute-lft-neg-in89.9%
metadata-eval89.9%
sub-neg89.9%
distribute-lft-in90.3%
metadata-eval90.3%
neg-mul-190.3%
*-commutative90.3%
associate-*l*90.3%
associate-+r+90.3%
metadata-eval90.3%
*-commutative90.3%
associate-*l*90.3%
metadata-eval90.3%
Simplified90.3%
Final simplification98.1%
(FPCore (x y z) :precision binary64 (if (or (<= y -1.2e-34) (not (<= y 9e+78))) (* y 4.0) (* x -3.0)))
double code(double x, double y, double z) {
double tmp;
if ((y <= -1.2e-34) || !(y <= 9e+78)) {
tmp = y * 4.0;
} else {
tmp = 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 ((y <= (-1.2d-34)) .or. (.not. (y <= 9d+78))) then
tmp = y * 4.0d0
else
tmp = x * (-3.0d0)
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((y <= -1.2e-34) || !(y <= 9e+78)) {
tmp = y * 4.0;
} else {
tmp = x * -3.0;
}
return tmp;
}
def code(x, y, z): tmp = 0 if (y <= -1.2e-34) or not (y <= 9e+78): tmp = y * 4.0 else: tmp = x * -3.0 return tmp
function code(x, y, z) tmp = 0.0 if ((y <= -1.2e-34) || !(y <= 9e+78)) tmp = Float64(y * 4.0); else tmp = Float64(x * -3.0); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((y <= -1.2e-34) || ~((y <= 9e+78))) tmp = y * 4.0; else tmp = x * -3.0; end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[y, -1.2e-34], N[Not[LessEqual[y, 9e+78]], $MachinePrecision]], N[(y * 4.0), $MachinePrecision], N[(x * -3.0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1.2 \cdot 10^{-34} \lor \neg \left(y \leq 9 \cdot 10^{+78}\right):\\
\;\;\;\;y \cdot 4\\
\mathbf{else}:\\
\;\;\;\;x \cdot -3\\
\end{array}
\end{array}
if y < -1.19999999999999996e-34 or 8.9999999999999999e78 < y Initial program 99.6%
metadata-eval99.6%
Simplified99.6%
Taylor expanded in z around 0 56.7%
Taylor expanded in y around inf 56.9%
distribute-lft1-in56.9%
metadata-eval56.9%
Simplified56.9%
Taylor expanded in y around inf 47.0%
*-commutative47.0%
Simplified47.0%
if -1.19999999999999996e-34 < y < 8.9999999999999999e78Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around inf 79.8%
metadata-eval79.8%
cancel-sign-sub-inv79.8%
*-commutative79.8%
cancel-sign-sub-inv79.8%
distribute-lft-neg-in79.8%
*-commutative79.8%
distribute-lft-neg-in79.8%
metadata-eval79.8%
sub-neg79.8%
distribute-lft-in79.8%
metadata-eval79.8%
neg-mul-179.8%
*-commutative79.8%
associate-*l*79.8%
associate-+r+79.8%
metadata-eval79.8%
*-commutative79.8%
associate-*l*79.8%
metadata-eval79.8%
Simplified79.8%
Taylor expanded in z around 0 38.0%
*-commutative38.0%
Simplified38.0%
Final simplification42.3%
(FPCore (x y z) :precision binary64 (+ x (* (- 0.6666666666666666 z) (+ (* x -6.0) (* y 6.0)))))
double code(double x, double y, double z) {
return x + ((0.6666666666666666 - z) * ((x * -6.0) + (y * 6.0)));
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = x + ((0.6666666666666666d0 - z) * ((x * (-6.0d0)) + (y * 6.0d0)))
end function
public static double code(double x, double y, double z) {
return x + ((0.6666666666666666 - z) * ((x * -6.0) + (y * 6.0)));
}
def code(x, y, z): return x + ((0.6666666666666666 - z) * ((x * -6.0) + (y * 6.0)))
function code(x, y, z) return Float64(x + Float64(Float64(0.6666666666666666 - z) * Float64(Float64(x * -6.0) + Float64(y * 6.0)))) end
function tmp = code(x, y, z) tmp = x + ((0.6666666666666666 - z) * ((x * -6.0) + (y * 6.0))); end
code[x_, y_, z_] := N[(x + N[(N[(0.6666666666666666 - z), $MachinePrecision] * N[(N[(x * -6.0), $MachinePrecision] + N[(y * 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(0.6666666666666666 - z\right) \cdot \left(x \cdot -6 + y \cdot 6\right)
\end{array}
Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in y around 0 99.5%
Final simplification99.5%
(FPCore (x y z) :precision binary64 (+ x (* (- 0.6666666666666666 z) (* (- y x) 6.0))))
double code(double x, double y, double z) {
return x + ((0.6666666666666666 - z) * ((y - x) * 6.0));
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = x + ((0.6666666666666666d0 - z) * ((y - x) * 6.0d0))
end function
public static double code(double x, double y, double z) {
return x + ((0.6666666666666666 - z) * ((y - x) * 6.0));
}
def code(x, y, z): return x + ((0.6666666666666666 - z) * ((y - x) * 6.0))
function code(x, y, z) return Float64(x + Float64(Float64(0.6666666666666666 - z) * Float64(Float64(y - x) * 6.0))) end
function tmp = code(x, y, z) tmp = x + ((0.6666666666666666 - z) * ((y - x) * 6.0)); end
code[x_, y_, z_] := N[(x + N[(N[(0.6666666666666666 - z), $MachinePrecision] * N[(N[(y - x), $MachinePrecision] * 6.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
x + \left(0.6666666666666666 - z\right) \cdot \left(\left(y - x\right) \cdot 6\right)
\end{array}
Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Final simplification99.5%
(FPCore (x y z) :precision binary64 (* x -3.0))
double code(double x, double y, double z) {
return x * -3.0;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = x * (-3.0d0)
end function
public static double code(double x, double y, double z) {
return x * -3.0;
}
def code(x, y, z): return x * -3.0
function code(x, y, z) return Float64(x * -3.0) end
function tmp = code(x, y, z) tmp = x * -3.0; end
code[x_, y_, z_] := N[(x * -3.0), $MachinePrecision]
\begin{array}{l}
\\
x \cdot -3
\end{array}
Initial program 99.5%
metadata-eval99.5%
Simplified99.5%
Taylor expanded in x around inf 53.6%
metadata-eval53.6%
cancel-sign-sub-inv53.6%
*-commutative53.6%
cancel-sign-sub-inv53.6%
distribute-lft-neg-in53.6%
*-commutative53.6%
distribute-lft-neg-in53.6%
metadata-eval53.6%
sub-neg53.6%
distribute-lft-in53.6%
metadata-eval53.6%
neg-mul-153.6%
*-commutative53.6%
associate-*l*53.6%
associate-+r+53.6%
metadata-eval53.6%
*-commutative53.6%
associate-*l*53.6%
metadata-eval53.6%
Simplified53.6%
Taylor expanded in z around 0 25.4%
*-commutative25.4%
Simplified25.4%
Final simplification25.4%
herbie shell --seed 2024059
(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))))