
(FPCore (x y z) :precision binary64 (* 2.0 (sqrt (+ (+ (* x y) (* x z)) (* y z)))))
double code(double x, double y, double z) {
return 2.0 * sqrt((((x * y) + (x * z)) + (y * z)));
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = 2.0d0 * sqrt((((x * y) + (x * z)) + (y * z)))
end function
public static double code(double x, double y, double z) {
return 2.0 * Math.sqrt((((x * y) + (x * z)) + (y * z)));
}
def code(x, y, z): return 2.0 * math.sqrt((((x * y) + (x * z)) + (y * z)))
function code(x, y, z) return Float64(2.0 * sqrt(Float64(Float64(Float64(x * y) + Float64(x * z)) + Float64(y * z)))) end
function tmp = code(x, y, z) tmp = 2.0 * sqrt((((x * y) + (x * z)) + (y * z))); end
code[x_, y_, z_] := N[(2.0 * N[Sqrt[N[(N[(N[(x * y), $MachinePrecision] + N[(x * z), $MachinePrecision]), $MachinePrecision] + N[(y * z), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
2 \cdot \sqrt{\left(x \cdot y + x \cdot z\right) + y \cdot z}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 11 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (x y z) :precision binary64 (* 2.0 (sqrt (+ (+ (* x y) (* x z)) (* y z)))))
double code(double x, double y, double z) {
return 2.0 * sqrt((((x * y) + (x * z)) + (y * z)));
}
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = 2.0d0 * sqrt((((x * y) + (x * z)) + (y * z)))
end function
public static double code(double x, double y, double z) {
return 2.0 * Math.sqrt((((x * y) + (x * z)) + (y * z)));
}
def code(x, y, z): return 2.0 * math.sqrt((((x * y) + (x * z)) + (y * z)))
function code(x, y, z) return Float64(2.0 * sqrt(Float64(Float64(Float64(x * y) + Float64(x * z)) + Float64(y * z)))) end
function tmp = code(x, y, z) tmp = 2.0 * sqrt((((x * y) + (x * z)) + (y * z))); end
code[x_, y_, z_] := N[(2.0 * N[Sqrt[N[(N[(N[(x * y), $MachinePrecision] + N[(x * z), $MachinePrecision]), $MachinePrecision] + N[(y * z), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
\\
2 \cdot \sqrt{\left(x \cdot y + x \cdot z\right) + y \cdot z}
\end{array}
NOTE: x, y, and z should be sorted in increasing order before calling this function.
(FPCore (x y z)
:precision binary64
(let* ((t_0 (log (/ -1.0 x)))
(t_1 (- t_0))
(t_2 (log (- (- z) y)))
(t_3 (sqrt t_2)))
(if (<= y -2.8e+32)
(* 2.0 (exp (* (+ (fma t_3 t_3 t_1) (fma t_1 1.0 t_0)) 0.5)))
(if (<= y -2.8e-209)
(* 2.0 (sqrt (+ (* z (+ y x)) (* y x))))
(if (<= y 1.95e-271)
(* 2.0 (exp (* 0.5 (- t_2 t_0))))
(* 2.0 (* (sqrt z) (sqrt y))))))))assert(x < y && y < z);
double code(double x, double y, double z) {
double t_0 = log((-1.0 / x));
double t_1 = -t_0;
double t_2 = log((-z - y));
double t_3 = sqrt(t_2);
double tmp;
if (y <= -2.8e+32) {
tmp = 2.0 * exp(((fma(t_3, t_3, t_1) + fma(t_1, 1.0, t_0)) * 0.5));
} else if (y <= -2.8e-209) {
tmp = 2.0 * sqrt(((z * (y + x)) + (y * x)));
} else if (y <= 1.95e-271) {
tmp = 2.0 * exp((0.5 * (t_2 - t_0)));
} else {
tmp = 2.0 * (sqrt(z) * sqrt(y));
}
return tmp;
}
x, y, z = sort([x, y, z]) function code(x, y, z) t_0 = log(Float64(-1.0 / x)) t_1 = Float64(-t_0) t_2 = log(Float64(Float64(-z) - y)) t_3 = sqrt(t_2) tmp = 0.0 if (y <= -2.8e+32) tmp = Float64(2.0 * exp(Float64(Float64(fma(t_3, t_3, t_1) + fma(t_1, 1.0, t_0)) * 0.5))); elseif (y <= -2.8e-209) tmp = Float64(2.0 * sqrt(Float64(Float64(z * Float64(y + x)) + Float64(y * x)))); elseif (y <= 1.95e-271) tmp = Float64(2.0 * exp(Float64(0.5 * Float64(t_2 - t_0)))); else tmp = Float64(2.0 * Float64(sqrt(z) * sqrt(y))); end return tmp end
NOTE: x, y, and z should be sorted in increasing order before calling this function.
code[x_, y_, z_] := Block[{t$95$0 = N[Log[N[(-1.0 / x), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$1 = (-t$95$0)}, Block[{t$95$2 = N[Log[N[((-z) - y), $MachinePrecision]], $MachinePrecision]}, Block[{t$95$3 = N[Sqrt[t$95$2], $MachinePrecision]}, If[LessEqual[y, -2.8e+32], N[(2.0 * N[Exp[N[(N[(N[(t$95$3 * t$95$3 + t$95$1), $MachinePrecision] + N[(t$95$1 * 1.0 + t$95$0), $MachinePrecision]), $MachinePrecision] * 0.5), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -2.8e-209], N[(2.0 * N[Sqrt[N[(N[(z * N[(y + x), $MachinePrecision]), $MachinePrecision] + N[(y * x), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 1.95e-271], N[(2.0 * N[Exp[N[(0.5 * N[(t$95$2 - t$95$0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(2.0 * N[(N[Sqrt[z], $MachinePrecision] * N[Sqrt[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]
\begin{array}{l}
[x, y, z] = \mathsf{sort}([x, y, z])\\
\\
\begin{array}{l}
t_0 := \log \left(\frac{-1}{x}\right)\\
t_1 := -t_0\\
t_2 := \log \left(\left(-z\right) - y\right)\\
t_3 := \sqrt{t_2}\\
\mathbf{if}\;y \leq -2.8 \cdot 10^{+32}:\\
\;\;\;\;2 \cdot e^{\left(\mathsf{fma}\left(t_3, t_3, t_1\right) + \mathsf{fma}\left(t_1, 1, t_0\right)\right) \cdot 0.5}\\
\mathbf{elif}\;y \leq -2.8 \cdot 10^{-209}:\\
\;\;\;\;2 \cdot \sqrt{z \cdot \left(y + x\right) + y \cdot x}\\
\mathbf{elif}\;y \leq 1.95 \cdot 10^{-271}:\\
\;\;\;\;2 \cdot e^{0.5 \cdot \left(t_2 - t_0\right)}\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \left(\sqrt{z} \cdot \sqrt{y}\right)\\
\end{array}
\end{array}
if y < -2.8e32Initial program 48.9%
distribute-lft-out48.9%
Simplified48.9%
distribute-lft-in48.9%
associate-+l+48.9%
+-commutative48.9%
distribute-rgt-in48.9%
fma-udef49.1%
pow1/249.1%
pow-to-exp45.8%
fma-udef45.6%
distribute-rgt-in45.6%
+-commutative45.6%
fma-def45.6%
distribute-rgt-in45.6%
Applied egg-rr45.6%
Taylor expanded in x around -inf 47.9%
+-commutative47.9%
mul-1-neg47.9%
unsub-neg47.9%
mul-1-neg47.9%
unsub-neg47.9%
mul-1-neg47.9%
Simplified47.9%
add-sqr-sqrt47.6%
*-un-lft-identity47.6%
prod-diff47.7%
Applied egg-rr47.7%
if -2.8e32 < y < -2.80000000000000012e-209Initial program 77.1%
associate-+l+77.1%
+-commutative77.1%
distribute-rgt-out77.1%
fma-def77.1%
Simplified77.1%
fma-udef77.1%
Applied egg-rr77.1%
if -2.80000000000000012e-209 < y < 1.94999999999999999e-271Initial program 64.7%
distribute-lft-out64.7%
Simplified64.7%
distribute-lft-in64.7%
associate-+l+64.7%
+-commutative64.7%
distribute-rgt-in64.7%
fma-udef64.7%
pow1/264.7%
pow-to-exp60.0%
fma-udef60.0%
distribute-rgt-in60.0%
+-commutative60.0%
fma-def60.0%
distribute-rgt-in60.0%
Applied egg-rr60.0%
Taylor expanded in x around -inf 54.5%
+-commutative54.5%
mul-1-neg54.5%
unsub-neg54.5%
mul-1-neg54.5%
unsub-neg54.5%
mul-1-neg54.5%
Simplified54.5%
if 1.94999999999999999e-271 < y Initial program 76.1%
distribute-lft-out76.1%
Simplified76.1%
Taylor expanded in x around 0 35.1%
pow1/235.1%
*-commutative35.1%
metadata-eval35.1%
unpow-prod-down44.7%
metadata-eval44.7%
pow1/244.7%
metadata-eval44.7%
pow1/244.7%
Applied egg-rr44.7%
Final simplification53.0%
NOTE: x, y, and z should be sorted in increasing order before calling this function.
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* 2.0 (exp (* 0.5 (- (log (- (- z) y)) (log (/ -1.0 x))))))))
(if (<= y -3.2e+31)
t_0
(if (<= y -3.5e-208)
(* 2.0 (sqrt (+ (* z (+ y x)) (* y x))))
(if (<= y 4.7e-271) t_0 (* 2.0 (* (sqrt z) (sqrt y))))))))assert(x < y && y < z);
double code(double x, double y, double z) {
double t_0 = 2.0 * exp((0.5 * (log((-z - y)) - log((-1.0 / x)))));
double tmp;
if (y <= -3.2e+31) {
tmp = t_0;
} else if (y <= -3.5e-208) {
tmp = 2.0 * sqrt(((z * (y + x)) + (y * x)));
} else if (y <= 4.7e-271) {
tmp = t_0;
} else {
tmp = 2.0 * (sqrt(z) * sqrt(y));
}
return tmp;
}
NOTE: x, y, and z should be sorted in increasing order before calling this function.
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 = 2.0d0 * exp((0.5d0 * (log((-z - y)) - log(((-1.0d0) / x)))))
if (y <= (-3.2d+31)) then
tmp = t_0
else if (y <= (-3.5d-208)) then
tmp = 2.0d0 * sqrt(((z * (y + x)) + (y * x)))
else if (y <= 4.7d-271) then
tmp = t_0
else
tmp = 2.0d0 * (sqrt(z) * sqrt(y))
end if
code = tmp
end function
assert x < y && y < z;
public static double code(double x, double y, double z) {
double t_0 = 2.0 * Math.exp((0.5 * (Math.log((-z - y)) - Math.log((-1.0 / x)))));
double tmp;
if (y <= -3.2e+31) {
tmp = t_0;
} else if (y <= -3.5e-208) {
tmp = 2.0 * Math.sqrt(((z * (y + x)) + (y * x)));
} else if (y <= 4.7e-271) {
tmp = t_0;
} else {
tmp = 2.0 * (Math.sqrt(z) * Math.sqrt(y));
}
return tmp;
}
[x, y, z] = sort([x, y, z]) def code(x, y, z): t_0 = 2.0 * math.exp((0.5 * (math.log((-z - y)) - math.log((-1.0 / x))))) tmp = 0 if y <= -3.2e+31: tmp = t_0 elif y <= -3.5e-208: tmp = 2.0 * math.sqrt(((z * (y + x)) + (y * x))) elif y <= 4.7e-271: tmp = t_0 else: tmp = 2.0 * (math.sqrt(z) * math.sqrt(y)) return tmp
x, y, z = sort([x, y, z]) function code(x, y, z) t_0 = Float64(2.0 * exp(Float64(0.5 * Float64(log(Float64(Float64(-z) - y)) - log(Float64(-1.0 / x)))))) tmp = 0.0 if (y <= -3.2e+31) tmp = t_0; elseif (y <= -3.5e-208) tmp = Float64(2.0 * sqrt(Float64(Float64(z * Float64(y + x)) + Float64(y * x)))); elseif (y <= 4.7e-271) tmp = t_0; else tmp = Float64(2.0 * Float64(sqrt(z) * sqrt(y))); end return tmp end
x, y, z = num2cell(sort([x, y, z])){:}
function tmp_2 = code(x, y, z)
t_0 = 2.0 * exp((0.5 * (log((-z - y)) - log((-1.0 / x)))));
tmp = 0.0;
if (y <= -3.2e+31)
tmp = t_0;
elseif (y <= -3.5e-208)
tmp = 2.0 * sqrt(((z * (y + x)) + (y * x)));
elseif (y <= 4.7e-271)
tmp = t_0;
else
tmp = 2.0 * (sqrt(z) * sqrt(y));
end
tmp_2 = tmp;
end
NOTE: x, y, and z should be sorted in increasing order before calling this function.
code[x_, y_, z_] := Block[{t$95$0 = N[(2.0 * N[Exp[N[(0.5 * N[(N[Log[N[((-z) - y), $MachinePrecision]], $MachinePrecision] - N[Log[N[(-1.0 / x), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -3.2e+31], t$95$0, If[LessEqual[y, -3.5e-208], N[(2.0 * N[Sqrt[N[(N[(z * N[(y + x), $MachinePrecision]), $MachinePrecision] + N[(y * x), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y, 4.7e-271], t$95$0, N[(2.0 * N[(N[Sqrt[z], $MachinePrecision] * N[Sqrt[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
[x, y, z] = \mathsf{sort}([x, y, z])\\
\\
\begin{array}{l}
t_0 := 2 \cdot e^{0.5 \cdot \left(\log \left(\left(-z\right) - y\right) - \log \left(\frac{-1}{x}\right)\right)}\\
\mathbf{if}\;y \leq -3.2 \cdot 10^{+31}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;y \leq -3.5 \cdot 10^{-208}:\\
\;\;\;\;2 \cdot \sqrt{z \cdot \left(y + x\right) + y \cdot x}\\
\mathbf{elif}\;y \leq 4.7 \cdot 10^{-271}:\\
\;\;\;\;t_0\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \left(\sqrt{z} \cdot \sqrt{y}\right)\\
\end{array}
\end{array}
if y < -3.2000000000000001e31 or -3.49999999999999991e-208 < y < 4.70000000000000005e-271Initial program 54.2%
distribute-lft-out54.2%
Simplified54.2%
distribute-lft-in54.2%
associate-+l+54.2%
+-commutative54.2%
distribute-rgt-in54.2%
fma-udef54.3%
pow1/254.3%
pow-to-exp50.5%
fma-udef50.4%
distribute-rgt-in50.4%
+-commutative50.4%
fma-def50.4%
distribute-rgt-in50.4%
Applied egg-rr50.4%
Taylor expanded in x around -inf 50.1%
+-commutative50.1%
mul-1-neg50.1%
unsub-neg50.1%
mul-1-neg50.1%
unsub-neg50.1%
mul-1-neg50.1%
Simplified50.1%
if -3.2000000000000001e31 < y < -3.49999999999999991e-208Initial program 77.1%
associate-+l+77.1%
+-commutative77.1%
distribute-rgt-out77.1%
fma-def77.1%
Simplified77.1%
fma-udef77.1%
Applied egg-rr77.1%
if 4.70000000000000005e-271 < y Initial program 76.1%
distribute-lft-out76.1%
Simplified76.1%
Taylor expanded in x around 0 35.1%
pow1/235.1%
*-commutative35.1%
metadata-eval35.1%
unpow-prod-down44.7%
metadata-eval44.7%
pow1/244.7%
metadata-eval44.7%
pow1/244.7%
Applied egg-rr44.7%
Final simplification53.1%
NOTE: x, y, and z should be sorted in increasing order before calling this function.
(FPCore (x y z)
:precision binary64
(let* ((t_0 (* 2.0 (exp (* 0.5 (- (log (- y)) (log (/ -1.0 x))))))))
(if (<= y -1.4e+34)
t_0
(if (<= y -2.8e-209)
(* 2.0 (sqrt (+ (* z (+ y x)) (* y x))))
(if (<= y -1e-310) t_0 (* 2.0 (* (sqrt z) (sqrt y))))))))assert(x < y && y < z);
double code(double x, double y, double z) {
double t_0 = 2.0 * exp((0.5 * (log(-y) - log((-1.0 / x)))));
double tmp;
if (y <= -1.4e+34) {
tmp = t_0;
} else if (y <= -2.8e-209) {
tmp = 2.0 * sqrt(((z * (y + x)) + (y * x)));
} else if (y <= -1e-310) {
tmp = t_0;
} else {
tmp = 2.0 * (sqrt(z) * sqrt(y));
}
return tmp;
}
NOTE: x, y, and z should be sorted in increasing order before calling this function.
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 = 2.0d0 * exp((0.5d0 * (log(-y) - log(((-1.0d0) / x)))))
if (y <= (-1.4d+34)) then
tmp = t_0
else if (y <= (-2.8d-209)) then
tmp = 2.0d0 * sqrt(((z * (y + x)) + (y * x)))
else if (y <= (-1d-310)) then
tmp = t_0
else
tmp = 2.0d0 * (sqrt(z) * sqrt(y))
end if
code = tmp
end function
assert x < y && y < z;
public static double code(double x, double y, double z) {
double t_0 = 2.0 * Math.exp((0.5 * (Math.log(-y) - Math.log((-1.0 / x)))));
double tmp;
if (y <= -1.4e+34) {
tmp = t_0;
} else if (y <= -2.8e-209) {
tmp = 2.0 * Math.sqrt(((z * (y + x)) + (y * x)));
} else if (y <= -1e-310) {
tmp = t_0;
} else {
tmp = 2.0 * (Math.sqrt(z) * Math.sqrt(y));
}
return tmp;
}
[x, y, z] = sort([x, y, z]) def code(x, y, z): t_0 = 2.0 * math.exp((0.5 * (math.log(-y) - math.log((-1.0 / x))))) tmp = 0 if y <= -1.4e+34: tmp = t_0 elif y <= -2.8e-209: tmp = 2.0 * math.sqrt(((z * (y + x)) + (y * x))) elif y <= -1e-310: tmp = t_0 else: tmp = 2.0 * (math.sqrt(z) * math.sqrt(y)) return tmp
x, y, z = sort([x, y, z]) function code(x, y, z) t_0 = Float64(2.0 * exp(Float64(0.5 * Float64(log(Float64(-y)) - log(Float64(-1.0 / x)))))) tmp = 0.0 if (y <= -1.4e+34) tmp = t_0; elseif (y <= -2.8e-209) tmp = Float64(2.0 * sqrt(Float64(Float64(z * Float64(y + x)) + Float64(y * x)))); elseif (y <= -1e-310) tmp = t_0; else tmp = Float64(2.0 * Float64(sqrt(z) * sqrt(y))); end return tmp end
x, y, z = num2cell(sort([x, y, z])){:}
function tmp_2 = code(x, y, z)
t_0 = 2.0 * exp((0.5 * (log(-y) - log((-1.0 / x)))));
tmp = 0.0;
if (y <= -1.4e+34)
tmp = t_0;
elseif (y <= -2.8e-209)
tmp = 2.0 * sqrt(((z * (y + x)) + (y * x)));
elseif (y <= -1e-310)
tmp = t_0;
else
tmp = 2.0 * (sqrt(z) * sqrt(y));
end
tmp_2 = tmp;
end
NOTE: x, y, and z should be sorted in increasing order before calling this function.
code[x_, y_, z_] := Block[{t$95$0 = N[(2.0 * N[Exp[N[(0.5 * N[(N[Log[(-y)], $MachinePrecision] - N[Log[N[(-1.0 / x), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[y, -1.4e+34], t$95$0, If[LessEqual[y, -2.8e-209], N[(2.0 * N[Sqrt[N[(N[(z * N[(y + x), $MachinePrecision]), $MachinePrecision] + N[(y * x), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[y, -1e-310], t$95$0, N[(2.0 * N[(N[Sqrt[z], $MachinePrecision] * N[Sqrt[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
[x, y, z] = \mathsf{sort}([x, y, z])\\
\\
\begin{array}{l}
t_0 := 2 \cdot e^{0.5 \cdot \left(\log \left(-y\right) - \log \left(\frac{-1}{x}\right)\right)}\\
\mathbf{if}\;y \leq -1.4 \cdot 10^{+34}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;y \leq -2.8 \cdot 10^{-209}:\\
\;\;\;\;2 \cdot \sqrt{z \cdot \left(y + x\right) + y \cdot x}\\
\mathbf{elif}\;y \leq -1 \cdot 10^{-310}:\\
\;\;\;\;t_0\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \left(\sqrt{z} \cdot \sqrt{y}\right)\\
\end{array}
\end{array}
if y < -1.40000000000000004e34 or -2.80000000000000012e-209 < y < -9.999999999999969e-311Initial program 55.1%
distribute-lft-out55.1%
Simplified55.1%
distribute-lft-in55.1%
associate-+l+55.1%
+-commutative55.1%
distribute-rgt-in55.1%
fma-udef55.2%
pow1/255.2%
pow-to-exp51.4%
fma-udef51.3%
distribute-rgt-in51.3%
+-commutative51.3%
fma-def51.3%
distribute-rgt-in51.3%
Applied egg-rr51.3%
Taylor expanded in x around -inf 51.6%
+-commutative51.6%
mul-1-neg51.6%
unsub-neg51.6%
mul-1-neg51.6%
unsub-neg51.6%
mul-1-neg51.6%
Simplified51.6%
Taylor expanded in z around 0 35.7%
if -1.40000000000000004e34 < y < -2.80000000000000012e-209Initial program 75.8%
associate-+l+75.8%
+-commutative75.8%
distribute-rgt-out75.8%
fma-def75.7%
Simplified75.7%
fma-udef75.8%
Applied egg-rr75.8%
if -9.999999999999969e-311 < y Initial program 74.7%
distribute-lft-out74.7%
Simplified74.7%
Taylor expanded in x around 0 33.3%
pow1/233.3%
*-commutative33.3%
metadata-eval33.3%
unpow-prod-down42.2%
metadata-eval42.2%
pow1/242.2%
metadata-eval42.2%
pow1/242.2%
Applied egg-rr42.2%
Final simplification47.8%
NOTE: x, y, and z should be sorted in increasing order before calling this function. (FPCore (x y z) :precision binary64 (if (<= y 4.7e-271) (* 2.0 (sqrt (fma z (+ y x) (* y x)))) (* 2.0 (* (sqrt z) (sqrt y)))))
assert(x < y && y < z);
double code(double x, double y, double z) {
double tmp;
if (y <= 4.7e-271) {
tmp = 2.0 * sqrt(fma(z, (y + x), (y * x)));
} else {
tmp = 2.0 * (sqrt(z) * sqrt(y));
}
return tmp;
}
x, y, z = sort([x, y, z]) function code(x, y, z) tmp = 0.0 if (y <= 4.7e-271) tmp = Float64(2.0 * sqrt(fma(z, Float64(y + x), Float64(y * x)))); else tmp = Float64(2.0 * Float64(sqrt(z) * sqrt(y))); end return tmp end
NOTE: x, y, and z should be sorted in increasing order before calling this function. code[x_, y_, z_] := If[LessEqual[y, 4.7e-271], N[(2.0 * N[Sqrt[N[(z * N[(y + x), $MachinePrecision] + N[(y * x), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(2.0 * N[(N[Sqrt[z], $MachinePrecision] * N[Sqrt[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z] = \mathsf{sort}([x, y, z])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq 4.7 \cdot 10^{-271}:\\
\;\;\;\;2 \cdot \sqrt{\mathsf{fma}\left(z, y + x, y \cdot x\right)}\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \left(\sqrt{z} \cdot \sqrt{y}\right)\\
\end{array}
\end{array}
if y < 4.70000000000000005e-271Initial program 63.8%
associate-+l+63.8%
+-commutative63.8%
distribute-rgt-out63.8%
fma-def63.8%
Simplified63.8%
if 4.70000000000000005e-271 < y Initial program 76.1%
distribute-lft-out76.1%
Simplified76.1%
Taylor expanded in x around 0 35.1%
pow1/235.1%
*-commutative35.1%
metadata-eval35.1%
unpow-prod-down44.7%
metadata-eval44.7%
pow1/244.7%
metadata-eval44.7%
pow1/244.7%
Applied egg-rr44.7%
Final simplification54.3%
NOTE: x, y, and z should be sorted in increasing order before calling this function. (FPCore (x y z) :precision binary64 (if (<= y 4.7e-271) (* 2.0 (sqrt (* x (+ y z)))) (* 2.0 (* (sqrt z) (sqrt y)))))
assert(x < y && y < z);
double code(double x, double y, double z) {
double tmp;
if (y <= 4.7e-271) {
tmp = 2.0 * sqrt((x * (y + z)));
} else {
tmp = 2.0 * (sqrt(z) * sqrt(y));
}
return tmp;
}
NOTE: x, y, and z should be sorted in increasing order before calling this function.
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 <= 4.7d-271) then
tmp = 2.0d0 * sqrt((x * (y + z)))
else
tmp = 2.0d0 * (sqrt(z) * sqrt(y))
end if
code = tmp
end function
assert x < y && y < z;
public static double code(double x, double y, double z) {
double tmp;
if (y <= 4.7e-271) {
tmp = 2.0 * Math.sqrt((x * (y + z)));
} else {
tmp = 2.0 * (Math.sqrt(z) * Math.sqrt(y));
}
return tmp;
}
[x, y, z] = sort([x, y, z]) def code(x, y, z): tmp = 0 if y <= 4.7e-271: tmp = 2.0 * math.sqrt((x * (y + z))) else: tmp = 2.0 * (math.sqrt(z) * math.sqrt(y)) return tmp
x, y, z = sort([x, y, z]) function code(x, y, z) tmp = 0.0 if (y <= 4.7e-271) tmp = Float64(2.0 * sqrt(Float64(x * Float64(y + z)))); else tmp = Float64(2.0 * Float64(sqrt(z) * sqrt(y))); end return tmp end
x, y, z = num2cell(sort([x, y, z])){:}
function tmp_2 = code(x, y, z)
tmp = 0.0;
if (y <= 4.7e-271)
tmp = 2.0 * sqrt((x * (y + z)));
else
tmp = 2.0 * (sqrt(z) * sqrt(y));
end
tmp_2 = tmp;
end
NOTE: x, y, and z should be sorted in increasing order before calling this function. code[x_, y_, z_] := If[LessEqual[y, 4.7e-271], N[(2.0 * N[Sqrt[N[(x * N[(y + z), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(2.0 * N[(N[Sqrt[z], $MachinePrecision] * N[Sqrt[y], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z] = \mathsf{sort}([x, y, z])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq 4.7 \cdot 10^{-271}:\\
\;\;\;\;2 \cdot \sqrt{x \cdot \left(y + z\right)}\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \left(\sqrt{z} \cdot \sqrt{y}\right)\\
\end{array}
\end{array}
if y < 4.70000000000000005e-271Initial program 63.8%
distribute-lft-out63.8%
Simplified63.8%
Taylor expanded in x around inf 44.7%
if 4.70000000000000005e-271 < y Initial program 76.1%
distribute-lft-out76.1%
Simplified76.1%
Taylor expanded in x around 0 35.1%
pow1/235.1%
*-commutative35.1%
metadata-eval35.1%
unpow-prod-down44.7%
metadata-eval44.7%
pow1/244.7%
metadata-eval44.7%
pow1/244.7%
Applied egg-rr44.7%
Final simplification44.7%
NOTE: x, y, and z should be sorted in increasing order before calling this function. (FPCore (x y z) :precision binary64 (* 2.0 (sqrt (+ (* x (+ y z)) (* y z)))))
assert(x < y && y < z);
double code(double x, double y, double z) {
return 2.0 * sqrt(((x * (y + z)) + (y * z)));
}
NOTE: x, y, and z should be sorted in increasing order before calling this function.
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = 2.0d0 * sqrt(((x * (y + z)) + (y * z)))
end function
assert x < y && y < z;
public static double code(double x, double y, double z) {
return 2.0 * Math.sqrt(((x * (y + z)) + (y * z)));
}
[x, y, z] = sort([x, y, z]) def code(x, y, z): return 2.0 * math.sqrt(((x * (y + z)) + (y * z)))
x, y, z = sort([x, y, z]) function code(x, y, z) return Float64(2.0 * sqrt(Float64(Float64(x * Float64(y + z)) + Float64(y * z)))) end
x, y, z = num2cell(sort([x, y, z])){:}
function tmp = code(x, y, z)
tmp = 2.0 * sqrt(((x * (y + z)) + (y * z)));
end
NOTE: x, y, and z should be sorted in increasing order before calling this function. code[x_, y_, z_] := N[(2.0 * N[Sqrt[N[(N[(x * N[(y + z), $MachinePrecision]), $MachinePrecision] + N[(y * z), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y, z] = \mathsf{sort}([x, y, z])\\
\\
2 \cdot \sqrt{x \cdot \left(y + z\right) + y \cdot z}
\end{array}
Initial program 69.9%
distribute-lft-out69.9%
Simplified69.9%
Final simplification69.9%
NOTE: x, y, and z should be sorted in increasing order before calling this function. (FPCore (x y z) :precision binary64 (* 2.0 (sqrt (+ (* z (+ y x)) (* y x)))))
assert(x < y && y < z);
double code(double x, double y, double z) {
return 2.0 * sqrt(((z * (y + x)) + (y * x)));
}
NOTE: x, y, and z should be sorted in increasing order before calling this function.
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = 2.0d0 * sqrt(((z * (y + x)) + (y * x)))
end function
assert x < y && y < z;
public static double code(double x, double y, double z) {
return 2.0 * Math.sqrt(((z * (y + x)) + (y * x)));
}
[x, y, z] = sort([x, y, z]) def code(x, y, z): return 2.0 * math.sqrt(((z * (y + x)) + (y * x)))
x, y, z = sort([x, y, z]) function code(x, y, z) return Float64(2.0 * sqrt(Float64(Float64(z * Float64(y + x)) + Float64(y * x)))) end
x, y, z = num2cell(sort([x, y, z])){:}
function tmp = code(x, y, z)
tmp = 2.0 * sqrt(((z * (y + x)) + (y * x)));
end
NOTE: x, y, and z should be sorted in increasing order before calling this function. code[x_, y_, z_] := N[(2.0 * N[Sqrt[N[(N[(z * N[(y + x), $MachinePrecision]), $MachinePrecision] + N[(y * x), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y, z] = \mathsf{sort}([x, y, z])\\
\\
2 \cdot \sqrt{z \cdot \left(y + x\right) + y \cdot x}
\end{array}
Initial program 69.9%
associate-+l+69.9%
+-commutative69.9%
distribute-rgt-out69.9%
fma-def69.9%
Simplified69.9%
fma-udef69.9%
Applied egg-rr69.9%
Final simplification69.9%
NOTE: x, y, and z should be sorted in increasing order before calling this function. (FPCore (x y z) :precision binary64 (if (<= y -2.3e-295) (* 2.0 (sqrt (* y x))) (* 2.0 (sqrt (* z (+ y x))))))
assert(x < y && y < z);
double code(double x, double y, double z) {
double tmp;
if (y <= -2.3e-295) {
tmp = 2.0 * sqrt((y * x));
} else {
tmp = 2.0 * sqrt((z * (y + x)));
}
return tmp;
}
NOTE: x, y, and z should be sorted in increasing order before calling this function.
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 <= (-2.3d-295)) then
tmp = 2.0d0 * sqrt((y * x))
else
tmp = 2.0d0 * sqrt((z * (y + x)))
end if
code = tmp
end function
assert x < y && y < z;
public static double code(double x, double y, double z) {
double tmp;
if (y <= -2.3e-295) {
tmp = 2.0 * Math.sqrt((y * x));
} else {
tmp = 2.0 * Math.sqrt((z * (y + x)));
}
return tmp;
}
[x, y, z] = sort([x, y, z]) def code(x, y, z): tmp = 0 if y <= -2.3e-295: tmp = 2.0 * math.sqrt((y * x)) else: tmp = 2.0 * math.sqrt((z * (y + x))) return tmp
x, y, z = sort([x, y, z]) function code(x, y, z) tmp = 0.0 if (y <= -2.3e-295) tmp = Float64(2.0 * sqrt(Float64(y * x))); else tmp = Float64(2.0 * sqrt(Float64(z * Float64(y + x)))); end return tmp end
x, y, z = num2cell(sort([x, y, z])){:}
function tmp_2 = code(x, y, z)
tmp = 0.0;
if (y <= -2.3e-295)
tmp = 2.0 * sqrt((y * x));
else
tmp = 2.0 * sqrt((z * (y + x)));
end
tmp_2 = tmp;
end
NOTE: x, y, and z should be sorted in increasing order before calling this function. code[x_, y_, z_] := If[LessEqual[y, -2.3e-295], N[(2.0 * N[Sqrt[N[(y * x), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(2.0 * N[Sqrt[N[(z * N[(y + x), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z] = \mathsf{sort}([x, y, z])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -2.3 \cdot 10^{-295}:\\
\;\;\;\;2 \cdot \sqrt{y \cdot x}\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \sqrt{z \cdot \left(y + x\right)}\\
\end{array}
\end{array}
if y < -2.3e-295Initial program 64.5%
distribute-lft-out64.5%
Simplified64.5%
Taylor expanded in z around 0 24.0%
if -2.3e-295 < y Initial program 74.7%
distribute-lft-out74.7%
Simplified74.7%
Taylor expanded in z around inf 54.8%
Final simplification40.3%
NOTE: x, y, and z should be sorted in increasing order before calling this function. (FPCore (x y z) :precision binary64 (if (<= y -1e-266) (* 2.0 (sqrt (* x (+ y z)))) (* 2.0 (sqrt (* z (+ y x))))))
assert(x < y && y < z);
double code(double x, double y, double z) {
double tmp;
if (y <= -1e-266) {
tmp = 2.0 * sqrt((x * (y + z)));
} else {
tmp = 2.0 * sqrt((z * (y + x)));
}
return tmp;
}
NOTE: x, y, and z should be sorted in increasing order before calling this function.
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 <= (-1d-266)) then
tmp = 2.0d0 * sqrt((x * (y + z)))
else
tmp = 2.0d0 * sqrt((z * (y + x)))
end if
code = tmp
end function
assert x < y && y < z;
public static double code(double x, double y, double z) {
double tmp;
if (y <= -1e-266) {
tmp = 2.0 * Math.sqrt((x * (y + z)));
} else {
tmp = 2.0 * Math.sqrt((z * (y + x)));
}
return tmp;
}
[x, y, z] = sort([x, y, z]) def code(x, y, z): tmp = 0 if y <= -1e-266: tmp = 2.0 * math.sqrt((x * (y + z))) else: tmp = 2.0 * math.sqrt((z * (y + x))) return tmp
x, y, z = sort([x, y, z]) function code(x, y, z) tmp = 0.0 if (y <= -1e-266) tmp = Float64(2.0 * sqrt(Float64(x * Float64(y + z)))); else tmp = Float64(2.0 * sqrt(Float64(z * Float64(y + x)))); end return tmp end
x, y, z = num2cell(sort([x, y, z])){:}
function tmp_2 = code(x, y, z)
tmp = 0.0;
if (y <= -1e-266)
tmp = 2.0 * sqrt((x * (y + z)));
else
tmp = 2.0 * sqrt((z * (y + x)));
end
tmp_2 = tmp;
end
NOTE: x, y, and z should be sorted in increasing order before calling this function. code[x_, y_, z_] := If[LessEqual[y, -1e-266], N[(2.0 * N[Sqrt[N[(x * N[(y + z), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(2.0 * N[Sqrt[N[(z * N[(y + x), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z] = \mathsf{sort}([x, y, z])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1 \cdot 10^{-266}:\\
\;\;\;\;2 \cdot \sqrt{x \cdot \left(y + z\right)}\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \sqrt{z \cdot \left(y + x\right)}\\
\end{array}
\end{array}
if y < -9.9999999999999998e-267Initial program 63.8%
distribute-lft-out63.8%
Simplified63.8%
Taylor expanded in x around inf 42.6%
if -9.9999999999999998e-267 < y Initial program 75.0%
distribute-lft-out75.0%
Simplified75.0%
Taylor expanded in z around inf 55.8%
Final simplification49.8%
NOTE: x, y, and z should be sorted in increasing order before calling this function. (FPCore (x y z) :precision binary64 (if (<= y -1e-310) (* 2.0 (sqrt (* y x))) (* 2.0 (sqrt (* y z)))))
assert(x < y && y < z);
double code(double x, double y, double z) {
double tmp;
if (y <= -1e-310) {
tmp = 2.0 * sqrt((y * x));
} else {
tmp = 2.0 * sqrt((y * z));
}
return tmp;
}
NOTE: x, y, and z should be sorted in increasing order before calling this function.
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 <= (-1d-310)) then
tmp = 2.0d0 * sqrt((y * x))
else
tmp = 2.0d0 * sqrt((y * z))
end if
code = tmp
end function
assert x < y && y < z;
public static double code(double x, double y, double z) {
double tmp;
if (y <= -1e-310) {
tmp = 2.0 * Math.sqrt((y * x));
} else {
tmp = 2.0 * Math.sqrt((y * z));
}
return tmp;
}
[x, y, z] = sort([x, y, z]) def code(x, y, z): tmp = 0 if y <= -1e-310: tmp = 2.0 * math.sqrt((y * x)) else: tmp = 2.0 * math.sqrt((y * z)) return tmp
x, y, z = sort([x, y, z]) function code(x, y, z) tmp = 0.0 if (y <= -1e-310) tmp = Float64(2.0 * sqrt(Float64(y * x))); else tmp = Float64(2.0 * sqrt(Float64(y * z))); end return tmp end
x, y, z = num2cell(sort([x, y, z])){:}
function tmp_2 = code(x, y, z)
tmp = 0.0;
if (y <= -1e-310)
tmp = 2.0 * sqrt((y * x));
else
tmp = 2.0 * sqrt((y * z));
end
tmp_2 = tmp;
end
NOTE: x, y, and z should be sorted in increasing order before calling this function. code[x_, y_, z_] := If[LessEqual[y, -1e-310], N[(2.0 * N[Sqrt[N[(y * x), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(2.0 * N[Sqrt[N[(y * z), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
[x, y, z] = \mathsf{sort}([x, y, z])\\
\\
\begin{array}{l}
\mathbf{if}\;y \leq -1 \cdot 10^{-310}:\\
\;\;\;\;2 \cdot \sqrt{y \cdot x}\\
\mathbf{else}:\\
\;\;\;\;2 \cdot \sqrt{y \cdot z}\\
\end{array}
\end{array}
if y < -9.999999999999969e-311Initial program 64.5%
distribute-lft-out64.5%
Simplified64.5%
Taylor expanded in z around 0 24.0%
if -9.999999999999969e-311 < y Initial program 74.7%
distribute-lft-out74.7%
Simplified74.7%
Taylor expanded in x around 0 33.3%
Final simplification28.9%
NOTE: x, y, and z should be sorted in increasing order before calling this function. (FPCore (x y z) :precision binary64 (* 2.0 (sqrt (* y x))))
assert(x < y && y < z);
double code(double x, double y, double z) {
return 2.0 * sqrt((y * x));
}
NOTE: x, y, and z should be sorted in increasing order before calling this function.
real(8) function code(x, y, z)
real(8), intent (in) :: x
real(8), intent (in) :: y
real(8), intent (in) :: z
code = 2.0d0 * sqrt((y * x))
end function
assert x < y && y < z;
public static double code(double x, double y, double z) {
return 2.0 * Math.sqrt((y * x));
}
[x, y, z] = sort([x, y, z]) def code(x, y, z): return 2.0 * math.sqrt((y * x))
x, y, z = sort([x, y, z]) function code(x, y, z) return Float64(2.0 * sqrt(Float64(y * x))) end
x, y, z = num2cell(sort([x, y, z])){:}
function tmp = code(x, y, z)
tmp = 2.0 * sqrt((y * x));
end
NOTE: x, y, and z should be sorted in increasing order before calling this function. code[x_, y_, z_] := N[(2.0 * N[Sqrt[N[(y * x), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
[x, y, z] = \mathsf{sort}([x, y, z])\\
\\
2 \cdot \sqrt{y \cdot x}
\end{array}
Initial program 69.9%
distribute-lft-out69.9%
Simplified69.9%
Taylor expanded in z around 0 22.7%
Final simplification22.7%
(FPCore (x y z)
:precision binary64
(let* ((t_0
(+
(* 0.25 (* (* (pow y -0.75) (* (pow z -0.75) x)) (+ y z)))
(* (pow z 0.25) (pow y 0.25)))))
(if (< z 7.636950090573675e+176)
(* 2.0 (sqrt (+ (* (+ x y) z) (* x y))))
(* (* t_0 t_0) 2.0))))
double code(double x, double y, double z) {
double t_0 = (0.25 * ((pow(y, -0.75) * (pow(z, -0.75) * x)) * (y + z))) + (pow(z, 0.25) * pow(y, 0.25));
double tmp;
if (z < 7.636950090573675e+176) {
tmp = 2.0 * sqrt((((x + y) * z) + (x * y)));
} else {
tmp = (t_0 * t_0) * 2.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 = (0.25d0 * (((y ** (-0.75d0)) * ((z ** (-0.75d0)) * x)) * (y + z))) + ((z ** 0.25d0) * (y ** 0.25d0))
if (z < 7.636950090573675d+176) then
tmp = 2.0d0 * sqrt((((x + y) * z) + (x * y)))
else
tmp = (t_0 * t_0) * 2.0d0
end if
code = tmp
end function
public static double code(double x, double y, double z) {
double t_0 = (0.25 * ((Math.pow(y, -0.75) * (Math.pow(z, -0.75) * x)) * (y + z))) + (Math.pow(z, 0.25) * Math.pow(y, 0.25));
double tmp;
if (z < 7.636950090573675e+176) {
tmp = 2.0 * Math.sqrt((((x + y) * z) + (x * y)));
} else {
tmp = (t_0 * t_0) * 2.0;
}
return tmp;
}
def code(x, y, z): t_0 = (0.25 * ((math.pow(y, -0.75) * (math.pow(z, -0.75) * x)) * (y + z))) + (math.pow(z, 0.25) * math.pow(y, 0.25)) tmp = 0 if z < 7.636950090573675e+176: tmp = 2.0 * math.sqrt((((x + y) * z) + (x * y))) else: tmp = (t_0 * t_0) * 2.0 return tmp
function code(x, y, z) t_0 = Float64(Float64(0.25 * Float64(Float64((y ^ -0.75) * Float64((z ^ -0.75) * x)) * Float64(y + z))) + Float64((z ^ 0.25) * (y ^ 0.25))) tmp = 0.0 if (z < 7.636950090573675e+176) tmp = Float64(2.0 * sqrt(Float64(Float64(Float64(x + y) * z) + Float64(x * y)))); else tmp = Float64(Float64(t_0 * t_0) * 2.0); end return tmp end
function tmp_2 = code(x, y, z) t_0 = (0.25 * (((y ^ -0.75) * ((z ^ -0.75) * x)) * (y + z))) + ((z ^ 0.25) * (y ^ 0.25)); tmp = 0.0; if (z < 7.636950090573675e+176) tmp = 2.0 * sqrt((((x + y) * z) + (x * y))); else tmp = (t_0 * t_0) * 2.0; end tmp_2 = tmp; end
code[x_, y_, z_] := Block[{t$95$0 = N[(N[(0.25 * N[(N[(N[Power[y, -0.75], $MachinePrecision] * N[(N[Power[z, -0.75], $MachinePrecision] * x), $MachinePrecision]), $MachinePrecision] * N[(y + z), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[Power[z, 0.25], $MachinePrecision] * N[Power[y, 0.25], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[Less[z, 7.636950090573675e+176], N[(2.0 * N[Sqrt[N[(N[(N[(x + y), $MachinePrecision] * z), $MachinePrecision] + N[(x * y), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[(t$95$0 * t$95$0), $MachinePrecision] * 2.0), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := 0.25 \cdot \left(\left({y}^{-0.75} \cdot \left({z}^{-0.75} \cdot x\right)\right) \cdot \left(y + z\right)\right) + {z}^{0.25} \cdot {y}^{0.25}\\
\mathbf{if}\;z < 7.636950090573675 \cdot 10^{+176}:\\
\;\;\;\;2 \cdot \sqrt{\left(x + y\right) \cdot z + x \cdot y}\\
\mathbf{else}:\\
\;\;\;\;\left(t_0 \cdot t_0\right) \cdot 2\\
\end{array}
\end{array}
herbie shell --seed 2023230
(FPCore (x y z)
:name "Diagrams.TwoD.Apollonian:descartes from diagrams-contrib-1.3.0.5"
:precision binary64
:herbie-target
(if (< z 7.636950090573675e+176) (* 2.0 (sqrt (+ (* (+ x y) z) (* x y)))) (* (* (+ (* 0.25 (* (* (pow y -0.75) (* (pow z -0.75) x)) (+ y z))) (* (pow z 0.25) (pow y 0.25))) (+ (* 0.25 (* (* (pow y -0.75) (* (pow z -0.75) x)) (+ y z))) (* (pow z 0.25) (pow y 0.25)))) 2.0))
(* 2.0 (sqrt (+ (+ (* x y) (* x z)) (* y z)))))