Toniolo and Linder, Equation (13)

Percentage Accurate: 50.6% → 66.6%
Time: 25.1s
Alternatives: 17
Speedup: 1.0×

Specification

?
\[\begin{array}{l} \\ \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \end{array} \]
(FPCore (n U t l Om U*)
 :precision binary64
 (sqrt
  (*
   (* (* 2.0 n) U)
   (- (- t (* 2.0 (/ (* l l) Om))) (* (* n (pow (/ l Om) 2.0)) (- U U*))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
	return sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * pow((l / Om), 2.0)) * (U - U_42_)))));
}
real(8) function code(n, u, t, l, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    code = sqrt((((2.0d0 * n) * u) * ((t - (2.0d0 * ((l * l) / om))) - ((n * ((l / om) ** 2.0d0)) * (u - u_42)))))
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	return Math.sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * Math.pow((l / Om), 2.0)) * (U - U_42_)))));
}
def code(n, U, t, l, Om, U_42_):
	return math.sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * math.pow((l / Om), 2.0)) * (U - U_42_)))))
function code(n, U, t, l, Om, U_42_)
	return sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l * l) / Om))) - Float64(Float64(n * (Float64(l / Om) ^ 2.0)) * Float64(U - U_42_)))))
end
function tmp = code(n, U, t, l, Om, U_42_)
	tmp = sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * ((l / Om) ^ 2.0)) * (U - U_42_)))));
end
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U - U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

\\
\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)}
\end{array}

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

The average percentage accuracy by input value. Horizontal axis shows value of an input variable; the variable is choosen in the title. Vertical axis is accuracy; higher is better. Red represent the original program, while blue represents Herbie's suggestion. These can be toggled with buttons below the plot. The line is an average while dots represent individual samples.

Accuracy vs Speed?

Herbie found 17 alternatives:

AlternativeAccuracySpeedup
The accuracy (vertical axis) and speed (horizontal axis) of each alternatives. Up and to the right is better. The red square shows the initial program, and each blue circle shows an alternative.The line shows the best available speed-accuracy tradeoffs.

Initial Program: 50.6% accurate, 1.0× speedup?

\[\begin{array}{l} \\ \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \end{array} \]
(FPCore (n U t l Om U*)
 :precision binary64
 (sqrt
  (*
   (* (* 2.0 n) U)
   (- (- t (* 2.0 (/ (* l l) Om))) (* (* n (pow (/ l Om) 2.0)) (- U U*))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
	return sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * pow((l / Om), 2.0)) * (U - U_42_)))));
}
real(8) function code(n, u, t, l, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    code = sqrt((((2.0d0 * n) * u) * ((t - (2.0d0 * ((l * l) / om))) - ((n * ((l / om) ** 2.0d0)) * (u - u_42)))))
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	return Math.sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * Math.pow((l / Om), 2.0)) * (U - U_42_)))));
}
def code(n, U, t, l, Om, U_42_):
	return math.sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * math.pow((l / Om), 2.0)) * (U - U_42_)))))
function code(n, U, t, l, Om, U_42_)
	return sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l * l) / Om))) - Float64(Float64(n * (Float64(l / Om) ^ 2.0)) * Float64(U - U_42_)))))
end
function tmp = code(n, U, t, l, Om, U_42_)
	tmp = sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * ((l / Om) ^ 2.0)) * (U - U_42_)))));
end
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U - U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}

\\
\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)}
\end{array}

