\[\frac{x \cdot x - \left(y \cdot 4\right) \cdot y}{x \cdot x + \left(y \cdot 4\right) \cdot y}
\]
↓
\[\begin{array}{l}
t_0 := \frac{x}{y} \cdot \frac{x}{y}\\
t_1 := x \cdot x + y \cdot \left(y \cdot -4\right)\\
t_2 := \frac{t_1}{x \cdot x + y \cdot \left(y \cdot 4\right)}\\
\mathbf{if}\;x \leq -5.93 \cdot 10^{+88}:\\
\;\;\;\;1\\
\mathbf{elif}\;x \leq -5.2 \cdot 10^{-161}:\\
\;\;\;\;\frac{t_1}{\mathsf{fma}\left(y \cdot 4, y, x \cdot x\right)}\\
\mathbf{elif}\;x \leq 5.7 \cdot 10^{-160}:\\
\;\;\;\;\mathsf{fma}\left(t_0, 0.5, -1\right)\\
\mathbf{elif}\;x \leq 1.55 \cdot 10^{-29}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq 1.4 \cdot 10^{+24}:\\
\;\;\;\;-1 + \frac{t_0}{4}\\
\mathbf{elif}\;x \leq 6 \cdot 10^{+57}:\\
\;\;\;\;t_2\\
\mathbf{else}:\\
\;\;\;\;1\\
\end{array}
\]
double code(double x, double y) {
return ((x * x) - ((y * 4.0) * y)) / ((x * x) + ((y * 4.0) * y));
}
↓
double code(double x, double y) {
double t_0 = (x / y) * (x / y);
double t_1 = (x * x) + (y * (y * -4.0));
double t_2 = t_1 / ((x * x) + (y * (y * 4.0)));
double tmp;
if (x <= -5.93e+88) {
tmp = 1.0;
} else if (x <= -5.2e-161) {
tmp = t_1 / fma((y * 4.0), y, (x * x));
} else if (x <= 5.7e-160) {
tmp = fma(t_0, 0.5, -1.0);
} else if (x <= 1.55e-29) {
tmp = t_2;
} else if (x <= 1.4e+24) {
tmp = -1.0 + (t_0 / 4.0);
} else if (x <= 6e+57) {
tmp = t_2;
} else {
tmp = 1.0;
}
return tmp;
}
function code(x, y)
return Float64(Float64(Float64(x * x) - Float64(Float64(y * 4.0) * y)) / Float64(Float64(x * x) + Float64(Float64(y * 4.0) * y)))
end
↓
function code(x, y)
t_0 = Float64(Float64(x / y) * Float64(x / y))
t_1 = Float64(Float64(x * x) + Float64(y * Float64(y * -4.0)))
t_2 = Float64(t_1 / Float64(Float64(x * x) + Float64(y * Float64(y * 4.0))))
tmp = 0.0
if (x <= -5.93e+88)
tmp = 1.0;
elseif (x <= -5.2e-161)
tmp = Float64(t_1 / fma(Float64(y * 4.0), y, Float64(x * x)));
elseif (x <= 5.7e-160)
tmp = fma(t_0, 0.5, -1.0);
elseif (x <= 1.55e-29)
tmp = t_2;
elseif (x <= 1.4e+24)
tmp = Float64(-1.0 + Float64(t_0 / 4.0));
elseif (x <= 6e+57)
tmp = t_2;
else
tmp = 1.0;
end
return tmp
end
code[x_, y_] := N[(N[(N[(x * x), $MachinePrecision] - N[(N[(y * 4.0), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision] / N[(N[(x * x), $MachinePrecision] + N[(N[(y * 4.0), $MachinePrecision] * y), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]
↓
code[x_, y_] := Block[{t$95$0 = N[(N[(x / y), $MachinePrecision] * N[(x / y), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[(x * x), $MachinePrecision] + N[(y * N[(y * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(t$95$1 / N[(N[(x * x), $MachinePrecision] + N[(y * N[(y * 4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[x, -5.93e+88], 1.0, If[LessEqual[x, -5.2e-161], N[(t$95$1 / N[(N[(y * 4.0), $MachinePrecision] * y + N[(x * x), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 5.7e-160], N[(t$95$0 * 0.5 + -1.0), $MachinePrecision], If[LessEqual[x, 1.55e-29], t$95$2, If[LessEqual[x, 1.4e+24], N[(-1.0 + N[(t$95$0 / 4.0), $MachinePrecision]), $MachinePrecision], If[LessEqual[x, 6e+57], t$95$2, 1.0]]]]]]]]]
\frac{x \cdot x - \left(y \cdot 4\right) \cdot y}{x \cdot x + \left(y \cdot 4\right) \cdot y}
↓
\begin{array}{l}
t_0 := \frac{x}{y} \cdot \frac{x}{y}\\
t_1 := x \cdot x + y \cdot \left(y \cdot -4\right)\\
t_2 := \frac{t_1}{x \cdot x + y \cdot \left(y \cdot 4\right)}\\
\mathbf{if}\;x \leq -5.93 \cdot 10^{+88}:\\
\;\;\;\;1\\
\mathbf{elif}\;x \leq -5.2 \cdot 10^{-161}:\\
\;\;\;\;\frac{t_1}{\mathsf{fma}\left(y \cdot 4, y, x \cdot x\right)}\\
\mathbf{elif}\;x \leq 5.7 \cdot 10^{-160}:\\
\;\;\;\;\mathsf{fma}\left(t_0, 0.5, -1\right)\\
\mathbf{elif}\;x \leq 1.55 \cdot 10^{-29}:\\
\;\;\;\;t_2\\
\mathbf{elif}\;x \leq 1.4 \cdot 10^{+24}:\\
\;\;\;\;-1 + \frac{t_0}{4}\\
\mathbf{elif}\;x \leq 6 \cdot 10^{+57}:\\
\;\;\;\;t_2\\
\mathbf{else}:\\
\;\;\;\;1\\
\end{array}