
(FPCore (A B C F)
:precision binary64
(let* ((t_0 (- (pow B 2.0) (* (* 4.0 A) C))))
(/
(-
(sqrt
(*
(* 2.0 (* t_0 F))
(+ (+ A C) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0)))))))
t_0)))
double code(double A, double B, double C, double F) {
double t_0 = pow(B, 2.0) - ((4.0 * A) * C);
return -sqrt(((2.0 * (t_0 * F)) * ((A + C) + sqrt((pow((A - C), 2.0) + pow(B, 2.0)))))) / t_0;
}
real(8) function code(a, b, c, f)
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: f
real(8) :: t_0
t_0 = (b ** 2.0d0) - ((4.0d0 * a) * c)
code = -sqrt(((2.0d0 * (t_0 * f)) * ((a + c) + sqrt((((a - c) ** 2.0d0) + (b ** 2.0d0)))))) / t_0
end function
public static double code(double A, double B, double C, double F) {
double t_0 = Math.pow(B, 2.0) - ((4.0 * A) * C);
return -Math.sqrt(((2.0 * (t_0 * F)) * ((A + C) + Math.sqrt((Math.pow((A - C), 2.0) + Math.pow(B, 2.0)))))) / t_0;
}
def code(A, B, C, F): t_0 = math.pow(B, 2.0) - ((4.0 * A) * C) return -math.sqrt(((2.0 * (t_0 * F)) * ((A + C) + math.sqrt((math.pow((A - C), 2.0) + math.pow(B, 2.0)))))) / t_0
function code(A, B, C, F) t_0 = Float64((B ^ 2.0) - Float64(Float64(4.0 * A) * C)) return Float64(Float64(-sqrt(Float64(Float64(2.0 * Float64(t_0 * F)) * Float64(Float64(A + C) + sqrt(Float64((Float64(A - C) ^ 2.0) + (B ^ 2.0))))))) / t_0) end
function tmp = code(A, B, C, F) t_0 = (B ^ 2.0) - ((4.0 * A) * C); tmp = -sqrt(((2.0 * (t_0 * F)) * ((A + C) + sqrt((((A - C) ^ 2.0) + (B ^ 2.0)))))) / t_0; end
code[A_, B_, C_, F_] := Block[{t$95$0 = N[(N[Power[B, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]}, N[((-N[Sqrt[N[(N[(2.0 * N[(t$95$0 * F), $MachinePrecision]), $MachinePrecision] * N[(N[(A + C), $MachinePrecision] + N[Sqrt[N[(N[Power[N[(A - C), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[B, 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := {B}^{2} - \left(4 \cdot A\right) \cdot C\\
\frac{-\sqrt{\left(2 \cdot \left(t_0 \cdot F\right)\right) \cdot \left(\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{t_0}
\end{array}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 20 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (A B C F)
:precision binary64
(let* ((t_0 (- (pow B 2.0) (* (* 4.0 A) C))))
(/
(-
(sqrt
(*
(* 2.0 (* t_0 F))
(+ (+ A C) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0)))))))
t_0)))
double code(double A, double B, double C, double F) {
double t_0 = pow(B, 2.0) - ((4.0 * A) * C);
return -sqrt(((2.0 * (t_0 * F)) * ((A + C) + sqrt((pow((A - C), 2.0) + pow(B, 2.0)))))) / t_0;
}
real(8) function code(a, b, c, f)
real(8), intent (in) :: a
real(8), intent (in) :: b
real(8), intent (in) :: c
real(8), intent (in) :: f
real(8) :: t_0
t_0 = (b ** 2.0d0) - ((4.0d0 * a) * c)
code = -sqrt(((2.0d0 * (t_0 * f)) * ((a + c) + sqrt((((a - c) ** 2.0d0) + (b ** 2.0d0)))))) / t_0
end function
public static double code(double A, double B, double C, double F) {
double t_0 = Math.pow(B, 2.0) - ((4.0 * A) * C);
return -Math.sqrt(((2.0 * (t_0 * F)) * ((A + C) + Math.sqrt((Math.pow((A - C), 2.0) + Math.pow(B, 2.0)))))) / t_0;
}
def code(A, B, C, F): t_0 = math.pow(B, 2.0) - ((4.0 * A) * C) return -math.sqrt(((2.0 * (t_0 * F)) * ((A + C) + math.sqrt((math.pow((A - C), 2.0) + math.pow(B, 2.0)))))) / t_0
function code(A, B, C, F) t_0 = Float64((B ^ 2.0) - Float64(Float64(4.0 * A) * C)) return Float64(Float64(-sqrt(Float64(Float64(2.0 * Float64(t_0 * F)) * Float64(Float64(A + C) + sqrt(Float64((Float64(A - C) ^ 2.0) + (B ^ 2.0))))))) / t_0) end
function tmp = code(A, B, C, F) t_0 = (B ^ 2.0) - ((4.0 * A) * C); tmp = -sqrt(((2.0 * (t_0 * F)) * ((A + C) + sqrt((((A - C) ^ 2.0) + (B ^ 2.0)))))) / t_0; end
code[A_, B_, C_, F_] := Block[{t$95$0 = N[(N[Power[B, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]}, N[((-N[Sqrt[N[(N[(2.0 * N[(t$95$0 * F), $MachinePrecision]), $MachinePrecision] * N[(N[(A + C), $MachinePrecision] + N[Sqrt[N[(N[Power[N[(A - C), $MachinePrecision], 2.0], $MachinePrecision] + N[Power[B, 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
t_0 := {B}^{2} - \left(4 \cdot A\right) \cdot C\\
\frac{-\sqrt{\left(2 \cdot \left(t_0 \cdot F\right)\right) \cdot \left(\left(A + C\right) + \sqrt{{\left(A - C\right)}^{2} + {B}^{2}}\right)}}{t_0}
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (fma B_m B_m (* A (* C -4.0))))
(t_1 (- (pow B_m 2.0) (* (* 4.0 A) C)))
(t_2 (* 2.0 (* t_1 F)))
(t_3
(/
(-
(sqrt
(* t_2 (+ (+ A C) (sqrt (+ (pow B_m 2.0) (pow (- A C) 2.0)))))))
t_1))
(t_4
(/
(*
(sqrt (* t_0 (* 2.0 F)))
(- (sqrt (+ A (+ C (hypot (- A C) B_m))))))
t_0)))
(if (<= t_3 -2e-197)
t_4
(if (<= t_3 0.0)
(/ (- (sqrt (* t_2 (+ (* -0.5 (/ (pow B_m 2.0) A)) (* 2.0 C))))) t_1)
(if (<= t_3 INFINITY)
t_4
(*
(* (sqrt (+ A (hypot B_m A))) (sqrt F))
(* (sqrt 2.0) (/ -1.0 B_m))))))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = fma(B_m, B_m, (A * (C * -4.0)));
double t_1 = pow(B_m, 2.0) - ((4.0 * A) * C);
double t_2 = 2.0 * (t_1 * F);
double t_3 = -sqrt((t_2 * ((A + C) + sqrt((pow(B_m, 2.0) + pow((A - C), 2.0)))))) / t_1;
double t_4 = (sqrt((t_0 * (2.0 * F))) * -sqrt((A + (C + hypot((A - C), B_m))))) / t_0;
double tmp;
if (t_3 <= -2e-197) {
tmp = t_4;
} else if (t_3 <= 0.0) {
tmp = -sqrt((t_2 * ((-0.5 * (pow(B_m, 2.0) / A)) + (2.0 * C)))) / t_1;
} else if (t_3 <= ((double) INFINITY)) {
tmp = t_4;
} else {
tmp = (sqrt((A + hypot(B_m, A))) * sqrt(F)) * (sqrt(2.0) * (-1.0 / B_m));
}
return tmp;
}
B_m = abs(B) function code(A, B_m, C, F) t_0 = fma(B_m, B_m, Float64(A * Float64(C * -4.0))) t_1 = Float64((B_m ^ 2.0) - Float64(Float64(4.0 * A) * C)) t_2 = Float64(2.0 * Float64(t_1 * F)) t_3 = Float64(Float64(-sqrt(Float64(t_2 * Float64(Float64(A + C) + sqrt(Float64((B_m ^ 2.0) + (Float64(A - C) ^ 2.0))))))) / t_1) t_4 = Float64(Float64(sqrt(Float64(t_0 * Float64(2.0 * F))) * Float64(-sqrt(Float64(A + Float64(C + hypot(Float64(A - C), B_m)))))) / t_0) tmp = 0.0 if (t_3 <= -2e-197) tmp = t_4; elseif (t_3 <= 0.0) tmp = Float64(Float64(-sqrt(Float64(t_2 * Float64(Float64(-0.5 * Float64((B_m ^ 2.0) / A)) + Float64(2.0 * C))))) / t_1); elseif (t_3 <= Inf) tmp = t_4; else tmp = Float64(Float64(sqrt(Float64(A + hypot(B_m, A))) * sqrt(F)) * Float64(sqrt(2.0) * Float64(-1.0 / B_m))); end return tmp end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(2.0 * N[(t$95$1 * F), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[((-N[Sqrt[N[(t$95$2 * N[(N[(A + C), $MachinePrecision] + N[Sqrt[N[(N[Power[B$95$m, 2.0], $MachinePrecision] + N[Power[N[(A - C), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$1), $MachinePrecision]}, Block[{t$95$4 = N[(N[(N[Sqrt[N[(t$95$0 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * (-N[Sqrt[N[(A + N[(C + N[Sqrt[N[(A - C), $MachinePrecision] ^ 2 + B$95$m ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision])), $MachinePrecision] / t$95$0), $MachinePrecision]}, If[LessEqual[t$95$3, -2e-197], t$95$4, If[LessEqual[t$95$3, 0.0], N[((-N[Sqrt[N[(t$95$2 * N[(N[(-0.5 * N[(N[Power[B$95$m, 2.0], $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision] + N[(2.0 * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$1), $MachinePrecision], If[LessEqual[t$95$3, Infinity], t$95$4, N[(N[(N[Sqrt[N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sqrt[F], $MachinePrecision]), $MachinePrecision] * N[(N[Sqrt[2.0], $MachinePrecision] * N[(-1.0 / B$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
t_1 := {B_m}^{2} - \left(4 \cdot A\right) \cdot C\\
t_2 := 2 \cdot \left(t_1 \cdot F\right)\\
t_3 := \frac{-\sqrt{t_2 \cdot \left(\left(A + C\right) + \sqrt{{B_m}^{2} + {\left(A - C\right)}^{2}}\right)}}{t_1}\\
t_4 := \frac{\sqrt{t_0 \cdot \left(2 \cdot F\right)} \cdot \left(-\sqrt{A + \left(C + \mathsf{hypot}\left(A - C, B_m\right)\right)}\right)}{t_0}\\
\mathbf{if}\;t_3 \leq -2 \cdot 10^{-197}:\\
\;\;\;\;t_4\\
\mathbf{elif}\;t_3 \leq 0:\\
\;\;\;\;\frac{-\sqrt{t_2 \cdot \left(-0.5 \cdot \frac{{B_m}^{2}}{A} + 2 \cdot C\right)}}{t_1}\\
\mathbf{elif}\;t_3 \leq \infty:\\
\;\;\;\;t_4\\
\mathbf{else}:\\
\;\;\;\;\left(\sqrt{A + \mathsf{hypot}\left(B_m, A\right)} \cdot \sqrt{F}\right) \cdot \left(\sqrt{2} \cdot \frac{-1}{B_m}\right)\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (fma B_m B_m (* A (* C -4.0)))) (t_1 (+ A (hypot B_m A))))
(if (<= (pow B_m 2.0) 5e-261)
(/
(-
(sqrt
(*
(+ (* -0.5 (/ (pow B_m 2.0) A)) (* 2.0 C))
(* 2.0 (* -4.0 (* A (* C F)))))))
(- (pow B_m 2.0) (* (* 4.0 A) C)))
(if (<= (pow B_m 2.0) 4e-138)
(/ (- (sqrt (* (* t_0 (* 2.0 F)) t_1))) t_0)
(if (<= (pow B_m 2.0) 4e+137)
(/
(- (sqrt (* (* 2.0 t_0) (* F (+ A (+ C (hypot (- A C) B_m)))))))
t_0)
(* (* (sqrt t_1) (sqrt F)) (* (sqrt 2.0) (/ -1.0 B_m))))))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = fma(B_m, B_m, (A * (C * -4.0)));
double t_1 = A + hypot(B_m, A);
double tmp;
if (pow(B_m, 2.0) <= 5e-261) {
tmp = -sqrt((((-0.5 * (pow(B_m, 2.0) / A)) + (2.0 * C)) * (2.0 * (-4.0 * (A * (C * F)))))) / (pow(B_m, 2.0) - ((4.0 * A) * C));
} else if (pow(B_m, 2.0) <= 4e-138) {
tmp = -sqrt(((t_0 * (2.0 * F)) * t_1)) / t_0;
} else if (pow(B_m, 2.0) <= 4e+137) {
tmp = -sqrt(((2.0 * t_0) * (F * (A + (C + hypot((A - C), B_m)))))) / t_0;
} else {
tmp = (sqrt(t_1) * sqrt(F)) * (sqrt(2.0) * (-1.0 / B_m));
}
return tmp;
}
B_m = abs(B) function code(A, B_m, C, F) t_0 = fma(B_m, B_m, Float64(A * Float64(C * -4.0))) t_1 = Float64(A + hypot(B_m, A)) tmp = 0.0 if ((B_m ^ 2.0) <= 5e-261) tmp = Float64(Float64(-sqrt(Float64(Float64(Float64(-0.5 * Float64((B_m ^ 2.0) / A)) + Float64(2.0 * C)) * Float64(2.0 * Float64(-4.0 * Float64(A * Float64(C * F))))))) / Float64((B_m ^ 2.0) - Float64(Float64(4.0 * A) * C))); elseif ((B_m ^ 2.0) <= 4e-138) tmp = Float64(Float64(-sqrt(Float64(Float64(t_0 * Float64(2.0 * F)) * t_1))) / t_0); elseif ((B_m ^ 2.0) <= 4e+137) tmp = Float64(Float64(-sqrt(Float64(Float64(2.0 * t_0) * Float64(F * Float64(A + Float64(C + hypot(Float64(A - C), B_m))))))) / t_0); else tmp = Float64(Float64(sqrt(t_1) * sqrt(F)) * Float64(sqrt(2.0) * Float64(-1.0 / B_m))); end return tmp end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 5e-261], N[((-N[Sqrt[N[(N[(N[(-0.5 * N[(N[Power[B$95$m, 2.0], $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision] + N[(2.0 * C), $MachinePrecision]), $MachinePrecision] * N[(2.0 * N[(-4.0 * N[(A * N[(C * F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 4e-138], N[((-N[Sqrt[N[(N[(t$95$0 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision] * t$95$1), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 4e+137], N[((-N[Sqrt[N[(N[(2.0 * t$95$0), $MachinePrecision] * N[(F * N[(A + N[(C + N[Sqrt[N[(A - C), $MachinePrecision] ^ 2 + B$95$m ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], N[(N[(N[Sqrt[t$95$1], $MachinePrecision] * N[Sqrt[F], $MachinePrecision]), $MachinePrecision] * N[(N[Sqrt[2.0], $MachinePrecision] * N[(-1.0 / B$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
t_1 := A + \mathsf{hypot}\left(B_m, A\right)\\
\mathbf{if}\;{B_m}^{2} \leq 5 \cdot 10^{-261}:\\
\;\;\;\;\frac{-\sqrt{\left(-0.5 \cdot \frac{{B_m}^{2}}{A} + 2 \cdot C\right) \cdot \left(2 \cdot \left(-4 \cdot \left(A \cdot \left(C \cdot F\right)\right)\right)\right)}}{{B_m}^{2} - \left(4 \cdot A\right) \cdot C}\\
\mathbf{elif}\;{B_m}^{2} \leq 4 \cdot 10^{-138}:\\
\;\;\;\;\frac{-\sqrt{\left(t_0 \cdot \left(2 \cdot F\right)\right) \cdot t_1}}{t_0}\\
\mathbf{elif}\;{B_m}^{2} \leq 4 \cdot 10^{+137}:\\
\;\;\;\;\frac{-\sqrt{\left(2 \cdot t_0\right) \cdot \left(F \cdot \left(A + \left(C + \mathsf{hypot}\left(A - C, B_m\right)\right)\right)\right)}}{t_0}\\
\mathbf{else}:\\
\;\;\;\;\left(\sqrt{t_1} \cdot \sqrt{F}\right) \cdot \left(\sqrt{2} \cdot \frac{-1}{B_m}\right)\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (fma B_m B_m (* A (* C -4.0))))
(t_1 (* t_0 (* 2.0 F)))
(t_2 (+ A (hypot B_m A))))
(if (<= (pow B_m 2.0) 5e-261)
(/
(-
(sqrt
(*
(+ (* -0.5 (/ (pow B_m 2.0) A)) (* 2.0 C))
(* 2.0 (* -4.0 (* A (* C F)))))))
(- (pow B_m 2.0) (* (* 4.0 A) C)))
(if (<= (pow B_m 2.0) 4e-138)
(/ (- (sqrt (* t_1 t_2))) t_0)
(if (<= (pow B_m 2.0) 2e+21)
(/ (- (sqrt (* t_1 (+ A (+ C (hypot B_m (- A C))))))) t_0)
(* (* (sqrt t_2) (sqrt F)) (* (sqrt 2.0) (/ -1.0 B_m))))))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = fma(B_m, B_m, (A * (C * -4.0)));
double t_1 = t_0 * (2.0 * F);
double t_2 = A + hypot(B_m, A);
double tmp;
if (pow(B_m, 2.0) <= 5e-261) {
tmp = -sqrt((((-0.5 * (pow(B_m, 2.0) / A)) + (2.0 * C)) * (2.0 * (-4.0 * (A * (C * F)))))) / (pow(B_m, 2.0) - ((4.0 * A) * C));
} else if (pow(B_m, 2.0) <= 4e-138) {
tmp = -sqrt((t_1 * t_2)) / t_0;
} else if (pow(B_m, 2.0) <= 2e+21) {
tmp = -sqrt((t_1 * (A + (C + hypot(B_m, (A - C)))))) / t_0;
} else {
tmp = (sqrt(t_2) * sqrt(F)) * (sqrt(2.0) * (-1.0 / B_m));
}
return tmp;
}
B_m = abs(B) function code(A, B_m, C, F) t_0 = fma(B_m, B_m, Float64(A * Float64(C * -4.0))) t_1 = Float64(t_0 * Float64(2.0 * F)) t_2 = Float64(A + hypot(B_m, A)) tmp = 0.0 if ((B_m ^ 2.0) <= 5e-261) tmp = Float64(Float64(-sqrt(Float64(Float64(Float64(-0.5 * Float64((B_m ^ 2.0) / A)) + Float64(2.0 * C)) * Float64(2.0 * Float64(-4.0 * Float64(A * Float64(C * F))))))) / Float64((B_m ^ 2.0) - Float64(Float64(4.0 * A) * C))); elseif ((B_m ^ 2.0) <= 4e-138) tmp = Float64(Float64(-sqrt(Float64(t_1 * t_2))) / t_0); elseif ((B_m ^ 2.0) <= 2e+21) tmp = Float64(Float64(-sqrt(Float64(t_1 * Float64(A + Float64(C + hypot(B_m, Float64(A - C))))))) / t_0); else tmp = Float64(Float64(sqrt(t_2) * sqrt(F)) * Float64(sqrt(2.0) * Float64(-1.0 / B_m))); end return tmp end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(t$95$0 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 5e-261], N[((-N[Sqrt[N[(N[(N[(-0.5 * N[(N[Power[B$95$m, 2.0], $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision] + N[(2.0 * C), $MachinePrecision]), $MachinePrecision] * N[(2.0 * N[(-4.0 * N[(A * N[(C * F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 4e-138], N[((-N[Sqrt[N[(t$95$1 * t$95$2), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e+21], N[((-N[Sqrt[N[(t$95$1 * N[(A + N[(C + N[Sqrt[B$95$m ^ 2 + N[(A - C), $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], N[(N[(N[Sqrt[t$95$2], $MachinePrecision] * N[Sqrt[F], $MachinePrecision]), $MachinePrecision] * N[(N[Sqrt[2.0], $MachinePrecision] * N[(-1.0 / B$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
t_1 := t_0 \cdot \left(2 \cdot F\right)\\
t_2 := A + \mathsf{hypot}\left(B_m, A\right)\\
\mathbf{if}\;{B_m}^{2} \leq 5 \cdot 10^{-261}:\\
\;\;\;\;\frac{-\sqrt{\left(-0.5 \cdot \frac{{B_m}^{2}}{A} + 2 \cdot C\right) \cdot \left(2 \cdot \left(-4 \cdot \left(A \cdot \left(C \cdot F\right)\right)\right)\right)}}{{B_m}^{2} - \left(4 \cdot A\right) \cdot C}\\
\mathbf{elif}\;{B_m}^{2} \leq 4 \cdot 10^{-138}:\\
\;\;\;\;\frac{-\sqrt{t_1 \cdot t_2}}{t_0}\\
\mathbf{elif}\;{B_m}^{2} \leq 2 \cdot 10^{+21}:\\
\;\;\;\;\frac{-\sqrt{t_1 \cdot \left(A + \left(C + \mathsf{hypot}\left(B_m, A - C\right)\right)\right)}}{t_0}\\
\mathbf{else}:\\
\;\;\;\;\left(\sqrt{t_2} \cdot \sqrt{F}\right) \cdot \left(\sqrt{2} \cdot \frac{-1}{B_m}\right)\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (fma B_m B_m (* A (* C -4.0))))
(t_1 (- (pow B_m 2.0) (* (* 4.0 A) C)))
(t_2 (+ A (hypot B_m A))))
(if (<= (pow B_m 2.0) 5e-261)
(/
(-
(sqrt
(*
(+ (* -0.5 (/ (pow B_m 2.0) A)) (* 2.0 C))
(* 2.0 (* -4.0 (* A (* C F)))))))
t_1)
(if (<= (pow B_m 2.0) 2e-111)
(/ (- (sqrt (* (* t_0 (* 2.0 F)) t_2))) t_0)
(if (<= (pow B_m 2.0) 2e+21)
(/ (- (sqrt (* (* 2.0 (* t_1 F)) (+ C (hypot B_m C))))) t_1)
(* (* (sqrt t_2) (sqrt F)) (* (sqrt 2.0) (/ -1.0 B_m))))))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = fma(B_m, B_m, (A * (C * -4.0)));
double t_1 = pow(B_m, 2.0) - ((4.0 * A) * C);
double t_2 = A + hypot(B_m, A);
double tmp;
if (pow(B_m, 2.0) <= 5e-261) {
tmp = -sqrt((((-0.5 * (pow(B_m, 2.0) / A)) + (2.0 * C)) * (2.0 * (-4.0 * (A * (C * F)))))) / t_1;
} else if (pow(B_m, 2.0) <= 2e-111) {
tmp = -sqrt(((t_0 * (2.0 * F)) * t_2)) / t_0;
} else if (pow(B_m, 2.0) <= 2e+21) {
tmp = -sqrt(((2.0 * (t_1 * F)) * (C + hypot(B_m, C)))) / t_1;
} else {
tmp = (sqrt(t_2) * sqrt(F)) * (sqrt(2.0) * (-1.0 / B_m));
}
return tmp;
}
B_m = abs(B) function code(A, B_m, C, F) t_0 = fma(B_m, B_m, Float64(A * Float64(C * -4.0))) t_1 = Float64((B_m ^ 2.0) - Float64(Float64(4.0 * A) * C)) t_2 = Float64(A + hypot(B_m, A)) tmp = 0.0 if ((B_m ^ 2.0) <= 5e-261) tmp = Float64(Float64(-sqrt(Float64(Float64(Float64(-0.5 * Float64((B_m ^ 2.0) / A)) + Float64(2.0 * C)) * Float64(2.0 * Float64(-4.0 * Float64(A * Float64(C * F))))))) / t_1); elseif ((B_m ^ 2.0) <= 2e-111) tmp = Float64(Float64(-sqrt(Float64(Float64(t_0 * Float64(2.0 * F)) * t_2))) / t_0); elseif ((B_m ^ 2.0) <= 2e+21) tmp = Float64(Float64(-sqrt(Float64(Float64(2.0 * Float64(t_1 * F)) * Float64(C + hypot(B_m, C))))) / t_1); else tmp = Float64(Float64(sqrt(t_2) * sqrt(F)) * Float64(sqrt(2.0) * Float64(-1.0 / B_m))); end return tmp end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 5e-261], N[((-N[Sqrt[N[(N[(N[(-0.5 * N[(N[Power[B$95$m, 2.0], $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision] + N[(2.0 * C), $MachinePrecision]), $MachinePrecision] * N[(2.0 * N[(-4.0 * N[(A * N[(C * F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$1), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-111], N[((-N[Sqrt[N[(N[(t$95$0 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision] * t$95$2), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e+21], N[((-N[Sqrt[N[(N[(2.0 * N[(t$95$1 * F), $MachinePrecision]), $MachinePrecision] * N[(C + N[Sqrt[B$95$m ^ 2 + C ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$1), $MachinePrecision], N[(N[(N[Sqrt[t$95$2], $MachinePrecision] * N[Sqrt[F], $MachinePrecision]), $MachinePrecision] * N[(N[Sqrt[2.0], $MachinePrecision] * N[(-1.0 / B$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
t_1 := {B_m}^{2} - \left(4 \cdot A\right) \cdot C\\
t_2 := A + \mathsf{hypot}\left(B_m, A\right)\\
\mathbf{if}\;{B_m}^{2} \leq 5 \cdot 10^{-261}:\\
\;\;\;\;\frac{-\sqrt{\left(-0.5 \cdot \frac{{B_m}^{2}}{A} + 2 \cdot C\right) \cdot \left(2 \cdot \left(-4 \cdot \left(A \cdot \left(C \cdot F\right)\right)\right)\right)}}{t_1}\\
\mathbf{elif}\;{B_m}^{2} \leq 2 \cdot 10^{-111}:\\
\;\;\;\;\frac{-\sqrt{\left(t_0 \cdot \left(2 \cdot F\right)\right) \cdot t_2}}{t_0}\\
\mathbf{elif}\;{B_m}^{2} \leq 2 \cdot 10^{+21}:\\
\;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(t_1 \cdot F\right)\right) \cdot \left(C + \mathsf{hypot}\left(B_m, C\right)\right)}}{t_1}\\
\mathbf{else}:\\
\;\;\;\;\left(\sqrt{t_2} \cdot \sqrt{F}\right) \cdot \left(\sqrt{2} \cdot \frac{-1}{B_m}\right)\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (- (pow B_m 2.0) (* (* 4.0 A) C)))
(t_1 (/ (- (sqrt (* (* 2.0 (* t_0 F)) (* 2.0 C)))) t_0))
(t_2 (/ (- (sqrt 2.0)) B_m)))
(if (<= (pow B_m 2.0) 2e-223)
t_1
(if (<= (pow B_m 2.0) 5e-26)
(* t_2 (sqrt (* -0.5 (/ (pow B_m 2.0) (/ C F)))))
(if (<= (pow B_m 2.0) 2e+21)
t_1
(* t_2 (sqrt (* F (+ A (hypot B_m A))))))))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = pow(B_m, 2.0) - ((4.0 * A) * C);
double t_1 = -sqrt(((2.0 * (t_0 * F)) * (2.0 * C))) / t_0;
double t_2 = -sqrt(2.0) / B_m;
double tmp;
if (pow(B_m, 2.0) <= 2e-223) {
tmp = t_1;
} else if (pow(B_m, 2.0) <= 5e-26) {
tmp = t_2 * sqrt((-0.5 * (pow(B_m, 2.0) / (C / F))));
} else if (pow(B_m, 2.0) <= 2e+21) {
tmp = t_1;
} else {
tmp = t_2 * sqrt((F * (A + hypot(B_m, A))));
}
return tmp;
}
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
double t_0 = Math.pow(B_m, 2.0) - ((4.0 * A) * C);
double t_1 = -Math.sqrt(((2.0 * (t_0 * F)) * (2.0 * C))) / t_0;
double t_2 = -Math.sqrt(2.0) / B_m;
double tmp;
if (Math.pow(B_m, 2.0) <= 2e-223) {
tmp = t_1;
} else if (Math.pow(B_m, 2.0) <= 5e-26) {
tmp = t_2 * Math.sqrt((-0.5 * (Math.pow(B_m, 2.0) / (C / F))));
} else if (Math.pow(B_m, 2.0) <= 2e+21) {
tmp = t_1;
} else {
tmp = t_2 * Math.sqrt((F * (A + Math.hypot(B_m, A))));
}
return tmp;
}
B_m = math.fabs(B) def code(A, B_m, C, F): t_0 = math.pow(B_m, 2.0) - ((4.0 * A) * C) t_1 = -math.sqrt(((2.0 * (t_0 * F)) * (2.0 * C))) / t_0 t_2 = -math.sqrt(2.0) / B_m tmp = 0 if math.pow(B_m, 2.0) <= 2e-223: tmp = t_1 elif math.pow(B_m, 2.0) <= 5e-26: tmp = t_2 * math.sqrt((-0.5 * (math.pow(B_m, 2.0) / (C / F)))) elif math.pow(B_m, 2.0) <= 2e+21: tmp = t_1 else: tmp = t_2 * math.sqrt((F * (A + math.hypot(B_m, A)))) return tmp
B_m = abs(B) function code(A, B_m, C, F) t_0 = Float64((B_m ^ 2.0) - Float64(Float64(4.0 * A) * C)) t_1 = Float64(Float64(-sqrt(Float64(Float64(2.0 * Float64(t_0 * F)) * Float64(2.0 * C)))) / t_0) t_2 = Float64(Float64(-sqrt(2.0)) / B_m) tmp = 0.0 if ((B_m ^ 2.0) <= 2e-223) tmp = t_1; elseif ((B_m ^ 2.0) <= 5e-26) tmp = Float64(t_2 * sqrt(Float64(-0.5 * Float64((B_m ^ 2.0) / Float64(C / F))))); elseif ((B_m ^ 2.0) <= 2e+21) tmp = t_1; else tmp = Float64(t_2 * sqrt(Float64(F * Float64(A + hypot(B_m, A))))); end return tmp end
B_m = abs(B); function tmp_2 = code(A, B_m, C, F) t_0 = (B_m ^ 2.0) - ((4.0 * A) * C); t_1 = -sqrt(((2.0 * (t_0 * F)) * (2.0 * C))) / t_0; t_2 = -sqrt(2.0) / B_m; tmp = 0.0; if ((B_m ^ 2.0) <= 2e-223) tmp = t_1; elseif ((B_m ^ 2.0) <= 5e-26) tmp = t_2 * sqrt((-0.5 * ((B_m ^ 2.0) / (C / F)))); elseif ((B_m ^ 2.0) <= 2e+21) tmp = t_1; else tmp = t_2 * sqrt((F * (A + hypot(B_m, A)))); end tmp_2 = tmp; end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[((-N[Sqrt[N[(N[(2.0 * N[(t$95$0 * F), $MachinePrecision]), $MachinePrecision] * N[(2.0 * C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision]}, Block[{t$95$2 = N[((-N[Sqrt[2.0], $MachinePrecision]) / B$95$m), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-223], t$95$1, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 5e-26], N[(t$95$2 * N[Sqrt[N[(-0.5 * N[(N[Power[B$95$m, 2.0], $MachinePrecision] / N[(C / F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e+21], t$95$1, N[(t$95$2 * N[Sqrt[N[(F * N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := {B_m}^{2} - \left(4 \cdot A\right) \cdot C\\
t_1 := \frac{-\sqrt{\left(2 \cdot \left(t_0 \cdot F\right)\right) \cdot \left(2 \cdot C\right)}}{t_0}\\
t_2 := \frac{-\sqrt{2}}{B_m}\\
\mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{-223}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;{B_m}^{2} \leq 5 \cdot 10^{-26}:\\
\;\;\;\;t_2 \cdot \sqrt{-0.5 \cdot \frac{{B_m}^{2}}{\frac{C}{F}}}\\
\mathbf{elif}\;{B_m}^{2} \leq 2 \cdot 10^{+21}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_2 \cdot \sqrt{F \cdot \left(A + \mathsf{hypot}\left(B_m, A\right)\right)}\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (- (pow B_m 2.0) (* (* 4.0 A) C)))
(t_1 (fma B_m B_m (* A (* C -4.0)))))
(if (<= (pow B_m 2.0) 2e-223)
(/
(-
(sqrt (* (* 2.0 (* t_0 F)) (+ (* -0.5 (/ (pow B_m 2.0) A)) (* 2.0 C)))))
t_0)
(if (<= (pow B_m 2.0) 2e+21)
(/ (- (sqrt (* (* t_1 (* 2.0 F)) (+ A (+ C (hypot B_m (- A C))))))) t_1)
(*
(* (sqrt (+ A (hypot B_m A))) (sqrt F))
(* (sqrt 2.0) (/ -1.0 B_m)))))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = pow(B_m, 2.0) - ((4.0 * A) * C);
double t_1 = fma(B_m, B_m, (A * (C * -4.0)));
double tmp;
if (pow(B_m, 2.0) <= 2e-223) {
tmp = -sqrt(((2.0 * (t_0 * F)) * ((-0.5 * (pow(B_m, 2.0) / A)) + (2.0 * C)))) / t_0;
} else if (pow(B_m, 2.0) <= 2e+21) {
tmp = -sqrt(((t_1 * (2.0 * F)) * (A + (C + hypot(B_m, (A - C)))))) / t_1;
} else {
tmp = (sqrt((A + hypot(B_m, A))) * sqrt(F)) * (sqrt(2.0) * (-1.0 / B_m));
}
return tmp;
}
B_m = abs(B) function code(A, B_m, C, F) t_0 = Float64((B_m ^ 2.0) - Float64(Float64(4.0 * A) * C)) t_1 = fma(B_m, B_m, Float64(A * Float64(C * -4.0))) tmp = 0.0 if ((B_m ^ 2.0) <= 2e-223) tmp = Float64(Float64(-sqrt(Float64(Float64(2.0 * Float64(t_0 * F)) * Float64(Float64(-0.5 * Float64((B_m ^ 2.0) / A)) + Float64(2.0 * C))))) / t_0); elseif ((B_m ^ 2.0) <= 2e+21) tmp = Float64(Float64(-sqrt(Float64(Float64(t_1 * Float64(2.0 * F)) * Float64(A + Float64(C + hypot(B_m, Float64(A - C))))))) / t_1); else tmp = Float64(Float64(sqrt(Float64(A + hypot(B_m, A))) * sqrt(F)) * Float64(sqrt(2.0) * Float64(-1.0 / B_m))); end return tmp end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-223], N[((-N[Sqrt[N[(N[(2.0 * N[(t$95$0 * F), $MachinePrecision]), $MachinePrecision] * N[(N[(-0.5 * N[(N[Power[B$95$m, 2.0], $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision] + N[(2.0 * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e+21], N[((-N[Sqrt[N[(N[(t$95$1 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision] * N[(A + N[(C + N[Sqrt[B$95$m ^ 2 + N[(A - C), $MachinePrecision] ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$1), $MachinePrecision], N[(N[(N[Sqrt[N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sqrt[F], $MachinePrecision]), $MachinePrecision] * N[(N[Sqrt[2.0], $MachinePrecision] * N[(-1.0 / B$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := {B_m}^{2} - \left(4 \cdot A\right) \cdot C\\
t_1 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
\mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{-223}:\\
\;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(t_0 \cdot F\right)\right) \cdot \left(-0.5 \cdot \frac{{B_m}^{2}}{A} + 2 \cdot C\right)}}{t_0}\\
\mathbf{elif}\;{B_m}^{2} \leq 2 \cdot 10^{+21}:\\
\;\;\;\;\frac{-\sqrt{\left(t_1 \cdot \left(2 \cdot F\right)\right) \cdot \left(A + \left(C + \mathsf{hypot}\left(B_m, A - C\right)\right)\right)}}{t_1}\\
\mathbf{else}:\\
\;\;\;\;\left(\sqrt{A + \mathsf{hypot}\left(B_m, A\right)} \cdot \sqrt{F}\right) \cdot \left(\sqrt{2} \cdot \frac{-1}{B_m}\right)\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (fma B_m B_m (* A (* C -4.0)))) (t_1 (+ A (hypot B_m A))))
(if (<= (pow B_m 2.0) 5e-261)
(/
(-
(sqrt
(*
(+ (* -0.5 (/ (pow B_m 2.0) A)) (* 2.0 C))
(* 2.0 (* -4.0 (* A (* C F)))))))
(- (pow B_m 2.0) (* (* 4.0 A) C)))
(if (<= (pow B_m 2.0) 2e-111)
(/ (- (sqrt (* (* t_0 (* 2.0 F)) t_1))) t_0)
(* (* (sqrt t_1) (sqrt F)) (* (sqrt 2.0) (/ -1.0 B_m)))))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = fma(B_m, B_m, (A * (C * -4.0)));
double t_1 = A + hypot(B_m, A);
double tmp;
if (pow(B_m, 2.0) <= 5e-261) {
tmp = -sqrt((((-0.5 * (pow(B_m, 2.0) / A)) + (2.0 * C)) * (2.0 * (-4.0 * (A * (C * F)))))) / (pow(B_m, 2.0) - ((4.0 * A) * C));
} else if (pow(B_m, 2.0) <= 2e-111) {
tmp = -sqrt(((t_0 * (2.0 * F)) * t_1)) / t_0;
} else {
tmp = (sqrt(t_1) * sqrt(F)) * (sqrt(2.0) * (-1.0 / B_m));
}
return tmp;
}
B_m = abs(B) function code(A, B_m, C, F) t_0 = fma(B_m, B_m, Float64(A * Float64(C * -4.0))) t_1 = Float64(A + hypot(B_m, A)) tmp = 0.0 if ((B_m ^ 2.0) <= 5e-261) tmp = Float64(Float64(-sqrt(Float64(Float64(Float64(-0.5 * Float64((B_m ^ 2.0) / A)) + Float64(2.0 * C)) * Float64(2.0 * Float64(-4.0 * Float64(A * Float64(C * F))))))) / Float64((B_m ^ 2.0) - Float64(Float64(4.0 * A) * C))); elseif ((B_m ^ 2.0) <= 2e-111) tmp = Float64(Float64(-sqrt(Float64(Float64(t_0 * Float64(2.0 * F)) * t_1))) / t_0); else tmp = Float64(Float64(sqrt(t_1) * sqrt(F)) * Float64(sqrt(2.0) * Float64(-1.0 / B_m))); end return tmp end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 5e-261], N[((-N[Sqrt[N[(N[(N[(-0.5 * N[(N[Power[B$95$m, 2.0], $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision] + N[(2.0 * C), $MachinePrecision]), $MachinePrecision] * N[(2.0 * N[(-4.0 * N[(A * N[(C * F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-111], N[((-N[Sqrt[N[(N[(t$95$0 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision] * t$95$1), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], N[(N[(N[Sqrt[t$95$1], $MachinePrecision] * N[Sqrt[F], $MachinePrecision]), $MachinePrecision] * N[(N[Sqrt[2.0], $MachinePrecision] * N[(-1.0 / B$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
t_1 := A + \mathsf{hypot}\left(B_m, A\right)\\
\mathbf{if}\;{B_m}^{2} \leq 5 \cdot 10^{-261}:\\
\;\;\;\;\frac{-\sqrt{\left(-0.5 \cdot \frac{{B_m}^{2}}{A} + 2 \cdot C\right) \cdot \left(2 \cdot \left(-4 \cdot \left(A \cdot \left(C \cdot F\right)\right)\right)\right)}}{{B_m}^{2} - \left(4 \cdot A\right) \cdot C}\\
\mathbf{elif}\;{B_m}^{2} \leq 2 \cdot 10^{-111}:\\
\;\;\;\;\frac{-\sqrt{\left(t_0 \cdot \left(2 \cdot F\right)\right) \cdot t_1}}{t_0}\\
\mathbf{else}:\\
\;\;\;\;\left(\sqrt{t_1} \cdot \sqrt{F}\right) \cdot \left(\sqrt{2} \cdot \frac{-1}{B_m}\right)\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (fma B_m B_m (* A (* C -4.0)))))
(if (<= (pow B_m 2.0) 2e-223)
(/
(-
(sqrt
(*
(+ (* -0.5 (/ (pow B_m 2.0) A)) (* 2.0 C))
(* 2.0 (* -4.0 (* A (* C F)))))))
(- (pow B_m 2.0) (* (* 4.0 A) C)))
(if (<= (pow B_m 2.0) 2e-111)
(/ (- (sqrt (* (* t_0 (* 2.0 F)) (+ A A)))) t_0)
(*
(* (sqrt (+ A (hypot B_m A))) (sqrt F))
(* (sqrt 2.0) (/ -1.0 B_m)))))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = fma(B_m, B_m, (A * (C * -4.0)));
double tmp;
if (pow(B_m, 2.0) <= 2e-223) {
tmp = -sqrt((((-0.5 * (pow(B_m, 2.0) / A)) + (2.0 * C)) * (2.0 * (-4.0 * (A * (C * F)))))) / (pow(B_m, 2.0) - ((4.0 * A) * C));
} else if (pow(B_m, 2.0) <= 2e-111) {
tmp = -sqrt(((t_0 * (2.0 * F)) * (A + A))) / t_0;
} else {
tmp = (sqrt((A + hypot(B_m, A))) * sqrt(F)) * (sqrt(2.0) * (-1.0 / B_m));
}
return tmp;
}
B_m = abs(B) function code(A, B_m, C, F) t_0 = fma(B_m, B_m, Float64(A * Float64(C * -4.0))) tmp = 0.0 if ((B_m ^ 2.0) <= 2e-223) tmp = Float64(Float64(-sqrt(Float64(Float64(Float64(-0.5 * Float64((B_m ^ 2.0) / A)) + Float64(2.0 * C)) * Float64(2.0 * Float64(-4.0 * Float64(A * Float64(C * F))))))) / Float64((B_m ^ 2.0) - Float64(Float64(4.0 * A) * C))); elseif ((B_m ^ 2.0) <= 2e-111) tmp = Float64(Float64(-sqrt(Float64(Float64(t_0 * Float64(2.0 * F)) * Float64(A + A)))) / t_0); else tmp = Float64(Float64(sqrt(Float64(A + hypot(B_m, A))) * sqrt(F)) * Float64(sqrt(2.0) * Float64(-1.0 / B_m))); end return tmp end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-223], N[((-N[Sqrt[N[(N[(N[(-0.5 * N[(N[Power[B$95$m, 2.0], $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision] + N[(2.0 * C), $MachinePrecision]), $MachinePrecision] * N[(2.0 * N[(-4.0 * N[(A * N[(C * F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-111], N[((-N[Sqrt[N[(N[(t$95$0 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision] * N[(A + A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], N[(N[(N[Sqrt[N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sqrt[F], $MachinePrecision]), $MachinePrecision] * N[(N[Sqrt[2.0], $MachinePrecision] * N[(-1.0 / B$95$m), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
\mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{-223}:\\
\;\;\;\;\frac{-\sqrt{\left(-0.5 \cdot \frac{{B_m}^{2}}{A} + 2 \cdot C\right) \cdot \left(2 \cdot \left(-4 \cdot \left(A \cdot \left(C \cdot F\right)\right)\right)\right)}}{{B_m}^{2} - \left(4 \cdot A\right) \cdot C}\\
\mathbf{elif}\;{B_m}^{2} \leq 2 \cdot 10^{-111}:\\
\;\;\;\;\frac{-\sqrt{\left(t_0 \cdot \left(2 \cdot F\right)\right) \cdot \left(A + A\right)}}{t_0}\\
\mathbf{else}:\\
\;\;\;\;\left(\sqrt{A + \mathsf{hypot}\left(B_m, A\right)} \cdot \sqrt{F}\right) \cdot \left(\sqrt{2} \cdot \frac{-1}{B_m}\right)\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (fma B_m B_m (* A (* C -4.0)))))
(if (<= (pow B_m 2.0) 2e-223)
(/
(-
(sqrt
(*
(+ (* -0.5 (/ (pow B_m 2.0) A)) (* 2.0 C))
(* 2.0 (* -4.0 (* A (* C F)))))))
(- (pow B_m 2.0) (* (* 4.0 A) C)))
(if (<= (pow B_m 2.0) 1e-40)
(/ (- (sqrt (* (* t_0 (* 2.0 F)) (+ A A)))) t_0)
(* (/ (- (sqrt 2.0)) B_m) (sqrt (fma F A (* F (hypot B_m A)))))))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = fma(B_m, B_m, (A * (C * -4.0)));
double tmp;
if (pow(B_m, 2.0) <= 2e-223) {
tmp = -sqrt((((-0.5 * (pow(B_m, 2.0) / A)) + (2.0 * C)) * (2.0 * (-4.0 * (A * (C * F)))))) / (pow(B_m, 2.0) - ((4.0 * A) * C));
} else if (pow(B_m, 2.0) <= 1e-40) {
tmp = -sqrt(((t_0 * (2.0 * F)) * (A + A))) / t_0;
} else {
tmp = (-sqrt(2.0) / B_m) * sqrt(fma(F, A, (F * hypot(B_m, A))));
}
return tmp;
}
B_m = abs(B) function code(A, B_m, C, F) t_0 = fma(B_m, B_m, Float64(A * Float64(C * -4.0))) tmp = 0.0 if ((B_m ^ 2.0) <= 2e-223) tmp = Float64(Float64(-sqrt(Float64(Float64(Float64(-0.5 * Float64((B_m ^ 2.0) / A)) + Float64(2.0 * C)) * Float64(2.0 * Float64(-4.0 * Float64(A * Float64(C * F))))))) / Float64((B_m ^ 2.0) - Float64(Float64(4.0 * A) * C))); elseif ((B_m ^ 2.0) <= 1e-40) tmp = Float64(Float64(-sqrt(Float64(Float64(t_0 * Float64(2.0 * F)) * Float64(A + A)))) / t_0); else tmp = Float64(Float64(Float64(-sqrt(2.0)) / B_m) * sqrt(fma(F, A, Float64(F * hypot(B_m, A))))); end return tmp end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-223], N[((-N[Sqrt[N[(N[(N[(-0.5 * N[(N[Power[B$95$m, 2.0], $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision] + N[(2.0 * C), $MachinePrecision]), $MachinePrecision] * N[(2.0 * N[(-4.0 * N[(A * N[(C * F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 1e-40], N[((-N[Sqrt[N[(N[(t$95$0 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision] * N[(A + A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], N[(N[((-N[Sqrt[2.0], $MachinePrecision]) / B$95$m), $MachinePrecision] * N[Sqrt[N[(F * A + N[(F * N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
\mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{-223}:\\
\;\;\;\;\frac{-\sqrt{\left(-0.5 \cdot \frac{{B_m}^{2}}{A} + 2 \cdot C\right) \cdot \left(2 \cdot \left(-4 \cdot \left(A \cdot \left(C \cdot F\right)\right)\right)\right)}}{{B_m}^{2} - \left(4 \cdot A\right) \cdot C}\\
\mathbf{elif}\;{B_m}^{2} \leq 10^{-40}:\\
\;\;\;\;\frac{-\sqrt{\left(t_0 \cdot \left(2 \cdot F\right)\right) \cdot \left(A + A\right)}}{t_0}\\
\mathbf{else}:\\
\;\;\;\;\frac{-\sqrt{2}}{B_m} \cdot \sqrt{\mathsf{fma}\left(F, A, F \cdot \mathsf{hypot}\left(B_m, A\right)\right)}\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (fma B_m B_m (* A (* C -4.0)))))
(if (<= (pow B_m 2.0) 2e-223)
(/
(-
(sqrt
(*
(+ (* -0.5 (/ (pow B_m 2.0) A)) (* 2.0 C))
(* 2.0 (* -4.0 (* A (* C F)))))))
(- (pow B_m 2.0) (* (* 4.0 A) C)))
(if (<= (pow B_m 2.0) 2e-111)
(/ (- (sqrt (* (* t_0 (* 2.0 F)) (+ A A)))) t_0)
(* (* (sqrt (+ A (hypot B_m A))) (sqrt F)) (/ (- (sqrt 2.0)) B_m))))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = fma(B_m, B_m, (A * (C * -4.0)));
double tmp;
if (pow(B_m, 2.0) <= 2e-223) {
tmp = -sqrt((((-0.5 * (pow(B_m, 2.0) / A)) + (2.0 * C)) * (2.0 * (-4.0 * (A * (C * F)))))) / (pow(B_m, 2.0) - ((4.0 * A) * C));
} else if (pow(B_m, 2.0) <= 2e-111) {
tmp = -sqrt(((t_0 * (2.0 * F)) * (A + A))) / t_0;
} else {
tmp = (sqrt((A + hypot(B_m, A))) * sqrt(F)) * (-sqrt(2.0) / B_m);
}
return tmp;
}
B_m = abs(B) function code(A, B_m, C, F) t_0 = fma(B_m, B_m, Float64(A * Float64(C * -4.0))) tmp = 0.0 if ((B_m ^ 2.0) <= 2e-223) tmp = Float64(Float64(-sqrt(Float64(Float64(Float64(-0.5 * Float64((B_m ^ 2.0) / A)) + Float64(2.0 * C)) * Float64(2.0 * Float64(-4.0 * Float64(A * Float64(C * F))))))) / Float64((B_m ^ 2.0) - Float64(Float64(4.0 * A) * C))); elseif ((B_m ^ 2.0) <= 2e-111) tmp = Float64(Float64(-sqrt(Float64(Float64(t_0 * Float64(2.0 * F)) * Float64(A + A)))) / t_0); else tmp = Float64(Float64(sqrt(Float64(A + hypot(B_m, A))) * sqrt(F)) * Float64(Float64(-sqrt(2.0)) / B_m)); end return tmp end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-223], N[((-N[Sqrt[N[(N[(N[(-0.5 * N[(N[Power[B$95$m, 2.0], $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision] + N[(2.0 * C), $MachinePrecision]), $MachinePrecision] * N[(2.0 * N[(-4.0 * N[(A * N[(C * F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-111], N[((-N[Sqrt[N[(N[(t$95$0 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision] * N[(A + A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], N[(N[(N[Sqrt[N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sqrt[F], $MachinePrecision]), $MachinePrecision] * N[((-N[Sqrt[2.0], $MachinePrecision]) / B$95$m), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
\mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{-223}:\\
\;\;\;\;\frac{-\sqrt{\left(-0.5 \cdot \frac{{B_m}^{2}}{A} + 2 \cdot C\right) \cdot \left(2 \cdot \left(-4 \cdot \left(A \cdot \left(C \cdot F\right)\right)\right)\right)}}{{B_m}^{2} - \left(4 \cdot A\right) \cdot C}\\
\mathbf{elif}\;{B_m}^{2} \leq 2 \cdot 10^{-111}:\\
\;\;\;\;\frac{-\sqrt{\left(t_0 \cdot \left(2 \cdot F\right)\right) \cdot \left(A + A\right)}}{t_0}\\
\mathbf{else}:\\
\;\;\;\;\left(\sqrt{A + \mathsf{hypot}\left(B_m, A\right)} \cdot \sqrt{F}\right) \cdot \frac{-\sqrt{2}}{B_m}\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (- (pow B_m 2.0) (* (* 4.0 A) C)))
(t_1 (fma B_m B_m (* A (* C -4.0)))))
(if (<= (pow B_m 2.0) 2e-223)
(/ (- (sqrt (* (* 2.0 (* t_0 F)) (* 2.0 C)))) t_0)
(if (<= (pow B_m 2.0) 1e-40)
(/ (- (sqrt (* (* t_1 (* 2.0 F)) (+ A A)))) t_1)
(* (/ (- (sqrt 2.0)) B_m) (sqrt (* F (+ A (hypot B_m A)))))))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = pow(B_m, 2.0) - ((4.0 * A) * C);
double t_1 = fma(B_m, B_m, (A * (C * -4.0)));
double tmp;
if (pow(B_m, 2.0) <= 2e-223) {
tmp = -sqrt(((2.0 * (t_0 * F)) * (2.0 * C))) / t_0;
} else if (pow(B_m, 2.0) <= 1e-40) {
tmp = -sqrt(((t_1 * (2.0 * F)) * (A + A))) / t_1;
} else {
tmp = (-sqrt(2.0) / B_m) * sqrt((F * (A + hypot(B_m, A))));
}
return tmp;
}
B_m = abs(B) function code(A, B_m, C, F) t_0 = Float64((B_m ^ 2.0) - Float64(Float64(4.0 * A) * C)) t_1 = fma(B_m, B_m, Float64(A * Float64(C * -4.0))) tmp = 0.0 if ((B_m ^ 2.0) <= 2e-223) tmp = Float64(Float64(-sqrt(Float64(Float64(2.0 * Float64(t_0 * F)) * Float64(2.0 * C)))) / t_0); elseif ((B_m ^ 2.0) <= 1e-40) tmp = Float64(Float64(-sqrt(Float64(Float64(t_1 * Float64(2.0 * F)) * Float64(A + A)))) / t_1); else tmp = Float64(Float64(Float64(-sqrt(2.0)) / B_m) * sqrt(Float64(F * Float64(A + hypot(B_m, A))))); end return tmp end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$1 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-223], N[((-N[Sqrt[N[(N[(2.0 * N[(t$95$0 * F), $MachinePrecision]), $MachinePrecision] * N[(2.0 * C), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 1e-40], N[((-N[Sqrt[N[(N[(t$95$1 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision] * N[(A + A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$1), $MachinePrecision], N[(N[((-N[Sqrt[2.0], $MachinePrecision]) / B$95$m), $MachinePrecision] * N[Sqrt[N[(F * N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := {B_m}^{2} - \left(4 \cdot A\right) \cdot C\\
t_1 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
\mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{-223}:\\
\;\;\;\;\frac{-\sqrt{\left(2 \cdot \left(t_0 \cdot F\right)\right) \cdot \left(2 \cdot C\right)}}{t_0}\\
\mathbf{elif}\;{B_m}^{2} \leq 10^{-40}:\\
\;\;\;\;\frac{-\sqrt{\left(t_1 \cdot \left(2 \cdot F\right)\right) \cdot \left(A + A\right)}}{t_1}\\
\mathbf{else}:\\
\;\;\;\;\frac{-\sqrt{2}}{B_m} \cdot \sqrt{F \cdot \left(A + \mathsf{hypot}\left(B_m, A\right)\right)}\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (fma B_m B_m (* A (* C -4.0)))))
(if (<= (pow B_m 2.0) 2e-223)
(/
(-
(sqrt
(*
(+ (* -0.5 (/ (pow B_m 2.0) A)) (* 2.0 C))
(* 2.0 (* -4.0 (* A (* C F)))))))
(- (pow B_m 2.0) (* (* 4.0 A) C)))
(if (<= (pow B_m 2.0) 1e-40)
(/ (- (sqrt (* (* t_0 (* 2.0 F)) (+ A A)))) t_0)
(* (/ (- (sqrt 2.0)) B_m) (sqrt (* F (+ A (hypot B_m A)))))))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = fma(B_m, B_m, (A * (C * -4.0)));
double tmp;
if (pow(B_m, 2.0) <= 2e-223) {
tmp = -sqrt((((-0.5 * (pow(B_m, 2.0) / A)) + (2.0 * C)) * (2.0 * (-4.0 * (A * (C * F)))))) / (pow(B_m, 2.0) - ((4.0 * A) * C));
} else if (pow(B_m, 2.0) <= 1e-40) {
tmp = -sqrt(((t_0 * (2.0 * F)) * (A + A))) / t_0;
} else {
tmp = (-sqrt(2.0) / B_m) * sqrt((F * (A + hypot(B_m, A))));
}
return tmp;
}
B_m = abs(B) function code(A, B_m, C, F) t_0 = fma(B_m, B_m, Float64(A * Float64(C * -4.0))) tmp = 0.0 if ((B_m ^ 2.0) <= 2e-223) tmp = Float64(Float64(-sqrt(Float64(Float64(Float64(-0.5 * Float64((B_m ^ 2.0) / A)) + Float64(2.0 * C)) * Float64(2.0 * Float64(-4.0 * Float64(A * Float64(C * F))))))) / Float64((B_m ^ 2.0) - Float64(Float64(4.0 * A) * C))); elseif ((B_m ^ 2.0) <= 1e-40) tmp = Float64(Float64(-sqrt(Float64(Float64(t_0 * Float64(2.0 * F)) * Float64(A + A)))) / t_0); else tmp = Float64(Float64(Float64(-sqrt(2.0)) / B_m) * sqrt(Float64(F * Float64(A + hypot(B_m, A))))); end return tmp end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = N[(B$95$m * B$95$m + N[(A * N[(C * -4.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 2e-223], N[((-N[Sqrt[N[(N[(N[(-0.5 * N[(N[Power[B$95$m, 2.0], $MachinePrecision] / A), $MachinePrecision]), $MachinePrecision] + N[(2.0 * C), $MachinePrecision]), $MachinePrecision] * N[(2.0 * N[(-4.0 * N[(A * N[(C * F), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / N[(N[Power[B$95$m, 2.0], $MachinePrecision] - N[(N[(4.0 * A), $MachinePrecision] * C), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[Power[B$95$m, 2.0], $MachinePrecision], 1e-40], N[((-N[Sqrt[N[(N[(t$95$0 * N[(2.0 * F), $MachinePrecision]), $MachinePrecision] * N[(A + A), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]) / t$95$0), $MachinePrecision], N[(N[((-N[Sqrt[2.0], $MachinePrecision]) / B$95$m), $MachinePrecision] * N[Sqrt[N[(F * N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := \mathsf{fma}\left(B_m, B_m, A \cdot \left(C \cdot -4\right)\right)\\
\mathbf{if}\;{B_m}^{2} \leq 2 \cdot 10^{-223}:\\
\;\;\;\;\frac{-\sqrt{\left(-0.5 \cdot \frac{{B_m}^{2}}{A} + 2 \cdot C\right) \cdot \left(2 \cdot \left(-4 \cdot \left(A \cdot \left(C \cdot F\right)\right)\right)\right)}}{{B_m}^{2} - \left(4 \cdot A\right) \cdot C}\\
\mathbf{elif}\;{B_m}^{2} \leq 10^{-40}:\\
\;\;\;\;\frac{-\sqrt{\left(t_0 \cdot \left(2 \cdot F\right)\right) \cdot \left(A + A\right)}}{t_0}\\
\mathbf{else}:\\
\;\;\;\;\frac{-\sqrt{2}}{B_m} \cdot \sqrt{F \cdot \left(A + \mathsf{hypot}\left(B_m, A\right)\right)}\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (- (sqrt 2.0))))
(if (<= F 3950000.0)
(* (/ t_0 B_m) (sqrt (+ (* F (hypot B_m A)) (* A F))))
(* (sqrt (/ F B_m)) t_0))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = -sqrt(2.0);
double tmp;
if (F <= 3950000.0) {
tmp = (t_0 / B_m) * sqrt(((F * hypot(B_m, A)) + (A * F)));
} else {
tmp = sqrt((F / B_m)) * t_0;
}
return tmp;
}
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
double t_0 = -Math.sqrt(2.0);
double tmp;
if (F <= 3950000.0) {
tmp = (t_0 / B_m) * Math.sqrt(((F * Math.hypot(B_m, A)) + (A * F)));
} else {
tmp = Math.sqrt((F / B_m)) * t_0;
}
return tmp;
}
B_m = math.fabs(B) def code(A, B_m, C, F): t_0 = -math.sqrt(2.0) tmp = 0 if F <= 3950000.0: tmp = (t_0 / B_m) * math.sqrt(((F * math.hypot(B_m, A)) + (A * F))) else: tmp = math.sqrt((F / B_m)) * t_0 return tmp
B_m = abs(B) function code(A, B_m, C, F) t_0 = Float64(-sqrt(2.0)) tmp = 0.0 if (F <= 3950000.0) tmp = Float64(Float64(t_0 / B_m) * sqrt(Float64(Float64(F * hypot(B_m, A)) + Float64(A * F)))); else tmp = Float64(sqrt(Float64(F / B_m)) * t_0); end return tmp end
B_m = abs(B); function tmp_2 = code(A, B_m, C, F) t_0 = -sqrt(2.0); tmp = 0.0; if (F <= 3950000.0) tmp = (t_0 / B_m) * sqrt(((F * hypot(B_m, A)) + (A * F))); else tmp = sqrt((F / B_m)) * t_0; end tmp_2 = tmp; end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = (-N[Sqrt[2.0], $MachinePrecision])}, If[LessEqual[F, 3950000.0], N[(N[(t$95$0 / B$95$m), $MachinePrecision] * N[Sqrt[N[(N[(F * N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision] + N[(A * F), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Sqrt[N[(F / B$95$m), $MachinePrecision]], $MachinePrecision] * t$95$0), $MachinePrecision]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := -\sqrt{2}\\
\mathbf{if}\;F \leq 3950000:\\
\;\;\;\;\frac{t_0}{B_m} \cdot \sqrt{F \cdot \mathsf{hypot}\left(B_m, A\right) + A \cdot F}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\frac{F}{B_m}} \cdot t_0\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (- (sqrt 2.0))))
(if (<= F 4000000.0)
(* (/ t_0 B_m) (sqrt (* F (+ A (hypot B_m A)))))
(* (sqrt (/ F B_m)) t_0))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = -sqrt(2.0);
double tmp;
if (F <= 4000000.0) {
tmp = (t_0 / B_m) * sqrt((F * (A + hypot(B_m, A))));
} else {
tmp = sqrt((F / B_m)) * t_0;
}
return tmp;
}
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
double t_0 = -Math.sqrt(2.0);
double tmp;
if (F <= 4000000.0) {
tmp = (t_0 / B_m) * Math.sqrt((F * (A + Math.hypot(B_m, A))));
} else {
tmp = Math.sqrt((F / B_m)) * t_0;
}
return tmp;
}
B_m = math.fabs(B) def code(A, B_m, C, F): t_0 = -math.sqrt(2.0) tmp = 0 if F <= 4000000.0: tmp = (t_0 / B_m) * math.sqrt((F * (A + math.hypot(B_m, A)))) else: tmp = math.sqrt((F / B_m)) * t_0 return tmp
B_m = abs(B) function code(A, B_m, C, F) t_0 = Float64(-sqrt(2.0)) tmp = 0.0 if (F <= 4000000.0) tmp = Float64(Float64(t_0 / B_m) * sqrt(Float64(F * Float64(A + hypot(B_m, A))))); else tmp = Float64(sqrt(Float64(F / B_m)) * t_0); end return tmp end
B_m = abs(B); function tmp_2 = code(A, B_m, C, F) t_0 = -sqrt(2.0); tmp = 0.0; if (F <= 4000000.0) tmp = (t_0 / B_m) * sqrt((F * (A + hypot(B_m, A)))); else tmp = sqrt((F / B_m)) * t_0; end tmp_2 = tmp; end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = (-N[Sqrt[2.0], $MachinePrecision])}, If[LessEqual[F, 4000000.0], N[(N[(t$95$0 / B$95$m), $MachinePrecision] * N[Sqrt[N[(F * N[(A + N[Sqrt[B$95$m ^ 2 + A ^ 2], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Sqrt[N[(F / B$95$m), $MachinePrecision]], $MachinePrecision] * t$95$0), $MachinePrecision]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := -\sqrt{2}\\
\mathbf{if}\;F \leq 4000000:\\
\;\;\;\;\frac{t_0}{B_m} \cdot \sqrt{F \cdot \left(A + \mathsf{hypot}\left(B_m, A\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\frac{F}{B_m}} \cdot t_0\\
\end{array}
\end{array}
B_m = (fabs.f64 B)
(FPCore (A B_m C F)
:precision binary64
(let* ((t_0 (- (sqrt 2.0))))
(if (<= F 1.45e-33)
(* (/ t_0 B_m) (sqrt (* B_m F)))
(* (sqrt (/ F B_m)) t_0))))B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double t_0 = -sqrt(2.0);
double tmp;
if (F <= 1.45e-33) {
tmp = (t_0 / B_m) * sqrt((B_m * F));
} else {
tmp = sqrt((F / B_m)) * t_0;
}
return tmp;
}
B_m = abs(B)
real(8) function code(a, b_m, c, f)
real(8), intent (in) :: a
real(8), intent (in) :: b_m
real(8), intent (in) :: c
real(8), intent (in) :: f
real(8) :: t_0
real(8) :: tmp
t_0 = -sqrt(2.0d0)
if (f <= 1.45d-33) then
tmp = (t_0 / b_m) * sqrt((b_m * f))
else
tmp = sqrt((f / b_m)) * t_0
end if
code = tmp
end function
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
double t_0 = -Math.sqrt(2.0);
double tmp;
if (F <= 1.45e-33) {
tmp = (t_0 / B_m) * Math.sqrt((B_m * F));
} else {
tmp = Math.sqrt((F / B_m)) * t_0;
}
return tmp;
}
B_m = math.fabs(B) def code(A, B_m, C, F): t_0 = -math.sqrt(2.0) tmp = 0 if F <= 1.45e-33: tmp = (t_0 / B_m) * math.sqrt((B_m * F)) else: tmp = math.sqrt((F / B_m)) * t_0 return tmp
B_m = abs(B) function code(A, B_m, C, F) t_0 = Float64(-sqrt(2.0)) tmp = 0.0 if (F <= 1.45e-33) tmp = Float64(Float64(t_0 / B_m) * sqrt(Float64(B_m * F))); else tmp = Float64(sqrt(Float64(F / B_m)) * t_0); end return tmp end
B_m = abs(B); function tmp_2 = code(A, B_m, C, F) t_0 = -sqrt(2.0); tmp = 0.0; if (F <= 1.45e-33) tmp = (t_0 / B_m) * sqrt((B_m * F)); else tmp = sqrt((F / B_m)) * t_0; end tmp_2 = tmp; end
B_m = N[Abs[B], $MachinePrecision]
code[A_, B$95$m_, C_, F_] := Block[{t$95$0 = (-N[Sqrt[2.0], $MachinePrecision])}, If[LessEqual[F, 1.45e-33], N[(N[(t$95$0 / B$95$m), $MachinePrecision] * N[Sqrt[N[(B$95$m * F), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Sqrt[N[(F / B$95$m), $MachinePrecision]], $MachinePrecision] * t$95$0), $MachinePrecision]]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
t_0 := -\sqrt{2}\\
\mathbf{if}\;F \leq 1.45 \cdot 10^{-33}:\\
\;\;\;\;\frac{t_0}{B_m} \cdot \sqrt{B_m \cdot F}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\frac{F}{B_m}} \cdot t_0\\
\end{array}
\end{array}
B_m = (fabs.f64 B) (FPCore (A B_m C F) :precision binary64 (* (sqrt (/ F B_m)) (- (sqrt 2.0))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
return sqrt((F / B_m)) * -sqrt(2.0);
}
B_m = abs(B)
real(8) function code(a, b_m, c, f)
real(8), intent (in) :: a
real(8), intent (in) :: b_m
real(8), intent (in) :: c
real(8), intent (in) :: f
code = sqrt((f / b_m)) * -sqrt(2.0d0)
end function
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
return Math.sqrt((F / B_m)) * -Math.sqrt(2.0);
}
B_m = math.fabs(B) def code(A, B_m, C, F): return math.sqrt((F / B_m)) * -math.sqrt(2.0)
B_m = abs(B) function code(A, B_m, C, F) return Float64(sqrt(Float64(F / B_m)) * Float64(-sqrt(2.0))) end
B_m = abs(B); function tmp = code(A, B_m, C, F) tmp = sqrt((F / B_m)) * -sqrt(2.0); end
B_m = N[Abs[B], $MachinePrecision] code[A_, B$95$m_, C_, F_] := N[(N[Sqrt[N[(F / B$95$m), $MachinePrecision]], $MachinePrecision] * (-N[Sqrt[2.0], $MachinePrecision])), $MachinePrecision]
\begin{array}{l}
B_m = \left|B\right|
\\
\sqrt{\frac{F}{B_m}} \cdot \left(-\sqrt{2}\right)
\end{array}
B_m = (fabs.f64 B) (FPCore (A B_m C F) :precision binary64 (if (<= A 3.2e-226) (* (sqrt (* C F)) (/ -2.0 B_m)) (* (pow (* A F) 0.5) (/ (- 2.0) B_m))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double tmp;
if (A <= 3.2e-226) {
tmp = sqrt((C * F)) * (-2.0 / B_m);
} else {
tmp = pow((A * F), 0.5) * (-2.0 / B_m);
}
return tmp;
}
B_m = abs(B)
real(8) function code(a, b_m, c, f)
real(8), intent (in) :: a
real(8), intent (in) :: b_m
real(8), intent (in) :: c
real(8), intent (in) :: f
real(8) :: tmp
if (a <= 3.2d-226) then
tmp = sqrt((c * f)) * ((-2.0d0) / b_m)
else
tmp = ((a * f) ** 0.5d0) * (-2.0d0 / b_m)
end if
code = tmp
end function
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
double tmp;
if (A <= 3.2e-226) {
tmp = Math.sqrt((C * F)) * (-2.0 / B_m);
} else {
tmp = Math.pow((A * F), 0.5) * (-2.0 / B_m);
}
return tmp;
}
B_m = math.fabs(B) def code(A, B_m, C, F): tmp = 0 if A <= 3.2e-226: tmp = math.sqrt((C * F)) * (-2.0 / B_m) else: tmp = math.pow((A * F), 0.5) * (-2.0 / B_m) return tmp
B_m = abs(B) function code(A, B_m, C, F) tmp = 0.0 if (A <= 3.2e-226) tmp = Float64(sqrt(Float64(C * F)) * Float64(-2.0 / B_m)); else tmp = Float64((Float64(A * F) ^ 0.5) * Float64(Float64(-2.0) / B_m)); end return tmp end
B_m = abs(B); function tmp_2 = code(A, B_m, C, F) tmp = 0.0; if (A <= 3.2e-226) tmp = sqrt((C * F)) * (-2.0 / B_m); else tmp = ((A * F) ^ 0.5) * (-2.0 / B_m); end tmp_2 = tmp; end
B_m = N[Abs[B], $MachinePrecision] code[A_, B$95$m_, C_, F_] := If[LessEqual[A, 3.2e-226], N[(N[Sqrt[N[(C * F), $MachinePrecision]], $MachinePrecision] * N[(-2.0 / B$95$m), $MachinePrecision]), $MachinePrecision], N[(N[Power[N[(A * F), $MachinePrecision], 0.5], $MachinePrecision] * N[((-2.0) / B$95$m), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
\mathbf{if}\;A \leq 3.2 \cdot 10^{-226}:\\
\;\;\;\;\sqrt{C \cdot F} \cdot \frac{-2}{B_m}\\
\mathbf{else}:\\
\;\;\;\;{\left(A \cdot F\right)}^{0.5} \cdot \frac{-2}{B_m}\\
\end{array}
\end{array}
B_m = (fabs.f64 B) (FPCore (A B_m C F) :precision binary64 (if (<= A 4.8e-228) (* (sqrt (* C F)) (/ -2.0 B_m)) (/ (* (sqrt (* A F)) (- 2.0)) B_m)))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double tmp;
if (A <= 4.8e-228) {
tmp = sqrt((C * F)) * (-2.0 / B_m);
} else {
tmp = (sqrt((A * F)) * -2.0) / B_m;
}
return tmp;
}
B_m = abs(B)
real(8) function code(a, b_m, c, f)
real(8), intent (in) :: a
real(8), intent (in) :: b_m
real(8), intent (in) :: c
real(8), intent (in) :: f
real(8) :: tmp
if (a <= 4.8d-228) then
tmp = sqrt((c * f)) * ((-2.0d0) / b_m)
else
tmp = (sqrt((a * f)) * -2.0d0) / b_m
end if
code = tmp
end function
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
double tmp;
if (A <= 4.8e-228) {
tmp = Math.sqrt((C * F)) * (-2.0 / B_m);
} else {
tmp = (Math.sqrt((A * F)) * -2.0) / B_m;
}
return tmp;
}
B_m = math.fabs(B) def code(A, B_m, C, F): tmp = 0 if A <= 4.8e-228: tmp = math.sqrt((C * F)) * (-2.0 / B_m) else: tmp = (math.sqrt((A * F)) * -2.0) / B_m return tmp
B_m = abs(B) function code(A, B_m, C, F) tmp = 0.0 if (A <= 4.8e-228) tmp = Float64(sqrt(Float64(C * F)) * Float64(-2.0 / B_m)); else tmp = Float64(Float64(sqrt(Float64(A * F)) * Float64(-2.0)) / B_m); end return tmp end
B_m = abs(B); function tmp_2 = code(A, B_m, C, F) tmp = 0.0; if (A <= 4.8e-228) tmp = sqrt((C * F)) * (-2.0 / B_m); else tmp = (sqrt((A * F)) * -2.0) / B_m; end tmp_2 = tmp; end
B_m = N[Abs[B], $MachinePrecision] code[A_, B$95$m_, C_, F_] := If[LessEqual[A, 4.8e-228], N[(N[Sqrt[N[(C * F), $MachinePrecision]], $MachinePrecision] * N[(-2.0 / B$95$m), $MachinePrecision]), $MachinePrecision], N[(N[(N[Sqrt[N[(A * F), $MachinePrecision]], $MachinePrecision] * (-2.0)), $MachinePrecision] / B$95$m), $MachinePrecision]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
\mathbf{if}\;A \leq 4.8 \cdot 10^{-228}:\\
\;\;\;\;\sqrt{C \cdot F} \cdot \frac{-2}{B_m}\\
\mathbf{else}:\\
\;\;\;\;\frac{\sqrt{A \cdot F} \cdot \left(-2\right)}{B_m}\\
\end{array}
\end{array}
B_m = (fabs.f64 B) (FPCore (A B_m C F) :precision binary64 (if (<= A 5e-228) (* (sqrt (* C F)) (/ -2.0 B_m)) (* (/ -2.0 B_m) (sqrt (* A F)))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
double tmp;
if (A <= 5e-228) {
tmp = sqrt((C * F)) * (-2.0 / B_m);
} else {
tmp = (-2.0 / B_m) * sqrt((A * F));
}
return tmp;
}
B_m = abs(B)
real(8) function code(a, b_m, c, f)
real(8), intent (in) :: a
real(8), intent (in) :: b_m
real(8), intent (in) :: c
real(8), intent (in) :: f
real(8) :: tmp
if (a <= 5d-228) then
tmp = sqrt((c * f)) * ((-2.0d0) / b_m)
else
tmp = ((-2.0d0) / b_m) * sqrt((a * f))
end if
code = tmp
end function
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
double tmp;
if (A <= 5e-228) {
tmp = Math.sqrt((C * F)) * (-2.0 / B_m);
} else {
tmp = (-2.0 / B_m) * Math.sqrt((A * F));
}
return tmp;
}
B_m = math.fabs(B) def code(A, B_m, C, F): tmp = 0 if A <= 5e-228: tmp = math.sqrt((C * F)) * (-2.0 / B_m) else: tmp = (-2.0 / B_m) * math.sqrt((A * F)) return tmp
B_m = abs(B) function code(A, B_m, C, F) tmp = 0.0 if (A <= 5e-228) tmp = Float64(sqrt(Float64(C * F)) * Float64(-2.0 / B_m)); else tmp = Float64(Float64(-2.0 / B_m) * sqrt(Float64(A * F))); end return tmp end
B_m = abs(B); function tmp_2 = code(A, B_m, C, F) tmp = 0.0; if (A <= 5e-228) tmp = sqrt((C * F)) * (-2.0 / B_m); else tmp = (-2.0 / B_m) * sqrt((A * F)); end tmp_2 = tmp; end
B_m = N[Abs[B], $MachinePrecision] code[A_, B$95$m_, C_, F_] := If[LessEqual[A, 5e-228], N[(N[Sqrt[N[(C * F), $MachinePrecision]], $MachinePrecision] * N[(-2.0 / B$95$m), $MachinePrecision]), $MachinePrecision], N[(N[(-2.0 / B$95$m), $MachinePrecision] * N[Sqrt[N[(A * F), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
B_m = \left|B\right|
\\
\begin{array}{l}
\mathbf{if}\;A \leq 5 \cdot 10^{-228}:\\
\;\;\;\;\sqrt{C \cdot F} \cdot \frac{-2}{B_m}\\
\mathbf{else}:\\
\;\;\;\;\frac{-2}{B_m} \cdot \sqrt{A \cdot F}\\
\end{array}
\end{array}
B_m = (fabs.f64 B) (FPCore (A B_m C F) :precision binary64 (* (/ -2.0 B_m) (sqrt (* A F))))
B_m = fabs(B);
double code(double A, double B_m, double C, double F) {
return (-2.0 / B_m) * sqrt((A * F));
}
B_m = abs(B)
real(8) function code(a, b_m, c, f)
real(8), intent (in) :: a
real(8), intent (in) :: b_m
real(8), intent (in) :: c
real(8), intent (in) :: f
code = ((-2.0d0) / b_m) * sqrt((a * f))
end function
B_m = Math.abs(B);
public static double code(double A, double B_m, double C, double F) {
return (-2.0 / B_m) * Math.sqrt((A * F));
}
B_m = math.fabs(B) def code(A, B_m, C, F): return (-2.0 / B_m) * math.sqrt((A * F))
B_m = abs(B) function code(A, B_m, C, F) return Float64(Float64(-2.0 / B_m) * sqrt(Float64(A * F))) end
B_m = abs(B); function tmp = code(A, B_m, C, F) tmp = (-2.0 / B_m) * sqrt((A * F)); end
B_m = N[Abs[B], $MachinePrecision] code[A_, B$95$m_, C_, F_] := N[(N[(-2.0 / B$95$m), $MachinePrecision] * N[Sqrt[N[(A * F), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
\begin{array}{l}
B_m = \left|B\right|
\\
\frac{-2}{B_m} \cdot \sqrt{A \cdot F}
\end{array}
herbie shell --seed 2024005
(FPCore (A B C F)
:name "ABCF->ab-angle a"
:precision binary64
(/ (- (sqrt (* (* 2.0 (* (- (pow B 2.0) (* (* 4.0 A) C)) F)) (+ (+ A C) (sqrt (+ (pow (- A C) 2.0) (pow B 2.0))))))) (- (pow B 2.0) (* (* 4.0 A) C))))