c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\begin{array}{l}
\mathbf{if}\;V \cdot \ell = -\infty:\\
\;\;\;\;c0 \cdot \sqrt{\frac{\frac{A}{\ell}}{V}}\\
\mathbf{elif}\;V \cdot \ell \le -1.7163677675578823 \cdot 10^{-306}:\\
\;\;\;\;\frac{c0 \cdot \sqrt{1}}{\frac{\sqrt{-V \cdot \ell}}{\sqrt{-A}}}\\
\mathbf{elif}\;V \cdot \ell \le 0.0:\\
\;\;\;\;\frac{c0 \cdot \sqrt{1}}{\frac{\sqrt{-V}}{\sqrt{-\frac{A}{\ell}}}}\\
\mathbf{elif}\;V \cdot \ell \le 1.6501826448876958 \cdot 10^{214}:\\
\;\;\;\;c0 \cdot \left(\sqrt{A} \cdot \sqrt{\frac{1}{V \cdot \ell}}\right)\\
\mathbf{else}:\\
\;\;\;\;c0 \cdot \sqrt{\frac{\frac{A}{\ell}}{V}}\\
\end{array}double code(double c0, double A, double V, double l) {
return (c0 * sqrt((A / (V * l))));
}
double code(double c0, double A, double V, double l) {
double VAR;
if (((V * l) <= -inf.0)) {
VAR = (c0 * sqrt(((A / l) / V)));
} else {
double VAR_1;
if (((V * l) <= -1.7163677675578823e-306)) {
VAR_1 = ((c0 * sqrt(1.0)) / (sqrt(-(V * l)) / sqrt(-A)));
} else {
double VAR_2;
if (((V * l) <= 0.0)) {
VAR_2 = ((c0 * sqrt(1.0)) / (sqrt(-V) / sqrt(-(A / l))));
} else {
double VAR_3;
if (((V * l) <= 1.6501826448876958e+214)) {
VAR_3 = (c0 * (sqrt(A) * sqrt((1.0 / (V * l)))));
} else {
VAR_3 = (c0 * sqrt(((A / l) / V)));
}
VAR_2 = VAR_3;
}
VAR_1 = VAR_2;
}
VAR = VAR_1;
}
return VAR;
}



Bits error versus c0



Bits error versus A



Bits error versus V



Bits error versus l
Results
if (* V l) < -inf.0 or 1.6501826448876958e+214 < (* V l) Initial program 34.6
rmApplied *-commutative34.6
Applied associate-/r*22.3
if -inf.0 < (* V l) < -1.7163677675578823e-306Initial program 9.2
rmApplied clear-num9.6
Applied sqrt-div9.3
Applied associate-*r/9.2
rmApplied frac-2neg9.2
Applied sqrt-div0.4
if -1.7163677675578823e-306 < (* V l) < 0.0Initial program 61.8
rmApplied clear-num61.8
Applied sqrt-div61.7
Applied associate-*r/61.7
rmApplied associate-/l*35.9
rmApplied frac-2neg35.9
Applied sqrt-div40.1
if 0.0 < (* V l) < 1.6501826448876958e+214Initial program 9.8
rmApplied div-inv10.1
rmApplied sqrt-prod1.3
Final simplification8.3
herbie shell --seed 2020071 +o rules:numerics
(FPCore (c0 A V l)
:name "Henrywood and Agarwal, Equation (3)"
:precision binary64
(* c0 (sqrt (/ A (* V l)))))