Toniolo and Linder, Equation (13)

Percentage Accurate: 49.7% → 65.8%
Time: 25.9s
Alternatives: 17
Speedup: 1.8×

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: 49.7% 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: 65.8% accurate, 0.5× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} t_1 := \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)\\ \mathbf{if}\;t_1 \leq 0:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t\right)}\\ \mathbf{elif}\;t_1 \leq 2 \cdot 10^{+293}:\\ \;\;\;\;\sqrt{t_1}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2} \cdot \left(\ell \cdot \sqrt{n \cdot \left(U \cdot \left(\left(U* - U\right) \cdot \frac{\frac{n}{Om}}{Om} - \frac{2}{Om}\right)\right)}\right)\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (let* ((t_1
         (*
          (* (* 2.0 n) U)
          (+
           (- t (* 2.0 (/ (* l l) Om)))
           (* (* n (pow (/ l Om) 2.0)) (- U* U))))))
   (if (<= t_1 0.0)
     (sqrt (* (* 2.0 n) (* U t)))
     (if (<= t_1 2e+293)
       (sqrt t_1)
       (*
        (sqrt 2.0)
        (*
         l
         (sqrt (* n (* U (- (* (- U* U) (/ (/ n Om) Om)) (/ 2.0 Om)))))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double t_1 = ((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) + ((n * pow((l / Om), 2.0)) * (U_42_ - U)));
	double tmp;
	if (t_1 <= 0.0) {
		tmp = sqrt(((2.0 * n) * (U * t)));
	} else if (t_1 <= 2e+293) {
		tmp = sqrt(t_1);
	} else {
		tmp = sqrt(2.0) * (l * sqrt((n * (U * (((U_42_ - U) * ((n / Om) / Om)) - (2.0 / Om))))));
	}
	return tmp;
}
NOTE: l should be positive before calling this function
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
    real(8) :: t_1
    real(8) :: tmp
    t_1 = ((2.0d0 * n) * u) * ((t - (2.0d0 * ((l * l) / om))) + ((n * ((l / om) ** 2.0d0)) * (u_42 - u)))
    if (t_1 <= 0.0d0) then
        tmp = sqrt(((2.0d0 * n) * (u * t)))
    else if (t_1 <= 2d+293) then
        tmp = sqrt(t_1)
    else
        tmp = sqrt(2.0d0) * (l * sqrt((n * (u * (((u_42 - u) * ((n / om) / om)) - (2.0d0 / om))))))
    end if
    code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	double t_1 = ((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) + ((n * Math.pow((l / Om), 2.0)) * (U_42_ - U)));
	double tmp;
	if (t_1 <= 0.0) {
		tmp = Math.sqrt(((2.0 * n) * (U * t)));
	} else if (t_1 <= 2e+293) {
		tmp = Math.sqrt(t_1);
	} else {
		tmp = Math.sqrt(2.0) * (l * Math.sqrt((n * (U * (((U_42_ - U) * ((n / Om) / Om)) - (2.0 / Om))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	t_1 = ((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) + ((n * math.pow((l / Om), 2.0)) * (U_42_ - U)))
	tmp = 0
	if t_1 <= 0.0:
		tmp = math.sqrt(((2.0 * n) * (U * t)))
	elif t_1 <= 2e+293:
		tmp = math.sqrt(t_1)
	else:
		tmp = math.sqrt(2.0) * (l * math.sqrt((n * (U * (((U_42_ - U) * ((n / Om) / Om)) - (2.0 / Om))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	t_1 = 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_42_ - U))))
	tmp = 0.0
	if (t_1 <= 0.0)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * t)));
	elseif (t_1 <= 2e+293)
		tmp = sqrt(t_1);
	else
		tmp = Float64(sqrt(2.0) * Float64(l * sqrt(Float64(n * Float64(U * Float64(Float64(Float64(U_42_ - U) * Float64(Float64(n / Om) / Om)) - Float64(2.0 / Om)))))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	t_1 = ((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) + ((n * ((l / Om) ^ 2.0)) * (U_42_ - U)));
	tmp = 0.0;
	if (t_1 <= 0.0)
		tmp = sqrt(((2.0 * n) * (U * t)));
	elseif (t_1 <= 2e+293)
		tmp = sqrt(t_1);
	else
		tmp = sqrt(2.0) * (l * sqrt((n * (U * (((U_42_ - U) * ((n / Om) / Om)) - (2.0 / Om))))));
	end
	tmp_2 = tmp;
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = 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$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 0.0], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$1, 2e+293], N[Sqrt[t$95$1], $MachinePrecision], N[(N[Sqrt[2.0], $MachinePrecision] * N[(l * N[Sqrt[N[(n * N[(U * N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(N[(n / Om), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] - N[(2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
t_1 := \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)\\
\mathbf{if}\;t_1 \leq 0:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t\right)}\\

\mathbf{elif}\;t_1 \leq 2 \cdot 10^{+293}:\\
\;\;\;\;\sqrt{t_1}\\

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


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

    1. Initial program 11.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. Simplified35.5%

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

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

    if 0.0 < (*.f64 (*.f64 (*.f64 2 n) U) (-.f64 (-.f64 t (*.f64 2 (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) 2)) (-.f64 U U*)))) < 1.9999999999999998e293

    1. Initial program 98.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)} \]

    if 1.9999999999999998e293 < (*.f64 (*.f64 (*.f64 2 n) U) (-.f64 (-.f64 t (*.f64 2 (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) 2)) (-.f64 U U*))))

    1. Initial program 10.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. Simplified36.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \sqrt{2} \cdot \left(\ell \cdot \sqrt{n \cdot \left(U \cdot \left(\color{blue}{\left(U* - U\right) \cdot \frac{\frac{n}{Om}}{Om}} - \frac{2}{Om}\right)\right)}\right) \]
  3. Recombined 3 regimes into one program.
  4. Final simplification56.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{\left(2 \cdot n\right) \cdot \left(U \cdot t\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 2 \cdot 10^{+293}:\\ \;\;\;\;\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)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2} \cdot \left(\ell \cdot \sqrt{n \cdot \left(U \cdot \left(\left(U* - U\right) \cdot \frac{\frac{n}{Om}}{Om} - \frac{2}{Om}\right)\right)}\right)\\ \end{array} \]

Alternative 2: 63.1% accurate, 1.0× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 2.75 \cdot 10^{-45}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, n \cdot \left(\frac{\ell}{Om} \cdot \left(U* - U\right)\right)\right)\right)\right)}\\ \mathbf{elif}\;\ell \leq 1.5 \cdot 10^{+119}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + \frac{\frac{n}{\frac{Om}{U* - U}} - 2}{\frac{\frac{Om}{U}}{\ell \cdot \ell}}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2} \cdot \left(\ell \cdot \sqrt{n \cdot \left(U \cdot \left(\frac{n}{\frac{Om}{\frac{U*}{Om}}} + \frac{-2}{Om}\right)\right)}\right)\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (if (<= l 2.75e-45)
   (sqrt
    (*
     2.0
     (* (* n U) (+ t (* (/ l Om) (fma l -2.0 (* n (* (/ l Om) (- U* U)))))))))
   (if (<= l 1.5e+119)
     (sqrt
      (*
       (* 2.0 n)
       (+ (* U t) (/ (- (/ n (/ Om (- U* U))) 2.0) (/ (/ Om U) (* l l))))))
     (*
      (sqrt 2.0)
      (* l (sqrt (* n (* U (+ (/ n (/ Om (/ U* Om))) (/ -2.0 Om))))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 2.75e-45) {
		tmp = sqrt((2.0 * ((n * U) * (t + ((l / Om) * fma(l, -2.0, (n * ((l / Om) * (U_42_ - U)))))))));
	} else if (l <= 1.5e+119) {
		tmp = sqrt(((2.0 * n) * ((U * t) + (((n / (Om / (U_42_ - U))) - 2.0) / ((Om / U) / (l * l))))));
	} else {
		tmp = sqrt(2.0) * (l * sqrt((n * (U * ((n / (Om / (U_42_ / Om))) + (-2.0 / Om))))));
	}
	return tmp;
}
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 2.75e-45)
		tmp = sqrt(Float64(2.0 * Float64(Float64(n * U) * Float64(t + Float64(Float64(l / Om) * fma(l, -2.0, Float64(n * Float64(Float64(l / Om) * Float64(U_42_ - U)))))))));
	elseif (l <= 1.5e+119)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(Float64(U * t) + Float64(Float64(Float64(n / Float64(Om / Float64(U_42_ - U))) - 2.0) / Float64(Float64(Om / U) / Float64(l * l))))));
	else
		tmp = Float64(sqrt(2.0) * Float64(l * sqrt(Float64(n * Float64(U * Float64(Float64(n / Float64(Om / Float64(U_42_ / Om))) + Float64(-2.0 / Om)))))));
	end
	return tmp
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 2.75e-45], N[Sqrt[N[(2.0 * N[(N[(n * U), $MachinePrecision] * N[(t + N[(N[(l / Om), $MachinePrecision] * N[(l * -2.0 + N[(n * N[(N[(l / Om), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 1.5e+119], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(N[(U * t), $MachinePrecision] + N[(N[(N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision] / N[(N[(Om / U), $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[2.0], $MachinePrecision] * N[(l * N[Sqrt[N[(n * N[(U * N[(N[(n / N[(Om / N[(U$42$ / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 2.75 \cdot 10^{-45}:\\
\;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, n \cdot \left(\frac{\ell}{Om} \cdot \left(U* - U\right)\right)\right)\right)\right)}\\

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

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


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

    1. Initial program 52.2%

      \[\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. Simplified57.1%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
    3. Step-by-step derivation
      1. *-un-lft-identity57.1%

        \[\leadsto \color{blue}{1 \cdot \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      2. associate-*l*57.0%

        \[\leadsto 1 \cdot \sqrt{\color{blue}{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    4. Applied egg-rr57.0%

      \[\leadsto \color{blue}{1 \cdot \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    5. Step-by-step derivation
      1. *-lft-identity57.0%

        \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
      2. associate-*r*56.6%

        \[\leadsto \sqrt{2 \cdot \color{blue}{\left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      3. +-commutative56.6%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\left(\frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) + t\right)}\right)} \]
      4. *-commutative56.6%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\color{blue}{\mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) \cdot \frac{\ell}{Om}} + t\right)\right)} \]
      5. fma-udef56.6%

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

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

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

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

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

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

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

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

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \mathsf{fma}\left(\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right), \frac{\ell}{Om}, t\right)\right)}} \]
    7. Step-by-step derivation
      1. fma-udef56.6%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\left(\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right) \cdot \frac{\ell}{Om} + t\right)}\right)} \]
      2. associate-*l*60.5%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\mathsf{fma}\left(\ell, -2, \color{blue}{n \cdot \left(\left(U* - U\right) \cdot \frac{\ell}{Om}\right)}\right) \cdot \frac{\ell}{Om} + t\right)\right)} \]
    8. Applied egg-rr60.5%

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

    if 2.75000000000000015e-45 < l < 1.50000000000000001e119

    1. Initial program 45.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. Simplified58.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 1.50000000000000001e119 < l

    1. Initial program 20.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. Simplified49.1%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
    3. Step-by-step derivation
      1. *-un-lft-identity49.1%

        \[\leadsto \color{blue}{1 \cdot \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      2. associate-*l*49.1%

        \[\leadsto 1 \cdot \sqrt{\color{blue}{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    4. Applied egg-rr49.1%

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

        \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
      2. associate-*r*48.9%

        \[\leadsto \sqrt{2 \cdot \color{blue}{\left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      3. +-commutative48.9%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\left(\frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) + t\right)}\right)} \]
      4. *-commutative48.9%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\color{blue}{\mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) \cdot \frac{\ell}{Om}} + t\right)\right)} \]
      5. fma-udef48.9%

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

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

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

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

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

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

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

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\mathsf{fma}\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell, \frac{\ell}{Om}, t\right)}\right)} \]
    6. Simplified48.9%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \mathsf{fma}\left(\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right), \frac{\ell}{Om}, t\right)\right)}} \]
    7. Step-by-step derivation
      1. fma-udef48.9%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\left(\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right) \cdot \frac{\ell}{Om} + t\right)}\right)} \]
      2. associate-*l*48.7%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\mathsf{fma}\left(\ell, -2, \color{blue}{n \cdot \left(\left(U* - U\right) \cdot \frac{\ell}{Om}\right)}\right) \cdot \frac{\ell}{Om} + t\right)\right)} \]
    8. Applied egg-rr48.7%

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

      \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\mathsf{fma}\left(\ell, -2, \color{blue}{\frac{n \cdot \left(\ell \cdot U*\right)}{Om}}\right) \cdot \frac{\ell}{Om} + t\right)\right)} \]
    10. Taylor expanded in l around inf 64.1%

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

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

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

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

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

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

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

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

        \[\leadsto \sqrt{2} \cdot \left(\ell \cdot \sqrt{n \cdot \left(U \cdot \left(\frac{n}{\frac{Om}{\frac{U*}{Om}}} + \left(-\frac{\color{blue}{2}}{Om}\right)\right)\right)}\right) \]
      9. distribute-neg-frac74.5%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 2.75 \cdot 10^{-45}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, n \cdot \left(\frac{\ell}{Om} \cdot \left(U* - U\right)\right)\right)\right)\right)}\\ \mathbf{elif}\;\ell \leq 1.5 \cdot 10^{+119}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + \frac{\frac{n}{\frac{Om}{U* - U}} - 2}{\frac{\frac{Om}{U}}{\ell \cdot \ell}}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2} \cdot \left(\ell \cdot \sqrt{n \cdot \left(U \cdot \left(\frac{n}{\frac{Om}{\frac{U*}{Om}}} + \frac{-2}{Om}\right)\right)}\right)\\ \end{array} \]

