Toniolo and Linder, Equation (13)

Percentage Accurate: 50.3% → 64.1%
Time: 17.5s
Alternatives: 20
Speedup: 2.0×

Specification

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

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

Sampling outcomes in binary64 precision:

Local Percentage Accuracy vs ?

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

Accuracy vs Speed?

Herbie found 20 alternatives:

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

Initial Program: 50.3% 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: 64.1% accurate, 0.4× speedup?

\[\begin{array}{l} \\ \begin{array}{l} t_1 := {\left(\frac{\ell}{Om}\right)}^{2}\\ t_2 := U \cdot \left(n \cdot 2\right)\\ t_3 := \frac{\ell \cdot \ell}{Om}\\ t_4 := \mathsf{fma}\left(-2, t\_3, t\right)\\ t_5 := \sqrt{\left(\left(U* - U\right) \cdot \left(t\_1 \cdot n\right) - \left(t\_3 \cdot 2 - t\right)\right) \cdot t\_2}\\ \mathbf{if}\;t\_5 \leq 10^{-160}:\\ \;\;\;\;\sqrt{U} \cdot \sqrt{\left(t\_4 - \left(\left(U - U*\right) \cdot n\right) \cdot t\_1\right) \cdot \left(n \cdot 2\right)}\\ \mathbf{elif}\;t\_5 \leq 2 \cdot 10^{+137}:\\ \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{\ell}{Om} \cdot n\right) \cdot \left(U* - U\right), \frac{\ell}{Om}, t\_4\right) \cdot t\_2}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\left(\left(-2 \cdot U\right) \cdot \ell\right) \cdot \frac{\mathsf{fma}\left(\frac{n}{Om}, U - U*, 2\right)}{Om}\right) \cdot n, \ell, \left(\left(t \cdot n\right) \cdot 2\right) \cdot U\right)}\\ \end{array} \end{array} \]
(FPCore (n U t l Om U*)
 :precision binary64
 (let* ((t_1 (pow (/ l Om) 2.0))
        (t_2 (* U (* n 2.0)))
        (t_3 (/ (* l l) Om))
        (t_4 (fma -2.0 t_3 t))
        (t_5 (sqrt (* (- (* (- U* U) (* t_1 n)) (- (* t_3 2.0) t)) t_2))))
   (if (<= t_5 1e-160)
     (* (sqrt U) (sqrt (* (- t_4 (* (* (- U U*) n) t_1)) (* n 2.0))))
     (if (<= t_5 2e+137)
       (sqrt (* (fma (* (* (/ l Om) n) (- U* U)) (/ l Om) t_4) t_2))
       (sqrt
        (fma
         (* (* (* (* -2.0 U) l) (/ (fma (/ n Om) (- U U*) 2.0) Om)) n)
         l
         (* (* (* t n) 2.0) U)))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
	double t_1 = pow((l / Om), 2.0);
	double t_2 = U * (n * 2.0);
	double t_3 = (l * l) / Om;
	double t_4 = fma(-2.0, t_3, t);
	double t_5 = sqrt(((((U_42_ - U) * (t_1 * n)) - ((t_3 * 2.0) - t)) * t_2));
	double tmp;
	if (t_5 <= 1e-160) {
		tmp = sqrt(U) * sqrt(((t_4 - (((U - U_42_) * n) * t_1)) * (n * 2.0)));
	} else if (t_5 <= 2e+137) {
		tmp = sqrt((fma((((l / Om) * n) * (U_42_ - U)), (l / Om), t_4) * t_2));
	} else {
		tmp = sqrt(fma(((((-2.0 * U) * l) * (fma((n / Om), (U - U_42_), 2.0) / Om)) * n), l, (((t * n) * 2.0) * U)));
	}
	return tmp;
}
function code(n, U, t, l, Om, U_42_)
	t_1 = Float64(l / Om) ^ 2.0
	t_2 = Float64(U * Float64(n * 2.0))
	t_3 = Float64(Float64(l * l) / Om)
	t_4 = fma(-2.0, t_3, t)
	t_5 = sqrt(Float64(Float64(Float64(Float64(U_42_ - U) * Float64(t_1 * n)) - Float64(Float64(t_3 * 2.0) - t)) * t_2))
	tmp = 0.0
	if (t_5 <= 1e-160)
		tmp = Float64(sqrt(U) * sqrt(Float64(Float64(t_4 - Float64(Float64(Float64(U - U_42_) * n) * t_1)) * Float64(n * 2.0))));
	elseif (t_5 <= 2e+137)
		tmp = sqrt(Float64(fma(Float64(Float64(Float64(l / Om) * n) * Float64(U_42_ - U)), Float64(l / Om), t_4) * t_2));
	else
		tmp = sqrt(fma(Float64(Float64(Float64(Float64(-2.0 * U) * l) * Float64(fma(Float64(n / Om), Float64(U - U_42_), 2.0) / Om)) * n), l, Float64(Float64(Float64(t * n) * 2.0) * U)));
	end
	return tmp
end
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]}, Block[{t$95$2 = N[(U * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]}, Block[{t$95$4 = N[(-2.0 * t$95$3 + t), $MachinePrecision]}, Block[{t$95$5 = N[Sqrt[N[(N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(t$95$1 * n), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$3 * 2.0), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] * t$95$2), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$5, 1e-160], N[(N[Sqrt[U], $MachinePrecision] * N[Sqrt[N[(N[(t$95$4 - N[(N[(N[(U - U$42$), $MachinePrecision] * n), $MachinePrecision] * t$95$1), $MachinePrecision]), $MachinePrecision] * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$5, 2e+137], N[Sqrt[N[(N[(N[(N[(N[(l / Om), $MachinePrecision] * n), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision] * N[(l / Om), $MachinePrecision] + t$95$4), $MachinePrecision] * t$95$2), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(N[(N[(-2.0 * U), $MachinePrecision] * l), $MachinePrecision] * N[(N[(N[(n / Om), $MachinePrecision] * N[(U - U$42$), $MachinePrecision] + 2.0), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] * n), $MachinePrecision] * l + N[(N[(N[(t * n), $MachinePrecision] * 2.0), $MachinePrecision] * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]]]]
\begin{array}{l}

\\
\begin{array}{l}
t_1 := {\left(\frac{\ell}{Om}\right)}^{2}\\
t_2 := U \cdot \left(n \cdot 2\right)\\
t_3 := \frac{\ell \cdot \ell}{Om}\\
t_4 := \mathsf{fma}\left(-2, t\_3, t\right)\\
t_5 := \sqrt{\left(\left(U* - U\right) \cdot \left(t\_1 \cdot n\right) - \left(t\_3 \cdot 2 - t\right)\right) \cdot t\_2}\\
\mathbf{if}\;t\_5 \leq 10^{-160}:\\
\;\;\;\;\sqrt{U} \cdot \sqrt{\left(t\_4 - \left(\left(U - U*\right) \cdot n\right) \cdot t\_1\right) \cdot \left(n \cdot 2\right)}\\

\mathbf{elif}\;t\_5 \leq 2 \cdot 10^{+137}:\\
\;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{\ell}{Om} \cdot n\right) \cdot \left(U* - U\right), \frac{\ell}{Om}, t\_4\right) \cdot t\_2}\\

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


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

    1. Initial program 9.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. Add Preprocessing
    3. Step-by-step derivation
      1. lift-sqrt.f64N/A

        \[\leadsto \color{blue}{\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. lift-*.f64N/A

        \[\leadsto \sqrt{\color{blue}{\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)}} \]
      3. *-commutativeN/A

        \[\leadsto \sqrt{\color{blue}{\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) \cdot \left(\left(2 \cdot n\right) \cdot U\right)}} \]
      4. lift-*.f64N/A

        \[\leadsto \sqrt{\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) \cdot \color{blue}{\left(\left(2 \cdot n\right) \cdot U\right)}} \]
      5. associate-*r*N/A

        \[\leadsto \sqrt{\color{blue}{\left(\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) \cdot \left(2 \cdot n\right)\right) \cdot U}} \]
      6. sqrt-prodN/A

        \[\leadsto \color{blue}{\sqrt{\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) \cdot \left(2 \cdot n\right)} \cdot \sqrt{U}} \]
      7. pow1/2N/A

        \[\leadsto \sqrt{\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) \cdot \left(2 \cdot n\right)} \cdot \color{blue}{{U}^{\frac{1}{2}}} \]
      8. lower-*.f64N/A

        \[\leadsto \color{blue}{\sqrt{\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) \cdot \left(2 \cdot n\right)} \cdot {U}^{\frac{1}{2}}} \]
    4. Applied rewrites45.4%

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

    if 9.9999999999999999e-161 < (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) < 2.0000000000000001e137

    1. Initial program 95.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. Add Preprocessing
    3. Step-by-step derivation
      1. lift--.f64N/A

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

        \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \color{blue}{\left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) + \left(\mathsf{neg}\left(\left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right)\right)}} \]
      3. +-commutativeN/A

        \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \color{blue}{\left(\left(\mathsf{neg}\left(\left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right) + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)}} \]
      4. lift-*.f64N/A

        \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(\mathsf{neg}\left(\color{blue}{\left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)}\right)\right) + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)} \]
      5. *-commutativeN/A

        \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(\mathsf{neg}\left(\color{blue}{\left(U - U*\right) \cdot \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right)}\right)\right) + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)} \]
      6. distribute-lft-neg-inN/A

        \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\color{blue}{\left(\mathsf{neg}\left(\left(U - U*\right)\right)\right) \cdot \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right)} + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)} \]
      7. lift-*.f64N/A

        \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(\mathsf{neg}\left(\left(U - U*\right)\right)\right) \cdot \color{blue}{\left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right)} + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)} \]
      8. lift-pow.f64N/A

        \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(\mathsf{neg}\left(\left(U - U*\right)\right)\right) \cdot \left(n \cdot \color{blue}{{\left(\frac{\ell}{Om}\right)}^{2}}\right) + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)} \]
      9. unpow2N/A

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

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

        \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\color{blue}{\left(\left(\mathsf{neg}\left(\left(U - U*\right)\right)\right) \cdot \left(n \cdot \frac{\ell}{Om}\right)\right) \cdot \frac{\ell}{Om}} + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)} \]
      12. lower-fma.f64N/A

        \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \color{blue}{\mathsf{fma}\left(\left(\mathsf{neg}\left(\left(U - U*\right)\right)\right) \cdot \left(n \cdot \frac{\ell}{Om}\right), \frac{\ell}{Om}, t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)}} \]
      13. lower-*.f64N/A

        \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \mathsf{fma}\left(\color{blue}{\left(\mathsf{neg}\left(\left(U - U*\right)\right)\right) \cdot \left(n \cdot \frac{\ell}{Om}\right)}, \frac{\ell}{Om}, t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)} \]
      14. lower-neg.f64N/A

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

        \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \mathsf{fma}\left(\left(-\left(U - U*\right)\right) \cdot \color{blue}{\left(n \cdot \frac{\ell}{Om}\right)}, \frac{\ell}{Om}, t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)} \]
      16. lift--.f64N/A

        \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \mathsf{fma}\left(\left(-\left(U - U*\right)\right) \cdot \left(n \cdot \frac{\ell}{Om}\right), \frac{\ell}{Om}, \color{blue}{t - 2 \cdot \frac{\ell \cdot \ell}{Om}}\right)} \]
      17. sub-negN/A

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

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

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

    1. Initial program 20.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. Add Preprocessing
    3. Taylor expanded in t around 0

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

        \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
      2. lower-fma.f64N/A

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

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

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

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

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

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

        Alternative 2: 55.6% accurate, 0.3× speedup?

        \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{\ell \cdot \ell}{Om}\\ t_2 := U \cdot \left(n \cdot 2\right)\\ t_3 := \left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_1 \cdot 2 - t\right)\right) \cdot t\_2\\ \mathbf{if}\;t\_3 \leq 10^{-320}:\\ \;\;\;\;\left(\sqrt{\mathsf{fma}\left(-2, t\_1, t\right) \cdot n} \cdot \sqrt{U}\right) \cdot \sqrt{2}\\ \mathbf{elif}\;t\_3 \leq 5 \cdot 10^{+274}:\\ \;\;\;\;\sqrt{\left(t - \frac{\mathsf{fma}\left(U - U*, \frac{n}{Om}, 2\right) \cdot \left(\ell \cdot \ell\right)}{Om}\right) \cdot t\_2}\\ \mathbf{elif}\;t\_3 \leq \infty:\\ \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{2}{Om} \cdot \ell\right) \cdot \left(\left(-2 \cdot U\right) \cdot \ell\right), n, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\left(\frac{\ell \cdot n}{Om} \cdot \frac{\left(\left(U* \cdot U\right) \cdot \ell\right) \cdot n}{Om}\right) \cdot 2}\\ \end{array} \end{array} \]
        (FPCore (n U t l Om U*)
         :precision binary64
         (let* ((t_1 (/ (* l l) Om))
                (t_2 (* U (* n 2.0)))
                (t_3
                 (* (- (* (- U* U) (* (pow (/ l Om) 2.0) n)) (- (* t_1 2.0) t)) t_2)))
           (if (<= t_3 1e-320)
             (* (* (sqrt (* (fma -2.0 t_1 t) n)) (sqrt U)) (sqrt 2.0))
             (if (<= t_3 5e+274)
               (sqrt (* (- t (/ (* (fma (- U U*) (/ n Om) 2.0) (* l l)) Om)) t_2))
               (if (<= t_3 INFINITY)
                 (sqrt
                  (fma (* (* (/ 2.0 Om) l) (* (* -2.0 U) l)) n (* (* (* t n) U) 2.0)))
                 (sqrt (* (* (/ (* l n) Om) (/ (* (* (* U* U) l) n) Om)) 2.0)))))))
        double code(double n, double U, double t, double l, double Om, double U_42_) {
        	double t_1 = (l * l) / Om;
        	double t_2 = U * (n * 2.0);
        	double t_3 = (((U_42_ - U) * (pow((l / Om), 2.0) * n)) - ((t_1 * 2.0) - t)) * t_2;
        	double tmp;
        	if (t_3 <= 1e-320) {
        		tmp = (sqrt((fma(-2.0, t_1, t) * n)) * sqrt(U)) * sqrt(2.0);
        	} else if (t_3 <= 5e+274) {
        		tmp = sqrt(((t - ((fma((U - U_42_), (n / Om), 2.0) * (l * l)) / Om)) * t_2));
        	} else if (t_3 <= ((double) INFINITY)) {
        		tmp = sqrt(fma((((2.0 / Om) * l) * ((-2.0 * U) * l)), n, (((t * n) * U) * 2.0)));
        	} else {
        		tmp = sqrt(((((l * n) / Om) * ((((U_42_ * U) * l) * n) / Om)) * 2.0));
        	}
        	return tmp;
        }
        
        function code(n, U, t, l, Om, U_42_)
        	t_1 = Float64(Float64(l * l) / Om)
        	t_2 = Float64(U * Float64(n * 2.0))
        	t_3 = Float64(Float64(Float64(Float64(U_42_ - U) * Float64((Float64(l / Om) ^ 2.0) * n)) - Float64(Float64(t_1 * 2.0) - t)) * t_2)
        	tmp = 0.0
        	if (t_3 <= 1e-320)
        		tmp = Float64(Float64(sqrt(Float64(fma(-2.0, t_1, t) * n)) * sqrt(U)) * sqrt(2.0));
        	elseif (t_3 <= 5e+274)
        		tmp = sqrt(Float64(Float64(t - Float64(Float64(fma(Float64(U - U_42_), Float64(n / Om), 2.0) * Float64(l * l)) / Om)) * t_2));
        	elseif (t_3 <= Inf)
        		tmp = sqrt(fma(Float64(Float64(Float64(2.0 / Om) * l) * Float64(Float64(-2.0 * U) * l)), n, Float64(Float64(Float64(t * n) * U) * 2.0)));
        	else
        		tmp = sqrt(Float64(Float64(Float64(Float64(l * n) / Om) * Float64(Float64(Float64(Float64(U_42_ * U) * l) * n) / Om)) * 2.0));
        	end
        	return tmp
        end
        
        code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]}, Block[{t$95$2 = N[(U * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$3 = N[(N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision] * n), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$1 * 2.0), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] * t$95$2), $MachinePrecision]}, If[LessEqual[t$95$3, 1e-320], N[(N[(N[Sqrt[N[(N[(-2.0 * t$95$1 + t), $MachinePrecision] * n), $MachinePrecision]], $MachinePrecision] * N[Sqrt[U], $MachinePrecision]), $MachinePrecision] * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, 5e+274], N[Sqrt[N[(N[(t - N[(N[(N[(N[(U - U$42$), $MachinePrecision] * N[(n / Om), $MachinePrecision] + 2.0), $MachinePrecision] * N[(l * l), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] * t$95$2), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$3, Infinity], N[Sqrt[N[(N[(N[(N[(2.0 / Om), $MachinePrecision] * l), $MachinePrecision] * N[(N[(-2.0 * U), $MachinePrecision] * l), $MachinePrecision]), $MachinePrecision] * n + N[(N[(N[(t * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(N[(l * n), $MachinePrecision] / Om), $MachinePrecision] * N[(N[(N[(N[(U$42$ * U), $MachinePrecision] * l), $MachinePrecision] * n), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision]]]]]]]
        
        \begin{array}{l}
        
        \\
        \begin{array}{l}
        t_1 := \frac{\ell \cdot \ell}{Om}\\
        t_2 := U \cdot \left(n \cdot 2\right)\\
        t_3 := \left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_1 \cdot 2 - t\right)\right) \cdot t\_2\\
        \mathbf{if}\;t\_3 \leq 10^{-320}:\\
        \;\;\;\;\left(\sqrt{\mathsf{fma}\left(-2, t\_1, t\right) \cdot n} \cdot \sqrt{U}\right) \cdot \sqrt{2}\\
        
        \mathbf{elif}\;t\_3 \leq 5 \cdot 10^{+274}:\\
        \;\;\;\;\sqrt{\left(t - \frac{\mathsf{fma}\left(U - U*, \frac{n}{Om}, 2\right) \cdot \left(\ell \cdot \ell\right)}{Om}\right) \cdot t\_2}\\
        
        \mathbf{elif}\;t\_3 \leq \infty:\\
        \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{2}{Om} \cdot \ell\right) \cdot \left(\left(-2 \cdot U\right) \cdot \ell\right), n, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\
        
        \mathbf{else}:\\
        \;\;\;\;\sqrt{\left(\frac{\ell \cdot n}{Om} \cdot \frac{\left(\left(U* \cdot U\right) \cdot \ell\right) \cdot n}{Om}\right) \cdot 2}\\
        
        
        \end{array}
        \end{array}
        
        Derivation
        1. Split input into 4 regimes
        2. if (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < 9.99989e-321

          1. Initial program 8.7%

            \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
          2. Add Preprocessing
          3. Taylor expanded in U* around 0

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

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

              \[\leadsto \color{blue}{\sqrt{2} \cdot \sqrt{U \cdot \left(n \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)\right)}} \]
            3. lower-sqrt.f64N/A

              \[\leadsto \color{blue}{\sqrt{2}} \cdot \sqrt{U \cdot \left(n \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)\right)} \]
            4. lower-sqrt.f64N/A

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

              \[\leadsto \sqrt{2} \cdot \sqrt{\color{blue}{\left(U \cdot n\right) \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)}} \]
            6. lower-*.f64N/A

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

              \[\leadsto \sqrt{2} \cdot \sqrt{\color{blue}{\left(n \cdot U\right)} \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)} \]
            8. lower-*.f64N/A

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

              \[\leadsto \sqrt{2} \cdot \sqrt{\left(n \cdot U\right) \cdot \color{blue}{\left(\left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right) - \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)}} \]
            10. lower--.f64N/A

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

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

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

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

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

            if 9.99989e-321 < (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < 4.9999999999999998e274

            1. Initial program 95.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. Add Preprocessing
            3. Taylor expanded in t around 0

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

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

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

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

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

                \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t - \left(\frac{\frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{Om}}{Om} + \color{blue}{\left(\mathsf{neg}\left(-2\right)\right)} \cdot \frac{{\ell}^{2}}{Om}\right)\right)} \]
              6. cancel-sign-sub-invN/A

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

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

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

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

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

            if 4.9999999999999998e274 < (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < +inf.0

            1. Initial program 33.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. Add Preprocessing
            3. Taylor expanded in t around 0

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

                \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
              2. lower-fma.f64N/A

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

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

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

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

                  \[\leadsto \sqrt{\mathsf{fma}\left(\left(\left(U \cdot -2\right) \cdot \ell\right) \cdot \left(\frac{2}{Om} \cdot \ell\right), n, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)} \]
                3. Step-by-step derivation
                  1. Applied rewrites40.4%

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

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

                  1. Initial program 0.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. Add Preprocessing
                  3. Taylor expanded in t around 0

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

                      \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                    2. lower-fma.f64N/A

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

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

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

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

                        \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                      2. lower-*.f64N/A

                        \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                      3. lower-/.f64N/A

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

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

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

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

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

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

                        \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(\ell \cdot \ell\right) \cdot \color{blue}{\left(n \cdot n\right)}\right)}{{Om}^{2}} \cdot 2} \]
                      10. unswap-sqrN/A

                        \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                      11. lower-*.f64N/A

                        \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                      12. *-commutativeN/A

                        \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                      13. lower-*.f64N/A

                        \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                      14. *-commutativeN/A

                        \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                      15. lower-*.f64N/A

                        \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                      16. unpow2N/A

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

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

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

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

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

                    Alternative 3: 63.7% accurate, 0.4× speedup?

                    \[\begin{array}{l} \\ \begin{array}{l} t_1 := U \cdot \left(n \cdot 2\right)\\ t_2 := \frac{\ell \cdot \ell}{Om}\\ t_3 := \sqrt{\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_2 \cdot 2 - t\right)\right) \cdot t\_1}\\ \mathbf{if}\;t\_3 \leq 10^{-160}:\\ \;\;\;\;\sqrt{U \cdot 2} \cdot \sqrt{\left(\frac{\mathsf{fma}\left(-n, \frac{\left(\ell \cdot \ell\right) \cdot U}{Om}, \left(-2 \cdot \ell\right) \cdot \ell\right)}{Om} + t\right) \cdot n}\\ \mathbf{elif}\;t\_3 \leq 2 \cdot 10^{+137}:\\ \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{\ell}{Om} \cdot n\right) \cdot \left(U* - U\right), \frac{\ell}{Om}, \mathsf{fma}\left(-2, t\_2, t\right)\right) \cdot t\_1}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\left(\left(-2 \cdot U\right) \cdot \ell\right) \cdot \frac{\mathsf{fma}\left(\frac{n}{Om}, U - U*, 2\right)}{Om}\right) \cdot n, \ell, \left(\left(t \cdot n\right) \cdot 2\right) \cdot U\right)}\\ \end{array} \end{array} \]
                    (FPCore (n U t l Om U*)
                     :precision binary64
                     (let* ((t_1 (* U (* n 2.0)))
                            (t_2 (/ (* l l) Om))
                            (t_3
                             (sqrt
                              (*
                               (- (* (- U* U) (* (pow (/ l Om) 2.0) n)) (- (* t_2 2.0) t))
                               t_1))))
                       (if (<= t_3 1e-160)
                         (*
                          (sqrt (* U 2.0))
                          (sqrt
                           (* (+ (/ (fma (- n) (/ (* (* l l) U) Om) (* (* -2.0 l) l)) Om) t) n)))
                         (if (<= t_3 2e+137)
                           (sqrt
                            (* (fma (* (* (/ l Om) n) (- U* U)) (/ l Om) (fma -2.0 t_2 t)) t_1))
                           (sqrt
                            (fma
                             (* (* (* (* -2.0 U) l) (/ (fma (/ n Om) (- U U*) 2.0) Om)) n)
                             l
                             (* (* (* t n) 2.0) U)))))))
                    double code(double n, double U, double t, double l, double Om, double U_42_) {
                    	double t_1 = U * (n * 2.0);
                    	double t_2 = (l * l) / Om;
                    	double t_3 = sqrt(((((U_42_ - U) * (pow((l / Om), 2.0) * n)) - ((t_2 * 2.0) - t)) * t_1));
                    	double tmp;
                    	if (t_3 <= 1e-160) {
                    		tmp = sqrt((U * 2.0)) * sqrt((((fma(-n, (((l * l) * U) / Om), ((-2.0 * l) * l)) / Om) + t) * n));
                    	} else if (t_3 <= 2e+137) {
                    		tmp = sqrt((fma((((l / Om) * n) * (U_42_ - U)), (l / Om), fma(-2.0, t_2, t)) * t_1));
                    	} else {
                    		tmp = sqrt(fma(((((-2.0 * U) * l) * (fma((n / Om), (U - U_42_), 2.0) / Om)) * n), l, (((t * n) * 2.0) * U)));
                    	}
                    	return tmp;
                    }
                    
                    function code(n, U, t, l, Om, U_42_)
                    	t_1 = Float64(U * Float64(n * 2.0))
                    	t_2 = Float64(Float64(l * l) / Om)
                    	t_3 = sqrt(Float64(Float64(Float64(Float64(U_42_ - U) * Float64((Float64(l / Om) ^ 2.0) * n)) - Float64(Float64(t_2 * 2.0) - t)) * t_1))
                    	tmp = 0.0
                    	if (t_3 <= 1e-160)
                    		tmp = Float64(sqrt(Float64(U * 2.0)) * sqrt(Float64(Float64(Float64(fma(Float64(-n), Float64(Float64(Float64(l * l) * U) / Om), Float64(Float64(-2.0 * l) * l)) / Om) + t) * n)));
                    	elseif (t_3 <= 2e+137)
                    		tmp = sqrt(Float64(fma(Float64(Float64(Float64(l / Om) * n) * Float64(U_42_ - U)), Float64(l / Om), fma(-2.0, t_2, t)) * t_1));
                    	else
                    		tmp = sqrt(fma(Float64(Float64(Float64(Float64(-2.0 * U) * l) * Float64(fma(Float64(n / Om), Float64(U - U_42_), 2.0) / Om)) * n), l, Float64(Float64(Float64(t * n) * 2.0) * U)));
                    	end
                    	return tmp
                    end
                    
                    code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(U * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]}, Block[{t$95$3 = N[Sqrt[N[(N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision] * n), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$2 * 2.0), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] * t$95$1), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$3, 1e-160], N[(N[Sqrt[N[(U * 2.0), $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(N[(N[(N[((-n) * N[(N[(N[(l * l), $MachinePrecision] * U), $MachinePrecision] / Om), $MachinePrecision] + N[(N[(-2.0 * l), $MachinePrecision] * l), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision] + t), $MachinePrecision] * n), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, 2e+137], N[Sqrt[N[(N[(N[(N[(N[(l / Om), $MachinePrecision] * n), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision] * N[(l / Om), $MachinePrecision] + N[(-2.0 * t$95$2 + t), $MachinePrecision]), $MachinePrecision] * t$95$1), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(N[(N[(-2.0 * U), $MachinePrecision] * l), $MachinePrecision] * N[(N[(N[(n / Om), $MachinePrecision] * N[(U - U$42$), $MachinePrecision] + 2.0), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] * n), $MachinePrecision] * l + N[(N[(N[(t * n), $MachinePrecision] * 2.0), $MachinePrecision] * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]]
                    
                    \begin{array}{l}
                    
                    \\
                    \begin{array}{l}
                    t_1 := U \cdot \left(n \cdot 2\right)\\
                    t_2 := \frac{\ell \cdot \ell}{Om}\\
                    t_3 := \sqrt{\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_2 \cdot 2 - t\right)\right) \cdot t\_1}\\
                    \mathbf{if}\;t\_3 \leq 10^{-160}:\\
                    \;\;\;\;\sqrt{U \cdot 2} \cdot \sqrt{\left(\frac{\mathsf{fma}\left(-n, \frac{\left(\ell \cdot \ell\right) \cdot U}{Om}, \left(-2 \cdot \ell\right) \cdot \ell\right)}{Om} + t\right) \cdot n}\\
                    
                    \mathbf{elif}\;t\_3 \leq 2 \cdot 10^{+137}:\\
                    \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{\ell}{Om} \cdot n\right) \cdot \left(U* - U\right), \frac{\ell}{Om}, \mathsf{fma}\left(-2, t\_2, t\right)\right) \cdot t\_1}\\
                    
                    \mathbf{else}:\\
                    \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\left(\left(-2 \cdot U\right) \cdot \ell\right) \cdot \frac{\mathsf{fma}\left(\frac{n}{Om}, U - U*, 2\right)}{Om}\right) \cdot n, \ell, \left(\left(t \cdot n\right) \cdot 2\right) \cdot U\right)}\\
                    
                    
                    \end{array}
                    \end{array}
                    
                    Derivation
                    1. Split input into 3 regimes
                    2. if (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) < 9.9999999999999999e-161

                      1. Initial program 9.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. Add Preprocessing
                      3. Taylor expanded in U* around 0

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

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

                          \[\leadsto \color{blue}{\sqrt{2} \cdot \sqrt{U \cdot \left(n \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)\right)}} \]
                        3. lower-sqrt.f64N/A

                          \[\leadsto \color{blue}{\sqrt{2}} \cdot \sqrt{U \cdot \left(n \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)\right)} \]
                        4. lower-sqrt.f64N/A

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

                          \[\leadsto \sqrt{2} \cdot \sqrt{\color{blue}{\left(U \cdot n\right) \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)}} \]
                        6. lower-*.f64N/A

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

                          \[\leadsto \sqrt{2} \cdot \sqrt{\color{blue}{\left(n \cdot U\right)} \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)} \]
                        8. lower-*.f64N/A

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

                          \[\leadsto \sqrt{2} \cdot \sqrt{\left(n \cdot U\right) \cdot \color{blue}{\left(\left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right) - \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)}} \]
                        10. lower--.f64N/A

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

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

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

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

                      if 9.9999999999999999e-161 < (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) < 2.0000000000000001e137

                      1. Initial program 95.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. Add Preprocessing
                      3. Step-by-step derivation
                        1. lift--.f64N/A

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

                          \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \color{blue}{\left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) + \left(\mathsf{neg}\left(\left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right)\right)}} \]
                        3. +-commutativeN/A

                          \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \color{blue}{\left(\left(\mathsf{neg}\left(\left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)\right) + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)}} \]
                        4. lift-*.f64N/A

                          \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(\mathsf{neg}\left(\color{blue}{\left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)}\right)\right) + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)} \]
                        5. *-commutativeN/A

                          \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(\mathsf{neg}\left(\color{blue}{\left(U - U*\right) \cdot \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right)}\right)\right) + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)} \]
                        6. distribute-lft-neg-inN/A

                          \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\color{blue}{\left(\mathsf{neg}\left(\left(U - U*\right)\right)\right) \cdot \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right)} + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)} \]
                        7. lift-*.f64N/A

                          \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(\mathsf{neg}\left(\left(U - U*\right)\right)\right) \cdot \color{blue}{\left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right)} + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)} \]
                        8. lift-pow.f64N/A

                          \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(\mathsf{neg}\left(\left(U - U*\right)\right)\right) \cdot \left(n \cdot \color{blue}{{\left(\frac{\ell}{Om}\right)}^{2}}\right) + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)} \]
                        9. unpow2N/A

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

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

                          \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\color{blue}{\left(\left(\mathsf{neg}\left(\left(U - U*\right)\right)\right) \cdot \left(n \cdot \frac{\ell}{Om}\right)\right) \cdot \frac{\ell}{Om}} + \left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)\right)} \]
                        12. lower-fma.f64N/A

                          \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \color{blue}{\mathsf{fma}\left(\left(\mathsf{neg}\left(\left(U - U*\right)\right)\right) \cdot \left(n \cdot \frac{\ell}{Om}\right), \frac{\ell}{Om}, t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)}} \]
                        13. lower-*.f64N/A

                          \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \mathsf{fma}\left(\color{blue}{\left(\mathsf{neg}\left(\left(U - U*\right)\right)\right) \cdot \left(n \cdot \frac{\ell}{Om}\right)}, \frac{\ell}{Om}, t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)} \]
                        14. lower-neg.f64N/A

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

                          \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \mathsf{fma}\left(\left(-\left(U - U*\right)\right) \cdot \color{blue}{\left(n \cdot \frac{\ell}{Om}\right)}, \frac{\ell}{Om}, t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right)} \]
                        16. lift--.f64N/A

                          \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \mathsf{fma}\left(\left(-\left(U - U*\right)\right) \cdot \left(n \cdot \frac{\ell}{Om}\right), \frac{\ell}{Om}, \color{blue}{t - 2 \cdot \frac{\ell \cdot \ell}{Om}}\right)} \]
                        17. sub-negN/A

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

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

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

                      1. Initial program 20.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. Add Preprocessing
                      3. Taylor expanded in t around 0

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

                          \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                        2. lower-fma.f64N/A

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

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

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

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

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

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

                          Alternative 4: 59.2% accurate, 0.4× speedup?

                          \[\begin{array}{l} \\ \begin{array}{l} t_1 := U \cdot \left(n \cdot 2\right)\\ t_2 := \frac{\ell \cdot \ell}{Om}\\ t_3 := \sqrt{\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_2 \cdot 2 - t\right)\right) \cdot t\_1}\\ \mathbf{if}\;t\_3 \leq 10^{-160}:\\ \;\;\;\;\left(\sqrt{\mathsf{fma}\left(-2, t\_2, t\right) \cdot n} \cdot \sqrt{U}\right) \cdot \sqrt{2}\\ \mathbf{elif}\;t\_3 \leq 2 \cdot 10^{+137}:\\ \;\;\;\;\sqrt{\left(t - \frac{\mathsf{fma}\left(U - U*, \frac{n}{Om}, 2\right) \cdot \left(\ell \cdot \ell\right)}{Om}\right) \cdot t\_1}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{2 - \frac{U* \cdot n}{Om}}{Om} \cdot \ell\right) \cdot \left(\left(-2 \cdot U\right) \cdot \ell\right), n, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\ \end{array} \end{array} \]
                          (FPCore (n U t l Om U*)
                           :precision binary64
                           (let* ((t_1 (* U (* n 2.0)))
                                  (t_2 (/ (* l l) Om))
                                  (t_3
                                   (sqrt
                                    (*
                                     (- (* (- U* U) (* (pow (/ l Om) 2.0) n)) (- (* t_2 2.0) t))
                                     t_1))))
                             (if (<= t_3 1e-160)
                               (* (* (sqrt (* (fma -2.0 t_2 t) n)) (sqrt U)) (sqrt 2.0))
                               (if (<= t_3 2e+137)
                                 (sqrt (* (- t (/ (* (fma (- U U*) (/ n Om) 2.0) (* l l)) Om)) t_1))
                                 (sqrt
                                  (fma
                                   (* (* (/ (- 2.0 (/ (* U* n) Om)) Om) l) (* (* -2.0 U) l))
                                   n
                                   (* (* (* t n) U) 2.0)))))))
                          double code(double n, double U, double t, double l, double Om, double U_42_) {
                          	double t_1 = U * (n * 2.0);
                          	double t_2 = (l * l) / Om;
                          	double t_3 = sqrt(((((U_42_ - U) * (pow((l / Om), 2.0) * n)) - ((t_2 * 2.0) - t)) * t_1));
                          	double tmp;
                          	if (t_3 <= 1e-160) {
                          		tmp = (sqrt((fma(-2.0, t_2, t) * n)) * sqrt(U)) * sqrt(2.0);
                          	} else if (t_3 <= 2e+137) {
                          		tmp = sqrt(((t - ((fma((U - U_42_), (n / Om), 2.0) * (l * l)) / Om)) * t_1));
                          	} else {
                          		tmp = sqrt(fma(((((2.0 - ((U_42_ * n) / Om)) / Om) * l) * ((-2.0 * U) * l)), n, (((t * n) * U) * 2.0)));
                          	}
                          	return tmp;
                          }
                          
                          function code(n, U, t, l, Om, U_42_)
                          	t_1 = Float64(U * Float64(n * 2.0))
                          	t_2 = Float64(Float64(l * l) / Om)
                          	t_3 = sqrt(Float64(Float64(Float64(Float64(U_42_ - U) * Float64((Float64(l / Om) ^ 2.0) * n)) - Float64(Float64(t_2 * 2.0) - t)) * t_1))
                          	tmp = 0.0
                          	if (t_3 <= 1e-160)
                          		tmp = Float64(Float64(sqrt(Float64(fma(-2.0, t_2, t) * n)) * sqrt(U)) * sqrt(2.0));
                          	elseif (t_3 <= 2e+137)
                          		tmp = sqrt(Float64(Float64(t - Float64(Float64(fma(Float64(U - U_42_), Float64(n / Om), 2.0) * Float64(l * l)) / Om)) * t_1));
                          	else
                          		tmp = sqrt(fma(Float64(Float64(Float64(Float64(2.0 - Float64(Float64(U_42_ * n) / Om)) / Om) * l) * Float64(Float64(-2.0 * U) * l)), n, Float64(Float64(Float64(t * n) * U) * 2.0)));
                          	end
                          	return tmp
                          end
                          
                          code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(U * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]}, Block[{t$95$3 = N[Sqrt[N[(N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision] * n), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$2 * 2.0), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] * t$95$1), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$3, 1e-160], N[(N[(N[Sqrt[N[(N[(-2.0 * t$95$2 + t), $MachinePrecision] * n), $MachinePrecision]], $MachinePrecision] * N[Sqrt[U], $MachinePrecision]), $MachinePrecision] * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, 2e+137], N[Sqrt[N[(N[(t - N[(N[(N[(N[(U - U$42$), $MachinePrecision] * N[(n / Om), $MachinePrecision] + 2.0), $MachinePrecision] * N[(l * l), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] * t$95$1), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(N[(N[(2.0 - N[(N[(U$42$ * n), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision] * l), $MachinePrecision] * N[(N[(-2.0 * U), $MachinePrecision] * l), $MachinePrecision]), $MachinePrecision] * n + N[(N[(N[(t * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]]
                          
                          \begin{array}{l}
                          
                          \\
                          \begin{array}{l}
                          t_1 := U \cdot \left(n \cdot 2\right)\\
                          t_2 := \frac{\ell \cdot \ell}{Om}\\
                          t_3 := \sqrt{\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_2 \cdot 2 - t\right)\right) \cdot t\_1}\\
                          \mathbf{if}\;t\_3 \leq 10^{-160}:\\
                          \;\;\;\;\left(\sqrt{\mathsf{fma}\left(-2, t\_2, t\right) \cdot n} \cdot \sqrt{U}\right) \cdot \sqrt{2}\\
                          
                          \mathbf{elif}\;t\_3 \leq 2 \cdot 10^{+137}:\\
                          \;\;\;\;\sqrt{\left(t - \frac{\mathsf{fma}\left(U - U*, \frac{n}{Om}, 2\right) \cdot \left(\ell \cdot \ell\right)}{Om}\right) \cdot t\_1}\\
                          
                          \mathbf{else}:\\
                          \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{2 - \frac{U* \cdot n}{Om}}{Om} \cdot \ell\right) \cdot \left(\left(-2 \cdot U\right) \cdot \ell\right), n, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\
                          
                          
                          \end{array}
                          \end{array}
                          
                          Derivation
                          1. Split input into 3 regimes
                          2. if (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) < 9.9999999999999999e-161

                            1. Initial program 9.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. Add Preprocessing
                            3. Taylor expanded in U* around 0

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

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

                                \[\leadsto \color{blue}{\sqrt{2} \cdot \sqrt{U \cdot \left(n \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)\right)}} \]
                              3. lower-sqrt.f64N/A

                                \[\leadsto \color{blue}{\sqrt{2}} \cdot \sqrt{U \cdot \left(n \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)\right)} \]
                              4. lower-sqrt.f64N/A

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

                                \[\leadsto \sqrt{2} \cdot \sqrt{\color{blue}{\left(U \cdot n\right) \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)}} \]
                              6. lower-*.f64N/A

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

                                \[\leadsto \sqrt{2} \cdot \sqrt{\color{blue}{\left(n \cdot U\right)} \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)} \]
                              8. lower-*.f64N/A

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

                                \[\leadsto \sqrt{2} \cdot \sqrt{\left(n \cdot U\right) \cdot \color{blue}{\left(\left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right) - \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)}} \]
                              10. lower--.f64N/A

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

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

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

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

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

                              if 9.9999999999999999e-161 < (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) < 2.0000000000000001e137

                              1. Initial program 95.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. Add Preprocessing
                              3. Taylor expanded in t around 0

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

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

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

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

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

                                  \[\leadsto \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t - \left(\frac{\frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{Om}}{Om} + \color{blue}{\left(\mathsf{neg}\left(-2\right)\right)} \cdot \frac{{\ell}^{2}}{Om}\right)\right)} \]
                                6. cancel-sign-sub-invN/A

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

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

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

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

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

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

                              1. Initial program 20.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. Add Preprocessing
                              3. Taylor expanded in t around 0

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

                                  \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                2. lower-fma.f64N/A

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

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

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

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

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

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

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

                                  Alternative 5: 51.1% accurate, 0.8× speedup?

                                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(\frac{\ell \cdot \ell}{Om} \cdot 2 - t\right)\right) \cdot \left(U \cdot \left(n \cdot 2\right)\right) \leq \infty:\\ \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{2}{Om} \cdot \ell\right) \cdot \left(\left(-2 \cdot U\right) \cdot \ell\right), n, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\left(\frac{\ell \cdot n}{Om} \cdot \frac{\left(\left(U* \cdot U\right) \cdot \ell\right) \cdot n}{Om}\right) \cdot 2}\\ \end{array} \end{array} \]
                                  (FPCore (n U t l Om U*)
                                   :precision binary64
                                   (if (<=
                                        (*
                                         (- (* (- U* U) (* (pow (/ l Om) 2.0) n)) (- (* (/ (* l l) Om) 2.0) t))
                                         (* U (* n 2.0)))
                                        INFINITY)
                                     (sqrt (fma (* (* (/ 2.0 Om) l) (* (* -2.0 U) l)) n (* (* (* t n) U) 2.0)))
                                     (sqrt (* (* (/ (* l n) Om) (/ (* (* (* U* U) l) n) Om)) 2.0))))
                                  double code(double n, double U, double t, double l, double Om, double U_42_) {
                                  	double tmp;
                                  	if (((((U_42_ - U) * (pow((l / Om), 2.0) * n)) - ((((l * l) / Om) * 2.0) - t)) * (U * (n * 2.0))) <= ((double) INFINITY)) {
                                  		tmp = sqrt(fma((((2.0 / Om) * l) * ((-2.0 * U) * l)), n, (((t * n) * U) * 2.0)));
                                  	} else {
                                  		tmp = sqrt(((((l * n) / Om) * ((((U_42_ * U) * l) * n) / Om)) * 2.0));
                                  	}
                                  	return tmp;
                                  }
                                  
                                  function code(n, U, t, l, Om, U_42_)
                                  	tmp = 0.0
                                  	if (Float64(Float64(Float64(Float64(U_42_ - U) * Float64((Float64(l / Om) ^ 2.0) * n)) - Float64(Float64(Float64(Float64(l * l) / Om) * 2.0) - t)) * Float64(U * Float64(n * 2.0))) <= Inf)
                                  		tmp = sqrt(fma(Float64(Float64(Float64(2.0 / Om) * l) * Float64(Float64(-2.0 * U) * l)), n, Float64(Float64(Float64(t * n) * U) * 2.0)));
                                  	else
                                  		tmp = sqrt(Float64(Float64(Float64(Float64(l * n) / Om) * Float64(Float64(Float64(Float64(U_42_ * U) * l) * n) / Om)) * 2.0));
                                  	end
                                  	return tmp
                                  end
                                  
                                  code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[N[(N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision] * n), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision] * 2.0), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] * N[(U * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], Infinity], N[Sqrt[N[(N[(N[(N[(2.0 / Om), $MachinePrecision] * l), $MachinePrecision] * N[(N[(-2.0 * U), $MachinePrecision] * l), $MachinePrecision]), $MachinePrecision] * n + N[(N[(N[(t * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(N[(l * n), $MachinePrecision] / Om), $MachinePrecision] * N[(N[(N[(N[(U$42$ * U), $MachinePrecision] * l), $MachinePrecision] * n), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision]]
                                  
                                  \begin{array}{l}
                                  
                                  \\
                                  \begin{array}{l}
                                  \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(\frac{\ell \cdot \ell}{Om} \cdot 2 - t\right)\right) \cdot \left(U \cdot \left(n \cdot 2\right)\right) \leq \infty:\\
                                  \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{2}{Om} \cdot \ell\right) \cdot \left(\left(-2 \cdot U\right) \cdot \ell\right), n, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\
                                  
                                  \mathbf{else}:\\
                                  \;\;\;\;\sqrt{\left(\frac{\ell \cdot n}{Om} \cdot \frac{\left(\left(U* \cdot U\right) \cdot \ell\right) \cdot n}{Om}\right) \cdot 2}\\
                                  
                                  
                                  \end{array}
                                  \end{array}
                                  
                                  Derivation
                                  1. Split input into 2 regimes
                                  2. if (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < +inf.0

                                    1. Initial program 52.1%

                                      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
                                    2. Add Preprocessing
                                    3. Taylor expanded in t around 0

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

                                        \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                      2. lower-fma.f64N/A

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

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

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

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

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

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

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

                                          1. Initial program 0.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. Add Preprocessing
                                          3. Taylor expanded in t around 0

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

                                              \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                            2. lower-fma.f64N/A

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

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

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

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

                                                \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                                              2. lower-*.f64N/A

                                                \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                                              3. lower-/.f64N/A

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

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

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

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

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

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

                                                \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(\ell \cdot \ell\right) \cdot \color{blue}{\left(n \cdot n\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                              10. unswap-sqrN/A

                                                \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                                              11. lower-*.f64N/A

                                                \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                                              12. *-commutativeN/A

                                                \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                                              13. lower-*.f64N/A

                                                \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                                              14. *-commutativeN/A

                                                \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                              15. lower-*.f64N/A

                                                \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                              16. unpow2N/A

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

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

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

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

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

                                            Alternative 6: 50.0% accurate, 0.8× speedup?

                                            \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(\frac{\ell \cdot \ell}{Om} \cdot 2 - t\right)\right) \cdot \left(U \cdot \left(n \cdot 2\right)\right) \leq \infty:\\ \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{U}{Om} \cdot \ell\right) \cdot \left(\ell \cdot n\right), -4, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\left(\frac{\ell \cdot n}{Om} \cdot \frac{\left(\left(U* \cdot U\right) \cdot \ell\right) \cdot n}{Om}\right) \cdot 2}\\ \end{array} \end{array} \]
                                            (FPCore (n U t l Om U*)
                                             :precision binary64
                                             (if (<=
                                                  (*
                                                   (- (* (- U* U) (* (pow (/ l Om) 2.0) n)) (- (* (/ (* l l) Om) 2.0) t))
                                                   (* U (* n 2.0)))
                                                  INFINITY)
                                               (sqrt (fma (* (* (/ U Om) l) (* l n)) -4.0 (* (* (* t n) U) 2.0)))
                                               (sqrt (* (* (/ (* l n) Om) (/ (* (* (* U* U) l) n) Om)) 2.0))))
                                            double code(double n, double U, double t, double l, double Om, double U_42_) {
                                            	double tmp;
                                            	if (((((U_42_ - U) * (pow((l / Om), 2.0) * n)) - ((((l * l) / Om) * 2.0) - t)) * (U * (n * 2.0))) <= ((double) INFINITY)) {
                                            		tmp = sqrt(fma((((U / Om) * l) * (l * n)), -4.0, (((t * n) * U) * 2.0)));
                                            	} else {
                                            		tmp = sqrt(((((l * n) / Om) * ((((U_42_ * U) * l) * n) / Om)) * 2.0));
                                            	}
                                            	return tmp;
                                            }
                                            
                                            function code(n, U, t, l, Om, U_42_)
                                            	tmp = 0.0
                                            	if (Float64(Float64(Float64(Float64(U_42_ - U) * Float64((Float64(l / Om) ^ 2.0) * n)) - Float64(Float64(Float64(Float64(l * l) / Om) * 2.0) - t)) * Float64(U * Float64(n * 2.0))) <= Inf)
                                            		tmp = sqrt(fma(Float64(Float64(Float64(U / Om) * l) * Float64(l * n)), -4.0, Float64(Float64(Float64(t * n) * U) * 2.0)));
                                            	else
                                            		tmp = sqrt(Float64(Float64(Float64(Float64(l * n) / Om) * Float64(Float64(Float64(Float64(U_42_ * U) * l) * n) / Om)) * 2.0));
                                            	end
                                            	return tmp
                                            end
                                            
                                            code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[N[(N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision] * n), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision] * 2.0), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] * N[(U * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], Infinity], N[Sqrt[N[(N[(N[(N[(U / Om), $MachinePrecision] * l), $MachinePrecision] * N[(l * n), $MachinePrecision]), $MachinePrecision] * -4.0 + N[(N[(N[(t * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(N[(l * n), $MachinePrecision] / Om), $MachinePrecision] * N[(N[(N[(N[(U$42$ * U), $MachinePrecision] * l), $MachinePrecision] * n), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision]]
                                            
                                            \begin{array}{l}
                                            
                                            \\
                                            \begin{array}{l}
                                            \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(\frac{\ell \cdot \ell}{Om} \cdot 2 - t\right)\right) \cdot \left(U \cdot \left(n \cdot 2\right)\right) \leq \infty:\\
                                            \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{U}{Om} \cdot \ell\right) \cdot \left(\ell \cdot n\right), -4, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\
                                            
                                            \mathbf{else}:\\
                                            \;\;\;\;\sqrt{\left(\frac{\ell \cdot n}{Om} \cdot \frac{\left(\left(U* \cdot U\right) \cdot \ell\right) \cdot n}{Om}\right) \cdot 2}\\
                                            
                                            
                                            \end{array}
                                            \end{array}
                                            
                                            Derivation
                                            1. Split input into 2 regimes
                                            2. if (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < +inf.0

                                              1. Initial program 52.1%

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

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

                                                  \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om} \cdot -4} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                                2. lower-fma.f64N/A

                                                  \[\leadsto \sqrt{\color{blue}{\mathsf{fma}\left(\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)}} \]
                                                3. lower-/.f64N/A

                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\color{blue}{\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om}}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                4. *-commutativeN/A

                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left({\ell}^{2} \cdot n\right) \cdot U}}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                5. lower-*.f64N/A

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

                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left(n \cdot {\ell}^{2}\right)} \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                7. lower-*.f64N/A

                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left(n \cdot {\ell}^{2}\right)} \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                8. unpow2N/A

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

                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \color{blue}{\left(\ell \cdot \ell\right)}\right) \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                10. *-commutativeN/A

                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot U}{Om}, -4, \color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}\right)} \]
                                                11. lower-*.f64N/A

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

                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot U}{Om}, -4, \color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2\right)} \]
                                                13. lower-*.f64N/A

                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot U}{Om}, -4, \color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2\right)} \]
                                                14. lower-*.f6452.3

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

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

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

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

                                                1. Initial program 0.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. Add Preprocessing
                                                3. Taylor expanded in t around 0

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

                                                    \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                                  2. lower-fma.f64N/A

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

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

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

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

                                                      \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                                                    2. lower-*.f64N/A

                                                      \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                                                    3. lower-/.f64N/A

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

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

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

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

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

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

                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(\ell \cdot \ell\right) \cdot \color{blue}{\left(n \cdot n\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                    10. unswap-sqrN/A

                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                                                    11. lower-*.f64N/A

                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                                                    12. *-commutativeN/A

                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                                                    13. lower-*.f64N/A

                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                                                    14. *-commutativeN/A

                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                    15. lower-*.f64N/A

                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                    16. unpow2N/A

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

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

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

                                                      \[\leadsto \sqrt{\left(\frac{\left(\left(U* \cdot U\right) \cdot \ell\right) \cdot n}{Om} \cdot \frac{n \cdot \ell}{Om}\right) \cdot 2} \]
                                                  6. Recombined 2 regimes into one program.
                                                  7. Final simplification54.5%

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

                                                  Alternative 7: 49.0% accurate, 0.8× speedup?

                                                  \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{\ell \cdot \ell}{Om}\\ \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_1 \cdot 2 - t\right)\right) \cdot \left(U \cdot \left(n \cdot 2\right)\right) \leq \infty:\\ \;\;\;\;\sqrt{\left(\left(\mathsf{fma}\left(-2, t\_1, t\right) \cdot n\right) \cdot U\right) \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\frac{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right) \cdot \left(U* \cdot U\right)}{Om \cdot Om} \cdot 2}\\ \end{array} \end{array} \]
                                                  (FPCore (n U t l Om U*)
                                                   :precision binary64
                                                   (let* ((t_1 (/ (* l l) Om)))
                                                     (if (<=
                                                          (*
                                                           (- (* (- U* U) (* (pow (/ l Om) 2.0) n)) (- (* t_1 2.0) t))
                                                           (* U (* n 2.0)))
                                                          INFINITY)
                                                       (sqrt (* (* (* (fma -2.0 t_1 t) n) U) 2.0))
                                                       (sqrt (* (/ (* (* (* l n) (* l n)) (* U* U)) (* Om Om)) 2.0)))))
                                                  double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                  	double t_1 = (l * l) / Om;
                                                  	double tmp;
                                                  	if (((((U_42_ - U) * (pow((l / Om), 2.0) * n)) - ((t_1 * 2.0) - t)) * (U * (n * 2.0))) <= ((double) INFINITY)) {
                                                  		tmp = sqrt((((fma(-2.0, t_1, t) * n) * U) * 2.0));
                                                  	} else {
                                                  		tmp = sqrt((((((l * n) * (l * n)) * (U_42_ * U)) / (Om * Om)) * 2.0));
                                                  	}
                                                  	return tmp;
                                                  }
                                                  
                                                  function code(n, U, t, l, Om, U_42_)
                                                  	t_1 = Float64(Float64(l * l) / Om)
                                                  	tmp = 0.0
                                                  	if (Float64(Float64(Float64(Float64(U_42_ - U) * Float64((Float64(l / Om) ^ 2.0) * n)) - Float64(Float64(t_1 * 2.0) - t)) * Float64(U * Float64(n * 2.0))) <= Inf)
                                                  		tmp = sqrt(Float64(Float64(Float64(fma(-2.0, t_1, t) * n) * U) * 2.0));
                                                  	else
                                                  		tmp = sqrt(Float64(Float64(Float64(Float64(Float64(l * n) * Float64(l * n)) * Float64(U_42_ * U)) / Float64(Om * Om)) * 2.0));
                                                  	end
                                                  	return tmp
                                                  end
                                                  
                                                  code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]}, If[LessEqual[N[(N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision] * n), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$1 * 2.0), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] * N[(U * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], Infinity], N[Sqrt[N[(N[(N[(N[(-2.0 * t$95$1 + t), $MachinePrecision] * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(N[(N[(l * n), $MachinePrecision] * N[(l * n), $MachinePrecision]), $MachinePrecision] * N[(U$42$ * U), $MachinePrecision]), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision]]]
                                                  
                                                  \begin{array}{l}
                                                  
                                                  \\
                                                  \begin{array}{l}
                                                  t_1 := \frac{\ell \cdot \ell}{Om}\\
                                                  \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_1 \cdot 2 - t\right)\right) \cdot \left(U \cdot \left(n \cdot 2\right)\right) \leq \infty:\\
                                                  \;\;\;\;\sqrt{\left(\left(\mathsf{fma}\left(-2, t\_1, t\right) \cdot n\right) \cdot U\right) \cdot 2}\\
                                                  
                                                  \mathbf{else}:\\
                                                  \;\;\;\;\sqrt{\frac{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right) \cdot \left(U* \cdot U\right)}{Om \cdot Om} \cdot 2}\\
                                                  
                                                  
                                                  \end{array}
                                                  \end{array}
                                                  
                                                  Derivation
                                                  1. Split input into 2 regimes
                                                  2. if (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < +inf.0

                                                    1. Initial program 52.1%

                                                      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
                                                    2. Add Preprocessing
                                                    3. Taylor expanded in n around 0

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

                                                        \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot \left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right)\right)\right) \cdot 2}} \]
                                                      2. lower-*.f64N/A

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

                                                        \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot \left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right)\right) \cdot U\right)} \cdot 2} \]
                                                      4. lower-*.f64N/A

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

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

                                                        \[\leadsto \sqrt{\left(\color{blue}{\left(\left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right) \cdot n\right)} \cdot U\right) \cdot 2} \]
                                                      7. cancel-sign-sub-invN/A

                                                        \[\leadsto \sqrt{\left(\left(\color{blue}{\left(t + \left(\mathsf{neg}\left(2\right)\right) \cdot \frac{{\ell}^{2}}{Om}\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                      8. metadata-evalN/A

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

                                                        \[\leadsto \sqrt{\left(\left(\color{blue}{\left(-2 \cdot \frac{{\ell}^{2}}{Om} + t\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                      10. lower-fma.f64N/A

                                                        \[\leadsto \sqrt{\left(\left(\color{blue}{\mathsf{fma}\left(-2, \frac{{\ell}^{2}}{Om}, t\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                      11. lower-/.f64N/A

                                                        \[\leadsto \sqrt{\left(\left(\mathsf{fma}\left(-2, \color{blue}{\frac{{\ell}^{2}}{Om}}, t\right) \cdot n\right) \cdot U\right) \cdot 2} \]
                                                      12. unpow2N/A

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

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

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

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

                                                    1. Initial program 0.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. Add Preprocessing
                                                    3. Taylor expanded in t around 0

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

                                                        \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                                      2. lower-fma.f64N/A

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

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

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

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

                                                          \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                                                        2. lower-*.f64N/A

                                                          \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                                                        3. lower-/.f64N/A

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

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

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

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

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

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

                                                          \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(\ell \cdot \ell\right) \cdot \color{blue}{\left(n \cdot n\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                        10. unswap-sqrN/A

                                                          \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                                                        11. lower-*.f64N/A

                                                          \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                                                        12. *-commutativeN/A

                                                          \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                                                        13. lower-*.f64N/A

                                                          \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                                                        14. *-commutativeN/A

                                                          \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                        15. lower-*.f64N/A

                                                          \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                        16. unpow2N/A

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

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

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

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

                                                    Alternative 8: 49.0% accurate, 0.8× speedup?

                                                    \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{\ell \cdot \ell}{Om}\\ \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_1 \cdot 2 - t\right)\right) \cdot \left(U \cdot \left(n \cdot 2\right)\right) \leq \infty:\\ \;\;\;\;\sqrt{\left(\left(\mathsf{fma}\left(-2, t\_1, t\right) \cdot n\right) \cdot U\right) \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\left(\frac{\ell \cdot n}{Om \cdot Om} \cdot \left(\left(\left(U* \cdot U\right) \cdot \ell\right) \cdot n\right)\right) \cdot 2}\\ \end{array} \end{array} \]
                                                    (FPCore (n U t l Om U*)
                                                     :precision binary64
                                                     (let* ((t_1 (/ (* l l) Om)))
                                                       (if (<=
                                                            (*
                                                             (- (* (- U* U) (* (pow (/ l Om) 2.0) n)) (- (* t_1 2.0) t))
                                                             (* U (* n 2.0)))
                                                            INFINITY)
                                                         (sqrt (* (* (* (fma -2.0 t_1 t) n) U) 2.0))
                                                         (sqrt (* (* (/ (* l n) (* Om Om)) (* (* (* U* U) l) n)) 2.0)))))
                                                    double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                    	double t_1 = (l * l) / Om;
                                                    	double tmp;
                                                    	if (((((U_42_ - U) * (pow((l / Om), 2.0) * n)) - ((t_1 * 2.0) - t)) * (U * (n * 2.0))) <= ((double) INFINITY)) {
                                                    		tmp = sqrt((((fma(-2.0, t_1, t) * n) * U) * 2.0));
                                                    	} else {
                                                    		tmp = sqrt(((((l * n) / (Om * Om)) * (((U_42_ * U) * l) * n)) * 2.0));
                                                    	}
                                                    	return tmp;
                                                    }
                                                    
                                                    function code(n, U, t, l, Om, U_42_)
                                                    	t_1 = Float64(Float64(l * l) / Om)
                                                    	tmp = 0.0
                                                    	if (Float64(Float64(Float64(Float64(U_42_ - U) * Float64((Float64(l / Om) ^ 2.0) * n)) - Float64(Float64(t_1 * 2.0) - t)) * Float64(U * Float64(n * 2.0))) <= Inf)
                                                    		tmp = sqrt(Float64(Float64(Float64(fma(-2.0, t_1, t) * n) * U) * 2.0));
                                                    	else
                                                    		tmp = sqrt(Float64(Float64(Float64(Float64(l * n) / Float64(Om * Om)) * Float64(Float64(Float64(U_42_ * U) * l) * n)) * 2.0));
                                                    	end
                                                    	return tmp
                                                    end
                                                    
                                                    code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]}, If[LessEqual[N[(N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision] * n), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$1 * 2.0), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] * N[(U * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], Infinity], N[Sqrt[N[(N[(N[(N[(-2.0 * t$95$1 + t), $MachinePrecision] * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(N[(l * n), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] * N[(N[(N[(U$42$ * U), $MachinePrecision] * l), $MachinePrecision] * n), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision]]]
                                                    
                                                    \begin{array}{l}
                                                    
                                                    \\
                                                    \begin{array}{l}
                                                    t_1 := \frac{\ell \cdot \ell}{Om}\\
                                                    \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_1 \cdot 2 - t\right)\right) \cdot \left(U \cdot \left(n \cdot 2\right)\right) \leq \infty:\\
                                                    \;\;\;\;\sqrt{\left(\left(\mathsf{fma}\left(-2, t\_1, t\right) \cdot n\right) \cdot U\right) \cdot 2}\\
                                                    
                                                    \mathbf{else}:\\
                                                    \;\;\;\;\sqrt{\left(\frac{\ell \cdot n}{Om \cdot Om} \cdot \left(\left(\left(U* \cdot U\right) \cdot \ell\right) \cdot n\right)\right) \cdot 2}\\
                                                    
                                                    
                                                    \end{array}
                                                    \end{array}
                                                    
                                                    Derivation
                                                    1. Split input into 2 regimes
                                                    2. if (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < +inf.0

                                                      1. Initial program 52.1%

                                                        \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
                                                      2. Add Preprocessing
                                                      3. Taylor expanded in n around 0

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

                                                          \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot \left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right)\right)\right) \cdot 2}} \]
                                                        2. lower-*.f64N/A

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

                                                          \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot \left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right)\right) \cdot U\right)} \cdot 2} \]
                                                        4. lower-*.f64N/A

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

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

                                                          \[\leadsto \sqrt{\left(\color{blue}{\left(\left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right) \cdot n\right)} \cdot U\right) \cdot 2} \]
                                                        7. cancel-sign-sub-invN/A

                                                          \[\leadsto \sqrt{\left(\left(\color{blue}{\left(t + \left(\mathsf{neg}\left(2\right)\right) \cdot \frac{{\ell}^{2}}{Om}\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                        8. metadata-evalN/A

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

                                                          \[\leadsto \sqrt{\left(\left(\color{blue}{\left(-2 \cdot \frac{{\ell}^{2}}{Om} + t\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                        10. lower-fma.f64N/A

                                                          \[\leadsto \sqrt{\left(\left(\color{blue}{\mathsf{fma}\left(-2, \frac{{\ell}^{2}}{Om}, t\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                        11. lower-/.f64N/A

                                                          \[\leadsto \sqrt{\left(\left(\mathsf{fma}\left(-2, \color{blue}{\frac{{\ell}^{2}}{Om}}, t\right) \cdot n\right) \cdot U\right) \cdot 2} \]
                                                        12. unpow2N/A

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

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

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

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

                                                      1. Initial program 0.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. Add Preprocessing
                                                      3. Taylor expanded in t around 0

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

                                                          \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                                        2. lower-fma.f64N/A

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

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

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

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

                                                            \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                                                          2. lower-*.f64N/A

                                                            \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                                                          3. lower-/.f64N/A

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

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

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

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

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

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

                                                            \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(\ell \cdot \ell\right) \cdot \color{blue}{\left(n \cdot n\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                          10. unswap-sqrN/A

                                                            \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                                                          11. lower-*.f64N/A

                                                            \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                                                          12. *-commutativeN/A

                                                            \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                                                          13. lower-*.f64N/A

                                                            \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                                                          14. *-commutativeN/A

                                                            \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                          15. lower-*.f64N/A

                                                            \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                          16. unpow2N/A

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

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

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

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

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

                                                        Alternative 9: 48.2% accurate, 0.8× speedup?

                                                        \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{\ell \cdot \ell}{Om}\\ \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_1 \cdot 2 - t\right)\right) \cdot \left(U \cdot \left(n \cdot 2\right)\right) \leq \infty:\\ \;\;\;\;\sqrt{\left(\left(\mathsf{fma}\left(-2, t\_1, t\right) \cdot n\right) \cdot U\right) \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\left(\frac{U}{Om \cdot Om} \cdot \left(\left(n \cdot n\right) \cdot \left(U* \cdot \left(\ell \cdot \ell\right)\right)\right)\right) \cdot 2}\\ \end{array} \end{array} \]
                                                        (FPCore (n U t l Om U*)
                                                         :precision binary64
                                                         (let* ((t_1 (/ (* l l) Om)))
                                                           (if (<=
                                                                (*
                                                                 (- (* (- U* U) (* (pow (/ l Om) 2.0) n)) (- (* t_1 2.0) t))
                                                                 (* U (* n 2.0)))
                                                                INFINITY)
                                                             (sqrt (* (* (* (fma -2.0 t_1 t) n) U) 2.0))
                                                             (sqrt (* (* (/ U (* Om Om)) (* (* n n) (* U* (* l l)))) 2.0)))))
                                                        double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                        	double t_1 = (l * l) / Om;
                                                        	double tmp;
                                                        	if (((((U_42_ - U) * (pow((l / Om), 2.0) * n)) - ((t_1 * 2.0) - t)) * (U * (n * 2.0))) <= ((double) INFINITY)) {
                                                        		tmp = sqrt((((fma(-2.0, t_1, t) * n) * U) * 2.0));
                                                        	} else {
                                                        		tmp = sqrt((((U / (Om * Om)) * ((n * n) * (U_42_ * (l * l)))) * 2.0));
                                                        	}
                                                        	return tmp;
                                                        }
                                                        
                                                        function code(n, U, t, l, Om, U_42_)
                                                        	t_1 = Float64(Float64(l * l) / Om)
                                                        	tmp = 0.0
                                                        	if (Float64(Float64(Float64(Float64(U_42_ - U) * Float64((Float64(l / Om) ^ 2.0) * n)) - Float64(Float64(t_1 * 2.0) - t)) * Float64(U * Float64(n * 2.0))) <= Inf)
                                                        		tmp = sqrt(Float64(Float64(Float64(fma(-2.0, t_1, t) * n) * U) * 2.0));
                                                        	else
                                                        		tmp = sqrt(Float64(Float64(Float64(U / Float64(Om * Om)) * Float64(Float64(n * n) * Float64(U_42_ * Float64(l * l)))) * 2.0));
                                                        	end
                                                        	return tmp
                                                        end
                                                        
                                                        code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]}, If[LessEqual[N[(N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision] * n), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$1 * 2.0), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] * N[(U * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], Infinity], N[Sqrt[N[(N[(N[(N[(-2.0 * t$95$1 + t), $MachinePrecision] * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(U / N[(Om * Om), $MachinePrecision]), $MachinePrecision] * N[(N[(n * n), $MachinePrecision] * N[(U$42$ * N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision]]]
                                                        
                                                        \begin{array}{l}
                                                        
                                                        \\
                                                        \begin{array}{l}
                                                        t_1 := \frac{\ell \cdot \ell}{Om}\\
                                                        \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_1 \cdot 2 - t\right)\right) \cdot \left(U \cdot \left(n \cdot 2\right)\right) \leq \infty:\\
                                                        \;\;\;\;\sqrt{\left(\left(\mathsf{fma}\left(-2, t\_1, t\right) \cdot n\right) \cdot U\right) \cdot 2}\\
                                                        
                                                        \mathbf{else}:\\
                                                        \;\;\;\;\sqrt{\left(\frac{U}{Om \cdot Om} \cdot \left(\left(n \cdot n\right) \cdot \left(U* \cdot \left(\ell \cdot \ell\right)\right)\right)\right) \cdot 2}\\
                                                        
                                                        
                                                        \end{array}
                                                        \end{array}
                                                        
                                                        Derivation
                                                        1. Split input into 2 regimes
                                                        2. if (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < +inf.0

                                                          1. Initial program 52.1%

                                                            \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
                                                          2. Add Preprocessing
                                                          3. Taylor expanded in n around 0

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

                                                              \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot \left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right)\right)\right) \cdot 2}} \]
                                                            2. lower-*.f64N/A

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

                                                              \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot \left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right)\right) \cdot U\right)} \cdot 2} \]
                                                            4. lower-*.f64N/A

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

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

                                                              \[\leadsto \sqrt{\left(\color{blue}{\left(\left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right) \cdot n\right)} \cdot U\right) \cdot 2} \]
                                                            7. cancel-sign-sub-invN/A

                                                              \[\leadsto \sqrt{\left(\left(\color{blue}{\left(t + \left(\mathsf{neg}\left(2\right)\right) \cdot \frac{{\ell}^{2}}{Om}\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                            8. metadata-evalN/A

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

                                                              \[\leadsto \sqrt{\left(\left(\color{blue}{\left(-2 \cdot \frac{{\ell}^{2}}{Om} + t\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                            10. lower-fma.f64N/A

                                                              \[\leadsto \sqrt{\left(\left(\color{blue}{\mathsf{fma}\left(-2, \frac{{\ell}^{2}}{Om}, t\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                            11. lower-/.f64N/A

                                                              \[\leadsto \sqrt{\left(\left(\mathsf{fma}\left(-2, \color{blue}{\frac{{\ell}^{2}}{Om}}, t\right) \cdot n\right) \cdot U\right) \cdot 2} \]
                                                            12. unpow2N/A

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

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

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

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

                                                          1. Initial program 0.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. Add Preprocessing
                                                          3. Taylor expanded in U* around inf

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

                                                              \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                                                            2. lower-*.f64N/A

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

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

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

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

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

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

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

                                                              \[\leadsto \sqrt{\left(\left(\left(U* \cdot \color{blue}{\left(\ell \cdot \ell\right)}\right) \cdot {n}^{2}\right) \cdot \frac{U}{{Om}^{2}}\right) \cdot 2} \]
                                                            10. lower-*.f64N/A

                                                              \[\leadsto \sqrt{\left(\left(\left(U* \cdot \color{blue}{\left(\ell \cdot \ell\right)}\right) \cdot {n}^{2}\right) \cdot \frac{U}{{Om}^{2}}\right) \cdot 2} \]
                                                            11. unpow2N/A

                                                              \[\leadsto \sqrt{\left(\left(\left(U* \cdot \left(\ell \cdot \ell\right)\right) \cdot \color{blue}{\left(n \cdot n\right)}\right) \cdot \frac{U}{{Om}^{2}}\right) \cdot 2} \]
                                                            12. lower-*.f64N/A

                                                              \[\leadsto \sqrt{\left(\left(\left(U* \cdot \left(\ell \cdot \ell\right)\right) \cdot \color{blue}{\left(n \cdot n\right)}\right) \cdot \frac{U}{{Om}^{2}}\right) \cdot 2} \]
                                                            13. lower-/.f64N/A

                                                              \[\leadsto \sqrt{\left(\left(\left(U* \cdot \left(\ell \cdot \ell\right)\right) \cdot \left(n \cdot n\right)\right) \cdot \color{blue}{\frac{U}{{Om}^{2}}}\right) \cdot 2} \]
                                                            14. unpow2N/A

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

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

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

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

                                                        Alternative 10: 47.8% accurate, 0.8× speedup?

                                                        \[\begin{array}{l} \\ \begin{array}{l} t_1 := \frac{\ell \cdot \ell}{Om}\\ \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_1 \cdot 2 - t\right)\right) \cdot \left(U \cdot \left(n \cdot 2\right)\right) \leq \infty:\\ \;\;\;\;\sqrt{\left(\left(\mathsf{fma}\left(-2, t\_1, t\right) \cdot n\right) \cdot U\right) \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;\frac{\left(\sqrt{2} \cdot n\right) \cdot \ell}{Om} \cdot \sqrt{U* \cdot U}\\ \end{array} \end{array} \]
                                                        (FPCore (n U t l Om U*)
                                                         :precision binary64
                                                         (let* ((t_1 (/ (* l l) Om)))
                                                           (if (<=
                                                                (*
                                                                 (- (* (- U* U) (* (pow (/ l Om) 2.0) n)) (- (* t_1 2.0) t))
                                                                 (* U (* n 2.0)))
                                                                INFINITY)
                                                             (sqrt (* (* (* (fma -2.0 t_1 t) n) U) 2.0))
                                                             (* (/ (* (* (sqrt 2.0) n) l) Om) (sqrt (* U* U))))))
                                                        double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                        	double t_1 = (l * l) / Om;
                                                        	double tmp;
                                                        	if (((((U_42_ - U) * (pow((l / Om), 2.0) * n)) - ((t_1 * 2.0) - t)) * (U * (n * 2.0))) <= ((double) INFINITY)) {
                                                        		tmp = sqrt((((fma(-2.0, t_1, t) * n) * U) * 2.0));
                                                        	} else {
                                                        		tmp = (((sqrt(2.0) * n) * l) / Om) * sqrt((U_42_ * U));
                                                        	}
                                                        	return tmp;
                                                        }
                                                        
                                                        function code(n, U, t, l, Om, U_42_)
                                                        	t_1 = Float64(Float64(l * l) / Om)
                                                        	tmp = 0.0
                                                        	if (Float64(Float64(Float64(Float64(U_42_ - U) * Float64((Float64(l / Om) ^ 2.0) * n)) - Float64(Float64(t_1 * 2.0) - t)) * Float64(U * Float64(n * 2.0))) <= Inf)
                                                        		tmp = sqrt(Float64(Float64(Float64(fma(-2.0, t_1, t) * n) * U) * 2.0));
                                                        	else
                                                        		tmp = Float64(Float64(Float64(Float64(sqrt(2.0) * n) * l) / Om) * sqrt(Float64(U_42_ * U)));
                                                        	end
                                                        	return tmp
                                                        end
                                                        
                                                        code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]}, If[LessEqual[N[(N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision] * n), $MachinePrecision]), $MachinePrecision] - N[(N[(t$95$1 * 2.0), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] * N[(U * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], Infinity], N[Sqrt[N[(N[(N[(N[(-2.0 * t$95$1 + t), $MachinePrecision] * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision], N[(N[(N[(N[(N[Sqrt[2.0], $MachinePrecision] * n), $MachinePrecision] * l), $MachinePrecision] / Om), $MachinePrecision] * N[Sqrt[N[(U$42$ * U), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
                                                        
                                                        \begin{array}{l}
                                                        
                                                        \\
                                                        \begin{array}{l}
                                                        t_1 := \frac{\ell \cdot \ell}{Om}\\
                                                        \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(t\_1 \cdot 2 - t\right)\right) \cdot \left(U \cdot \left(n \cdot 2\right)\right) \leq \infty:\\
                                                        \;\;\;\;\sqrt{\left(\left(\mathsf{fma}\left(-2, t\_1, t\right) \cdot n\right) \cdot U\right) \cdot 2}\\
                                                        
                                                        \mathbf{else}:\\
                                                        \;\;\;\;\frac{\left(\sqrt{2} \cdot n\right) \cdot \ell}{Om} \cdot \sqrt{U* \cdot U}\\
                                                        
                                                        
                                                        \end{array}
                                                        \end{array}
                                                        
                                                        Derivation
                                                        1. Split input into 2 regimes
                                                        2. if (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < +inf.0

                                                          1. Initial program 52.1%

                                                            \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
                                                          2. Add Preprocessing
                                                          3. Taylor expanded in n around 0

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

                                                              \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot \left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right)\right)\right) \cdot 2}} \]
                                                            2. lower-*.f64N/A

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

                                                              \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot \left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right)\right) \cdot U\right)} \cdot 2} \]
                                                            4. lower-*.f64N/A

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

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

                                                              \[\leadsto \sqrt{\left(\color{blue}{\left(\left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right) \cdot n\right)} \cdot U\right) \cdot 2} \]
                                                            7. cancel-sign-sub-invN/A

                                                              \[\leadsto \sqrt{\left(\left(\color{blue}{\left(t + \left(\mathsf{neg}\left(2\right)\right) \cdot \frac{{\ell}^{2}}{Om}\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                            8. metadata-evalN/A

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

                                                              \[\leadsto \sqrt{\left(\left(\color{blue}{\left(-2 \cdot \frac{{\ell}^{2}}{Om} + t\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                            10. lower-fma.f64N/A

                                                              \[\leadsto \sqrt{\left(\left(\color{blue}{\mathsf{fma}\left(-2, \frac{{\ell}^{2}}{Om}, t\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                            11. lower-/.f64N/A

                                                              \[\leadsto \sqrt{\left(\left(\mathsf{fma}\left(-2, \color{blue}{\frac{{\ell}^{2}}{Om}}, t\right) \cdot n\right) \cdot U\right) \cdot 2} \]
                                                            12. unpow2N/A

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

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

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

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

                                                          1. Initial program 0.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. Add Preprocessing
                                                          3. Taylor expanded in U* around inf

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

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

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

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

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

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

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

                                                              \[\leadsto \sqrt{U* \cdot U} \cdot \frac{\color{blue}{\left(n \cdot \sqrt{2}\right) \cdot \ell}}{Om} \]
                                                            8. lower-*.f64N/A

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

                                                              \[\leadsto \sqrt{U* \cdot U} \cdot \frac{\color{blue}{\left(\sqrt{2} \cdot n\right)} \cdot \ell}{Om} \]
                                                            10. lower-*.f64N/A

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

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

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

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

                                                        Alternative 11: 38.5% accurate, 0.9× speedup?

                                                        \[\begin{array}{l} \\ \begin{array}{l} t_1 := U \cdot \left(n \cdot 2\right)\\ \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(\frac{\ell \cdot \ell}{Om} \cdot 2 - t\right)\right) \cdot t\_1 \leq 0:\\ \;\;\;\;\sqrt{\left(t \cdot U\right) \cdot \left(n \cdot 2\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{t \cdot t\_1}\\ \end{array} \end{array} \]
                                                        (FPCore (n U t l Om U*)
                                                         :precision binary64
                                                         (let* ((t_1 (* U (* n 2.0))))
                                                           (if (<=
                                                                (*
                                                                 (- (* (- U* U) (* (pow (/ l Om) 2.0) n)) (- (* (/ (* l l) Om) 2.0) t))
                                                                 t_1)
                                                                0.0)
                                                             (sqrt (* (* t U) (* n 2.0)))
                                                             (sqrt (* t t_1)))))
                                                        double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                        	double t_1 = U * (n * 2.0);
                                                        	double tmp;
                                                        	if (((((U_42_ - U) * (pow((l / Om), 2.0) * n)) - ((((l * l) / Om) * 2.0) - t)) * t_1) <= 0.0) {
                                                        		tmp = sqrt(((t * U) * (n * 2.0)));
                                                        	} else {
                                                        		tmp = sqrt((t * t_1));
                                                        	}
                                                        	return tmp;
                                                        }
                                                        
                                                        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 = u * (n * 2.0d0)
                                                            if (((((u_42 - u) * (((l / om) ** 2.0d0) * n)) - ((((l * l) / om) * 2.0d0) - t)) * t_1) <= 0.0d0) then
                                                                tmp = sqrt(((t * u) * (n * 2.0d0)))
                                                            else
                                                                tmp = sqrt((t * t_1))
                                                            end if
                                                            code = tmp
                                                        end function
                                                        
                                                        public static double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                        	double t_1 = U * (n * 2.0);
                                                        	double tmp;
                                                        	if (((((U_42_ - U) * (Math.pow((l / Om), 2.0) * n)) - ((((l * l) / Om) * 2.0) - t)) * t_1) <= 0.0) {
                                                        		tmp = Math.sqrt(((t * U) * (n * 2.0)));
                                                        	} else {
                                                        		tmp = Math.sqrt((t * t_1));
                                                        	}
                                                        	return tmp;
                                                        }
                                                        
                                                        def code(n, U, t, l, Om, U_42_):
                                                        	t_1 = U * (n * 2.0)
                                                        	tmp = 0
                                                        	if ((((U_42_ - U) * (math.pow((l / Om), 2.0) * n)) - ((((l * l) / Om) * 2.0) - t)) * t_1) <= 0.0:
                                                        		tmp = math.sqrt(((t * U) * (n * 2.0)))
                                                        	else:
                                                        		tmp = math.sqrt((t * t_1))
                                                        	return tmp
                                                        
                                                        function code(n, U, t, l, Om, U_42_)
                                                        	t_1 = Float64(U * Float64(n * 2.0))
                                                        	tmp = 0.0
                                                        	if (Float64(Float64(Float64(Float64(U_42_ - U) * Float64((Float64(l / Om) ^ 2.0) * n)) - Float64(Float64(Float64(Float64(l * l) / Om) * 2.0) - t)) * t_1) <= 0.0)
                                                        		tmp = sqrt(Float64(Float64(t * U) * Float64(n * 2.0)));
                                                        	else
                                                        		tmp = sqrt(Float64(t * t_1));
                                                        	end
                                                        	return tmp
                                                        end
                                                        
                                                        function tmp_2 = code(n, U, t, l, Om, U_42_)
                                                        	t_1 = U * (n * 2.0);
                                                        	tmp = 0.0;
                                                        	if (((((U_42_ - U) * (((l / Om) ^ 2.0) * n)) - ((((l * l) / Om) * 2.0) - t)) * t_1) <= 0.0)
                                                        		tmp = sqrt(((t * U) * (n * 2.0)));
                                                        	else
                                                        		tmp = sqrt((t * t_1));
                                                        	end
                                                        	tmp_2 = tmp;
                                                        end
                                                        
                                                        code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(U * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[N[(N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision] * n), $MachinePrecision]), $MachinePrecision] - N[(N[(N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision] * 2.0), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision] * t$95$1), $MachinePrecision], 0.0], N[Sqrt[N[(N[(t * U), $MachinePrecision] * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(t * t$95$1), $MachinePrecision]], $MachinePrecision]]]
                                                        
                                                        \begin{array}{l}
                                                        
                                                        \\
                                                        \begin{array}{l}
                                                        t_1 := U \cdot \left(n \cdot 2\right)\\
                                                        \mathbf{if}\;\left(\left(U* - U\right) \cdot \left({\left(\frac{\ell}{Om}\right)}^{2} \cdot n\right) - \left(\frac{\ell \cdot \ell}{Om} \cdot 2 - t\right)\right) \cdot t\_1 \leq 0:\\
                                                        \;\;\;\;\sqrt{\left(t \cdot U\right) \cdot \left(n \cdot 2\right)}\\
                                                        
                                                        \mathbf{else}:\\
                                                        \;\;\;\;\sqrt{t \cdot t\_1}\\
                                                        
                                                        
                                                        \end{array}
                                                        \end{array}
                                                        
                                                        Derivation
                                                        1. Split input into 2 regimes
                                                        2. if (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < 0.0

                                                          1. Initial program 8.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. Add Preprocessing
                                                          3. Taylor expanded in t around inf

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

                                                              \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}} \]
                                                            2. lower-*.f64N/A

                                                              \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}} \]
                                                            3. *-commutativeN/A

                                                              \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2} \]
                                                            4. lower-*.f64N/A

                                                              \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2} \]
                                                            5. lower-*.f6434.0

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

                                                            \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot t\right) \cdot U\right) \cdot 2}} \]
                                                          6. Step-by-step derivation
                                                            1. Applied rewrites34.0%

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

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

                                                            1. Initial program 50.5%

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

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

                                                                \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}} \]
                                                              2. lower-*.f64N/A

                                                                \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}} \]
                                                              3. *-commutativeN/A

                                                                \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2} \]
                                                              4. lower-*.f64N/A

                                                                \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2} \]
                                                              5. lower-*.f6438.4

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

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

                                                                \[\leadsto \sqrt{t \cdot \color{blue}{\left(\left(2 \cdot n\right) \cdot U\right)}} \]
                                                            7. Recombined 2 regimes into one program.
                                                            8. Final simplification37.0%

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

                                                            Alternative 12: 55.2% accurate, 2.0× speedup?

                                                            \[\begin{array}{l} \\ \begin{array}{l} t_1 := \mathsf{fma}\left(\frac{n}{Om}, U - U*, 2\right)\\ \mathbf{if}\;\ell \leq 1.75 \cdot 10^{+63}:\\ \;\;\;\;\sqrt{\mathsf{fma}\left(-2 \cdot U, \frac{\left(t\_1 \cdot \ell\right) \cdot \ell}{Om} \cdot n, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\left(\left(-2 \cdot U\right) \cdot \ell\right) \cdot \frac{t\_1}{Om}\right) \cdot n, \ell, \left(\left(t \cdot n\right) \cdot 2\right) \cdot U\right)}\\ \end{array} \end{array} \]
                                                            (FPCore (n U t l Om U*)
                                                             :precision binary64
                                                             (let* ((t_1 (fma (/ n Om) (- U U*) 2.0)))
                                                               (if (<= l 1.75e+63)
                                                                 (sqrt (fma (* -2.0 U) (* (/ (* (* t_1 l) l) Om) n) (* (* (* t n) U) 2.0)))
                                                                 (sqrt
                                                                  (fma (* (* (* (* -2.0 U) l) (/ t_1 Om)) n) l (* (* (* t n) 2.0) U))))))
                                                            double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                            	double t_1 = fma((n / Om), (U - U_42_), 2.0);
                                                            	double tmp;
                                                            	if (l <= 1.75e+63) {
                                                            		tmp = sqrt(fma((-2.0 * U), ((((t_1 * l) * l) / Om) * n), (((t * n) * U) * 2.0)));
                                                            	} else {
                                                            		tmp = sqrt(fma(((((-2.0 * U) * l) * (t_1 / Om)) * n), l, (((t * n) * 2.0) * U)));
                                                            	}
                                                            	return tmp;
                                                            }
                                                            
                                                            function code(n, U, t, l, Om, U_42_)
                                                            	t_1 = fma(Float64(n / Om), Float64(U - U_42_), 2.0)
                                                            	tmp = 0.0
                                                            	if (l <= 1.75e+63)
                                                            		tmp = sqrt(fma(Float64(-2.0 * U), Float64(Float64(Float64(Float64(t_1 * l) * l) / Om) * n), Float64(Float64(Float64(t * n) * U) * 2.0)));
                                                            	else
                                                            		tmp = sqrt(fma(Float64(Float64(Float64(Float64(-2.0 * U) * l) * Float64(t_1 / Om)) * n), l, Float64(Float64(Float64(t * n) * 2.0) * U)));
                                                            	end
                                                            	return tmp
                                                            end
                                                            
                                                            code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(N[(n / Om), $MachinePrecision] * N[(U - U$42$), $MachinePrecision] + 2.0), $MachinePrecision]}, If[LessEqual[l, 1.75e+63], N[Sqrt[N[(N[(-2.0 * U), $MachinePrecision] * N[(N[(N[(N[(t$95$1 * l), $MachinePrecision] * l), $MachinePrecision] / Om), $MachinePrecision] * n), $MachinePrecision] + N[(N[(N[(t * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(N[(N[(-2.0 * U), $MachinePrecision] * l), $MachinePrecision] * N[(t$95$1 / Om), $MachinePrecision]), $MachinePrecision] * n), $MachinePrecision] * l + N[(N[(N[(t * n), $MachinePrecision] * 2.0), $MachinePrecision] * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]
                                                            
                                                            \begin{array}{l}
                                                            
                                                            \\
                                                            \begin{array}{l}
                                                            t_1 := \mathsf{fma}\left(\frac{n}{Om}, U - U*, 2\right)\\
                                                            \mathbf{if}\;\ell \leq 1.75 \cdot 10^{+63}:\\
                                                            \;\;\;\;\sqrt{\mathsf{fma}\left(-2 \cdot U, \frac{\left(t\_1 \cdot \ell\right) \cdot \ell}{Om} \cdot n, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\
                                                            
                                                            \mathbf{else}:\\
                                                            \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\left(\left(-2 \cdot U\right) \cdot \ell\right) \cdot \frac{t\_1}{Om}\right) \cdot n, \ell, \left(\left(t \cdot n\right) \cdot 2\right) \cdot U\right)}\\
                                                            
                                                            
                                                            \end{array}
                                                            \end{array}
                                                            
                                                            Derivation
                                                            1. Split input into 2 regimes
                                                            2. if l < 1.75000000000000015e63

                                                              1. Initial program 46.1%

                                                                \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
                                                              2. Add Preprocessing
                                                              3. Taylor expanded in t around 0

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

                                                                  \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                                                2. lower-fma.f64N/A

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

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

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

                                                                if 1.75000000000000015e63 < l

                                                                1. Initial program 23.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. Add Preprocessing
                                                                3. Taylor expanded in t around 0

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

                                                                    \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                                                  2. lower-fma.f64N/A

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

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

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

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

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

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

                                                                    Alternative 13: 47.1% accurate, 2.7× speedup?

                                                                    \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\ell \leq 1.15 \cdot 10^{+162}:\\ \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{U}{Om} \cdot \ell\right) \cdot \left(\ell \cdot n\right), -4, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\left(\left(\left(\frac{-2}{Om \cdot Om} \cdot n\right) \cdot \left(\left(U - U*\right) \cdot n\right)\right) \cdot \ell\right) \cdot \left(\ell \cdot U\right)}\\ \end{array} \end{array} \]
                                                                    (FPCore (n U t l Om U*)
                                                                     :precision binary64
                                                                     (if (<= l 1.15e+162)
                                                                       (sqrt (fma (* (* (/ U Om) l) (* l n)) -4.0 (* (* (* t n) U) 2.0)))
                                                                       (sqrt (* (* (* (* (/ -2.0 (* Om Om)) n) (* (- U U*) n)) l) (* l U)))))
                                                                    double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                                    	double tmp;
                                                                    	if (l <= 1.15e+162) {
                                                                    		tmp = sqrt(fma((((U / Om) * l) * (l * n)), -4.0, (((t * n) * U) * 2.0)));
                                                                    	} else {
                                                                    		tmp = sqrt((((((-2.0 / (Om * Om)) * n) * ((U - U_42_) * n)) * l) * (l * U)));
                                                                    	}
                                                                    	return tmp;
                                                                    }
                                                                    
                                                                    function code(n, U, t, l, Om, U_42_)
                                                                    	tmp = 0.0
                                                                    	if (l <= 1.15e+162)
                                                                    		tmp = sqrt(fma(Float64(Float64(Float64(U / Om) * l) * Float64(l * n)), -4.0, Float64(Float64(Float64(t * n) * U) * 2.0)));
                                                                    	else
                                                                    		tmp = sqrt(Float64(Float64(Float64(Float64(Float64(-2.0 / Float64(Om * Om)) * n) * Float64(Float64(U - U_42_) * n)) * l) * Float64(l * U)));
                                                                    	end
                                                                    	return tmp
                                                                    end
                                                                    
                                                                    code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 1.15e+162], N[Sqrt[N[(N[(N[(N[(U / Om), $MachinePrecision] * l), $MachinePrecision] * N[(l * n), $MachinePrecision]), $MachinePrecision] * -4.0 + N[(N[(N[(t * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(N[(N[(-2.0 / N[(Om * Om), $MachinePrecision]), $MachinePrecision] * n), $MachinePrecision] * N[(N[(U - U$42$), $MachinePrecision] * n), $MachinePrecision]), $MachinePrecision] * l), $MachinePrecision] * N[(l * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
                                                                    
                                                                    \begin{array}{l}
                                                                    
                                                                    \\
                                                                    \begin{array}{l}
                                                                    \mathbf{if}\;\ell \leq 1.15 \cdot 10^{+162}:\\
                                                                    \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{U}{Om} \cdot \ell\right) \cdot \left(\ell \cdot n\right), -4, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\
                                                                    
                                                                    \mathbf{else}:\\
                                                                    \;\;\;\;\sqrt{\left(\left(\left(\frac{-2}{Om \cdot Om} \cdot n\right) \cdot \left(\left(U - U*\right) \cdot n\right)\right) \cdot \ell\right) \cdot \left(\ell \cdot U\right)}\\
                                                                    
                                                                    
                                                                    \end{array}
                                                                    \end{array}
                                                                    
                                                                    Derivation
                                                                    1. Split input into 2 regimes
                                                                    2. if l < 1.14999999999999997e162

                                                                      1. Initial program 45.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. Add Preprocessing
                                                                      3. Taylor expanded in Om around inf

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

                                                                          \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om} \cdot -4} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                                                        2. lower-fma.f64N/A

                                                                          \[\leadsto \sqrt{\color{blue}{\mathsf{fma}\left(\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)}} \]
                                                                        3. lower-/.f64N/A

                                                                          \[\leadsto \sqrt{\mathsf{fma}\left(\color{blue}{\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om}}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                        4. *-commutativeN/A

                                                                          \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left({\ell}^{2} \cdot n\right) \cdot U}}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                        5. lower-*.f64N/A

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

                                                                          \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left(n \cdot {\ell}^{2}\right)} \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                        7. lower-*.f64N/A

                                                                          \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left(n \cdot {\ell}^{2}\right)} \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                        8. unpow2N/A

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

                                                                          \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \color{blue}{\left(\ell \cdot \ell\right)}\right) \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                        10. *-commutativeN/A

                                                                          \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot U}{Om}, -4, \color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}\right)} \]
                                                                        11. lower-*.f64N/A

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

                                                                          \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot U}{Om}, -4, \color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2\right)} \]
                                                                        13. lower-*.f64N/A

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

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

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

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

                                                                        if 1.14999999999999997e162 < l

                                                                        1. Initial program 12.5%

                                                                          \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
                                                                        2. Add Preprocessing
                                                                        3. Taylor expanded in Om around 0

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

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

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

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

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

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

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

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

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

                                                                            \[\leadsto \sqrt{\left(\left(U \cdot \color{blue}{\left(\ell \cdot \ell\right)}\right) \cdot \left({n}^{2} \cdot \left(U - U*\right)\right)\right) \cdot \frac{-2}{{Om}^{2}}} \]
                                                                          10. *-commutativeN/A

                                                                            \[\leadsto \sqrt{\left(\left(U \cdot \left(\ell \cdot \ell\right)\right) \cdot \color{blue}{\left(\left(U - U*\right) \cdot {n}^{2}\right)}\right) \cdot \frac{-2}{{Om}^{2}}} \]
                                                                          11. lower-*.f64N/A

                                                                            \[\leadsto \sqrt{\left(\left(U \cdot \left(\ell \cdot \ell\right)\right) \cdot \color{blue}{\left(\left(U - U*\right) \cdot {n}^{2}\right)}\right) \cdot \frac{-2}{{Om}^{2}}} \]
                                                                          12. lower--.f64N/A

                                                                            \[\leadsto \sqrt{\left(\left(U \cdot \left(\ell \cdot \ell\right)\right) \cdot \left(\color{blue}{\left(U - U*\right)} \cdot {n}^{2}\right)\right) \cdot \frac{-2}{{Om}^{2}}} \]
                                                                          13. unpow2N/A

                                                                            \[\leadsto \sqrt{\left(\left(U \cdot \left(\ell \cdot \ell\right)\right) \cdot \left(\left(U - U*\right) \cdot \color{blue}{\left(n \cdot n\right)}\right)\right) \cdot \frac{-2}{{Om}^{2}}} \]
                                                                          14. lower-*.f64N/A

                                                                            \[\leadsto \sqrt{\left(\left(U \cdot \left(\ell \cdot \ell\right)\right) \cdot \left(\left(U - U*\right) \cdot \color{blue}{\left(n \cdot n\right)}\right)\right) \cdot \frac{-2}{{Om}^{2}}} \]
                                                                          15. lower-/.f64N/A

                                                                            \[\leadsto \sqrt{\left(\left(U \cdot \left(\ell \cdot \ell\right)\right) \cdot \left(\left(U - U*\right) \cdot \left(n \cdot n\right)\right)\right) \cdot \color{blue}{\frac{-2}{{Om}^{2}}}} \]
                                                                          16. unpow2N/A

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

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

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

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

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

                                                                        Alternative 14: 46.9% accurate, 2.8× speedup?

                                                                        \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\ell \leq 1.15 \cdot 10^{+162}:\\ \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{U}{Om} \cdot \ell\right) \cdot \left(\ell \cdot n\right), -4, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\frac{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right) \cdot \left(U* \cdot U\right)}{Om \cdot Om} \cdot 2}\\ \end{array} \end{array} \]
                                                                        (FPCore (n U t l Om U*)
                                                                         :precision binary64
                                                                         (if (<= l 1.15e+162)
                                                                           (sqrt (fma (* (* (/ U Om) l) (* l n)) -4.0 (* (* (* t n) U) 2.0)))
                                                                           (sqrt (* (/ (* (* (* l n) (* l n)) (* U* U)) (* Om Om)) 2.0))))
                                                                        double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                                        	double tmp;
                                                                        	if (l <= 1.15e+162) {
                                                                        		tmp = sqrt(fma((((U / Om) * l) * (l * n)), -4.0, (((t * n) * U) * 2.0)));
                                                                        	} else {
                                                                        		tmp = sqrt((((((l * n) * (l * n)) * (U_42_ * U)) / (Om * Om)) * 2.0));
                                                                        	}
                                                                        	return tmp;
                                                                        }
                                                                        
                                                                        function code(n, U, t, l, Om, U_42_)
                                                                        	tmp = 0.0
                                                                        	if (l <= 1.15e+162)
                                                                        		tmp = sqrt(fma(Float64(Float64(Float64(U / Om) * l) * Float64(l * n)), -4.0, Float64(Float64(Float64(t * n) * U) * 2.0)));
                                                                        	else
                                                                        		tmp = sqrt(Float64(Float64(Float64(Float64(Float64(l * n) * Float64(l * n)) * Float64(U_42_ * U)) / Float64(Om * Om)) * 2.0));
                                                                        	end
                                                                        	return tmp
                                                                        end
                                                                        
                                                                        code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 1.15e+162], N[Sqrt[N[(N[(N[(N[(U / Om), $MachinePrecision] * l), $MachinePrecision] * N[(l * n), $MachinePrecision]), $MachinePrecision] * -4.0 + N[(N[(N[(t * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(N[(N[(l * n), $MachinePrecision] * N[(l * n), $MachinePrecision]), $MachinePrecision] * N[(U$42$ * U), $MachinePrecision]), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision]]
                                                                        
                                                                        \begin{array}{l}
                                                                        
                                                                        \\
                                                                        \begin{array}{l}
                                                                        \mathbf{if}\;\ell \leq 1.15 \cdot 10^{+162}:\\
                                                                        \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{U}{Om} \cdot \ell\right) \cdot \left(\ell \cdot n\right), -4, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\
                                                                        
                                                                        \mathbf{else}:\\
                                                                        \;\;\;\;\sqrt{\frac{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right) \cdot \left(U* \cdot U\right)}{Om \cdot Om} \cdot 2}\\
                                                                        
                                                                        
                                                                        \end{array}
                                                                        \end{array}
                                                                        
                                                                        Derivation
                                                                        1. Split input into 2 regimes
                                                                        2. if l < 1.14999999999999997e162

                                                                          1. Initial program 45.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. Add Preprocessing
                                                                          3. Taylor expanded in Om around inf

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

                                                                              \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om} \cdot -4} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                                                            2. lower-fma.f64N/A

                                                                              \[\leadsto \sqrt{\color{blue}{\mathsf{fma}\left(\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)}} \]
                                                                            3. lower-/.f64N/A

                                                                              \[\leadsto \sqrt{\mathsf{fma}\left(\color{blue}{\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om}}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                            4. *-commutativeN/A

                                                                              \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left({\ell}^{2} \cdot n\right) \cdot U}}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                            5. lower-*.f64N/A

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

                                                                              \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left(n \cdot {\ell}^{2}\right)} \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                            7. lower-*.f64N/A

                                                                              \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left(n \cdot {\ell}^{2}\right)} \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                            8. unpow2N/A

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

                                                                              \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \color{blue}{\left(\ell \cdot \ell\right)}\right) \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                            10. *-commutativeN/A

                                                                              \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot U}{Om}, -4, \color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}\right)} \]
                                                                            11. lower-*.f64N/A

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

                                                                              \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot U}{Om}, -4, \color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2\right)} \]
                                                                            13. lower-*.f64N/A

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

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

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

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

                                                                            if 1.14999999999999997e162 < l

                                                                            1. Initial program 12.5%

                                                                              \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
                                                                            2. Add Preprocessing
                                                                            3. Taylor expanded in t around 0

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

                                                                                \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                                                              2. lower-fma.f64N/A

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

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

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

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

                                                                                  \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                                                                                2. lower-*.f64N/A

                                                                                  \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                                                                                3. lower-/.f64N/A

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

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

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

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

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

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

                                                                                  \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(\ell \cdot \ell\right) \cdot \color{blue}{\left(n \cdot n\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                                                10. unswap-sqrN/A

                                                                                  \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                                                                                11. lower-*.f64N/A

                                                                                  \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                                                                                12. *-commutativeN/A

                                                                                  \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                                                                                13. lower-*.f64N/A

                                                                                  \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                                                                                14. *-commutativeN/A

                                                                                  \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                                                15. lower-*.f64N/A

                                                                                  \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                                                16. unpow2N/A

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

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

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

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

                                                                            Alternative 15: 44.0% accurate, 2.8× speedup?

                                                                            \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\ell \leq 2 \cdot 10^{+146}:\\ \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{U}{Om} \cdot \left(\ell \cdot \ell\right)\right) \cdot n, -4, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\frac{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right) \cdot \left(U* \cdot U\right)}{Om \cdot Om} \cdot 2}\\ \end{array} \end{array} \]
                                                                            (FPCore (n U t l Om U*)
                                                                             :precision binary64
                                                                             (if (<= l 2e+146)
                                                                               (sqrt (fma (* (* (/ U Om) (* l l)) n) -4.0 (* (* (* t n) U) 2.0)))
                                                                               (sqrt (* (/ (* (* (* l n) (* l n)) (* U* U)) (* Om Om)) 2.0))))
                                                                            double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                                            	double tmp;
                                                                            	if (l <= 2e+146) {
                                                                            		tmp = sqrt(fma((((U / Om) * (l * l)) * n), -4.0, (((t * n) * U) * 2.0)));
                                                                            	} else {
                                                                            		tmp = sqrt((((((l * n) * (l * n)) * (U_42_ * U)) / (Om * Om)) * 2.0));
                                                                            	}
                                                                            	return tmp;
                                                                            }
                                                                            
                                                                            function code(n, U, t, l, Om, U_42_)
                                                                            	tmp = 0.0
                                                                            	if (l <= 2e+146)
                                                                            		tmp = sqrt(fma(Float64(Float64(Float64(U / Om) * Float64(l * l)) * n), -4.0, Float64(Float64(Float64(t * n) * U) * 2.0)));
                                                                            	else
                                                                            		tmp = sqrt(Float64(Float64(Float64(Float64(Float64(l * n) * Float64(l * n)) * Float64(U_42_ * U)) / Float64(Om * Om)) * 2.0));
                                                                            	end
                                                                            	return tmp
                                                                            end
                                                                            
                                                                            code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 2e+146], N[Sqrt[N[(N[(N[(N[(U / Om), $MachinePrecision] * N[(l * l), $MachinePrecision]), $MachinePrecision] * n), $MachinePrecision] * -4.0 + N[(N[(N[(t * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(N[(N[(l * n), $MachinePrecision] * N[(l * n), $MachinePrecision]), $MachinePrecision] * N[(U$42$ * U), $MachinePrecision]), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision]]
                                                                            
                                                                            \begin{array}{l}
                                                                            
                                                                            \\
                                                                            \begin{array}{l}
                                                                            \mathbf{if}\;\ell \leq 2 \cdot 10^{+146}:\\
                                                                            \;\;\;\;\sqrt{\mathsf{fma}\left(\left(\frac{U}{Om} \cdot \left(\ell \cdot \ell\right)\right) \cdot n, -4, \left(\left(t \cdot n\right) \cdot U\right) \cdot 2\right)}\\
                                                                            
                                                                            \mathbf{else}:\\
                                                                            \;\;\;\;\sqrt{\frac{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right) \cdot \left(U* \cdot U\right)}{Om \cdot Om} \cdot 2}\\
                                                                            
                                                                            
                                                                            \end{array}
                                                                            \end{array}
                                                                            
                                                                            Derivation
                                                                            1. Split input into 2 regimes
                                                                            2. if l < 1.99999999999999987e146

                                                                              1. Initial program 46.1%

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

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

                                                                                  \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om} \cdot -4} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                                                                2. lower-fma.f64N/A

                                                                                  \[\leadsto \sqrt{\color{blue}{\mathsf{fma}\left(\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)}} \]
                                                                                3. lower-/.f64N/A

                                                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\color{blue}{\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om}}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                                4. *-commutativeN/A

                                                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left({\ell}^{2} \cdot n\right) \cdot U}}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                                5. lower-*.f64N/A

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

                                                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left(n \cdot {\ell}^{2}\right)} \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                                7. lower-*.f64N/A

                                                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left(n \cdot {\ell}^{2}\right)} \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                                8. unpow2N/A

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

                                                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \color{blue}{\left(\ell \cdot \ell\right)}\right) \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                                10. *-commutativeN/A

                                                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot U}{Om}, -4, \color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}\right)} \]
                                                                                11. lower-*.f64N/A

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

                                                                                  \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot U}{Om}, -4, \color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2\right)} \]
                                                                                13. lower-*.f64N/A

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

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

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

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

                                                                                if 1.99999999999999987e146 < l

                                                                                1. Initial program 12.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. Add Preprocessing
                                                                                3. Taylor expanded in t around 0

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

                                                                                    \[\leadsto \sqrt{\color{blue}{\left(-2 \cdot U\right) \cdot \left(n \cdot \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{{\ell}^{2} \cdot \left(n \cdot \left(U - U*\right)\right)}{{Om}^{2}}\right)\right)} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                                                                  2. lower-fma.f64N/A

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

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

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

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

                                                                                      \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                                                                                    2. lower-*.f64N/A

                                                                                      \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left(U* \cdot \left({\ell}^{2} \cdot {n}^{2}\right)\right)}{{Om}^{2}} \cdot 2}} \]
                                                                                    3. lower-/.f64N/A

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

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

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

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

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

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

                                                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(\ell \cdot \ell\right) \cdot \color{blue}{\left(n \cdot n\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                                                    10. unswap-sqrN/A

                                                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                                                                                    11. lower-*.f64N/A

                                                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \color{blue}{\left(\left(\ell \cdot n\right) \cdot \left(\ell \cdot n\right)\right)}}{{Om}^{2}} \cdot 2} \]
                                                                                    12. *-commutativeN/A

                                                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                                                                                    13. lower-*.f64N/A

                                                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\color{blue}{\left(n \cdot \ell\right)} \cdot \left(\ell \cdot n\right)\right)}{{Om}^{2}} \cdot 2} \]
                                                                                    14. *-commutativeN/A

                                                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                                                    15. lower-*.f64N/A

                                                                                      \[\leadsto \sqrt{\frac{\left(U* \cdot U\right) \cdot \left(\left(n \cdot \ell\right) \cdot \color{blue}{\left(n \cdot \ell\right)}\right)}{{Om}^{2}} \cdot 2} \]
                                                                                    16. unpow2N/A

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

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

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

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

                                                                                Alternative 16: 38.6% accurate, 3.4× speedup?

                                                                                \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;U \leq -7.5 \cdot 10^{-290}:\\ \;\;\;\;\sqrt{\left(\left(t \cdot n\right) \cdot U\right) \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;\left(\sqrt{t \cdot n} \cdot \sqrt{U}\right) \cdot \sqrt{2}\\ \end{array} \end{array} \]
                                                                                (FPCore (n U t l Om U*)
                                                                                 :precision binary64
                                                                                 (if (<= U -7.5e-290)
                                                                                   (sqrt (* (* (* t n) U) 2.0))
                                                                                   (* (* (sqrt (* t n)) (sqrt U)) (sqrt 2.0))))
                                                                                double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                                                	double tmp;
                                                                                	if (U <= -7.5e-290) {
                                                                                		tmp = sqrt((((t * n) * U) * 2.0));
                                                                                	} else {
                                                                                		tmp = (sqrt((t * n)) * sqrt(U)) * sqrt(2.0);
                                                                                	}
                                                                                	return tmp;
                                                                                }
                                                                                
                                                                                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 (u <= (-7.5d-290)) then
                                                                                        tmp = sqrt((((t * n) * u) * 2.0d0))
                                                                                    else
                                                                                        tmp = (sqrt((t * n)) * sqrt(u)) * sqrt(2.0d0)
                                                                                    end if
                                                                                    code = tmp
                                                                                end function
                                                                                
                                                                                public static double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                                                	double tmp;
                                                                                	if (U <= -7.5e-290) {
                                                                                		tmp = Math.sqrt((((t * n) * U) * 2.0));
                                                                                	} else {
                                                                                		tmp = (Math.sqrt((t * n)) * Math.sqrt(U)) * Math.sqrt(2.0);
                                                                                	}
                                                                                	return tmp;
                                                                                }
                                                                                
                                                                                def code(n, U, t, l, Om, U_42_):
                                                                                	tmp = 0
                                                                                	if U <= -7.5e-290:
                                                                                		tmp = math.sqrt((((t * n) * U) * 2.0))
                                                                                	else:
                                                                                		tmp = (math.sqrt((t * n)) * math.sqrt(U)) * math.sqrt(2.0)
                                                                                	return tmp
                                                                                
                                                                                function code(n, U, t, l, Om, U_42_)
                                                                                	tmp = 0.0
                                                                                	if (U <= -7.5e-290)
                                                                                		tmp = sqrt(Float64(Float64(Float64(t * n) * U) * 2.0));
                                                                                	else
                                                                                		tmp = Float64(Float64(sqrt(Float64(t * n)) * sqrt(U)) * sqrt(2.0));
                                                                                	end
                                                                                	return tmp
                                                                                end
                                                                                
                                                                                function tmp_2 = code(n, U, t, l, Om, U_42_)
                                                                                	tmp = 0.0;
                                                                                	if (U <= -7.5e-290)
                                                                                		tmp = sqrt((((t * n) * U) * 2.0));
                                                                                	else
                                                                                		tmp = (sqrt((t * n)) * sqrt(U)) * sqrt(2.0);
                                                                                	end
                                                                                	tmp_2 = tmp;
                                                                                end
                                                                                
                                                                                code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[U, -7.5e-290], N[Sqrt[N[(N[(N[(t * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision], N[(N[(N[Sqrt[N[(t * n), $MachinePrecision]], $MachinePrecision] * N[Sqrt[U], $MachinePrecision]), $MachinePrecision] * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]]
                                                                                
                                                                                \begin{array}{l}
                                                                                
                                                                                \\
                                                                                \begin{array}{l}
                                                                                \mathbf{if}\;U \leq -7.5 \cdot 10^{-290}:\\
                                                                                \;\;\;\;\sqrt{\left(\left(t \cdot n\right) \cdot U\right) \cdot 2}\\
                                                                                
                                                                                \mathbf{else}:\\
                                                                                \;\;\;\;\left(\sqrt{t \cdot n} \cdot \sqrt{U}\right) \cdot \sqrt{2}\\
                                                                                
                                                                                
                                                                                \end{array}
                                                                                \end{array}
                                                                                
                                                                                Derivation
                                                                                1. Split input into 2 regimes
                                                                                2. if U < -7.4999999999999995e-290

                                                                                  1. Initial program 40.4%

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

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

                                                                                      \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}} \]
                                                                                    2. lower-*.f64N/A

                                                                                      \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}} \]
                                                                                    3. *-commutativeN/A

                                                                                      \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2} \]
                                                                                    4. lower-*.f64N/A

                                                                                      \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2} \]
                                                                                    5. lower-*.f6439.5

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

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

                                                                                  if -7.4999999999999995e-290 < U

                                                                                  1. Initial program 44.6%

                                                                                    \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
                                                                                  2. Add Preprocessing
                                                                                  3. Taylor expanded in U* around 0

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

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

                                                                                      \[\leadsto \color{blue}{\sqrt{2} \cdot \sqrt{U \cdot \left(n \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)\right)}} \]
                                                                                    3. lower-sqrt.f64N/A

                                                                                      \[\leadsto \color{blue}{\sqrt{2}} \cdot \sqrt{U \cdot \left(n \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)\right)} \]
                                                                                    4. lower-sqrt.f64N/A

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

                                                                                      \[\leadsto \sqrt{2} \cdot \sqrt{\color{blue}{\left(U \cdot n\right) \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)}} \]
                                                                                    6. lower-*.f64N/A

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

                                                                                      \[\leadsto \sqrt{2} \cdot \sqrt{\color{blue}{\left(n \cdot U\right)} \cdot \left(t - \left(2 \cdot \frac{{\ell}^{2}}{Om} + \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)\right)} \]
                                                                                    8. lower-*.f64N/A

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

                                                                                      \[\leadsto \sqrt{2} \cdot \sqrt{\left(n \cdot U\right) \cdot \color{blue}{\left(\left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right) - \frac{U \cdot \left({\ell}^{2} \cdot n\right)}{{Om}^{2}}\right)}} \]
                                                                                    10. lower--.f64N/A

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

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

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

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

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

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

                                                                                  Alternative 17: 38.0% accurate, 3.7× speedup?

                                                                                  \[\begin{array}{l} \\ \begin{array}{l} \mathbf{if}\;\ell \leq 6.5 \cdot 10^{+42}:\\ \;\;\;\;\sqrt{\left(\left(t \cdot n\right) \cdot U\right) \cdot 2}\\ \mathbf{else}:\\ \;\;\;\;\sqrt{\frac{\left(\left(\ell \cdot \ell\right) \cdot n\right) \cdot U}{Om} \cdot -4}\\ \end{array} \end{array} \]
                                                                                  (FPCore (n U t l Om U*)
                                                                                   :precision binary64
                                                                                   (if (<= l 6.5e+42)
                                                                                     (sqrt (* (* (* t n) U) 2.0))
                                                                                     (sqrt (* (/ (* (* (* l l) n) U) Om) -4.0))))
                                                                                  double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                                                  	double tmp;
                                                                                  	if (l <= 6.5e+42) {
                                                                                  		tmp = sqrt((((t * n) * U) * 2.0));
                                                                                  	} else {
                                                                                  		tmp = sqrt((((((l * l) * n) * U) / Om) * -4.0));
                                                                                  	}
                                                                                  	return tmp;
                                                                                  }
                                                                                  
                                                                                  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+42) then
                                                                                          tmp = sqrt((((t * n) * u) * 2.0d0))
                                                                                      else
                                                                                          tmp = sqrt((((((l * l) * n) * u) / om) * (-4.0d0)))
                                                                                      end if
                                                                                      code = tmp
                                                                                  end function
                                                                                  
                                                                                  public static double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                                                  	double tmp;
                                                                                  	if (l <= 6.5e+42) {
                                                                                  		tmp = Math.sqrt((((t * n) * U) * 2.0));
                                                                                  	} else {
                                                                                  		tmp = Math.sqrt((((((l * l) * n) * U) / Om) * -4.0));
                                                                                  	}
                                                                                  	return tmp;
                                                                                  }
                                                                                  
                                                                                  def code(n, U, t, l, Om, U_42_):
                                                                                  	tmp = 0
                                                                                  	if l <= 6.5e+42:
                                                                                  		tmp = math.sqrt((((t * n) * U) * 2.0))
                                                                                  	else:
                                                                                  		tmp = math.sqrt((((((l * l) * n) * U) / Om) * -4.0))
                                                                                  	return tmp
                                                                                  
                                                                                  function code(n, U, t, l, Om, U_42_)
                                                                                  	tmp = 0.0
                                                                                  	if (l <= 6.5e+42)
                                                                                  		tmp = sqrt(Float64(Float64(Float64(t * n) * U) * 2.0));
                                                                                  	else
                                                                                  		tmp = sqrt(Float64(Float64(Float64(Float64(Float64(l * l) * n) * U) / Om) * -4.0));
                                                                                  	end
                                                                                  	return tmp
                                                                                  end
                                                                                  
                                                                                  function tmp_2 = code(n, U, t, l, Om, U_42_)
                                                                                  	tmp = 0.0;
                                                                                  	if (l <= 6.5e+42)
                                                                                  		tmp = sqrt((((t * n) * U) * 2.0));
                                                                                  	else
                                                                                  		tmp = sqrt((((((l * l) * n) * U) / Om) * -4.0));
                                                                                  	end
                                                                                  	tmp_2 = tmp;
                                                                                  end
                                                                                  
                                                                                  code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 6.5e+42], N[Sqrt[N[(N[(N[(t * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(N[(N[(N[(l * l), $MachinePrecision] * n), $MachinePrecision] * U), $MachinePrecision] / Om), $MachinePrecision] * -4.0), $MachinePrecision]], $MachinePrecision]]
                                                                                  
                                                                                  \begin{array}{l}
                                                                                  
                                                                                  \\
                                                                                  \begin{array}{l}
                                                                                  \mathbf{if}\;\ell \leq 6.5 \cdot 10^{+42}:\\
                                                                                  \;\;\;\;\sqrt{\left(\left(t \cdot n\right) \cdot U\right) \cdot 2}\\
                                                                                  
                                                                                  \mathbf{else}:\\
                                                                                  \;\;\;\;\sqrt{\frac{\left(\left(\ell \cdot \ell\right) \cdot n\right) \cdot U}{Om} \cdot -4}\\
                                                                                  
                                                                                  
                                                                                  \end{array}
                                                                                  \end{array}
                                                                                  
                                                                                  Derivation
                                                                                  1. Split input into 2 regimes
                                                                                  2. if l < 6.50000000000000052e42

                                                                                    1. Initial program 46.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. Add Preprocessing
                                                                                    3. Taylor expanded in t around inf

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

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}} \]
                                                                                      2. lower-*.f64N/A

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}} \]
                                                                                      3. *-commutativeN/A

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2} \]
                                                                                      4. lower-*.f64N/A

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2} \]
                                                                                      5. lower-*.f6442.6

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

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

                                                                                    if 6.50000000000000052e42 < l

                                                                                    1. Initial program 25.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. Add Preprocessing
                                                                                    3. Taylor expanded in Om around inf

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

                                                                                        \[\leadsto \sqrt{\color{blue}{\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om} \cdot -4} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)} \]
                                                                                      2. lower-fma.f64N/A

                                                                                        \[\leadsto \sqrt{\color{blue}{\mathsf{fma}\left(\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)}} \]
                                                                                      3. lower-/.f64N/A

                                                                                        \[\leadsto \sqrt{\mathsf{fma}\left(\color{blue}{\frac{U \cdot \left({\ell}^{2} \cdot n\right)}{Om}}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                                      4. *-commutativeN/A

                                                                                        \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left({\ell}^{2} \cdot n\right) \cdot U}}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                                      5. lower-*.f64N/A

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

                                                                                        \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left(n \cdot {\ell}^{2}\right)} \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                                      7. lower-*.f64N/A

                                                                                        \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\color{blue}{\left(n \cdot {\ell}^{2}\right)} \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                                      8. unpow2N/A

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

                                                                                        \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \color{blue}{\left(\ell \cdot \ell\right)}\right) \cdot U}{Om}, -4, 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)} \]
                                                                                      10. *-commutativeN/A

                                                                                        \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot U}{Om}, -4, \color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}\right)} \]
                                                                                      11. lower-*.f64N/A

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

                                                                                        \[\leadsto \sqrt{\mathsf{fma}\left(\frac{\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot U}{Om}, -4, \color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2\right)} \]
                                                                                      13. lower-*.f64N/A

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

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

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

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

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

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

                                                                                    Alternative 18: 44.8% accurate, 3.7× speedup?

                                                                                    \[\begin{array}{l} \\ \sqrt{\left(\left(\mathsf{fma}\left(-2, \frac{\ell \cdot \ell}{Om}, t\right) \cdot n\right) \cdot U\right) \cdot 2} \end{array} \]
                                                                                    (FPCore (n U t l Om U*)
                                                                                     :precision binary64
                                                                                     (sqrt (* (* (* (fma -2.0 (/ (* l l) Om) t) n) U) 2.0)))
                                                                                    double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                                                    	return sqrt((((fma(-2.0, ((l * l) / Om), t) * n) * U) * 2.0));
                                                                                    }
                                                                                    
                                                                                    function code(n, U, t, l, Om, U_42_)
                                                                                    	return sqrt(Float64(Float64(Float64(fma(-2.0, Float64(Float64(l * l) / Om), t) * n) * U) * 2.0))
                                                                                    end
                                                                                    
                                                                                    code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(N[(N[(N[(-2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision] + t), $MachinePrecision] * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision]
                                                                                    
                                                                                    \begin{array}{l}
                                                                                    
                                                                                    \\
                                                                                    \sqrt{\left(\left(\mathsf{fma}\left(-2, \frac{\ell \cdot \ell}{Om}, t\right) \cdot n\right) \cdot U\right) \cdot 2}
                                                                                    \end{array}
                                                                                    
                                                                                    Derivation
                                                                                    1. Initial program 42.5%

                                                                                      \[\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)} \]
                                                                                    2. Add Preprocessing
                                                                                    3. Taylor expanded in n around 0

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

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot \left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right)\right)\right) \cdot 2}} \]
                                                                                      2. lower-*.f64N/A

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

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot \left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right)\right) \cdot U\right)} \cdot 2} \]
                                                                                      4. lower-*.f64N/A

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

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

                                                                                        \[\leadsto \sqrt{\left(\color{blue}{\left(\left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right) \cdot n\right)} \cdot U\right) \cdot 2} \]
                                                                                      7. cancel-sign-sub-invN/A

                                                                                        \[\leadsto \sqrt{\left(\left(\color{blue}{\left(t + \left(\mathsf{neg}\left(2\right)\right) \cdot \frac{{\ell}^{2}}{Om}\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                                                      8. metadata-evalN/A

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

                                                                                        \[\leadsto \sqrt{\left(\left(\color{blue}{\left(-2 \cdot \frac{{\ell}^{2}}{Om} + t\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                                                      10. lower-fma.f64N/A

                                                                                        \[\leadsto \sqrt{\left(\left(\color{blue}{\mathsf{fma}\left(-2, \frac{{\ell}^{2}}{Om}, t\right)} \cdot n\right) \cdot U\right) \cdot 2} \]
                                                                                      11. lower-/.f64N/A

                                                                                        \[\leadsto \sqrt{\left(\left(\mathsf{fma}\left(-2, \color{blue}{\frac{{\ell}^{2}}{Om}}, t\right) \cdot n\right) \cdot U\right) \cdot 2} \]
                                                                                      12. unpow2N/A

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

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

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

                                                                                    Alternative 19: 36.1% accurate, 6.8× speedup?

                                                                                    \[\begin{array}{l} \\ \sqrt{\left(\left(t \cdot n\right) \cdot U\right) \cdot 2} \end{array} \]
                                                                                    (FPCore (n U t l Om U*) :precision binary64 (sqrt (* (* (* t n) U) 2.0)))
                                                                                    double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                                                    	return sqrt((((t * n) * U) * 2.0));
                                                                                    }
                                                                                    
                                                                                    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((((t * n) * u) * 2.0d0))
                                                                                    end function
                                                                                    
                                                                                    public static double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                                                    	return Math.sqrt((((t * n) * U) * 2.0));
                                                                                    }
                                                                                    
                                                                                    def code(n, U, t, l, Om, U_42_):
                                                                                    	return math.sqrt((((t * n) * U) * 2.0))
                                                                                    
                                                                                    function code(n, U, t, l, Om, U_42_)
                                                                                    	return sqrt(Float64(Float64(Float64(t * n) * U) * 2.0))
                                                                                    end
                                                                                    
                                                                                    function tmp = code(n, U, t, l, Om, U_42_)
                                                                                    	tmp = sqrt((((t * n) * U) * 2.0));
                                                                                    end
                                                                                    
                                                                                    code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(N[(N[(t * n), $MachinePrecision] * U), $MachinePrecision] * 2.0), $MachinePrecision]], $MachinePrecision]
                                                                                    
                                                                                    \begin{array}{l}
                                                                                    
                                                                                    \\
                                                                                    \sqrt{\left(\left(t \cdot n\right) \cdot U\right) \cdot 2}
                                                                                    \end{array}
                                                                                    
                                                                                    Derivation
                                                                                    1. Initial program 42.5%

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

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

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}} \]
                                                                                      2. lower-*.f64N/A

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}} \]
                                                                                      3. *-commutativeN/A

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2} \]
                                                                                      4. lower-*.f64N/A

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2} \]
                                                                                      5. lower-*.f6437.6

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

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

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

                                                                                    Alternative 20: 35.8% accurate, 6.8× speedup?

                                                                                    \[\begin{array}{l} \\ \sqrt{t \cdot \left(U \cdot \left(n \cdot 2\right)\right)} \end{array} \]
                                                                                    (FPCore (n U t l Om U*) :precision binary64 (sqrt (* t (* U (* n 2.0)))))
                                                                                    double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                                                    	return sqrt((t * (U * (n * 2.0))));
                                                                                    }
                                                                                    
                                                                                    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((t * (u * (n * 2.0d0))))
                                                                                    end function
                                                                                    
                                                                                    public static double code(double n, double U, double t, double l, double Om, double U_42_) {
                                                                                    	return Math.sqrt((t * (U * (n * 2.0))));
                                                                                    }
                                                                                    
                                                                                    def code(n, U, t, l, Om, U_42_):
                                                                                    	return math.sqrt((t * (U * (n * 2.0))))
                                                                                    
                                                                                    function code(n, U, t, l, Om, U_42_)
                                                                                    	return sqrt(Float64(t * Float64(U * Float64(n * 2.0))))
                                                                                    end
                                                                                    
                                                                                    function tmp = code(n, U, t, l, Om, U_42_)
                                                                                    	tmp = sqrt((t * (U * (n * 2.0))));
                                                                                    end
                                                                                    
                                                                                    code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(t * N[(U * N[(n * 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
                                                                                    
                                                                                    \begin{array}{l}
                                                                                    
                                                                                    \\
                                                                                    \sqrt{t \cdot \left(U \cdot \left(n \cdot 2\right)\right)}
                                                                                    \end{array}
                                                                                    
                                                                                    Derivation
                                                                                    1. Initial program 42.5%

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

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

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}} \]
                                                                                      2. lower-*.f64N/A

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(U \cdot \left(n \cdot t\right)\right) \cdot 2}} \]
                                                                                      3. *-commutativeN/A

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2} \]
                                                                                      4. lower-*.f64N/A

                                                                                        \[\leadsto \sqrt{\color{blue}{\left(\left(n \cdot t\right) \cdot U\right)} \cdot 2} \]
                                                                                      5. lower-*.f6437.6

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

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

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

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

                                                                                      Reproduce

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