\[ \begin{array}{c}[V, l] = \mathsf{sort}([V, l])\\ \end{array} \]
\[c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}
\]
↓
\[\begin{array}{l}
t_0 := \sqrt{-V}\\
t_1 := \sqrt{-A}\\
\mathbf{if}\;V \cdot \ell \leq -\infty:\\
\;\;\;\;\frac{t_1}{\frac{\sqrt{\ell}}{c0} \cdot t_0}\\
\mathbf{elif}\;V \cdot \ell \leq -1 \cdot 10^{-188}:\\
\;\;\;\;\frac{c0}{\frac{\sqrt{V \cdot \left(-\ell\right)}}{t_1}}\\
\mathbf{elif}\;V \cdot \ell \leq 0:\\
\;\;\;\;\frac{c0}{\frac{t_0}{\sqrt{\frac{-A}{\ell}}}}\\
\mathbf{elif}\;V \cdot \ell \leq 2 \cdot 10^{+256}:\\
\;\;\;\;c0 \cdot \frac{\sqrt{A}}{\sqrt{V \cdot \ell}}\\
\mathbf{else}:\\
\;\;\;\;c0 \cdot \sqrt{\frac{\frac{A}{V}}{\ell}}\\
\end{array}
\]
(FPCore (c0 A V l) :precision binary64 (* c0 (sqrt (/ A (* V l)))))
↓
(FPCore (c0 A V l)
:precision binary64
(let* ((t_0 (sqrt (- V))) (t_1 (sqrt (- A))))
(if (<= (* V l) (- INFINITY))
(/ t_1 (* (/ (sqrt l) c0) t_0))
(if (<= (* V l) -1e-188)
(/ c0 (/ (sqrt (* V (- l))) t_1))
(if (<= (* V l) 0.0)
(/ c0 (/ t_0 (sqrt (/ (- A) l))))
(if (<= (* V l) 2e+256)
(* c0 (/ (sqrt A) (sqrt (* V l))))
(* c0 (sqrt (/ (/ A V) l)))))))))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 t_0 = sqrt(-V);
double t_1 = sqrt(-A);
double tmp;
if ((V * l) <= -((double) INFINITY)) {
tmp = t_1 / ((sqrt(l) / c0) * t_0);
} else if ((V * l) <= -1e-188) {
tmp = c0 / (sqrt((V * -l)) / t_1);
} else if ((V * l) <= 0.0) {
tmp = c0 / (t_0 / sqrt((-A / l)));
} else if ((V * l) <= 2e+256) {
tmp = c0 * (sqrt(A) / sqrt((V * l)));
} else {
tmp = c0 * sqrt(((A / V) / l));
}
return tmp;
}
public static double code(double c0, double A, double V, double l) {
return c0 * Math.sqrt((A / (V * l)));
}
↓
public static double code(double c0, double A, double V, double l) {
double t_0 = Math.sqrt(-V);
double t_1 = Math.sqrt(-A);
double tmp;
if ((V * l) <= -Double.POSITIVE_INFINITY) {
tmp = t_1 / ((Math.sqrt(l) / c0) * t_0);
} else if ((V * l) <= -1e-188) {
tmp = c0 / (Math.sqrt((V * -l)) / t_1);
} else if ((V * l) <= 0.0) {
tmp = c0 / (t_0 / Math.sqrt((-A / l)));
} else if ((V * l) <= 2e+256) {
tmp = c0 * (Math.sqrt(A) / Math.sqrt((V * l)));
} else {
tmp = c0 * Math.sqrt(((A / V) / l));
}
return tmp;
}
def code(c0, A, V, l):
return c0 * math.sqrt((A / (V * l)))
↓
def code(c0, A, V, l):
t_0 = math.sqrt(-V)
t_1 = math.sqrt(-A)
tmp = 0
if (V * l) <= -math.inf:
tmp = t_1 / ((math.sqrt(l) / c0) * t_0)
elif (V * l) <= -1e-188:
tmp = c0 / (math.sqrt((V * -l)) / t_1)
elif (V * l) <= 0.0:
tmp = c0 / (t_0 / math.sqrt((-A / l)))
elif (V * l) <= 2e+256:
tmp = c0 * (math.sqrt(A) / math.sqrt((V * l)))
else:
tmp = c0 * math.sqrt(((A / V) / l))
return tmp
function code(c0, A, V, l)
return Float64(c0 * sqrt(Float64(A / Float64(V * l))))
end
↓
function code(c0, A, V, l)
t_0 = sqrt(Float64(-V))
t_1 = sqrt(Float64(-A))
tmp = 0.0
if (Float64(V * l) <= Float64(-Inf))
tmp = Float64(t_1 / Float64(Float64(sqrt(l) / c0) * t_0));
elseif (Float64(V * l) <= -1e-188)
tmp = Float64(c0 / Float64(sqrt(Float64(V * Float64(-l))) / t_1));
elseif (Float64(V * l) <= 0.0)
tmp = Float64(c0 / Float64(t_0 / sqrt(Float64(Float64(-A) / l))));
elseif (Float64(V * l) <= 2e+256)
tmp = Float64(c0 * Float64(sqrt(A) / sqrt(Float64(V * l))));
else
tmp = Float64(c0 * sqrt(Float64(Float64(A / V) / l)));
end
return tmp
end
function tmp = code(c0, A, V, l)
tmp = c0 * sqrt((A / (V * l)));
end
↓
function tmp_2 = code(c0, A, V, l)
t_0 = sqrt(-V);
t_1 = sqrt(-A);
tmp = 0.0;
if ((V * l) <= -Inf)
tmp = t_1 / ((sqrt(l) / c0) * t_0);
elseif ((V * l) <= -1e-188)
tmp = c0 / (sqrt((V * -l)) / t_1);
elseif ((V * l) <= 0.0)
tmp = c0 / (t_0 / sqrt((-A / l)));
elseif ((V * l) <= 2e+256)
tmp = c0 * (sqrt(A) / sqrt((V * l)));
else
tmp = c0 * sqrt(((A / V) / l));
end
tmp_2 = tmp;
end
code[c0_, A_, V_, l_] := N[(c0 * N[Sqrt[N[(A / N[(V * l), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]
↓
code[c0_, A_, V_, l_] := Block[{t$95$0 = N[Sqrt[(-V)], $MachinePrecision]}, Block[{t$95$1 = N[Sqrt[(-A)], $MachinePrecision]}, If[LessEqual[N[(V * l), $MachinePrecision], (-Infinity)], N[(t$95$1 / N[(N[(N[Sqrt[l], $MachinePrecision] / c0), $MachinePrecision] * t$95$0), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(V * l), $MachinePrecision], -1e-188], N[(c0 / N[(N[Sqrt[N[(V * (-l)), $MachinePrecision]], $MachinePrecision] / t$95$1), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(V * l), $MachinePrecision], 0.0], N[(c0 / N[(t$95$0 / N[Sqrt[N[((-A) / l), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], If[LessEqual[N[(V * l), $MachinePrecision], 2e+256], N[(c0 * N[(N[Sqrt[A], $MachinePrecision] / N[Sqrt[N[(V * l), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(c0 * N[Sqrt[N[(N[(A / V), $MachinePrecision] / l), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]]]]
c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}
↓
\begin{array}{l}
t_0 := \sqrt{-V}\\
t_1 := \sqrt{-A}\\
\mathbf{if}\;V \cdot \ell \leq -\infty:\\
\;\;\;\;\frac{t_1}{\frac{\sqrt{\ell}}{c0} \cdot t_0}\\
\mathbf{elif}\;V \cdot \ell \leq -1 \cdot 10^{-188}:\\
\;\;\;\;\frac{c0}{\frac{\sqrt{V \cdot \left(-\ell\right)}}{t_1}}\\
\mathbf{elif}\;V \cdot \ell \leq 0:\\
\;\;\;\;\frac{c0}{\frac{t_0}{\sqrt{\frac{-A}{\ell}}}}\\
\mathbf{elif}\;V \cdot \ell \leq 2 \cdot 10^{+256}:\\
\;\;\;\;c0 \cdot \frac{\sqrt{A}}{\sqrt{V \cdot \ell}}\\
\mathbf{else}:\\
\;\;\;\;c0 \cdot \sqrt{\frac{\frac{A}{V}}{\ell}}\\
\end{array}
Alternatives
| Alternative 1 |
|---|
| Error | 14.7 |
|---|
| Cost | 34640 |
|---|
\[\begin{array}{l}
t_0 := c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\\
\mathbf{if}\;t_0 \leq -\infty:\\
\;\;\;\;\frac{c0}{\sqrt{\ell \cdot \frac{V}{A}}}\\
\mathbf{elif}\;t_0 \leq -1 \cdot 10^{-268}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;t_0 \leq 10^{-156}:\\
\;\;\;\;c0 \cdot \sqrt{\frac{\frac{A}{V}}{\ell}}\\
\mathbf{elif}\;t_0 \leq 5 \cdot 10^{+295}:\\
\;\;\;\;t_0\\
\mathbf{else}:\\
\;\;\;\;\sqrt{c0 \cdot \left(\frac{c0}{V} \cdot \frac{A}{\ell}\right)}\\
\end{array}
\]
| Alternative 2 |
|---|
| Error | 15.0 |
|---|
| Cost | 34512 |
|---|
\[\begin{array}{l}
t_0 := \frac{c0}{\sqrt{\ell \cdot \frac{V}{A}}}\\
t_1 := c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}\\
\mathbf{if}\;t_1 \leq -\infty:\\
\;\;\;\;t_0\\
\mathbf{elif}\;t_1 \leq -1 \cdot 10^{-268}:\\
\;\;\;\;t_1\\
\mathbf{elif}\;t_1 \leq 10^{-156}:\\
\;\;\;\;c0 \cdot \sqrt{\frac{\frac{A}{V}}{\ell}}\\
\mathbf{elif}\;t_1 \leq 5 \cdot 10^{+256}:\\
\;\;\;\;t_1\\
\mathbf{else}:\\
\;\;\;\;t_0\\
\end{array}
\]
| Alternative 3 |
|---|
| Error | 12.7 |
|---|
| Cost | 14288 |
|---|
\[\begin{array}{l}
\mathbf{if}\;V \cdot \ell \leq -5 \cdot 10^{+280}:\\
\;\;\;\;\sqrt{\frac{A}{V} \cdot \frac{c0 \cdot c0}{\ell}}\\
\mathbf{elif}\;V \cdot \ell \leq -1 \cdot 10^{-130}:\\
\;\;\;\;\frac{c0}{\sqrt{\left(V \cdot \ell\right) \cdot \frac{1}{A}}}\\
\mathbf{elif}\;V \cdot \ell \leq 10^{-278}:\\
\;\;\;\;c0 \cdot {\left(\ell \cdot \frac{V}{A}\right)}^{-0.5}\\
\mathbf{elif}\;V \cdot \ell \leq 2 \cdot 10^{+256}:\\
\;\;\;\;c0 \cdot \frac{\sqrt{A}}{\sqrt{V \cdot \ell}}\\
\mathbf{else}:\\
\;\;\;\;c0 \cdot \sqrt{\frac{\frac{A}{V}}{\ell}}\\
\end{array}
\]
| Alternative 4 |
|---|
| Error | 8.4 |
|---|
| Cost | 14288 |
|---|
\[\begin{array}{l}
t_0 := c0 \cdot \frac{\sqrt{\frac{A}{V}}}{\sqrt{\ell}}\\
\mathbf{if}\;V \cdot \ell \leq -5 \cdot 10^{+87}:\\
\;\;\;\;t_0\\
\mathbf{elif}\;V \cdot \ell \leq -5 \cdot 10^{-132}:\\
\;\;\;\;\frac{c0}{\sqrt{\left(V \cdot \ell\right) \cdot \frac{1}{A}}}\\
\mathbf{elif}\;V \cdot \ell \leq 0:\\
\;\;\;\;t_0\\
\mathbf{elif}\;V \cdot \ell \leq 2 \cdot 10^{+256}:\\
\;\;\;\;c0 \cdot \frac{\sqrt{A}}{\sqrt{V \cdot \ell}}\\
\mathbf{else}:\\
\;\;\;\;c0 \cdot \sqrt{\frac{\frac{A}{V}}{\ell}}\\
\end{array}
\]
| Alternative 5 |
|---|
| Error | 8.4 |
|---|
| Cost | 14288 |
|---|
\[\begin{array}{l}
t_0 := \sqrt{\frac{A}{V}}\\
\mathbf{if}\;V \cdot \ell \leq -5 \cdot 10^{+87}:\\
\;\;\;\;\frac{c0}{\frac{\sqrt{\ell}}{t_0}}\\
\mathbf{elif}\;V \cdot \ell \leq -5 \cdot 10^{-132}:\\
\;\;\;\;\frac{c0}{\sqrt{\left(V \cdot \ell\right) \cdot \frac{1}{A}}}\\
\mathbf{elif}\;V \cdot \ell \leq 0:\\
\;\;\;\;c0 \cdot \frac{t_0}{\sqrt{\ell}}\\
\mathbf{elif}\;V \cdot \ell \leq 2 \cdot 10^{+256}:\\
\;\;\;\;c0 \cdot \frac{\sqrt{A}}{\sqrt{V \cdot \ell}}\\
\mathbf{else}:\\
\;\;\;\;c0 \cdot \sqrt{\frac{\frac{A}{V}}{\ell}}\\
\end{array}
\]
| Alternative 6 |
|---|
| Error | 8.3 |
|---|
| Cost | 14288 |
|---|
\[\begin{array}{l}
\mathbf{if}\;V \cdot \ell \leq -5 \cdot 10^{+87}:\\
\;\;\;\;\frac{c0}{\frac{\sqrt{\ell}}{\sqrt{\frac{A}{V}}}}\\
\mathbf{elif}\;V \cdot \ell \leq -1 \cdot 10^{-130}:\\
\;\;\;\;\frac{c0}{\sqrt{\left(V \cdot \ell\right) \cdot \frac{1}{A}}}\\
\mathbf{elif}\;V \cdot \ell \leq 0:\\
\;\;\;\;\frac{c0}{\frac{\sqrt{-V}}{\sqrt{\frac{-A}{\ell}}}}\\
\mathbf{elif}\;V \cdot \ell \leq 2 \cdot 10^{+256}:\\
\;\;\;\;c0 \cdot \frac{\sqrt{A}}{\sqrt{V \cdot \ell}}\\
\mathbf{else}:\\
\;\;\;\;c0 \cdot \sqrt{\frac{\frac{A}{V}}{\ell}}\\
\end{array}
\]
| Alternative 7 |
|---|
| Error | 6.0 |
|---|
| Cost | 14288 |
|---|
\[\begin{array}{l}
t_0 := \frac{c0}{\frac{\sqrt{-V}}{\sqrt{\frac{-A}{\ell}}}}\\
\mathbf{if}\;V \cdot \ell \leq -\infty:\\
\;\;\;\;t_0\\
\mathbf{elif}\;V \cdot \ell \leq -1 \cdot 10^{-188}:\\
\;\;\;\;\frac{c0}{\frac{\sqrt{V \cdot \left(-\ell\right)}}{\sqrt{-A}}}\\
\mathbf{elif}\;V \cdot \ell \leq 0:\\
\;\;\;\;t_0\\
\mathbf{elif}\;V \cdot \ell \leq 2 \cdot 10^{+256}:\\
\;\;\;\;c0 \cdot \frac{\sqrt{A}}{\sqrt{V \cdot \ell}}\\
\mathbf{else}:\\
\;\;\;\;c0 \cdot \sqrt{\frac{\frac{A}{V}}{\ell}}\\
\end{array}
\]
| Alternative 8 |
|---|
| Error | 15.0 |
|---|
| Cost | 7625 |
|---|
\[\begin{array}{l}
t_0 := \frac{A}{V \cdot \ell}\\
\mathbf{if}\;t_0 \leq 0 \lor \neg \left(t_0 \leq 4 \cdot 10^{+280}\right):\\
\;\;\;\;c0 \cdot \sqrt{\frac{\frac{A}{V}}{\ell}}\\
\mathbf{else}:\\
\;\;\;\;c0 \cdot \sqrt{t_0}\\
\end{array}
\]
| Alternative 9 |
|---|
| Error | 18.8 |
|---|
| Cost | 6848 |
|---|
\[c0 \cdot \sqrt{\frac{A}{V \cdot \ell}}
\]
| Alternative 10 |
|---|
| Error | 55.0 |
|---|
| Cost | 64 |
|---|
\[0
\]