Alternative 3: 62.7% accurate, 1.0× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 1200000000:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\right)}{Om}\right)\right)}\\ \mathbf{elif}\;\ell \leq 1.6 \cdot 10^{+119}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + \frac{\frac{n}{\frac{Om}{U* - U}} - 2}{\frac{\frac{Om}{U}}{\ell \cdot \ell}}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2} \cdot \left(\ell \cdot \sqrt{n \cdot \left(U \cdot \left(\frac{n}{\frac{Om}{\frac{U*}{Om}}} + \frac{-2}{Om}\right)\right)}\right)\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (if (<= l 1200000000.0)
   (sqrt
    (*
     (* 2.0 n)
     (* U (+ t (/ (* l (+ (/ (* n (* l U*)) Om) (* l -2.0))) Om)))))
   (if (<= l 1.6e+119)
     (sqrt
      (*
       (* 2.0 n)
       (+ (* U t) (/ (- (/ n (/ Om (- U* U))) 2.0) (/ (/ Om U) (* l l))))))
     (*
      (sqrt 2.0)
      (* l (sqrt (* n (* U (+ (/ n (/ Om (/ U* Om))) (/ -2.0 Om))))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 1200000000.0) {
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * (((n * (l * U_42_)) / Om) + (l * -2.0))) / Om)))));
	} else if (l <= 1.6e+119) {
		tmp = sqrt(((2.0 * n) * ((U * t) + (((n / (Om / (U_42_ - U))) - 2.0) / ((Om / U) / (l * l))))));
	} else {
		tmp = sqrt(2.0) * (l * sqrt((n * (U * ((n / (Om / (U_42_ / Om))) + (-2.0 / Om))))));
	}
	return tmp;
}
NOTE: l should be positive before calling this function
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
    real(8) :: tmp
    if (l <= 1200000000.0d0) then
        tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * (((n * (l * u_42)) / om) + (l * (-2.0d0)))) / om)))))
    else if (l <= 1.6d+119) then
        tmp = sqrt(((2.0d0 * n) * ((u * t) + (((n / (om / (u_42 - u))) - 2.0d0) / ((om / u) / (l * l))))))
    else
        tmp = sqrt(2.0d0) * (l * sqrt((n * (u * ((n / (om / (u_42 / om))) + ((-2.0d0) / om))))))
    end if
    code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 1200000000.0) {
		tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * (((n * (l * U_42_)) / Om) + (l * -2.0))) / Om)))));
	} else if (l <= 1.6e+119) {
		tmp = Math.sqrt(((2.0 * n) * ((U * t) + (((n / (Om / (U_42_ - U))) - 2.0) / ((Om / U) / (l * l))))));
	} else {
		tmp = Math.sqrt(2.0) * (l * Math.sqrt((n * (U * ((n / (Om / (U_42_ / Om))) + (-2.0 / Om))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 1200000000.0:
		tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * (((n * (l * U_42_)) / Om) + (l * -2.0))) / Om)))))
	elif l <= 1.6e+119:
		tmp = math.sqrt(((2.0 * n) * ((U * t) + (((n / (Om / (U_42_ - U))) - 2.0) / ((Om / U) / (l * l))))))
	else:
		tmp = math.sqrt(2.0) * (l * math.sqrt((n * (U * ((n / (Om / (U_42_ / Om))) + (-2.0 / Om))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 1200000000.0)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(Float64(n * Float64(l * U_42_)) / Om) + Float64(l * -2.0))) / Om)))));
	elseif (l <= 1.6e+119)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(Float64(U * t) + Float64(Float64(Float64(n / Float64(Om / Float64(U_42_ - U))) - 2.0) / Float64(Float64(Om / U) / Float64(l * l))))));
	else
		tmp = Float64(sqrt(2.0) * Float64(l * sqrt(Float64(n * Float64(U * Float64(Float64(n / Float64(Om / Float64(U_42_ / Om))) + Float64(-2.0 / Om)))))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	tmp = 0.0;
	if (l <= 1200000000.0)
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * (((n * (l * U_42_)) / Om) + (l * -2.0))) / Om)))));
	elseif (l <= 1.6e+119)
		tmp = sqrt(((2.0 * n) * ((U * t) + (((n / (Om / (U_42_ - U))) - 2.0) / ((Om / U) / (l * l))))));
	else
		tmp = sqrt(2.0) * (l * sqrt((n * (U * ((n / (Om / (U_42_ / Om))) + (-2.0 / Om))))));
	end
	tmp_2 = tmp;
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 1200000000.0], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision] + N[(l * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 1.6e+119], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(N[(U * t), $MachinePrecision] + N[(N[(N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision] / N[(N[(Om / U), $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[2.0], $MachinePrecision] * N[(l * N[Sqrt[N[(n * N[(U * N[(N[(n / N[(Om / N[(U$42$ / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 1200000000:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\right)}{Om}\right)\right)}\\

\mathbf{elif}\;\ell \leq 1.6 \cdot 10^{+119}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + \frac{\frac{n}{\frac{Om}{U* - U}} - 2}{\frac{\frac{Om}{U}}{\ell \cdot \ell}}\right)}\\

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


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

    1. Initial program 51.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. Simplified57.4%

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

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

    if 1.2e9 < l < 1.59999999999999995e119

    1. Initial program 48.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.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 1.59999999999999995e119 < l

    1. Initial program 20.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. Simplified49.1%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
    3. Step-by-step derivation
      1. *-un-lft-identity49.1%

        \[\leadsto \color{blue}{1 \cdot \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      2. associate-*l*49.1%

        \[\leadsto 1 \cdot \sqrt{\color{blue}{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    4. Applied egg-rr49.1%

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

        \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
      2. associate-*r*48.9%

        \[\leadsto \sqrt{2 \cdot \color{blue}{\left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      3. +-commutative48.9%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\left(\frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) + t\right)}\right)} \]
      4. *-commutative48.9%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\color{blue}{\mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) \cdot \frac{\ell}{Om}} + t\right)\right)} \]
      5. fma-udef48.9%

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

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

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

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

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

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

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

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\mathsf{fma}\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell, \frac{\ell}{Om}, t\right)}\right)} \]
    6. Simplified48.9%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \mathsf{fma}\left(\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right), \frac{\ell}{Om}, t\right)\right)}} \]
    7. Step-by-step derivation
      1. fma-udef48.9%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\left(\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right) \cdot \frac{\ell}{Om} + t\right)}\right)} \]
      2. associate-*l*48.7%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\mathsf{fma}\left(\ell, -2, \color{blue}{n \cdot \left(\left(U* - U\right) \cdot \frac{\ell}{Om}\right)}\right) \cdot \frac{\ell}{Om} + t\right)\right)} \]
    8. Applied egg-rr48.7%

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

      \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\mathsf{fma}\left(\ell, -2, \color{blue}{\frac{n \cdot \left(\ell \cdot U*\right)}{Om}}\right) \cdot \frac{\ell}{Om} + t\right)\right)} \]
    10. Taylor expanded in l around inf 64.1%

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

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

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

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

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

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

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

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

        \[\leadsto \sqrt{2} \cdot \left(\ell \cdot \sqrt{n \cdot \left(U \cdot \left(\frac{n}{\frac{Om}{\frac{U*}{Om}}} + \left(-\frac{\color{blue}{2}}{Om}\right)\right)\right)}\right) \]
      9. distribute-neg-frac74.5%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 1200000000:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\right)}{Om}\right)\right)}\\ \mathbf{elif}\;\ell \leq 1.6 \cdot 10^{+119}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + \frac{\frac{n}{\frac{Om}{U* - U}} - 2}{\frac{\frac{Om}{U}}{\ell \cdot \ell}}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2} \cdot \left(\ell \cdot \sqrt{n \cdot \left(U \cdot \left(\frac{n}{\frac{Om}{\frac{U*}{Om}}} + \frac{-2}{Om}\right)\right)}\right)\\ \end{array} \]