Alternative 1: 66.6% accurate, 0.3× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} t_1 := \left(n \cdot {\left(\frac{l\_m}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\\ t_2 := \left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{l\_m \cdot l\_m}{Om}\right) + t\_1\right)\\ \mathbf{if}\;t\_2 \leq 0:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{elif}\;t\_2 \leq 10^{+308}:\\ \;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(t\_1 - 2 \cdot \left(l\_m \cdot \frac{l\_m}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;{\left(\left(n \cdot U\right) \cdot \mathsf{fma}\left(n, \left(U* - U\right) \cdot {Om}^{-2}, \frac{2}{-Om}\right)\right)}^{0.5} \cdot \left(l\_m \cdot \sqrt{2}\right)\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (let* ((t_1 (* (* n (pow (/ l_m Om) 2.0)) (- U* U)))
        (t_2 (* (* (* 2.0 n) U) (+ (- t (* 2.0 (/ (* l_m l_m) Om))) t_1))))
   (if (<= t_2 0.0)
     (sqrt
      (*
       2.0
       (* n (* U (+ t (/ (* (* l_m l_m) (- (* n (/ (- U* U) Om)) 2.0)) Om))))))
     (if (<= t_2 1e+308)
       (sqrt (* (* 2.0 (* n U)) (+ t (- t_1 (* 2.0 (* l_m (/ l_m Om)))))))
       (*
        (pow (* (* n U) (fma n (* (- U* U) (pow Om -2.0)) (/ 2.0 (- Om)))) 0.5)
        (* l_m (sqrt 2.0)))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double t_1 = (n * pow((l_m / Om), 2.0)) * (U_42_ - U);
	double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1);
	double tmp;
	if (t_2 <= 0.0) {
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	} else if (t_2 <= 1e+308) {
		tmp = sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om)))))));
	} else {
		tmp = pow(((n * U) * fma(n, ((U_42_ - U) * pow(Om, -2.0)), (2.0 / -Om))), 0.5) * (l_m * sqrt(2.0));
	}
	return tmp;
}
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	t_1 = Float64(Float64(n * (Float64(l_m / Om) ^ 2.0)) * Float64(U_42_ - U))
	t_2 = Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l_m * l_m) / Om))) + t_1))
	tmp = 0.0
	if (t_2 <= 0.0)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t + Float64(Float64(Float64(l_m * l_m) * Float64(Float64(n * Float64(Float64(U_42_ - U) / Om)) - 2.0)) / Om))))));
	elseif (t_2 <= 1e+308)
		tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * Float64(t + Float64(t_1 - Float64(2.0 * Float64(l_m * Float64(l_m / Om)))))));
	else
		tmp = Float64((Float64(Float64(n * U) * fma(n, Float64(Float64(U_42_ - U) * (Om ^ -2.0)), Float64(2.0 / Float64(-Om)))) ^ 0.5) * Float64(l_m * sqrt(2.0)));
	end
	return tmp
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := Block[{t$95$1 = N[(N[(n * N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l$95$m * l$95$m), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, 0.0], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t + N[(N[(N[(l$95$m * l$95$m), $MachinePrecision] * N[(N[(n * N[(N[(U$42$ - U), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$2, 1e+308], N[Sqrt[N[(N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision] * N[(t + N[(t$95$1 - N[(2.0 * N[(l$95$m * N[(l$95$m / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Power[N[(N[(n * U), $MachinePrecision] * N[(n * N[(N[(U$42$ - U), $MachinePrecision] * N[Power[Om, -2.0], $MachinePrecision]), $MachinePrecision] + N[(2.0 / (-Om)), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision] * N[(l$95$m * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
t_1 := \left(n \cdot {\left(\frac{l\_m}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\\
t_2 := \left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{l\_m \cdot l\_m}{Om}\right) + t\_1\right)\\
\mathbf{if}\;t\_2 \leq 0:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\

\mathbf{elif}\;t\_2 \leq 10^{+308}:\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(t\_1 - 2 \cdot \left(l\_m \cdot \frac{l\_m}{Om}\right)\right)\right)}\\

\mathbf{else}:\\
\;\;\;\;{\left(\left(n \cdot U\right) \cdot \mathsf{fma}\left(n, \left(U* - U\right) \cdot {Om}^{-2}, \frac{2}{-Om}\right)\right)}^{0.5} \cdot \left(l\_m \cdot \sqrt{2}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < 0.0

    1. Initial program 7.8%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified32.5%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in Om around -inf 32.3%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t + -1 \cdot \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
    5. Step-by-step derivation
      1. mul-1-neg32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \color{blue}{\left(-\frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)\right)} \]
      2. unsub-neg32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
      3. +-commutative32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} + -1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      4. mul-1-neg32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} + \color{blue}{\left(-\frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
      5. unsub-neg32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} - \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      6. associate-/l*38.2%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} - \color{blue}{{\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}}{Om}\right)\right)\right)} \]
    6. Simplified38.2%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{2 \cdot {\ell}^{2} - {\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}{Om}\right)}\right)\right)} \]
    7. Taylor expanded in l around 0 38.4%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - \frac{n \cdot \left(U* - U\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
    8. Step-by-step derivation
      1. associate-*r/41.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{{\ell}^{2} \cdot \left(2 - \color{blue}{n \cdot \frac{U* - U}{Om}}\right)}{Om}\right)\right)\right)} \]
    9. Simplified41.1%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}}{Om}\right)\right)\right)} \]
    10. Step-by-step derivation
      1. pow241.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]
    11. Applied egg-rr41.1%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]

    if 0.0 < (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < 1e308

    1. Initial program 96.7%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified96.7%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t - \left(2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right)}} \]
    3. Add Preprocessing

    if 1e308 < (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))

    1. Initial program 20.4%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified28.1%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around inf 15.6%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(\frac{n \cdot \left(U* - U\right)}{{Om}^{2}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    5. Step-by-step derivation
      1. associate-/l*14.0%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(\color{blue}{n \cdot \frac{U* - U}{{Om}^{2}}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      2. associate-*r/14.0%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \color{blue}{\frac{2 \cdot 1}{Om}}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      3. metadata-eval14.0%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{\color{blue}{2}}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    6. Simplified14.0%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    7. Step-by-step derivation
      1. pow1/214.2%

        \[\leadsto \color{blue}{{\left(U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)\right)}^{0.5}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      2. associate-*r*17.0%

        \[\leadsto {\color{blue}{\left(\left(U \cdot n\right) \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)}}^{0.5} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      3. *-commutative17.0%

        \[\leadsto {\left(\color{blue}{\left(n \cdot U\right)} \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)}^{0.5} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      4. fma-neg17.0%

        \[\leadsto {\left(\left(n \cdot U\right) \cdot \color{blue}{\mathsf{fma}\left(n, \frac{U* - U}{{Om}^{2}}, -\frac{2}{Om}\right)}\right)}^{0.5} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      5. div-inv17.0%

        \[\leadsto {\left(\left(n \cdot U\right) \cdot \mathsf{fma}\left(n, \color{blue}{\left(U* - U\right) \cdot \frac{1}{{Om}^{2}}}, -\frac{2}{Om}\right)\right)}^{0.5} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      6. pow-flip17.0%

        \[\leadsto {\left(\left(n \cdot U\right) \cdot \mathsf{fma}\left(n, \left(U* - U\right) \cdot \color{blue}{{Om}^{\left(-2\right)}}, -\frac{2}{Om}\right)\right)}^{0.5} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      7. metadata-eval17.0%

        \[\leadsto {\left(\left(n \cdot U\right) \cdot \mathsf{fma}\left(n, \left(U* - U\right) \cdot {Om}^{\color{blue}{-2}}, -\frac{2}{Om}\right)\right)}^{0.5} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    8. Applied egg-rr17.0%

      \[\leadsto \color{blue}{{\left(\left(n \cdot U\right) \cdot \mathsf{fma}\left(n, \left(U* - U\right) \cdot {Om}^{-2}, -\frac{2}{Om}\right)\right)}^{0.5}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
  3. Recombined 3 regimes into one program.
  4. Final simplification53.8%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right) \leq 0:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(\ell \cdot \ell\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{elif}\;\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right) \leq 10^{+308}:\\ \;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(\left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right) - 2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;{\left(\left(n \cdot U\right) \cdot \mathsf{fma}\left(n, \left(U* - U\right) \cdot {Om}^{-2}, \frac{2}{-Om}\right)\right)}^{0.5} \cdot \left(\ell \cdot \sqrt{2}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 2: 65.8% accurate, 0.4× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} t_1 := \left(n \cdot {\left(\frac{l\_m}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\\ t_2 := \left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{l\_m \cdot l\_m}{Om}\right) + t\_1\right)\\ \mathbf{if}\;t\_2 \leq 0:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{elif}\;t\_2 \leq 10^{+308}:\\ \;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(t\_1 - 2 \cdot \left(l\_m \cdot \frac{l\_m}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(l\_m \cdot \sqrt{2}\right) \cdot \sqrt[3]{{\left(\left(n \cdot U\right) \cdot \frac{\frac{n \cdot \left(U* - U\right)}{Om} - 2}{Om}\right)}^{1.5}}\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (let* ((t_1 (* (* n (pow (/ l_m Om) 2.0)) (- U* U)))
        (t_2 (* (* (* 2.0 n) U) (+ (- t (* 2.0 (/ (* l_m l_m) Om))) t_1))))
   (if (<= t_2 0.0)
     (sqrt
      (*
       2.0
       (* n (* U (+ t (/ (* (* l_m l_m) (- (* n (/ (- U* U) Om)) 2.0)) Om))))))
     (if (<= t_2 1e+308)
       (sqrt (* (* 2.0 (* n U)) (+ t (- t_1 (* 2.0 (* l_m (/ l_m Om)))))))
       (*
        (* l_m (sqrt 2.0))
        (cbrt (pow (* (* n U) (/ (- (/ (* n (- U* U)) Om) 2.0) Om)) 1.5)))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double t_1 = (n * pow((l_m / Om), 2.0)) * (U_42_ - U);
	double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1);
	double tmp;
	if (t_2 <= 0.0) {
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	} else if (t_2 <= 1e+308) {
		tmp = sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om)))))));
	} else {
		tmp = (l_m * sqrt(2.0)) * cbrt(pow(((n * U) * ((((n * (U_42_ - U)) / Om) - 2.0) / Om)), 1.5));
	}
	return tmp;
}
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double t_1 = (n * Math.pow((l_m / Om), 2.0)) * (U_42_ - U);
	double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1);
	double tmp;
	if (t_2 <= 0.0) {
		tmp = Math.sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	} else if (t_2 <= 1e+308) {
		tmp = Math.sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om)))))));
	} else {
		tmp = (l_m * Math.sqrt(2.0)) * Math.cbrt(Math.pow(((n * U) * ((((n * (U_42_ - U)) / Om) - 2.0) / Om)), 1.5));
	}
	return tmp;
}
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	t_1 = Float64(Float64(n * (Float64(l_m / Om) ^ 2.0)) * Float64(U_42_ - U))
	t_2 = Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l_m * l_m) / Om))) + t_1))
	tmp = 0.0
	if (t_2 <= 0.0)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t + Float64(Float64(Float64(l_m * l_m) * Float64(Float64(n * Float64(Float64(U_42_ - U) / Om)) - 2.0)) / Om))))));
	elseif (t_2 <= 1e+308)
		tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * Float64(t + Float64(t_1 - Float64(2.0 * Float64(l_m * Float64(l_m / Om)))))));
	else
		tmp = Float64(Float64(l_m * sqrt(2.0)) * cbrt((Float64(Float64(n * U) * Float64(Float64(Float64(Float64(n * Float64(U_42_ - U)) / Om) - 2.0) / Om)) ^ 1.5)));
	end
	return tmp
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := Block[{t$95$1 = N[(N[(n * N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l$95$m * l$95$m), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, 0.0], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t + N[(N[(N[(l$95$m * l$95$m), $MachinePrecision] * N[(N[(n * N[(N[(U$42$ - U), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$2, 1e+308], N[Sqrt[N[(N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision] * N[(t + N[(t$95$1 - N[(2.0 * N[(l$95$m * N[(l$95$m / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[(l$95$m * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Power[N[Power[N[(N[(n * U), $MachinePrecision] * N[(N[(N[(N[(n * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision] - 2.0), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision], 1.5], $MachinePrecision], 1/3], $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
t_1 := \left(n \cdot {\left(\frac{l\_m}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\\
t_2 := \left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{l\_m \cdot l\_m}{Om}\right) + t\_1\right)\\
\mathbf{if}\;t\_2 \leq 0:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\

\mathbf{elif}\;t\_2 \leq 10^{+308}:\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(t\_1 - 2 \cdot \left(l\_m \cdot \frac{l\_m}{Om}\right)\right)\right)}\\

\mathbf{else}:\\
\;\;\;\;\left(l\_m \cdot \sqrt{2}\right) \cdot \sqrt[3]{{\left(\left(n \cdot U\right) \cdot \frac{\frac{n \cdot \left(U* - U\right)}{Om} - 2}{Om}\right)}^{1.5}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < 0.0

    1. Initial program 7.8%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified32.5%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in Om around -inf 32.3%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t + -1 \cdot \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
    5. Step-by-step derivation
      1. mul-1-neg32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \color{blue}{\left(-\frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)\right)} \]
      2. unsub-neg32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
      3. +-commutative32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} + -1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      4. mul-1-neg32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} + \color{blue}{\left(-\frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
      5. unsub-neg32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} - \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      6. associate-/l*38.2%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} - \color{blue}{{\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}}{Om}\right)\right)\right)} \]
    6. Simplified38.2%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{2 \cdot {\ell}^{2} - {\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}{Om}\right)}\right)\right)} \]
    7. Taylor expanded in l around 0 38.4%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - \frac{n \cdot \left(U* - U\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
    8. Step-by-step derivation
      1. associate-*r/41.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{{\ell}^{2} \cdot \left(2 - \color{blue}{n \cdot \frac{U* - U}{Om}}\right)}{Om}\right)\right)\right)} \]
    9. Simplified41.1%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}}{Om}\right)\right)\right)} \]
    10. Step-by-step derivation
      1. pow241.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]
    11. Applied egg-rr41.1%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]

    if 0.0 < (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < 1e308

    1. Initial program 96.7%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified96.7%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t - \left(2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right)}} \]
    3. Add Preprocessing

    if 1e308 < (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))

    1. Initial program 20.4%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified28.1%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around inf 15.6%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(\frac{n \cdot \left(U* - U\right)}{{Om}^{2}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    5. Step-by-step derivation
      1. associate-/l*14.0%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(\color{blue}{n \cdot \frac{U* - U}{{Om}^{2}}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      2. associate-*r/14.0%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \color{blue}{\frac{2 \cdot 1}{Om}}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      3. metadata-eval14.0%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{\color{blue}{2}}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    6. Simplified14.0%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    7. Step-by-step derivation
      1. add-cbrt-cube13.9%

        \[\leadsto \color{blue}{\sqrt[3]{\left(\sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)} \cdot \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)}\right) \cdot \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)}}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      2. add-sqr-sqrt13.9%

        \[\leadsto \sqrt[3]{\color{blue}{\left(U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)\right)} \cdot \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      3. pow113.9%

        \[\leadsto \sqrt[3]{\color{blue}{{\left(U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)\right)}^{1}} \cdot \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      4. pow1/214.3%

        \[\leadsto \sqrt[3]{{\left(U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)\right)}^{1} \cdot \color{blue}{{\left(U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)\right)}^{0.5}}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      5. pow-prod-up14.3%

        \[\leadsto \sqrt[3]{\color{blue}{{\left(U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)\right)}^{\left(1 + 0.5\right)}}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    8. Applied egg-rr15.3%

      \[\leadsto \color{blue}{\sqrt[3]{{\left(\left(n \cdot U\right) \cdot \mathsf{fma}\left(n, \left(U* - U\right) \cdot {Om}^{-2}, -\frac{2}{Om}\right)\right)}^{1.5}}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    9. Taylor expanded in Om around inf 17.9%

      \[\leadsto \sqrt[3]{{\left(\left(n \cdot U\right) \cdot \color{blue}{\frac{\frac{n \cdot \left(U* - U\right)}{Om} - 2}{Om}}\right)}^{1.5}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
  3. Recombined 3 regimes into one program.
  4. Final simplification54.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right) \leq 0:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(\ell \cdot \ell\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{elif}\;\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right) \leq 10^{+308}:\\ \;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(\left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right) - 2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt[3]{{\left(\left(n \cdot U\right) \cdot \frac{\frac{n \cdot \left(U* - U\right)}{Om} - 2}{Om}\right)}^{1.5}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 3: 64.3% accurate, 0.5× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} t_1 := \left(n \cdot {\left(\frac{l\_m}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\\ t_2 := \left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{l\_m \cdot l\_m}{Om}\right) + t\_1\right)\\ \mathbf{if}\;t\_2 \leq 0:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{elif}\;t\_2 \leq 10^{+308}:\\ \;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(t\_1 - 2 \cdot \left(l\_m \cdot \frac{l\_m}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(l\_m \cdot \sqrt{2}\right) \cdot \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{Om \cdot Om} - \frac{2}{Om}\right)\right)}\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (let* ((t_1 (* (* n (pow (/ l_m Om) 2.0)) (- U* U)))
        (t_2 (* (* (* 2.0 n) U) (+ (- t (* 2.0 (/ (* l_m l_m) Om))) t_1))))
   (if (<= t_2 0.0)
     (sqrt
      (*
       2.0
       (* n (* U (+ t (/ (* (* l_m l_m) (- (* n (/ (- U* U) Om)) 2.0)) Om))))))
     (if (<= t_2 1e+308)
       (sqrt (* (* 2.0 (* n U)) (+ t (- t_1 (* 2.0 (* l_m (/ l_m Om)))))))
       (*
        (* l_m (sqrt 2.0))
        (sqrt (* U (* n (- (* n (/ (- U* U) (* Om Om))) (/ 2.0 Om))))))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double t_1 = (n * pow((l_m / Om), 2.0)) * (U_42_ - U);
	double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1);
	double tmp;
	if (t_2 <= 0.0) {
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	} else if (t_2 <= 1e+308) {
		tmp = sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om)))))));
	} else {
		tmp = (l_m * sqrt(2.0)) * sqrt((U * (n * ((n * ((U_42_ - U) / (Om * Om))) - (2.0 / Om)))));
	}
	return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = (n * ((l_m / om) ** 2.0d0)) * (u_42 - u)
    t_2 = ((2.0d0 * n) * u) * ((t - (2.0d0 * ((l_m * l_m) / om))) + t_1)
    if (t_2 <= 0.0d0) then
        tmp = sqrt((2.0d0 * (n * (u * (t + (((l_m * l_m) * ((n * ((u_42 - u) / om)) - 2.0d0)) / om))))))
    else if (t_2 <= 1d+308) then
        tmp = sqrt(((2.0d0 * (n * u)) * (t + (t_1 - (2.0d0 * (l_m * (l_m / om)))))))
    else
        tmp = (l_m * sqrt(2.0d0)) * sqrt((u * (n * ((n * ((u_42 - u) / (om * om))) - (2.0d0 / om)))))
    end if
    code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double t_1 = (n * Math.pow((l_m / Om), 2.0)) * (U_42_ - U);
	double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1);
	double tmp;
	if (t_2 <= 0.0) {
		tmp = Math.sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	} else if (t_2 <= 1e+308) {
		tmp = Math.sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om)))))));
	} else {
		tmp = (l_m * Math.sqrt(2.0)) * Math.sqrt((U * (n * ((n * ((U_42_ - U) / (Om * Om))) - (2.0 / Om)))));
	}
	return tmp;
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	t_1 = (n * math.pow((l_m / Om), 2.0)) * (U_42_ - U)
	t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1)
	tmp = 0
	if t_2 <= 0.0:
		tmp = math.sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))))
	elif t_2 <= 1e+308:
		tmp = math.sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om)))))))
	else:
		tmp = (l_m * math.sqrt(2.0)) * math.sqrt((U * (n * ((n * ((U_42_ - U) / (Om * Om))) - (2.0 / Om)))))
	return tmp
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	t_1 = Float64(Float64(n * (Float64(l_m / Om) ^ 2.0)) * Float64(U_42_ - U))
	t_2 = Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l_m * l_m) / Om))) + t_1))
	tmp = 0.0
	if (t_2 <= 0.0)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t + Float64(Float64(Float64(l_m * l_m) * Float64(Float64(n * Float64(Float64(U_42_ - U) / Om)) - 2.0)) / Om))))));
	elseif (t_2 <= 1e+308)
		tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * Float64(t + Float64(t_1 - Float64(2.0 * Float64(l_m * Float64(l_m / Om)))))));
	else
		tmp = Float64(Float64(l_m * sqrt(2.0)) * sqrt(Float64(U * Float64(n * Float64(Float64(n * Float64(Float64(U_42_ - U) / Float64(Om * Om))) - Float64(2.0 / Om))))));
	end
	return tmp
