
(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:
Herbie found 21 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(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}
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1 (* n (/ l Om)))
(t_2 (* (* 2.0 n) U))
(t_3 (/ (* l l) Om))
(t_4
(* t_2 (+ (- t (* 2.0 t_3)) (* (* n (pow (/ l Om) 2.0)) (- U* U)))))
(t_5 (fma (* l -2.0) (/ l Om) t)))
(if (<= t_4 -5e-171)
(sqrt (* t_2 (fma (* (/ l Om) U*) t_1 t_5)))
(if (<= t_4 4e-306)
(sqrt (* (* n (fma -2.0 t_3 t)) (* 2.0 U)))
(if (<= t_4 INFINITY)
(sqrt (* t_2 (fma (* (/ l Om) (- U* U)) t_1 t_5)))
(sqrt
(*
(* U -2.0)
(* (* l (fma n (/ (- U U*) (* Om Om)) (/ 2.0 Om))) (* n l)))))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = n * (l / Om);
double t_2 = (2.0 * n) * U;
double t_3 = (l * l) / Om;
double t_4 = t_2 * ((t - (2.0 * t_3)) + ((n * pow((l / Om), 2.0)) * (U_42_ - U)));
double t_5 = fma((l * -2.0), (l / Om), t);
double tmp;
if (t_4 <= -5e-171) {
tmp = sqrt((t_2 * fma(((l / Om) * U_42_), t_1, t_5)));
} else if (t_4 <= 4e-306) {
tmp = sqrt(((n * fma(-2.0, t_3, t)) * (2.0 * U)));
} else if (t_4 <= ((double) INFINITY)) {
tmp = sqrt((t_2 * fma(((l / Om) * (U_42_ - U)), t_1, t_5)));
} else {
tmp = sqrt(((U * -2.0) * ((l * fma(n, ((U - U_42_) / (Om * Om)), (2.0 / Om))) * (n * l))));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) t_1 = Float64(n * Float64(l / Om)) t_2 = Float64(Float64(2.0 * n) * U) t_3 = Float64(Float64(l * l) / Om) t_4 = Float64(t_2 * Float64(Float64(t - Float64(2.0 * t_3)) + Float64(Float64(n * (Float64(l / Om) ^ 2.0)) * Float64(U_42_ - U)))) t_5 = fma(Float64(l * -2.0), Float64(l / Om), t) tmp = 0.0 if (t_4 <= -5e-171) tmp = sqrt(Float64(t_2 * fma(Float64(Float64(l / Om) * U_42_), t_1, t_5))); elseif (t_4 <= 4e-306) tmp = sqrt(Float64(Float64(n * fma(-2.0, t_3, t)) * Float64(2.0 * U))); elseif (t_4 <= Inf) tmp = sqrt(Float64(t_2 * fma(Float64(Float64(l / Om) * Float64(U_42_ - U)), t_1, t_5))); else tmp = sqrt(Float64(Float64(U * -2.0) * Float64(Float64(l * fma(n, Float64(Float64(U - U_42_) / Float64(Om * Om)), Float64(2.0 / Om))) * Float64(n * l)))); end return tmp end
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(n * N[(l / Om), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]}, Block[{t$95$3 = N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]}, Block[{t$95$4 = N[(t$95$2 * N[(N[(t - N[(2.0 * t$95$3), $MachinePrecision]), $MachinePrecision] + N[(N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$5 = N[(N[(l * -2.0), $MachinePrecision] * N[(l / Om), $MachinePrecision] + t), $MachinePrecision]}, If[LessEqual[t$95$4, -5e-171], N[Sqrt[N[(t$95$2 * N[(N[(N[(l / Om), $MachinePrecision] * U$42$), $MachinePrecision] * t$95$1 + t$95$5), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$4, 4e-306], N[Sqrt[N[(N[(n * N[(-2.0 * t$95$3 + t), $MachinePrecision]), $MachinePrecision] * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$4, Infinity], N[Sqrt[N[(t$95$2 * N[(N[(N[(l / Om), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision] * t$95$1 + t$95$5), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(U * -2.0), $MachinePrecision] * N[(N[(l * N[(n * N[(N[(U - U$42$), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] + N[(2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(n * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := n \cdot \frac{\ell}{Om}\\
t_2 := \left(2 \cdot n\right) \cdot U\\
t_3 := \frac{\ell \cdot \ell}{Om}\\
t_4 := t\_2 \cdot \left(\left(t - 2 \cdot t\_3\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right)\\
t_5 := \mathsf{fma}\left(\ell \cdot -2, \frac{\ell}{Om}, t\right)\\
\mathbf{if}\;t\_4 \leq -5 \cdot 10^{-171}:\\
\;\;\;\;\sqrt{t\_2 \cdot \mathsf{fma}\left(\frac{\ell}{Om} \cdot U*, t\_1, t\_5\right)}\\
\mathbf{elif}\;t\_4 \leq 4 \cdot 10^{-306}:\\
\;\;\;\;\sqrt{\left(n \cdot \mathsf{fma}\left(-2, t\_3, t\right)\right) \cdot \left(2 \cdot U\right)}\\
\mathbf{elif}\;t\_4 \leq \infty:\\
\;\;\;\;\sqrt{t\_2 \cdot \mathsf{fma}\left(\frac{\ell}{Om} \cdot \left(U* - U\right), t\_1, t\_5\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(U \cdot -2\right) \cdot \left(\left(\ell \cdot \mathsf{fma}\left(n, \frac{U - U*}{Om \cdot Om}, \frac{2}{Om}\right)\right) \cdot \left(n \cdot \ell\right)\right)}\\
\end{array}
\end{array}
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*)))) < -4.99999999999999992e-171Initial program 0.0%
lift--.f64N/A
sub-negN/A
+-commutativeN/A
lift-*.f64N/A
*-commutativeN/A
distribute-lft-neg-inN/A
lift-*.f64N/A
*-commutativeN/A
lift-pow.f64N/A
unpow2N/A
associate-*l*N/A
associate-*r*N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-neg.f64N/A
lower-*.f6471.0
lift--.f64N/A
Applied rewrites86.1%
Taylor expanded in U around 0
associate-/l*N/A
lower-*.f64N/A
lower-/.f6486.1
Applied rewrites86.1%
if -4.99999999999999992e-171 < (*.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.00000000000000011e-306Initial program 14.7%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6435.8
Applied rewrites35.8%
Taylor expanded in n around 0
associate-*r*N/A
cancel-sign-sub-invN/A
metadata-evalN/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
+-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6445.0
Applied rewrites45.0%
if 4.00000000000000011e-306 < (*.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.0Initial program 67.8%
lift--.f64N/A
sub-negN/A
+-commutativeN/A
lift-*.f64N/A
*-commutativeN/A
distribute-lft-neg-inN/A
lift-*.f64N/A
*-commutativeN/A
lift-pow.f64N/A
unpow2N/A
associate-*l*N/A
associate-*r*N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-neg.f64N/A
lower-*.f6468.8
lift--.f64N/A
Applied rewrites73.9%
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*)))) Initial program 0.0%
Taylor expanded in l around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
associate-/l*N/A
lower-fma.f64N/A
lower-/.f64N/A
lower--.f64N/A
unpow2N/A
lower-*.f64N/A
associate-*r/N/A
metadata-evalN/A
lower-/.f6427.3
Applied rewrites27.3%
Applied rewrites47.7%
Final simplification66.1%
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1 (/ (* l l) Om))
(t_2 (* (* 2.0 n) U))
(t_3
(* t_2 (+ (- t (* 2.0 t_1)) (* (* n (pow (/ l Om) 2.0)) (- U* U)))))
(t_4
(sqrt
(*
t_2
(fma (* (/ l Om) U*) (* n (/ l Om)) (fma (* l -2.0) (/ l Om) t))))))
(if (<= t_3 -5e-171)
t_4
(if (<= t_3 4e-306)
(sqrt (* (* n (fma -2.0 t_1 t)) (* 2.0 U)))
(if (<= t_3 INFINITY)
t_4
(sqrt
(*
(* U -2.0)
(* (* l (fma n (/ (- U U*) (* Om Om)) (/ 2.0 Om))) (* n l)))))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = (l * l) / Om;
double t_2 = (2.0 * n) * U;
double t_3 = t_2 * ((t - (2.0 * t_1)) + ((n * pow((l / Om), 2.0)) * (U_42_ - U)));
double t_4 = sqrt((t_2 * fma(((l / Om) * U_42_), (n * (l / Om)), fma((l * -2.0), (l / Om), t))));
double tmp;
if (t_3 <= -5e-171) {
tmp = t_4;
} else if (t_3 <= 4e-306) {
tmp = sqrt(((n * fma(-2.0, t_1, t)) * (2.0 * U)));
} else if (t_3 <= ((double) INFINITY)) {
tmp = t_4;
} else {
tmp = sqrt(((U * -2.0) * ((l * fma(n, ((U - U_42_) / (Om * Om)), (2.0 / Om))) * (n * l))));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) t_1 = Float64(Float64(l * l) / Om) t_2 = Float64(Float64(2.0 * n) * U) t_3 = Float64(t_2 * Float64(Float64(t - Float64(2.0 * t_1)) + Float64(Float64(n * (Float64(l / Om) ^ 2.0)) * Float64(U_42_ - U)))) t_4 = sqrt(Float64(t_2 * fma(Float64(Float64(l / Om) * U_42_), Float64(n * Float64(l / Om)), fma(Float64(l * -2.0), Float64(l / Om), t)))) tmp = 0.0 if (t_3 <= -5e-171) tmp = t_4; elseif (t_3 <= 4e-306) tmp = sqrt(Float64(Float64(n * fma(-2.0, t_1, t)) * Float64(2.0 * U))); elseif (t_3 <= Inf) tmp = t_4; else tmp = sqrt(Float64(Float64(U * -2.0) * Float64(Float64(l * fma(n, Float64(Float64(U - U_42_) / Float64(Om * Om)), Float64(2.0 / Om))) * Float64(n * l)))); 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[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]}, Block[{t$95$3 = N[(t$95$2 * N[(N[(t - N[(2.0 * t$95$1), $MachinePrecision]), $MachinePrecision] + N[(N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$4 = N[Sqrt[N[(t$95$2 * N[(N[(N[(l / Om), $MachinePrecision] * U$42$), $MachinePrecision] * N[(n * N[(l / Om), $MachinePrecision]), $MachinePrecision] + N[(N[(l * -2.0), $MachinePrecision] * N[(l / Om), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$3, -5e-171], t$95$4, If[LessEqual[t$95$3, 4e-306], N[Sqrt[N[(N[(n * N[(-2.0 * t$95$1 + t), $MachinePrecision]), $MachinePrecision] * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$3, Infinity], t$95$4, N[Sqrt[N[(N[(U * -2.0), $MachinePrecision] * N[(N[(l * N[(n * N[(N[(U - U$42$), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] + N[(2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(n * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\ell \cdot \ell}{Om}\\
t_2 := \left(2 \cdot n\right) \cdot U\\
t_3 := t\_2 \cdot \left(\left(t - 2 \cdot t\_1\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right)\\
t_4 := \sqrt{t\_2 \cdot \mathsf{fma}\left(\frac{\ell}{Om} \cdot U*, n \cdot \frac{\ell}{Om}, \mathsf{fma}\left(\ell \cdot -2, \frac{\ell}{Om}, t\right)\right)}\\
\mathbf{if}\;t\_3 \leq -5 \cdot 10^{-171}:\\
\;\;\;\;t\_4\\
\mathbf{elif}\;t\_3 \leq 4 \cdot 10^{-306}:\\
\;\;\;\;\sqrt{\left(n \cdot \mathsf{fma}\left(-2, t\_1, t\right)\right) \cdot \left(2 \cdot U\right)}\\
\mathbf{elif}\;t\_3 \leq \infty:\\
\;\;\;\;t\_4\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(U \cdot -2\right) \cdot \left(\left(\ell \cdot \mathsf{fma}\left(n, \frac{U - U*}{Om \cdot Om}, \frac{2}{Om}\right)\right) \cdot \left(n \cdot \ell\right)\right)}\\
\end{array}
\end{array}
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*)))) < -4.99999999999999992e-171 or 4.00000000000000011e-306 < (*.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.0Initial program 65.2%
lift--.f64N/A
sub-negN/A
+-commutativeN/A
lift-*.f64N/A
*-commutativeN/A
distribute-lft-neg-inN/A
lift-*.f64N/A
*-commutativeN/A
lift-pow.f64N/A
unpow2N/A
associate-*l*N/A
associate-*r*N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-neg.f64N/A
lower-*.f6468.8
lift--.f64N/A
Applied rewrites74.4%
Taylor expanded in U around 0
associate-/l*N/A
lower-*.f64N/A
lower-/.f6473.6
Applied rewrites73.6%
if -4.99999999999999992e-171 < (*.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.00000000000000011e-306Initial program 14.7%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6435.8
Applied rewrites35.8%
Taylor expanded in n around 0
associate-*r*N/A
cancel-sign-sub-invN/A
metadata-evalN/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
+-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6445.0
Applied rewrites45.0%
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*)))) Initial program 0.0%
Taylor expanded in l around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
associate-/l*N/A
lower-fma.f64N/A
lower-/.f64N/A
lower--.f64N/A
unpow2N/A
lower-*.f64N/A
associate-*r/N/A
metadata-evalN/A
lower-/.f6427.3
Applied rewrites27.3%
Applied rewrites47.7%
Final simplification65.6%
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1 (/ (* l l) Om)) (t_2 (* (* 2.0 n) U)))
(if (<=
(sqrt
(* t_2 (+ (- t (* 2.0 t_1)) (* (* n (pow (/ l Om) 2.0)) (- U* U)))))
2e-153)
(sqrt (* (* n (fma -2.0 t_1 t)) (* 2.0 U)))
(sqrt (* t_2 (- t (* l (* l (/ (fma (- U U*) (/ n Om) 2.0) Om)))))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = (l * l) / Om;
double t_2 = (2.0 * n) * U;
double tmp;
if (sqrt((t_2 * ((t - (2.0 * t_1)) + ((n * pow((l / Om), 2.0)) * (U_42_ - U))))) <= 2e-153) {
tmp = sqrt(((n * fma(-2.0, t_1, t)) * (2.0 * U)));
} else {
tmp = sqrt((t_2 * (t - (l * (l * (fma((U - U_42_), (n / Om), 2.0) / Om))))));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) t_1 = Float64(Float64(l * l) / Om) t_2 = Float64(Float64(2.0 * n) * U) tmp = 0.0 if (sqrt(Float64(t_2 * Float64(Float64(t - Float64(2.0 * t_1)) + Float64(Float64(n * (Float64(l / Om) ^ 2.0)) * Float64(U_42_ - U))))) <= 2e-153) tmp = sqrt(Float64(Float64(n * fma(-2.0, t_1, t)) * Float64(2.0 * U))); else tmp = sqrt(Float64(t_2 * Float64(t - Float64(l * Float64(l * Float64(fma(Float64(U - U_42_), Float64(n / Om), 2.0) / Om)))))); 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[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]}, If[LessEqual[N[Sqrt[N[(t$95$2 * N[(N[(t - N[(2.0 * t$95$1), $MachinePrecision]), $MachinePrecision] + N[(N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], 2e-153], N[Sqrt[N[(N[(n * N[(-2.0 * t$95$1 + t), $MachinePrecision]), $MachinePrecision] * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(t$95$2 * N[(t - N[(l * N[(l * N[(N[(N[(U - U$42$), $MachinePrecision] * N[(n / Om), $MachinePrecision] + 2.0), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\ell \cdot \ell}{Om}\\
t_2 := \left(2 \cdot n\right) \cdot U\\
\mathbf{if}\;\sqrt{t\_2 \cdot \left(\left(t - 2 \cdot t\_1\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right)} \leq 2 \cdot 10^{-153}:\\
\;\;\;\;\sqrt{\left(n \cdot \mathsf{fma}\left(-2, t\_1, t\right)\right) \cdot \left(2 \cdot U\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{t\_2 \cdot \left(t - \ell \cdot \left(\ell \cdot \frac{\mathsf{fma}\left(U - U*, \frac{n}{Om}, 2\right)}{Om}\right)\right)}\\
\end{array}
\end{array}
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*))))) < 2.00000000000000008e-153Initial program 14.7%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6435.8
Applied rewrites35.8%
Taylor expanded in n around 0
associate-*r*N/A
cancel-sign-sub-invN/A
metadata-evalN/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
+-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6445.0
Applied rewrites45.0%
if 2.00000000000000008e-153 < (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*))))) Initial program 55.1%
Taylor expanded in t around 0
lower--.f64N/A
+-commutativeN/A
unpow2N/A
associate-/r*N/A
metadata-evalN/A
cancel-sign-sub-invN/A
associate-*r/N/A
div-subN/A
lower-/.f64N/A
Applied rewrites58.0%
Applied rewrites63.4%
Final simplification60.4%
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1 (/ (* l l) Om)))
(if (<=
(sqrt
(*
(* (* 2.0 n) U)
(+ (- t (* 2.0 t_1)) (* (* n (pow (/ l Om) 2.0)) (- U* U)))))
INFINITY)
(sqrt (* (* n (fma -2.0 t_1 t)) (* 2.0 U)))
(* (sqrt (* U U*)) (* l (* n (/ (sqrt 2.0) Om)))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = (l * l) / Om;
double tmp;
if (sqrt((((2.0 * n) * U) * ((t - (2.0 * t_1)) + ((n * pow((l / Om), 2.0)) * (U_42_ - U))))) <= ((double) INFINITY)) {
tmp = sqrt(((n * fma(-2.0, t_1, t)) * (2.0 * U)));
} else {
tmp = sqrt((U * U_42_)) * (l * (n * (sqrt(2.0) / Om)));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) t_1 = Float64(Float64(l * l) / Om) tmp = 0.0 if (sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * t_1)) + Float64(Float64(n * (Float64(l / Om) ^ 2.0)) * Float64(U_42_ - U))))) <= Inf) tmp = sqrt(Float64(Float64(n * fma(-2.0, t_1, t)) * Float64(2.0 * U))); else tmp = Float64(sqrt(Float64(U * U_42_)) * Float64(l * Float64(n * Float64(sqrt(2.0) / Om)))); 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[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * t$95$1), $MachinePrecision]), $MachinePrecision] + N[(N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], Infinity], N[Sqrt[N[(N[(n * N[(-2.0 * t$95$1 + t), $MachinePrecision]), $MachinePrecision] * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(U * U$42$), $MachinePrecision]], $MachinePrecision] * N[(l * N[(n * N[(N[Sqrt[2.0], $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\ell \cdot \ell}{Om}\\
\mathbf{if}\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot t\_1\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right)} \leq \infty:\\
\;\;\;\;\sqrt{\left(n \cdot \mathsf{fma}\left(-2, t\_1, t\right)\right) \cdot \left(2 \cdot U\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{U \cdot U*} \cdot \left(\ell \cdot \left(n \cdot \frac{\sqrt{2}}{Om}\right)\right)\\
\end{array}
\end{array}
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*))))) < +inf.0Initial program 57.5%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6441.2
Applied rewrites41.2%
Taylor expanded in n around 0
associate-*r*N/A
cancel-sign-sub-invN/A
metadata-evalN/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
+-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6457.1
Applied rewrites57.1%
if +inf.0 < (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*))))) Initial program 0.0%
Taylor expanded in U* around -inf
mul-1-negN/A
*-commutativeN/A
distribute-rgt-neg-inN/A
mul-1-negN/A
lower-*.f64N/A
lower-sqrt.f64N/A
lower-*.f64N/A
mul-1-negN/A
lower-neg.f64N/A
associate-/l*N/A
lower-*.f64N/A
associate-*r*N/A
associate-/l*N/A
Applied rewrites24.7%
Final simplification52.1%
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1 (/ (* l l) Om)))
(if (<=
(sqrt
(*
(* (* 2.0 n) U)
(+ (- t (* 2.0 t_1)) (* (* n (pow (/ l Om) 2.0)) (- U* U)))))
INFINITY)
(sqrt (* (* n (fma -2.0 t_1 t)) (* 2.0 U)))
(* (sqrt (* U U*)) (* l (/ (* n (sqrt 2.0)) Om))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = (l * l) / Om;
double tmp;
if (sqrt((((2.0 * n) * U) * ((t - (2.0 * t_1)) + ((n * pow((l / Om), 2.0)) * (U_42_ - U))))) <= ((double) INFINITY)) {
tmp = sqrt(((n * fma(-2.0, t_1, t)) * (2.0 * U)));
} else {
tmp = sqrt((U * U_42_)) * (l * ((n * sqrt(2.0)) / Om));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) t_1 = Float64(Float64(l * l) / Om) tmp = 0.0 if (sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * t_1)) + Float64(Float64(n * (Float64(l / Om) ^ 2.0)) * Float64(U_42_ - U))))) <= Inf) tmp = sqrt(Float64(Float64(n * fma(-2.0, t_1, t)) * Float64(2.0 * U))); else tmp = Float64(sqrt(Float64(U * U_42_)) * Float64(l * Float64(Float64(n * sqrt(2.0)) / Om))); 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[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * t$95$1), $MachinePrecision]), $MachinePrecision] + N[(N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], Infinity], N[Sqrt[N[(N[(n * N[(-2.0 * t$95$1 + t), $MachinePrecision]), $MachinePrecision] * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(U * U$42$), $MachinePrecision]], $MachinePrecision] * N[(l * N[(N[(n * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\ell \cdot \ell}{Om}\\
\mathbf{if}\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot t\_1\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right)} \leq \infty:\\
\;\;\;\;\sqrt{\left(n \cdot \mathsf{fma}\left(-2, t\_1, t\right)\right) \cdot \left(2 \cdot U\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{U \cdot U*} \cdot \left(\ell \cdot \frac{n \cdot \sqrt{2}}{Om}\right)\\
\end{array}
\end{array}
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*))))) < +inf.0Initial program 57.5%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6441.2
Applied rewrites41.2%
Taylor expanded in n around 0
associate-*r*N/A
cancel-sign-sub-invN/A
metadata-evalN/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
+-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6457.1
Applied rewrites57.1%
if +inf.0 < (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*))))) Initial program 0.0%
lift-sqrt.f64N/A
pow1/2N/A
lift-*.f64N/A
*-commutativeN/A
unpow-prod-downN/A
lower-*.f64N/A
Applied rewrites0.0%
Taylor expanded in U* around inf
lower-*.f64N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
lower-sqrt.f64N/A
lower-sqrt.f64N/A
lower-*.f6424.6
Applied rewrites24.6%
Final simplification52.1%
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1 (/ (* l l) Om)))
(if (<=
(sqrt
(*
(* (* 2.0 n) U)
(+ (- t (* 2.0 t_1)) (* (* n (pow (/ l Om) 2.0)) (- U* U)))))
INFINITY)
(sqrt (* (* n (fma -2.0 t_1 t)) (* 2.0 U)))
(* (sqrt (* U U*)) (/ (* l (* n (sqrt 2.0))) Om)))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = (l * l) / Om;
double tmp;
if (sqrt((((2.0 * n) * U) * ((t - (2.0 * t_1)) + ((n * pow((l / Om), 2.0)) * (U_42_ - U))))) <= ((double) INFINITY)) {
tmp = sqrt(((n * fma(-2.0, t_1, t)) * (2.0 * U)));
} else {
tmp = sqrt((U * U_42_)) * ((l * (n * sqrt(2.0))) / Om);
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) t_1 = Float64(Float64(l * l) / Om) tmp = 0.0 if (sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * t_1)) + Float64(Float64(n * (Float64(l / Om) ^ 2.0)) * Float64(U_42_ - U))))) <= Inf) tmp = sqrt(Float64(Float64(n * fma(-2.0, t_1, t)) * Float64(2.0 * U))); else tmp = Float64(sqrt(Float64(U * U_42_)) * Float64(Float64(l * Float64(n * sqrt(2.0))) / Om)); 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[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * t$95$1), $MachinePrecision]), $MachinePrecision] + N[(N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], Infinity], N[Sqrt[N[(N[(n * N[(-2.0 * t$95$1 + t), $MachinePrecision]), $MachinePrecision] * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(U * U$42$), $MachinePrecision]], $MachinePrecision] * N[(N[(l * N[(n * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \frac{\ell \cdot \ell}{Om}\\
\mathbf{if}\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot t\_1\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right)} \leq \infty:\\
\;\;\;\;\sqrt{\left(n \cdot \mathsf{fma}\left(-2, t\_1, t\right)\right) \cdot \left(2 \cdot U\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{U \cdot U*} \cdot \frac{\ell \cdot \left(n \cdot \sqrt{2}\right)}{Om}\\
\end{array}
\end{array}
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*))))) < +inf.0Initial program 57.5%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6441.2
Applied rewrites41.2%
Taylor expanded in n around 0
associate-*r*N/A
cancel-sign-sub-invN/A
metadata-evalN/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
+-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6457.1
Applied rewrites57.1%
if +inf.0 < (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*))))) Initial program 0.0%
Taylor expanded in U* around inf
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
lower-*.f64N/A
lower-sqrt.f64N/A
lower-sqrt.f64N/A
lower-*.f6422.4
Applied rewrites22.4%
Final simplification51.7%
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 1.82e-214)
(sqrt (* 2.0 (* n (* U t))))
(if (<= l 1.45e+103)
(sqrt
(* (* (* 2.0 n) U) (- t (* l (* l (/ (fma (- U U*) (/ n Om) 2.0) Om))))))
(if (<= l 6e+278)
(sqrt
(*
(* U -2.0)
(* (* l (fma n (/ (- U U*) (* Om Om)) (/ 2.0 Om))) (* n l))))
(*
(sqrt (* (* n U) (- (/ (* n (- U* U)) (* Om Om)) (/ 2.0 Om))))
(* l (sqrt 2.0)))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 1.82e-214) {
tmp = sqrt((2.0 * (n * (U * t))));
} else if (l <= 1.45e+103) {
tmp = sqrt((((2.0 * n) * U) * (t - (l * (l * (fma((U - U_42_), (n / Om), 2.0) / Om))))));
} else if (l <= 6e+278) {
tmp = sqrt(((U * -2.0) * ((l * fma(n, ((U - U_42_) / (Om * Om)), (2.0 / Om))) * (n * l))));
} else {
tmp = sqrt(((n * U) * (((n * (U_42_ - U)) / (Om * Om)) - (2.0 / Om)))) * (l * sqrt(2.0));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 1.82e-214) tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * t)))); elseif (l <= 1.45e+103) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t - Float64(l * Float64(l * Float64(fma(Float64(U - U_42_), Float64(n / Om), 2.0) / Om)))))); elseif (l <= 6e+278) tmp = sqrt(Float64(Float64(U * -2.0) * Float64(Float64(l * fma(n, Float64(Float64(U - U_42_) / Float64(Om * Om)), Float64(2.0 / Om))) * Float64(n * l)))); else tmp = Float64(sqrt(Float64(Float64(n * U) * Float64(Float64(Float64(n * Float64(U_42_ - U)) / Float64(Om * Om)) - Float64(2.0 / Om)))) * Float64(l * sqrt(2.0))); end return tmp end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 1.82e-214], N[Sqrt[N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 1.45e+103], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t - N[(l * N[(l * N[(N[(N[(U - U$42$), $MachinePrecision] * N[(n / Om), $MachinePrecision] + 2.0), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 6e+278], N[Sqrt[N[(N[(U * -2.0), $MachinePrecision] * N[(N[(l * N[(n * N[(N[(U - U$42$), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] + N[(2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(n * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(N[(n * U), $MachinePrecision] * N[(N[(N[(n * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] - N[(2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 1.82 \cdot 10^{-214}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right)}\\
\mathbf{elif}\;\ell \leq 1.45 \cdot 10^{+103}:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t - \ell \cdot \left(\ell \cdot \frac{\mathsf{fma}\left(U - U*, \frac{n}{Om}, 2\right)}{Om}\right)\right)}\\
\mathbf{elif}\;\ell \leq 6 \cdot 10^{+278}:\\
\;\;\;\;\sqrt{\left(U \cdot -2\right) \cdot \left(\left(\ell \cdot \mathsf{fma}\left(n, \frac{U - U*}{Om \cdot Om}, \frac{2}{Om}\right)\right) \cdot \left(n \cdot \ell\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(n \cdot U\right) \cdot \left(\frac{n \cdot \left(U* - U\right)}{Om \cdot Om} - \frac{2}{Om}\right)} \cdot \left(\ell \cdot \sqrt{2}\right)\\
\end{array}
\end{array}
if l < 1.82e-214Initial program 52.0%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6439.1
Applied rewrites39.1%
Applied rewrites32.9%
Applied rewrites38.0%
if 1.82e-214 < l < 1.4499999999999999e103Initial program 57.7%
Taylor expanded in t around 0
lower--.f64N/A
+-commutativeN/A
unpow2N/A
associate-/r*N/A
metadata-evalN/A
cancel-sign-sub-invN/A
associate-*r/N/A
div-subN/A
lower-/.f64N/A
Applied rewrites60.1%
Applied rewrites60.5%
if 1.4499999999999999e103 < l < 6.0000000000000001e278Initial program 18.2%
Taylor expanded in l around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
associate-/l*N/A
lower-fma.f64N/A
lower-/.f64N/A
lower--.f64N/A
unpow2N/A
lower-*.f64N/A
associate-*r/N/A
metadata-evalN/A
lower-/.f6429.0
Applied rewrites29.0%
Applied rewrites51.0%
if 6.0000000000000001e278 < l Initial program 0.9%
lift-sqrt.f64N/A
pow1/2N/A
lift-*.f64N/A
*-commutativeN/A
unpow-prod-downN/A
lower-*.f64N/A
Applied rewrites0.0%
Taylor expanded in U* around inf
lower-*.f64N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
lower-sqrt.f64N/A
lower-sqrt.f64N/A
lower-*.f6419.5
Applied rewrites19.5%
Taylor expanded in l around inf
lower-*.f64N/A
lower-sqrt.f64N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower-*.f64N/A
lower--.f64N/A
unpow2N/A
lower-*.f64N/A
associate-*r/N/A
metadata-evalN/A
lower-/.f64N/A
lower-*.f64N/A
Applied rewrites79.7%
Final simplification46.7%
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 1.82e-214)
(sqrt (* 2.0 (* n (* U t))))
(if (<= l 1.45e+103)
(sqrt
(* (* (* 2.0 n) U) (- t (* l (* l (/ (fma (- U U*) (/ n Om) 2.0) Om))))))
(if (<= l 6.1e+278)
(sqrt
(*
(* U -2.0)
(* (* l (fma n (/ (- U U*) (* Om Om)) (/ 2.0 Om))) (* n l))))
(*
(* l (sqrt 2.0))
(sqrt (* (* n U) (fma n (/ (- U* U) (* Om Om)) (/ -2.0 Om)))))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 1.82e-214) {
tmp = sqrt((2.0 * (n * (U * t))));
} else if (l <= 1.45e+103) {
tmp = sqrt((((2.0 * n) * U) * (t - (l * (l * (fma((U - U_42_), (n / Om), 2.0) / Om))))));
} else if (l <= 6.1e+278) {
tmp = sqrt(((U * -2.0) * ((l * fma(n, ((U - U_42_) / (Om * Om)), (2.0 / Om))) * (n * l))));
} else {
tmp = (l * sqrt(2.0)) * sqrt(((n * U) * fma(n, ((U_42_ - U) / (Om * Om)), (-2.0 / Om))));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 1.82e-214) tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * t)))); elseif (l <= 1.45e+103) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t - Float64(l * Float64(l * Float64(fma(Float64(U - U_42_), Float64(n / Om), 2.0) / Om)))))); elseif (l <= 6.1e+278) tmp = sqrt(Float64(Float64(U * -2.0) * Float64(Float64(l * fma(n, Float64(Float64(U - U_42_) / Float64(Om * Om)), Float64(2.0 / Om))) * Float64(n * l)))); else tmp = Float64(Float64(l * sqrt(2.0)) * sqrt(Float64(Float64(n * U) * fma(n, Float64(Float64(U_42_ - U) / Float64(Om * Om)), Float64(-2.0 / Om))))); end return tmp end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 1.82e-214], N[Sqrt[N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 1.45e+103], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t - N[(l * N[(l * N[(N[(N[(U - U$42$), $MachinePrecision] * N[(n / Om), $MachinePrecision] + 2.0), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 6.1e+278], N[Sqrt[N[(N[(U * -2.0), $MachinePrecision] * N[(N[(l * N[(n * N[(N[(U - U$42$), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] + N[(2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(n * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(N[(n * U), $MachinePrecision] * N[(n * N[(N[(U$42$ - U), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] + N[(-2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 1.82 \cdot 10^{-214}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right)}\\
\mathbf{elif}\;\ell \leq 1.45 \cdot 10^{+103}:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t - \ell \cdot \left(\ell \cdot \frac{\mathsf{fma}\left(U - U*, \frac{n}{Om}, 2\right)}{Om}\right)\right)}\\
\mathbf{elif}\;\ell \leq 6.1 \cdot 10^{+278}:\\
\;\;\;\;\sqrt{\left(U \cdot -2\right) \cdot \left(\left(\ell \cdot \mathsf{fma}\left(n, \frac{U - U*}{Om \cdot Om}, \frac{2}{Om}\right)\right) \cdot \left(n \cdot \ell\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt{\left(n \cdot U\right) \cdot \mathsf{fma}\left(n, \frac{U* - U}{Om \cdot Om}, \frac{-2}{Om}\right)}\\
\end{array}
\end{array}
if l < 1.82e-214Initial program 52.0%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6439.1
Applied rewrites39.1%
Applied rewrites32.9%
Applied rewrites38.0%
if 1.82e-214 < l < 1.4499999999999999e103Initial program 57.7%
Taylor expanded in t around 0
lower--.f64N/A
+-commutativeN/A
unpow2N/A
associate-/r*N/A
metadata-evalN/A
cancel-sign-sub-invN/A
associate-*r/N/A
div-subN/A
lower-/.f64N/A
Applied rewrites60.1%
Applied rewrites60.5%
if 1.4499999999999999e103 < l < 6.10000000000000039e278Initial program 18.2%
Taylor expanded in l around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
associate-/l*N/A
lower-fma.f64N/A
lower-/.f64N/A
lower--.f64N/A
unpow2N/A
lower-*.f64N/A
associate-*r/N/A
metadata-evalN/A
lower-/.f6429.0
Applied rewrites29.0%
Applied rewrites51.0%
if 6.10000000000000039e278 < l Initial program 0.9%
lift-sqrt.f64N/A
pow1/2N/A
lift-*.f64N/A
*-commutativeN/A
unpow-prod-downN/A
lower-*.f64N/A
Applied rewrites0.0%
Taylor expanded in l around inf
lower-*.f64N/A
Applied rewrites79.7%
Final simplification46.7%
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 1.05e+103)
(sqrt
(*
(+ t (/ (- (* (* (/ l Om) (- U* U)) (* n l)) (* 2.0 (* l l))) Om))
(* n (* 2.0 U))))
(if (<= l 6e+278)
(sqrt
(*
(* U -2.0)
(* (* l (fma n (/ (- U U*) (* Om Om)) (/ 2.0 Om))) (* n l))))
(*
(sqrt (* (* n U) (- (/ (* n (- U* U)) (* Om Om)) (/ 2.0 Om))))
(* l (sqrt 2.0))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 1.05e+103) {
tmp = sqrt(((t + (((((l / Om) * (U_42_ - U)) * (n * l)) - (2.0 * (l * l))) / Om)) * (n * (2.0 * U))));
} else if (l <= 6e+278) {
tmp = sqrt(((U * -2.0) * ((l * fma(n, ((U - U_42_) / (Om * Om)), (2.0 / Om))) * (n * l))));
} else {
tmp = sqrt(((n * U) * (((n * (U_42_ - U)) / (Om * Om)) - (2.0 / Om)))) * (l * sqrt(2.0));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 1.05e+103) tmp = sqrt(Float64(Float64(t + Float64(Float64(Float64(Float64(Float64(l / Om) * Float64(U_42_ - U)) * Float64(n * l)) - Float64(2.0 * Float64(l * l))) / Om)) * Float64(n * Float64(2.0 * U)))); elseif (l <= 6e+278) tmp = sqrt(Float64(Float64(U * -2.0) * Float64(Float64(l * fma(n, Float64(Float64(U - U_42_) / Float64(Om * Om)), Float64(2.0 / Om))) * Float64(n * l)))); else tmp = Float64(sqrt(Float64(Float64(n * U) * Float64(Float64(Float64(n * Float64(U_42_ - U)) / Float64(Om * Om)) - Float64(2.0 / Om)))) * Float64(l * sqrt(2.0))); end return tmp end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 1.05e+103], N[Sqrt[N[(N[(t + N[(N[(N[(N[(N[(l / Om), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision] * N[(n * l), $MachinePrecision]), $MachinePrecision] - N[(2.0 * N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] * N[(n * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 6e+278], N[Sqrt[N[(N[(U * -2.0), $MachinePrecision] * N[(N[(l * N[(n * N[(N[(U - U$42$), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] + N[(2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(n * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(N[(n * U), $MachinePrecision] * N[(N[(N[(n * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] - N[(2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 1.05 \cdot 10^{+103}:\\
\;\;\;\;\sqrt{\left(t + \frac{\left(\frac{\ell}{Om} \cdot \left(U* - U\right)\right) \cdot \left(n \cdot \ell\right) - 2 \cdot \left(\ell \cdot \ell\right)}{Om}\right) \cdot \left(n \cdot \left(2 \cdot U\right)\right)}\\
\mathbf{elif}\;\ell \leq 6 \cdot 10^{+278}:\\
\;\;\;\;\sqrt{\left(U \cdot -2\right) \cdot \left(\left(\ell \cdot \mathsf{fma}\left(n, \frac{U - U*}{Om \cdot Om}, \frac{2}{Om}\right)\right) \cdot \left(n \cdot \ell\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(n \cdot U\right) \cdot \left(\frac{n \cdot \left(U* - U\right)}{Om \cdot Om} - \frac{2}{Om}\right)} \cdot \left(\ell \cdot \sqrt{2}\right)\\
\end{array}
\end{array}
if l < 1.0500000000000001e103Initial program 53.9%
lift--.f64N/A
sub-negN/A
+-commutativeN/A
lift-*.f64N/A
*-commutativeN/A
distribute-lft-neg-inN/A
lift-*.f64N/A
*-commutativeN/A
lift-pow.f64N/A
unpow2N/A
associate-*l*N/A
associate-*r*N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-neg.f64N/A
lower-*.f6456.9
lift--.f64N/A
Applied rewrites59.4%
Applied rewrites57.0%
if 1.0500000000000001e103 < l < 6.0000000000000001e278Initial program 18.2%
Taylor expanded in l around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
associate-/l*N/A
lower-fma.f64N/A
lower-/.f64N/A
lower--.f64N/A
unpow2N/A
lower-*.f64N/A
associate-*r/N/A
metadata-evalN/A
lower-/.f6429.0
Applied rewrites29.0%
Applied rewrites51.0%
if 6.0000000000000001e278 < l Initial program 0.9%
lift-sqrt.f64N/A
pow1/2N/A
lift-*.f64N/A
*-commutativeN/A
unpow-prod-downN/A
lower-*.f64N/A
Applied rewrites0.0%
Taylor expanded in U* around inf
lower-*.f64N/A
associate-/l*N/A
lower-*.f64N/A
lower-/.f64N/A
lower-*.f64N/A
lower-sqrt.f64N/A
lower-sqrt.f64N/A
lower-*.f6419.5
Applied rewrites19.5%
Taylor expanded in l around inf
lower-*.f64N/A
lower-sqrt.f64N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
lower-/.f64N/A
lower-*.f64N/A
lower--.f64N/A
unpow2N/A
lower-*.f64N/A
associate-*r/N/A
metadata-evalN/A
lower-/.f64N/A
lower-*.f64N/A
Applied rewrites79.7%
Final simplification56.7%
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 1.82e-214)
(sqrt (* 2.0 (* n (* U t))))
(if (<= l 1.45e+103)
(sqrt
(* (* (* 2.0 n) U) (- t (* l (* l (/ (fma (- U U*) (/ n Om) 2.0) Om))))))
(sqrt
(*
(* U -2.0)
(* (* l (fma n (/ (- U U*) (* Om Om)) (/ 2.0 Om))) (* n l)))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 1.82e-214) {
tmp = sqrt((2.0 * (n * (U * t))));
} else if (l <= 1.45e+103) {
tmp = sqrt((((2.0 * n) * U) * (t - (l * (l * (fma((U - U_42_), (n / Om), 2.0) / Om))))));
} else {
tmp = sqrt(((U * -2.0) * ((l * fma(n, ((U - U_42_) / (Om * Om)), (2.0 / Om))) * (n * l))));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 1.82e-214) tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * t)))); elseif (l <= 1.45e+103) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t - Float64(l * Float64(l * Float64(fma(Float64(U - U_42_), Float64(n / Om), 2.0) / Om)))))); else tmp = sqrt(Float64(Float64(U * -2.0) * Float64(Float64(l * fma(n, Float64(Float64(U - U_42_) / Float64(Om * Om)), Float64(2.0 / Om))) * Float64(n * l)))); end return tmp end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 1.82e-214], N[Sqrt[N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 1.45e+103], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t - N[(l * N[(l * N[(N[(N[(U - U$42$), $MachinePrecision] * N[(n / Om), $MachinePrecision] + 2.0), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(U * -2.0), $MachinePrecision] * N[(N[(l * N[(n * N[(N[(U - U$42$), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision] + N[(2.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(n * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 1.82 \cdot 10^{-214}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right)}\\
\mathbf{elif}\;\ell \leq 1.45 \cdot 10^{+103}:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t - \ell \cdot \left(\ell \cdot \frac{\mathsf{fma}\left(U - U*, \frac{n}{Om}, 2\right)}{Om}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(U \cdot -2\right) \cdot \left(\left(\ell \cdot \mathsf{fma}\left(n, \frac{U - U*}{Om \cdot Om}, \frac{2}{Om}\right)\right) \cdot \left(n \cdot \ell\right)\right)}\\
\end{array}
\end{array}
if l < 1.82e-214Initial program 52.0%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6439.1
Applied rewrites39.1%
Applied rewrites32.9%
Applied rewrites38.0%
if 1.82e-214 < l < 1.4499999999999999e103Initial program 57.7%
Taylor expanded in t around 0
lower--.f64N/A
+-commutativeN/A
unpow2N/A
associate-/r*N/A
metadata-evalN/A
cancel-sign-sub-invN/A
associate-*r/N/A
div-subN/A
lower-/.f64N/A
Applied rewrites60.1%
Applied rewrites60.5%
if 1.4499999999999999e103 < l Initial program 15.8%
Taylor expanded in l around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
associate-/l*N/A
lower-fma.f64N/A
lower-/.f64N/A
lower--.f64N/A
unpow2N/A
lower-*.f64N/A
associate-*r/N/A
metadata-evalN/A
lower-/.f6425.7
Applied rewrites25.7%
Applied rewrites47.3%
Final simplification45.7%
(FPCore (n U t l Om U*)
:precision binary64
(if (<= n -1.55e-22)
(sqrt (* (* (* 2.0 n) U) (- t (/ (- (/ (* U* (* n (* l l))) Om)) Om))))
(if (<= n 6.9e-298)
(sqrt (fma 2.0 (* U (* n t)) (/ (* (* U (* l (* n l))) -4.0) Om)))
(* (sqrt (* 2.0 n)) (sqrt (* U (fma -2.0 (/ (* l l) Om) t)))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (n <= -1.55e-22) {
tmp = sqrt((((2.0 * n) * U) * (t - (-((U_42_ * (n * (l * l))) / Om) / Om))));
} else if (n <= 6.9e-298) {
tmp = sqrt(fma(2.0, (U * (n * t)), (((U * (l * (n * l))) * -4.0) / Om)));
} else {
tmp = sqrt((2.0 * n)) * sqrt((U * fma(-2.0, ((l * l) / Om), t)));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (n <= -1.55e-22) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t - Float64(Float64(-Float64(Float64(U_42_ * Float64(n * Float64(l * l))) / Om)) / Om)))); elseif (n <= 6.9e-298) tmp = sqrt(fma(2.0, Float64(U * Float64(n * t)), Float64(Float64(Float64(U * Float64(l * Float64(n * l))) * -4.0) / Om))); else tmp = Float64(sqrt(Float64(2.0 * n)) * sqrt(Float64(U * fma(-2.0, Float64(Float64(l * l) / Om), t)))); end return tmp end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[n, -1.55e-22], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t - N[((-N[(N[(U$42$ * N[(n * N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]) / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[n, 6.9e-298], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(U * N[(l * N[(n * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * -4.0), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(2.0 * n), $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(U * N[(-2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;n \leq -1.55 \cdot 10^{-22}:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t - \frac{-\frac{U* \cdot \left(n \cdot \left(\ell \cdot \ell\right)\right)}{Om}}{Om}\right)}\\
\mathbf{elif}\;n \leq 6.9 \cdot 10^{-298}:\\
\;\;\;\;\sqrt{\mathsf{fma}\left(2, U \cdot \left(n \cdot t\right), \frac{\left(U \cdot \left(\ell \cdot \left(n \cdot \ell\right)\right)\right) \cdot -4}{Om}\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot n} \cdot \sqrt{U \cdot \mathsf{fma}\left(-2, \frac{\ell \cdot \ell}{Om}, t\right)}\\
\end{array}
\end{array}
if n < -1.55000000000000006e-22Initial program 59.2%
Taylor expanded in t around 0
lower--.f64N/A
+-commutativeN/A
unpow2N/A
associate-/r*N/A
metadata-evalN/A
cancel-sign-sub-invN/A
associate-*r/N/A
div-subN/A
lower-/.f64N/A
Applied rewrites60.4%
Taylor expanded in U* around inf
Applied rewrites60.6%
if -1.55000000000000006e-22 < n < 6.90000000000000022e-298Initial program 38.8%
Taylor expanded in Om around inf
+-commutativeN/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f64N/A
associate-*r/N/A
lower-/.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f6449.3
Applied rewrites49.3%
Applied rewrites59.0%
if 6.90000000000000022e-298 < n Initial program 50.5%
lift--.f64N/A
sub-negN/A
+-commutativeN/A
lift-*.f64N/A
*-commutativeN/A
distribute-lft-neg-inN/A
lift-*.f64N/A
*-commutativeN/A
lift-pow.f64N/A
unpow2N/A
associate-*l*N/A
associate-*r*N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-neg.f64N/A
lower-*.f6455.2
lift--.f64N/A
Applied rewrites58.0%
Applied rewrites67.2%
Taylor expanded in Om around inf
+-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6456.5
Applied rewrites56.5%
Final simplification58.1%
(FPCore (n U t l Om U*)
:precision binary64
(if (<= n -3.3e-22)
(sqrt (* (* (* 2.0 n) U) (- t (/ (* (* n (* l l)) (- U*)) (* Om Om)))))
(if (<= n 6.9e-298)
(sqrt (fma 2.0 (* U (* n t)) (/ (* (* U (* l (* n l))) -4.0) Om)))
(* (sqrt (* 2.0 n)) (sqrt (* U (fma -2.0 (/ (* l l) Om) t)))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (n <= -3.3e-22) {
tmp = sqrt((((2.0 * n) * U) * (t - (((n * (l * l)) * -U_42_) / (Om * Om)))));
} else if (n <= 6.9e-298) {
tmp = sqrt(fma(2.0, (U * (n * t)), (((U * (l * (n * l))) * -4.0) / Om)));
} else {
tmp = sqrt((2.0 * n)) * sqrt((U * fma(-2.0, ((l * l) / Om), t)));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (n <= -3.3e-22) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t - Float64(Float64(Float64(n * Float64(l * l)) * Float64(-U_42_)) / Float64(Om * Om))))); elseif (n <= 6.9e-298) tmp = sqrt(fma(2.0, Float64(U * Float64(n * t)), Float64(Float64(Float64(U * Float64(l * Float64(n * l))) * -4.0) / Om))); else tmp = Float64(sqrt(Float64(2.0 * n)) * sqrt(Float64(U * fma(-2.0, Float64(Float64(l * l) / Om), t)))); end return tmp end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[n, -3.3e-22], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t - N[(N[(N[(n * N[(l * l), $MachinePrecision]), $MachinePrecision] * (-U$42$)), $MachinePrecision] / N[(Om * Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[n, 6.9e-298], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(U * N[(l * N[(n * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * -4.0), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(2.0 * n), $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(U * N[(-2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;n \leq -3.3 \cdot 10^{-22}:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t - \frac{\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot \left(-U*\right)}{Om \cdot Om}\right)}\\
\mathbf{elif}\;n \leq 6.9 \cdot 10^{-298}:\\
\;\;\;\;\sqrt{\mathsf{fma}\left(2, U \cdot \left(n \cdot t\right), \frac{\left(U \cdot \left(\ell \cdot \left(n \cdot \ell\right)\right)\right) \cdot -4}{Om}\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot n} \cdot \sqrt{U \cdot \mathsf{fma}\left(-2, \frac{\ell \cdot \ell}{Om}, t\right)}\\
\end{array}
\end{array}
if n < -3.3000000000000001e-22Initial program 59.2%
Taylor expanded in t around 0
lower--.f64N/A
+-commutativeN/A
unpow2N/A
associate-/r*N/A
metadata-evalN/A
cancel-sign-sub-invN/A
associate-*r/N/A
div-subN/A
lower-/.f64N/A
Applied rewrites60.4%
Taylor expanded in U* around inf
Applied rewrites56.3%
if -3.3000000000000001e-22 < n < 6.90000000000000022e-298Initial program 38.8%
Taylor expanded in Om around inf
+-commutativeN/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f64N/A
associate-*r/N/A
lower-/.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f6449.3
Applied rewrites49.3%
Applied rewrites59.0%
if 6.90000000000000022e-298 < n Initial program 50.5%
lift--.f64N/A
sub-negN/A
+-commutativeN/A
lift-*.f64N/A
*-commutativeN/A
distribute-lft-neg-inN/A
lift-*.f64N/A
*-commutativeN/A
lift-pow.f64N/A
unpow2N/A
associate-*l*N/A
associate-*r*N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-neg.f64N/A
lower-*.f6455.2
lift--.f64N/A
Applied rewrites58.0%
Applied rewrites67.2%
Taylor expanded in Om around inf
+-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6456.5
Applied rewrites56.5%
Final simplification57.2%
(FPCore (n U t l Om U*)
:precision binary64
(if (<= n -7.5e-55)
(sqrt (* (* (* 2.0 n) U) (fma (* l l) (/ -2.0 Om) t)))
(if (<= n 6.9e-298)
(sqrt (fma 2.0 (* U (* n t)) (/ (* (* U (* l (* n l))) -4.0) Om)))
(* (sqrt (* 2.0 n)) (sqrt (* U (fma -2.0 (/ (* l l) Om) t)))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (n <= -7.5e-55) {
tmp = sqrt((((2.0 * n) * U) * fma((l * l), (-2.0 / Om), t)));
} else if (n <= 6.9e-298) {
tmp = sqrt(fma(2.0, (U * (n * t)), (((U * (l * (n * l))) * -4.0) / Om)));
} else {
tmp = sqrt((2.0 * n)) * sqrt((U * fma(-2.0, ((l * l) / Om), t)));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (n <= -7.5e-55) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * fma(Float64(l * l), Float64(-2.0 / Om), t))); elseif (n <= 6.9e-298) tmp = sqrt(fma(2.0, Float64(U * Float64(n * t)), Float64(Float64(Float64(U * Float64(l * Float64(n * l))) * -4.0) / Om))); else tmp = Float64(sqrt(Float64(2.0 * n)) * sqrt(Float64(U * fma(-2.0, Float64(Float64(l * l) / Om), t)))); end return tmp end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[n, -7.5e-55], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(l * l), $MachinePrecision] * N[(-2.0 / Om), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[n, 6.9e-298], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(U * N[(l * N[(n * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * -4.0), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(2.0 * n), $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(U * N[(-2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;n \leq -7.5 \cdot 10^{-55}:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \mathsf{fma}\left(\ell \cdot \ell, \frac{-2}{Om}, t\right)}\\
\mathbf{elif}\;n \leq 6.9 \cdot 10^{-298}:\\
\;\;\;\;\sqrt{\mathsf{fma}\left(2, U \cdot \left(n \cdot t\right), \frac{\left(U \cdot \left(\ell \cdot \left(n \cdot \ell\right)\right)\right) \cdot -4}{Om}\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot n} \cdot \sqrt{U \cdot \mathsf{fma}\left(-2, \frac{\ell \cdot \ell}{Om}, t\right)}\\
\end{array}
\end{array}
if n < -7.50000000000000023e-55Initial program 58.5%
Taylor expanded in Om around inf
+-commutativeN/A
associate-*r/N/A
*-commutativeN/A
associate-/l*N/A
lower-fma.f64N/A
unpow2N/A
lower-*.f64N/A
lower-/.f6448.7
Applied rewrites48.7%
if -7.50000000000000023e-55 < n < 6.90000000000000022e-298Initial program 37.7%
Taylor expanded in Om around inf
+-commutativeN/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f64N/A
associate-*r/N/A
lower-/.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f6449.1
Applied rewrites49.1%
Applied rewrites59.5%
if 6.90000000000000022e-298 < n Initial program 50.5%
lift--.f64N/A
sub-negN/A
+-commutativeN/A
lift-*.f64N/A
*-commutativeN/A
distribute-lft-neg-inN/A
lift-*.f64N/A
*-commutativeN/A
lift-pow.f64N/A
unpow2N/A
associate-*l*N/A
associate-*r*N/A
lower-fma.f64N/A
lower-*.f64N/A
lower-neg.f64N/A
lower-*.f6455.2
lift--.f64N/A
Applied rewrites58.0%
Applied rewrites67.2%
Taylor expanded in Om around inf
+-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6456.5
Applied rewrites56.5%
Final simplification55.7%
(FPCore (n U t l Om U*) :precision binary64 (if (<= l 7e+153) (sqrt (* (* n (fma -2.0 (/ (* l l) Om) t)) (* 2.0 U))) (sqrt (fma 2.0 (* U (* n t)) (/ (* (* U (* l (* n l))) -4.0) Om)))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 7e+153) {
tmp = sqrt(((n * fma(-2.0, ((l * l) / Om), t)) * (2.0 * U)));
} else {
tmp = sqrt(fma(2.0, (U * (n * t)), (((U * (l * (n * l))) * -4.0) / Om)));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 7e+153) tmp = sqrt(Float64(Float64(n * fma(-2.0, Float64(Float64(l * l) / Om), t)) * Float64(2.0 * U))); else tmp = sqrt(fma(2.0, Float64(U * Float64(n * t)), Float64(Float64(Float64(U * Float64(l * Float64(n * l))) * -4.0) / Om))); end return tmp end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 7e+153], N[Sqrt[N[(N[(n * N[(-2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision] * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(U * N[(l * N[(n * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * -4.0), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 7 \cdot 10^{+153}:\\
\;\;\;\;\sqrt{\left(n \cdot \mathsf{fma}\left(-2, \frac{\ell \cdot \ell}{Om}, t\right)\right) \cdot \left(2 \cdot U\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\mathsf{fma}\left(2, U \cdot \left(n \cdot t\right), \frac{\left(U \cdot \left(\ell \cdot \left(n \cdot \ell\right)\right)\right) \cdot -4}{Om}\right)}\\
\end{array}
\end{array}
if l < 6.9999999999999998e153Initial program 53.6%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6440.2
Applied rewrites40.2%
Taylor expanded in n around 0
associate-*r*N/A
cancel-sign-sub-invN/A
metadata-evalN/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
+-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6454.3
Applied rewrites54.3%
if 6.9999999999999998e153 < l Initial program 11.6%
Taylor expanded in Om around inf
+-commutativeN/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f64N/A
associate-*r/N/A
lower-/.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f6412.6
Applied rewrites12.6%
Applied rewrites31.4%
Final simplification51.5%
(FPCore (n U t l Om U*) :precision binary64 (if (<= t 2.4e+230) (sqrt (* (* n (fma -2.0 (/ (* l l) Om) t)) (* 2.0 U))) (* (sqrt (* 2.0 t)) (sqrt (* n U)))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 2.4e+230) {
tmp = sqrt(((n * fma(-2.0, ((l * l) / Om), t)) * (2.0 * U)));
} else {
tmp = sqrt((2.0 * t)) * sqrt((n * U));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= 2.4e+230) tmp = sqrt(Float64(Float64(n * fma(-2.0, Float64(Float64(l * l) / Om), t)) * Float64(2.0 * U))); else tmp = Float64(sqrt(Float64(2.0 * t)) * sqrt(Float64(n * U))); end return tmp end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, 2.4e+230], N[Sqrt[N[(N[(n * N[(-2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision] * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(2.0 * t), $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(n * U), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq 2.4 \cdot 10^{+230}:\\
\;\;\;\;\sqrt{\left(n \cdot \mathsf{fma}\left(-2, \frac{\ell \cdot \ell}{Om}, t\right)\right) \cdot \left(2 \cdot U\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot t} \cdot \sqrt{n \cdot U}\\
\end{array}
\end{array}
if t < 2.39999999999999998e230Initial program 48.1%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6436.4
Applied rewrites36.4%
Taylor expanded in n around 0
associate-*r*N/A
cancel-sign-sub-invN/A
metadata-evalN/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
+-commutativeN/A
lower-fma.f64N/A
lower-/.f64N/A
unpow2N/A
lower-*.f6449.7
Applied rewrites49.7%
if 2.39999999999999998e230 < t Initial program 55.5%
Taylor expanded in Om around 0
lower-/.f64N/A
associate-*r*N/A
*-commutativeN/A
distribute-rgt-out--N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
unpow2N/A
lower-*.f648.1
Applied rewrites8.1%
lift-sqrt.f64N/A
lift-*.f64N/A
*-commutativeN/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
*-commutativeN/A
lift-*.f64N/A
associate-*r*N/A
Applied rewrites8.2%
Taylor expanded in t around inf
lower-*.f6473.7
Applied rewrites73.7%
Final simplification51.1%
(FPCore (n U t l Om U*) :precision binary64 (if (<= l 3.6e+61) (sqrt (* (* 2.0 U) (* n t))) (sqrt (* (* U -2.0) (/ (* 2.0 (* n (* l l))) Om)))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 3.6e+61) {
tmp = sqrt(((2.0 * U) * (n * t)));
} else {
tmp = sqrt(((U * -2.0) * ((2.0 * (n * (l * l))) / Om)));
}
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 <= 3.6d+61) then
tmp = sqrt(((2.0d0 * u) * (n * t)))
else
tmp = sqrt(((u * (-2.0d0)) * ((2.0d0 * (n * (l * l))) / om)))
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 <= 3.6e+61) {
tmp = Math.sqrt(((2.0 * U) * (n * t)));
} else {
tmp = Math.sqrt(((U * -2.0) * ((2.0 * (n * (l * l))) / Om)));
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if l <= 3.6e+61: tmp = math.sqrt(((2.0 * U) * (n * t))) else: tmp = math.sqrt(((U * -2.0) * ((2.0 * (n * (l * l))) / Om))) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 3.6e+61) tmp = sqrt(Float64(Float64(2.0 * U) * Float64(n * t))); else tmp = sqrt(Float64(Float64(U * -2.0) * Float64(Float64(2.0 * Float64(n * Float64(l * l))) / Om))); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (l <= 3.6e+61) tmp = sqrt(((2.0 * U) * (n * t))); else tmp = sqrt(((U * -2.0) * ((2.0 * (n * (l * l))) / Om))); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 3.6e+61], N[Sqrt[N[(N[(2.0 * U), $MachinePrecision] * N[(n * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(U * -2.0), $MachinePrecision] * N[(N[(2.0 * N[(n * N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 3.6 \cdot 10^{+61}:\\
\;\;\;\;\sqrt{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(U \cdot -2\right) \cdot \frac{2 \cdot \left(n \cdot \left(\ell \cdot \ell\right)\right)}{Om}}\\
\end{array}
\end{array}
if l < 3.6000000000000001e61Initial program 54.4%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6440.8
Applied rewrites40.8%
if 3.6000000000000001e61 < l Initial program 18.5%
Taylor expanded in l around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
+-commutativeN/A
associate-/l*N/A
lower-fma.f64N/A
lower-/.f64N/A
lower--.f64N/A
unpow2N/A
lower-*.f64N/A
associate-*r/N/A
metadata-evalN/A
lower-/.f6427.0
Applied rewrites27.0%
Taylor expanded in n around 0
Applied rewrites21.5%
Final simplification37.6%
(FPCore (n U t l Om U*) :precision binary64 (if (<= l 3.6e+61) (sqrt (* (* 2.0 U) (* n t))) (sqrt (/ (* -4.0 (* U (* n (* l l)))) Om))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 3.6e+61) {
tmp = sqrt(((2.0 * U) * (n * t)));
} else {
tmp = sqrt(((-4.0 * (U * (n * (l * l)))) / Om));
}
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 <= 3.6d+61) then
tmp = sqrt(((2.0d0 * u) * (n * t)))
else
tmp = sqrt((((-4.0d0) * (u * (n * (l * l)))) / om))
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 <= 3.6e+61) {
tmp = Math.sqrt(((2.0 * U) * (n * t)));
} else {
tmp = Math.sqrt(((-4.0 * (U * (n * (l * l)))) / Om));
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if l <= 3.6e+61: tmp = math.sqrt(((2.0 * U) * (n * t))) else: tmp = math.sqrt(((-4.0 * (U * (n * (l * l)))) / Om)) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 3.6e+61) tmp = sqrt(Float64(Float64(2.0 * U) * Float64(n * t))); else tmp = sqrt(Float64(Float64(-4.0 * Float64(U * Float64(n * Float64(l * l)))) / Om)); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (l <= 3.6e+61) tmp = sqrt(((2.0 * U) * (n * t))); else tmp = sqrt(((-4.0 * (U * (n * (l * l)))) / Om)); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 3.6e+61], N[Sqrt[N[(N[(2.0 * U), $MachinePrecision] * N[(n * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(-4.0 * N[(U * N[(n * N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 3.6 \cdot 10^{+61}:\\
\;\;\;\;\sqrt{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\frac{-4 \cdot \left(U \cdot \left(n \cdot \left(\ell \cdot \ell\right)\right)\right)}{Om}}\\
\end{array}
\end{array}
if l < 3.6000000000000001e61Initial program 54.4%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6440.8
Applied rewrites40.8%
if 3.6000000000000001e61 < l Initial program 18.5%
Taylor expanded in Om around inf
+-commutativeN/A
lower-fma.f64N/A
lower-*.f64N/A
lower-*.f64N/A
associate-*r/N/A
lower-/.f64N/A
*-commutativeN/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f64N/A
unpow2N/A
lower-*.f6426.1
Applied rewrites26.1%
Taylor expanded in t around 0
Applied rewrites21.6%
Final simplification37.6%
(FPCore (n U t l Om U*) :precision binary64 (if (<= t 8e-309) (sqrt (* 2.0 (* U (* n t)))) (* (sqrt (* 2.0 t)) (sqrt (* n U)))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 8e-309) {
tmp = sqrt((2.0 * (U * (n * t))));
} else {
tmp = sqrt((2.0 * t)) * sqrt((n * U));
}
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 (t <= 8d-309) then
tmp = sqrt((2.0d0 * (u * (n * t))))
else
tmp = sqrt((2.0d0 * t)) * sqrt((n * u))
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 (t <= 8e-309) {
tmp = Math.sqrt((2.0 * (U * (n * t))));
} else {
tmp = Math.sqrt((2.0 * t)) * Math.sqrt((n * U));
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if t <= 8e-309: tmp = math.sqrt((2.0 * (U * (n * t)))) else: tmp = math.sqrt((2.0 * t)) * math.sqrt((n * U)) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= 8e-309) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t)))); else tmp = Float64(sqrt(Float64(2.0 * t)) * sqrt(Float64(n * U))); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (t <= 8e-309) tmp = sqrt((2.0 * (U * (n * t)))); else tmp = sqrt((2.0 * t)) * sqrt((n * U)); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, 8e-309], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(2.0 * t), $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(n * U), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq 8 \cdot 10^{-309}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot t} \cdot \sqrt{n \cdot U}\\
\end{array}
\end{array}
if t < 8.0000000000000003e-309Initial program 44.8%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6438.6
Applied rewrites38.6%
Applied rewrites38.6%
if 8.0000000000000003e-309 < t Initial program 52.9%
Taylor expanded in Om around 0
lower-/.f64N/A
associate-*r*N/A
*-commutativeN/A
distribute-rgt-out--N/A
lower-*.f64N/A
unpow2N/A
lower-*.f64N/A
lower--.f64N/A
lower-*.f64N/A
lower-*.f64N/A
lower--.f64N/A
unpow2N/A
lower-*.f6423.9
Applied rewrites23.9%
lift-sqrt.f64N/A
lift-*.f64N/A
*-commutativeN/A
lift-*.f64N/A
lift-*.f64N/A
associate-*r*N/A
*-commutativeN/A
lift-*.f64N/A
associate-*r*N/A
Applied rewrites11.9%
Taylor expanded in t around inf
lower-*.f6444.4
Applied rewrites44.4%
Final simplification41.3%
(FPCore (n U t l Om U*) :precision binary64 (if (<= t 8e-309) (sqrt (* 2.0 (* U (* n t)))) (* (sqrt t) (sqrt (* 2.0 (* n U))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 8e-309) {
tmp = sqrt((2.0 * (U * (n * t))));
} else {
tmp = sqrt(t) * sqrt((2.0 * (n * U)));
}
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 (t <= 8d-309) then
tmp = sqrt((2.0d0 * (u * (n * t))))
else
tmp = sqrt(t) * sqrt((2.0d0 * (n * u)))
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 (t <= 8e-309) {
tmp = Math.sqrt((2.0 * (U * (n * t))));
} else {
tmp = Math.sqrt(t) * Math.sqrt((2.0 * (n * U)));
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if t <= 8e-309: tmp = math.sqrt((2.0 * (U * (n * t)))) else: tmp = math.sqrt(t) * math.sqrt((2.0 * (n * U))) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= 8e-309) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t)))); else tmp = Float64(sqrt(t) * sqrt(Float64(2.0 * Float64(n * U)))); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (t <= 8e-309) tmp = sqrt((2.0 * (U * (n * t)))); else tmp = sqrt(t) * sqrt((2.0 * (n * U))); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, 8e-309], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[t], $MachinePrecision] * N[Sqrt[N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq 8 \cdot 10^{-309}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{t} \cdot \sqrt{2 \cdot \left(n \cdot U\right)}\\
\end{array}
\end{array}
if t < 8.0000000000000003e-309Initial program 44.8%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6438.6
Applied rewrites38.6%
Applied rewrites38.6%
if 8.0000000000000003e-309 < t Initial program 52.9%
lift-sqrt.f64N/A
pow1/2N/A
lift-*.f64N/A
*-commutativeN/A
unpow-prod-downN/A
lower-*.f64N/A
Applied rewrites46.8%
Taylor expanded in l around 0
lower-sqrt.f6444.3
Applied rewrites44.3%
Final simplification41.3%
(FPCore (n U t l Om U*) :precision binary64 (sqrt (* 2.0 (* U (* n t)))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
return sqrt((2.0 * (U * (n * t))));
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
code = sqrt((2.0d0 * (u * (n * t))))
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
return Math.sqrt((2.0 * (U * (n * t))));
}
def code(n, U, t, l, Om, U_42_): return math.sqrt((2.0 * (U * (n * t))))
function code(n, U, t, l, Om, U_42_) return sqrt(Float64(2.0 * Float64(U * Float64(n * t)))) end
function tmp = code(n, U, t, l, Om, U_42_) tmp = sqrt((2.0 * (U * (n * t)))); end
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
\\
\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}
\end{array}
Initial program 48.5%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6436.4
Applied rewrites36.4%
Applied rewrites36.4%
Final simplification36.4%
(FPCore (n U t l Om U*) :precision binary64 (sqrt (* (* 2.0 U) (* n t))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
return sqrt(((2.0 * U) * (n * t)));
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
code = sqrt(((2.0d0 * u) * (n * t)))
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
return Math.sqrt(((2.0 * U) * (n * t)));
}
def code(n, U, t, l, Om, U_42_): return math.sqrt(((2.0 * U) * (n * t)))
function code(n, U, t, l, Om, U_42_) return sqrt(Float64(Float64(2.0 * U) * Float64(n * t))) end
function tmp = code(n, U, t, l, Om, U_42_) tmp = sqrt(((2.0 * U) * (n * t))); end
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(N[(2.0 * U), $MachinePrecision] * N[(n * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
\\
\sqrt{\left(2 \cdot U\right) \cdot \left(n \cdot t\right)}
\end{array}
Initial program 48.5%
Taylor expanded in t around inf
associate-*r*N/A
lower-*.f64N/A
lower-*.f64N/A
lower-*.f6436.4
Applied rewrites36.4%
herbie shell --seed 2024223
(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*))))))