
(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 16 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}
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
:precision binary64
(let* ((t_1 (pow (/ l_m Om) 2.0))
(t_2
(*
(* (* 2.0 n) U)
(+ (- t (* 2.0 (/ (* l_m l_m) Om))) (* (* n t_1) (- U* U))))))
(if (<= t_2 4e-279)
(sqrt
(+
(/
(-
(* 2.0 (/ (* U (* (pow l_m 2.0) (* (pow n 2.0) (- U* U)))) Om))
(* 4.0 (* U (* n (pow l_m 2.0)))))
Om)
(* 2.0 (* U (* n t)))))
(if (<= t_2 INFINITY)
(sqrt
(*
(* 2.0 (* n U))
(+ t (+ (* n (* t_1 (- U* U))) (* 2.0 (* l_m (* l_m (/ -1.0 Om))))))))
(* l_m (* (sqrt (fabs (* U U*))) (/ (* n (sqrt 2.0)) Om)))))))l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = pow((l_m / Om), 2.0);
double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U)));
double tmp;
if (t_2 <= 4e-279) {
tmp = sqrt(((((2.0 * ((U * (pow(l_m, 2.0) * (pow(n, 2.0) * (U_42_ - U)))) / Om)) - (4.0 * (U * (n * pow(l_m, 2.0))))) / Om) + (2.0 * (U * (n * t)))));
} else if (t_2 <= ((double) INFINITY)) {
tmp = sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om))))))));
} else {
tmp = l_m * (sqrt(fabs((U * U_42_))) * ((n * sqrt(2.0)) / Om));
}
return tmp;
}
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = Math.pow((l_m / Om), 2.0);
double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U)));
double tmp;
if (t_2 <= 4e-279) {
tmp = Math.sqrt(((((2.0 * ((U * (Math.pow(l_m, 2.0) * (Math.pow(n, 2.0) * (U_42_ - U)))) / Om)) - (4.0 * (U * (n * Math.pow(l_m, 2.0))))) / Om) + (2.0 * (U * (n * t)))));
} else if (t_2 <= Double.POSITIVE_INFINITY) {
tmp = Math.sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om))))))));
} else {
tmp = l_m * (Math.sqrt(Math.abs((U * U_42_))) * ((n * Math.sqrt(2.0)) / Om));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): t_1 = math.pow((l_m / Om), 2.0) t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U))) tmp = 0 if t_2 <= 4e-279: tmp = math.sqrt(((((2.0 * ((U * (math.pow(l_m, 2.0) * (math.pow(n, 2.0) * (U_42_ - U)))) / Om)) - (4.0 * (U * (n * math.pow(l_m, 2.0))))) / Om) + (2.0 * (U * (n * t))))) elif t_2 <= math.inf: tmp = math.sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om)))))))) else: tmp = l_m * (math.sqrt(math.fabs((U * U_42_))) * ((n * math.sqrt(2.0)) / Om)) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) t_1 = Float64(l_m / Om) ^ 2.0 t_2 = Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l_m * l_m) / Om))) + Float64(Float64(n * t_1) * Float64(U_42_ - U)))) tmp = 0.0 if (t_2 <= 4e-279) tmp = sqrt(Float64(Float64(Float64(Float64(2.0 * Float64(Float64(U * Float64((l_m ^ 2.0) * Float64((n ^ 2.0) * Float64(U_42_ - U)))) / Om)) - Float64(4.0 * Float64(U * Float64(n * (l_m ^ 2.0))))) / Om) + Float64(2.0 * Float64(U * Float64(n * t))))); elseif (t_2 <= Inf) tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * Float64(t + Float64(Float64(n * Float64(t_1 * Float64(U_42_ - U))) + Float64(2.0 * Float64(l_m * Float64(l_m * Float64(-1.0 / Om)))))))); else tmp = Float64(l_m * Float64(sqrt(abs(Float64(U * U_42_))) * Float64(Float64(n * sqrt(2.0)) / Om))); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) t_1 = (l_m / Om) ^ 2.0; t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U))); tmp = 0.0; if (t_2 <= 4e-279) tmp = sqrt(((((2.0 * ((U * ((l_m ^ 2.0) * ((n ^ 2.0) * (U_42_ - U)))) / Om)) - (4.0 * (U * (n * (l_m ^ 2.0))))) / Om) + (2.0 * (U * (n * t))))); elseif (t_2 <= Inf) tmp = sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om)))))))); else tmp = l_m * (sqrt(abs((U * U_42_))) * ((n * sqrt(2.0)) / Om)); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := Block[{t$95$1 = N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l$95$m * l$95$m), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(n * t$95$1), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, 4e-279], N[Sqrt[N[(N[(N[(N[(2.0 * N[(N[(U * N[(N[Power[l$95$m, 2.0], $MachinePrecision] * N[(N[Power[n, 2.0], $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] - N[(4.0 * N[(U * N[(n * N[Power[l$95$m, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision] + N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$2, Infinity], N[Sqrt[N[(N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision] * N[(t + N[(N[(n * N[(t$95$1 * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(2.0 * N[(l$95$m * N[(l$95$m * N[(-1.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(l$95$m * N[(N[Sqrt[N[Abs[N[(U * U$42$), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * N[(N[(n * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
t_1 := {\left(\frac{l\_m}{Om}\right)}^{2}\\
t_2 := \left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{l\_m \cdot l\_m}{Om}\right) + \left(n \cdot t\_1\right) \cdot \left(U* - U\right)\right)\\
\mathbf{if}\;t\_2 \leq 4 \cdot 10^{-279}:\\
\;\;\;\;\sqrt{\frac{2 \cdot \frac{U \cdot \left({l\_m}^{2} \cdot \left({n}^{2} \cdot \left(U* - U\right)\right)\right)}{Om} - 4 \cdot \left(U \cdot \left(n \cdot {l\_m}^{2}\right)\right)}{Om} + 2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\
\mathbf{elif}\;t\_2 \leq \infty:\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(n \cdot \left(t\_1 \cdot \left(U* - U\right)\right) + 2 \cdot \left(l\_m \cdot \left(l\_m \cdot \frac{-1}{Om}\right)\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;l\_m \cdot \left(\sqrt{\left|U \cdot U*\right|} \cdot \frac{n \cdot \sqrt{2}}{Om}\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.00000000000000022e-279Initial program 18.7%
Simplified40.5%
Taylor expanded in Om around -inf 49.4%
if 4.00000000000000022e-279 < (*.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 63.1%
Simplified68.1%
sub-neg68.1%
distribute-lft-in57.3%
Applied egg-rr57.3%
distribute-lft-out68.1%
sub-neg68.1%
associate-*r*69.1%
*-commutative69.1%
Simplified69.1%
div-inv69.1%
Applied egg-rr69.1%
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%
Simplified0.3%
sub-neg0.3%
distribute-lft-in0.3%
Applied egg-rr0.3%
distribute-lft-out0.3%
sub-neg0.3%
associate-*r*3.0%
*-commutative3.0%
Simplified3.0%
div-inv3.0%
Applied egg-rr3.0%
Taylor expanded in U* around inf 30.7%
associate-/l*33.3%
associate-*r/33.3%
associate-*r*33.3%
*-commutative33.3%
associate-*r/33.3%
Simplified33.3%
add-sqr-sqrt33.3%
pow1/233.3%
pow1/233.3%
pow-prod-down28.4%
pow228.4%
Applied egg-rr28.4%
unpow1/228.4%
unpow228.4%
rem-sqrt-square33.7%
Simplified33.7%
Final simplification60.6%
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
:precision binary64
(let* ((t_1 (pow (/ l_m Om) 2.0))
(t_2
(*
(* (* 2.0 n) U)
(+ (- t (* 2.0 (/ (* l_m l_m) Om))) (* (* n t_1) (- U* U))))))
(if (<= t_2 4e-279)
(sqrt
(*
(* 2.0 n)
(+
(/
(-
(/ (* U (* (pow l_m 2.0) (* n (- U* U)))) Om)
(* 2.0 (* U (pow l_m 2.0))))
Om)
(* U t))))
(if (<= t_2 INFINITY)
(sqrt
(*
(* 2.0 (* n U))
(+ t (+ (* n (* t_1 (- U* U))) (* 2.0 (* l_m (* l_m (/ -1.0 Om))))))))
(* l_m (* (sqrt (fabs (* U U*))) (/ (* n (sqrt 2.0)) Om)))))))l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = pow((l_m / Om), 2.0);
double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U)));
double tmp;
if (t_2 <= 4e-279) {
tmp = sqrt(((2.0 * n) * (((((U * (pow(l_m, 2.0) * (n * (U_42_ - U)))) / Om) - (2.0 * (U * pow(l_m, 2.0)))) / Om) + (U * t))));
} else if (t_2 <= ((double) INFINITY)) {
tmp = sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om))))))));
} else {
tmp = l_m * (sqrt(fabs((U * U_42_))) * ((n * sqrt(2.0)) / Om));
}
return tmp;
}
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = Math.pow((l_m / Om), 2.0);
double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U)));
double tmp;
if (t_2 <= 4e-279) {
tmp = Math.sqrt(((2.0 * n) * (((((U * (Math.pow(l_m, 2.0) * (n * (U_42_ - U)))) / Om) - (2.0 * (U * Math.pow(l_m, 2.0)))) / Om) + (U * t))));
} else if (t_2 <= Double.POSITIVE_INFINITY) {
tmp = Math.sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om))))))));
} else {
tmp = l_m * (Math.sqrt(Math.abs((U * U_42_))) * ((n * Math.sqrt(2.0)) / Om));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): t_1 = math.pow((l_m / Om), 2.0) t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U))) tmp = 0 if t_2 <= 4e-279: tmp = math.sqrt(((2.0 * n) * (((((U * (math.pow(l_m, 2.0) * (n * (U_42_ - U)))) / Om) - (2.0 * (U * math.pow(l_m, 2.0)))) / Om) + (U * t)))) elif t_2 <= math.inf: tmp = math.sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om)))))))) else: tmp = l_m * (math.sqrt(math.fabs((U * U_42_))) * ((n * math.sqrt(2.0)) / Om)) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) t_1 = Float64(l_m / Om) ^ 2.0 t_2 = Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l_m * l_m) / Om))) + Float64(Float64(n * t_1) * Float64(U_42_ - U)))) tmp = 0.0 if (t_2 <= 4e-279) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(Float64(Float64(Float64(Float64(U * Float64((l_m ^ 2.0) * Float64(n * Float64(U_42_ - U)))) / Om) - Float64(2.0 * Float64(U * (l_m ^ 2.0)))) / Om) + Float64(U * t)))); elseif (t_2 <= Inf) tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * Float64(t + Float64(Float64(n * Float64(t_1 * Float64(U_42_ - U))) + Float64(2.0 * Float64(l_m * Float64(l_m * Float64(-1.0 / Om)))))))); else tmp = Float64(l_m * Float64(sqrt(abs(Float64(U * U_42_))) * Float64(Float64(n * sqrt(2.0)) / Om))); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) t_1 = (l_m / Om) ^ 2.0; t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U))); tmp = 0.0; if (t_2 <= 4e-279) tmp = sqrt(((2.0 * n) * (((((U * ((l_m ^ 2.0) * (n * (U_42_ - U)))) / Om) - (2.0 * (U * (l_m ^ 2.0)))) / Om) + (U * t)))); elseif (t_2 <= Inf) tmp = sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om)))))))); else tmp = l_m * (sqrt(abs((U * U_42_))) * ((n * sqrt(2.0)) / Om)); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := Block[{t$95$1 = N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l$95$m * l$95$m), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(n * t$95$1), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, 4e-279], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(N[(N[(N[(N[(U * N[(N[Power[l$95$m, 2.0], $MachinePrecision] * N[(n * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision] - N[(2.0 * N[(U * N[Power[l$95$m, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision] + N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$2, Infinity], N[Sqrt[N[(N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision] * N[(t + N[(N[(n * N[(t$95$1 * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(2.0 * N[(l$95$m * N[(l$95$m * N[(-1.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(l$95$m * N[(N[Sqrt[N[Abs[N[(U * U$42$), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * N[(N[(n * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
t_1 := {\left(\frac{l\_m}{Om}\right)}^{2}\\
t_2 := \left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{l\_m \cdot l\_m}{Om}\right) + \left(n \cdot t\_1\right) \cdot \left(U* - U\right)\right)\\
\mathbf{if}\;t\_2 \leq 4 \cdot 10^{-279}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(\frac{\frac{U \cdot \left({l\_m}^{2} \cdot \left(n \cdot \left(U* - U\right)\right)\right)}{Om} - 2 \cdot \left(U \cdot {l\_m}^{2}\right)}{Om} + U \cdot t\right)}\\
\mathbf{elif}\;t\_2 \leq \infty:\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(n \cdot \left(t\_1 \cdot \left(U* - U\right)\right) + 2 \cdot \left(l\_m \cdot \left(l\_m \cdot \frac{-1}{Om}\right)\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;l\_m \cdot \left(\sqrt{\left|U \cdot U*\right|} \cdot \frac{n \cdot \sqrt{2}}{Om}\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.00000000000000022e-279Initial program 18.7%
Simplified40.5%
Taylor expanded in Om around -inf 47.2%
if 4.00000000000000022e-279 < (*.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 63.1%
Simplified68.1%
sub-neg68.1%
distribute-lft-in57.3%
Applied egg-rr57.3%
distribute-lft-out68.1%
sub-neg68.1%
associate-*r*69.1%
*-commutative69.1%
Simplified69.1%
div-inv69.1%
Applied egg-rr69.1%
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%
Simplified0.3%
sub-neg0.3%
distribute-lft-in0.3%
Applied egg-rr0.3%
distribute-lft-out0.3%
sub-neg0.3%
associate-*r*3.0%
*-commutative3.0%
Simplified3.0%
div-inv3.0%
Applied egg-rr3.0%
Taylor expanded in U* around inf 30.7%
associate-/l*33.3%
associate-*r/33.3%
associate-*r*33.3%
*-commutative33.3%
associate-*r/33.3%
Simplified33.3%
add-sqr-sqrt33.3%
pow1/233.3%
pow1/233.3%
pow-prod-down28.4%
pow228.4%
Applied egg-rr28.4%
unpow1/228.4%
unpow228.4%
rem-sqrt-square33.7%
Simplified33.7%
Final simplification60.2%
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
:precision binary64
(let* ((t_1 (pow (/ l_m Om) 2.0))
(t_2
(*
(* (* 2.0 n) U)
(+ (- t (* 2.0 (/ (* l_m l_m) Om))) (* (* n t_1) (- U* U))))))
(if (<= t_2 4e-279)
(sqrt (* (* 2.0 U) (* n (+ t (* (/ (pow l_m 2.0) Om) -2.0)))))
(if (<= t_2 INFINITY)
(sqrt
(*
(* 2.0 (* n U))
(+ t (+ (* n (* t_1 (- U* U))) (* 2.0 (* l_m (* l_m (/ -1.0 Om))))))))
(* l_m (* (sqrt (fabs (* U U*))) (/ (* n (sqrt 2.0)) Om)))))))l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = pow((l_m / Om), 2.0);
double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U)));
double tmp;
if (t_2 <= 4e-279) {
tmp = sqrt(((2.0 * U) * (n * (t + ((pow(l_m, 2.0) / Om) * -2.0)))));
} else if (t_2 <= ((double) INFINITY)) {
tmp = sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om))))))));
} else {
tmp = l_m * (sqrt(fabs((U * U_42_))) * ((n * sqrt(2.0)) / Om));
}
return tmp;
}
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = Math.pow((l_m / Om), 2.0);
double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U)));
double tmp;
if (t_2 <= 4e-279) {
tmp = Math.sqrt(((2.0 * U) * (n * (t + ((Math.pow(l_m, 2.0) / Om) * -2.0)))));
} else if (t_2 <= Double.POSITIVE_INFINITY) {
tmp = Math.sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om))))))));
} else {
tmp = l_m * (Math.sqrt(Math.abs((U * U_42_))) * ((n * Math.sqrt(2.0)) / Om));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): t_1 = math.pow((l_m / Om), 2.0) t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U))) tmp = 0 if t_2 <= 4e-279: tmp = math.sqrt(((2.0 * U) * (n * (t + ((math.pow(l_m, 2.0) / Om) * -2.0))))) elif t_2 <= math.inf: tmp = math.sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om)))))))) else: tmp = l_m * (math.sqrt(math.fabs((U * U_42_))) * ((n * math.sqrt(2.0)) / Om)) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) t_1 = Float64(l_m / Om) ^ 2.0 t_2 = Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l_m * l_m) / Om))) + Float64(Float64(n * t_1) * Float64(U_42_ - U)))) tmp = 0.0 if (t_2 <= 4e-279) tmp = sqrt(Float64(Float64(2.0 * U) * Float64(n * Float64(t + Float64(Float64((l_m ^ 2.0) / Om) * -2.0))))); elseif (t_2 <= Inf) tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * Float64(t + Float64(Float64(n * Float64(t_1 * Float64(U_42_ - U))) + Float64(2.0 * Float64(l_m * Float64(l_m * Float64(-1.0 / Om)))))))); else tmp = Float64(l_m * Float64(sqrt(abs(Float64(U * U_42_))) * Float64(Float64(n * sqrt(2.0)) / Om))); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) t_1 = (l_m / Om) ^ 2.0; t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U))); tmp = 0.0; if (t_2 <= 4e-279) tmp = sqrt(((2.0 * U) * (n * (t + (((l_m ^ 2.0) / Om) * -2.0))))); elseif (t_2 <= Inf) tmp = sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om)))))))); else tmp = l_m * (sqrt(abs((U * U_42_))) * ((n * sqrt(2.0)) / Om)); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := Block[{t$95$1 = N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l$95$m * l$95$m), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(n * t$95$1), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, 4e-279], N[Sqrt[N[(N[(2.0 * U), $MachinePrecision] * N[(n * N[(t + N[(N[(N[Power[l$95$m, 2.0], $MachinePrecision] / Om), $MachinePrecision] * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$2, Infinity], N[Sqrt[N[(N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision] * N[(t + N[(N[(n * N[(t$95$1 * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(2.0 * N[(l$95$m * N[(l$95$m * N[(-1.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(l$95$m * N[(N[Sqrt[N[Abs[N[(U * U$42$), $MachinePrecision]], $MachinePrecision]], $MachinePrecision] * N[(N[(n * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
t_1 := {\left(\frac{l\_m}{Om}\right)}^{2}\\
t_2 := \left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{l\_m \cdot l\_m}{Om}\right) + \left(n \cdot t\_1\right) \cdot \left(U* - U\right)\right)\\
\mathbf{if}\;t\_2 \leq 4 \cdot 10^{-279}:\\
\;\;\;\;\sqrt{\left(2 \cdot U\right) \cdot \left(n \cdot \left(t + \frac{{l\_m}^{2}}{Om} \cdot -2\right)\right)}\\
\mathbf{elif}\;t\_2 \leq \infty:\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(n \cdot \left(t\_1 \cdot \left(U* - U\right)\right) + 2 \cdot \left(l\_m \cdot \left(l\_m \cdot \frac{-1}{Om}\right)\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;l\_m \cdot \left(\sqrt{\left|U \cdot U*\right|} \cdot \frac{n \cdot \sqrt{2}}{Om}\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.00000000000000022e-279Initial program 18.7%
Simplified40.5%
Taylor expanded in U around 0 35.4%
associate-/l*33.2%
unpow233.2%
unpow233.2%
times-frac40.5%
unpow240.5%
neg-mul-140.5%
distribute-lft-neg-out40.5%
*-commutative40.5%
Simplified40.5%
Taylor expanded in n around 0 47.2%
associate-*r*47.2%
cancel-sign-sub-inv47.2%
metadata-eval47.2%
*-commutative47.2%
Simplified47.2%
if 4.00000000000000022e-279 < (*.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 63.1%
Simplified68.1%
sub-neg68.1%
distribute-lft-in57.3%
Applied egg-rr57.3%
distribute-lft-out68.1%
sub-neg68.1%
associate-*r*69.1%
*-commutative69.1%
Simplified69.1%
div-inv69.1%
Applied egg-rr69.1%
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%
Simplified0.3%
sub-neg0.3%
distribute-lft-in0.3%
Applied egg-rr0.3%
distribute-lft-out0.3%
sub-neg0.3%
associate-*r*3.0%
*-commutative3.0%
Simplified3.0%
div-inv3.0%
Applied egg-rr3.0%
Taylor expanded in U* around inf 30.7%
associate-/l*33.3%
associate-*r/33.3%
associate-*r*33.3%
*-commutative33.3%
associate-*r/33.3%
Simplified33.3%
add-sqr-sqrt33.3%
pow1/233.3%
pow1/233.3%
pow-prod-down28.4%
pow228.4%
Applied egg-rr28.4%
unpow1/228.4%
unpow228.4%
rem-sqrt-square33.7%
Simplified33.7%
Final simplification60.2%
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
:precision binary64
(let* ((t_1 (pow (/ l_m Om) 2.0))
(t_2
(*
(* (* 2.0 n) U)
(+ (- t (* 2.0 (/ (* l_m l_m) Om))) (* (* n t_1) (- U* U))))))
(if (<= t_2 4e-279)
(sqrt (* (* 2.0 U) (* n (+ t (* (/ (pow l_m 2.0) Om) -2.0)))))
(if (<= t_2 INFINITY)
(sqrt
(*
(* 2.0 (* n U))
(+ t (+ (* n (* t_1 (- U* U))) (* 2.0 (* l_m (* l_m (/ -1.0 Om))))))))
(* l_m (* (sqrt (* U U*)) (* n (/ (sqrt 2.0) Om))))))))l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = pow((l_m / Om), 2.0);
double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U)));
double tmp;
if (t_2 <= 4e-279) {
tmp = sqrt(((2.0 * U) * (n * (t + ((pow(l_m, 2.0) / Om) * -2.0)))));
} else if (t_2 <= ((double) INFINITY)) {
tmp = sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om))))))));
} else {
tmp = l_m * (sqrt((U * U_42_)) * (n * (sqrt(2.0) / Om)));
}
return tmp;
}
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = Math.pow((l_m / Om), 2.0);
double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U)));
double tmp;
if (t_2 <= 4e-279) {
tmp = Math.sqrt(((2.0 * U) * (n * (t + ((Math.pow(l_m, 2.0) / Om) * -2.0)))));
} else if (t_2 <= Double.POSITIVE_INFINITY) {
tmp = Math.sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om))))))));
} else {
tmp = l_m * (Math.sqrt((U * U_42_)) * (n * (Math.sqrt(2.0) / Om)));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): t_1 = math.pow((l_m / Om), 2.0) t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U))) tmp = 0 if t_2 <= 4e-279: tmp = math.sqrt(((2.0 * U) * (n * (t + ((math.pow(l_m, 2.0) / Om) * -2.0))))) elif t_2 <= math.inf: tmp = math.sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om)))))))) else: tmp = l_m * (math.sqrt((U * U_42_)) * (n * (math.sqrt(2.0) / Om))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) t_1 = Float64(l_m / Om) ^ 2.0 t_2 = Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l_m * l_m) / Om))) + Float64(Float64(n * t_1) * Float64(U_42_ - U)))) tmp = 0.0 if (t_2 <= 4e-279) tmp = sqrt(Float64(Float64(2.0 * U) * Float64(n * Float64(t + Float64(Float64((l_m ^ 2.0) / Om) * -2.0))))); elseif (t_2 <= Inf) tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * Float64(t + Float64(Float64(n * Float64(t_1 * Float64(U_42_ - U))) + Float64(2.0 * Float64(l_m * Float64(l_m * Float64(-1.0 / Om)))))))); else tmp = Float64(l_m * Float64(sqrt(Float64(U * U_42_)) * Float64(n * Float64(sqrt(2.0) / Om)))); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) t_1 = (l_m / Om) ^ 2.0; t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U))); tmp = 0.0; if (t_2 <= 4e-279) tmp = sqrt(((2.0 * U) * (n * (t + (((l_m ^ 2.0) / Om) * -2.0))))); elseif (t_2 <= Inf) tmp = sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) + (2.0 * (l_m * (l_m * (-1.0 / Om)))))))); else tmp = l_m * (sqrt((U * U_42_)) * (n * (sqrt(2.0) / Om))); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := Block[{t$95$1 = N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l$95$m * l$95$m), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(n * t$95$1), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, 4e-279], N[Sqrt[N[(N[(2.0 * U), $MachinePrecision] * N[(n * N[(t + N[(N[(N[Power[l$95$m, 2.0], $MachinePrecision] / Om), $MachinePrecision] * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$2, Infinity], N[Sqrt[N[(N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision] * N[(t + N[(N[(n * N[(t$95$1 * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(2.0 * N[(l$95$m * N[(l$95$m * N[(-1.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(l$95$m * N[(N[Sqrt[N[(U * U$42$), $MachinePrecision]], $MachinePrecision] * N[(n * N[(N[Sqrt[2.0], $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
t_1 := {\left(\frac{l\_m}{Om}\right)}^{2}\\
t_2 := \left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{l\_m \cdot l\_m}{Om}\right) + \left(n \cdot t\_1\right) \cdot \left(U* - U\right)\right)\\
\mathbf{if}\;t\_2 \leq 4 \cdot 10^{-279}:\\
\;\;\;\;\sqrt{\left(2 \cdot U\right) \cdot \left(n \cdot \left(t + \frac{{l\_m}^{2}}{Om} \cdot -2\right)\right)}\\
\mathbf{elif}\;t\_2 \leq \infty:\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(n \cdot \left(t\_1 \cdot \left(U* - U\right)\right) + 2 \cdot \left(l\_m \cdot \left(l\_m \cdot \frac{-1}{Om}\right)\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;l\_m \cdot \left(\sqrt{U \cdot U*} \cdot \left(n \cdot \frac{\sqrt{2}}{Om}\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.00000000000000022e-279Initial program 18.7%
Simplified40.5%
Taylor expanded in U around 0 35.4%
associate-/l*33.2%
unpow233.2%
unpow233.2%
times-frac40.5%
unpow240.5%
neg-mul-140.5%
distribute-lft-neg-out40.5%
*-commutative40.5%
Simplified40.5%
Taylor expanded in n around 0 47.2%
associate-*r*47.2%
cancel-sign-sub-inv47.2%
metadata-eval47.2%
*-commutative47.2%
Simplified47.2%
if 4.00000000000000022e-279 < (*.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 63.1%
Simplified68.1%
sub-neg68.1%
distribute-lft-in57.3%
Applied egg-rr57.3%
distribute-lft-out68.1%
sub-neg68.1%
associate-*r*69.1%
*-commutative69.1%
Simplified69.1%
div-inv69.1%
Applied egg-rr69.1%
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%
Simplified0.3%
sub-neg0.3%
distribute-lft-in0.3%
Applied egg-rr0.3%
distribute-lft-out0.3%
sub-neg0.3%
associate-*r*3.0%
*-commutative3.0%
Simplified3.0%
div-inv3.0%
Applied egg-rr3.0%
Taylor expanded in U* around inf 30.7%
associate-/l*33.3%
associate-*r/33.3%
associate-*r*33.3%
*-commutative33.3%
associate-*r/33.3%
Simplified33.3%
Taylor expanded in U around 0 33.3%
associate-*r/33.3%
*-commutative33.3%
Simplified33.3%
Final simplification60.1%
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
:precision binary64
(let* ((t_1 (pow (/ l_m Om) 2.0))
(t_2
(*
(* (* 2.0 n) U)
(+ (- t (* 2.0 (/ (* l_m l_m) Om))) (* (* n t_1) (- U* U))))))
(if (<= t_2 4e-279)
(sqrt (* (* 2.0 U) (* n (+ t (* (/ (pow l_m 2.0) Om) -2.0)))))
(if (<= t_2 INFINITY)
(sqrt
(*
(* 2.0 (* n U))
(+ t (- (* n (* t_1 (- U* U))) (* 2.0 (* l_m (/ l_m Om)))))))
(* l_m (* (sqrt (* U U*)) (* n (/ (sqrt 2.0) Om))))))))l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = pow((l_m / Om), 2.0);
double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U)));
double tmp;
if (t_2 <= 4e-279) {
tmp = sqrt(((2.0 * U) * (n * (t + ((pow(l_m, 2.0) / Om) * -2.0)))));
} else if (t_2 <= ((double) INFINITY)) {
tmp = sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) - (2.0 * (l_m * (l_m / Om)))))));
} else {
tmp = l_m * (sqrt((U * U_42_)) * (n * (sqrt(2.0) / Om)));
}
return tmp;
}
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = Math.pow((l_m / Om), 2.0);
double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U)));
double tmp;
if (t_2 <= 4e-279) {
tmp = Math.sqrt(((2.0 * U) * (n * (t + ((Math.pow(l_m, 2.0) / Om) * -2.0)))));
} else if (t_2 <= Double.POSITIVE_INFINITY) {
tmp = Math.sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) - (2.0 * (l_m * (l_m / Om)))))));
} else {
tmp = l_m * (Math.sqrt((U * U_42_)) * (n * (Math.sqrt(2.0) / Om)));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): t_1 = math.pow((l_m / Om), 2.0) t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U))) tmp = 0 if t_2 <= 4e-279: tmp = math.sqrt(((2.0 * U) * (n * (t + ((math.pow(l_m, 2.0) / Om) * -2.0))))) elif t_2 <= math.inf: tmp = math.sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) - (2.0 * (l_m * (l_m / Om))))))) else: tmp = l_m * (math.sqrt((U * U_42_)) * (n * (math.sqrt(2.0) / Om))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) t_1 = Float64(l_m / Om) ^ 2.0 t_2 = Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l_m * l_m) / Om))) + Float64(Float64(n * t_1) * Float64(U_42_ - U)))) tmp = 0.0 if (t_2 <= 4e-279) tmp = sqrt(Float64(Float64(2.0 * U) * Float64(n * Float64(t + Float64(Float64((l_m ^ 2.0) / Om) * -2.0))))); elseif (t_2 <= Inf) tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * Float64(t + Float64(Float64(n * Float64(t_1 * Float64(U_42_ - U))) - Float64(2.0 * Float64(l_m * Float64(l_m / Om))))))); else tmp = Float64(l_m * Float64(sqrt(Float64(U * U_42_)) * Float64(n * Float64(sqrt(2.0) / Om)))); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) t_1 = (l_m / Om) ^ 2.0; t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + ((n * t_1) * (U_42_ - U))); tmp = 0.0; if (t_2 <= 4e-279) tmp = sqrt(((2.0 * U) * (n * (t + (((l_m ^ 2.0) / Om) * -2.0))))); elseif (t_2 <= Inf) tmp = sqrt(((2.0 * (n * U)) * (t + ((n * (t_1 * (U_42_ - U))) - (2.0 * (l_m * (l_m / Om))))))); else tmp = l_m * (sqrt((U * U_42_)) * (n * (sqrt(2.0) / Om))); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := Block[{t$95$1 = N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision]}, Block[{t$95$2 = N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l$95$m * l$95$m), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(n * t$95$1), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, 4e-279], N[Sqrt[N[(N[(2.0 * U), $MachinePrecision] * N[(n * N[(t + N[(N[(N[Power[l$95$m, 2.0], $MachinePrecision] / Om), $MachinePrecision] * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$2, Infinity], N[Sqrt[N[(N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision] * N[(t + N[(N[(n * N[(t$95$1 * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(2.0 * N[(l$95$m * N[(l$95$m / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(l$95$m * N[(N[Sqrt[N[(U * U$42$), $MachinePrecision]], $MachinePrecision] * N[(n * N[(N[Sqrt[2.0], $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
t_1 := {\left(\frac{l\_m}{Om}\right)}^{2}\\
t_2 := \left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{l\_m \cdot l\_m}{Om}\right) + \left(n \cdot t\_1\right) \cdot \left(U* - U\right)\right)\\
\mathbf{if}\;t\_2 \leq 4 \cdot 10^{-279}:\\
\;\;\;\;\sqrt{\left(2 \cdot U\right) \cdot \left(n \cdot \left(t + \frac{{l\_m}^{2}}{Om} \cdot -2\right)\right)}\\
\mathbf{elif}\;t\_2 \leq \infty:\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(n \cdot \left(t\_1 \cdot \left(U* - U\right)\right) - 2 \cdot \left(l\_m \cdot \frac{l\_m}{Om}\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;l\_m \cdot \left(\sqrt{U \cdot U*} \cdot \left(n \cdot \frac{\sqrt{2}}{Om}\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.00000000000000022e-279Initial program 18.7%
Simplified40.5%
Taylor expanded in U around 0 35.4%
associate-/l*33.2%
unpow233.2%
unpow233.2%
times-frac40.5%
unpow240.5%
neg-mul-140.5%
distribute-lft-neg-out40.5%
*-commutative40.5%
Simplified40.5%
Taylor expanded in n around 0 47.2%
associate-*r*47.2%
cancel-sign-sub-inv47.2%
metadata-eval47.2%
*-commutative47.2%
Simplified47.2%
if 4.00000000000000022e-279 < (*.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 63.1%
Simplified68.1%
sub-neg68.1%
distribute-lft-in57.3%
Applied egg-rr57.3%
distribute-lft-out68.1%
sub-neg68.1%
associate-*r*69.1%
*-commutative69.1%
Simplified69.1%
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%
Simplified0.3%
sub-neg0.3%
distribute-lft-in0.3%
Applied egg-rr0.3%
distribute-lft-out0.3%
sub-neg0.3%
associate-*r*3.0%
*-commutative3.0%
Simplified3.0%
div-inv3.0%
Applied egg-rr3.0%
Taylor expanded in U* around inf 30.7%
associate-/l*33.3%
associate-*r/33.3%
associate-*r*33.3%
*-commutative33.3%
associate-*r/33.3%
Simplified33.3%
Taylor expanded in U around 0 33.3%
associate-*r/33.3%
*-commutative33.3%
Simplified33.3%
Final simplification60.1%
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
:precision binary64
(let* ((t_1 (* 2.0 (* n U))))
(if (<= t 1.25e+233)
(sqrt
(*
t_1
(+ t (- (* n (* (pow (/ l_m Om) 2.0) U*)) (* 2.0 (* l_m (/ l_m Om)))))))
(* (sqrt t_1) (sqrt t)))))l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = 2.0 * (n * U);
double tmp;
if (t <= 1.25e+233) {
tmp = sqrt((t_1 * (t + ((n * (pow((l_m / Om), 2.0) * U_42_)) - (2.0 * (l_m * (l_m / Om)))))));
} else {
tmp = sqrt(t_1) * sqrt(t);
}
return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l_m
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: t_1
real(8) :: tmp
t_1 = 2.0d0 * (n * u)
if (t <= 1.25d+233) then
tmp = sqrt((t_1 * (t + ((n * (((l_m / om) ** 2.0d0) * u_42)) - (2.0d0 * (l_m * (l_m / om)))))))
else
tmp = sqrt(t_1) * sqrt(t)
end if
code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = 2.0 * (n * U);
double tmp;
if (t <= 1.25e+233) {
tmp = Math.sqrt((t_1 * (t + ((n * (Math.pow((l_m / Om), 2.0) * U_42_)) - (2.0 * (l_m * (l_m / Om)))))));
} else {
tmp = Math.sqrt(t_1) * Math.sqrt(t);
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): t_1 = 2.0 * (n * U) tmp = 0 if t <= 1.25e+233: tmp = math.sqrt((t_1 * (t + ((n * (math.pow((l_m / Om), 2.0) * U_42_)) - (2.0 * (l_m * (l_m / Om))))))) else: tmp = math.sqrt(t_1) * math.sqrt(t) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) t_1 = Float64(2.0 * Float64(n * U)) tmp = 0.0 if (t <= 1.25e+233) tmp = sqrt(Float64(t_1 * Float64(t + Float64(Float64(n * Float64((Float64(l_m / Om) ^ 2.0) * U_42_)) - Float64(2.0 * Float64(l_m * Float64(l_m / Om))))))); else tmp = Float64(sqrt(t_1) * sqrt(t)); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) t_1 = 2.0 * (n * U); tmp = 0.0; if (t <= 1.25e+233) tmp = sqrt((t_1 * (t + ((n * (((l_m / Om) ^ 2.0) * U_42_)) - (2.0 * (l_m * (l_m / Om))))))); else tmp = sqrt(t_1) * sqrt(t); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision]
code[n_, U_, t_, l$95$m_, Om_, U$42$_] := Block[{t$95$1 = N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, 1.25e+233], N[Sqrt[N[(t$95$1 * N[(t + N[(N[(n * N[(N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision] * U$42$), $MachinePrecision]), $MachinePrecision] - N[(2.0 * N[(l$95$m * N[(l$95$m / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[t$95$1], $MachinePrecision] * N[Sqrt[t], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
t_1 := 2 \cdot \left(n \cdot U\right)\\
\mathbf{if}\;t \leq 1.25 \cdot 10^{+233}:\\
\;\;\;\;\sqrt{t\_1 \cdot \left(t + \left(n \cdot \left({\left(\frac{l\_m}{Om}\right)}^{2} \cdot U*\right) - 2 \cdot \left(l\_m \cdot \frac{l\_m}{Om}\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{t\_1} \cdot \sqrt{t}\\
\end{array}
\end{array}
if t < 1.25000000000000002e233Initial program 49.0%
Simplified52.6%
sub-neg52.6%
distribute-lft-in44.8%
Applied egg-rr44.8%
distribute-lft-out52.6%
sub-neg52.6%
associate-*r*53.3%
*-commutative53.3%
Simplified53.3%
Taylor expanded in U around 0 53.3%
neg-mul-153.3%
Simplified53.3%
if 1.25000000000000002e233 < t Initial program 9.8%
Simplified21.3%
Taylor expanded in t around inf 21.6%
pow1/222.0%
associate-*r*21.8%
associate-*r*21.8%
unpow-prod-down65.2%
pow1/265.2%
pow1/265.2%
Applied egg-rr65.2%
Final simplification54.1%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (or (<= n -2.6e-131) (not (<= n 2.6e-42))) (sqrt (* (* (* 2.0 n) U) (- t (* (* n (pow (/ l_m Om) 2.0)) (- U U*))))) (sqrt (+ (* 2.0 (* U (* n t))) (* -4.0 (/ (* U (* n (pow l_m 2.0))) Om))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if ((n <= -2.6e-131) || !(n <= 2.6e-42)) {
tmp = sqrt((((2.0 * n) * U) * (t - ((n * pow((l_m / Om), 2.0)) * (U - U_42_)))));
} else {
tmp = sqrt(((2.0 * (U * (n * t))) + (-4.0 * ((U * (n * pow(l_m, 2.0))) / Om))));
}
return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l_m
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if ((n <= (-2.6d-131)) .or. (.not. (n <= 2.6d-42))) then
tmp = sqrt((((2.0d0 * n) * u) * (t - ((n * ((l_m / om) ** 2.0d0)) * (u - u_42)))))
else
tmp = sqrt(((2.0d0 * (u * (n * t))) + ((-4.0d0) * ((u * (n * (l_m ** 2.0d0))) / om))))
end if
code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if ((n <= -2.6e-131) || !(n <= 2.6e-42)) {
tmp = Math.sqrt((((2.0 * n) * U) * (t - ((n * Math.pow((l_m / Om), 2.0)) * (U - U_42_)))));
} else {
tmp = Math.sqrt(((2.0 * (U * (n * t))) + (-4.0 * ((U * (n * Math.pow(l_m, 2.0))) / Om))));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if (n <= -2.6e-131) or not (n <= 2.6e-42): tmp = math.sqrt((((2.0 * n) * U) * (t - ((n * math.pow((l_m / Om), 2.0)) * (U - U_42_))))) else: tmp = math.sqrt(((2.0 * (U * (n * t))) + (-4.0 * ((U * (n * math.pow(l_m, 2.0))) / Om)))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if ((n <= -2.6e-131) || !(n <= 2.6e-42)) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t - Float64(Float64(n * (Float64(l_m / Om) ^ 2.0)) * Float64(U - U_42_))))); else tmp = sqrt(Float64(Float64(2.0 * Float64(U * Float64(n * t))) + Float64(-4.0 * Float64(Float64(U * Float64(n * (l_m ^ 2.0))) / Om)))); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) tmp = 0.0; if ((n <= -2.6e-131) || ~((n <= 2.6e-42))) tmp = sqrt((((2.0 * n) * U) * (t - ((n * ((l_m / Om) ^ 2.0)) * (U - U_42_))))); else tmp = sqrt(((2.0 * (U * (n * t))) + (-4.0 * ((U * (n * (l_m ^ 2.0))) / Om)))); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[Or[LessEqual[n, -2.6e-131], N[Not[LessEqual[n, 2.6e-42]], $MachinePrecision]], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t - N[(N[(n * N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U - U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(-4.0 * N[(N[(U * N[(n * N[Power[l$95$m, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;n \leq -2.6 \cdot 10^{-131} \lor \neg \left(n \leq 2.6 \cdot 10^{-42}\right):\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t - \left(n \cdot {\left(\frac{l\_m}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right) + -4 \cdot \frac{U \cdot \left(n \cdot {l\_m}^{2}\right)}{Om}}\\
\end{array}
\end{array}
if n < -2.59999999999999996e-131 or 2.6e-42 < n Initial program 50.0%
add-sqr-sqrt24.1%
times-frac25.4%
Applied egg-rr25.4%
unpow225.4%
Simplified25.4%
Taylor expanded in t around inf 53.2%
if -2.59999999999999996e-131 < n < 2.6e-42Initial program 41.2%
Simplified43.3%
Taylor expanded in Om around inf 49.6%
Final simplification51.7%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (<= n -1.2e-142) (sqrt (* (* (* 2.0 n) U) (- t (* (* n (pow (/ l_m Om) 2.0)) (- U U*))))) (sqrt (* (* 2.0 U) (* n (+ t (* (/ (pow l_m 2.0) Om) -2.0)))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (n <= -1.2e-142) {
tmp = sqrt((((2.0 * n) * U) * (t - ((n * pow((l_m / Om), 2.0)) * (U - U_42_)))));
} else {
tmp = sqrt(((2.0 * U) * (n * (t + ((pow(l_m, 2.0) / Om) * -2.0)))));
}
return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l_m
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (n <= (-1.2d-142)) then
tmp = sqrt((((2.0d0 * n) * u) * (t - ((n * ((l_m / om) ** 2.0d0)) * (u - u_42)))))
else
tmp = sqrt(((2.0d0 * u) * (n * (t + (((l_m ** 2.0d0) / om) * (-2.0d0))))))
end if
code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (n <= -1.2e-142) {
tmp = Math.sqrt((((2.0 * n) * U) * (t - ((n * Math.pow((l_m / Om), 2.0)) * (U - U_42_)))));
} else {
tmp = Math.sqrt(((2.0 * U) * (n * (t + ((Math.pow(l_m, 2.0) / Om) * -2.0)))));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if n <= -1.2e-142: tmp = math.sqrt((((2.0 * n) * U) * (t - ((n * math.pow((l_m / Om), 2.0)) * (U - U_42_))))) else: tmp = math.sqrt(((2.0 * U) * (n * (t + ((math.pow(l_m, 2.0) / Om) * -2.0))))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (n <= -1.2e-142) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t - Float64(Float64(n * (Float64(l_m / Om) ^ 2.0)) * Float64(U - U_42_))))); else tmp = sqrt(Float64(Float64(2.0 * U) * Float64(n * Float64(t + Float64(Float64((l_m ^ 2.0) / Om) * -2.0))))); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) tmp = 0.0; if (n <= -1.2e-142) tmp = sqrt((((2.0 * n) * U) * (t - ((n * ((l_m / Om) ^ 2.0)) * (U - U_42_))))); else tmp = sqrt(((2.0 * U) * (n * (t + (((l_m ^ 2.0) / Om) * -2.0))))); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[n, -1.2e-142], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t - N[(N[(n * N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U - U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(2.0 * U), $MachinePrecision] * N[(n * N[(t + N[(N[(N[Power[l$95$m, 2.0], $MachinePrecision] / Om), $MachinePrecision] * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;n \leq -1.2 \cdot 10^{-142}:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t - \left(n \cdot {\left(\frac{l\_m}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot U\right) \cdot \left(n \cdot \left(t + \frac{{l\_m}^{2}}{Om} \cdot -2\right)\right)}\\
\end{array}
\end{array}
if n < -1.19999999999999994e-142Initial program 53.3%
add-sqr-sqrt27.7%
times-frac28.9%
Applied egg-rr28.9%
unpow228.9%
Simplified28.9%
Taylor expanded in t around inf 60.0%
if -1.19999999999999994e-142 < n Initial program 43.2%
Simplified47.2%
Taylor expanded in U around 0 40.8%
associate-/l*40.8%
unpow240.8%
unpow240.8%
times-frac47.4%
unpow247.4%
neg-mul-147.4%
distribute-lft-neg-out47.4%
*-commutative47.4%
Simplified47.4%
Taylor expanded in n around 0 44.9%
associate-*r*44.9%
cancel-sign-sub-inv44.9%
metadata-eval44.9%
*-commutative44.9%
Simplified44.9%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (<= t 5.3e-223) (sqrt (* 2.0 (* U (* n (- t (* 2.0 (/ (pow l_m 2.0) Om))))))) (* (sqrt (* 2.0 (* n U))) (sqrt t))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (t <= 5.3e-223) {
tmp = sqrt((2.0 * (U * (n * (t - (2.0 * (pow(l_m, 2.0) / Om)))))));
} else {
tmp = sqrt((2.0 * (n * U))) * sqrt(t);
}
return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l_m
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (t <= 5.3d-223) then
tmp = sqrt((2.0d0 * (u * (n * (t - (2.0d0 * ((l_m ** 2.0d0) / om)))))))
else
tmp = sqrt((2.0d0 * (n * u))) * sqrt(t)
end if
code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (t <= 5.3e-223) {
tmp = Math.sqrt((2.0 * (U * (n * (t - (2.0 * (Math.pow(l_m, 2.0) / Om)))))));
} else {
tmp = Math.sqrt((2.0 * (n * U))) * Math.sqrt(t);
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if t <= 5.3e-223: tmp = math.sqrt((2.0 * (U * (n * (t - (2.0 * (math.pow(l_m, 2.0) / Om))))))) else: tmp = math.sqrt((2.0 * (n * U))) * math.sqrt(t) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (t <= 5.3e-223) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * Float64(t - Float64(2.0 * Float64((l_m ^ 2.0) / Om))))))); else tmp = Float64(sqrt(Float64(2.0 * Float64(n * U))) * sqrt(t)); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) tmp = 0.0; if (t <= 5.3e-223) tmp = sqrt((2.0 * (U * (n * (t - (2.0 * ((l_m ^ 2.0) / Om))))))); else tmp = sqrt((2.0 * (n * U))) * sqrt(t); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[t, 5.3e-223], N[Sqrt[N[(2.0 * N[(U * N[(n * N[(t - N[(2.0 * N[(N[Power[l$95$m, 2.0], $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sqrt[t], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;t \leq 5.3 \cdot 10^{-223}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot \left(t - 2 \cdot \frac{{l\_m}^{2}}{Om}\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot U\right)} \cdot \sqrt{t}\\
\end{array}
\end{array}
if t < 5.30000000000000027e-223Initial program 50.0%
Simplified53.4%
Taylor expanded in n around 0 46.9%
if 5.30000000000000027e-223 < t Initial program 40.6%
Simplified47.3%
Taylor expanded in t around inf 31.1%
pow1/233.2%
associate-*r*36.0%
associate-*r*36.0%
unpow-prod-down45.0%
pow1/245.0%
pow1/245.0%
Applied egg-rr45.0%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (<= l_m 2.9e+109) (pow (* (* n t) (* 2.0 U)) 0.5) (* l_m (* (sqrt (* U U*)) (* n (/ (sqrt 2.0) Om))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (l_m <= 2.9e+109) {
tmp = pow(((n * t) * (2.0 * U)), 0.5);
} else {
tmp = l_m * (sqrt((U * U_42_)) * (n * (sqrt(2.0) / Om)));
}
return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l_m
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (l_m <= 2.9d+109) then
tmp = ((n * t) * (2.0d0 * u)) ** 0.5d0
else
tmp = l_m * (sqrt((u * u_42)) * (n * (sqrt(2.0d0) / om)))
end if
code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (l_m <= 2.9e+109) {
tmp = Math.pow(((n * t) * (2.0 * U)), 0.5);
} else {
tmp = l_m * (Math.sqrt((U * U_42_)) * (n * (Math.sqrt(2.0) / Om)));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if l_m <= 2.9e+109: tmp = math.pow(((n * t) * (2.0 * U)), 0.5) else: tmp = l_m * (math.sqrt((U * U_42_)) * (n * (math.sqrt(2.0) / Om))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (l_m <= 2.9e+109) tmp = Float64(Float64(n * t) * Float64(2.0 * U)) ^ 0.5; else tmp = Float64(l_m * Float64(sqrt(Float64(U * U_42_)) * Float64(n * Float64(sqrt(2.0) / Om)))); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) tmp = 0.0; if (l_m <= 2.9e+109) tmp = ((n * t) * (2.0 * U)) ^ 0.5; else tmp = l_m * (sqrt((U * U_42_)) * (n * (sqrt(2.0) / Om))); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[l$95$m, 2.9e+109], N[Power[N[(N[(n * t), $MachinePrecision] * N[(2.0 * U), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], N[(l$95$m * N[(N[Sqrt[N[(U * U$42$), $MachinePrecision]], $MachinePrecision] * N[(n * N[(N[Sqrt[2.0], $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;l\_m \leq 2.9 \cdot 10^{+109}:\\
\;\;\;\;{\left(\left(n \cdot t\right) \cdot \left(2 \cdot U\right)\right)}^{0.5}\\
\mathbf{else}:\\
\;\;\;\;l\_m \cdot \left(\sqrt{U \cdot U*} \cdot \left(n \cdot \frac{\sqrt{2}}{Om}\right)\right)\\
\end{array}
\end{array}
if l < 2.9e109Initial program 50.7%
Simplified54.0%
Taylor expanded in t around inf 39.5%
add-exp-log17.3%
Applied egg-rr17.3%
pow1/218.3%
associate-*r*18.3%
rem-exp-log41.4%
Applied egg-rr41.4%
if 2.9e109 < l Initial program 23.6%
Simplified33.2%
sub-neg33.2%
distribute-lft-in20.7%
Applied egg-rr20.7%
distribute-lft-out33.2%
sub-neg33.2%
associate-*r*35.3%
*-commutative35.3%
Simplified35.3%
div-inv35.3%
Applied egg-rr35.3%
Taylor expanded in U* around inf 18.6%
associate-/l*20.9%
associate-*r/20.9%
associate-*r*20.9%
*-commutative20.9%
associate-*r/20.9%
Simplified20.9%
Taylor expanded in U around 0 20.9%
associate-*r/20.9%
*-commutative20.9%
Simplified20.9%
Final simplification38.1%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (<= t 4.5e-250) (pow (* (* n t) (* 2.0 U)) 0.5) (* (sqrt (* 2.0 (* n U))) (sqrt t))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (t <= 4.5e-250) {
tmp = pow(((n * t) * (2.0 * U)), 0.5);
} else {
tmp = sqrt((2.0 * (n * U))) * sqrt(t);
}
return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l_m
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (t <= 4.5d-250) then
tmp = ((n * t) * (2.0d0 * u)) ** 0.5d0
else
tmp = sqrt((2.0d0 * (n * u))) * sqrt(t)
end if
code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (t <= 4.5e-250) {
tmp = Math.pow(((n * t) * (2.0 * U)), 0.5);
} else {
tmp = Math.sqrt((2.0 * (n * U))) * Math.sqrt(t);
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if t <= 4.5e-250: tmp = math.pow(((n * t) * (2.0 * U)), 0.5) else: tmp = math.sqrt((2.0 * (n * U))) * math.sqrt(t) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (t <= 4.5e-250) tmp = Float64(Float64(n * t) * Float64(2.0 * U)) ^ 0.5; else tmp = Float64(sqrt(Float64(2.0 * Float64(n * U))) * sqrt(t)); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) tmp = 0.0; if (t <= 4.5e-250) tmp = ((n * t) * (2.0 * U)) ^ 0.5; else tmp = sqrt((2.0 * (n * U))) * sqrt(t); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[t, 4.5e-250], N[Power[N[(N[(n * t), $MachinePrecision] * N[(2.0 * U), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], N[(N[Sqrt[N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision] * N[Sqrt[t], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;t \leq 4.5 \cdot 10^{-250}:\\
\;\;\;\;{\left(\left(n \cdot t\right) \cdot \left(2 \cdot U\right)\right)}^{0.5}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot U\right)} \cdot \sqrt{t}\\
\end{array}
\end{array}
if t < 4.49999999999999993e-250Initial program 50.6%
Simplified54.1%
Taylor expanded in t around inf 35.9%
add-exp-log15.7%
Applied egg-rr15.7%
pow1/216.4%
associate-*r*16.4%
rem-exp-log37.9%
Applied egg-rr37.9%
if 4.49999999999999993e-250 < t Initial program 40.1%
Simplified46.6%
Taylor expanded in t around inf 30.0%
pow1/232.0%
associate-*r*34.7%
associate-*r*34.7%
unpow-prod-down44.3%
pow1/244.3%
pow1/244.3%
Applied egg-rr44.3%
Final simplification40.5%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (<= U 1e-247) (pow (* (* n t) (* 2.0 U)) 0.5) (* (sqrt (* 2.0 U)) (sqrt (* n t)))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (U <= 1e-247) {
tmp = pow(((n * t) * (2.0 * U)), 0.5);
} else {
tmp = sqrt((2.0 * U)) * sqrt((n * t));
}
return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l_m
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (u <= 1d-247) then
tmp = ((n * t) * (2.0d0 * u)) ** 0.5d0
else
tmp = sqrt((2.0d0 * u)) * sqrt((n * t))
end if
code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (U <= 1e-247) {
tmp = Math.pow(((n * t) * (2.0 * U)), 0.5);
} else {
tmp = Math.sqrt((2.0 * U)) * Math.sqrt((n * t));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if U <= 1e-247: tmp = math.pow(((n * t) * (2.0 * U)), 0.5) else: tmp = math.sqrt((2.0 * U)) * math.sqrt((n * t)) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (U <= 1e-247) tmp = Float64(Float64(n * t) * Float64(2.0 * U)) ^ 0.5; else tmp = Float64(sqrt(Float64(2.0 * U)) * sqrt(Float64(n * t))); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) tmp = 0.0; if (U <= 1e-247) tmp = ((n * t) * (2.0 * U)) ^ 0.5; else tmp = sqrt((2.0 * U)) * sqrt((n * t)); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[U, 1e-247], N[Power[N[(N[(n * t), $MachinePrecision] * N[(2.0 * U), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], N[(N[Sqrt[N[(2.0 * U), $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(n * t), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;U \leq 10^{-247}:\\
\;\;\;\;{\left(\left(n \cdot t\right) \cdot \left(2 \cdot U\right)\right)}^{0.5}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot U} \cdot \sqrt{n \cdot t}\\
\end{array}
\end{array}
if U < 1e-247Initial program 46.9%
Simplified53.9%
Taylor expanded in t around inf 36.9%
add-exp-log5.7%
Applied egg-rr5.7%
pow1/27.1%
associate-*r*7.1%
rem-exp-log38.3%
Applied egg-rr38.3%
if 1e-247 < U Initial program 45.6%
Simplified46.6%
Taylor expanded in t around inf 31.2%
pow1/235.2%
associate-*r*35.2%
unpow-prod-down44.8%
pow1/241.8%
Applied egg-rr41.8%
unpow1/241.8%
Simplified41.8%
Final simplification39.7%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (<= U* 1.75e+79) (sqrt (* 2.0 (* U (* n t)))) (pow (* 2.0 (* t (* n U))) 0.5)))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (U_42_ <= 1.75e+79) {
tmp = sqrt((2.0 * (U * (n * t))));
} else {
tmp = pow((2.0 * (t * (n * U))), 0.5);
}
return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l_m
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (u_42 <= 1.75d+79) then
tmp = sqrt((2.0d0 * (u * (n * t))))
else
tmp = (2.0d0 * (t * (n * u))) ** 0.5d0
end if
code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (U_42_ <= 1.75e+79) {
tmp = Math.sqrt((2.0 * (U * (n * t))));
} else {
tmp = Math.pow((2.0 * (t * (n * U))), 0.5);
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if U_42_ <= 1.75e+79: tmp = math.sqrt((2.0 * (U * (n * t)))) else: tmp = math.pow((2.0 * (t * (n * U))), 0.5) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (U_42_ <= 1.75e+79) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t)))); else tmp = Float64(2.0 * Float64(t * Float64(n * U))) ^ 0.5; end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) tmp = 0.0; if (U_42_ <= 1.75e+79) tmp = sqrt((2.0 * (U * (n * t)))); else tmp = (2.0 * (t * (n * U))) ^ 0.5; end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[U$42$, 1.75e+79], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Power[N[(2.0 * N[(t * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;U* \leq 1.75 \cdot 10^{+79}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;{\left(2 \cdot \left(t \cdot \left(n \cdot U\right)\right)\right)}^{0.5}\\
\end{array}
\end{array}
if U* < 1.7499999999999999e79Initial program 46.5%
Simplified52.4%
Taylor expanded in t around inf 37.0%
if 1.7499999999999999e79 < U* Initial program 45.7%
Simplified45.7%
Taylor expanded in t around inf 25.4%
pow1/231.1%
associate-*r*36.6%
*-commutative36.6%
Applied egg-rr36.6%
Final simplification36.9%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (<= U* 6200000000.0) (sqrt (* 2.0 (* U (* n t)))) (pow (* 2.0 (* n (* U t))) 0.5)))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (U_42_ <= 6200000000.0) {
tmp = sqrt((2.0 * (U * (n * t))));
} else {
tmp = pow((2.0 * (n * (U * t))), 0.5);
}
return tmp;
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l_m
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (u_42 <= 6200000000.0d0) then
tmp = sqrt((2.0d0 * (u * (n * t))))
else
tmp = (2.0d0 * (n * (u * t))) ** 0.5d0
end if
code = tmp
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (U_42_ <= 6200000000.0) {
tmp = Math.sqrt((2.0 * (U * (n * t))));
} else {
tmp = Math.pow((2.0 * (n * (U * t))), 0.5);
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if U_42_ <= 6200000000.0: tmp = math.sqrt((2.0 * (U * (n * t)))) else: tmp = math.pow((2.0 * (n * (U * t))), 0.5) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (U_42_ <= 6200000000.0) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t)))); else tmp = Float64(2.0 * Float64(n * Float64(U * t))) ^ 0.5; end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) tmp = 0.0; if (U_42_ <= 6200000000.0) tmp = sqrt((2.0 * (U * (n * t)))); else tmp = (2.0 * (n * (U * t))) ^ 0.5; end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[U$42$, 6200000000.0], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Power[N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;U* \leq 6200000000:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;{\left(2 \cdot \left(n \cdot \left(U \cdot t\right)\right)\right)}^{0.5}\\
\end{array}
\end{array}
if U* < 6.2e9Initial program 46.6%
Simplified52.4%
Taylor expanded in t around inf 36.8%
if 6.2e9 < U* Initial program 45.7%
Simplified47.2%
Taylor expanded in t around inf 31.7%
pow1/236.2%
associate-*l*36.2%
Applied egg-rr36.2%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (pow (* (* n t) (* 2.0 U)) 0.5))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
return pow(((n * t) * (2.0 * U)), 0.5);
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l_m
real(8), intent (in) :: om
real(8), intent (in) :: u_42
code = ((n * t) * (2.0d0 * u)) ** 0.5d0
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
return Math.pow(((n * t) * (2.0 * U)), 0.5);
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): return math.pow(((n * t) * (2.0 * U)), 0.5)
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) return Float64(Float64(n * t) * Float64(2.0 * U)) ^ 0.5 end
l_m = abs(l); function tmp = code(n, U, t, l_m, Om, U_42_) tmp = ((n * t) * (2.0 * U)) ^ 0.5; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := N[Power[N[(N[(n * t), $MachinePrecision] * N[(2.0 * U), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]
\begin{array}{l}
l_m = \left|\ell\right|
\\
{\left(\left(n \cdot t\right) \cdot \left(2 \cdot U\right)\right)}^{0.5}
\end{array}
Initial program 46.4%
Simplified51.0%
Taylor expanded in t around inf 34.6%
add-exp-log15.1%
Applied egg-rr15.1%
pow1/215.9%
associate-*r*15.9%
rem-exp-log37.1%
Applied egg-rr37.1%
Final simplification37.1%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (sqrt (* 2.0 (* U (* n t)))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
return sqrt((2.0 * (U * (n * t))));
}
l_m = abs(l)
real(8) function code(n, u, t, l_m, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l_m
real(8), intent (in) :: om
real(8), intent (in) :: u_42
code = sqrt((2.0d0 * (u * (n * t))))
end function
l_m = Math.abs(l);
public static double code(double n, double U, double t, double l_m, double Om, double U_42_) {
return Math.sqrt((2.0 * (U * (n * t))));
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): return math.sqrt((2.0 * (U * (n * t))))
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) return sqrt(Float64(2.0 * Float64(U * Float64(n * t)))) end
l_m = abs(l); function tmp = code(n, U, t, l_m, Om, U_42_) tmp = sqrt((2.0 * (U * (n * t)))); end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}
\end{array}
Initial program 46.4%
Simplified51.0%
Taylor expanded in t around inf 34.6%
herbie shell --seed 2024143
(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*))))))