end
l_m = abs(l);
function tmp_2 = code(n, U, t, l_m, Om, U_42_)
	t_1 = (n * ((l_m / Om) ^ 2.0)) * (U_42_ - U);
	t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1);
	tmp = 0.0;
	if (t_2 <= 0.0)
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	elseif (t_2 <= 1e+308)
		tmp = sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om)))))));
	else
		tmp = (l_m * sqrt(2.0)) * sqrt((U * (n * ((n * ((U_42_ - U) / (Om * Om))) - (2.0 / Om)))));
	end
	tmp_2 = tmp;
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := Block[{t$95$1 = N[(N[(n * N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l$95$m * l$95$m), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, 0.0], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t + N[(N[(N[(l$95$m * l$95$m), $MachinePrecision] * N[(N[(n * N[(N[(U$42$ - U), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$2, 1e+308], N[Sqrt[N[(N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision] * N[(t + N[(t$95$1 - N[(2.0 * N[(l$95$m * N[(l$95$m / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[(l$95$m * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(U * N[(n * N[(N[(n * N[(N[(U$42$ - U), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
t_1 := \left(n \cdot {\left(\frac{l\_m}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\\
t_2 := \left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{l\_m \cdot l\_m}{Om}\right) + t\_1\right)\\
\mathbf{if}\;t\_2 \leq 0:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\

\mathbf{elif}\;t\_2 \leq 10^{+308}:\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(t\_1 - 2 \cdot \left(l\_m \cdot \frac{l\_m}{Om}\right)\right)\right)}\\

\mathbf{else}:\\
\;\;\;\;\left(l\_m \cdot \sqrt{2}\right) \cdot \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{Om \cdot Om} - \frac{2}{Om}\right)\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < 0.0

    1. Initial program 7.8%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified32.5%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in Om around -inf 32.3%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t + -1 \cdot \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
    5. Step-by-step derivation
      1. mul-1-neg32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \color{blue}{\left(-\frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)\right)} \]
      2. unsub-neg32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
      3. +-commutative32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} + -1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      4. mul-1-neg32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} + \color{blue}{\left(-\frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
      5. unsub-neg32.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} - \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      6. associate-/l*38.2%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} - \color{blue}{{\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}}{Om}\right)\right)\right)} \]
    6. Simplified38.2%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{2 \cdot {\ell}^{2} - {\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}{Om}\right)}\right)\right)} \]
    7. Taylor expanded in l around 0 38.4%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - \frac{n \cdot \left(U* - U\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
    8. Step-by-step derivation
      1. associate-*r/41.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{{\ell}^{2} \cdot \left(2 - \color{blue}{n \cdot \frac{U* - U}{Om}}\right)}{Om}\right)\right)\right)} \]
    9. Simplified41.1%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}}{Om}\right)\right)\right)} \]
    10. Step-by-step derivation
      1. pow241.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]
    11. Applied egg-rr41.1%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]

    if 0.0 < (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < 1e308

    1. Initial program 96.7%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified96.7%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t - \left(2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right)}} \]
    3. Add Preprocessing

    if 1e308 < (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))

    1. Initial program 20.4%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified28.1%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around inf 15.6%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(\frac{n \cdot \left(U* - U\right)}{{Om}^{2}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    5. Step-by-step derivation
      1. associate-/l*14.0%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(\color{blue}{n \cdot \frac{U* - U}{{Om}^{2}}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      2. associate-*r/14.0%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \color{blue}{\frac{2 \cdot 1}{Om}}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      3. metadata-eval14.0%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{\color{blue}{2}}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    6. Simplified14.0%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    7. Step-by-step derivation
      1. unpow214.0%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{\color{blue}{Om \cdot Om}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    8. Applied egg-rr14.0%

      \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{\color{blue}{Om \cdot Om}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
  3. Recombined 3 regimes into one program.
  4. Final simplification52.4%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right) \leq 0:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(\ell \cdot \ell\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{elif}\;\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right) \leq 10^{+308}:\\ \;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(\left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right) - 2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{Om \cdot Om} - \frac{2}{Om}\right)\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 4: 59.9% accurate, 1.0× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} \mathbf{if}\;l\_m \leq 6 \cdot 10^{-145}:\\ \;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\ \mathbf{elif}\;l\_m \leq 2.9 \cdot 10^{+140}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(l\_m \cdot \sqrt{2}\right) \cdot \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{Om \cdot Om} - \frac{2}{Om}\right)\right)}\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (if (<= l_m 6e-145)
   (sqrt (* t (* 2.0 (* n U))))
   (if (<= l_m 2.9e+140)
     (sqrt
      (*
       2.0
       (* n (* U (+ t (/ (* (* l_m l_m) (- (* n (/ (- U* U) Om)) 2.0)) Om))))))
     (*
      (* l_m (sqrt 2.0))
      (sqrt (* U (* n (- (* n (/ (- U* U) (* Om Om))) (/ 2.0 Om)))))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (l_m <= 6e-145) {
		tmp = sqrt((t * (2.0 * (n * U))));
	} else if (l_m <= 2.9e+140) {
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	} else {
		tmp = (l_m * sqrt(2.0)) * sqrt((U * (n * ((n * ((U_42_ - U) / (Om * Om))) - (2.0 / Om)))));
	}
	return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    real(8) :: tmp
    if (l_m <= 6d-145) then
        tmp = sqrt((t * (2.0d0 * (n * u))))
    else if (l_m <= 2.9d+140) then
        tmp = sqrt((2.0d0 * (n * (u * (t + (((l_m * l_m) * ((n * ((u_42 - u) / om)) - 2.0d0)) / om))))))
    else
        tmp = (l_m * sqrt(2.0d0)) * sqrt((u * (n * ((n * ((u_42 - u) / (om * om))) - (2.0d0 / om)))))
    end if
    code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (l_m <= 6e-145) {
		tmp = Math.sqrt((t * (2.0 * (n * U))));
	} else if (l_m <= 2.9e+140) {
		tmp = Math.sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	} else {
		tmp = (l_m * Math.sqrt(2.0)) * Math.sqrt((U * (n * ((n * ((U_42_ - U) / (Om * Om))) - (2.0 / Om)))));
	}
	return tmp;
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	tmp = 0
	if l_m <= 6e-145:
		tmp = math.sqrt((t * (2.0 * (n * U))))
	elif l_m <= 2.9e+140:
		tmp = math.sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))))
	else:
		tmp = (l_m * math.sqrt(2.0)) * math.sqrt((U * (n * ((n * ((U_42_ - U) / (Om * Om))) - (2.0 / Om)))))
	return tmp
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0
	if (l_m <= 6e-145)
		tmp = sqrt(Float64(t * Float64(2.0 * Float64(n * U))));
	elseif (l_m <= 2.9e+140)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t + Float64(Float64(Float64(l_m * l_m) * Float64(Float64(n * Float64(Float64(U_42_ - U) / Om)) - 2.0)) / Om))))));
	else
		tmp = Float64(Float64(l_m * sqrt(2.0)) * sqrt(Float64(U * Float64(n * Float64(Float64(n * Float64(Float64(U_42_ - U) / Float64(Om * Om))) - Float64(2.0 / Om))))));
	end
	return tmp
end
l_m = abs(l);
function tmp_2 = code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0;
	if (l_m <= 6e-145)
		tmp = sqrt((t * (2.0 * (n * U))));
	elseif (l_m <= 2.9e+140)
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	else
		tmp = (l_m * sqrt(2.0)) * sqrt((U * (n * ((n * ((U_42_ - U) / (Om * Om))) - (2.0 / Om)))));
	end
	tmp_2 = tmp;
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[l$95$m, 6e-145], N[Sqrt[N[(t * N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l$95$m, 2.9e+140], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t + N[(N[(N[(l$95$m * l$95$m), $MachinePrecision] * N[(N[(n * N[(N[(U$42$ - U), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[(l$95$m * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(U * N[(n * N[(N[(n * N[(N[(U$42$ - U), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
\mathbf{if}\;l\_m \leq 6 \cdot 10^{-145}:\\
\;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\

\mathbf{elif}\;l\_m \leq 2.9 \cdot 10^{+140}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\

\mathbf{else}:\\
\;\;\;\;\left(l\_m \cdot \sqrt{2}\right) \cdot \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{Om \cdot Om} - \frac{2}{Om}\right)\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if l < 5.99999999999999985e-145

    1. Initial program 54.7%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified56.5%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t - \left(2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around inf 44.6%

      \[\leadsto \sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \color{blue}{t}} \]

    if 5.99999999999999985e-145 < l < 2.8999999999999999e140

    1. Initial program 52.9%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified48.6%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in Om around -inf 53.3%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t + -1 \cdot \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
    5. Step-by-step derivation
      1. mul-1-neg53.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \color{blue}{\left(-\frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)\right)} \]
      2. unsub-neg53.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
      3. +-commutative53.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} + -1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      4. mul-1-neg53.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} + \color{blue}{\left(-\frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
      5. unsub-neg53.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} - \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      6. associate-/l*56.7%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} - \color{blue}{{\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}}{Om}\right)\right)\right)} \]
    6. Simplified56.7%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{2 \cdot {\ell}^{2} - {\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}{Om}\right)}\right)\right)} \]
    7. Taylor expanded in l around 0 56.8%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - \frac{n \cdot \left(U* - U\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
    8. Step-by-step derivation
      1. associate-*r/55.2%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{{\ell}^{2} \cdot \left(2 - \color{blue}{n \cdot \frac{U* - U}{Om}}\right)}{Om}\right)\right)\right)} \]
    9. Simplified55.2%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}}{Om}\right)\right)\right)} \]
    10. Step-by-step derivation
      1. pow255.2%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]
    11. Applied egg-rr55.2%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]

    if 2.8999999999999999e140 < l

    1. Initial program 23.7%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified34.9%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around inf 52.1%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(\frac{n \cdot \left(U* - U\right)}{{Om}^{2}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    5. Step-by-step derivation
      1. associate-/l*45.2%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(\color{blue}{n \cdot \frac{U* - U}{{Om}^{2}}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      2. associate-*r/45.2%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \color{blue}{\frac{2 \cdot 1}{Om}}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      3. metadata-eval45.2%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{\color{blue}{2}}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    6. Simplified45.2%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    7. Step-by-step derivation
      1. unpow245.2%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{\color{blue}{Om \cdot Om}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    8. Applied egg-rr45.2%

      \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{\color{blue}{Om \cdot Om}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
  3. Recombined 3 regimes into one program.
  4. Final simplification47.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 6 \cdot 10^{-145}:\\ \;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\ \mathbf{elif}\;\ell \leq 2.9 \cdot 10^{+140}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(\ell \cdot \ell\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{Om \cdot Om} - \frac{2}{Om}\right)\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 5: 60.1% accurate, 1.0× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} \mathbf{if}\;l\_m \leq 4.5 \cdot 10^{-145}:\\ \;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\ \mathbf{elif}\;l\_m \leq 1.5 \cdot 10^{+140}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(l\_m \cdot \sqrt{2}\right) \cdot \sqrt{U \cdot \left(n \cdot \left(\frac{n \cdot U*}{Om \cdot Om} - \frac{2}{Om}\right)\right)}\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (if (<= l_m 4.5e-145)
   (sqrt (* t (* 2.0 (* n U))))
   (if (<= l_m 1.5e+140)
     (sqrt
      (*
       2.0
       (* n (* U (+ t (/ (* (* l_m l_m) (- (* n (/ (- U* U) Om)) 2.0)) Om))))))
     (*
      (* l_m (sqrt 2.0))
      (sqrt (* U (* n (- (/ (* n U*) (* Om Om)) (/ 2.0 Om)))))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (l_m <= 4.5e-145) {
		tmp = sqrt((t * (2.0 * (n * U))));
	} else if (l_m <= 1.5e+140) {
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	} else {
		tmp = (l_m * sqrt(2.0)) * sqrt((U * (n * (((n * U_42_) / (Om * Om)) - (2.0 / Om)))));
	}
	return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    real(8) :: tmp
    if (l_m <= 4.5d-145) then
        tmp = sqrt((t * (2.0d0 * (n * u))))
    else if (l_m <= 1.5d+140) then
        tmp = sqrt((2.0d0 * (n * (u * (t + (((l_m * l_m) * ((n * ((u_42 - u) / om)) - 2.0d0)) / om))))))
    else
        tmp = (l_m * sqrt(2.0d0)) * sqrt((u * (n * (((n * u_42) / (om * om)) - (2.0d0 / om)))))
    end if
    code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (l_m <= 4.5e-145) {
		tmp = Math.sqrt((t * (2.0 * (n * U))));
	} else if (l_m <= 1.5e+140) {
		tmp = Math.sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	} else {
		tmp = (l_m * Math.sqrt(2.0)) * Math.sqrt((U * (n * (((n * U_42_) / (Om * Om)) - (2.0 / Om)))));
	}
	return tmp;
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	tmp = 0
	if l_m <= 4.5e-145:
		tmp = math.sqrt((t * (2.0 * (n * U))))
	elif l_m <= 1.5e+140:
		tmp = math.sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))))
	else:
		tmp = (l_m * math.sqrt(2.0)) * math.sqrt((U * (n * (((n * U_42_) / (Om * Om)) - (2.0 / Om)))))
	return tmp
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0
	if (l_m <= 4.5e-145)
		tmp = sqrt(Float64(t * Float64(2.0 * Float64(n * U))));
	elseif (l_m <= 1.5e+140)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t + Float64(Float64(Float64(l_m * l_m) * Float64(Float64(n * Float64(Float64(U_42_ - U) / Om)) - 2.0)) / Om))))));
	else
		tmp = Float64(Float64(l_m * sqrt(2.0)) * sqrt(Float64(U * Float64(n * Float64(Float64(Float64(n * U_42_) / Float64(Om * Om)) - Float64(2.0 / Om))))));
	end
	return tmp