Alternative 4: 62.4% accurate, 1.0× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 1.9 \cdot 10^{-106}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)\right)\right)}\\ \mathbf{elif}\;\ell \leq 9 \cdot 10^{+118}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + \frac{\frac{n}{\frac{Om}{U* - U}} - 2}{\frac{\frac{Om}{U}}{\ell \cdot \ell}}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2} \cdot \left(\ell \cdot \sqrt{n \cdot \left(U \cdot \left(\frac{n}{\frac{Om}{\frac{U*}{Om}}} + \frac{-2}{Om}\right)\right)}\right)\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (if (<= l 1.9e-106)
   (sqrt
    (* 2.0 (* (* n U) (+ t (* (/ l Om) (fma l -2.0 (/ (* n (* l U*)) Om)))))))
   (if (<= l 9e+118)
     (sqrt
      (*
       (* 2.0 n)
       (+ (* U t) (/ (- (/ n (/ Om (- U* U))) 2.0) (/ (/ Om U) (* l l))))))
     (*
      (sqrt 2.0)
      (* l (sqrt (* n (* U (+ (/ n (/ Om (/ U* Om))) (/ -2.0 Om))))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 1.9e-106) {
		tmp = sqrt((2.0 * ((n * U) * (t + ((l / Om) * fma(l, -2.0, ((n * (l * U_42_)) / Om)))))));
	} else if (l <= 9e+118) {
		tmp = sqrt(((2.0 * n) * ((U * t) + (((n / (Om / (U_42_ - U))) - 2.0) / ((Om / U) / (l * l))))));
	} else {
		tmp = sqrt(2.0) * (l * sqrt((n * (U * ((n / (Om / (U_42_ / Om))) + (-2.0 / Om))))));
	}
	return tmp;
}
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 1.9e-106)
		tmp = sqrt(Float64(2.0 * Float64(Float64(n * U) * Float64(t + Float64(Float64(l / Om) * fma(l, -2.0, Float64(Float64(n * Float64(l * U_42_)) / Om)))))));
	elseif (l <= 9e+118)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(Float64(U * t) + Float64(Float64(Float64(n / Float64(Om / Float64(U_42_ - U))) - 2.0) / Float64(Float64(Om / U) / Float64(l * l))))));
	else
		tmp = Float64(sqrt(2.0) * Float64(l * sqrt(Float64(n * Float64(U * Float64(Float64(n / Float64(Om / Float64(U_42_ / Om))) + Float64(-2.0 / Om)))))));
	end
	return tmp
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 1.9e-106], N[Sqrt[N[(2.0 * N[(N[(n * U), $MachinePrecision] * N[(t + N[(N[(l / Om), $MachinePrecision] * N[(l * -2.0 + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 9e+118], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(N[(U * t), $MachinePrecision] + N[(N[(N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision] / N[(N[(Om / U), $MachinePrecision] / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[2.0], $MachinePrecision] * N[(l * N[Sqrt[N[(n * N[(U * N[(N[(n / N[(Om / N[(U$42$ / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 1.9 \cdot 10^{-106}:\\
\;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)\right)\right)}\\

\mathbf{elif}\;\ell \leq 9 \cdot 10^{+118}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + \frac{\frac{n}{\frac{Om}{U* - U}} - 2}{\frac{\frac{Om}{U}}{\ell \cdot \ell}}\right)}\\

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


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

    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. Simplified57.1%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
    3. Step-by-step derivation
      1. *-un-lft-identity57.1%

        \[\leadsto \color{blue}{1 \cdot \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      2. associate-*l*57.1%

        \[\leadsto 1 \cdot \sqrt{\color{blue}{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    4. Applied egg-rr57.1%

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

        \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
      2. associate-*r*56.5%

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

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\left(\frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) + t\right)}\right)} \]
      4. *-commutative56.5%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\color{blue}{\mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) \cdot \frac{\ell}{Om}} + t\right)\right)} \]
      5. fma-udef56.5%

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

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

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

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

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

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

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\color{blue}{\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell\right)} \cdot \frac{\ell}{Om} + t\right)\right)} \]
      12. fma-def55.8%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\mathsf{fma}\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell, \frac{\ell}{Om}, t\right)}\right)} \]
    6. Simplified56.5%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \mathsf{fma}\left(\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right), \frac{\ell}{Om}, t\right)\right)}} \]
    7. Step-by-step derivation
      1. fma-udef56.5%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\left(\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right) \cdot \frac{\ell}{Om} + t\right)}\right)} \]
      2. associate-*l*60.6%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\mathsf{fma}\left(\ell, -2, \color{blue}{n \cdot \left(\left(U* - U\right) \cdot \frac{\ell}{Om}\right)}\right) \cdot \frac{\ell}{Om} + t\right)\right)} \]
    8. Applied egg-rr60.6%

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

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

    if 1.9e-106 < l < 9.00000000000000004e118

    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. Simplified57.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 9.00000000000000004e118 < l

    1. Initial program 20.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. Simplified49.1%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
    3. Step-by-step derivation
      1. *-un-lft-identity49.1%

        \[\leadsto \color{blue}{1 \cdot \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      2. associate-*l*49.1%

        \[\leadsto 1 \cdot \sqrt{\color{blue}{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    4. Applied egg-rr49.1%

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

        \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
      2. associate-*r*48.9%

        \[\leadsto \sqrt{2 \cdot \color{blue}{\left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      3. +-commutative48.9%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\left(\frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) + t\right)}\right)} \]
      4. *-commutative48.9%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\color{blue}{\mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) \cdot \frac{\ell}{Om}} + t\right)\right)} \]
      5. fma-udef48.9%

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

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

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

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

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

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

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

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\mathsf{fma}\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell, \frac{\ell}{Om}, t\right)}\right)} \]
    6. Simplified48.9%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \mathsf{fma}\left(\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right), \frac{\ell}{Om}, t\right)\right)}} \]
    7. Step-by-step derivation
      1. fma-udef48.9%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\left(\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right) \cdot \frac{\ell}{Om} + t\right)}\right)} \]
      2. associate-*l*48.7%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\mathsf{fma}\left(\ell, -2, \color{blue}{n \cdot \left(\left(U* - U\right) \cdot \frac{\ell}{Om}\right)}\right) \cdot \frac{\ell}{Om} + t\right)\right)} \]
    8. Applied egg-rr48.7%

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

      \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\mathsf{fma}\left(\ell, -2, \color{blue}{\frac{n \cdot \left(\ell \cdot U*\right)}{Om}}\right) \cdot \frac{\ell}{Om} + t\right)\right)} \]
    10. Taylor expanded in l around inf 64.1%

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

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

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

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

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

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

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

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

        \[\leadsto \sqrt{2} \cdot \left(\ell \cdot \sqrt{n \cdot \left(U \cdot \left(\frac{n}{\frac{Om}{\frac{U*}{Om}}} + \left(-\frac{\color{blue}{2}}{Om}\right)\right)\right)}\right) \]
      9. distribute-neg-frac74.5%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 1.9 \cdot 10^{-106}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)\right)\right)}\\ \mathbf{elif}\;\ell \leq 9 \cdot 10^{+118}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + \frac{\frac{n}{\frac{Om}{U* - U}} - 2}{\frac{\frac{Om}{U}}{\ell \cdot \ell}}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2} \cdot \left(\ell \cdot \sqrt{n \cdot \left(U \cdot \left(\frac{n}{\frac{Om}{\frac{U*}{Om}}} + \frac{-2}{Om}\right)\right)}\right)\\ \end{array} \]

