\[\sqrt{2 \cdot \left(x \cdot x\right)}
\]
↓
\[\begin{array}{l}
t_0 := \left(x + x\right) \cdot x\\
t_1 := t_0 \ne 0\\
\mathbf{if}\;t_1:\\
\;\;\;\;\begin{array}{l}
\mathbf{if}\;t_1:\\
\;\;\;\;\mathsf{hypot}\left(x, x\right)\\
\mathbf{else}:\\
\;\;\;\;{\left({t_0}^{-0.5}\right)}^{-1}\\
\end{array}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2} \cdot \left|x\right|\\
\end{array}
\]
(FPCore (x) :precision binary64 (sqrt (* 2.0 (* x x))))
↓
(FPCore (x)
:precision binary64
(let* ((t_0 (* (+ x x) x)) (t_1 (!= t_0 0.0)))
(if t_1
(if t_1 (hypot x x) (pow (pow t_0 -0.5) -1.0))
(* (sqrt 2.0) (fabs x)))))double code(double x) {
return sqrt((2.0 * (x * x)));
}
↓
double code(double x) {
double t_0 = (x + x) * x;
int t_1 = t_0 != 0.0;
double tmp_1;
if (t_1) {
double tmp_2;
if (t_1) {
tmp_2 = hypot(x, x);
} else {
tmp_2 = pow(pow(t_0, -0.5), -1.0);
}
tmp_1 = tmp_2;
} else {
tmp_1 = sqrt(2.0) * fabs(x);
}
return tmp_1;
}
public static double code(double x) {
return Math.sqrt((2.0 * (x * x)));
}
↓
public static double code(double x) {
double t_0 = (x + x) * x;
boolean t_1 = t_0 != 0.0;
double tmp_1;
if (t_1) {
double tmp_2;
if (t_1) {
tmp_2 = Math.hypot(x, x);
} else {
tmp_2 = Math.pow(Math.pow(t_0, -0.5), -1.0);
}
tmp_1 = tmp_2;
} else {
tmp_1 = Math.sqrt(2.0) * Math.abs(x);
}
return tmp_1;
}
def code(x):
return math.sqrt((2.0 * (x * x)))
↓
def code(x):
t_0 = (x + x) * x
t_1 = t_0 != 0.0
tmp_1 = 0
if t_1:
tmp_2 = 0
if t_1:
tmp_2 = math.hypot(x, x)
else:
tmp_2 = math.pow(math.pow(t_0, -0.5), -1.0)
tmp_1 = tmp_2
else:
tmp_1 = math.sqrt(2.0) * math.fabs(x)
return tmp_1
function code(x)
return sqrt(Float64(2.0 * Float64(x * x)))
end
↓
function code(x)
t_0 = Float64(Float64(x + x) * x)
t_1 = t_0 != 0.0
tmp_1 = 0.0
if (t_1)
tmp_2 = 0.0
if (t_1)
tmp_2 = hypot(x, x);
else
tmp_2 = (t_0 ^ -0.5) ^ -1.0;
end
tmp_1 = tmp_2;
else
tmp_1 = Float64(sqrt(2.0) * abs(x));
end
return tmp_1
end
function tmp = code(x)
tmp = sqrt((2.0 * (x * x)));
end
↓
function tmp_4 = code(x)
t_0 = (x + x) * x;
t_1 = t_0 ~= 0.0;
tmp_2 = 0.0;
if (t_1)
tmp_3 = 0.0;
if (t_1)
tmp_3 = hypot(x, x);
else
tmp_3 = (t_0 ^ -0.5) ^ -1.0;
end
tmp_2 = tmp_3;
else
tmp_2 = sqrt(2.0) * abs(x);
end
tmp_4 = tmp_2;
end
code[x_] := N[Sqrt[N[(2.0 * N[(x * x), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
↓
code[x_] := Block[{t$95$0 = N[(N[(x + x), $MachinePrecision] * x), $MachinePrecision]}, Block[{t$95$1 = Unequal[t$95$0, 0.0]}, If[t$95$1, If[t$95$1, N[Sqrt[x ^ 2 + x ^ 2], $MachinePrecision], N[Power[N[Power[t$95$0, -0.5], $MachinePrecision], -1.0], $MachinePrecision]], N[(N[Sqrt[2.0], $MachinePrecision] * N[Abs[x], $MachinePrecision]), $MachinePrecision]]]]
\sqrt{2 \cdot \left(x \cdot x\right)}
↓
\begin{array}{l}
t_0 := \left(x + x\right) \cdot x\\
t_1 := t_0 \ne 0\\
\mathbf{if}\;t_1:\\
\;\;\;\;\begin{array}{l}
\mathbf{if}\;t_1:\\
\;\;\;\;\mathsf{hypot}\left(x, x\right)\\
\mathbf{else}:\\
\;\;\;\;{\left({t_0}^{-0.5}\right)}^{-1}\\
\end{array}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2} \cdot \left|x\right|\\
\end{array}