end
l_m = abs(l);
function tmp_2 = code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0;
	if (l_m <= 4.5e-145)
		tmp = sqrt((t * (2.0 * (n * U))));
	elseif (l_m <= 1.5e+140)
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	else
		tmp = (l_m * sqrt(2.0)) * sqrt((U * (n * (((n * U_42_) / (Om * Om)) - (2.0 / Om)))));
	end
	tmp_2 = tmp;
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[l$95$m, 4.5e-145], N[Sqrt[N[(t * N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l$95$m, 1.5e+140], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t + N[(N[(N[(l$95$m * l$95$m), $MachinePrecision] * N[(N[(n * N[(N[(U$42$ - U), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[(l$95$m * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(U * N[(n * N[(N[(N[(n * U$42$), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] - N[(2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
\mathbf{if}\;l\_m \leq 4.5 \cdot 10^{-145}:\\
\;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\

\mathbf{elif}\;l\_m \leq 1.5 \cdot 10^{+140}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\

\mathbf{else}:\\
\;\;\;\;\left(l\_m \cdot \sqrt{2}\right) \cdot \sqrt{U \cdot \left(n \cdot \left(\frac{n \cdot U*}{Om \cdot Om} - \frac{2}{Om}\right)\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if l < 4.5000000000000001e-145

    1. Initial program 54.7%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified56.5%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t - \left(2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around inf 44.6%

      \[\leadsto \sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \color{blue}{t}} \]

    if 4.5000000000000001e-145 < l < 1.49999999999999998e140

    1. Initial program 52.9%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified48.6%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in Om around -inf 53.3%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t + -1 \cdot \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
    5. Step-by-step derivation
      1. mul-1-neg53.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \color{blue}{\left(-\frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)\right)} \]
      2. unsub-neg53.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
      3. +-commutative53.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} + -1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      4. mul-1-neg53.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} + \color{blue}{\left(-\frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
      5. unsub-neg53.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} - \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      6. associate-/l*56.7%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} - \color{blue}{{\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}}{Om}\right)\right)\right)} \]
    6. Simplified56.7%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{2 \cdot {\ell}^{2} - {\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}{Om}\right)}\right)\right)} \]
    7. Taylor expanded in l around 0 56.8%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - \frac{n \cdot \left(U* - U\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
    8. Step-by-step derivation
      1. associate-*r/55.2%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{{\ell}^{2} \cdot \left(2 - \color{blue}{n \cdot \frac{U* - U}{Om}}\right)}{Om}\right)\right)\right)} \]
    9. Simplified55.2%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}}{Om}\right)\right)\right)} \]
    10. Step-by-step derivation
      1. pow255.2%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]
    11. Applied egg-rr55.2%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]

    if 1.49999999999999998e140 < l

    1. Initial program 23.7%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified34.9%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around inf 52.1%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(\frac{n \cdot \left(U* - U\right)}{{Om}^{2}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    5. Step-by-step derivation
      1. associate-/l*45.2%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(\color{blue}{n \cdot \frac{U* - U}{{Om}^{2}}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      2. associate-*r/45.2%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \color{blue}{\frac{2 \cdot 1}{Om}}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      3. metadata-eval45.2%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{\color{blue}{2}}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    6. Simplified45.2%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    7. Taylor expanded in U* around inf 52.1%

      \[\leadsto \sqrt{U \cdot \left(n \cdot \left(\color{blue}{\frac{U* \cdot n}{{Om}^{2}}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    8. Step-by-step derivation
      1. unpow245.2%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{\color{blue}{Om \cdot Om}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    9. Applied egg-rr52.1%

      \[\leadsto \sqrt{U \cdot \left(n \cdot \left(\frac{U* \cdot n}{\color{blue}{Om \cdot Om}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
  3. Recombined 3 regimes into one program.
  4. Final simplification47.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 4.5 \cdot 10^{-145}:\\ \;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\ \mathbf{elif}\;\ell \leq 1.5 \cdot 10^{+140}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(\ell \cdot \ell\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt{U \cdot \left(n \cdot \left(\frac{n \cdot U*}{Om \cdot Om} - \frac{2}{Om}\right)\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 6: 54.8% accurate, 1.0× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} \mathbf{if}\;l\_m \leq 5.8 \cdot 10^{-145}:\\ \;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\ \mathbf{elif}\;l\_m \leq 1.02 \cdot 10^{+143}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(l\_m \cdot \sqrt{2}\right) \cdot \sqrt{\frac{n \cdot \left(U \cdot -2\right)}{Om}}\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (if (<= l_m 5.8e-145)
   (sqrt (* t (* 2.0 (* n U))))
   (if (<= l_m 1.02e+143)
     (sqrt
      (*
       2.0
       (* n (* U (+ t (/ (* (* l_m l_m) (- (* n (/ (- U* U) Om)) 2.0)) Om))))))
     (* (* l_m (sqrt 2.0)) (sqrt (/ (* n (* U -2.0)) Om))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (l_m <= 5.8e-145) {
		tmp = sqrt((t * (2.0 * (n * U))));
	} else if (l_m <= 1.02e+143) {
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	} else {
		tmp = (l_m * sqrt(2.0)) * sqrt(((n * (U * -2.0)) / Om));
	}
	return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    real(8) :: tmp
    if (l_m <= 5.8d-145) then
        tmp = sqrt((t * (2.0d0 * (n * u))))
    else if (l_m <= 1.02d+143) then
        tmp = sqrt((2.0d0 * (n * (u * (t + (((l_m * l_m) * ((n * ((u_42 - u) / om)) - 2.0d0)) / om))))))
    else
        tmp = (l_m * sqrt(2.0d0)) * sqrt(((n * (u * (-2.0d0))) / om))
    end if
    code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (l_m <= 5.8e-145) {
		tmp = Math.sqrt((t * (2.0 * (n * U))));
	} else if (l_m <= 1.02e+143) {
		tmp = Math.sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	} else {
		tmp = (l_m * Math.sqrt(2.0)) * Math.sqrt(((n * (U * -2.0)) / Om));
	}
	return tmp;
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	tmp = 0
	if l_m <= 5.8e-145:
		tmp = math.sqrt((t * (2.0 * (n * U))))
	elif l_m <= 1.02e+143:
		tmp = math.sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))))
	else:
		tmp = (l_m * math.sqrt(2.0)) * math.sqrt(((n * (U * -2.0)) / Om))
	return tmp
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0
	if (l_m <= 5.8e-145)
		tmp = sqrt(Float64(t * Float64(2.0 * Float64(n * U))));
	elseif (l_m <= 1.02e+143)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t + Float64(Float64(Float64(l_m * l_m) * Float64(Float64(n * Float64(Float64(U_42_ - U) / Om)) - 2.0)) / Om))))));
	else
		tmp = Float64(Float64(l_m * sqrt(2.0)) * sqrt(Float64(Float64(n * Float64(U * -2.0)) / Om)));
	end
	return tmp
end
l_m = abs(l);
function tmp_2 = code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0;
	if (l_m <= 5.8e-145)
		tmp = sqrt((t * (2.0 * (n * U))));
	elseif (l_m <= 1.02e+143)
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	else
		tmp = (l_m * sqrt(2.0)) * sqrt(((n * (U * -2.0)) / Om));
	end
	tmp_2 = tmp;
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[l$95$m, 5.8e-145], N[Sqrt[N[(t * N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l$95$m, 1.02e+143], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t + N[(N[(N[(l$95$m * l$95$m), $MachinePrecision] * N[(N[(n * N[(N[(U$42$ - U), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[(l$95$m * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(N[(n * N[(U * -2.0), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
\mathbf{if}\;l\_m \leq 5.8 \cdot 10^{-145}:\\
\;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\

\mathbf{elif}\;l\_m \leq 1.02 \cdot 10^{+143}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\

\mathbf{else}:\\
\;\;\;\;\left(l\_m \cdot \sqrt{2}\right) \cdot \sqrt{\frac{n \cdot \left(U \cdot -2\right)}{Om}}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if l < 5.79999999999999968e-145

    1. Initial program 54.7%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified56.5%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t - \left(2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around inf 44.6%

      \[\leadsto \sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \color{blue}{t}} \]

    if 5.79999999999999968e-145 < l < 1.01999999999999995e143

    1. Initial program 53.6%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified49.4%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in Om around -inf 54.1%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t + -1 \cdot \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
    5. Step-by-step derivation
      1. mul-1-neg54.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \color{blue}{\left(-\frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)\right)} \]
      2. unsub-neg54.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
      3. +-commutative54.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} + -1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      4. mul-1-neg54.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} + \color{blue}{\left(-\frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
      5. unsub-neg54.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} - \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      6. associate-/l*57.4%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} - \color{blue}{{\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}}{Om}\right)\right)\right)} \]
    6. Simplified57.4%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{2 \cdot {\ell}^{2} - {\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}{Om}\right)}\right)\right)} \]
    7. Taylor expanded in l around 0 57.4%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - \frac{n \cdot \left(U* - U\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
    8. Step-by-step derivation
      1. associate-*r/55.9%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{{\ell}^{2} \cdot \left(2 - \color{blue}{n \cdot \frac{U* - U}{Om}}\right)}{Om}\right)\right)\right)} \]
    9. Simplified55.9%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}}{Om}\right)\right)\right)} \]
    10. Step-by-step derivation
      1. pow255.9%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]
    11. Applied egg-rr55.9%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]

    if 1.01999999999999995e143 < l

    1. Initial program 20.8%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified32.4%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around inf 50.3%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(\frac{n \cdot \left(U* - U\right)}{{Om}^{2}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    5. Step-by-step derivation
      1. associate-/l*43.1%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(\color{blue}{n \cdot \frac{U* - U}{{Om}^{2}}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      2. associate-*r/43.1%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \color{blue}{\frac{2 \cdot 1}{Om}}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      3. metadata-eval43.1%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{\color{blue}{2}}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    6. Simplified43.1%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    7. Taylor expanded in n around 0 39.9%

      \[\leadsto \sqrt{U \cdot \color{blue}{\left(-2 \cdot \frac{n}{Om}\right)}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    8. Taylor expanded in U around 0 52.2%

      \[\leadsto \sqrt{\color{blue}{-2 \cdot \frac{U \cdot n}{Om}}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    9. Step-by-step derivation
      1. associate-*r/52.2%

        \[\leadsto \sqrt{\color{blue}{\frac{-2 \cdot \left(U \cdot n\right)}{Om}}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      2. associate-*r*52.2%

        \[\leadsto \sqrt{\frac{\color{blue}{\left(-2 \cdot U\right) \cdot n}}{Om}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    10. Simplified52.2%

      \[\leadsto \sqrt{\color{blue}{\frac{\left(-2 \cdot U\right) \cdot n}{Om}}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
  3. Recombined 3 regimes into one program.
  4. Final simplification48.1%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 5.8 \cdot 10^{-145}:\\ \;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\ \mathbf{elif}\;\ell \leq 1.02 \cdot 10^{+143}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(\ell \cdot \ell\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt{\frac{n \cdot \left(U \cdot -2\right)}{Om}}\\ \end{array} \]
  5. Add Preprocessing

Alternative 7: 54.9% accurate, 1.0× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} \mathbf{if}\;l\_m \leq 2.2 \cdot 10^{-144}:\\ \;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\ \mathbf{elif}\;l\_m \leq 1.8 \cdot 10^{+162}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(l\_m \cdot \sqrt{2}\right) \cdot \sqrt{U \cdot \left(-2 \cdot \frac{n}{Om}\right)}\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (if (<= l_m 2.2e-144)
   (sqrt (* t (* 2.0 (* n U))))
   (if (<= l_m 1.8e+162)
     (sqrt
      (*
       2.0
       (* n (* U (+ t (/ (* (* l_m l_m) (- (* n (/ (- U* U) Om)) 2.0)) Om))))))
     (* (* l_m (sqrt 2.0)) (sqrt (* U (* -2.0 (/ n Om))))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (l_m <= 2.2e-144) {
		tmp = sqrt((t * (2.0 * (n * U))));
	} else if (l_m <= 1.8e+162) {
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	} else {
		tmp = (l_m * sqrt(2.0)) * sqrt((U * (-2.0 * (n / Om))));
	}
	return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    real(8) :: tmp
    if (l_m <= 2.2d-144) then
        tmp = sqrt((t * (2.0d0 * (n * u))))
    else if (l_m <= 1.8d+162) then
        tmp = sqrt((2.0d0 * (n * (u * (t + (((l_m * l_m) * ((n * ((u_42 - u) / om)) - 2.0d0)) / om))))))
    else
        tmp = (l_m * sqrt(2.0d0)) * sqrt((u * ((-2.0d0) * (n / om))))
    end if
    code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (l_m <= 2.2e-144) {
		tmp = Math.sqrt((t * (2.0 * (n * U))));
	} else if (l_m <= 1.8e+162) {
		tmp = Math.sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	} else {
		tmp = (l_m * Math.sqrt(2.0)) * Math.sqrt((U * (-2.0 * (n / Om))));
	}
	return tmp;
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	tmp = 0
	if l_m <= 2.2e-144:
		tmp = math.sqrt((t * (2.0 * (n * U))))
	elif l_m <= 1.8e+162:
		tmp = math.sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))))
	else:
		tmp = (l_m * math.sqrt(2.0)) * math.sqrt((U * (-2.0 * (n / Om))))
	return tmp
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0
	if (l_m <= 2.2e-144)
		tmp = sqrt(Float64(t * Float64(2.0 * Float64(n * U))));
	elseif (l_m <= 1.8e+162)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t + Float64(Float64(Float64(l_m * l_m) * Float64(Float64(n * Float64(Float64(U_42_ - U) / Om)) - 2.0)) / Om))))));
	else
		tmp = Float64(Float64(l_m * sqrt(2.0)) * sqrt(Float64(U * Float64(-2.0 * Float64(n / Om)))));
	end
	return tmp
end
l_m = abs(l);
function tmp_2 = code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0;
	if (l_m <= 2.2e-144)
		tmp = sqrt((t * (2.0 * (n * U))));
	elseif (l_m <= 1.8e+162)
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	else
		tmp = (l_m * sqrt(2.0)) * sqrt((U * (-2.0 * (n / Om))));
	end
	tmp_2 = tmp;
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[l$95$m, 2.2e-144], N[Sqrt[N[(t * N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l$95$m, 1.8e+162], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t + N[(N[(N[(l$95$m * l$95$m), $MachinePrecision] * N[(N[(n * N[(N[(U$42$ - U), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[(l$95$m * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(U * N[(-2.0 * N[(n / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
\mathbf{if}\;l\_m \leq 2.2 \cdot 10^{-144}:\\
\;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\

\mathbf{elif}\;l\_m \leq 1.8 \cdot 10^{+162}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\

\mathbf{else}:\\
\;\;\;\;\left(l\_m \cdot \sqrt{2}\right) \cdot \sqrt{U \cdot \left(-2 \cdot \frac{n}{Om}\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if l < 2.20000000000000006e-144

    1. Initial program 54.7%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified56.5%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t - \left(2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around inf 44.6%

      \[\leadsto \sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \color{blue}{t}} \]

    if 2.20000000000000006e-144 < l < 1.79999999999999997e162

    1. Initial program 51.3%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified48.8%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in Om around -inf 50.1%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t + -1 \cdot \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
    5. Step-by-step derivation
      1. mul-1-neg50.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \color{blue}{\left(-\frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)\right)} \]
      2. unsub-neg50.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
      3. +-commutative50.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} + -1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      4. mul-1-neg50.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} + \color{blue}{\left(-\frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
      5. unsub-neg50.1%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} - \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      6. associate-/l*56.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} - \color{blue}{{\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}}{Om}\right)\right)\right)} \]
    6. Simplified56.3%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{2 \cdot {\ell}^{2} - {\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}{Om}\right)}\right)\right)} \]
    7. Taylor expanded in l around 0 56.3%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - \frac{n \cdot \left(U* - U\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
    8. Step-by-step derivation
      1. associate-*r/54.9%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{{\ell}^{2} \cdot \left(2 - \color{blue}{n \cdot \frac{U* - U}{Om}}\right)}{Om}\right)\right)\right)} \]
    9. Simplified54.9%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}}{Om}\right)\right)\right)} \]
    10. Step-by-step derivation
      1. pow254.9%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]
    11. Applied egg-rr54.9%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]

    if 1.79999999999999997e162 < l

    1. Initial program 20.4%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified30.2%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around inf 56.8%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(\frac{n \cdot \left(U* - U\right)}{{Om}^{2}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    5. Step-by-step derivation
      1. associate-/l*47.8%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(\color{blue}{n \cdot \frac{U* - U}{{Om}^{2}}} - 2 \cdot \frac{1}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      2. associate-*r/47.8%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \color{blue}{\frac{2 \cdot 1}{Om}}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
      3. metadata-eval47.8%

        \[\leadsto \sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{\color{blue}{2}}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right) \]
    6. Simplified47.8%

      \[\leadsto \color{blue}{\sqrt{U \cdot \left(n \cdot \left(n \cdot \frac{U* - U}{{Om}^{2}} - \frac{2}{Om}\right)\right)} \cdot \left(\ell \cdot \sqrt{2}\right)} \]
    7. Taylor expanded in n around 0 43.9%

      \[\leadsto \sqrt{U \cdot \color{blue}{\left(-2 \cdot \frac{n}{Om}\right)}} \cdot \left(\ell \cdot \sqrt{2}\right) \]
  3. Recombined 3 regimes into one program.
  4. Final simplification47.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 2.2 \cdot 10^{-144}:\\ \;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\ \mathbf{elif}\;\ell \leq 1.8 \cdot 10^{+162}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(\ell \cdot \ell\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt{U \cdot \left(-2 \cdot \frac{n}{Om}\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 8: 50.6% accurate, 1.8× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} \mathbf{if}\;t \leq -8 \cdot 10^{+214}:\\ \;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (if (<= t -8e+214)
   (sqrt (* t (* 2.0 (* n U))))
   (sqrt
    (*
     2.0
     (* n (* U (+ t (/ (* (* l_m l_m) (- (* n (/ (- U* U) Om)) 2.0)) Om))))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (t <= -8e+214) {
		tmp = sqrt((t * (2.0 * (n * U))));
	} else {
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	}
	return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    real(8) :: tmp
    if (t <= (-8d+214)) then
        tmp = sqrt((t * (2.0d0 * (n * u))))
    else
        tmp = sqrt((2.0d0 * (n * (u * (t + (((l_m * l_m) * ((n * ((u_42 - u) / om)) - 2.0d0)) / om))))))
    end if
    code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (t <= -8e+214) {
		tmp = Math.sqrt((t * (2.0 * (n * U))));
	} else {
		tmp = Math.sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	}
	return tmp;
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	tmp = 0
	if t <= -8e+214:
		tmp = math.sqrt((t * (2.0 * (n * U))))
	else:
		tmp = math.sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))))
	return tmp
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0
	if (t <= -8e+214)
		tmp = sqrt(Float64(t * Float64(2.0 * Float64(n * U))));
	else
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t + Float64(Float64(Float64(l_m * l_m) * Float64(Float64(n * Float64(Float64(U_42_ - U) / Om)) - 2.0)) / Om))))));
	end
	return tmp
end
l_m = abs(l);
function tmp_2 = code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0;
	if (t <= -8e+214)
		tmp = sqrt((t * (2.0 * (n * U))));
	else
		tmp = sqrt((2.0 * (n * (U * (t + (((l_m * l_m) * ((n * ((U_42_ - U) / Om)) - 2.0)) / Om))))));
	end
	tmp_2 = tmp;
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[t, -8e+214], N[Sqrt[N[(t * N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t + N[(N[(N[(l$95$m * l$95$m), $MachinePrecision] * N[(N[(n * N[(N[(U$42$ - U), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
\mathbf{if}\;t \leq -8 \cdot 10^{+214}:\\
\;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\

\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(l\_m \cdot l\_m\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -7.9999999999999996e214

    1. Initial program 53.8%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified58.0%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t - \left(2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around inf 62.9%

      \[\leadsto \sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \color{blue}{t}} \]

    if -7.9999999999999996e214 < t

    1. Initial program 50.7%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified53.7%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in Om around -inf 46.3%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t + -1 \cdot \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
    5. Step-by-step derivation
      1. mul-1-neg46.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \color{blue}{\left(-\frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)\right)} \]
      2. unsub-neg46.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{-1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om} + 2 \cdot {\ell}^{2}}{Om}\right)}\right)\right)} \]
      3. +-commutative46.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} + -1 \cdot \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      4. mul-1-neg46.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} + \color{blue}{\left(-\frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
      5. unsub-neg46.3%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{2 \cdot {\ell}^{2} - \frac{{\ell}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)}{Om}}}{Om}\right)\right)\right)} \]
      6. associate-/l*49.5%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{2 \cdot {\ell}^{2} - \color{blue}{{\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}}{Om}\right)\right)\right)} \]
    6. Simplified49.5%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \color{blue}{\left(t - \frac{2 \cdot {\ell}^{2} - {\ell}^{2} \cdot \frac{n \cdot \left(U* - U\right)}{Om}}{Om}\right)}\right)\right)} \]
    7. Taylor expanded in l around 0 52.8%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - \frac{n \cdot \left(U* - U\right)}{Om}\right)}}{Om}\right)\right)\right)} \]
    8. Step-by-step derivation
      1. associate-*r/53.8%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{{\ell}^{2} \cdot \left(2 - \color{blue}{n \cdot \frac{U* - U}{Om}}\right)}{Om}\right)\right)\right)} \]
    9. Simplified53.8%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{{\ell}^{2} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}}{Om}\right)\right)\right)} \]
    10. Step-by-step derivation
      1. pow253.8%

        \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]
    11. Applied egg-rr53.8%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - \frac{\color{blue}{\left(\ell \cdot \ell\right)} \cdot \left(2 - n \cdot \frac{U* - U}{Om}\right)}{Om}\right)\right)\right)} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification54.6%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -8 \cdot 10^{+214}:\\ \;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\left(\ell \cdot \ell\right) \cdot \left(n \cdot \frac{U* - U}{Om} - 2\right)}{Om}\right)\right)\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 9: 39.6% accurate, 1.8× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} \mathbf{if}\;l\_m \leq 3.6 \cdot 10^{+57}:\\ \;\;\;\;\sqrt{t \cdot \left(n \cdot \left(2 \cdot U\right)\right)}\\ \mathbf{elif}\;l\_m \leq 1.35 \cdot 10^{+217}:\\ \;\;\;\;\left(l\_m \cdot \frac{n}{Om}\right) \cdot \sqrt{U \cdot \left(2 \cdot U*\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{U \cdot \left(\left(U - U*\right) \cdot -2\right)} \cdot \left(l\_m \cdot \frac{-n}{Om}\right)\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (if (<= l_m 3.6e+57)
   (sqrt (* t (* n (* 2.0 U))))
   (if (<= l_m 1.35e+217)
     (* (* l_m (/ n Om)) (sqrt (* U (* 2.0 U*))))
     (* (sqrt (* U (* (- U U*) -2.0))) (* l_m (/ (- n) Om))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (l_m <= 3.6e+57) {
		tmp = sqrt((t * (n * (2.0 * U))));
	} else if (l_m <= 1.35e+217) {
		tmp = (l_m * (n / Om)) * sqrt((U * (2.0 * U_42_)));
	} else {
		tmp = sqrt((U * ((U - U_42_) * -2.0))) * (l_m * (-n / Om));
	}
	return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    real(8) :: tmp
    if (l_m <= 3.6d+57) then
        tmp = sqrt((t * (n * (2.0d0 * u))))
    else if (l_m <= 1.35d+217) then
        tmp = (l_m * (n / om)) * sqrt((u * (2.0d0 * u_42)))
    else
        tmp = sqrt((u * ((u - u_42) * (-2.0d0)))) * (l_m * (-n / om))
    end if
    code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (l_m <= 3.6e+57) {
		tmp = Math.sqrt((t * (n * (2.0 * U))));
	} else if (l_m <= 1.35e+217) {
		tmp = (l_m * (n / Om)) * Math.sqrt((U * (2.0 * U_42_)));
	} else {
		tmp = Math.sqrt((U * ((U - U_42_) * -2.0))) * (l_m * (-n / Om));
	}
	return tmp;
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	tmp = 0
	if l_m <= 3.6e+57:
		tmp = math.sqrt((t * (n * (2.0 * U))))
	elif l_m <= 1.35e+217:
		tmp = (l_m * (n / Om)) * math.sqrt((U * (2.0 * U_42_)))
	else:
		tmp = math.sqrt((U * ((U - U_42_) * -2.0))) * (l_m * (-n / Om))
	return tmp
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0
	if (l_m <= 3.6e+57)
		tmp = sqrt(Float64(t * Float64(n * Float64(2.0 * U))));
	elseif (l_m <= 1.35e+217)
		tmp = Float64(Float64(l_m * Float64(n / Om)) * sqrt(Float64(U * Float64(2.0 * U_42_))));
	else
		tmp = Float64(sqrt(Float64(U * Float64(Float64(U - U_42_) * -2.0))) * Float64(l_m * Float64(Float64(-n) / Om)));
	end
	return tmp
end
l_m = abs(l);
function tmp_2 = code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0;
	if (l_m <= 3.6e+57)
		tmp = sqrt((t * (n * (2.0 * U))));
	elseif (l_m <= 1.35e+217)
		tmp = (l_m * (n / Om)) * sqrt((U * (2.0 * U_42_)));
	else
		tmp = sqrt((U * ((U - U_42_) * -2.0))) * (l_m * (-n / Om));
	end
	tmp_2 = tmp;
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[l$95$m, 3.6e+57], N[Sqrt[N[(t * N[(n * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l$95$m, 1.35e+217], N[(N[(l$95$m * N[(n / Om), $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(U * N[(2.0 * U$42$), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Sqrt[N[(U * N[(N[(U - U$42$), $MachinePrecision] * -2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[(l$95$m * N[((-n) / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
\mathbf{if}\;l\_m \leq 3.6 \cdot 10^{+57}:\\
\;\;\;\;\sqrt{t \cdot \left(n \cdot \left(2 \cdot U\right)\right)}\\

\mathbf{elif}\;l\_m \leq 1.35 \cdot 10^{+217}:\\
\;\;\;\;\left(l\_m \cdot \frac{n}{Om}\right) \cdot \sqrt{U \cdot \left(2 \cdot U*\right)}\\

\mathbf{else}:\\
\;\;\;\;\sqrt{U \cdot \left(\left(U - U*\right) \cdot -2\right)} \cdot \left(l\_m \cdot \frac{-n}{Om}\right)\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if l < 3.6000000000000002e57

    1. Initial program 55.0%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified54.7%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around 0 40.6%

      \[\leadsto \sqrt{\color{blue}{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}} \]
    5. Step-by-step derivation
      1. associate-*r*40.6%

        \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
    6. Simplified40.6%

      \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
    7. Taylor expanded in U around 0 40.6%

      \[\leadsto \sqrt{\color{blue}{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}} \]
    8. Step-by-step derivation
      1. associate-*r*40.6%

        \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
      2. associate-*r*43.7%

        \[\leadsto \sqrt{\color{blue}{\left(\left(2 \cdot U\right) \cdot n\right) \cdot t}} \]
    9. Simplified43.7%

      \[\leadsto \sqrt{\color{blue}{\left(\left(2 \cdot U\right) \cdot n\right) \cdot t}} \]

    if 3.6000000000000002e57 < l < 1.35000000000000001e217

    1. Initial program 35.7%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt35.5%

        \[\leadsto \sqrt{\color{blue}{\left(\left(\sqrt[3]{\left(2 \cdot n\right) \cdot U} \cdot \sqrt[3]{\left(2 \cdot n\right) \cdot U}\right) \cdot \sqrt[3]{\left(2 \cdot n\right) \cdot U}\right)} \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
      2. pow335.5%

        \[\leadsto \sqrt{\color{blue}{{\left(\sqrt[3]{\left(2 \cdot n\right) \cdot U}\right)}^{3}} \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
      3. associate-*r*35.5%

        \[\leadsto \sqrt{{\left(\sqrt[3]{\color{blue}{2 \cdot \left(n \cdot U\right)}}\right)}^{3} \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    4. Applied egg-rr35.5%

      \[\leadsto \sqrt{\color{blue}{{\left(\sqrt[3]{2 \cdot \left(n \cdot U\right)}\right)}^{3}} \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    5. Taylor expanded in U* around inf 19.5%

      \[\leadsto \color{blue}{\frac{\ell \cdot n}{Om} \cdot \sqrt{U \cdot \left(U* \cdot {\left(\sqrt[3]{2}\right)}^{3}\right)}} \]
    6. Step-by-step derivation
      1. associate-/l*22.3%

        \[\leadsto \color{blue}{\left(\ell \cdot \frac{n}{Om}\right)} \cdot \sqrt{U \cdot \left(U* \cdot {\left(\sqrt[3]{2}\right)}^{3}\right)} \]
      2. rem-cube-cbrt22.4%

        \[\leadsto \left(\ell \cdot \frac{n}{Om}\right) \cdot \sqrt{U \cdot \left(U* \cdot \color{blue}{2}\right)} \]
    7. Simplified22.4%

      \[\leadsto \color{blue}{\left(\ell \cdot \frac{n}{Om}\right) \cdot \sqrt{U \cdot \left(U* \cdot 2\right)}} \]

    if 1.35000000000000001e217 < l

    1. Initial program 17.4%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt17.4%

        \[\leadsto \sqrt{\color{blue}{\left(\left(\sqrt[3]{\left(2 \cdot n\right) \cdot U} \cdot \sqrt[3]{\left(2 \cdot n\right) \cdot U}\right) \cdot \sqrt[3]{\left(2 \cdot n\right) \cdot U}\right)} \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
      2. pow317.4%

        \[\leadsto \sqrt{\color{blue}{{\left(\sqrt[3]{\left(2 \cdot n\right) \cdot U}\right)}^{3}} \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
      3. associate-*r*17.4%

        \[\leadsto \sqrt{{\left(\sqrt[3]{\color{blue}{2 \cdot \left(n \cdot U\right)}}\right)}^{3} \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    4. Applied egg-rr17.4%

      \[\leadsto \sqrt{\color{blue}{{\left(\sqrt[3]{2 \cdot \left(n \cdot U\right)}\right)}^{3}} \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    5. Taylor expanded in n around -inf 17.0%

      \[\leadsto \color{blue}{-1 \cdot \left(\frac{\ell \cdot n}{Om} \cdot \sqrt{U \cdot \left({\left(\sqrt[3]{-2}\right)}^{3} \cdot \left(U - U*\right)\right)}\right)} \]
    6. Step-by-step derivation
      1. mul-1-neg17.0%

        \[\leadsto \color{blue}{-\frac{\ell \cdot n}{Om} \cdot \sqrt{U \cdot \left({\left(\sqrt[3]{-2}\right)}^{3} \cdot \left(U - U*\right)\right)}} \]
      2. associate-/l*17.0%

        \[\leadsto -\color{blue}{\left(\ell \cdot \frac{n}{Om}\right)} \cdot \sqrt{U \cdot \left({\left(\sqrt[3]{-2}\right)}^{3} \cdot \left(U - U*\right)\right)} \]
      3. rem-cube-cbrt17.0%

        \[\leadsto -\left(\ell \cdot \frac{n}{Om}\right) \cdot \sqrt{U \cdot \left(\color{blue}{-2} \cdot \left(U - U*\right)\right)} \]
    7. Simplified17.0%

      \[\leadsto \color{blue}{-\left(\ell \cdot \frac{n}{Om}\right) \cdot \sqrt{U \cdot \left(-2 \cdot \left(U - U*\right)\right)}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification39.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 3.6 \cdot 10^{+57}:\\ \;\;\;\;\sqrt{t \cdot \left(n \cdot \left(2 \cdot U\right)\right)}\\ \mathbf{elif}\;\ell \leq 1.35 \cdot 10^{+217}:\\ \;\;\;\;\left(\ell \cdot \frac{n}{Om}\right) \cdot \sqrt{U \cdot \left(2 \cdot U*\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{U \cdot \left(\left(U - U*\right) \cdot -2\right)} \cdot \left(\ell \cdot \frac{-n}{Om}\right)\\ \end{array} \]
  5. Add Preprocessing

Alternative 10: 37.9% accurate, 1.9× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} \mathbf{if}\;Om \leq -1.85 \cdot 10^{-29}:\\ \;\;\;\;\sqrt{t \cdot \left(n \cdot \left(2 \cdot U\right)\right)}\\ \mathbf{elif}\;Om \leq 2.25 \cdot 10^{-133}:\\ \;\;\;\;\left(l\_m \cdot \frac{n}{Om}\right) \cdot \sqrt{U \cdot \left(2 \cdot U*\right)}\\ \mathbf{else}:\\ \;\;\;\;{\left(\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right)}^{0.5}\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (if (<= Om -1.85e-29)
   (sqrt (* t (* n (* 2.0 U))))
   (if (<= Om 2.25e-133)
     (* (* l_m (/ n Om)) (sqrt (* U (* 2.0 U*))))
     (pow (* (* 2.0 n) (* U t)) 0.5))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (Om <= -1.85e-29) {
		tmp = sqrt((t * (n * (2.0 * U))));
	} else if (Om <= 2.25e-133) {
		tmp = (l_m * (n / Om)) * sqrt((U * (2.0 * U_42_)));
	} else {
		tmp = pow(((2.0 * n) * (U * t)), 0.5);
	}
	return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    real(8) :: tmp
    if (om <= (-1.85d-29)) then
        tmp = sqrt((t * (n * (2.0d0 * u))))
    else if (om <= 2.25d-133) then
        tmp = (l_m * (n / om)) * sqrt((u * (2.0d0 * u_42)))
    else
        tmp = ((2.0d0 * n) * (u * t)) ** 0.5d0
    end if
    code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (Om <= -1.85e-29) {
		tmp = Math.sqrt((t * (n * (2.0 * U))));
	} else if (Om <= 2.25e-133) {
		tmp = (l_m * (n / Om)) * Math.sqrt((U * (2.0 * U_42_)));
	} else {
		tmp = Math.pow(((2.0 * n) * (U * t)), 0.5);
	}
	return tmp;
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	tmp = 0
	if Om <= -1.85e-29:
		tmp = math.sqrt((t * (n * (2.0 * U))))
	elif Om <= 2.25e-133:
		tmp = (l_m * (n / Om)) * math.sqrt((U * (2.0 * U_42_)))
	else:
		tmp = math.pow(((2.0 * n) * (U * t)), 0.5)
	return tmp
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0
	if (Om <= -1.85e-29)
		tmp = sqrt(Float64(t * Float64(n * Float64(2.0 * U))));
	elseif (Om <= 2.25e-133)
		tmp = Float64(Float64(l_m * Float64(n / Om)) * sqrt(Float64(U * Float64(2.0 * U_42_))));
	else
		tmp = Float64(Float64(2.0 * n) * Float64(U * t)) ^ 0.5;
	end
	return tmp
end
l_m = abs(l);
function tmp_2 = code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0;
	if (Om <= -1.85e-29)
		tmp = sqrt((t * (n * (2.0 * U))));
	elseif (Om <= 2.25e-133)
		tmp = (l_m * (n / Om)) * sqrt((U * (2.0 * U_42_)));
	else
		tmp = ((2.0 * n) * (U * t)) ^ 0.5;
	end
	tmp_2 = tmp;
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[Om, -1.85e-29], N[Sqrt[N[(t * N[(n * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[Om, 2.25e-133], N[(N[(l$95$m * N[(n / Om), $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(U * N[(2.0 * U$42$), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[Power[N[(N[(2.0 * n), $MachinePrecision] * N[(U * t), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
\mathbf{if}\;Om \leq -1.85 \cdot 10^{-29}:\\
\;\;\;\;\sqrt{t \cdot \left(n \cdot \left(2 \cdot U\right)\right)}\\

\mathbf{elif}\;Om \leq 2.25 \cdot 10^{-133}:\\
\;\;\;\;\left(l\_m \cdot \frac{n}{Om}\right) \cdot \sqrt{U \cdot \left(2 \cdot U*\right)}\\

\mathbf{else}:\\
\;\;\;\;{\left(\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right)}^{0.5}\\


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if Om < -1.8499999999999999e-29

    1. Initial program 63.3%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified62.0%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around 0 51.4%

      \[\leadsto \sqrt{\color{blue}{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}} \]
    5. Step-by-step derivation
      1. associate-*r*51.4%

        \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
    6. Simplified51.4%

      \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
    7. Taylor expanded in U around 0 51.4%

      \[\leadsto \sqrt{\color{blue}{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}} \]
    8. Step-by-step derivation
      1. associate-*r*51.4%

        \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
      2. associate-*r*57.6%

        \[\leadsto \sqrt{\color{blue}{\left(\left(2 \cdot U\right) \cdot n\right) \cdot t}} \]
    9. Simplified57.6%

      \[\leadsto \sqrt{\color{blue}{\left(\left(2 \cdot U\right) \cdot n\right) \cdot t}} \]

    if -1.8499999999999999e-29 < Om < 2.25000000000000005e-133

    1. Initial program 48.5%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Add Preprocessing
    3. Step-by-step derivation
      1. add-cube-cbrt48.2%

        \[\leadsto \sqrt{\color{blue}{\left(\left(\sqrt[3]{\left(2 \cdot n\right) \cdot U} \cdot \sqrt[3]{\left(2 \cdot n\right) \cdot U}\right) \cdot \sqrt[3]{\left(2 \cdot n\right) \cdot U}\right)} \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
      2. pow348.1%

        \[\leadsto \sqrt{\color{blue}{{\left(\sqrt[3]{\left(2 \cdot n\right) \cdot U}\right)}^{3}} \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
      3. associate-*r*48.1%

        \[\leadsto \sqrt{{\left(\sqrt[3]{\color{blue}{2 \cdot \left(n \cdot U\right)}}\right)}^{3} \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    4. Applied egg-rr48.1%

      \[\leadsto \sqrt{\color{blue}{{\left(\sqrt[3]{2 \cdot \left(n \cdot U\right)}\right)}^{3}} \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    5. Taylor expanded in U* around inf 32.8%

      \[\leadsto \color{blue}{\frac{\ell \cdot n}{Om} \cdot \sqrt{U \cdot \left(U* \cdot {\left(\sqrt[3]{2}\right)}^{3}\right)}} \]
    6. Step-by-step derivation
      1. associate-/l*28.3%

        \[\leadsto \color{blue}{\left(\ell \cdot \frac{n}{Om}\right)} \cdot \sqrt{U \cdot \left(U* \cdot {\left(\sqrt[3]{2}\right)}^{3}\right)} \]
      2. rem-cube-cbrt28.5%

        \[\leadsto \left(\ell \cdot \frac{n}{Om}\right) \cdot \sqrt{U \cdot \left(U* \cdot \color{blue}{2}\right)} \]
    7. Simplified28.5%

      \[\leadsto \color{blue}{\left(\ell \cdot \frac{n}{Om}\right) \cdot \sqrt{U \cdot \left(U* \cdot 2\right)}} \]

    if 2.25000000000000005e-133 < Om

    1. Initial program 42.9%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified48.1%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around 0 35.7%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \color{blue}{\left(U \cdot t\right)}\right)} \]
    5. Step-by-step derivation
      1. pow1/237.5%

        \[\leadsto \color{blue}{{\left(2 \cdot \left(n \cdot \left(U \cdot t\right)\right)\right)}^{0.5}} \]
      2. associate-*r*37.5%

        \[\leadsto {\color{blue}{\left(\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right)}}^{0.5} \]
    6. Applied egg-rr37.5%

      \[\leadsto \color{blue}{{\left(\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right)}^{0.5}} \]
  3. Recombined 3 regimes into one program.
  4. Final simplification42.0%

    \[\leadsto \begin{array}{l} \mathbf{if}\;Om \leq -1.85 \cdot 10^{-29}:\\ \;\;\;\;\sqrt{t \cdot \left(n \cdot \left(2 \cdot U\right)\right)}\\ \mathbf{elif}\;Om \leq 2.25 \cdot 10^{-133}:\\ \;\;\;\;\left(\ell \cdot \frac{n}{Om}\right) \cdot \sqrt{U \cdot \left(2 \cdot U*\right)}\\ \mathbf{else}:\\ \;\;\;\;{\left(\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right)}^{0.5}\\ \end{array} \]
  5. Add Preprocessing

Alternative 11: 48.2% accurate, 1.9× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} \mathbf{if}\;t \leq -2.4 \cdot 10^{+130}:\\ \;\;\;\;{\left(\left(2 \cdot U\right) \cdot \left(n \cdot t\right)\right)}^{0.5}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t - 2 \cdot \left(l\_m \cdot \frac{l\_m}{Om}\right)\right)\right)}\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (if (<= t -2.4e+130)
   (pow (* (* 2.0 U) (* n t)) 0.5)
   (sqrt (* (* 2.0 n) (* U (- t (* 2.0 (* l_m (/ l_m Om)))))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (t <= -2.4e+130) {
		tmp = pow(((2.0 * U) * (n * t)), 0.5);
	} else {
		tmp = sqrt(((2.0 * n) * (U * (t - (2.0 * (l_m * (l_m / Om)))))));
	}
	return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    real(8) :: tmp
    if (t <= (-2.4d+130)) then
        tmp = ((2.0d0 * u) * (n * t)) ** 0.5d0
    else
        tmp = sqrt(((2.0d0 * n) * (u * (t - (2.0d0 * (l_m * (l_m / om)))))))
    end if
    code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (t <= -2.4e+130) {
		tmp = Math.pow(((2.0 * U) * (n * t)), 0.5);
	} else {
		tmp = Math.sqrt(((2.0 * n) * (U * (t - (2.0 * (l_m * (l_m / Om)))))));
	}
	return tmp;
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	tmp = 0
	if t <= -2.4e+130:
		tmp = math.pow(((2.0 * U) * (n * t)), 0.5)
	else:
		tmp = math.sqrt(((2.0 * n) * (U * (t - (2.0 * (l_m * (l_m / Om)))))))
	return tmp
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0
	if (t <= -2.4e+130)
		tmp = Float64(Float64(2.0 * U) * Float64(n * t)) ^ 0.5;
	else
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t - Float64(2.0 * Float64(l_m * Float64(l_m / Om)))))));
	end
	return tmp
end
l_m = abs(l);
function tmp_2 = code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0;
	if (t <= -2.4e+130)
		tmp = ((2.0 * U) * (n * t)) ^ 0.5;
	else
		tmp = sqrt(((2.0 * n) * (U * (t - (2.0 * (l_m * (l_m / Om)))))));
	end
	tmp_2 = tmp;
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[t, -2.4e+130], N[Power[N[(N[(2.0 * U), $MachinePrecision] * N[(n * t), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t - N[(2.0 * N[(l$95$m * N[(l$95$m / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.4 \cdot 10^{+130}:\\
\;\;\;\;{\left(\left(2 \cdot U\right) \cdot \left(n \cdot t\right)\right)}^{0.5}\\

\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t - 2 \cdot \left(l\_m \cdot \frac{l\_m}{Om}\right)\right)\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -2.40000000000000024e130

    1. Initial program 45.7%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified37.9%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around 0 51.3%

      \[\leadsto \sqrt{\color{blue}{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}} \]
    5. Step-by-step derivation
      1. associate-*r*51.3%

        \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
    6. Simplified51.3%

      \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
    7. Step-by-step derivation
      1. pow1/255.7%

        \[\leadsto \color{blue}{{\left(\left(2 \cdot U\right) \cdot \left(n \cdot t\right)\right)}^{0.5}} \]
    8. Applied egg-rr55.7%

      \[\leadsto \color{blue}{{\left(\left(2 \cdot U\right) \cdot \left(n \cdot t\right)\right)}^{0.5}} \]

    if -2.40000000000000024e130 < t

    1. Initial program 52.1%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified54.4%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t - \mathsf{fma}\left(2, \ell \cdot \frac{\ell}{Om}, n \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U - U*\right)\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in Om around inf 45.2%

      \[\leadsto \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t - \color{blue}{2 \cdot \frac{{\ell}^{2}}{Om}}\right)\right)} \]
    5. Step-by-step derivation
      1. pow245.2%

        \[\leadsto \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t - 2 \cdot \frac{\color{blue}{\ell \cdot \ell}}{Om}\right)\right)} \]
      2. associate-/l*47.5%

        \[\leadsto \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t - 2 \cdot \color{blue}{\left(\ell \cdot \frac{\ell}{Om}\right)}\right)\right)} \]
    6. Applied egg-rr47.5%

      \[\leadsto \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t - 2 \cdot \color{blue}{\left(\ell \cdot \frac{\ell}{Om}\right)}\right)\right)} \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 12: 37.1% accurate, 2.0× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} \mathbf{if}\;Om \leq -1.7 \cdot 10^{-296}:\\ \;\;\;\;\sqrt{t \cdot \left(n \cdot \left(2 \cdot U\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;{\left(\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right)}^{0.5}\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (if (<= Om -1.7e-296)
   (sqrt (* t (* n (* 2.0 U))))
   (pow (* (* 2.0 n) (* U t)) 0.5)))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (Om <= -1.7e-296) {
		tmp = sqrt((t * (n * (2.0 * U))));
	} else {
		tmp = pow(((2.0 * n) * (U * t)), 0.5);
	}
	return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    real(8) :: tmp
    if (om <= (-1.7d-296)) then
        tmp = sqrt((t * (n * (2.0d0 * u))))
    else
        tmp = ((2.0d0 * n) * (u * t)) ** 0.5d0
    end if
    code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (Om <= -1.7e-296) {
		tmp = Math.sqrt((t * (n * (2.0 * U))));
	} else {
		tmp = Math.pow(((2.0 * n) * (U * t)), 0.5);
	}
	return tmp;
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	tmp = 0
	if Om <= -1.7e-296:
		tmp = math.sqrt((t * (n * (2.0 * U))))
	else:
		tmp = math.pow(((2.0 * n) * (U * t)), 0.5)
	return tmp
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0
	if (Om <= -1.7e-296)
		tmp = sqrt(Float64(t * Float64(n * Float64(2.0 * U))));
	else
		tmp = Float64(Float64(2.0 * n) * Float64(U * t)) ^ 0.5;
	end
	return tmp
end
l_m = abs(l);
function tmp_2 = code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0;
	if (Om <= -1.7e-296)
		tmp = sqrt((t * (n * (2.0 * U))));
	else
		tmp = ((2.0 * n) * (U * t)) ^ 0.5;
	end
	tmp_2 = tmp;
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[Om, -1.7e-296], N[Sqrt[N[(t * N[(n * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Power[N[(N[(2.0 * n), $MachinePrecision] * N[(U * t), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
\mathbf{if}\;Om \leq -1.7 \cdot 10^{-296}:\\
\;\;\;\;\sqrt{t \cdot \left(n \cdot \left(2 \cdot U\right)\right)}\\

\mathbf{else}:\\
\;\;\;\;{\left(\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right)}^{0.5}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if Om < -1.69999999999999998e-296

    1. Initial program 57.6%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified55.2%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around 0 40.3%

      \[\leadsto \sqrt{\color{blue}{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}} \]
    5. Step-by-step derivation
      1. associate-*r*40.3%

        \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
    6. Simplified40.3%

      \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
    7. Taylor expanded in U around 0 40.3%

      \[\leadsto \sqrt{\color{blue}{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}} \]
    8. Step-by-step derivation
      1. associate-*r*40.3%

        \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
      2. associate-*r*46.0%

        \[\leadsto \sqrt{\color{blue}{\left(\left(2 \cdot U\right) \cdot n\right) \cdot t}} \]
    9. Simplified46.0%

      \[\leadsto \sqrt{\color{blue}{\left(\left(2 \cdot U\right) \cdot n\right) \cdot t}} \]

    if -1.69999999999999998e-296 < Om

    1. Initial program 44.6%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified47.9%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around 0 32.7%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \color{blue}{\left(U \cdot t\right)}\right)} \]
    5. Step-by-step derivation
      1. pow1/235.9%

        \[\leadsto \color{blue}{{\left(2 \cdot \left(n \cdot \left(U \cdot t\right)\right)\right)}^{0.5}} \]
      2. associate-*r*35.9%

        \[\leadsto {\color{blue}{\left(\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right)}}^{0.5} \]
    6. Applied egg-rr35.9%

      \[\leadsto \color{blue}{{\left(\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right)}^{0.5}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification40.9%

    \[\leadsto \begin{array}{l} \mathbf{if}\;Om \leq -1.7 \cdot 10^{-296}:\\ \;\;\;\;\sqrt{t \cdot \left(n \cdot \left(2 \cdot U\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;{\left(\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right)}^{0.5}\\ \end{array} \]
  5. Add Preprocessing

Alternative 13: 38.0% accurate, 2.0× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} \mathbf{if}\;t \leq -1.35 \cdot 10^{+102}:\\ \;\;\;\;{\left(\left(2 \cdot U\right) \cdot \left(n \cdot t\right)\right)}^{0.5}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (if (<= t -1.35e+102)
   (pow (* (* 2.0 U) (* n t)) 0.5)
   (sqrt (* t (* 2.0 (* n U))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (t <= -1.35e+102) {
		tmp = pow(((2.0 * U) * (n * t)), 0.5);
	} else {
		tmp = sqrt((t * (2.0 * (n * U))));
	}
	return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    real(8) :: tmp
    if (t <= (-1.35d+102)) then
        tmp = ((2.0d0 * u) * (n * t)) ** 0.5d0
    else
        tmp = sqrt((t * (2.0d0 * (n * u))))
    end if
    code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (t <= -1.35e+102) {
		tmp = Math.pow(((2.0 * U) * (n * t)), 0.5);
	} else {
		tmp = Math.sqrt((t * (2.0 * (n * U))));
	}
	return tmp;
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	tmp = 0
	if t <= -1.35e+102:
		tmp = math.pow(((2.0 * U) * (n * t)), 0.5)
	else:
		tmp = math.sqrt((t * (2.0 * (n * U))))
	return tmp
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0
	if (t <= -1.35e+102)
		tmp = Float64(Float64(2.0 * U) * Float64(n * t)) ^ 0.5;
	else
		tmp = sqrt(Float64(t * Float64(2.0 * Float64(n * U))));
	end
	return tmp
end
l_m = abs(l);
function tmp_2 = code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0;
	if (t <= -1.35e+102)
		tmp = ((2.0 * U) * (n * t)) ^ 0.5;
	else
		tmp = sqrt((t * (2.0 * (n * U))));
	end
	tmp_2 = tmp;
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[t, -1.35e+102], N[Power[N[(N[(2.0 * U), $MachinePrecision] * N[(n * t), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], N[Sqrt[N[(t * N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
\mathbf{if}\;t \leq -1.35 \cdot 10^{+102}:\\
\;\;\;\;{\left(\left(2 \cdot U\right) \cdot \left(n \cdot t\right)\right)}^{0.5}\\

\mathbf{else}:\\
\;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -1.3500000000000001e102

    1. Initial program 46.9%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified39.2%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around 0 50.2%

      \[\leadsto \sqrt{\color{blue}{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}} \]
    5. Step-by-step derivation
      1. associate-*r*50.2%

        \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
    6. Simplified50.2%

      \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
    7. Step-by-step derivation
      1. pow1/256.7%

        \[\leadsto \color{blue}{{\left(\left(2 \cdot U\right) \cdot \left(n \cdot t\right)\right)}^{0.5}} \]
    8. Applied egg-rr56.7%

      \[\leadsto \color{blue}{{\left(\left(2 \cdot U\right) \cdot \left(n \cdot t\right)\right)}^{0.5}} \]

    if -1.3500000000000001e102 < t

    1. Initial program 51.9%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified55.0%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t - \left(2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in t around inf 36.6%

      \[\leadsto \sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \color{blue}{t}} \]
  3. Recombined 2 regimes into one program.
  4. Final simplification40.2%

    \[\leadsto \begin{array}{l} \mathbf{if}\;t \leq -1.35 \cdot 10^{+102}:\\ \;\;\;\;{\left(\left(2 \cdot U\right) \cdot \left(n \cdot t\right)\right)}^{0.5}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}\\ \end{array} \]
  5. Add Preprocessing

Alternative 14: 36.2% accurate, 2.0× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \begin{array}{l} \mathbf{if}\;t \leq -4.5 \cdot 10^{+127}:\\ \;\;\;\;\sqrt{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right)}\\ \end{array} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
 :precision binary64
 (if (<= t -4.5e+127)
   (sqrt (* (* 2.0 U) (* n t)))
   (sqrt (* 2.0 (* n (* U t))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (t <= -4.5e+127) {
		tmp = sqrt(((2.0 * U) * (n * t)));
	} else {
		tmp = sqrt((2.0 * (n * (U * t))));
	}
	return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    real(8) :: tmp
    if (t <= (-4.5d+127)) then
        tmp = sqrt(((2.0d0 * u) * (n * t)))
    else
        tmp = sqrt((2.0d0 * (n * (u * t))))
    end if
    code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	double tmp;
	if (t <= -4.5e+127) {
		tmp = Math.sqrt(((2.0 * U) * (n * t)));
	} else {
		tmp = Math.sqrt((2.0 * (n * (U * t))));
	}
	return tmp;
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	tmp = 0
	if t <= -4.5e+127:
		tmp = math.sqrt(((2.0 * U) * (n * t)))
	else:
		tmp = math.sqrt((2.0 * (n * (U * t))))
	return tmp
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0
	if (t <= -4.5e+127)
		tmp = sqrt(Float64(Float64(2.0 * U) * Float64(n * t)));
	else
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * t))));
	end
	return tmp
end
l_m = abs(l);
function tmp_2 = code(n, U, t, l_m, Om, U_42_)
	tmp = 0.0;
	if (t <= -4.5e+127)
		tmp = sqrt(((2.0 * U) * (n * t)));
	else
		tmp = sqrt((2.0 * (n * (U * t))));
	end
	tmp_2 = tmp;
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[t, -4.5e+127], N[Sqrt[N[(N[(2.0 * U), $MachinePrecision] * N[(n * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.5 \cdot 10^{+127}:\\
\;\;\;\;\sqrt{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}\\

\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right)}\\


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < -4.50000000000000034e127

    1. Initial program 45.7%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified37.9%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around 0 51.3%

      \[\leadsto \sqrt{\color{blue}{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}} \]
    5. Step-by-step derivation
      1. associate-*r*51.3%

        \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
    6. Simplified51.3%

      \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]

    if -4.50000000000000034e127 < t

    1. Initial program 52.1%

      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
    2. Simplified54.4%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
    3. Add Preprocessing
    4. Taylor expanded in l around 0 35.6%

      \[\leadsto \sqrt{2 \cdot \left(n \cdot \color{blue}{\left(U \cdot t\right)}\right)} \]
  3. Recombined 2 regimes into one program.
  4. Add Preprocessing

Alternative 15: 36.7% accurate, 2.1× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \sqrt{t \cdot \left(n \cdot \left(2 \cdot U\right)\right)} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*) :precision binary64 (sqrt (* t (* n (* 2.0 U)))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	return sqrt((t * (n * (2.0 * U))));
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    code = sqrt((t * (n * (2.0d0 * u))))
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	return Math.sqrt((t * (n * (2.0 * U))));
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	return math.sqrt((t * (n * (2.0 * U))))
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	return sqrt(Float64(t * Float64(n * Float64(2.0 * U))))
end
l_m = abs(l);
function tmp = code(n, U, t, l_m, Om, U_42_)
	tmp = sqrt((t * (n * (2.0 * U))));
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := N[Sqrt[N[(t * N[(n * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\sqrt{t \cdot \left(n \cdot \left(2 \cdot U\right)\right)}
\end{array}
Derivation
  1. Initial program 51.0%

    \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
  2. Simplified51.5%

    \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
  3. Add Preprocessing
  4. Taylor expanded in l around 0 35.6%

    \[\leadsto \sqrt{\color{blue}{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}} \]
  5. Step-by-step derivation
    1. associate-*r*35.6%

      \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
  6. Simplified35.6%

    \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
  7. Taylor expanded in U around 0 35.6%

    \[\leadsto \sqrt{\color{blue}{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}} \]
  8. Step-by-step derivation
    1. associate-*r*35.6%

      \[\leadsto \sqrt{\color{blue}{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}} \]
    2. associate-*r*38.5%

      \[\leadsto \sqrt{\color{blue}{\left(\left(2 \cdot U\right) \cdot n\right) \cdot t}} \]
  9. Simplified38.5%

    \[\leadsto \sqrt{\color{blue}{\left(\left(2 \cdot U\right) \cdot n\right) \cdot t}} \]
  10. Final simplification38.5%

    \[\leadsto \sqrt{t \cdot \left(n \cdot \left(2 \cdot U\right)\right)} \]
  11. Add Preprocessing

Alternative 16: 36.7% accurate, 2.1× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*) :precision binary64 (sqrt (* t (* 2.0 (* n U)))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	return sqrt((t * (2.0 * (n * U))));
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    code = sqrt((t * (2.0d0 * (n * u))))
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	return Math.sqrt((t * (2.0 * (n * U))));
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	return math.sqrt((t * (2.0 * (n * U))))
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	return sqrt(Float64(t * Float64(2.0 * Float64(n * U))))
end
l_m = abs(l);
function tmp = code(n, U, t, l_m, Om, U_42_)
	tmp = sqrt((t * (2.0 * (n * U))));
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := N[Sqrt[N[(t * N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)}
\end{array}
Derivation
  1. Initial program 51.0%

    \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
  2. Simplified53.9%

    \[\leadsto \color{blue}{\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t - \left(2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right)}} \]
  3. Add Preprocessing
  4. Taylor expanded in t around inf 38.5%

    \[\leadsto \sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \color{blue}{t}} \]
  5. Final simplification38.5%

    \[\leadsto \sqrt{t \cdot \left(2 \cdot \left(n \cdot U\right)\right)} \]
  6. Add Preprocessing

Alternative 17: 35.7% accurate, 2.1× speedup?

\[\begin{array}{l} l_m = \left|\ell\right| \\ \sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right)} \end{array} \]
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*) :precision binary64 (sqrt (* 2.0 (* n (* U t)))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	return sqrt((2.0 * (n * (U * t))));
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
    real(8), intent (in) :: n
    real(8), intent (in) :: u
    real(8), intent (in) :: t
    real(8), intent (in) :: l_m
    real(8), intent (in) :: om
    real(8), intent (in) :: u_42
    code = sqrt((2.0d0 * (n * (u * t))))
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
	return Math.sqrt((2.0 * (n * (U * t))));
}
l_m = math.fabs(l)
def code(n, U, t, l_m, Om, U_42_):
	return math.sqrt((2.0 * (n * (U * t))))
l_m = abs(l)
function code(n, U, t, l_m, Om, U_42_)
	return sqrt(Float64(2.0 * Float64(n * Float64(U * t))))
end
l_m = abs(l);
function tmp = code(n, U, t, l_m, Om, U_42_)
	tmp = sqrt((2.0 * (n * (U * t))));
end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := N[Sqrt[N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
l_m = \left|\ell\right|

\\
\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right)}
\end{array}
Derivation
  1. Initial program 51.0%

    \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
  2. Simplified51.5%

    \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \mathsf{fma}\left(n, {\left(\frac{\ell}{Om}\right)}^{2} \cdot \left(U* - U\right), \mathsf{fma}\left(\ell \cdot \frac{\ell}{Om}, -2, t\right)\right)\right)\right)}} \]
  3. Add Preprocessing
  4. Taylor expanded in l around 0 36.1%

    \[\leadsto \sqrt{2 \cdot \left(n \cdot \color{blue}{\left(U \cdot t\right)}\right)} \]
  5. Add Preprocessing

Reproduce

?
herbie shell --seed 2024130 
(FPCore (n U t l Om U*)
  :name "Toniolo and Linder, Equation (13)"
  :precision binary64
  (sqrt (* (* (* 2.0 n) U) (- (- t (* 2.0 (/ (* l l) Om))) (* (* n (pow (/ l Om) 2.0)) (- U U*))))))