Alternative 5: 57.0% accurate, 1.7× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} t_1 := \frac{\ell}{\frac{Om}{\ell}}\\ \mathbf{if}\;Om \leq -1.4 \cdot 10^{+159}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot t_1\right)\right)\right)}\\ \mathbf{elif}\;Om \leq -1.42 \cdot 10^{-306}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right) - 2 \cdot \frac{\left(n \cdot \left(U \cdot \ell\right)\right) \cdot \left(\frac{n \cdot \left(\ell \cdot \left(U - U*\right)\right)}{Om} - \ell \cdot -2\right)}{Om}}\\ \mathbf{elif}\;Om \leq 1.65 \cdot 10^{-96}:\\ \;\;\;\;\sqrt{\frac{2 \cdot n}{\frac{Om}{\ell \cdot \left(U \cdot \left(\frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\right)\right)}}}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + t_1 \cdot \left(\frac{n}{\frac{Om}{U*}} - 2\right)\right)\right)}\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (let* ((t_1 (/ l (/ Om l))))
   (if (<= Om -1.4e+159)
     (sqrt (* 2.0 (* n (* U (- t (* 2.0 t_1))))))
     (if (<= Om -1.42e-306)
       (sqrt
        (-
         (* 2.0 (* n (* U t)))
         (*
          2.0
          (/
           (* (* n (* U l)) (- (/ (* n (* l (- U U*))) Om) (* l -2.0)))
           Om))))
       (if (<= Om 1.65e-96)
         (sqrt
          (/
           (* 2.0 n)
           (/ Om (* l (* U (+ (/ (* n (* l U*)) Om) (* l -2.0)))))))
         (sqrt (* 2.0 (* (* n U) (+ t (* t_1 (- (/ n (/ Om U*)) 2.0)))))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double t_1 = l / (Om / l);
	double tmp;
	if (Om <= -1.4e+159) {
		tmp = sqrt((2.0 * (n * (U * (t - (2.0 * t_1))))));
	} else if (Om <= -1.42e-306) {
		tmp = sqrt(((2.0 * (n * (U * t))) - (2.0 * (((n * (U * l)) * (((n * (l * (U - U_42_))) / Om) - (l * -2.0))) / Om))));
	} else if (Om <= 1.65e-96) {
		tmp = sqrt(((2.0 * n) / (Om / (l * (U * (((n * (l * U_42_)) / Om) + (l * -2.0)))))));
	} else {
		tmp = sqrt((2.0 * ((n * U) * (t + (t_1 * ((n / (Om / U_42_)) - 2.0))))));
	}
	return tmp;
}
NOTE: l should be positive before calling this function
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
    real(8) :: t_1
    real(8) :: tmp
    t_1 = l / (om / l)
    if (om <= (-1.4d+159)) then
        tmp = sqrt((2.0d0 * (n * (u * (t - (2.0d0 * t_1))))))
    else if (om <= (-1.42d-306)) then
        tmp = sqrt(((2.0d0 * (n * (u * t))) - (2.0d0 * (((n * (u * l)) * (((n * (l * (u - u_42))) / om) - (l * (-2.0d0)))) / om))))
    else if (om <= 1.65d-96) then
        tmp = sqrt(((2.0d0 * n) / (om / (l * (u * (((n * (l * u_42)) / om) + (l * (-2.0d0))))))))
    else
        tmp = sqrt((2.0d0 * ((n * u) * (t + (t_1 * ((n / (om / u_42)) - 2.0d0))))))
    end if
    code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	double t_1 = l / (Om / l);
	double tmp;
	if (Om <= -1.4e+159) {
		tmp = Math.sqrt((2.0 * (n * (U * (t - (2.0 * t_1))))));
	} else if (Om <= -1.42e-306) {
		tmp = Math.sqrt(((2.0 * (n * (U * t))) - (2.0 * (((n * (U * l)) * (((n * (l * (U - U_42_))) / Om) - (l * -2.0))) / Om))));
	} else if (Om <= 1.65e-96) {
		tmp = Math.sqrt(((2.0 * n) / (Om / (l * (U * (((n * (l * U_42_)) / Om) + (l * -2.0)))))));
	} else {
		tmp = Math.sqrt((2.0 * ((n * U) * (t + (t_1 * ((n / (Om / U_42_)) - 2.0))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	t_1 = l / (Om / l)
	tmp = 0
	if Om <= -1.4e+159:
		tmp = math.sqrt((2.0 * (n * (U * (t - (2.0 * t_1))))))
	elif Om <= -1.42e-306:
		tmp = math.sqrt(((2.0 * (n * (U * t))) - (2.0 * (((n * (U * l)) * (((n * (l * (U - U_42_))) / Om) - (l * -2.0))) / Om))))
	elif Om <= 1.65e-96:
		tmp = math.sqrt(((2.0 * n) / (Om / (l * (U * (((n * (l * U_42_)) / Om) + (l * -2.0)))))))
	else:
		tmp = math.sqrt((2.0 * ((n * U) * (t + (t_1 * ((n / (Om / U_42_)) - 2.0))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	t_1 = Float64(l / Float64(Om / l))
	tmp = 0.0
	if (Om <= -1.4e+159)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t - Float64(2.0 * t_1))))));
	elseif (Om <= -1.42e-306)
		tmp = sqrt(Float64(Float64(2.0 * Float64(n * Float64(U * t))) - Float64(2.0 * Float64(Float64(Float64(n * Float64(U * l)) * Float64(Float64(Float64(n * Float64(l * Float64(U - U_42_))) / Om) - Float64(l * -2.0))) / Om))));
	elseif (Om <= 1.65e-96)
		tmp = sqrt(Float64(Float64(2.0 * n) / Float64(Om / Float64(l * Float64(U * Float64(Float64(Float64(n * Float64(l * U_42_)) / Om) + Float64(l * -2.0)))))));
	else
		tmp = sqrt(Float64(2.0 * Float64(Float64(n * U) * Float64(t + Float64(t_1 * Float64(Float64(n / Float64(Om / U_42_)) - 2.0))))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	t_1 = l / (Om / l);
	tmp = 0.0;
	if (Om <= -1.4e+159)
		tmp = sqrt((2.0 * (n * (U * (t - (2.0 * t_1))))));
	elseif (Om <= -1.42e-306)
		tmp = sqrt(((2.0 * (n * (U * t))) - (2.0 * (((n * (U * l)) * (((n * (l * (U - U_42_))) / Om) - (l * -2.0))) / Om))));
	elseif (Om <= 1.65e-96)
		tmp = sqrt(((2.0 * n) / (Om / (l * (U * (((n * (l * U_42_)) / Om) + (l * -2.0)))))));
	else
		tmp = sqrt((2.0 * ((n * U) * (t + (t_1 * ((n / (Om / U_42_)) - 2.0))))));
	end
	tmp_2 = tmp;
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(l / N[(Om / l), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[Om, -1.4e+159], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t - N[(2.0 * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[Om, -1.42e-306], N[Sqrt[N[(N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(2.0 * N[(N[(N[(n * N[(U * l), $MachinePrecision]), $MachinePrecision] * N[(N[(N[(n * N[(l * N[(U - U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision] - N[(l * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[Om, 1.65e-96], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] / N[(Om / N[(l * N[(U * N[(N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision] + N[(l * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(2.0 * N[(N[(n * U), $MachinePrecision] * N[(t + N[(t$95$1 * N[(N[(n / N[(Om / U$42$), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
t_1 := \frac{\ell}{\frac{Om}{\ell}}\\
\mathbf{if}\;Om \leq -1.4 \cdot 10^{+159}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot t_1\right)\right)\right)}\\

\mathbf{elif}\;Om \leq -1.42 \cdot 10^{-306}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right) - 2 \cdot \frac{\left(n \cdot \left(U \cdot \ell\right)\right) \cdot \left(\frac{n \cdot \left(\ell \cdot \left(U - U*\right)\right)}{Om} - \ell \cdot -2\right)}{Om}}\\

\mathbf{elif}\;Om \leq 1.65 \cdot 10^{-96}:\\
\;\;\;\;\sqrt{\frac{2 \cdot n}{\frac{Om}{\ell \cdot \left(U \cdot \left(\frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\right)\right)}}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if Om < -1.4000000000000001e159

    1. Initial program 51.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. Simplified60.6%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.4000000000000001e159 < Om < -1.42000000000000005e-306

    1. Initial program 38.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. Simplified53.9%

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

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

    if -1.42000000000000005e-306 < Om < 1.64999999999999995e-96

    1. Initial program 34.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. Simplified59.2%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \sqrt{\color{blue}{\frac{2 \cdot n}{\frac{\frac{Om}{\ell \cdot U}}{\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right)}}}} \]
    6. Taylor expanded in U around 0 77.0%

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

    if 1.64999999999999995e-96 < Om

    1. Initial program 55.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. Simplified55.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;Om \leq -1.4 \cdot 10^{+159}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell}{\frac{Om}{\ell}}\right)\right)\right)}\\ \mathbf{elif}\;Om \leq -1.42 \cdot 10^{-306}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right) - 2 \cdot \frac{\left(n \cdot \left(U \cdot \ell\right)\right) \cdot \left(\frac{n \cdot \left(\ell \cdot \left(U - U*\right)\right)}{Om} - \ell \cdot -2\right)}{Om}}\\ \mathbf{elif}\;Om \leq 1.65 \cdot 10^{-96}:\\ \;\;\;\;\sqrt{\frac{2 \cdot n}{\frac{Om}{\ell \cdot \left(U \cdot \left(\frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\right)\right)}}}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{\frac{Om}{\ell}} \cdot \left(\frac{n}{\frac{Om}{U*}} - 2\right)\right)\right)}\\ \end{array} \]

Alternative 6: 54.7% accurate, 1.8× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} t_1 := \frac{\ell}{\frac{Om}{\ell}}\\ \mathbf{if}\;Om \leq -1.56 \cdot 10^{+156}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot t_1\right)\right)\right)}\\ \mathbf{elif}\;Om \leq -8.5 \cdot 10^{-208}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t - \frac{2 + \left(U - U*\right) \cdot \frac{n}{Om}}{\frac{Om}{\ell \cdot \ell}}\right)\right)}\\ \mathbf{elif}\;Om \leq 3 \cdot 10^{-98}:\\ \;\;\;\;\sqrt{\frac{2 \cdot n}{\frac{Om}{\ell \cdot \left(U \cdot \left(\frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\right)\right)}}}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + t_1 \cdot \left(\frac{n}{\frac{Om}{U*}} - 2\right)\right)\right)}\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (let* ((t_1 (/ l (/ Om l))))
   (if (<= Om -1.56e+156)
     (sqrt (* 2.0 (* n (* U (- t (* 2.0 t_1))))))
     (if (<= Om -8.5e-208)
       (sqrt
        (*
         2.0
         (* (* n U) (- t (/ (+ 2.0 (* (- U U*) (/ n Om))) (/ Om (* l l)))))))
       (if (<= Om 3e-98)
         (sqrt
          (/
           (* 2.0 n)
           (/ Om (* l (* U (+ (/ (* n (* l U*)) Om) (* l -2.0)))))))
         (sqrt (* 2.0 (* (* n U) (+ t (* t_1 (- (/ n (/ Om U*)) 2.0)))))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double t_1 = l / (Om / l);
	double tmp;
	if (Om <= -1.56e+156) {
		tmp = sqrt((2.0 * (n * (U * (t - (2.0 * t_1))))));
	} else if (Om <= -8.5e-208) {
		tmp = sqrt((2.0 * ((n * U) * (t - ((2.0 + ((U - U_42_) * (n / Om))) / (Om / (l * l)))))));
	} else if (Om <= 3e-98) {
		tmp = sqrt(((2.0 * n) / (Om / (l * (U * (((n * (l * U_42_)) / Om) + (l * -2.0)))))));
	} else {
		tmp = sqrt((2.0 * ((n * U) * (t + (t_1 * ((n / (Om / U_42_)) - 2.0))))));
	}
	return tmp;
}
NOTE: l should be positive before calling this function
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
    real(8) :: t_1
    real(8) :: tmp
    t_1 = l / (om / l)
    if (om <= (-1.56d+156)) then
        tmp = sqrt((2.0d0 * (n * (u * (t - (2.0d0 * t_1))))))
    else if (om <= (-8.5d-208)) then
        tmp = sqrt((2.0d0 * ((n * u) * (t - ((2.0d0 + ((u - u_42) * (n / om))) / (om / (l * l)))))))
    else if (om <= 3d-98) then
        tmp = sqrt(((2.0d0 * n) / (om / (l * (u * (((n * (l * u_42)) / om) + (l * (-2.0d0))))))))
    else
        tmp = sqrt((2.0d0 * ((n * u) * (t + (t_1 * ((n / (om / u_42)) - 2.0d0))))))
    end if
    code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	double t_1 = l / (Om / l);
	double tmp;
	if (Om <= -1.56e+156) {
		tmp = Math.sqrt((2.0 * (n * (U * (t - (2.0 * t_1))))));
	} else if (Om <= -8.5e-208) {
		tmp = Math.sqrt((2.0 * ((n * U) * (t - ((2.0 + ((U - U_42_) * (n / Om))) / (Om / (l * l)))))));
	} else if (Om <= 3e-98) {
		tmp = Math.sqrt(((2.0 * n) / (Om / (l * (U * (((n * (l * U_42_)) / Om) + (l * -2.0)))))));
	} else {
		tmp = Math.sqrt((2.0 * ((n * U) * (t + (t_1 * ((n / (Om / U_42_)) - 2.0))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	t_1 = l / (Om / l)
	tmp = 0
	if Om <= -1.56e+156:
		tmp = math.sqrt((2.0 * (n * (U * (t - (2.0 * t_1))))))
	elif Om <= -8.5e-208:
		tmp = math.sqrt((2.0 * ((n * U) * (t - ((2.0 + ((U - U_42_) * (n / Om))) / (Om / (l * l)))))))
	elif Om <= 3e-98:
		tmp = math.sqrt(((2.0 * n) / (Om / (l * (U * (((n * (l * U_42_)) / Om) + (l * -2.0)))))))
	else:
		tmp = math.sqrt((2.0 * ((n * U) * (t + (t_1 * ((n / (Om / U_42_)) - 2.0))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	t_1 = Float64(l / Float64(Om / l))
	tmp = 0.0
	if (Om <= -1.56e+156)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t - Float64(2.0 * t_1))))));
	elseif (Om <= -8.5e-208)
		tmp = sqrt(Float64(2.0 * Float64(Float64(n * U) * Float64(t - Float64(Float64(2.0 + Float64(Float64(U - U_42_) * Float64(n / Om))) / Float64(Om / Float64(l * l)))))));
	elseif (Om <= 3e-98)
		tmp = sqrt(Float64(Float64(2.0 * n) / Float64(Om / Float64(l * Float64(U * Float64(Float64(Float64(n * Float64(l * U_42_)) / Om) + Float64(l * -2.0)))))));
	else
		tmp = sqrt(Float64(2.0 * Float64(Float64(n * U) * Float64(t + Float64(t_1 * Float64(Float64(n / Float64(Om / U_42_)) - 2.0))))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	t_1 = l / (Om / l);
	tmp = 0.0;
	if (Om <= -1.56e+156)
		tmp = sqrt((2.0 * (n * (U * (t - (2.0 * t_1))))));
	elseif (Om <= -8.5e-208)
		tmp = sqrt((2.0 * ((n * U) * (t - ((2.0 + ((U - U_42_) * (n / Om))) / (Om / (l * l)))))));
	elseif (Om <= 3e-98)
		tmp = sqrt(((2.0 * n) / (Om / (l * (U * (((n * (l * U_42_)) / Om) + (l * -2.0)))))));
	else
		tmp = sqrt((2.0 * ((n * U) * (t + (t_1 * ((n / (Om / U_42_)) - 2.0))))));
	end
	tmp_2 = tmp;
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(l / N[(Om / l), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[Om, -1.56e+156], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t - N[(2.0 * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[Om, -8.5e-208], N[Sqrt[N[(2.0 * N[(N[(n * U), $MachinePrecision] * N[(t - N[(N[(2.0 + N[(N[(U - U$42$), $MachinePrecision] * N[(n / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(Om / N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[Om, 3e-98], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] / N[(Om / N[(l * N[(U * N[(N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision] + N[(l * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(2.0 * N[(N[(n * U), $MachinePrecision] * N[(t + N[(t$95$1 * N[(N[(n / N[(Om / U$42$), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
t_1 := \frac{\ell}{\frac{Om}{\ell}}\\
\mathbf{if}\;Om \leq -1.56 \cdot 10^{+156}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot t_1\right)\right)\right)}\\

\mathbf{elif}\;Om \leq -8.5 \cdot 10^{-208}:\\
\;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t - \frac{2 + \left(U - U*\right) \cdot \frac{n}{Om}}{\frac{Om}{\ell \cdot \ell}}\right)\right)}\\

\mathbf{elif}\;Om \leq 3 \cdot 10^{-98}:\\
\;\;\;\;\sqrt{\frac{2 \cdot n}{\frac{Om}{\ell \cdot \left(U \cdot \left(\frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\right)\right)}}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if Om < -1.55999999999999992e156

    1. Initial program 50.2%

      \[\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. Simplified61.2%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.55999999999999992e156 < Om < -8.49999999999999997e-208

    1. Initial program 40.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. Simplified50.3%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
    3. Step-by-step derivation
      1. *-un-lft-identity50.3%

        \[\leadsto \color{blue}{1 \cdot \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      2. associate-*l*50.3%

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

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

        \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
      2. associate-*r*51.6%

        \[\leadsto \sqrt{2 \cdot \color{blue}{\left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      3. +-commutative51.6%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\left(\frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) + t\right)}\right)} \]
      4. *-commutative51.6%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\color{blue}{\mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) \cdot \frac{\ell}{Om}} + t\right)\right)} \]
      5. fma-udef51.6%

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

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

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

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

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

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

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\color{blue}{\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell\right)} \cdot \frac{\ell}{Om} + t\right)\right)} \]
      12. fma-def52.7%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\mathsf{fma}\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell, \frac{\ell}{Om}, t\right)}\right)} \]
    6. Simplified51.6%

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

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

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

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

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

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

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

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

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

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

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

    if -8.49999999999999997e-208 < Om < 3e-98

    1. Initial program 32.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. Simplified62.0%

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \sqrt{\frac{2 \cdot n}{\frac{\frac{Om}{\ell \cdot U}}{\ell \cdot -2 + \color{blue}{\frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)}}}} \]
      11. fma-udef52.3%

        \[\leadsto \sqrt{\frac{2 \cdot n}{\frac{\frac{Om}{\ell \cdot U}}{\color{blue}{\mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)}}}} \]
      12. *-commutative52.3%

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

      \[\leadsto \sqrt{\color{blue}{\frac{2 \cdot n}{\frac{\frac{Om}{\ell \cdot U}}{\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right)}}}} \]
    6. Taylor expanded in U around 0 62.4%

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

    if 3e-98 < Om

    1. Initial program 55.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. Simplified55.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;Om \leq -1.56 \cdot 10^{+156}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell}{\frac{Om}{\ell}}\right)\right)\right)}\\ \mathbf{elif}\;Om \leq -8.5 \cdot 10^{-208}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t - \frac{2 + \left(U - U*\right) \cdot \frac{n}{Om}}{\frac{Om}{\ell \cdot \ell}}\right)\right)}\\ \mathbf{elif}\;Om \leq 3 \cdot 10^{-98}:\\ \;\;\;\;\sqrt{\frac{2 \cdot n}{\frac{Om}{\ell \cdot \left(U \cdot \left(\frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\right)\right)}}}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{\frac{Om}{\ell}} \cdot \left(\frac{n}{\frac{Om}{U*}} - 2\right)\right)\right)}\\ \end{array} \]

Alternative 7: 56.7% accurate, 1.8× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} t_1 := \frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\\ t_2 := \frac{\ell}{\frac{Om}{\ell}}\\ \mathbf{if}\;Om \leq -1.9 \cdot 10^{+167}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot t_2\right)\right)\right)}\\ \mathbf{elif}\;Om \leq 3.7 \cdot 10^{-287}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot t_1}{Om}\right)\right)}\\ \mathbf{elif}\;Om \leq 3 \cdot 10^{-98}:\\ \;\;\;\;\sqrt{\frac{2 \cdot n}{\frac{Om}{\ell \cdot \left(U \cdot t_1\right)}}}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + t_2 \cdot \left(\frac{n}{\frac{Om}{U*}} - 2\right)\right)\right)}\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (let* ((t_1 (+ (/ (* n (* l U*)) Om) (* l -2.0))) (t_2 (/ l (/ Om l))))
   (if (<= Om -1.9e+167)
     (sqrt (* 2.0 (* n (* U (- t (* 2.0 t_2))))))
     (if (<= Om 3.7e-287)
       (sqrt (* (* 2.0 n) (* U (+ t (/ (* l t_1) Om)))))
       (if (<= Om 3e-98)
         (sqrt (/ (* 2.0 n) (/ Om (* l (* U t_1)))))
         (sqrt (* 2.0 (* (* n U) (+ t (* t_2 (- (/ n (/ Om U*)) 2.0)))))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double t_1 = ((n * (l * U_42_)) / Om) + (l * -2.0);
	double t_2 = l / (Om / l);
	double tmp;
	if (Om <= -1.9e+167) {
		tmp = sqrt((2.0 * (n * (U * (t - (2.0 * t_2))))));
	} else if (Om <= 3.7e-287) {
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * t_1) / Om)))));
	} else if (Om <= 3e-98) {
		tmp = sqrt(((2.0 * n) / (Om / (l * (U * t_1)))));
	} else {
		tmp = sqrt((2.0 * ((n * U) * (t + (t_2 * ((n / (Om / U_42_)) - 2.0))))));
	}
	return tmp;
}
NOTE: l should be positive before calling this function
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
    real(8) :: t_1
    real(8) :: t_2
    real(8) :: tmp
    t_1 = ((n * (l * u_42)) / om) + (l * (-2.0d0))
    t_2 = l / (om / l)
    if (om <= (-1.9d+167)) then
        tmp = sqrt((2.0d0 * (n * (u * (t - (2.0d0 * t_2))))))
    else if (om <= 3.7d-287) then
        tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * t_1) / om)))))
    else if (om <= 3d-98) then
        tmp = sqrt(((2.0d0 * n) / (om / (l * (u * t_1)))))
    else
        tmp = sqrt((2.0d0 * ((n * u) * (t + (t_2 * ((n / (om / u_42)) - 2.0d0))))))
    end if
    code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	double t_1 = ((n * (l * U_42_)) / Om) + (l * -2.0);
	double t_2 = l / (Om / l);
	double tmp;
	if (Om <= -1.9e+167) {
		tmp = Math.sqrt((2.0 * (n * (U * (t - (2.0 * t_2))))));
	} else if (Om <= 3.7e-287) {
		tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * t_1) / Om)))));
	} else if (Om <= 3e-98) {
		tmp = Math.sqrt(((2.0 * n) / (Om / (l * (U * t_1)))));
	} else {
		tmp = Math.sqrt((2.0 * ((n * U) * (t + (t_2 * ((n / (Om / U_42_)) - 2.0))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	t_1 = ((n * (l * U_42_)) / Om) + (l * -2.0)
	t_2 = l / (Om / l)
	tmp = 0
	if Om <= -1.9e+167:
		tmp = math.sqrt((2.0 * (n * (U * (t - (2.0 * t_2))))))
	elif Om <= 3.7e-287:
		tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * t_1) / Om)))))
	elif Om <= 3e-98:
		tmp = math.sqrt(((2.0 * n) / (Om / (l * (U * t_1)))))
	else:
		tmp = math.sqrt((2.0 * ((n * U) * (t + (t_2 * ((n / (Om / U_42_)) - 2.0))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	t_1 = Float64(Float64(Float64(n * Float64(l * U_42_)) / Om) + Float64(l * -2.0))
	t_2 = Float64(l / Float64(Om / l))
	tmp = 0.0
	if (Om <= -1.9e+167)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t - Float64(2.0 * t_2))))));
	elseif (Om <= 3.7e-287)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * t_1) / Om)))));
	elseif (Om <= 3e-98)
		tmp = sqrt(Float64(Float64(2.0 * n) / Float64(Om / Float64(l * Float64(U * t_1)))));
	else
		tmp = sqrt(Float64(2.0 * Float64(Float64(n * U) * Float64(t + Float64(t_2 * Float64(Float64(n / Float64(Om / U_42_)) - 2.0))))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	t_1 = ((n * (l * U_42_)) / Om) + (l * -2.0);
	t_2 = l / (Om / l);
	tmp = 0.0;
	if (Om <= -1.9e+167)
		tmp = sqrt((2.0 * (n * (U * (t - (2.0 * t_2))))));
	elseif (Om <= 3.7e-287)
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * t_1) / Om)))));
	elseif (Om <= 3e-98)
		tmp = sqrt(((2.0 * n) / (Om / (l * (U * t_1)))));
	else
		tmp = sqrt((2.0 * ((n * U) * (t + (t_2 * ((n / (Om / U_42_)) - 2.0))))));
	end
	tmp_2 = tmp;
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision] + N[(l * -2.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(l / N[(Om / l), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[Om, -1.9e+167], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t - N[(2.0 * t$95$2), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[Om, 3.7e-287], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * t$95$1), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[Om, 3e-98], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] / N[(Om / N[(l * N[(U * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(2.0 * N[(N[(n * U), $MachinePrecision] * N[(t + N[(t$95$2 * N[(N[(n / N[(Om / U$42$), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
t_1 := \frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\\
t_2 := \frac{\ell}{\frac{Om}{\ell}}\\
\mathbf{if}\;Om \leq -1.9 \cdot 10^{+167}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot t_2\right)\right)\right)}\\

\mathbf{elif}\;Om \leq 3.7 \cdot 10^{-287}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot t_1}{Om}\right)\right)}\\

\mathbf{elif}\;Om \leq 3 \cdot 10^{-98}:\\
\;\;\;\;\sqrt{\frac{2 \cdot n}{\frac{Om}{\ell \cdot \left(U \cdot t_1\right)}}}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if Om < -1.89999999999999997e167

    1. Initial program 51.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. Simplified64.4%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.89999999999999997e167 < Om < 3.70000000000000027e-287

    1. Initial program 37.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. Simplified53.3%

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

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

    if 3.70000000000000027e-287 < Om < 3e-98

    1. Initial program 39.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. Simplified58.3%

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \sqrt{\frac{2 \cdot n}{\frac{\frac{Om}{\ell \cdot U}}{\ell \cdot -2 + \color{blue}{\frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)}}}} \]
      11. fma-udef59.1%

        \[\leadsto \sqrt{\frac{2 \cdot n}{\frac{\frac{Om}{\ell \cdot U}}{\color{blue}{\mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)}}}} \]
      12. *-commutative59.1%

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

      \[\leadsto \sqrt{\color{blue}{\frac{2 \cdot n}{\frac{\frac{Om}{\ell \cdot U}}{\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right)}}}} \]
    6. Taylor expanded in U around 0 78.1%

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

    if 3e-98 < Om

    1. Initial program 55.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. Simplified55.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;Om \leq -1.9 \cdot 10^{+167}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell}{\frac{Om}{\ell}}\right)\right)\right)}\\ \mathbf{elif}\;Om \leq 3.7 \cdot 10^{-287}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\right)}{Om}\right)\right)}\\ \mathbf{elif}\;Om \leq 3 \cdot 10^{-98}:\\ \;\;\;\;\sqrt{\frac{2 \cdot n}{\frac{Om}{\ell \cdot \left(U \cdot \left(\frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\right)\right)}}}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{\frac{Om}{\ell}} \cdot \left(\frac{n}{\frac{Om}{U*}} - 2\right)\right)\right)}\\ \end{array} \]

