
(FPCore (x y z) :precision binary64 (+ 1.0 (/ (* 4.0 (- (+ x (* y 0.75)) z)) y)))
double code(double x, double y, double z) {
return 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = 1.0d0 + ((4.0d0 * ((x + (y * 0.75d0)) - z)) / y)
end function
public static double code(double x, double y, double z) {
return 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y);
}
def code(x, y, z): return 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y)
function code(x, y, z) return Float64(1.0 + Float64(Float64(4.0 * Float64(Float64(x + Float64(y * 0.75)) - z)) / y)) end
function tmp = code(x, y, z) tmp = 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y); end
code[x_, y_, z_] := N[(1.0 + N[(N[(4.0 * N[(N[(x + N[(y * 0.75), $MachinePrecision]), $MachinePrecision] - z), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
1 + \frac{4 \cdot \left(\left(x + y \cdot 0.75\right) - z\right)}{y}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 12 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z) :precision binary64 (+ 1.0 (/ (* 4.0 (- (+ x (* y 0.75)) z)) y)))
double code(double x, double y, double z) {
return 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = 1.0d0 + ((4.0d0 * ((x + (y * 0.75d0)) - z)) / y)
end function
public static double code(double x, double y, double z) {
return 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y);
}
def code(x, y, z): return 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y)
function code(x, y, z) return Float64(1.0 + Float64(Float64(4.0 * Float64(Float64(x + Float64(y * 0.75)) - z)) / y)) end
function tmp = code(x, y, z) tmp = 1.0 + ((4.0 * ((x + (y * 0.75)) - z)) / y); end
code[x_, y_, z_] := N[(1.0 + N[(N[(4.0 * N[(N[(x + N[(y * 0.75), $MachinePrecision]), $MachinePrecision] - z), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
1 + \frac{4 \cdot \left(\left(x + y \cdot 0.75\right) - z\right)}{y}
\end{array}
(FPCore (x y z) :precision binary64 (+ 4.0 (/ (* 4.0 (- x z)) y)))
double code(double x, double y, double z) {
return 4.0 + ((4.0 * (x - z)) / y);
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = 4.0d0 + ((4.0d0 * (x - z)) / y)
end function
public static double code(double x, double y, double z) {
return 4.0 + ((4.0 * (x - z)) / y);
}
def code(x, y, z): return 4.0 + ((4.0 * (x - z)) / y)
function code(x, y, z) return Float64(4.0 + Float64(Float64(4.0 * Float64(x - z)) / y)) end
function tmp = code(x, y, z) tmp = 4.0 + ((4.0 * (x - z)) / y); end
code[x_, y_, z_] := N[(4.0 + N[(N[(4.0 * N[(x - z), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
4 + \frac{4 \cdot \left(x - z\right)}{y}
\end{array}
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* z (/ -4.0 y))) (t_1 (* x (/ 4.0 y))))
(if (<= x -2.7e+53)
t_1
(if (<= x -1.52e-27)
4.0
(if (<= x -1.8e-47)
t_1
(if (<= x -7.6e-84)
t_0
(if (<= x -8.5e-115)
4.0
(if (<= x -2.2e-137)
t_0
(if (<= x -1e-210)
4.0
(if (<= x -2.8e-305)
t_0
(if (<= x 1.55e-163)
4.0
(if (<= x 2.3e-147)
t_0
(if (<= x 52000.0)
4.0
(if (or (<= x 4.1e+108) (not (<= x 1e+169)))
t_1
4.0))))))))))))))
double code(double x, double y, double z) {
double t_0 = z * (-4.0 / y);
double t_1 = x * (4.0 / y);
double tmp;
if (x <= -2.7e+53) {
tmp = t_1;
} else if (x <= -1.52e-27) {
tmp = 4.0;
} else if (x <= -1.8e-47) {
tmp = t_1;
} else if (x <= -7.6e-84) {
tmp = t_0;
} else if (x <= -8.5e-115) {
tmp = 4.0;
} else if (x <= -2.2e-137) {
tmp = t_0;
} else if (x <= -1e-210) {
tmp = 4.0;
} else if (x <= -2.8e-305) {
tmp = t_0;
} else if (x <= 1.55e-163) {
tmp = 4.0;
} else if (x <= 2.3e-147) {
tmp = t_0;
} else if (x <= 52000.0) {
tmp = 4.0;
} else if ((x <= 4.1e+108) || !(x <= 1e+169)) {
tmp = t_1;
} else {
tmp = 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) :: t_0
real(8) :: t_1
real(8) :: tmp
t_0 = z * ((-4.0d0) / y)
t_1 = x * (4.0d0 / y)
if (x <= (-2.7d+53)) then
tmp = t_1
else if (x <= (-1.52d-27)) then
tmp = 4.0d0
else if (x <= (-1.8d-47)) then
tmp = t_1
else if (x <= (-7.6d-84)) then
tmp = t_0
else if (x <= (-8.5d-115)) then
tmp = 4.0d0
else if (x <= (-2.2d-137)) then
tmp = t_0
else if (x <= (-1d-210)) then
tmp = 4.0d0
else if (x <= (-2.8d-305)) then
tmp = t_0
else if (x <= 1.55d-163) then
tmp = 4.0d0
else if (x <= 2.3d-147) then
tmp = t_0
else if (x <= 52000.0d0) then
tmp = 4.0d0
else if ((x <= 4.1d+108) .or. (.not. (x <= 1d+169))) then
tmp = t_1
else
tmp = 4.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = z * (-4.0 / y);
double t_1 = x * (4.0 / y);
double tmp;
if (x <= -2.7e+53) {
tmp = t_1;
} else if (x <= -1.52e-27) {
tmp = 4.0;
} else if (x <= -1.8e-47) {
tmp = t_1;
} else if (x <= -7.6e-84) {
tmp = t_0;
} else if (x <= -8.5e-115) {
tmp = 4.0;
} else if (x <= -2.2e-137) {
tmp = t_0;
} else if (x <= -1e-210) {
tmp = 4.0;
} else if (x <= -2.8e-305) {
tmp = t_0;
} else if (x <= 1.55e-163) {
tmp = 4.0;
} else if (x <= 2.3e-147) {
tmp = t_0;
} else if (x <= 52000.0) {
tmp = 4.0;
} else if ((x <= 4.1e+108) || !(x <= 1e+169)) {
tmp = t_1;
} else {
tmp = 4.0;
}
return tmp;
}
def code(x, y, z): t_0 = z * (-4.0 / y) t_1 = x * (4.0 / y) tmp = 0 if x <= -2.7e+53: tmp = t_1 elif x <= -1.52e-27: tmp = 4.0 elif x <= -1.8e-47: tmp = t_1 elif x <= -7.6e-84: tmp = t_0 elif x <= -8.5e-115: tmp = 4.0 elif x <= -2.2e-137: tmp = t_0 elif x <= -1e-210: tmp = 4.0 elif x <= -2.8e-305: tmp = t_0 elif x <= 1.55e-163: tmp = 4.0 elif x <= 2.3e-147: tmp = t_0 elif x <= 52000.0: tmp = 4.0 elif (x <= 4.1e+108) or not (x <= 1e+169): tmp = t_1 else: tmp = 4.0 return tmp
function code(x, y, z) t_0 = Float64(z * Float64(-4.0 / y)) t_1 = Float64(x * Float64(4.0 / y)) tmp = 0.0 if (x <= -2.7e+53) tmp = t_1; elseif (x <= -1.52e-27) tmp = 4.0; elseif (x <= -1.8e-47) tmp = t_1; elseif (x <= -7.6e-84) tmp = t_0; elseif (x <= -8.5e-115) tmp = 4.0; elseif (x <= -2.2e-137) tmp = t_0; elseif (x <= -1e-210) tmp = 4.0; elseif (x <= -2.8e-305) tmp = t_0; elseif (x <= 1.55e-163) tmp = 4.0; elseif (x <= 2.3e-147) tmp = t_0; elseif (x <= 52000.0) tmp = 4.0; elseif ((x <= 4.1e+108) || !(x <= 1e+169)) tmp = t_1; else tmp = 4.0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = z * (-4.0 / y); t_1 = x * (4.0 / y); tmp = 0.0; if (x <= -2.7e+53) tmp = t_1; elseif (x <= -1.52e-27) tmp = 4.0; elseif (x <= -1.8e-47) tmp = t_1; elseif (x <= -7.6e-84) tmp = t_0; elseif (x <= -8.5e-115) tmp = 4.0; elseif (x <= -2.2e-137) tmp = t_0; elseif (x <= -1e-210) tmp = 4.0; elseif (x <= -2.8e-305) tmp = t_0; elseif (x <= 1.55e-163) tmp = 4.0; elseif (x <= 2.3e-147) tmp = t_0; elseif (x <= 52000.0) tmp = 4.0; elseif ((x <= 4.1e+108) || ~((x <= 1e+169))) tmp = t_1; else tmp = 4.0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(z * N[(-4.0 / y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x * N[(4.0 / y), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -2.7e+53], t$95$1, If[LessEqual[x, -1.52e-27], 4.0, If[LessEqual[x, -1.8e-47], t$95$1, If[LessEqual[x, -7.6e-84], t$95$0, If[LessEqual[x, -8.5e-115], 4.0, If[LessEqual[x, -2.2e-137], t$95$0, If[LessEqual[x, -1e-210], 4.0, If[LessEqual[x, -2.8e-305], t$95$0, If[LessEqual[x, 1.55e-163], 4.0, If[LessEqual[x, 2.3e-147], t$95$0, If[LessEqual[x, 52000.0], 4.0, If[Or[LessEqual[x, 4.1e+108], N[Not[LessEqual[x, 1e+169]], $MachinePrecision]], t$95$1, 4.0]]]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := z \cdot \frac{-4}{y}\\
t_1 := x \cdot \frac{4}{y}\\
\mathbf{if}\;x \leq -2.7 \cdot 10^{+53}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -1.52 \cdot 10^{-27}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq -1.8 \cdot 10^{-47}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -7.6 \cdot 10^{-84}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq -8.5 \cdot 10^{-115}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq -2.2 \cdot 10^{-137}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq -1 \cdot 10^{-210}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq -2.8 \cdot 10^{-305}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq 1.55 \cdot 10^{-163}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq 2.3 \cdot 10^{-147}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq 52000:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq 4.1 \cdot 10^{+108} \lor \neg \left(x \leq 10^{+169}\right):\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;4\\
\end{array}
\end{array}
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* z (/ -4.0 y))) (t_1 (* x (/ 4.0 y))) (t_2 (/ z (/ y -4.0))))
(if (<= x -2.35e+53)
t_1
(if (<= x -3.9e-30)
4.0
(if (<= x -2e-47)
t_1
(if (<= x -1.85e-84)
t_0
(if (<= x -3.1e-114)
4.0
(if (<= x -3.4e-137)
t_2
(if (<= x -4.8e-210)
4.0
(if (<= x -3.1e-305)
t_2
(if (<= x 2.1e-163)
4.0
(if (<= x 5e-146)
t_0
(if (<= x 126000000.0)
4.0
(if (or (<= x 2.4e+109) (not (<= x 1e+169)))
t_1
4.0))))))))))))))
double code(double x, double y, double z) {
double t_0 = z * (-4.0 / y);
double t_1 = x * (4.0 / y);
double t_2 = z / (y / -4.0);
double tmp;
if (x <= -2.35e+53) {
tmp = t_1;
} else if (x <= -3.9e-30) {
tmp = 4.0;
} else if (x <= -2e-47) {
tmp = t_1;
} else if (x <= -1.85e-84) {
tmp = t_0;
} else if (x <= -3.1e-114) {
tmp = 4.0;
} else if (x <= -3.4e-137) {
tmp = t_2;
} else if (x <= -4.8e-210) {
tmp = 4.0;
} else if (x <= -3.1e-305) {
tmp = t_2;
} else if (x <= 2.1e-163) {
tmp = 4.0;
} else if (x <= 5e-146) {
tmp = t_0;
} else if (x <= 126000000.0) {
tmp = 4.0;
} else if ((x <= 2.4e+109) || !(x <= 1e+169)) {
tmp = t_1;
} else {
tmp = 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) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_0 = z * ((-4.0d0) / y)
t_1 = x * (4.0d0 / y)
t_2 = z / (y / (-4.0d0))
if (x <= (-2.35d+53)) then
tmp = t_1
else if (x <= (-3.9d-30)) then
tmp = 4.0d0
else if (x <= (-2d-47)) then
tmp = t_1
else if (x <= (-1.85d-84)) then
tmp = t_0
else if (x <= (-3.1d-114)) then
tmp = 4.0d0
else if (x <= (-3.4d-137)) then
tmp = t_2
else if (x <= (-4.8d-210)) then
tmp = 4.0d0
else if (x <= (-3.1d-305)) then
tmp = t_2
else if (x <= 2.1d-163) then
tmp = 4.0d0
else if (x <= 5d-146) then
tmp = t_0
else if (x <= 126000000.0d0) then
tmp = 4.0d0
else if ((x <= 2.4d+109) .or. (.not. (x <= 1d+169))) then
tmp = t_1
else
tmp = 4.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = z * (-4.0 / y);
double t_1 = x * (4.0 / y);
double t_2 = z / (y / -4.0);
double tmp;
if (x <= -2.35e+53) {
tmp = t_1;
} else if (x <= -3.9e-30) {
tmp = 4.0;
} else if (x <= -2e-47) {
tmp = t_1;
} else if (x <= -1.85e-84) {
tmp = t_0;
} else if (x <= -3.1e-114) {
tmp = 4.0;
} else if (x <= -3.4e-137) {
tmp = t_2;
} else if (x <= -4.8e-210) {
tmp = 4.0;
} else if (x <= -3.1e-305) {
tmp = t_2;
} else if (x <= 2.1e-163) {
tmp = 4.0;
} else if (x <= 5e-146) {
tmp = t_0;
} else if (x <= 126000000.0) {
tmp = 4.0;
} else if ((x <= 2.4e+109) || !(x <= 1e+169)) {
tmp = t_1;
} else {
tmp = 4.0;
}
return tmp;
}
def code(x, y, z): t_0 = z * (-4.0 / y) t_1 = x * (4.0 / y) t_2 = z / (y / -4.0) tmp = 0 if x <= -2.35e+53: tmp = t_1 elif x <= -3.9e-30: tmp = 4.0 elif x <= -2e-47: tmp = t_1 elif x <= -1.85e-84: tmp = t_0 elif x <= -3.1e-114: tmp = 4.0 elif x <= -3.4e-137: tmp = t_2 elif x <= -4.8e-210: tmp = 4.0 elif x <= -3.1e-305: tmp = t_2 elif x <= 2.1e-163: tmp = 4.0 elif x <= 5e-146: tmp = t_0 elif x <= 126000000.0: tmp = 4.0 elif (x <= 2.4e+109) or not (x <= 1e+169): tmp = t_1 else: tmp = 4.0 return tmp
function code(x, y, z) t_0 = Float64(z * Float64(-4.0 / y)) t_1 = Float64(x * Float64(4.0 / y)) t_2 = Float64(z / Float64(y / -4.0)) tmp = 0.0 if (x <= -2.35e+53) tmp = t_1; elseif (x <= -3.9e-30) tmp = 4.0; elseif (x <= -2e-47) tmp = t_1; elseif (x <= -1.85e-84) tmp = t_0; elseif (x <= -3.1e-114) tmp = 4.0; elseif (x <= -3.4e-137) tmp = t_2; elseif (x <= -4.8e-210) tmp = 4.0; elseif (x <= -3.1e-305) tmp = t_2; elseif (x <= 2.1e-163) tmp = 4.0; elseif (x <= 5e-146) tmp = t_0; elseif (x <= 126000000.0) tmp = 4.0; elseif ((x <= 2.4e+109) || !(x <= 1e+169)) tmp = t_1; else tmp = 4.0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = z * (-4.0 / y); t_1 = x * (4.0 / y); t_2 = z / (y / -4.0); tmp = 0.0; if (x <= -2.35e+53) tmp = t_1; elseif (x <= -3.9e-30) tmp = 4.0; elseif (x <= -2e-47) tmp = t_1; elseif (x <= -1.85e-84) tmp = t_0; elseif (x <= -3.1e-114) tmp = 4.0; elseif (x <= -3.4e-137) tmp = t_2; elseif (x <= -4.8e-210) tmp = 4.0; elseif (x <= -3.1e-305) tmp = t_2; elseif (x <= 2.1e-163) tmp = 4.0; elseif (x <= 5e-146) tmp = t_0; elseif (x <= 126000000.0) tmp = 4.0; elseif ((x <= 2.4e+109) || ~((x <= 1e+169))) tmp = t_1; else tmp = 4.0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(z * N[(-4.0 / y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(x * N[(4.0 / y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(z / N[(y / -4.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -2.35e+53], t$95$1, If[LessEqual[x, -3.9e-30], 4.0, If[LessEqual[x, -2e-47], t$95$1, If[LessEqual[x, -1.85e-84], t$95$0, If[LessEqual[x, -3.1e-114], 4.0, If[LessEqual[x, -3.4e-137], t$95$2, If[LessEqual[x, -4.8e-210], 4.0, If[LessEqual[x, -3.1e-305], t$95$2, If[LessEqual[x, 2.1e-163], 4.0, If[LessEqual[x, 5e-146], t$95$0, If[LessEqual[x, 126000000.0], 4.0, If[Or[LessEqual[x, 2.4e+109], N[Not[LessEqual[x, 1e+169]], $MachinePrecision]], t$95$1, 4.0]]]]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := z \cdot \frac{-4}{y}\\
t_1 := x \cdot \frac{4}{y}\\
t_2 := \frac{z}{\frac{y}{-4}}\\
\mathbf{if}\;x \leq -2.35 \cdot 10^{+53}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -3.9 \cdot 10^{-30}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq -2 \cdot 10^{-47}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -1.85 \cdot 10^{-84}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq -3.1 \cdot 10^{-114}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq -3.4 \cdot 10^{-137}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq -4.8 \cdot 10^{-210}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq -3.1 \cdot 10^{-305}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq 2.1 \cdot 10^{-163}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq 5 \cdot 10^{-146}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq 126000000:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq 2.4 \cdot 10^{+109} \lor \neg \left(x \leq 10^{+169}\right):\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;4\\
\end{array}
\end{array}
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* z (/ -4.0 y))) (t_1 (/ (* 4.0 x) y)) (t_2 (/ z (/ y -4.0))))
(if (<= x -5.2e+53)
t_1
(if (<= x -3.9e-30)
4.0
(if (<= x -1.85e-47)
t_1
(if (<= x -4.5e-85)
t_0
(if (<= x -1.3e-112)
4.0
(if (<= x -2.9e-139)
t_2
(if (<= x -2.9e-209)
4.0
(if (<= x -4.8e-305)
t_2
(if (<= x 5.2e-166)
4.0
(if (<= x 9e-145)
t_0
(if (<= x 2300000000000.0)
4.0
(if (or (<= x 3.1e+109) (not (<= x 1.3e+169)))
t_1
4.0))))))))))))))
double code(double x, double y, double z) {
double t_0 = z * (-4.0 / y);
double t_1 = (4.0 * x) / y;
double t_2 = z / (y / -4.0);
double tmp;
if (x <= -5.2e+53) {
tmp = t_1;
} else if (x <= -3.9e-30) {
tmp = 4.0;
} else if (x <= -1.85e-47) {
tmp = t_1;
} else if (x <= -4.5e-85) {
tmp = t_0;
} else if (x <= -1.3e-112) {
tmp = 4.0;
} else if (x <= -2.9e-139) {
tmp = t_2;
} else if (x <= -2.9e-209) {
tmp = 4.0;
} else if (x <= -4.8e-305) {
tmp = t_2;
} else if (x <= 5.2e-166) {
tmp = 4.0;
} else if (x <= 9e-145) {
tmp = t_0;
} else if (x <= 2300000000000.0) {
tmp = 4.0;
} else if ((x <= 3.1e+109) || !(x <= 1.3e+169)) {
tmp = t_1;
} else {
tmp = 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) :: t_0
real(8) :: t_1
real(8) :: t_2
real(8) :: tmp
t_0 = z * ((-4.0d0) / y)
t_1 = (4.0d0 * x) / y
t_2 = z / (y / (-4.0d0))
if (x <= (-5.2d+53)) then
tmp = t_1
else if (x <= (-3.9d-30)) then
tmp = 4.0d0
else if (x <= (-1.85d-47)) then
tmp = t_1
else if (x <= (-4.5d-85)) then
tmp = t_0
else if (x <= (-1.3d-112)) then
tmp = 4.0d0
else if (x <= (-2.9d-139)) then
tmp = t_2
else if (x <= (-2.9d-209)) then
tmp = 4.0d0
else if (x <= (-4.8d-305)) then
tmp = t_2
else if (x <= 5.2d-166) then
tmp = 4.0d0
else if (x <= 9d-145) then
tmp = t_0
else if (x <= 2300000000000.0d0) then
tmp = 4.0d0
else if ((x <= 3.1d+109) .or. (.not. (x <= 1.3d+169))) then
tmp = t_1
else
tmp = 4.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = z * (-4.0 / y);
double t_1 = (4.0 * x) / y;
double t_2 = z / (y / -4.0);
double tmp;
if (x <= -5.2e+53) {
tmp = t_1;
} else if (x <= -3.9e-30) {
tmp = 4.0;
} else if (x <= -1.85e-47) {
tmp = t_1;
} else if (x <= -4.5e-85) {
tmp = t_0;
} else if (x <= -1.3e-112) {
tmp = 4.0;
} else if (x <= -2.9e-139) {
tmp = t_2;
} else if (x <= -2.9e-209) {
tmp = 4.0;
} else if (x <= -4.8e-305) {
tmp = t_2;
} else if (x <= 5.2e-166) {
tmp = 4.0;
} else if (x <= 9e-145) {
tmp = t_0;
} else if (x <= 2300000000000.0) {
tmp = 4.0;
} else if ((x <= 3.1e+109) || !(x <= 1.3e+169)) {
tmp = t_1;
} else {
tmp = 4.0;
}
return tmp;
}
def code(x, y, z): t_0 = z * (-4.0 / y) t_1 = (4.0 * x) / y t_2 = z / (y / -4.0) tmp = 0 if x <= -5.2e+53: tmp = t_1 elif x <= -3.9e-30: tmp = 4.0 elif x <= -1.85e-47: tmp = t_1 elif x <= -4.5e-85: tmp = t_0 elif x <= -1.3e-112: tmp = 4.0 elif x <= -2.9e-139: tmp = t_2 elif x <= -2.9e-209: tmp = 4.0 elif x <= -4.8e-305: tmp = t_2 elif x <= 5.2e-166: tmp = 4.0 elif x <= 9e-145: tmp = t_0 elif x <= 2300000000000.0: tmp = 4.0 elif (x <= 3.1e+109) or not (x <= 1.3e+169): tmp = t_1 else: tmp = 4.0 return tmp
function code(x, y, z) t_0 = Float64(z * Float64(-4.0 / y)) t_1 = Float64(Float64(4.0 * x) / y) t_2 = Float64(z / Float64(y / -4.0)) tmp = 0.0 if (x <= -5.2e+53) tmp = t_1; elseif (x <= -3.9e-30) tmp = 4.0; elseif (x <= -1.85e-47) tmp = t_1; elseif (x <= -4.5e-85) tmp = t_0; elseif (x <= -1.3e-112) tmp = 4.0; elseif (x <= -2.9e-139) tmp = t_2; elseif (x <= -2.9e-209) tmp = 4.0; elseif (x <= -4.8e-305) tmp = t_2; elseif (x <= 5.2e-166) tmp = 4.0; elseif (x <= 9e-145) tmp = t_0; elseif (x <= 2300000000000.0) tmp = 4.0; elseif ((x <= 3.1e+109) || !(x <= 1.3e+169)) tmp = t_1; else tmp = 4.0; end return tmp end
function tmp_2 = code(x, y, z) t_0 = z * (-4.0 / y); t_1 = (4.0 * x) / y; t_2 = z / (y / -4.0); tmp = 0.0; if (x <= -5.2e+53) tmp = t_1; elseif (x <= -3.9e-30) tmp = 4.0; elseif (x <= -1.85e-47) tmp = t_1; elseif (x <= -4.5e-85) tmp = t_0; elseif (x <= -1.3e-112) tmp = 4.0; elseif (x <= -2.9e-139) tmp = t_2; elseif (x <= -2.9e-209) tmp = 4.0; elseif (x <= -4.8e-305) tmp = t_2; elseif (x <= 5.2e-166) tmp = 4.0; elseif (x <= 9e-145) tmp = t_0; elseif (x <= 2300000000000.0) tmp = 4.0; elseif ((x <= 3.1e+109) || ~((x <= 1.3e+169))) tmp = t_1; else tmp = 4.0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(z * N[(-4.0 / y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[(4.0 * x), $MachinePrecision] / y), $MachinePrecision]}, Block[{t$95$2 = N[(z / N[(y / -4.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -5.2e+53], t$95$1, If[LessEqual[x, -3.9e-30], 4.0, If[LessEqual[x, -1.85e-47], t$95$1, If[LessEqual[x, -4.5e-85], t$95$0, If[LessEqual[x, -1.3e-112], 4.0, If[LessEqual[x, -2.9e-139], t$95$2, If[LessEqual[x, -2.9e-209], 4.0, If[LessEqual[x, -4.8e-305], t$95$2, If[LessEqual[x, 5.2e-166], 4.0, If[LessEqual[x, 9e-145], t$95$0, If[LessEqual[x, 2300000000000.0], 4.0, If[Or[LessEqual[x, 3.1e+109], N[Not[LessEqual[x, 1.3e+169]], $MachinePrecision]], t$95$1, 4.0]]]]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := z \cdot \frac{-4}{y}\\
t_1 := \frac{4 \cdot x}{y}\\
t_2 := \frac{z}{\frac{y}{-4}}\\
\mathbf{if}\;x \leq -5.2 \cdot 10^{+53}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -3.9 \cdot 10^{-30}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq -1.85 \cdot 10^{-47}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -4.5 \cdot 10^{-85}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq -1.3 \cdot 10^{-112}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq -2.9 \cdot 10^{-139}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq -2.9 \cdot 10^{-209}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq -4.8 \cdot 10^{-305}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq 5.2 \cdot 10^{-166}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq 9 \cdot 10^{-145}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq 2300000000000:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq 3.1 \cdot 10^{+109} \lor \neg \left(x \leq 1.3 \cdot 10^{+169}\right):\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;4\\
\end{array}
\end{array}
(FPCore (x y z)
:precision binary64
(let* ((t_0 (/ z (/ y -4.0))) (t_1 (+ 1.0 (* 4.0 (/ x y)))))
(if (<= x -8.8e+33)
t_1
(if (<= x -0.027)
t_0
(if (<= x -6.7e-49)
t_1
(if (<= x -1.1e-112)
4.0
(if (<= x -5e-139)
t_0
(if (<= x -4.8e-210)
4.0
(if (<= x -2.7e-305)
t_0
(if (<= x 3.9e-165)
4.0
(if (<= x 1.2e-137)
(* z (/ -4.0 y))
(if (<= x 14600000.0) 4.0 t_1))))))))))))
double code(double x, double y, double z) {
double t_0 = z / (y / -4.0);
double t_1 = 1.0 + (4.0 * (x / y));
double tmp;
if (x <= -8.8e+33) {
tmp = t_1;
} else if (x <= -0.027) {
tmp = t_0;
} else if (x <= -6.7e-49) {
tmp = t_1;
} else if (x <= -1.1e-112) {
tmp = 4.0;
} else if (x <= -5e-139) {
tmp = t_0;
} else if (x <= -4.8e-210) {
tmp = 4.0;
} else if (x <= -2.7e-305) {
tmp = t_0;
} else if (x <= 3.9e-165) {
tmp = 4.0;
} else if (x <= 1.2e-137) {
tmp = z * (-4.0 / y);
} else if (x <= 14600000.0) {
tmp = 4.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 = z / (y / (-4.0d0))
t_1 = 1.0d0 + (4.0d0 * (x / y))
if (x <= (-8.8d+33)) then
tmp = t_1
else if (x <= (-0.027d0)) then
tmp = t_0
else if (x <= (-6.7d-49)) then
tmp = t_1
else if (x <= (-1.1d-112)) then
tmp = 4.0d0
else if (x <= (-5d-139)) then
tmp = t_0
else if (x <= (-4.8d-210)) then
tmp = 4.0d0
else if (x <= (-2.7d-305)) then
tmp = t_0
else if (x <= 3.9d-165) then
tmp = 4.0d0
else if (x <= 1.2d-137) then
tmp = z * ((-4.0d0) / y)
else if (x <= 14600000.0d0) then
tmp = 4.0d0
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = z / (y / -4.0);
double t_1 = 1.0 + (4.0 * (x / y));
double tmp;
if (x <= -8.8e+33) {
tmp = t_1;
} else if (x <= -0.027) {
tmp = t_0;
} else if (x <= -6.7e-49) {
tmp = t_1;
} else if (x <= -1.1e-112) {
tmp = 4.0;
} else if (x <= -5e-139) {
tmp = t_0;
} else if (x <= -4.8e-210) {
tmp = 4.0;
} else if (x <= -2.7e-305) {
tmp = t_0;
} else if (x <= 3.9e-165) {
tmp = 4.0;
} else if (x <= 1.2e-137) {
tmp = z * (-4.0 / y);
} else if (x <= 14600000.0) {
tmp = 4.0;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z): t_0 = z / (y / -4.0) t_1 = 1.0 + (4.0 * (x / y)) tmp = 0 if x <= -8.8e+33: tmp = t_1 elif x <= -0.027: tmp = t_0 elif x <= -6.7e-49: tmp = t_1 elif x <= -1.1e-112: tmp = 4.0 elif x <= -5e-139: tmp = t_0 elif x <= -4.8e-210: tmp = 4.0 elif x <= -2.7e-305: tmp = t_0 elif x <= 3.9e-165: tmp = 4.0 elif x <= 1.2e-137: tmp = z * (-4.0 / y) elif x <= 14600000.0: tmp = 4.0 else: tmp = t_1 return tmp
function code(x, y, z) t_0 = Float64(z / Float64(y / -4.0)) t_1 = Float64(1.0 + Float64(4.0 * Float64(x / y))) tmp = 0.0 if (x <= -8.8e+33) tmp = t_1; elseif (x <= -0.027) tmp = t_0; elseif (x <= -6.7e-49) tmp = t_1; elseif (x <= -1.1e-112) tmp = 4.0; elseif (x <= -5e-139) tmp = t_0; elseif (x <= -4.8e-210) tmp = 4.0; elseif (x <= -2.7e-305) tmp = t_0; elseif (x <= 3.9e-165) tmp = 4.0; elseif (x <= 1.2e-137) tmp = Float64(z * Float64(-4.0 / y)); elseif (x <= 14600000.0) tmp = 4.0; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z) t_0 = z / (y / -4.0); t_1 = 1.0 + (4.0 * (x / y)); tmp = 0.0; if (x <= -8.8e+33) tmp = t_1; elseif (x <= -0.027) tmp = t_0; elseif (x <= -6.7e-49) tmp = t_1; elseif (x <= -1.1e-112) tmp = 4.0; elseif (x <= -5e-139) tmp = t_0; elseif (x <= -4.8e-210) tmp = 4.0; elseif (x <= -2.7e-305) tmp = t_0; elseif (x <= 3.9e-165) tmp = 4.0; elseif (x <= 1.2e-137) tmp = z * (-4.0 / y); elseif (x <= 14600000.0) tmp = 4.0; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(z / N[(y / -4.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(1.0 + N[(4.0 * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -8.8e+33], t$95$1, If[LessEqual[x, -0.027], t$95$0, If[LessEqual[x, -6.7e-49], t$95$1, If[LessEqual[x, -1.1e-112], 4.0, If[LessEqual[x, -5e-139], t$95$0, If[LessEqual[x, -4.8e-210], 4.0, If[LessEqual[x, -2.7e-305], t$95$0, If[LessEqual[x, 3.9e-165], 4.0, If[LessEqual[x, 1.2e-137], N[(z * N[(-4.0 / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 14600000.0], 4.0, t$95$1]]]]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := \frac{z}{\frac{y}{-4}}\\
t_1 := 1 + 4 \cdot \frac{x}{y}\\
\mathbf{if}\;x \leq -8.8 \cdot 10^{+33}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -0.027:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq -6.7 \cdot 10^{-49}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -1.1 \cdot 10^{-112}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq -5 \cdot 10^{-139}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq -4.8 \cdot 10^{-210}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq -2.7 \cdot 10^{-305}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq 3.9 \cdot 10^{-165}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq 1.2 \cdot 10^{-137}:\\
\;\;\;\;z \cdot \frac{-4}{y}\\
\mathbf{elif}\;x \leq 14600000:\\
\;\;\;\;4\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
(FPCore (x y z)
:precision binary64
(let* ((t_0 (+ 1.0 (* -4.0 (/ z y)))) (t_1 (+ 1.0 (* 4.0 (/ x y)))))
(if (<= x -1.7e+32)
t_1
(if (<= x -0.021)
t_0
(if (<= x -2e-47)
t_1
(if (<= x -2.9e-305)
t_0
(if (<= x 4.9e-166)
4.0
(if (<= x 4.8e-137)
(* z (/ -4.0 y))
(if (<= x 330000000.0) 4.0 t_1)))))))))
double code(double x, double y, double z) {
double t_0 = 1.0 + (-4.0 * (z / y));
double t_1 = 1.0 + (4.0 * (x / y));
double tmp;
if (x <= -1.7e+32) {
tmp = t_1;
} else if (x <= -0.021) {
tmp = t_0;
} else if (x <= -2e-47) {
tmp = t_1;
} else if (x <= -2.9e-305) {
tmp = t_0;
} else if (x <= 4.9e-166) {
tmp = 4.0;
} else if (x <= 4.8e-137) {
tmp = z * (-4.0 / y);
} else if (x <= 330000000.0) {
tmp = 4.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 = 1.0d0 + ((-4.0d0) * (z / y))
t_1 = 1.0d0 + (4.0d0 * (x / y))
if (x <= (-1.7d+32)) then
tmp = t_1
else if (x <= (-0.021d0)) then
tmp = t_0
else if (x <= (-2d-47)) then
tmp = t_1
else if (x <= (-2.9d-305)) then
tmp = t_0
else if (x <= 4.9d-166) then
tmp = 4.0d0
else if (x <= 4.8d-137) then
tmp = z * ((-4.0d0) / y)
else if (x <= 330000000.0d0) then
tmp = 4.0d0
else
tmp = t_1
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = 1.0 + (-4.0 * (z / y));
double t_1 = 1.0 + (4.0 * (x / y));
double tmp;
if (x <= -1.7e+32) {
tmp = t_1;
} else if (x <= -0.021) {
tmp = t_0;
} else if (x <= -2e-47) {
tmp = t_1;
} else if (x <= -2.9e-305) {
tmp = t_0;
} else if (x <= 4.9e-166) {
tmp = 4.0;
} else if (x <= 4.8e-137) {
tmp = z * (-4.0 / y);
} else if (x <= 330000000.0) {
tmp = 4.0;
} else {
tmp = t_1;
}
return tmp;
}
def code(x, y, z): t_0 = 1.0 + (-4.0 * (z / y)) t_1 = 1.0 + (4.0 * (x / y)) tmp = 0 if x <= -1.7e+32: tmp = t_1 elif x <= -0.021: tmp = t_0 elif x <= -2e-47: tmp = t_1 elif x <= -2.9e-305: tmp = t_0 elif x <= 4.9e-166: tmp = 4.0 elif x <= 4.8e-137: tmp = z * (-4.0 / y) elif x <= 330000000.0: tmp = 4.0 else: tmp = t_1 return tmp
function code(x, y, z) t_0 = Float64(1.0 + Float64(-4.0 * Float64(z / y))) t_1 = Float64(1.0 + Float64(4.0 * Float64(x / y))) tmp = 0.0 if (x <= -1.7e+32) tmp = t_1; elseif (x <= -0.021) tmp = t_0; elseif (x <= -2e-47) tmp = t_1; elseif (x <= -2.9e-305) tmp = t_0; elseif (x <= 4.9e-166) tmp = 4.0; elseif (x <= 4.8e-137) tmp = Float64(z * Float64(-4.0 / y)); elseif (x <= 330000000.0) tmp = 4.0; else tmp = t_1; end return tmp end
function tmp_2 = code(x, y, z) t_0 = 1.0 + (-4.0 * (z / y)); t_1 = 1.0 + (4.0 * (x / y)); tmp = 0.0; if (x <= -1.7e+32) tmp = t_1; elseif (x <= -0.021) tmp = t_0; elseif (x <= -2e-47) tmp = t_1; elseif (x <= -2.9e-305) tmp = t_0; elseif (x <= 4.9e-166) tmp = 4.0; elseif (x <= 4.8e-137) tmp = z * (-4.0 / y); elseif (x <= 330000000.0) tmp = 4.0; else tmp = t_1; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(1.0 + N[(-4.0 * N[(z / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(1.0 + N[(4.0 * N[(x / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -1.7e+32], t$95$1, If[LessEqual[x, -0.021], t$95$0, If[LessEqual[x, -2e-47], t$95$1, If[LessEqual[x, -2.9e-305], t$95$0, If[LessEqual[x, 4.9e-166], 4.0, If[LessEqual[x, 4.8e-137], N[(z * N[(-4.0 / y), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 330000000.0], 4.0, t$95$1]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 1 + -4 \cdot \frac{z}{y}\\
t_1 := 1 + 4 \cdot \frac{x}{y}\\
\mathbf{if}\;x \leq -1.7 \cdot 10^{+32}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -0.021:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq -2 \cdot 10^{-47}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;x \leq -2.9 \cdot 10^{-305}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;x \leq 4.9 \cdot 10^{-166}:\\
\;\;\;\;4\\
\mathbf{elif}\;x \leq 4.8 \cdot 10^{-137}:\\
\;\;\;\;z \cdot \frac{-4}{y}\\
\mathbf{elif}\;x \leq 330000000:\\
\;\;\;\;4\\
\mathbf{else}:\\
\;\;\;\;t_1\\
\end{array}
\end{array}
(FPCore (x y z)
:precision binary64
(if (or (<= x -6.4e+34)
(not (or (<= x -0.0175) (and (not (<= x -1.6e-47)) (<= x 3.1e-47)))))
(+ 4.0 (* x (/ 4.0 y)))
(+ 4.0 (/ (* z -4.0) y))))
double code(double x, double y, double z) {
double tmp;
if ((x <= -6.4e+34) || !((x <= -0.0175) || (!(x <= -1.6e-47) && (x <= 3.1e-47)))) {
tmp = 4.0 + (x * (4.0 / y));
} else {
tmp = 4.0 + ((z * -4.0) / y);
}
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 <= (-6.4d+34)) .or. (.not. (x <= (-0.0175d0)) .or. (.not. (x <= (-1.6d-47))) .and. (x <= 3.1d-47))) then
tmp = 4.0d0 + (x * (4.0d0 / y))
else
tmp = 4.0d0 + ((z * (-4.0d0)) / y)
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((x <= -6.4e+34) || !((x <= -0.0175) || (!(x <= -1.6e-47) && (x <= 3.1e-47)))) {
tmp = 4.0 + (x * (4.0 / y));
} else {
tmp = 4.0 + ((z * -4.0) / y);
}
return tmp;
}
def code(x, y, z): tmp = 0 if (x <= -6.4e+34) or not ((x <= -0.0175) or (not (x <= -1.6e-47) and (x <= 3.1e-47))): tmp = 4.0 + (x * (4.0 / y)) else: tmp = 4.0 + ((z * -4.0) / y) return tmp
function code(x, y, z) tmp = 0.0 if ((x <= -6.4e+34) || !((x <= -0.0175) || (!(x <= -1.6e-47) && (x <= 3.1e-47)))) tmp = Float64(4.0 + Float64(x * Float64(4.0 / y))); else tmp = Float64(4.0 + Float64(Float64(z * -4.0) / y)); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((x <= -6.4e+34) || ~(((x <= -0.0175) || (~((x <= -1.6e-47)) && (x <= 3.1e-47))))) tmp = 4.0 + (x * (4.0 / y)); else tmp = 4.0 + ((z * -4.0) / y); end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[x, -6.4e+34], N[Not[Or[LessEqual[x, -0.0175], And[N[Not[LessEqual[x, -1.6e-47]], $MachinePrecision], LessEqual[x, 3.1e-47]]]], $MachinePrecision]], N[(4.0 + N[(x * N[(4.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(4.0 + N[(N[(z * -4.0), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -6.4 \cdot 10^{+34} \lor \neg \left(x \leq -0.0175 \lor \neg \left(x \leq -1.6 \cdot 10^{-47}\right) \land x \leq 3.1 \cdot 10^{-47}\right):\\
\;\;\;\;4 + x \cdot \frac{4}{y}\\
\mathbf{else}:\\
\;\;\;\;4 + \frac{z \cdot -4}{y}\\
\end{array}
\end{array}
(FPCore (x y z)
:precision binary64
(if (<= x -4e+59)
(/ (* 4.0 (- x z)) y)
(if (or (<= x -7.5e-7) (and (not (<= x -1.9e-47)) (<= x 8.5e-47)))
(+ 4.0 (/ (* z -4.0) y))
(+ 4.0 (* x (/ 4.0 y))))))
double code(double x, double y, double z) {
double tmp;
if (x <= -4e+59) {
tmp = (4.0 * (x - z)) / y;
} else if ((x <= -7.5e-7) || (!(x <= -1.9e-47) && (x <= 8.5e-47))) {
tmp = 4.0 + ((z * -4.0) / y);
} else {
tmp = 4.0 + (x * (4.0 / y));
}
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 <= (-4d+59)) then
tmp = (4.0d0 * (x - z)) / y
else if ((x <= (-7.5d-7)) .or. (.not. (x <= (-1.9d-47))) .and. (x <= 8.5d-47)) then
tmp = 4.0d0 + ((z * (-4.0d0)) / y)
else
tmp = 4.0d0 + (x * (4.0d0 / y))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if (x <= -4e+59) {
tmp = (4.0 * (x - z)) / y;
} else if ((x <= -7.5e-7) || (!(x <= -1.9e-47) && (x <= 8.5e-47))) {
tmp = 4.0 + ((z * -4.0) / y);
} else {
tmp = 4.0 + (x * (4.0 / y));
}
return tmp;
}
def code(x, y, z): tmp = 0 if x <= -4e+59: tmp = (4.0 * (x - z)) / y elif (x <= -7.5e-7) or (not (x <= -1.9e-47) and (x <= 8.5e-47)): tmp = 4.0 + ((z * -4.0) / y) else: tmp = 4.0 + (x * (4.0 / y)) return tmp
function code(x, y, z) tmp = 0.0 if (x <= -4e+59) tmp = Float64(Float64(4.0 * Float64(x - z)) / y); elseif ((x <= -7.5e-7) || (!(x <= -1.9e-47) && (x <= 8.5e-47))) tmp = Float64(4.0 + Float64(Float64(z * -4.0) / y)); else tmp = Float64(4.0 + Float64(x * Float64(4.0 / y))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if (x <= -4e+59) tmp = (4.0 * (x - z)) / y; elseif ((x <= -7.5e-7) || (~((x <= -1.9e-47)) && (x <= 8.5e-47))) tmp = 4.0 + ((z * -4.0) / y); else tmp = 4.0 + (x * (4.0 / y)); end tmp_2 = tmp; end
code[x_, y_, z_] := If[LessEqual[x, -4e+59], N[(N[(4.0 * N[(x - z), $MachinePrecision]), $MachinePrecision] / y), $MachinePrecision], If[Or[LessEqual[x, -7.5e-7], And[N[Not[LessEqual[x, -1.9e-47]], $MachinePrecision], LessEqual[x, 8.5e-47]]], N[(4.0 + N[(N[(z * -4.0), $MachinePrecision] / y), $MachinePrecision]), $MachinePrecision], N[(4.0 + N[(x * N[(4.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -4 \cdot 10^{+59}:\\
\;\;\;\;\frac{4 \cdot \left(x - z\right)}{y}\\
\mathbf{elif}\;x \leq -7.5 \cdot 10^{-7} \lor \neg \left(x \leq -1.9 \cdot 10^{-47}\right) \land x \leq 8.5 \cdot 10^{-47}:\\
\;\;\;\;4 + \frac{z \cdot -4}{y}\\
\mathbf{else}:\\
\;\;\;\;4 + x \cdot \frac{4}{y}\\
\end{array}
\end{array}
(FPCore (x y z)
:precision binary64
(if (or (<= x -9.5e+53)
(and (not (<= x 7000000.0))
(or (<= x 1.15e+109) (not (<= x 5.4e+169)))))
(* x (/ 4.0 y))
4.0))
double code(double x, double y, double z) {
double tmp;
if ((x <= -9.5e+53) || (!(x <= 7000000.0) && ((x <= 1.15e+109) || !(x <= 5.4e+169)))) {
tmp = x * (4.0 / y);
} else {
tmp = 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 <= (-9.5d+53)) .or. (.not. (x <= 7000000.0d0)) .and. (x <= 1.15d+109) .or. (.not. (x <= 5.4d+169))) then
tmp = x * (4.0d0 / y)
else
tmp = 4.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((x <= -9.5e+53) || (!(x <= 7000000.0) && ((x <= 1.15e+109) || !(x <= 5.4e+169)))) {
tmp = x * (4.0 / y);
} else {
tmp = 4.0;
}
return tmp;
}
def code(x, y, z): tmp = 0 if (x <= -9.5e+53) or (not (x <= 7000000.0) and ((x <= 1.15e+109) or not (x <= 5.4e+169))): tmp = x * (4.0 / y) else: tmp = 4.0 return tmp
function code(x, y, z) tmp = 0.0 if ((x <= -9.5e+53) || (!(x <= 7000000.0) && ((x <= 1.15e+109) || !(x <= 5.4e+169)))) tmp = Float64(x * Float64(4.0 / y)); else tmp = 4.0; end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((x <= -9.5e+53) || (~((x <= 7000000.0)) && ((x <= 1.15e+109) || ~((x <= 5.4e+169))))) tmp = x * (4.0 / y); else tmp = 4.0; end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[x, -9.5e+53], And[N[Not[LessEqual[x, 7000000.0]], $MachinePrecision], Or[LessEqual[x, 1.15e+109], N[Not[LessEqual[x, 5.4e+169]], $MachinePrecision]]]], N[(x * N[(4.0 / y), $MachinePrecision]), $MachinePrecision], 4.0]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;x \leq -9.5 \cdot 10^{+53} \lor \neg \left(x \leq 7000000\right) \land \left(x \leq 1.15 \cdot 10^{+109} \lor \neg \left(x \leq 5.4 \cdot 10^{+169}\right)\right):\\
\;\;\;\;x \cdot \frac{4}{y}\\
\mathbf{else}:\\
\;\;\;\;4\\
\end{array}
\end{array}
(FPCore (x y z) :precision binary64 (if (or (<= z -8.8e+185) (not (<= z 1.9e+160))) (+ 1.0 (* -4.0 (/ z y))) (+ 4.0 (* x (/ 4.0 y)))))
double code(double x, double y, double z) {
double tmp;
if ((z <= -8.8e+185) || !(z <= 1.9e+160)) {
tmp = 1.0 + (-4.0 * (z / y));
} else {
tmp = 4.0 + (x * (4.0 / y));
}
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 <= (-8.8d+185)) .or. (.not. (z <= 1.9d+160))) then
tmp = 1.0d0 + ((-4.0d0) * (z / y))
else
tmp = 4.0d0 + (x * (4.0d0 / y))
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double tmp;
if ((z <= -8.8e+185) || !(z <= 1.9e+160)) {
tmp = 1.0 + (-4.0 * (z / y));
} else {
tmp = 4.0 + (x * (4.0 / y));
}
return tmp;
}
def code(x, y, z): tmp = 0 if (z <= -8.8e+185) or not (z <= 1.9e+160): tmp = 1.0 + (-4.0 * (z / y)) else: tmp = 4.0 + (x * (4.0 / y)) return tmp
function code(x, y, z) tmp = 0.0 if ((z <= -8.8e+185) || !(z <= 1.9e+160)) tmp = Float64(1.0 + Float64(-4.0 * Float64(z / y))); else tmp = Float64(4.0 + Float64(x * Float64(4.0 / y))); end return tmp end
function tmp_2 = code(x, y, z) tmp = 0.0; if ((z <= -8.8e+185) || ~((z <= 1.9e+160))) tmp = 1.0 + (-4.0 * (z / y)); else tmp = 4.0 + (x * (4.0 / y)); end tmp_2 = tmp; end
code[x_, y_, z_] := If[Or[LessEqual[z, -8.8e+185], N[Not[LessEqual[z, 1.9e+160]], $MachinePrecision]], N[(1.0 + N[(-4.0 * N[(z / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(4.0 + N[(x * N[(4.0 / y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;z \leq -8.8 \cdot 10^{+185} \lor \neg \left(z \leq 1.9 \cdot 10^{+160}\right):\\
\;\;\;\;1 + -4 \cdot \frac{z}{y}\\
\mathbf{else}:\\
\;\;\;\;4 + x \cdot \frac{4}{y}\\
\end{array}
\end{array}
(FPCore (x y z) :precision binary64 1.0)
double code(double x, double y, double z) {
return 1.0;
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = 1.0d0
end function
public static double code(double x, double y, double z) {
return 1.0;
}
def code(x, y, z): return 1.0
function code(x, y, z) return 1.0 end
function tmp = code(x, y, z) tmp = 1.0; end
code[x_, y_, z_] := 1.0
\begin{array}{l}
\\
1
\end{array}
(FPCore (x y z) :precision binary64 4.0)
double code(double x, double y, double z) {
return 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 = 4.0d0
end function
public static double code(double x, double y, double z) {
return 4.0;
}
def code(x, y, z): return 4.0
function code(x, y, z) return 4.0 end
function tmp = code(x, y, z) tmp = 4.0; end
code[x_, y_, z_] := 4.0
\begin{array}{l}
\\
4
\end{array}
herbie shell --seed 2023350
(FPCore (x y z)
:name "Data.Array.Repa.Algorithms.ColorRamp:rampColorHotToCold from repa-algorithms-3.4.0.1, A"
:precision binary64
(+ 1.0 (/ (* 4.0 (- (+ x (* y 0.75)) z)) y)))