Toniolo and Linder, Equation (13)

Percentage Accurate: 49.5% → 70.1%
Time: 23.8s
Alternatives: 21
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 21 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.5% 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: 70.1% 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 \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)}\\ \mathbf{elif}\;t_1 \leq 4 \cdot 10^{+305}:\\ \;\;\;\;\sqrt{t_1}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2} \cdot \left(\ell \cdot \sqrt{\left(U \cdot \frac{n}{Om}\right) \cdot \left(-2 + \left(U* - U\right) \cdot \frac{n}{Om}\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 (* (/ l Om) (fma l -2.0 (* (/ l Om) (* n (- U* U)))))))))
     (if (<= t_1 4e+305)
       (sqrt t_1)
       (*
        (sqrt 2.0)
        (* l (sqrt (* (* U (/ n Om)) (+ -2.0 (* (- U* U) (/ n 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 + ((l / Om) * fma(l, -2.0, ((l / Om) * (n * (U_42_ - U)))))))));
	} else if (t_1 <= 4e+305) {
		tmp = sqrt(t_1);
	} else {
		tmp = sqrt(2.0) * (l * sqrt(((U * (n / Om)) * (-2.0 + ((U_42_ - U) * (n / 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 * Float64(t + Float64(Float64(l / Om) * fma(l, -2.0, Float64(Float64(l / Om) * Float64(n * Float64(U_42_ - U)))))))));
	elseif (t_1 <= 4e+305)
		tmp = sqrt(t_1);
	else
		tmp = Float64(sqrt(2.0) * Float64(l * sqrt(Float64(Float64(U * Float64(n / Om)) * Float64(-2.0 + Float64(Float64(U_42_ - U) * Float64(n / Om)))))));
	end
	return 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 * N[(t + N[(N[(l / Om), $MachinePrecision] * N[(l * -2.0 + N[(N[(l / Om), $MachinePrecision] * N[(n * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$1, 4e+305], N[Sqrt[t$95$1], $MachinePrecision], N[(N[Sqrt[2.0], $MachinePrecision] * N[(l * N[Sqrt[N[(N[(U * N[(n / Om), $MachinePrecision]), $MachinePrecision] * N[(-2.0 + N[(N[(U$42$ - U), $MachinePrecision] * N[(n / 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 \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)}\\

\mathbf{elif}\;t_1 \leq 4 \cdot 10^{+305}:\\
\;\;\;\;\sqrt{t_1}\\

\mathbf{else}:\\
\;\;\;\;\sqrt{2} \cdot \left(\ell \cdot \sqrt{\left(U \cdot \frac{n}{Om}\right) \cdot \left(-2 + \left(U* - U\right) \cdot \frac{n}{Om}\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 16.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. Simplified51.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)}} \]

    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*)))) < 3.9999999999999998e305

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

    if 3.9999999999999998e305 < (*.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 18.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. Simplified39.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. distribute-rgt-in39.3%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right) \leq 0:\\ \;\;\;\;\sqrt{\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)}\\ \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 4 \cdot 10^{+305}:\\ \;\;\;\;\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{\left(U \cdot \frac{n}{Om}\right) \cdot \left(-2 + \left(U* - U\right) \cdot \frac{n}{Om}\right)}\right)\\ \end{array} \]

Alternative 2: 63.0% accurate, 1.0× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 1.5 \cdot 10^{+77}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2} \cdot \left(\ell \cdot \sqrt{\left(U \cdot \frac{n}{Om}\right) \cdot \left(-2 + \left(U* - U\right) \cdot \frac{n}{Om}\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.5e+77)
   (sqrt
    (*
     (* 2.0 n)
     (* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
   (*
    (sqrt 2.0)
    (* l (sqrt (* (* U (/ n Om)) (+ -2.0 (* (- U* U) (/ n Om)))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 1.5e+77) {
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else {
		tmp = sqrt(2.0) * (l * sqrt(((U * (n / Om)) * (-2.0 + ((U_42_ - U) * (n / 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 <= 1.5d+77) then
        tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
    else
        tmp = sqrt(2.0d0) * (l * sqrt(((u * (n / om)) * ((-2.0d0) + ((u_42 - u) * (n / 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 <= 1.5e+77) {
		tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else {
		tmp = Math.sqrt(2.0) * (l * Math.sqrt(((U * (n / Om)) * (-2.0 + ((U_42_ - U) * (n / Om))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 1.5e+77:
		tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))))
	else:
		tmp = math.sqrt(2.0) * (l * math.sqrt(((U * (n / Om)) * (-2.0 + ((U_42_ - U) * (n / Om))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 1.5e+77)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om)))));
	else
		tmp = Float64(sqrt(2.0) * Float64(l * sqrt(Float64(Float64(U * Float64(n / Om)) * Float64(-2.0 + Float64(Float64(U_42_ - U) * Float64(n / Om)))))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	tmp = 0.0;
	if (l <= 1.5e+77)
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	else
		tmp = sqrt(2.0) * (l * sqrt(((U * (n / Om)) * (-2.0 + ((U_42_ - U) * (n / 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, 1.5e+77], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[2.0], $MachinePrecision] * N[(l * N[Sqrt[N[(N[(U * N[(n / Om), $MachinePrecision]), $MachinePrecision] * N[(-2.0 + N[(N[(U$42$ - U), $MachinePrecision] * N[(n / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 1.5 \cdot 10^{+77}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\

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


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

    1. Initial program 56.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. Simplified62.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 64.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.4999999999999999e77 < l

    1. Initial program 17.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. Simplified46.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. Step-by-step derivation
      1. distribute-rgt-in46.2%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 3: 62.3% accurate, 1.0× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 4 \cdot 10^{+87}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt{\frac{n}{\frac{Om}{U \cdot \left(\frac{n \cdot U*}{Om} - 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 (<= l 4e+87)
   (sqrt
    (*
     (* 2.0 n)
     (* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
   (* (* l (sqrt 2.0)) (sqrt (/ n (/ Om (* U (- (/ (* 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 (l <= 4e+87) {
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else {
		tmp = (l * sqrt(2.0)) * sqrt((n / (Om / (U * (((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 (l <= 4d+87) then
        tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
    else
        tmp = (l * sqrt(2.0d0)) * sqrt((n / (om / (u * (((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 (l <= 4e+87) {
		tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else {
		tmp = (l * Math.sqrt(2.0)) * Math.sqrt((n / (Om / (U * (((n * U_42_) / Om) - 2.0)))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 4e+87:
		tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))))
	else:
		tmp = (l * math.sqrt(2.0)) * math.sqrt((n / (Om / (U * (((n * U_42_) / Om) - 2.0)))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 4e+87)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om)))));
	else
		tmp = Float64(Float64(l * sqrt(2.0)) * sqrt(Float64(n / Float64(Om / Float64(U * 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 (l <= 4e+87)
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	else
		tmp = (l * sqrt(2.0)) * sqrt((n / (Om / (U * (((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[LessEqual[l, 4e+87], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(n / N[(Om / N[(U * N[(N[(N[(n * U$42$), $MachinePrecision] / Om), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 4 \cdot 10^{+87}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\

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


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

    1. Initial program 56.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. Simplified62.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 U around 0 64.8%

      \[\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.9999999999999998e87 < l

    1. Initial program 15.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. Simplified43.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. Step-by-step derivation
      1. distribute-rgt-in43.2%

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

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

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

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

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

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

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

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

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

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

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

Alternative 4: 62.1% accurate, 1.0× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 3.6 \cdot 10^{+79}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt{\frac{n \cdot \left(U \cdot \left(\frac{n \cdot U*}{Om} - 2\right)\right)}{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 3.6e+79)
   (sqrt
    (*
     (* 2.0 n)
     (* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
   (* (* l (sqrt 2.0)) (sqrt (/ (* n (* U (- (/ (* n 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 <= 3.6e+79) {
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else {
		tmp = (l * sqrt(2.0)) * sqrt(((n * (U * (((n * 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 <= 3.6d+79) then
        tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
    else
        tmp = (l * sqrt(2.0d0)) * sqrt(((n * (u * (((n * 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 <= 3.6e+79) {
		tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else {
		tmp = (l * Math.sqrt(2.0)) * Math.sqrt(((n * (U * (((n * U_42_) / Om) - 2.0))) / Om));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 3.6e+79:
		tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))))
	else:
		tmp = (l * math.sqrt(2.0)) * math.sqrt(((n * (U * (((n * 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 <= 3.6e+79)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om)))));
	else
		tmp = Float64(Float64(l * sqrt(2.0)) * sqrt(Float64(Float64(n * Float64(U * Float64(Float64(Float64(n * U_42_) / Om) - 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 <= 3.6e+79)
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	else
		tmp = (l * sqrt(2.0)) * sqrt(((n * (U * (((n * 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, 3.6e+79], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(N[(n * N[(U * N[(N[(N[(n * U$42$), $MachinePrecision] / Om), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 3.6 \cdot 10^{+79}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\

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


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

    1. Initial program 56.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. Simplified62.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 64.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 3.5999999999999999e79 < l

    1. Initial program 17.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. Simplified46.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. Step-by-step derivation
      1. distribute-rgt-in46.2%

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

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

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

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

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

Alternative 5: 57.0% accurate, 1.0× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 9 \cdot 10^{+69}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\ \mathbf{elif}\;\ell \leq 2.2 \cdot 10^{+202}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right) + 2 \cdot \frac{\left(\ell \cdot -2 + \left(n \cdot \ell\right) \cdot \left(\left(U - U*\right) \cdot \frac{-1}{Om}\right)\right) \cdot \left(n \cdot \left(U \cdot \ell\right)\right)}{Om}}\\ \mathbf{elif}\;\ell \leq 2.05 \cdot 10^{+264}:\\ \;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt{-2 \cdot \frac{n \cdot U}{Om}}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\left(2 - \frac{n}{\frac{Om}{U* - U}}\right) \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 9e+69)
   (sqrt
    (*
     (* 2.0 n)
     (* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
   (if (<= l 2.2e+202)
     (sqrt
      (+
       (* 2.0 (* n (* U t)))
       (*
        2.0
        (/
         (* (+ (* l -2.0) (* (* n l) (* (- U U*) (/ -1.0 Om)))) (* n (* U l)))
         Om))))
     (if (<= l 2.05e+264)
       (* (* l (sqrt 2.0)) (sqrt (* -2.0 (/ (* n U) Om))))
       (sqrt
        (*
         -2.0
         (/ n (/ Om (* (- 2.0 (/ n (/ Om (- U* U)))) (* 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 <= 9e+69) {
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else if (l <= 2.2e+202) {
		tmp = sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om))));
	} else if (l <= 2.05e+264) {
		tmp = (l * sqrt(2.0)) * sqrt((-2.0 * ((n * U) / Om)));
	} else {
		tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (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 <= 9d+69) then
        tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
    else if (l <= 2.2d+202) then
        tmp = sqrt(((2.0d0 * (n * (u * t))) + (2.0d0 * ((((l * (-2.0d0)) + ((n * l) * ((u - u_42) * ((-1.0d0) / om)))) * (n * (u * l))) / om))))
    else if (l <= 2.05d+264) then
        tmp = (l * sqrt(2.0d0)) * sqrt(((-2.0d0) * ((n * u) / om)))
    else
        tmp = sqrt(((-2.0d0) * (n / (om / ((2.0d0 - (n / (om / (u_42 - u)))) * (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 <= 9e+69) {
		tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else if (l <= 2.2e+202) {
		tmp = Math.sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om))));
	} else if (l <= 2.05e+264) {
		tmp = (l * Math.sqrt(2.0)) * Math.sqrt((-2.0 * ((n * U) / Om)));
	} else {
		tmp = Math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 9e+69:
		tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))))
	elif l <= 2.2e+202:
		tmp = math.sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om))))
	elif l <= 2.05e+264:
		tmp = (l * math.sqrt(2.0)) * math.sqrt((-2.0 * ((n * U) / Om)))
	else:
		tmp = math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 9e+69)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om)))));
	elseif (l <= 2.2e+202)
		tmp = sqrt(Float64(Float64(2.0 * Float64(n * Float64(U * t))) + Float64(2.0 * Float64(Float64(Float64(Float64(l * -2.0) + Float64(Float64(n * l) * Float64(Float64(U - U_42_) * Float64(-1.0 / Om)))) * Float64(n * Float64(U * l))) / Om))));
	elseif (l <= 2.05e+264)
		tmp = Float64(Float64(l * sqrt(2.0)) * sqrt(Float64(-2.0 * Float64(Float64(n * U) / Om))));
	else
		tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(Float64(2.0 - Float64(n / Float64(Om / Float64(U_42_ - U)))) * 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 <= 9e+69)
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	elseif (l <= 2.2e+202)
		tmp = sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om))));
	elseif (l <= 2.05e+264)
		tmp = (l * sqrt(2.0)) * sqrt((-2.0 * ((n * U) / Om)));
	else
		tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (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, 9e+69], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 2.2e+202], N[Sqrt[N[(N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(2.0 * N[(N[(N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * l), $MachinePrecision] * N[(N[(U - U$42$), $MachinePrecision] * N[(-1.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(n * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 2.05e+264], N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(-2.0 * N[(N[(n * U), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(N[(2.0 - N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 9 \cdot 10^{+69}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if l < 8.9999999999999999e69

    1. Initial program 56.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. Simplified62.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 64.3%

      \[\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 8.9999999999999999e69 < l < 2.19999999999999978e202

    1. Initial program 33.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. Simplified59.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 t around inf 59.6%

      \[\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}}} \]
    4. Step-by-step derivation
      1. div-inv59.6%

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

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

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

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

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

    if 2.19999999999999978e202 < l < 2.05e264

    1. Initial program 10.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. Simplified30.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. Step-by-step derivation
      1. distribute-rgt-in30.7%

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

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

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

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

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

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

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

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

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

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

    if 2.05e264 < l

    1. Initial program 1.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. Simplified42.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. Step-by-step derivation
      1. distribute-rgt-in42.9%

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

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

      \[\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}}} \]
    6. Step-by-step derivation
      1. associate-/l*42.9%

        \[\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. associate-*r*42.9%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 9 \cdot 10^{+69}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\ \mathbf{elif}\;\ell \leq 2.2 \cdot 10^{+202}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right) + 2 \cdot \frac{\left(\ell \cdot -2 + \left(n \cdot \ell\right) \cdot \left(\left(U - U*\right) \cdot \frac{-1}{Om}\right)\right) \cdot \left(n \cdot \left(U \cdot \ell\right)\right)}{Om}}\\ \mathbf{elif}\;\ell \leq 2.05 \cdot 10^{+264}:\\ \;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt{-2 \cdot \frac{n \cdot U}{Om}}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\left(2 - \frac{n}{\frac{Om}{U* - U}}\right) \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)}}}\\ \end{array} \]

Alternative 6: 58.9% accurate, 1.7× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 1.6 \cdot 10^{+67}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right) + 2 \cdot \frac{\left(\ell \cdot -2 + \left(n \cdot \ell\right) \cdot \left(\left(U - U*\right) \cdot \frac{-1}{Om}\right)\right) \cdot \left(n \cdot \left(U \cdot \ell\right)\right)}{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 1.6e+67)
   (sqrt
    (*
     (* 2.0 n)
     (* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
   (sqrt
    (+
     (* 2.0 (* n (* U t)))
     (*
      2.0
      (/
       (* (+ (* l -2.0) (* (* n l) (* (- U U*) (/ -1.0 Om)))) (* n (* U l)))
       Om))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 1.6e+67) {
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else {
		tmp = sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / 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 <= 1.6d+67) then
        tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
    else
        tmp = sqrt(((2.0d0 * (n * (u * t))) + (2.0d0 * ((((l * (-2.0d0)) + ((n * l) * ((u - u_42) * ((-1.0d0) / om)))) * (n * (u * l))) / 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 <= 1.6e+67) {
		tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else {
		tmp = Math.sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 1.6e+67:
		tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))))
	else:
		tmp = math.sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 1.6e+67)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om)))));
	else
		tmp = sqrt(Float64(Float64(2.0 * Float64(n * Float64(U * t))) + Float64(2.0 * Float64(Float64(Float64(Float64(l * -2.0) + Float64(Float64(n * l) * Float64(Float64(U - U_42_) * Float64(-1.0 / Om)))) * Float64(n * Float64(U * l))) / Om))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	tmp = 0.0;
	if (l <= 1.6e+67)
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	else
		tmp = sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / 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, 1.6e+67], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(2.0 * N[(N[(N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * l), $MachinePrecision] * N[(N[(U - U$42$), $MachinePrecision] * N[(-1.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(n * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 1.6 \cdot 10^{+67}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\

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


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

    1. Initial program 56.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. Simplified62.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 64.3%

      \[\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.59999999999999991e67 < l

    1. Initial program 19.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. Simplified47.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 52.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}}} \]
    4. Step-by-step derivation
      1. div-inv52.1%

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

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

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

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

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

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

Alternative 7: 58.6% accurate, 1.7× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 6.5 \cdot 10^{+68}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;{\left(2 \cdot \left(n \cdot \left(U \cdot t\right) + \frac{\ell \cdot -2 + \frac{\left(U* - U\right) \cdot \left(n \cdot \ell\right)}{Om}}{\frac{Om}{n \cdot \left(U \cdot \ell\right)}}\right)\right)}^{0.5}\\ \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+68)
   (sqrt
    (*
     (* 2.0 n)
     (* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
   (pow
    (*
     2.0
     (+
      (* n (* U t))
      (/ (+ (* l -2.0) (/ (* (- U* U) (* n l)) Om)) (/ Om (* n (* U l))))))
    0.5)))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 6.5e+68) {
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else {
		tmp = pow((2.0 * ((n * (U * t)) + (((l * -2.0) + (((U_42_ - U) * (n * l)) / Om)) / (Om / (n * (U * l)))))), 0.5);
	}
	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+68) then
        tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
    else
        tmp = (2.0d0 * ((n * (u * t)) + (((l * (-2.0d0)) + (((u_42 - u) * (n * l)) / om)) / (om / (n * (u * l)))))) ** 0.5d0
    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+68) {
		tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else {
		tmp = Math.pow((2.0 * ((n * (U * t)) + (((l * -2.0) + (((U_42_ - U) * (n * l)) / Om)) / (Om / (n * (U * l)))))), 0.5);
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 6.5e+68:
		tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))))
	else:
		tmp = math.pow((2.0 * ((n * (U * t)) + (((l * -2.0) + (((U_42_ - U) * (n * l)) / Om)) / (Om / (n * (U * l)))))), 0.5)
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 6.5e+68)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om)))));
	else
		tmp = Float64(2.0 * Float64(Float64(n * Float64(U * t)) + Float64(Float64(Float64(l * -2.0) + Float64(Float64(Float64(U_42_ - U) * Float64(n * l)) / Om)) / Float64(Om / Float64(n * Float64(U * l)))))) ^ 0.5;
	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+68)
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	else
		tmp = (2.0 * ((n * (U * t)) + (((l * -2.0) + (((U_42_ - U) * (n * l)) / Om)) / (Om / (n * (U * l)))))) ^ 0.5;
	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+68], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Power[N[(2.0 * N[(N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(l * -2.0), $MachinePrecision] + N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(n * l), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] / N[(Om / N[(n * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 6.5 \cdot 10^{+68}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\

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


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

    1. Initial program 56.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. Simplified62.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 64.3%

      \[\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 6.5000000000000005e68 < l

    1. Initial program 19.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. Simplified47.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 52.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}}} \]
    4. Step-by-step derivation
      1. pow1/252.5%

        \[\leadsto \color{blue}{{\left(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}\right)}^{0.5}} \]
      2. distribute-lft-out52.5%

        \[\leadsto {\color{blue}{\left(2 \cdot \left(n \cdot \left(t \cdot U\right) + \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}\right)\right)}}^{0.5} \]
      3. associate-/l*52.5%

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

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

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

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

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

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

Alternative 8: 57.4% accurate, 1.7× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} t_1 := \ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\\ \mathbf{if}\;\ell \leq 1.06 \cdot 10^{+76}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot t_1}{Om}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right) + 2 \cdot \frac{t_1 \cdot \left(n \cdot \left(U \cdot \ell\right)\right)}{Om}}\\ \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 -2.0) (/ (* n (* l U*)) Om))))
   (if (<= l 1.06e+76)
     (sqrt (* (* 2.0 n) (* U (+ t (/ (* l t_1) Om)))))
     (sqrt (+ (* 2.0 (* n (* U t))) (* 2.0 (/ (* t_1 (* n (* U l))) Om)))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double t_1 = (l * -2.0) + ((n * (l * U_42_)) / Om);
	double tmp;
	if (l <= 1.06e+76) {
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * t_1) / Om)))));
	} else {
		tmp = sqrt(((2.0 * (n * (U * t))) + (2.0 * ((t_1 * (n * (U * l))) / 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 = (l * (-2.0d0)) + ((n * (l * u_42)) / om)
    if (l <= 1.06d+76) then
        tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * t_1) / om)))))
    else
        tmp = sqrt(((2.0d0 * (n * (u * t))) + (2.0d0 * ((t_1 * (n * (u * l))) / 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 = (l * -2.0) + ((n * (l * U_42_)) / Om);
	double tmp;
	if (l <= 1.06e+76) {
		tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * t_1) / Om)))));
	} else {
		tmp = Math.sqrt(((2.0 * (n * (U * t))) + (2.0 * ((t_1 * (n * (U * l))) / Om))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	t_1 = (l * -2.0) + ((n * (l * U_42_)) / Om)
	tmp = 0
	if l <= 1.06e+76:
		tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * t_1) / Om)))))
	else:
		tmp = math.sqrt(((2.0 * (n * (U * t))) + (2.0 * ((t_1 * (n * (U * l))) / Om))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	t_1 = Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))
	tmp = 0.0
	if (l <= 1.06e+76)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * t_1) / Om)))));
	else
		tmp = sqrt(Float64(Float64(2.0 * Float64(n * Float64(U * t))) + Float64(2.0 * Float64(Float64(t_1 * Float64(n * Float64(U * l))) / Om))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	t_1 = (l * -2.0) + ((n * (l * U_42_)) / Om);
	tmp = 0.0;
	if (l <= 1.06e+76)
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * t_1) / Om)))));
	else
		tmp = sqrt(((2.0 * (n * (U * t))) + (2.0 * ((t_1 * (n * (U * l))) / 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[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[l, 1.06e+76], 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], N[Sqrt[N[(N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(2.0 * N[(N[(t$95$1 * N[(n * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
t_1 := \ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\\
\mathbf{if}\;\ell \leq 1.06 \cdot 10^{+76}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot t_1}{Om}\right)\right)}\\

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


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

    1. Initial program 56.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. Simplified62.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 64.3%

      \[\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.06e76 < l

    1. Initial program 19.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. Simplified47.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 52.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}}} \]
    4. Taylor expanded in U* around inf 52.3%

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

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

Alternative 9: 49.4% accurate, 1.7× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 3 \cdot 10^{-150}:\\ \;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\ \mathbf{elif}\;\ell \leq 8.2 \cdot 10^{+68}:\\ \;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\ \mathbf{elif}\;\ell \leq 5 \cdot 10^{+140}:\\ \;\;\;\;\sqrt{-2 \cdot \left(\left(n \cdot \left(U \cdot \left(\ell \cdot \ell\right)\right)\right) \cdot \left(\frac{2}{Om} + \frac{n}{\frac{Om \cdot Om}{U - U*}}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\left(2 - \frac{n}{\frac{Om}{U* - U}}\right) \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 3e-150)
   (sqrt (* 2.0 (* U (* n t))))
   (if (<= l 8.2e+68)
     (sqrt (* (* (* 2.0 n) U) (+ t (* -2.0 (* l (/ l Om))))))
     (if (<= l 5e+140)
       (sqrt
        (*
         -2.0
         (* (* n (* U (* l l))) (+ (/ 2.0 Om) (/ n (/ (* Om Om) (- U U*)))))))
       (sqrt
        (*
         -2.0
         (/ n (/ Om (* (- 2.0 (/ n (/ Om (- U* U)))) (* 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 <= 3e-150) {
		tmp = sqrt((2.0 * (U * (n * t))));
	} else if (l <= 8.2e+68) {
		tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	} else if (l <= 5e+140) {
		tmp = sqrt((-2.0 * ((n * (U * (l * l))) * ((2.0 / Om) + (n / ((Om * Om) / (U - U_42_)))))));
	} else {
		tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (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 <= 3d-150) then
        tmp = sqrt((2.0d0 * (u * (n * t))))
    else if (l <= 8.2d+68) then
        tmp = sqrt((((2.0d0 * n) * u) * (t + ((-2.0d0) * (l * (l / om))))))
    else if (l <= 5d+140) then
        tmp = sqrt(((-2.0d0) * ((n * (u * (l * l))) * ((2.0d0 / om) + (n / ((om * om) / (u - u_42)))))))
    else
        tmp = sqrt(((-2.0d0) * (n / (om / ((2.0d0 - (n / (om / (u_42 - u)))) * (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 <= 3e-150) {
		tmp = Math.sqrt((2.0 * (U * (n * t))));
	} else if (l <= 8.2e+68) {
		tmp = Math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	} else if (l <= 5e+140) {
		tmp = Math.sqrt((-2.0 * ((n * (U * (l * l))) * ((2.0 / Om) + (n / ((Om * Om) / (U - U_42_)))))));
	} else {
		tmp = Math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 3e-150:
		tmp = math.sqrt((2.0 * (U * (n * t))))
	elif l <= 8.2e+68:
		tmp = math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))))
	elif l <= 5e+140:
		tmp = math.sqrt((-2.0 * ((n * (U * (l * l))) * ((2.0 / Om) + (n / ((Om * Om) / (U - U_42_)))))))
	else:
		tmp = math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 3e-150)
		tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t))));
	elseif (l <= 8.2e+68)
		tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om))))));
	elseif (l <= 5e+140)
		tmp = sqrt(Float64(-2.0 * Float64(Float64(n * Float64(U * Float64(l * l))) * Float64(Float64(2.0 / Om) + Float64(n / Float64(Float64(Om * Om) / Float64(U - U_42_)))))));
	else
		tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(Float64(2.0 - Float64(n / Float64(Om / Float64(U_42_ - U)))) * 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 <= 3e-150)
		tmp = sqrt((2.0 * (U * (n * t))));
	elseif (l <= 8.2e+68)
		tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	elseif (l <= 5e+140)
		tmp = sqrt((-2.0 * ((n * (U * (l * l))) * ((2.0 / Om) + (n / ((Om * Om) / (U - U_42_)))))));
	else
		tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (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, 3e-150], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 8.2e+68], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 5e+140], N[Sqrt[N[(-2.0 * N[(N[(n * N[(U * N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(2.0 / Om), $MachinePrecision] + N[(n / N[(N[(Om * Om), $MachinePrecision] / N[(U - U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(N[(2.0 - N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * 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 \cdot 10^{-150}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if l < 3.0000000000000002e-150

    1. Initial program 54.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. Simplified61.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. distribute-rgt-in61.0%

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

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

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

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

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

    if 3.0000000000000002e-150 < l < 8.1999999999999998e68

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

      \[\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. unpow261.0%

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

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

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

    if 8.1999999999999998e68 < l < 5.00000000000000008e140

    1. Initial program 56.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. Taylor expanded in l around inf 55.5%

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

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

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

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

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

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

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

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

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

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

    if 5.00000000000000008e140 < l

    1. Initial program 5.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. Simplified40.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. distribute-rgt-in40.8%

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

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

      \[\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}}} \]
    6. Step-by-step derivation
      1. associate-/l*27.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. associate-*r*27.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 3 \cdot 10^{-150}:\\ \;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\ \mathbf{elif}\;\ell \leq 8.2 \cdot 10^{+68}:\\ \;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\ \mathbf{elif}\;\ell \leq 5 \cdot 10^{+140}:\\ \;\;\;\;\sqrt{-2 \cdot \left(\left(n \cdot \left(U \cdot \left(\ell \cdot \ell\right)\right)\right) \cdot \left(\frac{2}{Om} + \frac{n}{\frac{Om \cdot Om}{U - U*}}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\left(2 - \frac{n}{\frac{Om}{U* - U}}\right) \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)}}}\\ \end{array} \]

Alternative 10: 47.6% accurate, 1.8× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 3.4 \cdot 10^{-149}:\\ \;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\ \mathbf{elif}\;\ell \leq 0.48:\\ \;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\ \mathbf{elif}\;\ell \leq 4.1 \cdot 10^{+96}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + -2 \cdot \frac{\ell \cdot \ell}{\frac{Om}{U}}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\left(2 - \frac{n}{\frac{Om}{U* - U}}\right) \cdot \left(U \cdot \left(\ell \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.4e-149)
   (sqrt (* 2.0 (* U (* n t))))
   (if (<= l 0.48)
     (sqrt (* (* (* 2.0 n) U) (+ t (* -2.0 (* l (/ l Om))))))
     (if (<= l 4.1e+96)
       (sqrt (* (* 2.0 n) (+ (* U t) (* -2.0 (/ (* l l) (/ Om U))))))
       (sqrt
        (*
         -2.0
         (/ n (/ Om (* (- 2.0 (/ n (/ Om (- U* U)))) (* U (* l l)))))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double tmp;
	if (l <= 3.4e-149) {
		tmp = sqrt((2.0 * (U * (n * t))));
	} else if (l <= 0.48) {
		tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	} else if (l <= 4.1e+96) {
		tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
	} else {
		tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (U * (l * 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.4d-149) then
        tmp = sqrt((2.0d0 * (u * (n * t))))
    else if (l <= 0.48d0) then
        tmp = sqrt((((2.0d0 * n) * u) * (t + ((-2.0d0) * (l * (l / om))))))
    else if (l <= 4.1d+96) then
        tmp = sqrt(((2.0d0 * n) * ((u * t) + ((-2.0d0) * ((l * l) / (om / u))))))
    else
        tmp = sqrt(((-2.0d0) * (n / (om / ((2.0d0 - (n / (om / (u_42 - u)))) * (u * (l * 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.4e-149) {
		tmp = Math.sqrt((2.0 * (U * (n * t))));
	} else if (l <= 0.48) {
		tmp = Math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	} else if (l <= 4.1e+96) {
		tmp = Math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
	} else {
		tmp = Math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (U * (l * l)))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 3.4e-149:
		tmp = math.sqrt((2.0 * (U * (n * t))))
	elif l <= 0.48:
		tmp = math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))))
	elif l <= 4.1e+96:
		tmp = math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))))
	else:
		tmp = math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (U * (l * l)))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 3.4e-149)
		tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t))));
	elseif (l <= 0.48)
		tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om))))));
	elseif (l <= 4.1e+96)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(Float64(U * t) + Float64(-2.0 * Float64(Float64(l * l) / Float64(Om / U))))));
	else
		tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(Float64(2.0 - Float64(n / Float64(Om / Float64(U_42_ - U)))) * Float64(U * Float64(l * 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.4e-149)
		tmp = sqrt((2.0 * (U * (n * t))));
	elseif (l <= 0.48)
		tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	elseif (l <= 4.1e+96)
		tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
	else
		tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (U * (l * 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.4e-149], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 0.48], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 4.1e+96], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(N[(U * t), $MachinePrecision] + N[(-2.0 * N[(N[(l * l), $MachinePrecision] / N[(Om / U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(N[(2.0 - N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(U * N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 3.4 \cdot 10^{-149}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if l < 3.3999999999999999e-149

    1. Initial program 54.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. Simplified61.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. distribute-rgt-in61.0%

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

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

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

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

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

    if 3.3999999999999999e-149 < l < 0.47999999999999998

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

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

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

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

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

    if 0.47999999999999998 < l < 4.09999999999999998e96

    1. Initial program 69.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. Simplified80.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. Step-by-step derivation
      1. distribute-rgt-in80.4%

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

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

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

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

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

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

    if 4.09999999999999998e96 < l

    1. Initial program 13.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. Simplified42.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. Step-by-step derivation
      1. distribute-rgt-in42.7%

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

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

      \[\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}}} \]
    6. Step-by-step derivation
      1. associate-/l*34.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. associate-*r*34.7%

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

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

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

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

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

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

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

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

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

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

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

Alternative 11: 50.3% accurate, 1.8× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 6.5 \cdot 10^{-149}:\\ \;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\ \mathbf{elif}\;\ell \leq 1250:\\ \;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\ \mathbf{elif}\;\ell \leq 3.45 \cdot 10^{+96}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + -2 \cdot \frac{\ell \cdot \ell}{\frac{Om}{U}}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\left(2 - \frac{n}{\frac{Om}{U* - U}}\right) \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-149)
   (sqrt (* 2.0 (* U (* n t))))
   (if (<= l 1250.0)
     (sqrt (* (* (* 2.0 n) U) (+ t (* -2.0 (* l (/ l Om))))))
     (if (<= l 3.45e+96)
       (sqrt (* (* 2.0 n) (+ (* U t) (* -2.0 (/ (* l l) (/ Om U))))))
       (sqrt
        (*
         -2.0
         (/ n (/ Om (* (- 2.0 (/ n (/ Om (- U* U)))) (* 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-149) {
		tmp = sqrt((2.0 * (U * (n * t))));
	} else if (l <= 1250.0) {
		tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	} else if (l <= 3.45e+96) {
		tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
	} else {
		tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (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-149) then
        tmp = sqrt((2.0d0 * (u * (n * t))))
    else if (l <= 1250.0d0) then
        tmp = sqrt((((2.0d0 * n) * u) * (t + ((-2.0d0) * (l * (l / om))))))
    else if (l <= 3.45d+96) then
        tmp = sqrt(((2.0d0 * n) * ((u * t) + ((-2.0d0) * ((l * l) / (om / u))))))
    else
        tmp = sqrt(((-2.0d0) * (n / (om / ((2.0d0 - (n / (om / (u_42 - u)))) * (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-149) {
		tmp = Math.sqrt((2.0 * (U * (n * t))));
	} else if (l <= 1250.0) {
		tmp = Math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	} else if (l <= 3.45e+96) {
		tmp = Math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
	} else {
		tmp = Math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 6.5e-149:
		tmp = math.sqrt((2.0 * (U * (n * t))))
	elif l <= 1250.0:
		tmp = math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))))
	elif l <= 3.45e+96:
		tmp = math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))))
	else:
		tmp = math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 6.5e-149)
		tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t))));
	elseif (l <= 1250.0)
		tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om))))));
	elseif (l <= 3.45e+96)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(Float64(U * t) + Float64(-2.0 * Float64(Float64(l * l) / Float64(Om / U))))));
	else
		tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(Float64(2.0 - Float64(n / Float64(Om / Float64(U_42_ - U)))) * 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-149)
		tmp = sqrt((2.0 * (U * (n * t))));
	elseif (l <= 1250.0)
		tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	elseif (l <= 3.45e+96)
		tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
	else
		tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (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-149], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 1250.0], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 3.45e+96], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(N[(U * t), $MachinePrecision] + N[(-2.0 * N[(N[(l * l), $MachinePrecision] / N[(Om / U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(N[(2.0 - N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * 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^{-149}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if l < 6.50000000000000019e-149

    1. Initial program 54.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. Simplified61.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. distribute-rgt-in61.0%

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

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

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

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

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

    if 6.50000000000000019e-149 < l < 1250

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

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

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

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

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

    if 1250 < l < 3.44999999999999999e96

    1. Initial program 69.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. Simplified80.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. Step-by-step derivation
      1. distribute-rgt-in80.4%

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

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

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

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

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

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

    if 3.44999999999999999e96 < l

    1. Initial program 13.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. Simplified42.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. Step-by-step derivation
      1. distribute-rgt-in42.7%

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

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

      \[\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}}} \]
    6. Step-by-step derivation
      1. associate-/l*34.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. associate-*r*34.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 12: 50.1% accurate, 1.8× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} t_1 := 2 - \frac{n}{\frac{Om}{U* - U}}\\ \mathbf{if}\;\ell \leq 1.25 \cdot 10^{-149}:\\ \;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\ \mathbf{elif}\;\ell \leq 2.3 \cdot 10^{+69}:\\ \;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\ \mathbf{elif}\;\ell \leq 3.5 \cdot 10^{+141}:\\ \;\;\;\;\sqrt{\frac{-2 \cdot \left(\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot \left(U \cdot t_1\right)\right)}{Om}}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{t_1 \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
 (let* ((t_1 (- 2.0 (/ n (/ Om (- U* U))))))
   (if (<= l 1.25e-149)
     (sqrt (* 2.0 (* U (* n t))))
     (if (<= l 2.3e+69)
       (sqrt (* (* (* 2.0 n) U) (+ t (* -2.0 (* l (/ l Om))))))
       (if (<= l 3.5e+141)
         (sqrt (/ (* -2.0 (* (* n (* l l)) (* U t_1))) Om))
         (sqrt (* -2.0 (/ n (/ Om (* t_1 (* l (* U l))))))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double t_1 = 2.0 - (n / (Om / (U_42_ - U)));
	double tmp;
	if (l <= 1.25e-149) {
		tmp = sqrt((2.0 * (U * (n * t))));
	} else if (l <= 2.3e+69) {
		tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	} else if (l <= 3.5e+141) {
		tmp = sqrt(((-2.0 * ((n * (l * l)) * (U * t_1))) / Om));
	} else {
		tmp = sqrt((-2.0 * (n / (Om / (t_1 * (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) :: t_1
    real(8) :: tmp
    t_1 = 2.0d0 - (n / (om / (u_42 - u)))
    if (l <= 1.25d-149) then
        tmp = sqrt((2.0d0 * (u * (n * t))))
    else if (l <= 2.3d+69) then
        tmp = sqrt((((2.0d0 * n) * u) * (t + ((-2.0d0) * (l * (l / om))))))
    else if (l <= 3.5d+141) then
        tmp = sqrt((((-2.0d0) * ((n * (l * l)) * (u * t_1))) / om))
    else
        tmp = sqrt(((-2.0d0) * (n / (om / (t_1 * (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 t_1 = 2.0 - (n / (Om / (U_42_ - U)));
	double tmp;
	if (l <= 1.25e-149) {
		tmp = Math.sqrt((2.0 * (U * (n * t))));
	} else if (l <= 2.3e+69) {
		tmp = Math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	} else if (l <= 3.5e+141) {
		tmp = Math.sqrt(((-2.0 * ((n * (l * l)) * (U * t_1))) / Om));
	} else {
		tmp = Math.sqrt((-2.0 * (n / (Om / (t_1 * (l * (U * l)))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	t_1 = 2.0 - (n / (Om / (U_42_ - U)))
	tmp = 0
	if l <= 1.25e-149:
		tmp = math.sqrt((2.0 * (U * (n * t))))
	elif l <= 2.3e+69:
		tmp = math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))))
	elif l <= 3.5e+141:
		tmp = math.sqrt(((-2.0 * ((n * (l * l)) * (U * t_1))) / Om))
	else:
		tmp = math.sqrt((-2.0 * (n / (Om / (t_1 * (l * (U * l)))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	t_1 = Float64(2.0 - Float64(n / Float64(Om / Float64(U_42_ - U))))
	tmp = 0.0
	if (l <= 1.25e-149)
		tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t))));
	elseif (l <= 2.3e+69)
		tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om))))));
	elseif (l <= 3.5e+141)
		tmp = sqrt(Float64(Float64(-2.0 * Float64(Float64(n * Float64(l * l)) * Float64(U * t_1))) / Om));
	else
		tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(t_1 * Float64(l * Float64(U * l)))))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	t_1 = 2.0 - (n / (Om / (U_42_ - U)));
	tmp = 0.0;
	if (l <= 1.25e-149)
		tmp = sqrt((2.0 * (U * (n * t))));
	elseif (l <= 2.3e+69)
		tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	elseif (l <= 3.5e+141)
		tmp = sqrt(((-2.0 * ((n * (l * l)) * (U * t_1))) / Om));
	else
		tmp = sqrt((-2.0 * (n / (Om / (t_1 * (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$_] := Block[{t$95$1 = N[(2.0 - N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[l, 1.25e-149], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 2.3e+69], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 3.5e+141], N[Sqrt[N[(N[(-2.0 * N[(N[(n * N[(l * l), $MachinePrecision]), $MachinePrecision] * N[(U * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(t$95$1 * N[(l * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
t_1 := 2 - \frac{n}{\frac{Om}{U* - U}}\\
\mathbf{if}\;\ell \leq 1.25 \cdot 10^{-149}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if l < 1.24999999999999992e-149

    1. Initial program 54.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. Simplified61.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. distribute-rgt-in61.0%

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

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

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

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

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

    if 1.24999999999999992e-149 < l < 2.30000000000000017e69

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

      \[\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. unpow261.0%

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

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

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

    if 2.30000000000000017e69 < l < 3.5e141

    1. Initial program 56.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. Simplified65.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. Taylor expanded in l around -inf 56.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-*r/56.0%

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

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

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

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

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

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

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

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

    if 3.5e141 < l

    1. Initial program 5.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. Simplified40.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. distribute-rgt-in40.8%

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

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

      \[\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}}} \]
    6. Step-by-step derivation
      1. associate-/l*27.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. associate-*r*27.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 1.25 \cdot 10^{-149}:\\ \;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\ \mathbf{elif}\;\ell \leq 2.3 \cdot 10^{+69}:\\ \;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\ \mathbf{elif}\;\ell \leq 3.5 \cdot 10^{+141}:\\ \;\;\;\;\sqrt{\frac{-2 \cdot \left(\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot \left(U \cdot \left(2 - \frac{n}{\frac{Om}{U* - U}}\right)\right)\right)}{Om}}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\left(2 - \frac{n}{\frac{Om}{U* - U}}\right) \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)}}}\\ \end{array} \]

Alternative 13: 47.1% accurate, 1.8× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 3 \cdot 10^{-149}:\\ \;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\ \mathbf{elif}\;\ell \leq 1250:\\ \;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\ \mathbf{elif}\;\ell \leq 3 \cdot 10^{+96}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + -2 \cdot \frac{\ell \cdot \ell}{\frac{Om}{U}}\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{U \cdot \left(\left(\ell \cdot \ell\right) \cdot \left(2 - \frac{n}{\frac{Om}{U*}}\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 3e-149)
   (sqrt (* 2.0 (* U (* n t))))
   (if (<= l 1250.0)
     (sqrt (* (* (* 2.0 n) U) (+ t (* -2.0 (* l (/ l Om))))))
     (if (<= l 3e+96)
       (sqrt (* (* 2.0 n) (+ (* U t) (* -2.0 (/ (* l l) (/ Om U))))))
       (sqrt
        (* -2.0 (/ n (/ Om (* U (* (* l l) (- 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 <= 3e-149) {
		tmp = sqrt((2.0 * (U * (n * t))));
	} else if (l <= 1250.0) {
		tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	} else if (l <= 3e+96) {
		tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
	} else {
		tmp = sqrt((-2.0 * (n / (Om / (U * ((l * l) * (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 <= 3d-149) then
        tmp = sqrt((2.0d0 * (u * (n * t))))
    else if (l <= 1250.0d0) then
        tmp = sqrt((((2.0d0 * n) * u) * (t + ((-2.0d0) * (l * (l / om))))))
    else if (l <= 3d+96) then
        tmp = sqrt(((2.0d0 * n) * ((u * t) + ((-2.0d0) * ((l * l) / (om / u))))))
    else
        tmp = sqrt(((-2.0d0) * (n / (om / (u * ((l * l) * (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 <= 3e-149) {
		tmp = Math.sqrt((2.0 * (U * (n * t))));
	} else if (l <= 1250.0) {
		tmp = Math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	} else if (l <= 3e+96) {
		tmp = Math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
	} else {
		tmp = Math.sqrt((-2.0 * (n / (Om / (U * ((l * l) * (2.0 - (n / (Om / U_42_)))))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 3e-149:
		tmp = math.sqrt((2.0 * (U * (n * t))))
	elif l <= 1250.0:
		tmp = math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))))
	elif l <= 3e+96:
		tmp = math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))))
	else:
		tmp = math.sqrt((-2.0 * (n / (Om / (U * ((l * l) * (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 <= 3e-149)
		tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t))));
	elseif (l <= 1250.0)
		tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om))))));
	elseif (l <= 3e+96)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(Float64(U * t) + Float64(-2.0 * Float64(Float64(l * l) / Float64(Om / U))))));
	else
		tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(U * Float64(Float64(l * l) * 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 <= 3e-149)
		tmp = sqrt((2.0 * (U * (n * t))));
	elseif (l <= 1250.0)
		tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
	elseif (l <= 3e+96)
		tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
	else
		tmp = sqrt((-2.0 * (n / (Om / (U * ((l * l) * (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, 3e-149], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 1250.0], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 3e+96], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(N[(U * t), $MachinePrecision] + N[(-2.0 * N[(N[(l * l), $MachinePrecision] / N[(Om / U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(U * N[(N[(l * l), $MachinePrecision] * N[(2.0 - N[(n / N[(Om / U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 3 \cdot 10^{-149}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\

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

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if l < 3.0000000000000002e-149

    1. Initial program 54.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. Simplified61.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. distribute-rgt-in61.0%

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

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

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

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

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

    if 3.0000000000000002e-149 < l < 1250

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

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

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

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

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

    if 1250 < l < 3e96

    1. Initial program 69.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. Simplified80.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. Step-by-step derivation
      1. distribute-rgt-in80.4%

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

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

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

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

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

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

    if 3e96 < l

    1. Initial program 13.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. Simplified42.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. Step-by-step derivation
      1. distribute-rgt-in42.7%

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

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

      \[\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}}} \]
    6. Step-by-step derivation
      1. associate-/l*34.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. associate-*r*34.7%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 14: 56.4% accurate, 1.8× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} \mathbf{if}\;\ell \leq 3.5 \cdot 10^{+87}:\\ \;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\left(2 - \frac{n}{\frac{Om}{U* - U}}\right) \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.5e+87)
   (sqrt
    (*
     (* 2.0 n)
     (* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
   (sqrt
    (* -2.0 (/ n (/ Om (* (- 2.0 (/ n (/ Om (- U* U)))) (* 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.5e+87) {
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else {
		tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (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.5d+87) then
        tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
    else
        tmp = sqrt(((-2.0d0) * (n / (om / ((2.0d0 - (n / (om / (u_42 - u)))) * (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.5e+87) {
		tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	} else {
		tmp = Math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	tmp = 0
	if l <= 3.5e+87:
		tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))))
	else:
		tmp = math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	tmp = 0.0
	if (l <= 3.5e+87)
		tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om)))));
	else
		tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(Float64(2.0 - Float64(n / Float64(Om / Float64(U_42_ - U)))) * 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.5e+87)
		tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
	else
		tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (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.5e+87], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(N[(2.0 - N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * 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.5 \cdot 10^{+87}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\

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


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

    1. Initial program 56.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. Simplified62.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 U around 0 64.8%

      \[\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.49999999999999986e87 < l

    1. Initial program 15.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. Simplified43.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. Step-by-step derivation
      1. distribute-rgt-in43.2%

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

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

      \[\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}}} \]
    6. Step-by-step derivation
      1. associate-/l*33.0%

        \[\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. associate-*r*33.0%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

Alternative 15: 56.0% accurate, 1.8× speedup?

\[\begin{array}{l} l = |l|\\ \\ \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + \frac{\ell \cdot \left(U \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)\right)}{Om}\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) (/ (* l (* U (+ (* l -2.0) (/ (* n (* l U*)) Om)))) Om)))))
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) + ((l * (U * ((l * -2.0) + ((n * (l * U_42_)) / Om)))) / Om))));
}
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) + ((l * (u * ((l * (-2.0d0)) + ((n * (l * u_42)) / om)))) / om))))
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) + ((l * (U * ((l * -2.0) + ((n * (l * U_42_)) / Om)))) / Om))));
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	return math.sqrt(((2.0 * n) * ((U * t) + ((l * (U * ((l * -2.0) + ((n * (l * U_42_)) / Om)))) / Om))))
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	return sqrt(Float64(Float64(2.0 * n) * Float64(Float64(U * t) + Float64(Float64(l * Float64(U * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om)))) / Om))))
end
l = abs(l)
function tmp = code(n, U, t, l, Om, U_42_)
	tmp = sqrt(((2.0 * n) * ((U * t) + ((l * (U * ((l * -2.0) + ((n * (l * U_42_)) / Om)))) / Om))));
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(N[(U * t), $MachinePrecision] + N[(N[(l * N[(U * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
l = |l|\\
\\
\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + \frac{\ell \cdot \left(U \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)\right)}{Om}\right)}
\end{array}
Derivation
  1. Initial program 50.7%

    \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
  2. Simplified59.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. Step-by-step derivation
    1. distribute-rgt-in59.9%

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

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

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

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

Alternative 16: 47.0% accurate, 1.8× speedup?

\[\begin{array}{l} l = |l|\\ \\ \begin{array}{l} t_1 := t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\\ \mathbf{if}\;\ell \leq 9.2 \cdot 10^{-150}:\\ \;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\ \mathbf{elif}\;\ell \leq 3 \cdot 10^{-22}:\\ \;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot t_1}\\ \mathbf{elif}\;\ell \leq 3.25 \cdot 10^{+174}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t_1\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\frac{-n}{\frac{Om}{\left(\ell \cdot \ell\right) \cdot \left(U \cdot U*\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 (+ t (* -2.0 (* l (/ l Om))))))
   (if (<= l 9.2e-150)
     (sqrt (* 2.0 (* U (* n t))))
     (if (<= l 3e-22)
       (sqrt (* (* (* 2.0 n) U) t_1))
       (if (<= l 3.25e+174)
         (sqrt (* 2.0 (* n (* U t_1))))
         (sqrt
          (* -2.0 (/ n (/ Om (/ (- n) (/ Om (* (* l l) (* U U*)))))))))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double t_1 = t + (-2.0 * (l * (l / Om)));
	double tmp;
	if (l <= 9.2e-150) {
		tmp = sqrt((2.0 * (U * (n * t))));
	} else if (l <= 3e-22) {
		tmp = sqrt((((2.0 * n) * U) * t_1));
	} else if (l <= 3.25e+174) {
		tmp = sqrt((2.0 * (n * (U * t_1))));
	} else {
		tmp = sqrt((-2.0 * (n / (Om / (-n / (Om / ((l * l) * (U * 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) :: t_1
    real(8) :: tmp
    t_1 = t + ((-2.0d0) * (l * (l / om)))
    if (l <= 9.2d-150) then
        tmp = sqrt((2.0d0 * (u * (n * t))))
    else if (l <= 3d-22) then
        tmp = sqrt((((2.0d0 * n) * u) * t_1))
    else if (l <= 3.25d+174) then
        tmp = sqrt((2.0d0 * (n * (u * t_1))))
    else
        tmp = sqrt(((-2.0d0) * (n / (om / (-n / (om / ((l * l) * (u * 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 t_1 = t + (-2.0 * (l * (l / Om)));
	double tmp;
	if (l <= 9.2e-150) {
		tmp = Math.sqrt((2.0 * (U * (n * t))));
	} else if (l <= 3e-22) {
		tmp = Math.sqrt((((2.0 * n) * U) * t_1));
	} else if (l <= 3.25e+174) {
		tmp = Math.sqrt((2.0 * (n * (U * t_1))));
	} else {
		tmp = Math.sqrt((-2.0 * (n / (Om / (-n / (Om / ((l * l) * (U * U_42_))))))));
	}
	return tmp;
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	t_1 = t + (-2.0 * (l * (l / Om)))
	tmp = 0
	if l <= 9.2e-150:
		tmp = math.sqrt((2.0 * (U * (n * t))))
	elif l <= 3e-22:
		tmp = math.sqrt((((2.0 * n) * U) * t_1))
	elif l <= 3.25e+174:
		tmp = math.sqrt((2.0 * (n * (U * t_1))))
	else:
		tmp = math.sqrt((-2.0 * (n / (Om / (-n / (Om / ((l * l) * (U * U_42_))))))))
	return tmp
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	t_1 = Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om))))
	tmp = 0.0
	if (l <= 9.2e-150)
		tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t))));
	elseif (l <= 3e-22)
		tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * t_1));
	elseif (l <= 3.25e+174)
		tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * t_1))));
	else
		tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(Float64(-n) / Float64(Om / Float64(Float64(l * l) * Float64(U * U_42_))))))));
	end
	return tmp
end
l = abs(l)
function tmp_2 = code(n, U, t, l, Om, U_42_)
	t_1 = t + (-2.0 * (l * (l / Om)));
	tmp = 0.0;
	if (l <= 9.2e-150)
		tmp = sqrt((2.0 * (U * (n * t))));
	elseif (l <= 3e-22)
		tmp = sqrt((((2.0 * n) * U) * t_1));
	elseif (l <= 3.25e+174)
		tmp = sqrt((2.0 * (n * (U * t_1))));
	else
		tmp = sqrt((-2.0 * (n / (Om / (-n / (Om / ((l * l) * (U * U_42_))))))));
	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[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[l, 9.2e-150], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 3e-22], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * t$95$1), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 3.25e+174], N[Sqrt[N[(2.0 * N[(n * N[(U * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[((-n) / N[(Om / N[(N[(l * l), $MachinePrecision] * N[(U * U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
t_1 := t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\\
\mathbf{if}\;\ell \leq 9.2 \cdot 10^{-150}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\

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

\mathbf{elif}\;\ell \leq 3.25 \cdot 10^{+174}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t_1\right)\right)}\\

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


\end{array}
\end{array}
Derivation
  1. Split input into 4 regimes
  2. if l < 9.20000000000000011e-150

    1. Initial program 54.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. Simplified61.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. distribute-rgt-in61.0%

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

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

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

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

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

    if 9.20000000000000011e-150 < l < 2.9999999999999999e-22

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

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

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

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

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

    if 2.9999999999999999e-22 < l < 3.2500000000000001e174

    1. Initial program 49.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. Simplified64.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 n around 0 45.5%

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

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

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

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

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

    if 3.2500000000000001e174 < l

    1. Initial program 6.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. Simplified37.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. distribute-rgt-in37.6%

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

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

      \[\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}}} \]
    6. Step-by-step derivation
      1. associate-/l*33.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. associate-*r*33.8%

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

    \[\leadsto \begin{array}{l} \mathbf{if}\;\ell \leq 9.2 \cdot 10^{-150}:\\ \;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\ \mathbf{elif}\;\ell \leq 3 \cdot 10^{-22}:\\ \;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\ \mathbf{elif}\;\ell \leq 3.25 \cdot 10^{+174}:\\ \;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)\right)\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\frac{-n}{\frac{Om}{\left(\ell \cdot \ell\right) \cdot \left(U \cdot U*\right)}}}}}\\ \end{array} \]

Alternative 17: 45.9% accurate, 1.9× speedup?

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < 8.5e11

    1. Initial program 49.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. 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 n around 0 42.8%

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

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

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

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

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

    if 8.5e11 < t

    1. Initial program 54.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. Simplified64.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. distribute-rgt-in64.5%

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

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

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

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

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

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

Alternative 18: 45.8% accurate, 1.9× speedup?

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

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


\end{array}
\end{array}
Derivation
  1. Split input into 2 regimes
  2. if t < 4.49999999999999979e23

    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. Taylor expanded in Om around inf 43.0%

      \[\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. unpow243.0%

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

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

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

    if 4.49999999999999979e23 < t

    1. Initial program 52.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. Simplified64.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 t around inf 62.9%

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

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

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

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

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

Alternative 19: 36.3% accurate, 2.1× speedup?

\[\begin{array}{l} l = |l|\\ \\ {\left(2 \cdot \left(n \cdot \left(U \cdot t\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 (* n (* U t))) 0.5))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	return pow((2.0 * (n * (U * t))), 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 * (n * (u * t))) ** 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 * (n * (U * t))), 0.5);
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	return math.pow((2.0 * (n * (U * t))), 0.5)
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	return Float64(2.0 * Float64(n * Float64(U * t))) ^ 0.5
end
l = abs(l)
function tmp = code(n, U, t, l, Om, U_42_)
	tmp = (2.0 * (n * (U * t))) ^ 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[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]
\begin{array}{l}
l = |l|\\
\\
{\left(2 \cdot \left(n \cdot \left(U \cdot t\right)\right)\right)}^{0.5}
\end{array}
Derivation
  1. Initial program 50.7%

    \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
  2. Simplified59.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 42.2%

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

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

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

    \[\leadsto \color{blue}{{\left(2 \cdot \left(n \cdot \left(t \cdot U\right)\right)\right)}^{0.5}} \]
  6. Final simplification42.2%

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

Alternative 20: 35.7% accurate, 2.1× speedup?

\[\begin{array}{l} l = |l|\\ \\ \sqrt{2 \cdot \left(U \cdot \left(n \cdot t\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 (* U (* n t)))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
	return sqrt((2.0 * (U * (n * t))));
}
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 * (u * (n * t))))
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 * (U * (n * t))));
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	return math.sqrt((2.0 * (U * (n * t))))
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	return sqrt(Float64(2.0 * Float64(U * Float64(n * t))))
end
l = abs(l)
function tmp = code(n, U, t, l, Om, U_42_)
	tmp = sqrt((2.0 * (U * (n * t))));
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
l = |l|\\
\\
\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}
\end{array}
Derivation
  1. Initial program 50.7%

    \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
  2. Simplified59.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. Step-by-step derivation
    1. distribute-rgt-in59.9%

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

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

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

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

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

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

Alternative 21: 34.8% accurate, 2.1× speedup?

\[\begin{array}{l} l = |l|\\ \\ \sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t\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))))
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)));
}
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)))
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)));
}
l = abs(l)
def code(n, U, t, l, Om, U_42_):
	return math.sqrt(((2.0 * n) * (U * t)))
l = abs(l)
function code(n, U, t, l, Om, U_42_)
	return sqrt(Float64(Float64(2.0 * n) * Float64(U * t)))
end
l = abs(l)
function tmp = code(n, U, t, l, Om, U_42_)
	tmp = sqrt(((2.0 * n) * (U * t)));
end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
l = |l|\\
\\
\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t\right)}
\end{array}
Derivation
  1. Initial program 50.7%

    \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
  2. Simplified59.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 42.2%

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

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

Reproduce

?
herbie shell --seed 2023230 
(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*))))))