Alternative 8: 54.8% accurate, 1.8× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;Om \leq -1.36 \cdot 10^{-285} \lor \neg \left(Om \leq 1.5 \cdot 10^{-97}\right):\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{\frac{Om}{\ell}} \cdot \left(\frac{n}{\frac{Om}{U*}} - 2\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(\frac{n}{Om} \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)\right) \cdot \left(\frac{n \cdot U*}{Om} - 2\right)\right)}\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (if (or (<= Om -1.36e-285) (not (<= Om 1.5e-97)))
   (sqrt (* 2.0 (* (* n U) (+ t (* (/ l (/ Om l)) (- (/ n (/ Om U*)) 2.0))))))
   (sqrt (* 2.0 (* (* (/ n Om) (* l (* U l))) (- (/ (* n U*) Om) 2.0))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if ((Om <= -1.36e-285) || !(Om <= 1.5e-97)) {
		tmp = sqrt((2.0 * ((n * U) * (t + ((l / (Om / l)) * ((n / (Om / U_42_)) - 2.0))))));
	} else {
		tmp = sqrt((2.0 * (((n / Om) * (l * (U * l))) * (((n * U_42_) / Om) - 2.0))));
	}
	return tmp;
}
NOTE: l should be positive before calling this function
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
    real(8) :: tmp
    if ((om <= (-1.36d-285)) .or. (.not. (om <= 1.5d-97))) then
        tmp = sqrt((2.0d0 * ((n * u) * (t + ((l / (om / l)) * ((n / (om / u_42)) - 2.0d0))))))
    else
        tmp = sqrt((2.0d0 * (((n / om) * (l * (u * l))) * (((n * u_42) / om) - 2.0d0))))
    end if
    code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if ((Om <= -1.36e-285) || !(Om <= 1.5e-97)) {
		tmp = Math.sqrt((2.0 * ((n * U) * (t + ((l / (Om / l)) * ((n / (Om / U_42_)) - 2.0))))));
	} else {
		tmp = Math.sqrt((2.0 * (((n / Om) * (l * (U * l))) * (((n * U_42_) / Om) - 2.0))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if (Om <= -1.36e-285) or not (Om <= 1.5e-97):
		tmp = math.sqrt((2.0 * ((n * U) * (t + ((l / (Om / l)) * ((n / (Om / U_42_)) - 2.0))))))
	else:
		tmp = math.sqrt((2.0 * (((n / Om) * (l * (U * l))) * (((n * U_42_) / Om) - 2.0))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if ((Om <= -1.36e-285) || !(Om <= 1.5e-97))
		tmp = sqrt(Float64(2.0 * Float64(Float64(n * U) * Float64(t + Float64(Float64(l / Float64(Om / l)) * Float64(Float64(n / Float64(Om / U_42_)) - 2.0))))));
	else
		tmp = sqrt(Float64(2.0 * Float64(Float64(Float64(n / Om) * Float64(l * Float64(U * l))) * Float64(Float64(Float64(n * U_42_) / Om) - 2.0))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	tmp = 0.0;
	if ((Om <= -1.36e-285) || ~((Om <= 1.5e-97)))
		tmp = sqrt((2.0 * ((n * U) * (t + ((l / (Om / l)) * ((n / (Om / U_42_)) - 2.0))))));
	else
		tmp = sqrt((2.0 * (((n / Om) * (l * (U * l))) * (((n * U_42_) / Om) - 2.0))));
	end
	tmp_2 = tmp;
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := If[Or[LessEqual[Om, -1.36e-285], N[Not[LessEqual[Om, 1.5e-97]], $MachinePrecision]], N[Sqrt[N[(2.0 * N[(N[(n * U), $MachinePrecision] * N[(t + N[(N[(l / N[(Om / l), $MachinePrecision]), $MachinePrecision] * N[(N[(n / N[(Om / U$42$), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(2.0 * N[(N[(N[(n / Om), $MachinePrecision] * N[(l * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(N[(n * U$42$), $MachinePrecision] / Om), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;Om \leq -1.36 \cdot 10^{-285} \lor \neg \left(Om \leq 1.5 \cdot 10^{-97}\right):\\
\;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{\frac{Om}{\ell}} \cdot \left(\frac{n}{\frac{Om}{U*}} - 2\right)\right)\right)}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if Om < -1.36e-285 or 1.50000000000000012e-97 < Om

    1. Initial program 48.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.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.36e-285 < Om < 1.50000000000000012e-97

    1. Initial program 30.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. Simplified59.5%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
    3. Step-by-step derivation
      1. *-un-lft-identity59.5%

        \[\leadsto \color{blue}{1 \cdot \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      2. associate-*l*59.4%

        \[\leadsto 1 \cdot \sqrt{\color{blue}{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    4. Applied egg-rr59.4%

      \[\leadsto \color{blue}{1 \cdot \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    5. Step-by-step derivation
      1. *-lft-identity59.4%

        \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
      2. associate-*r*51.0%

        \[\leadsto \sqrt{2 \cdot \color{blue}{\left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      3. +-commutative51.0%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\left(\frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) + t\right)}\right)} \]
      4. *-commutative51.0%

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

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

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

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

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

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

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

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\color{blue}{\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell\right)} \cdot \frac{\ell}{Om} + t\right)\right)} \]
      12. fma-def51.0%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\mathsf{fma}\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell, \frac{\ell}{Om}, t\right)}\right)} \]
    6. Simplified51.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;Om \leq -1.36 \cdot 10^{-285} \lor \neg \left(Om \leq 1.5 \cdot 10^{-97}\right):\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{\frac{Om}{\ell}} \cdot \left(\frac{n}{\frac{Om}{U*}} - 2\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(\frac{n}{Om} \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)\right) \cdot \left(\frac{n \cdot U*}{Om} - 2\right)\right)}\\ \end{array} \]

Alternative 9: 55.4% accurate, 1.8× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;Om \leq -1.75 \cdot 10^{-283} \lor \neg \left(Om \leq 3.2 \cdot 10^{-96}\right):\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{\frac{Om}{\ell}} \cdot \left(\frac{n}{\frac{Om}{U*}} - 2\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\frac{2 \cdot n}{\frac{Om}{\ell \cdot \left(U \cdot \left(\frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\right)\right)}}}\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (if (or (<= Om -1.75e-283) (not (<= Om 3.2e-96)))
   (sqrt (* 2.0 (* (* n U) (+ t (* (/ l (/ Om l)) (- (/ n (/ Om U*)) 2.0))))))
   (sqrt
    (/ (* 2.0 n) (/ Om (* l (* U (+ (/ (* n (* l U*)) Om) (* l -2.0)))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if ((Om <= -1.75e-283) || !(Om <= 3.2e-96)) {
		tmp = sqrt((2.0 * ((n * U) * (t + ((l / (Om / l)) * ((n / (Om / U_42_)) - 2.0))))));
	} else {
		tmp = sqrt(((2.0 * n) / (Om / (l * (U * (((n * (l * U_42_)) / Om) + (l * -2.0)))))));
	}
	return tmp;
}
NOTE: l should be positive before calling this function
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
    real(8) :: tmp
    if ((om <= (-1.75d-283)) .or. (.not. (om <= 3.2d-96))) then
        tmp = sqrt((2.0d0 * ((n * u) * (t + ((l / (om / l)) * ((n / (om / u_42)) - 2.0d0))))))
    else
        tmp = sqrt(((2.0d0 * n) / (om / (l * (u * (((n * (l * u_42)) / om) + (l * (-2.0d0))))))))
    end if
    code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if ((Om <= -1.75e-283) || !(Om <= 3.2e-96)) {
		tmp = Math.sqrt((2.0 * ((n * U) * (t + ((l / (Om / l)) * ((n / (Om / U_42_)) - 2.0))))));
	} else {
		tmp = Math.sqrt(((2.0 * n) / (Om / (l * (U * (((n * (l * U_42_)) / Om) + (l * -2.0)))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if (Om <= -1.75e-283) or not (Om <= 3.2e-96):
		tmp = math.sqrt((2.0 * ((n * U) * (t + ((l / (Om / l)) * ((n / (Om / U_42_)) - 2.0))))))
	else:
		tmp = math.sqrt(((2.0 * n) / (Om / (l * (U * (((n * (l * U_42_)) / Om) + (l * -2.0)))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if ((Om <= -1.75e-283) || !(Om <= 3.2e-96))
		tmp = sqrt(Float64(2.0 * Float64(Float64(n * U) * Float64(t + Float64(Float64(l / Float64(Om / l)) * Float64(Float64(n / Float64(Om / U_42_)) - 2.0))))));
	else
		tmp = sqrt(Float64(Float64(2.0 * n) / Float64(Om / Float64(l * Float64(U * Float64(Float64(Float64(n * Float64(l * U_42_)) / Om) + Float64(l * -2.0)))))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	tmp = 0.0;
	if ((Om <= -1.75e-283) || ~((Om <= 3.2e-96)))
		tmp = sqrt((2.0 * ((n * U) * (t + ((l / (Om / l)) * ((n / (Om / U_42_)) - 2.0))))));
	else
		tmp = sqrt(((2.0 * n) / (Om / (l * (U * (((n * (l * U_42_)) / Om) + (l * -2.0)))))));
	end
	tmp_2 = tmp;
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := If[Or[LessEqual[Om, -1.75e-283], N[Not[LessEqual[Om, 3.2e-96]], $MachinePrecision]], N[Sqrt[N[(2.0 * N[(N[(n * U), $MachinePrecision] * N[(t + N[(N[(l / N[(Om / l), $MachinePrecision]), $MachinePrecision] * N[(N[(n / N[(Om / U$42$), $MachinePrecision]), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] / N[(Om / N[(l * N[(U * N[(N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision] + N[(l * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;Om \leq -1.75 \cdot 10^{-283} \lor \neg \left(Om \leq 3.2 \cdot 10^{-96}\right):\\
\;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{\frac{Om}{\ell}} \cdot \left(\frac{n}{\frac{Om}{U*}} - 2\right)\right)\right)}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if Om < -1.7499999999999999e-283 or 3.20000000000000012e-96 < Om

    1. Initial program 48.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.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -1.7499999999999999e-283 < Om < 3.20000000000000012e-96

    1. Initial program 30.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. Simplified59.5%

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

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

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

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

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

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

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

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

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

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

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

        \[\leadsto \sqrt{\frac{2 \cdot n}{\frac{\frac{Om}{\ell \cdot U}}{\ell \cdot -2 + \color{blue}{\frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)}}}} \]
      11. fma-udef57.4%

        \[\leadsto \sqrt{\frac{2 \cdot n}{\frac{\frac{Om}{\ell \cdot U}}{\color{blue}{\mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)}}}} \]
      12. *-commutative57.4%

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

      \[\leadsto \sqrt{\color{blue}{\frac{2 \cdot n}{\frac{\frac{Om}{\ell \cdot U}}{\mathsf{fma}\left(\ell, -2, \left(n \cdot \left(U* - U\right)\right) \cdot \frac{\ell}{Om}\right)}}}} \]
    6. Taylor expanded in U around 0 72.0%

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;Om \leq -1.75 \cdot 10^{-283} \lor \neg \left(Om \leq 3.2 \cdot 10^{-96}\right):\\ \;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{\ell}{\frac{Om}{\ell}} \cdot \left(\frac{n}{\frac{Om}{U*}} - 2\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\frac{2 \cdot n}{\frac{Om}{\ell \cdot \left(U \cdot \left(\frac{n \cdot \left(\ell \cdot U*\right)}{Om} + \ell \cdot -2\right)\right)}}}\\ \end{array} \]

Alternative 10: 46.9% accurate, 1.8× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 3.95 \cdot 10^{+177}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell}{\frac{Om}{\ell}}\right)\right)\right)}\\ \mathbf{elif}\;\ell \leq 1.2 \cdot 10^{+229} \lor \neg \left(\ell \leq 6.4 \cdot 10^{+248}\right):\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \frac{n}{\frac{Om \cdot Om}{\left(\ell \cdot \ell\right) \cdot \left(U \cdot U*\right)}}}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{2 \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)}}}\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (if (<= l 3.95e+177)
   (sqrt (* 2.0 (* n (* U (- t (* 2.0 (/ l (/ Om l))))))))
   (if (or (<= l 1.2e+229) (not (<= l 6.4e+248)))
     (sqrt (* (* 2.0 n) (/ n (/ (* Om Om) (* (* l l) (* U U*))))))
     (sqrt (* -2.0 (/ n (/ Om (* 2.0 (* l (* U l))))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 3.95e+177) {
		tmp = sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))));
	} else if ((l <= 1.2e+229) || !(l <= 6.4e+248)) {
		tmp = sqrt(((2.0 * n) * (n / ((Om * Om) / ((l * l) * (U * U_42_))))));
	} else {
		tmp = sqrt((-2.0 * (n / (Om / (2.0 * (l * (U * l)))))));
	}
	return tmp;
}
NOTE: l should be positive before calling this function
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
    real(8) :: tmp
    if (l <= 3.95d+177) then
        tmp = sqrt((2.0d0 * (n * (u * (t - (2.0d0 * (l / (om / l))))))))
    else if ((l <= 1.2d+229) .or. (.not. (l <= 6.4d+248))) then
        tmp = sqrt(((2.0d0 * n) * (n / ((om * om) / ((l * l) * (u * u_42))))))
    else
        tmp = sqrt(((-2.0d0) * (n / (om / (2.0d0 * (l * (u * l)))))))
    end if
    code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 3.95e+177) {
		tmp = Math.sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))));
	} else if ((l <= 1.2e+229) || !(l <= 6.4e+248)) {
		tmp = Math.sqrt(((2.0 * n) * (n / ((Om * Om) / ((l * l) * (U * U_42_))))));
	} else {
		tmp = Math.sqrt((-2.0 * (n / (Om / (2.0 * (l * (U * l)))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 3.95e+177:
		tmp = math.sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))))
	elif (l <= 1.2e+229) or not (l <= 6.4e+248):
		tmp = math.sqrt(((2.0 * n) * (n / ((Om * Om) / ((l * l) * (U * U_42_))))))
	else:
		tmp = math.sqrt((-2.0 * (n / (Om / (2.0 * (l * (U * l)))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 3.95e+177)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t - Float64(2.0 * Float64(l / Float64(Om / l))))))));
	elseif ((l <= 1.2e+229) || !(l <= 6.4e+248))
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(n / Float64(Float64(Om * Om) / Float64(Float64(l * l) * Float64(U * U_42_))))));
	else
		tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(2.0 * Float64(l * Float64(U * l)))))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	tmp = 0.0;
	if (l <= 3.95e+177)
		tmp = sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))));
	elseif ((l <= 1.2e+229) || ~((l <= 6.4e+248)))
		tmp = sqrt(((2.0 * n) * (n / ((Om * Om) / ((l * l) * (U * U_42_))))));
	else
		tmp = sqrt((-2.0 * (n / (Om / (2.0 * (l * (U * l)))))));
	end
	tmp_2 = tmp;
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 3.95e+177], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t - N[(2.0 * N[(l / N[(Om / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[Or[LessEqual[l, 1.2e+229], N[Not[LessEqual[l, 6.4e+248]], $MachinePrecision]], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(n / N[(N[(Om * Om), $MachinePrecision] / N[(N[(l * l), $MachinePrecision] * N[(U * U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(2.0 * N[(l * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 3.95 \cdot 10^{+177}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell}{\frac{Om}{\ell}}\right)\right)\right)}\\

\mathbf{elif}\;\ell \leq 1.2 \cdot 10^{+229} \lor \neg \left(\ell \leq 6.4 \cdot 10^{+248}\right):\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \frac{n}{\frac{Om \cdot Om}{\left(\ell \cdot \ell\right) \cdot \left(U \cdot U*\right)}}}\\

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


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

    1. Initial program 50.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. Simplified56.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 3.95e177 < l < 1.2e229 or 6.39999999999999969e248 < l

    1. Initial program 6.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. Simplified57.7%

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

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

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

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

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

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

    if 1.2e229 < l < 6.39999999999999969e248

    1. Initial program 15.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. Simplified45.0%

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 3.95 \cdot 10^{+177}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell}{\frac{Om}{\ell}}\right)\right)\right)}\\ \mathbf{elif}\;\ell \leq 1.2 \cdot 10^{+229} \lor \neg \left(\ell \leq 6.4 \cdot 10^{+248}\right):\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \frac{n}{\frac{Om \cdot Om}{\left(\ell \cdot \ell\right) \cdot \left(U \cdot U*\right)}}}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{2 \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)}}}\\ \end{array} \]

Alternative 11: 46.8% accurate, 1.8× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;Om \leq -7.6 \cdot 10^{+33}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell}{\frac{Om}{\ell}}\right)\right)\right)}\\ \mathbf{elif}\;Om \leq 2.8 \cdot 10^{-95}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(\frac{n}{Om} \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)\right) \cdot \left(\frac{n \cdot U*}{Om} - 2\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + \frac{\ell \cdot \ell}{Om} \cdot -2\right)}\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (if (<= Om -7.6e+33)
   (sqrt (* 2.0 (* n (* U (- t (* 2.0 (/ l (/ Om l))))))))
   (if (<= Om 2.8e-95)
     (sqrt (* 2.0 (* (* (/ n Om) (* l (* U l))) (- (/ (* n U*) Om) 2.0))))
     (sqrt (* (* (* 2.0 n) U) (+ t (* (/ (* l l) Om) -2.0)))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (Om <= -7.6e+33) {
		tmp = sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))));
	} else if (Om <= 2.8e-95) {
		tmp = sqrt((2.0 * (((n / Om) * (l * (U * l))) * (((n * U_42_) / Om) - 2.0))));
	} else {
		tmp = sqrt((((2.0 * n) * U) * (t + (((l * l) / Om) * -2.0))));
	}
	return tmp;
}
NOTE: l should be positive before calling this function
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
    real(8) :: tmp
    if (om <= (-7.6d+33)) then
        tmp = sqrt((2.0d0 * (n * (u * (t - (2.0d0 * (l / (om / l))))))))
    else if (om <= 2.8d-95) then
        tmp = sqrt((2.0d0 * (((n / om) * (l * (u * l))) * (((n * u_42) / om) - 2.0d0))))
    else
        tmp = sqrt((((2.0d0 * n) * u) * (t + (((l * l) / om) * (-2.0d0)))))
    end if
    code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (Om <= -7.6e+33) {
		tmp = Math.sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))));
	} else if (Om <= 2.8e-95) {
		tmp = Math.sqrt((2.0 * (((n / Om) * (l * (U * l))) * (((n * U_42_) / Om) - 2.0))));
	} else {
		tmp = Math.sqrt((((2.0 * n) * U) * (t + (((l * l) / Om) * -2.0))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if Om <= -7.6e+33:
		tmp = math.sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))))
	elif Om <= 2.8e-95:
		tmp = math.sqrt((2.0 * (((n / Om) * (l * (U * l))) * (((n * U_42_) / Om) - 2.0))))
	else:
		tmp = math.sqrt((((2.0 * n) * U) * (t + (((l * l) / Om) * -2.0))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (Om <= -7.6e+33)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t - Float64(2.0 * Float64(l / Float64(Om / l))))))));
	elseif (Om <= 2.8e-95)
		tmp = sqrt(Float64(2.0 * Float64(Float64(Float64(n / Om) * Float64(l * Float64(U * l))) * Float64(Float64(Float64(n * U_42_) / Om) - 2.0))));
	else
		tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t + Float64(Float64(Float64(l * l) / Om) * -2.0))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	tmp = 0.0;
	if (Om <= -7.6e+33)
		tmp = sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))));
	elseif (Om <= 2.8e-95)
		tmp = sqrt((2.0 * (((n / Om) * (l * (U * l))) * (((n * U_42_) / Om) - 2.0))));
	else
		tmp = sqrt((((2.0 * n) * U) * (t + (((l * l) / Om) * -2.0))));
	end
	tmp_2 = tmp;
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[Om, -7.6e+33], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t - N[(2.0 * N[(l / N[(Om / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[Om, 2.8e-95], N[Sqrt[N[(2.0 * N[(N[(N[(n / Om), $MachinePrecision] * N[(l * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(N[(n * U$42$), $MachinePrecision] / Om), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t + N[(N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision] * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;Om \leq -7.6 \cdot 10^{+33}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell}{\frac{Om}{\ell}}\right)\right)\right)}\\

\mathbf{elif}\;Om \leq 2.8 \cdot 10^{-95}:\\
\;\;\;\;\sqrt{2 \cdot \left(\left(\frac{n}{Om} \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)\right) \cdot \left(\frac{n \cdot U*}{Om} - 2\right)\right)}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 3 regimes
  2. if Om < -7.60000000000000005e33

    1. Initial program 51.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.2%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if -7.60000000000000005e33 < Om < 2.7999999999999999e-95

    1. Initial program 32.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. Simplified57.6%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
    3. Step-by-step derivation
      1. *-un-lft-identity57.6%

        \[\leadsto \color{blue}{1 \cdot \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      2. associate-*l*57.6%

        \[\leadsto 1 \cdot \sqrt{\color{blue}{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    4. Applied egg-rr57.6%

      \[\leadsto \color{blue}{1 \cdot \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    5. Step-by-step derivation
      1. *-lft-identity57.6%

        \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
      2. associate-*r*53.5%

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

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\left(\frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) + t\right)}\right)} \]
      4. *-commutative53.5%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\color{blue}{\mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right) \cdot \frac{\ell}{Om}} + t\right)\right)} \]
      5. fma-udef53.5%

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

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

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

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

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

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

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

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\mathsf{fma}\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell, \frac{\ell}{Om}, t\right)}\right)} \]
    6. Simplified53.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 2.7999999999999999e-95 < Om

    1. Initial program 55.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. Taylor expanded in Om around inf 54.9%

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;Om \leq -7.6 \cdot 10^{+33}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell}{\frac{Om}{\ell}}\right)\right)\right)}\\ \mathbf{elif}\;Om \leq 2.8 \cdot 10^{-95}:\\ \;\;\;\;\sqrt{2 \cdot \left(\left(\frac{n}{Om} \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)\right) \cdot \left(\frac{n \cdot U*}{Om} - 2\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + \frac{\ell \cdot \ell}{Om} \cdot -2\right)}\\ \end{array} \]

Alternative 12: 47.7% accurate, 1.9× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 4.4 \cdot 10^{+75}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{\frac{Om}{\ell \cdot \ell}}{U \cdot \left(2 - \frac{n}{\frac{Om}{U*}}\right)}}}\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (if (<= l 4.4e+75)
   (sqrt (* (* 2.0 n) (* U (- t (* 2.0 (/ (* l l) Om))))))
   (sqrt (* -2.0 (/ n (/ (/ Om (* l l)) (* U (- 2.0 (/ n (/ Om U*))))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 4.4e+75) {
		tmp = sqrt(((2.0 * n) * (U * (t - (2.0 * ((l * l) / Om))))));
	} else {
		tmp = sqrt((-2.0 * (n / ((Om / (l * l)) / (U * (2.0 - (n / (Om / U_42_))))))));
	}
	return tmp;
}
NOTE: l should be positive before calling this function
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
    real(8) :: tmp
    if (l <= 4.4d+75) then
        tmp = sqrt(((2.0d0 * n) * (u * (t - (2.0d0 * ((l * l) / om))))))
    else
        tmp = sqrt(((-2.0d0) * (n / ((om / (l * l)) / (u * (2.0d0 - (n / (om / u_42))))))))
    end if
    code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 4.4e+75) {
		tmp = Math.sqrt(((2.0 * n) * (U * (t - (2.0 * ((l * l) / Om))))));
	} else {
		tmp = Math.sqrt((-2.0 * (n / ((Om / (l * l)) / (U * (2.0 - (n / (Om / U_42_))))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 4.4e+75:
		tmp = math.sqrt(((2.0 * n) * (U * (t - (2.0 * ((l * l) / Om))))))
	else:
		tmp = math.sqrt((-2.0 * (n / ((Om / (l * l)) / (U * (2.0 - (n / (Om / U_42_))))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 4.4e+75)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t - Float64(2.0 * Float64(Float64(l * l) / Om))))));
	else
		tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Float64(Om / Float64(l * l)) / Float64(U * Float64(2.0 - Float64(n / Float64(Om / U_42_))))))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	tmp = 0.0;
	if (l <= 4.4e+75)
		tmp = sqrt(((2.0 * n) * (U * (t - (2.0 * ((l * l) / Om))))));
	else
		tmp = sqrt((-2.0 * (n / ((Om / (l * l)) / (U * (2.0 - (n / (Om / U_42_))))))));
	end
	tmp_2 = tmp;
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 4.4e+75], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t - N[(2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(N[(Om / N[(l * l), $MachinePrecision]), $MachinePrecision] / N[(U * N[(2.0 - N[(n / N[(Om / U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 4.4 \cdot 10^{+75}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if l < 4.40000000000000024e75

    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. Step-by-step derivation
      1. associate-*l*51.2%

        \[\leadsto \sqrt{\color{blue}{\left(2 \cdot n\right) \cdot \left(U \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)\right)}} \]
      2. sub-neg51.2%

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

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

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

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

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

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

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

      \[\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. unpow247.3%

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

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

    if 4.40000000000000024e75 < l

    1. Initial program 21.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. Simplified50.5%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 13: 47.3% accurate, 1.9× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 2.5 \cdot 10^{+183}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell}{\frac{Om}{\ell}}\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\frac{2 \cdot \left(\left(\left(n \cdot \ell\right) \cdot \left(n \cdot \ell\right)\right) \cdot \left(U \cdot U*\right)\right)}{Om \cdot Om}}\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (if (<= l 2.5e+183)
   (sqrt (* 2.0 (* n (* U (- t (* 2.0 (/ l (/ Om l))))))))
   (sqrt (/ (* 2.0 (* (* (* n l) (* n l)) (* U U*))) (* Om Om)))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 2.5e+183) {
		tmp = sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))));
	} else {
		tmp = sqrt(((2.0 * (((n * l) * (n * l)) * (U * U_42_))) / (Om * Om)));
	}
	return tmp;
}
NOTE: l should be positive before calling this function
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
    real(8) :: tmp
    if (l <= 2.5d+183) then
        tmp = sqrt((2.0d0 * (n * (u * (t - (2.0d0 * (l / (om / l))))))))
    else
        tmp = sqrt(((2.0d0 * (((n * l) * (n * l)) * (u * u_42))) / (om * om)))
    end if
    code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 2.5e+183) {
		tmp = Math.sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))));
	} else {
		tmp = Math.sqrt(((2.0 * (((n * l) * (n * l)) * (U * U_42_))) / (Om * Om)));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 2.5e+183:
		tmp = math.sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))))
	else:
		tmp = math.sqrt(((2.0 * (((n * l) * (n * l)) * (U * U_42_))) / (Om * Om)))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 2.5e+183)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t - Float64(2.0 * Float64(l / Float64(Om / l))))))));
	else
		tmp = sqrt(Float64(Float64(2.0 * Float64(Float64(Float64(n * l) * Float64(n * l)) * Float64(U * U_42_))) / Float64(Om * Om)));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	tmp = 0.0;
	if (l <= 2.5e+183)
		tmp = sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))));
	else
		tmp = sqrt(((2.0 * (((n * l) * (n * l)) * (U * U_42_))) / (Om * Om)));
	end
	tmp_2 = tmp;
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 2.5e+183], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t - N[(2.0 * N[(l / N[(Om / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(2.0 * N[(N[(N[(n * l), $MachinePrecision] * N[(n * l), $MachinePrecision]), $MachinePrecision] * N[(U * U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 2.5 \cdot 10^{+183}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell}{\frac{Om}{\ell}}\right)\right)\right)}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if l < 2.50000000000000004e183

    1. Initial program 50.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. Simplified56.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    if 2.50000000000000004e183 < l

    1. Initial program 8.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. Simplified54.4%

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

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

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

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

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

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

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

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

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

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

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

Alternative 14: 42.8% accurate, 2.0× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 6.5 \cdot 10^{+116}:\\ \;\;\;\;{\left(2 \cdot \left(t \cdot \left(n \cdot U\right)\right)\right)}^{0.5}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{2 \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)}}}\\ \end{array} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (if (<= l 6.5e+116)
   (pow (* 2.0 (* t (* n U))) 0.5)
   (sqrt (* -2.0 (/ n (/ Om (* 2.0 (* l (* U l)))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 6.5e+116) {
		tmp = pow((2.0 * (t * (n * U))), 0.5);
	} else {
		tmp = sqrt((-2.0 * (n / (Om / (2.0 * (l * (U * l)))))));
	}
	return tmp;
}
NOTE: l should be positive before calling this function
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
    real(8) :: tmp
    if (l <= 6.5d+116) then
        tmp = (2.0d0 * (t * (n * u))) ** 0.5d0
    else
        tmp = sqrt(((-2.0d0) * (n / (om / (2.0d0 * (l * (u * l)))))))
    end if
    code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 6.5e+116) {
		tmp = Math.pow((2.0 * (t * (n * U))), 0.5);
	} else {
		tmp = Math.sqrt((-2.0 * (n / (Om / (2.0 * (l * (U * l)))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 6.5e+116:
		tmp = math.pow((2.0 * (t * (n * U))), 0.5)
	else:
		tmp = math.sqrt((-2.0 * (n / (Om / (2.0 * (l * (U * l)))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 6.5e+116)
		tmp = Float64(2.0 * Float64(t * Float64(n * U))) ^ 0.5;
	else
		tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(2.0 * Float64(l * Float64(U * l)))))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	tmp = 0.0;
	if (l <= 6.5e+116)
		tmp = (2.0 * (t * (n * U))) ^ 0.5;
	else
		tmp = sqrt((-2.0 * (n / (Om / (2.0 * (l * (U * l)))))));
	end
	tmp_2 = tmp;
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 6.5e+116], N[Power[N[(2.0 * N[(t * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(2.0 * N[(l * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 6.5 \cdot 10^{+116}:\\
\;\;\;\;{\left(2 \cdot \left(t \cdot \left(n \cdot U\right)\right)\right)}^{0.5}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if l < 6.4999999999999998e116

    1. Initial program 51.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. Simplified57.0%

      \[\leadsto \color{blue}{\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
    3. Step-by-step derivation
      1. *-un-lft-identity57.0%

        \[\leadsto \color{blue}{1 \cdot \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
      2. associate-*l*57.0%

        \[\leadsto 1 \cdot \sqrt{\color{blue}{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    4. Applied egg-rr57.0%

      \[\leadsto \color{blue}{1 \cdot \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    5. Step-by-step derivation
      1. *-lft-identity57.0%

        \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
      2. associate-*r*56.1%

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

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

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

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

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

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

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

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

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

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(\color{blue}{\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell\right)} \cdot \frac{\ell}{Om} + t\right)\right)} \]
      12. fma-def55.0%

        \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\mathsf{fma}\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell, \frac{\ell}{Om}, t\right)}\right)} \]
    6. Simplified56.1%

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

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

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

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

    if 6.4999999999999998e116 < l

    1. Initial program 21.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. Simplified50.2%

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 6.5 \cdot 10^{+116}:\\ \;\;\;\;{\left(2 \cdot \left(t \cdot \left(n \cdot U\right)\right)\right)}^{0.5}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{2 \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)}}}\\ \end{array} \]

Alternative 15: 47.6% accurate, 2.0× speedup?

\[\begin{array}{l} l = |l|\\ \\ \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell}{\frac{Om}{\ell}}\right)\right)\right)} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
 :precision binary64
 (sqrt (* 2.0 (* n (* U (- t (* 2.0 (/ l (/ Om l)))))))))
l = abs(l);
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 / (Om / l))))))));
}
NOTE: l should be positive before calling this function
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 / (om / l))))))))
end function
l = Math.abs(l);
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 / (Om / l))))))));
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	return math.sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))))
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	return sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t - Float64(2.0 * Float64(l / Float64(Om / l))))))))
end
l = abs(l)
function tmp = code(n, U, t, l, Om, U_42_)
	tmp = sqrt((2.0 * (n * (U * (t - (2.0 * (l / (Om / l))))))));
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t - N[(2.0 * N[(l / N[(Om / l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
l = |l|\\
\\
\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t - 2 \cdot \frac{\ell}{\frac{Om}{\ell}}\right)\right)\right)}
\end{array}
Derivation
  1. Initial program 46.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. Simplified55.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 16: 38.0% accurate, 2.1× speedup?

\[\begin{array}{l} l = |l|\\ \\ {\left(2 \cdot \left(t \cdot \left(n \cdot U\right)\right)\right)}^{0.5} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*) :precision binary64 (pow (* 2.0 (* t (* n U))) 0.5))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	return pow((2.0 * (t * (n * U))), 0.5);
}
NOTE: l should be positive before calling this function
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 = (2.0d0 * (t * (n * u))) ** 0.5d0
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	return Math.pow((2.0 * (t * (n * U))), 0.5);
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	return math.pow((2.0 * (t * (n * U))), 0.5)
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	return Float64(2.0 * Float64(t * Float64(n * U))) ^ 0.5
end
l = abs(l)
function tmp = code(n, U, t, l, Om, U_42_)
	tmp = (2.0 * (t * (n * U))) ^ 0.5;
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := N[Power[N[(2.0 * N[(t * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]
\begin{array}{l}
l = |l|\\
\\
{\left(2 \cdot \left(t \cdot \left(n \cdot U\right)\right)\right)}^{0.5}
\end{array}
Derivation
  1. Initial program 46.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. Simplified55.8%

    \[\leadsto \color{blue}{\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
  3. Step-by-step derivation
    1. *-un-lft-identity55.8%

      \[\leadsto \color{blue}{1 \cdot \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
    2. associate-*l*55.8%

      \[\leadsto 1 \cdot \sqrt{\color{blue}{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
  4. Applied egg-rr55.8%

    \[\leadsto \color{blue}{1 \cdot \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
  5. Step-by-step derivation
    1. *-lft-identity55.8%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    2. associate-*r*55.1%

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\mathsf{fma}\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell, \frac{\ell}{Om}, t\right)}\right)} \]
  6. Simplified55.1%

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

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

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

    \[\leadsto \color{blue}{{\left(2 \cdot \left(\left(n \cdot U\right) \cdot t\right)\right)}^{0.5}} \]
  10. Final simplification35.2%

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

Alternative 17: 36.5% accurate, 2.1× speedup?

\[\begin{array}{l} l = |l|\\ \\ \sqrt{2 \cdot \left(t \cdot \left(n \cdot U\right)\right)} \end{array} \]
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*) :precision binary64 (sqrt (* 2.0 (* t (* n U)))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	return sqrt((2.0 * (t * (n * U))));
}
NOTE: l should be positive before calling this function
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 * (t * (n * u))))
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
	return Math.sqrt((2.0 * (t * (n * U))));
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	return math.sqrt((2.0 * (t * (n * U))))
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	return sqrt(Float64(2.0 * Float64(t * Float64(n * U))))
end
l = abs(l)
function tmp = code(n, U, t, l, Om, U_42_)
	tmp = sqrt((2.0 * (t * (n * U))));
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(2.0 * N[(t * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
l = |l|\\
\\
\sqrt{2 \cdot \left(t \cdot \left(n \cdot U\right)\right)}
\end{array}
Derivation
  1. Initial program 46.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. Simplified55.8%

    \[\leadsto \color{blue}{\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
  3. Step-by-step derivation
    1. *-un-lft-identity55.8%

      \[\leadsto \color{blue}{1 \cdot \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}} \]
    2. associate-*l*55.8%

      \[\leadsto 1 \cdot \sqrt{\color{blue}{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
  4. Applied egg-rr55.8%

    \[\leadsto \color{blue}{1 \cdot \sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
  5. Step-by-step derivation
    1. *-lft-identity55.8%

      \[\leadsto \color{blue}{\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)\right)}} \]
    2. associate-*r*55.1%

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

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

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

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

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

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

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

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

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

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

      \[\leadsto \sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \color{blue}{\mathsf{fma}\left(\frac{n \cdot \left(\ell \cdot \left(U* - U\right)\right)}{Om} + -2 \cdot \ell, \frac{\ell}{Om}, t\right)}\right)} \]
  6. Simplified55.1%

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

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

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

Reproduce

?
herbie shell --seed 2023200 
(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*))))))