
(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 (* (* n (pow (/ l_m Om) 2.0)) (- U* U)))
(t_2
(sqrt (* (* (* 2.0 n) U) (+ (- t (* 2.0 (/ (* l_m l_m) Om))) t_1)))))
(if (<= t_2 0.01)
(sqrt
(*
(* 2.0 n)
(*
U
(+
t
(/ (- (* U* (/ (* n (pow l_m 2.0)) Om)) (* 2.0 (pow l_m 2.0))) Om)))))
(if (<= t_2 INFINITY)
(sqrt (* (* 2.0 (* n U)) (+ t (- t_1 (* 2.0 (* l_m (/ l_m Om)))))))
(*
(sqrt (/ (- (* -2.0 (/ U n)) (/ (* U (- U U*)) Om)) Om))
(* l_m (* (sqrt 2.0) (- n))))))))l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = (n * pow((l_m / Om), 2.0)) * (U_42_ - U);
double t_2 = sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1)));
double tmp;
if (t_2 <= 0.01) {
tmp = sqrt(((2.0 * n) * (U * (t + (((U_42_ * ((n * pow(l_m, 2.0)) / Om)) - (2.0 * pow(l_m, 2.0))) / Om)))));
} else if (t_2 <= ((double) INFINITY)) {
tmp = sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om)))))));
} else {
tmp = sqrt((((-2.0 * (U / n)) - ((U * (U - U_42_)) / Om)) / Om)) * (l_m * (sqrt(2.0) * -n));
}
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 = (n * Math.pow((l_m / Om), 2.0)) * (U_42_ - U);
double t_2 = Math.sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1)));
double tmp;
if (t_2 <= 0.01) {
tmp = Math.sqrt(((2.0 * n) * (U * (t + (((U_42_ * ((n * Math.pow(l_m, 2.0)) / Om)) - (2.0 * Math.pow(l_m, 2.0))) / Om)))));
} else if (t_2 <= Double.POSITIVE_INFINITY) {
tmp = Math.sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om)))))));
} else {
tmp = Math.sqrt((((-2.0 * (U / n)) - ((U * (U - U_42_)) / Om)) / Om)) * (l_m * (Math.sqrt(2.0) * -n));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): t_1 = (n * math.pow((l_m / Om), 2.0)) * (U_42_ - U) t_2 = math.sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1))) tmp = 0 if t_2 <= 0.01: tmp = math.sqrt(((2.0 * n) * (U * (t + (((U_42_ * ((n * math.pow(l_m, 2.0)) / Om)) - (2.0 * math.pow(l_m, 2.0))) / Om))))) elif t_2 <= math.inf: tmp = math.sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om))))))) else: tmp = math.sqrt((((-2.0 * (U / n)) - ((U * (U - U_42_)) / Om)) / Om)) * (l_m * (math.sqrt(2.0) * -n)) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) t_1 = Float64(Float64(n * (Float64(l_m / Om) ^ 2.0)) * Float64(U_42_ - U)) t_2 = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l_m * l_m) / Om))) + t_1))) tmp = 0.0 if (t_2 <= 0.01) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(Float64(U_42_ * Float64(Float64(n * (l_m ^ 2.0)) / Om)) - Float64(2.0 * (l_m ^ 2.0))) / Om))))); elseif (t_2 <= Inf) tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * Float64(t + Float64(t_1 - Float64(2.0 * Float64(l_m * Float64(l_m / Om))))))); else tmp = Float64(sqrt(Float64(Float64(Float64(-2.0 * Float64(U / n)) - Float64(Float64(U * Float64(U - U_42_)) / Om)) / Om)) * Float64(l_m * Float64(sqrt(2.0) * Float64(-n)))); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) t_1 = (n * ((l_m / Om) ^ 2.0)) * (U_42_ - U); t_2 = sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1))); tmp = 0.0; if (t_2 <= 0.01) tmp = sqrt(((2.0 * n) * (U * (t + (((U_42_ * ((n * (l_m ^ 2.0)) / Om)) - (2.0 * (l_m ^ 2.0))) / Om))))); elseif (t_2 <= Inf) tmp = sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om))))))); else tmp = sqrt((((-2.0 * (U / n)) - ((U * (U - U_42_)) / Om)) / Om)) * (l_m * (sqrt(2.0) * -n)); 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[(N[(n * N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Sqrt[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] + t$95$1), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$2, 0.01], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(N[(U$42$ * N[(N[(n * N[Power[l$95$m, 2.0], $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] - N[(2.0 * N[Power[l$95$m, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $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[(t$95$1 - N[(2.0 * N[(l$95$m * N[(l$95$m / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(N[(N[(-2.0 * N[(U / n), $MachinePrecision]), $MachinePrecision] - N[(N[(U * N[(U - U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]], $MachinePrecision] * N[(l$95$m * N[(N[Sqrt[2.0], $MachinePrecision] * (-n)), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
t_1 := \left(n \cdot {\left(\frac{l\_m}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\\
t_2 := \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{l\_m \cdot l\_m}{Om}\right) + t\_1\right)}\\
\mathbf{if}\;t\_2 \leq 0.01:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{U* \cdot \frac{n \cdot {l\_m}^{2}}{Om} - 2 \cdot {l\_m}^{2}}{Om}\right)\right)}\\
\mathbf{elif}\;t\_2 \leq \infty:\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(t\_1 - 2 \cdot \left(l\_m \cdot \frac{l\_m}{Om}\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\frac{-2 \cdot \frac{U}{n} - \frac{U \cdot \left(U - U*\right)}{Om}}{Om}} \cdot \left(l\_m \cdot \left(\sqrt{2} \cdot \left(-n\right)\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*))))) < 0.0100000000000000002Initial program 61.3%
Simplified71.2%
Taylor expanded in U around 0 68.4%
associate-/l*70.2%
unpow270.2%
unpow270.2%
times-frac70.8%
unpow270.8%
neg-mul-170.8%
distribute-lft-neg-out70.8%
*-commutative70.8%
Simplified70.8%
div-inv70.8%
Applied egg-rr70.8%
Taylor expanded in Om around -inf 74.0%
mul-1-neg74.0%
unsub-neg74.0%
cancel-sign-sub-inv74.0%
metadata-eval74.0%
+-commutative74.0%
mul-1-neg74.0%
unsub-neg74.0%
associate-/l*73.7%
*-commutative73.7%
Simplified73.7%
if 0.0100000000000000002 < (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 68.5%
Simplified73.7%
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%
Simplified8.4%
Taylor expanded in n around inf 0.5%
Taylor expanded in l around -inf 15.6%
mul-1-neg15.6%
*-commutative15.6%
associate-*r/15.6%
metadata-eval15.6%
*-commutative15.6%
Simplified15.6%
Taylor expanded in Om around inf 30.4%
Final simplification65.6%
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
:precision binary64
(let* ((t_1 (* (* n (pow (/ l_m Om) 2.0)) (- U* U)))
(t_2 (* (* (* 2.0 n) U) (+ (- t (* 2.0 (/ (* l_m l_m) Om))) t_1))))
(if (<= t_2 0.0)
(sqrt (fabs (* (* 2.0 n) (* U t))))
(if (<= t_2 INFINITY)
(sqrt (* (* 2.0 (* n U)) (+ t (- t_1 (* 2.0 (* l_m (/ l_m Om)))))))
(*
(sqrt (/ (- (* -2.0 (/ U n)) (/ (* U (- U U*)) Om)) Om))
(* l_m (* (sqrt 2.0) (- n))))))))l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = (n * pow((l_m / Om), 2.0)) * (U_42_ - U);
double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1);
double tmp;
if (t_2 <= 0.0) {
tmp = sqrt(fabs(((2.0 * n) * (U * t))));
} else if (t_2 <= ((double) INFINITY)) {
tmp = sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om)))))));
} else {
tmp = sqrt((((-2.0 * (U / n)) - ((U * (U - U_42_)) / Om)) / Om)) * (l_m * (sqrt(2.0) * -n));
}
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 = (n * Math.pow((l_m / Om), 2.0)) * (U_42_ - U);
double t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1);
double tmp;
if (t_2 <= 0.0) {
tmp = Math.sqrt(Math.abs(((2.0 * n) * (U * t))));
} else if (t_2 <= Double.POSITIVE_INFINITY) {
tmp = Math.sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om)))))));
} else {
tmp = Math.sqrt((((-2.0 * (U / n)) - ((U * (U - U_42_)) / Om)) / Om)) * (l_m * (Math.sqrt(2.0) * -n));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): t_1 = (n * math.pow((l_m / Om), 2.0)) * (U_42_ - U) t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1) tmp = 0 if t_2 <= 0.0: tmp = math.sqrt(math.fabs(((2.0 * n) * (U * t)))) elif t_2 <= math.inf: tmp = math.sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om))))))) else: tmp = math.sqrt((((-2.0 * (U / n)) - ((U * (U - U_42_)) / Om)) / Om)) * (l_m * (math.sqrt(2.0) * -n)) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) t_1 = Float64(Float64(n * (Float64(l_m / Om) ^ 2.0)) * Float64(U_42_ - U)) t_2 = Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l_m * l_m) / Om))) + t_1)) tmp = 0.0 if (t_2 <= 0.0) tmp = sqrt(abs(Float64(Float64(2.0 * n) * Float64(U * t)))); elseif (t_2 <= Inf) tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * Float64(t + Float64(t_1 - Float64(2.0 * Float64(l_m * Float64(l_m / Om))))))); else tmp = Float64(sqrt(Float64(Float64(Float64(-2.0 * Float64(U / n)) - Float64(Float64(U * Float64(U - U_42_)) / Om)) / Om)) * Float64(l_m * Float64(sqrt(2.0) * Float64(-n)))); end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) t_1 = (n * ((l_m / Om) ^ 2.0)) * (U_42_ - U); t_2 = ((2.0 * n) * U) * ((t - (2.0 * ((l_m * l_m) / Om))) + t_1); tmp = 0.0; if (t_2 <= 0.0) tmp = sqrt(abs(((2.0 * n) * (U * t)))); elseif (t_2 <= Inf) tmp = sqrt(((2.0 * (n * U)) * (t + (t_1 - (2.0 * (l_m * (l_m / Om))))))); else tmp = sqrt((((-2.0 * (U / n)) - ((U * (U - U_42_)) / Om)) / Om)) * (l_m * (sqrt(2.0) * -n)); 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[(N[(n * N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $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] + t$95$1), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$2, 0.0], N[Sqrt[N[Abs[N[(N[(2.0 * n), $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[(t$95$1 - N[(2.0 * N[(l$95$m * N[(l$95$m / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(N[(N[(-2.0 * N[(U / n), $MachinePrecision]), $MachinePrecision] - N[(N[(U * N[(U - U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]], $MachinePrecision] * N[(l$95$m * N[(N[Sqrt[2.0], $MachinePrecision] * (-n)), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
t_1 := \left(n \cdot {\left(\frac{l\_m}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\\
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) + t\_1\right)\\
\mathbf{if}\;t\_2 \leq 0:\\
\;\;\;\;\sqrt{\left|\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right|}\\
\mathbf{elif}\;t\_2 \leq \infty:\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(t\_1 - 2 \cdot \left(l\_m \cdot \frac{l\_m}{Om}\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\frac{-2 \cdot \frac{U}{n} - \frac{U \cdot \left(U - U*\right)}{Om}}{Om}} \cdot \left(l\_m \cdot \left(\sqrt{2} \cdot \left(-n\right)\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*)))) < 0.0Initial program 7.6%
Simplified33.8%
Taylor expanded in Om around inf 33.2%
Taylor expanded in l around 0 36.2%
associate-*r*36.4%
associate-*r*10.6%
Simplified10.6%
add-sqr-sqrt10.6%
pow1/210.6%
pow1/211.0%
pow-prod-down11.3%
pow211.3%
associate-*l*11.3%
*-commutative11.3%
associate-*r*11.3%
Applied egg-rr11.3%
unpow1/211.3%
unpow211.3%
rem-sqrt-square11.3%
associate-*l*37.1%
Simplified37.1%
if 0.0 < (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*)))) < +inf.0Initial program 75.1%
Simplified78.8%
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%
Simplified6.8%
Taylor expanded in n around inf 0.5%
Taylor expanded in l around -inf 14.7%
mul-1-neg14.7%
*-commutative14.7%
associate-*r/14.7%
metadata-eval14.7%
*-commutative14.7%
Simplified14.7%
Taylor expanded in Om around inf 33.0%
Final simplification65.6%
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
:precision binary64
(let* ((t_1 (sqrt (* 2.0 (* U (* n (- t (* 2.0 (/ (pow l_m 2.0) Om))))))))
(t_2 (sqrt (fabs (* 2.0 (* t (* n U)))))))
(if (<= n -9.5e-51)
t_2
(if (<= n 2.4e-305)
t_1
(if (<= n 3.4e-186)
(* (sqrt (* 2.0 n)) (sqrt (* U t)))
(if (<= n 2.8e+137) t_1 t_2))))))l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double t_1 = sqrt((2.0 * (U * (n * (t - (2.0 * (pow(l_m, 2.0) / Om)))))));
double t_2 = sqrt(fabs((2.0 * (t * (n * U)))));
double tmp;
if (n <= -9.5e-51) {
tmp = t_2;
} else if (n <= 2.4e-305) {
tmp = t_1;
} else if (n <= 3.4e-186) {
tmp = sqrt((2.0 * n)) * sqrt((U * t));
} else if (n <= 2.8e+137) {
tmp = t_1;
} else {
tmp = t_2;
}
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) :: t_2
real(8) :: tmp
t_1 = sqrt((2.0d0 * (u * (n * (t - (2.0d0 * ((l_m ** 2.0d0) / om)))))))
t_2 = sqrt(abs((2.0d0 * (t * (n * u)))))
if (n <= (-9.5d-51)) then
tmp = t_2
else if (n <= 2.4d-305) then
tmp = t_1
else if (n <= 3.4d-186) then
tmp = sqrt((2.0d0 * n)) * sqrt((u * t))
else if (n <= 2.8d+137) then
tmp = t_1
else
tmp = t_2
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 = Math.sqrt((2.0 * (U * (n * (t - (2.0 * (Math.pow(l_m, 2.0) / Om)))))));
double t_2 = Math.sqrt(Math.abs((2.0 * (t * (n * U)))));
double tmp;
if (n <= -9.5e-51) {
tmp = t_2;
} else if (n <= 2.4e-305) {
tmp = t_1;
} else if (n <= 3.4e-186) {
tmp = Math.sqrt((2.0 * n)) * Math.sqrt((U * t));
} else if (n <= 2.8e+137) {
tmp = t_1;
} else {
tmp = t_2;
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): t_1 = math.sqrt((2.0 * (U * (n * (t - (2.0 * (math.pow(l_m, 2.0) / Om))))))) t_2 = math.sqrt(math.fabs((2.0 * (t * (n * U))))) tmp = 0 if n <= -9.5e-51: tmp = t_2 elif n <= 2.4e-305: tmp = t_1 elif n <= 3.4e-186: tmp = math.sqrt((2.0 * n)) * math.sqrt((U * t)) elif n <= 2.8e+137: tmp = t_1 else: tmp = t_2 return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) t_1 = sqrt(Float64(2.0 * Float64(U * Float64(n * Float64(t - Float64(2.0 * Float64((l_m ^ 2.0) / Om))))))) t_2 = sqrt(abs(Float64(2.0 * Float64(t * Float64(n * U))))) tmp = 0.0 if (n <= -9.5e-51) tmp = t_2; elseif (n <= 2.4e-305) tmp = t_1; elseif (n <= 3.4e-186) tmp = Float64(sqrt(Float64(2.0 * n)) * sqrt(Float64(U * t))); elseif (n <= 2.8e+137) tmp = t_1; else tmp = t_2; end return tmp end
l_m = abs(l); function tmp_2 = code(n, U, t, l_m, Om, U_42_) t_1 = sqrt((2.0 * (U * (n * (t - (2.0 * ((l_m ^ 2.0) / Om))))))); t_2 = sqrt(abs((2.0 * (t * (n * U))))); tmp = 0.0; if (n <= -9.5e-51) tmp = t_2; elseif (n <= 2.4e-305) tmp = t_1; elseif (n <= 3.4e-186) tmp = sqrt((2.0 * n)) * sqrt((U * t)); elseif (n <= 2.8e+137) tmp = t_1; else tmp = t_2; 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[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]}, Block[{t$95$2 = N[Sqrt[N[Abs[N[(2.0 * N[(t * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]}, If[LessEqual[n, -9.5e-51], t$95$2, If[LessEqual[n, 2.4e-305], t$95$1, If[LessEqual[n, 3.4e-186], N[(N[Sqrt[N[(2.0 * n), $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(U * t), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[n, 2.8e+137], t$95$1, t$95$2]]]]]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
t_1 := \sqrt{2 \cdot \left(U \cdot \left(n \cdot \left(t - 2 \cdot \frac{{l\_m}^{2}}{Om}\right)\right)\right)}\\
t_2 := \sqrt{\left|2 \cdot \left(t \cdot \left(n \cdot U\right)\right)\right|}\\
\mathbf{if}\;n \leq -9.5 \cdot 10^{-51}:\\
\;\;\;\;t\_2\\
\mathbf{elif}\;n \leq 2.4 \cdot 10^{-305}:\\
\;\;\;\;t\_1\\
\mathbf{elif}\;n \leq 3.4 \cdot 10^{-186}:\\
\;\;\;\;\sqrt{2 \cdot n} \cdot \sqrt{U \cdot t}\\
\mathbf{elif}\;n \leq 2.8 \cdot 10^{+137}:\\
\;\;\;\;t\_1\\
\mathbf{else}:\\
\;\;\;\;t\_2\\
\end{array}
\end{array}
if n < -9.4999999999999998e-51 or 2.80000000000000001e137 < n Initial program 52.2%
Simplified59.0%
Taylor expanded in t around inf 36.8%
add-sqr-sqrt36.8%
pow1/236.8%
pow1/242.9%
pow-prod-down37.1%
pow237.1%
associate-*l*37.1%
Applied egg-rr37.1%
unpow1/237.1%
associate-*r*37.3%
*-commutative37.3%
associate-*r*35.3%
unpow235.3%
rem-sqrt-square37.5%
associate-*r*45.1%
Simplified45.1%
if -9.4999999999999998e-51 < n < 2.40000000000000019e-305 or 3.3999999999999999e-186 < n < 2.80000000000000001e137Initial program 58.2%
Simplified58.3%
Taylor expanded in n around 0 56.3%
if 2.40000000000000019e-305 < n < 3.3999999999999999e-186Initial program 32.5%
Simplified36.9%
Taylor expanded in t around inf 37.6%
sqrt-prod63.7%
Applied egg-rr63.7%
*-commutative63.7%
Simplified63.7%
Final simplification52.6%
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
:precision binary64
(if (<= t -2.6e+134)
(sqrt (fabs (* (* 2.0 n) (* U t))))
(sqrt
(*
(* 2.0 (* n U))
(+
t
(-
(* n (* (pow (/ l_m Om) 2.0) (- U* U)))
(* 2.0 (* l_m (/ l_m Om)))))))))l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (t <= -2.6e+134) {
tmp = sqrt(fabs(((2.0 * n) * (U * t))));
} else {
tmp = sqrt(((2.0 * (n * U)) * (t + ((n * (pow((l_m / Om), 2.0) * (U_42_ - U))) - (2.0 * (l_m * (l_m / 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 (t <= (-2.6d+134)) then
tmp = sqrt(abs(((2.0d0 * n) * (u * t))))
else
tmp = sqrt(((2.0d0 * (n * u)) * (t + ((n * (((l_m / om) ** 2.0d0) * (u_42 - u))) - (2.0d0 * (l_m * (l_m / 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 (t <= -2.6e+134) {
tmp = Math.sqrt(Math.abs(((2.0 * n) * (U * t))));
} else {
tmp = Math.sqrt(((2.0 * (n * U)) * (t + ((n * (Math.pow((l_m / Om), 2.0) * (U_42_ - U))) - (2.0 * (l_m * (l_m / Om)))))));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if t <= -2.6e+134: tmp = math.sqrt(math.fabs(((2.0 * n) * (U * t)))) else: tmp = math.sqrt(((2.0 * (n * U)) * (t + ((n * (math.pow((l_m / Om), 2.0) * (U_42_ - U))) - (2.0 * (l_m * (l_m / Om))))))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (t <= -2.6e+134) tmp = sqrt(abs(Float64(Float64(2.0 * n) * Float64(U * t)))); else tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * Float64(t + Float64(Float64(n * Float64((Float64(l_m / Om) ^ 2.0) * Float64(U_42_ - U))) - Float64(2.0 * Float64(l_m * Float64(l_m / 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 (t <= -2.6e+134) tmp = sqrt(abs(((2.0 * n) * (U * t)))); else tmp = sqrt(((2.0 * (n * U)) * (t + ((n * (((l_m / Om) ^ 2.0) * (U_42_ - U))) - (2.0 * (l_m * (l_m / Om))))))); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[t, -2.6e+134], N[Sqrt[N[Abs[N[(N[(2.0 * n), $MachinePrecision] * N[(U * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision] * N[(t + N[(N[(n * N[(N[Power[N[(l$95$m / Om), $MachinePrecision], 2.0], $MachinePrecision] * 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]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.6 \cdot 10^{+134}:\\
\;\;\;\;\sqrt{\left|\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right|}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \left(n \cdot \left({\left(\frac{l\_m}{Om}\right)}^{2} \cdot \left(U* - U\right)\right) - 2 \cdot \left(l\_m \cdot \frac{l\_m}{Om}\right)\right)\right)}\\
\end{array}
\end{array}
if t < -2.6000000000000002e134Initial program 57.6%
Simplified71.9%
Taylor expanded in Om around inf 55.7%
Taylor expanded in l around 0 61.1%
associate-*r*61.1%
associate-*r*50.1%
Simplified50.1%
add-sqr-sqrt50.1%
pow1/250.1%
pow1/255.9%
pow-prod-down35.2%
pow235.2%
associate-*l*35.2%
*-commutative35.2%
associate-*r*35.2%
Applied egg-rr35.2%
unpow1/235.2%
unpow235.2%
rem-sqrt-square56.5%
associate-*l*72.9%
Simplified72.9%
if -2.6000000000000002e134 < t Initial program 52.8%
Simplified55.9%
sub-neg55.9%
distribute-lft-in46.9%
Applied egg-rr46.9%
distribute-lft-out55.9%
sub-neg55.9%
associate-*r*56.0%
*-commutative56.0%
Simplified56.0%
Final simplification58.4%
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
:precision binary64
(if (<= U -102.0)
(sqrt (fabs (* 2.0 (* t (* n U)))))
(if (<= U 1.3e+118)
(sqrt (* (* 2.0 n) (+ (* U t) (* -2.0 (/ (* U (pow l_m 2.0)) Om)))))
(sqrt (* 2.0 (* (* n U) (+ t (/ (* (pow l_m 2.0) -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 (U <= -102.0) {
tmp = sqrt(fabs((2.0 * (t * (n * U)))));
} else if (U <= 1.3e+118) {
tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((U * pow(l_m, 2.0)) / Om)))));
} else {
tmp = sqrt((2.0 * ((n * U) * (t + ((pow(l_m, 2.0) * -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 (u <= (-102.0d0)) then
tmp = sqrt(abs((2.0d0 * (t * (n * u)))))
else if (u <= 1.3d+118) then
tmp = sqrt(((2.0d0 * n) * ((u * t) + ((-2.0d0) * ((u * (l_m ** 2.0d0)) / om)))))
else
tmp = sqrt((2.0d0 * ((n * u) * (t + (((l_m ** 2.0d0) * (-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 (U <= -102.0) {
tmp = Math.sqrt(Math.abs((2.0 * (t * (n * U)))));
} else if (U <= 1.3e+118) {
tmp = Math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((U * Math.pow(l_m, 2.0)) / Om)))));
} else {
tmp = Math.sqrt((2.0 * ((n * U) * (t + ((Math.pow(l_m, 2.0) * -2.0) / Om)))));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if U <= -102.0: tmp = math.sqrt(math.fabs((2.0 * (t * (n * U))))) elif U <= 1.3e+118: tmp = math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((U * math.pow(l_m, 2.0)) / Om))))) else: tmp = math.sqrt((2.0 * ((n * U) * (t + ((math.pow(l_m, 2.0) * -2.0) / Om))))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (U <= -102.0) tmp = sqrt(abs(Float64(2.0 * Float64(t * Float64(n * U))))); elseif (U <= 1.3e+118) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(Float64(U * t) + Float64(-2.0 * Float64(Float64(U * (l_m ^ 2.0)) / Om))))); else tmp = sqrt(Float64(2.0 * Float64(Float64(n * U) * Float64(t + Float64(Float64((l_m ^ 2.0) * -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 (U <= -102.0) tmp = sqrt(abs((2.0 * (t * (n * U))))); elseif (U <= 1.3e+118) tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((U * (l_m ^ 2.0)) / Om))))); else tmp = sqrt((2.0 * ((n * U) * (t + (((l_m ^ 2.0) * -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[U, -102.0], N[Sqrt[N[Abs[N[(2.0 * N[(t * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision], If[LessEqual[U, 1.3e+118], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(N[(U * t), $MachinePrecision] + N[(-2.0 * N[(N[(U * N[Power[l$95$m, 2.0], $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(2.0 * N[(N[(n * U), $MachinePrecision] * N[(t + N[(N[(N[Power[l$95$m, 2.0], $MachinePrecision] * -2.0), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;U \leq -102:\\
\;\;\;\;\sqrt{\left|2 \cdot \left(t \cdot \left(n \cdot U\right)\right)\right|}\\
\mathbf{elif}\;U \leq 1.3 \cdot 10^{+118}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + -2 \cdot \frac{U \cdot {l\_m}^{2}}{Om}\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{{l\_m}^{2} \cdot -2}{Om}\right)\right)}\\
\end{array}
\end{array}
if U < -102Initial program 68.6%
Simplified64.9%
Taylor expanded in t around inf 45.3%
add-sqr-sqrt45.3%
pow1/245.3%
pow1/251.3%
pow-prod-down42.7%
pow242.7%
associate-*l*42.7%
Applied egg-rr42.7%
unpow1/242.7%
associate-*r*44.6%
*-commutative44.6%
associate-*r*44.6%
unpow244.6%
rem-sqrt-square55.6%
associate-*r*63.4%
Simplified63.4%
if -102 < U < 1.30000000000000008e118Initial program 45.7%
Simplified54.4%
Taylor expanded in Om around inf 45.1%
if 1.30000000000000008e118 < U Initial program 74.9%
Simplified55.5%
Taylor expanded in U around 0 50.4%
associate-/l*53.8%
unpow253.8%
unpow253.8%
times-frac54.5%
unpow254.5%
neg-mul-154.5%
distribute-lft-neg-out54.5%
*-commutative54.5%
Simplified54.5%
div-inv54.5%
Applied egg-rr54.5%
Taylor expanded in n around 0 64.7%
associate-*r*68.1%
cancel-sign-sub-inv68.1%
metadata-eval68.1%
associate-*r/68.1%
*-commutative68.1%
Simplified68.1%
Final simplification51.2%
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
:precision binary64
(if (<= t -2.75e-136)
(pow (* (* 2.0 U) (* n t)) 0.5)
(if (<= t 1.45e-292)
(sqrt (* -4.0 (/ (* U (* n (pow l_m 2.0))) Om)))
(sqrt (fabs (* 2.0 (* t (* n U))))))))l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (t <= -2.75e-136) {
tmp = pow(((2.0 * U) * (n * t)), 0.5);
} else if (t <= 1.45e-292) {
tmp = sqrt((-4.0 * ((U * (n * pow(l_m, 2.0))) / Om)));
} else {
tmp = sqrt(fabs((2.0 * (t * (n * U)))));
}
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 <= (-2.75d-136)) then
tmp = ((2.0d0 * u) * (n * t)) ** 0.5d0
else if (t <= 1.45d-292) then
tmp = sqrt(((-4.0d0) * ((u * (n * (l_m ** 2.0d0))) / om)))
else
tmp = sqrt(abs((2.0d0 * (t * (n * u)))))
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 <= -2.75e-136) {
tmp = Math.pow(((2.0 * U) * (n * t)), 0.5);
} else if (t <= 1.45e-292) {
tmp = Math.sqrt((-4.0 * ((U * (n * Math.pow(l_m, 2.0))) / Om)));
} else {
tmp = Math.sqrt(Math.abs((2.0 * (t * (n * U)))));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if t <= -2.75e-136: tmp = math.pow(((2.0 * U) * (n * t)), 0.5) elif t <= 1.45e-292: tmp = math.sqrt((-4.0 * ((U * (n * math.pow(l_m, 2.0))) / Om))) else: tmp = math.sqrt(math.fabs((2.0 * (t * (n * U))))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (t <= -2.75e-136) tmp = Float64(Float64(2.0 * U) * Float64(n * t)) ^ 0.5; elseif (t <= 1.45e-292) tmp = sqrt(Float64(-4.0 * Float64(Float64(U * Float64(n * (l_m ^ 2.0))) / Om))); else tmp = sqrt(abs(Float64(2.0 * Float64(t * Float64(n * U))))); 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 <= -2.75e-136) tmp = ((2.0 * U) * (n * t)) ^ 0.5; elseif (t <= 1.45e-292) tmp = sqrt((-4.0 * ((U * (n * (l_m ^ 2.0))) / Om))); else tmp = sqrt(abs((2.0 * (t * (n * U))))); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[t, -2.75e-136], N[Power[N[(N[(2.0 * U), $MachinePrecision] * N[(n * t), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], If[LessEqual[t, 1.45e-292], N[Sqrt[N[(-4.0 * N[(N[(U * N[(n * N[Power[l$95$m, 2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[Abs[N[(2.0 * N[(t * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.75 \cdot 10^{-136}:\\
\;\;\;\;{\left(\left(2 \cdot U\right) \cdot \left(n \cdot t\right)\right)}^{0.5}\\
\mathbf{elif}\;t \leq 1.45 \cdot 10^{-292}:\\
\;\;\;\;\sqrt{-4 \cdot \frac{U \cdot \left(n \cdot {l\_m}^{2}\right)}{Om}}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left|2 \cdot \left(t \cdot \left(n \cdot U\right)\right)\right|}\\
\end{array}
\end{array}
if t < -2.75e-136Initial program 55.2%
Simplified57.6%
Taylor expanded in t around inf 52.3%
pow1/254.5%
associate-*r*54.5%
Applied egg-rr54.5%
if -2.75e-136 < t < 1.44999999999999996e-292Initial program 44.9%
Simplified54.7%
Taylor expanded in Om around inf 38.4%
Taylor expanded in l around inf 36.0%
if 1.44999999999999996e-292 < t Initial program 54.9%
Simplified56.4%
Taylor expanded in t around inf 36.2%
add-sqr-sqrt36.2%
pow1/236.2%
pow1/240.5%
pow-prod-down33.4%
pow233.4%
associate-*l*33.4%
Applied egg-rr33.4%
unpow1/233.4%
associate-*r*34.2%
*-commutative34.2%
associate-*r*32.6%
unpow232.6%
rem-sqrt-square39.4%
associate-*r*43.2%
Simplified43.2%
Final simplification46.5%
l_m = (fabs.f64 l)
(FPCore (n U t l_m Om U*)
:precision binary64
(if (<= t -2.7e-135)
(pow (* (* 2.0 U) (* n t)) 0.5)
(if (<= t 2.7e-292)
(sqrt (* -4.0 (* U (* (pow l_m 2.0) (/ n Om)))))
(sqrt (fabs (* 2.0 (* t (* n U))))))))l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (t <= -2.7e-135) {
tmp = pow(((2.0 * U) * (n * t)), 0.5);
} else if (t <= 2.7e-292) {
tmp = sqrt((-4.0 * (U * (pow(l_m, 2.0) * (n / Om)))));
} else {
tmp = sqrt(fabs((2.0 * (t * (n * U)))));
}
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 <= (-2.7d-135)) then
tmp = ((2.0d0 * u) * (n * t)) ** 0.5d0
else if (t <= 2.7d-292) then
tmp = sqrt(((-4.0d0) * (u * ((l_m ** 2.0d0) * (n / om)))))
else
tmp = sqrt(abs((2.0d0 * (t * (n * u)))))
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 <= -2.7e-135) {
tmp = Math.pow(((2.0 * U) * (n * t)), 0.5);
} else if (t <= 2.7e-292) {
tmp = Math.sqrt((-4.0 * (U * (Math.pow(l_m, 2.0) * (n / Om)))));
} else {
tmp = Math.sqrt(Math.abs((2.0 * (t * (n * U)))));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if t <= -2.7e-135: tmp = math.pow(((2.0 * U) * (n * t)), 0.5) elif t <= 2.7e-292: tmp = math.sqrt((-4.0 * (U * (math.pow(l_m, 2.0) * (n / Om))))) else: tmp = math.sqrt(math.fabs((2.0 * (t * (n * U))))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (t <= -2.7e-135) tmp = Float64(Float64(2.0 * U) * Float64(n * t)) ^ 0.5; elseif (t <= 2.7e-292) tmp = sqrt(Float64(-4.0 * Float64(U * Float64((l_m ^ 2.0) * Float64(n / Om))))); else tmp = sqrt(abs(Float64(2.0 * Float64(t * Float64(n * U))))); 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 <= -2.7e-135) tmp = ((2.0 * U) * (n * t)) ^ 0.5; elseif (t <= 2.7e-292) tmp = sqrt((-4.0 * (U * ((l_m ^ 2.0) * (n / Om))))); else tmp = sqrt(abs((2.0 * (t * (n * U))))); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[t, -2.7e-135], N[Power[N[(N[(2.0 * U), $MachinePrecision] * N[(n * t), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], If[LessEqual[t, 2.7e-292], N[Sqrt[N[(-4.0 * N[(U * N[(N[Power[l$95$m, 2.0], $MachinePrecision] * N[(n / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[Abs[N[(2.0 * N[(t * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.7 \cdot 10^{-135}:\\
\;\;\;\;{\left(\left(2 \cdot U\right) \cdot \left(n \cdot t\right)\right)}^{0.5}\\
\mathbf{elif}\;t \leq 2.7 \cdot 10^{-292}:\\
\;\;\;\;\sqrt{-4 \cdot \left(U \cdot \left({l\_m}^{2} \cdot \frac{n}{Om}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left|2 \cdot \left(t \cdot \left(n \cdot U\right)\right)\right|}\\
\end{array}
\end{array}
if t < -2.69999999999999999e-135Initial program 55.2%
Simplified57.6%
Taylor expanded in t around inf 52.3%
pow1/254.5%
associate-*r*54.5%
Applied egg-rr54.5%
if -2.69999999999999999e-135 < t < 2.6999999999999999e-292Initial program 44.9%
Simplified54.7%
Taylor expanded in Om around inf 38.4%
Taylor expanded in l around inf 36.0%
associate-/l*35.9%
associate-/l*35.9%
Simplified35.9%
if 2.6999999999999999e-292 < t Initial program 54.9%
Simplified56.4%
Taylor expanded in t around inf 36.2%
add-sqr-sqrt36.2%
pow1/236.2%
pow1/240.5%
pow-prod-down33.4%
pow233.4%
associate-*l*33.4%
Applied egg-rr33.4%
unpow1/233.4%
associate-*r*34.2%
*-commutative34.2%
associate-*r*32.6%
unpow232.6%
rem-sqrt-square39.4%
associate-*r*43.2%
Simplified43.2%
Final simplification46.5%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (<= t -6.9e+72) (sqrt (fabs (* (* 2.0 n) (* U t)))) (sqrt (* 2.0 (* (* n U) (+ t (/ (* (pow l_m 2.0) -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 (t <= -6.9e+72) {
tmp = sqrt(fabs(((2.0 * n) * (U * t))));
} else {
tmp = sqrt((2.0 * ((n * U) * (t + ((pow(l_m, 2.0) * -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 (t <= (-6.9d+72)) then
tmp = sqrt(abs(((2.0d0 * n) * (u * t))))
else
tmp = sqrt((2.0d0 * ((n * u) * (t + (((l_m ** 2.0d0) * (-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 (t <= -6.9e+72) {
tmp = Math.sqrt(Math.abs(((2.0 * n) * (U * t))));
} else {
tmp = Math.sqrt((2.0 * ((n * U) * (t + ((Math.pow(l_m, 2.0) * -2.0) / Om)))));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if t <= -6.9e+72: tmp = math.sqrt(math.fabs(((2.0 * n) * (U * t)))) else: tmp = math.sqrt((2.0 * ((n * U) * (t + ((math.pow(l_m, 2.0) * -2.0) / Om))))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (t <= -6.9e+72) tmp = sqrt(abs(Float64(Float64(2.0 * n) * Float64(U * t)))); else tmp = sqrt(Float64(2.0 * Float64(Float64(n * U) * Float64(t + Float64(Float64((l_m ^ 2.0) * -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 (t <= -6.9e+72) tmp = sqrt(abs(((2.0 * n) * (U * t)))); else tmp = sqrt((2.0 * ((n * U) * (t + (((l_m ^ 2.0) * -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[t, -6.9e+72], N[Sqrt[N[Abs[N[(N[(2.0 * n), $MachinePrecision] * N[(U * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(2.0 * N[(N[(n * U), $MachinePrecision] * N[(t + N[(N[(N[Power[l$95$m, 2.0], $MachinePrecision] * -2.0), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;t \leq -6.9 \cdot 10^{+72}:\\
\;\;\;\;\sqrt{\left|\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right|}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot \left(\left(n \cdot U\right) \cdot \left(t + \frac{{l\_m}^{2} \cdot -2}{Om}\right)\right)}\\
\end{array}
\end{array}
if t < -6.90000000000000034e72Initial program 54.9%
Simplified65.4%
Taylor expanded in Om around inf 55.6%
Taylor expanded in l around 0 61.5%
associate-*r*61.6%
associate-*r*51.5%
Simplified51.5%
add-sqr-sqrt51.5%
pow1/251.5%
pow1/255.8%
pow-prod-down36.7%
pow236.7%
associate-*l*36.7%
*-commutative36.7%
associate-*r*36.7%
Applied egg-rr36.7%
unpow1/236.7%
unpow236.7%
rem-sqrt-square56.3%
associate-*l*66.4%
Simplified66.4%
if -6.90000000000000034e72 < t Initial program 53.1%
Simplified54.5%
Taylor expanded in U around 0 44.6%
associate-/l*45.9%
unpow245.9%
unpow245.9%
times-frac54.4%
unpow254.4%
neg-mul-154.4%
distribute-lft-neg-out54.4%
*-commutative54.4%
Simplified54.4%
div-inv54.4%
Applied egg-rr54.4%
Taylor expanded in n around 0 42.2%
associate-*r*45.4%
cancel-sign-sub-inv45.4%
metadata-eval45.4%
associate-*r/45.4%
*-commutative45.4%
Simplified45.4%
Final simplification49.4%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (or (<= U -8.5e-71) (not (<= U 1.45e+118))) (sqrt (fabs (* 2.0 (* t (* n U))))) (sqrt (fabs (* (* 2.0 n) (* U 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 <= -8.5e-71) || !(U <= 1.45e+118)) {
tmp = sqrt(fabs((2.0 * (t * (n * U)))));
} else {
tmp = sqrt(fabs(((2.0 * n) * (U * 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 <= (-8.5d-71)) .or. (.not. (u <= 1.45d+118))) then
tmp = sqrt(abs((2.0d0 * (t * (n * u)))))
else
tmp = sqrt(abs(((2.0d0 * n) * (u * 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 <= -8.5e-71) || !(U <= 1.45e+118)) {
tmp = Math.sqrt(Math.abs((2.0 * (t * (n * U)))));
} else {
tmp = Math.sqrt(Math.abs(((2.0 * n) * (U * t))));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if (U <= -8.5e-71) or not (U <= 1.45e+118): tmp = math.sqrt(math.fabs((2.0 * (t * (n * U))))) else: tmp = math.sqrt(math.fabs(((2.0 * n) * (U * t)))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if ((U <= -8.5e-71) || !(U <= 1.45e+118)) tmp = sqrt(abs(Float64(2.0 * Float64(t * Float64(n * U))))); else tmp = sqrt(abs(Float64(Float64(2.0 * n) * Float64(U * 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 <= -8.5e-71) || ~((U <= 1.45e+118))) tmp = sqrt(abs((2.0 * (t * (n * U))))); else tmp = sqrt(abs(((2.0 * n) * (U * t)))); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[Or[LessEqual[U, -8.5e-71], N[Not[LessEqual[U, 1.45e+118]], $MachinePrecision]], N[Sqrt[N[Abs[N[(2.0 * N[(t * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision], N[Sqrt[N[Abs[N[(N[(2.0 * n), $MachinePrecision] * N[(U * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;U \leq -8.5 \cdot 10^{-71} \lor \neg \left(U \leq 1.45 \cdot 10^{+118}\right):\\
\;\;\;\;\sqrt{\left|2 \cdot \left(t \cdot \left(n \cdot U\right)\right)\right|}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left|\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right|}\\
\end{array}
\end{array}
if U < -8.49999999999999988e-71 or 1.45000000000000008e118 < U Initial program 68.5%
Simplified60.9%
Taylor expanded in t around inf 40.3%
add-sqr-sqrt40.3%
pow1/240.3%
pow1/243.6%
pow-prod-down35.1%
pow235.1%
associate-*l*35.1%
Applied egg-rr35.1%
unpow1/235.1%
associate-*r*36.2%
*-commutative36.2%
associate-*r*36.1%
unpow236.1%
rem-sqrt-square50.4%
associate-*r*55.6%
Simplified55.6%
if -8.49999999999999988e-71 < U < 1.45000000000000008e118Initial program 44.6%
Simplified54.1%
Taylor expanded in Om around inf 38.6%
Taylor expanded in l around 0 31.5%
associate-*r*31.6%
associate-*r*30.3%
Simplified30.3%
add-sqr-sqrt30.3%
pow1/230.3%
pow1/232.8%
pow-prod-down26.2%
pow226.2%
associate-*l*26.2%
*-commutative26.2%
associate-*r*26.2%
Applied egg-rr26.2%
unpow1/226.2%
unpow226.2%
rem-sqrt-square33.6%
associate-*l*40.4%
Simplified40.4%
Final simplification46.0%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (or (<= U -3.9e-177) (not (<= U 1.6e-95))) (sqrt (fabs (* 2.0 (* t (* n U))))) (sqrt (* (* 2.0 n) (* U 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 <= -3.9e-177) || !(U <= 1.6e-95)) {
tmp = sqrt(fabs((2.0 * (t * (n * U)))));
} else {
tmp = sqrt(((2.0 * n) * (U * 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 <= (-3.9d-177)) .or. (.not. (u <= 1.6d-95))) then
tmp = sqrt(abs((2.0d0 * (t * (n * u)))))
else
tmp = sqrt(((2.0d0 * n) * (u * 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 <= -3.9e-177) || !(U <= 1.6e-95)) {
tmp = Math.sqrt(Math.abs((2.0 * (t * (n * U)))));
} else {
tmp = Math.sqrt(((2.0 * n) * (U * t)));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if (U <= -3.9e-177) or not (U <= 1.6e-95): tmp = math.sqrt(math.fabs((2.0 * (t * (n * U))))) else: tmp = math.sqrt(((2.0 * n) * (U * t))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if ((U <= -3.9e-177) || !(U <= 1.6e-95)) tmp = sqrt(abs(Float64(2.0 * Float64(t * Float64(n * U))))); else tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * 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 <= -3.9e-177) || ~((U <= 1.6e-95))) tmp = sqrt(abs((2.0 * (t * (n * U))))); else tmp = sqrt(((2.0 * n) * (U * t))); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[Or[LessEqual[U, -3.9e-177], N[Not[LessEqual[U, 1.6e-95]], $MachinePrecision]], N[Sqrt[N[Abs[N[(2.0 * N[(t * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;U \leq -3.9 \cdot 10^{-177} \lor \neg \left(U \leq 1.6 \cdot 10^{-95}\right):\\
\;\;\;\;\sqrt{\left|2 \cdot \left(t \cdot \left(n \cdot U\right)\right)\right|}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t\right)}\\
\end{array}
\end{array}
if U < -3.90000000000000014e-177 or 1.5999999999999999e-95 < U Initial program 64.9%
Simplified60.7%
Taylor expanded in t around inf 39.5%
add-sqr-sqrt39.5%
pow1/239.5%
pow1/243.6%
pow-prod-down34.2%
pow234.2%
associate-*l*34.2%
Applied egg-rr34.2%
unpow1/234.2%
associate-*r*34.8%
*-commutative34.8%
associate-*r*34.8%
unpow234.8%
rem-sqrt-square45.5%
associate-*r*50.1%
Simplified50.1%
if -3.90000000000000014e-177 < U < 1.5999999999999999e-95Initial program 30.5%
Simplified48.3%
Taylor expanded in t around inf 35.7%
Final simplification45.3%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (<= l_m 6.8e+193) (sqrt (fabs (* (* 2.0 n) (* U t)))) (* (* l_m (* n (/ (sqrt 2.0) Om))) (sqrt (* U U*)))))
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 <= 6.8e+193) {
tmp = sqrt(fabs(((2.0 * n) * (U * t))));
} else {
tmp = (l_m * (n * (sqrt(2.0) / Om))) * sqrt((U * U_42_));
}
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 <= 6.8d+193) then
tmp = sqrt(abs(((2.0d0 * n) * (u * t))))
else
tmp = (l_m * (n * (sqrt(2.0d0) / om))) * sqrt((u * u_42))
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 <= 6.8e+193) {
tmp = Math.sqrt(Math.abs(((2.0 * n) * (U * t))));
} else {
tmp = (l_m * (n * (Math.sqrt(2.0) / Om))) * Math.sqrt((U * U_42_));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if l_m <= 6.8e+193: tmp = math.sqrt(math.fabs(((2.0 * n) * (U * t)))) else: tmp = (l_m * (n * (math.sqrt(2.0) / Om))) * math.sqrt((U * U_42_)) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (l_m <= 6.8e+193) tmp = sqrt(abs(Float64(Float64(2.0 * n) * Float64(U * t)))); else tmp = Float64(Float64(l_m * Float64(n * Float64(sqrt(2.0) / Om))) * sqrt(Float64(U * U_42_))); 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 <= 6.8e+193) tmp = sqrt(abs(((2.0 * n) * (U * t)))); else tmp = (l_m * (n * (sqrt(2.0) / Om))) * sqrt((U * U_42_)); 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, 6.8e+193], N[Sqrt[N[Abs[N[(N[(2.0 * n), $MachinePrecision] * N[(U * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]], $MachinePrecision], N[(N[(l$95$m * N[(n * N[(N[Sqrt[2.0], $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(U * U$42$), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;l\_m \leq 6.8 \cdot 10^{+193}:\\
\;\;\;\;\sqrt{\left|\left(2 \cdot n\right) \cdot \left(U \cdot t\right)\right|}\\
\mathbf{else}:\\
\;\;\;\;\left(l\_m \cdot \left(n \cdot \frac{\sqrt{2}}{Om}\right)\right) \cdot \sqrt{U \cdot U*}\\
\end{array}
\end{array}
if l < 6.79999999999999972e193Initial program 55.8%
Simplified58.8%
Taylor expanded in Om around inf 45.7%
Taylor expanded in l around 0 39.6%
associate-*r*39.6%
associate-*r*40.3%
Simplified40.3%
add-sqr-sqrt40.3%
pow1/240.3%
pow1/243.4%
pow-prod-down31.0%
pow231.0%
associate-*l*31.0%
*-commutative31.0%
associate-*r*31.0%
Applied egg-rr31.0%
unpow1/231.0%
unpow231.0%
rem-sqrt-square44.2%
associate-*l*44.4%
Simplified44.4%
if 6.79999999999999972e193 < l Initial program 25.8%
Simplified30.8%
Taylor expanded in U* around inf 39.3%
associate-/l*44.0%
Simplified44.0%
associate-/l*44.0%
Applied egg-rr44.0%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (or (<= U -3.5e-164) (not (<= U 2e-47))) (pow (* (* (* 2.0 n) U) t) 0.5) (sqrt (* (* 2.0 n) (* U 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 <= -3.5e-164) || !(U <= 2e-47)) {
tmp = pow((((2.0 * n) * U) * t), 0.5);
} else {
tmp = sqrt(((2.0 * n) * (U * 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 <= (-3.5d-164)) .or. (.not. (u <= 2d-47))) then
tmp = (((2.0d0 * n) * u) * t) ** 0.5d0
else
tmp = sqrt(((2.0d0 * n) * (u * 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 <= -3.5e-164) || !(U <= 2e-47)) {
tmp = Math.pow((((2.0 * n) * U) * t), 0.5);
} else {
tmp = Math.sqrt(((2.0 * n) * (U * t)));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if (U <= -3.5e-164) or not (U <= 2e-47): tmp = math.pow((((2.0 * n) * U) * t), 0.5) else: tmp = math.sqrt(((2.0 * n) * (U * t))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if ((U <= -3.5e-164) || !(U <= 2e-47)) tmp = Float64(Float64(Float64(2.0 * n) * U) * t) ^ 0.5; else tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * 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 <= -3.5e-164) || ~((U <= 2e-47))) tmp = (((2.0 * n) * U) * t) ^ 0.5; else tmp = sqrt(((2.0 * n) * (U * t))); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[Or[LessEqual[U, -3.5e-164], N[Not[LessEqual[U, 2e-47]], $MachinePrecision]], N[Power[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * t), $MachinePrecision], 0.5], $MachinePrecision], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;U \leq -3.5 \cdot 10^{-164} \lor \neg \left(U \leq 2 \cdot 10^{-47}\right):\\
\;\;\;\;{\left(\left(\left(2 \cdot n\right) \cdot U\right) \cdot t\right)}^{0.5}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t\right)}\\
\end{array}
\end{array}
if U < -3.5e-164 or 1.9999999999999999e-47 < U Initial program 67.5%
Simplified62.8%
Taylor expanded in Om around inf 49.4%
Taylor expanded in l around 0 43.9%
associate-*r*43.9%
associate-*r*47.7%
Simplified47.7%
pow1/253.1%
associate-*l*53.1%
*-commutative53.1%
associate-*r*53.1%
Applied egg-rr53.1%
if -3.5e-164 < U < 1.9999999999999999e-47Initial program 33.2%
Simplified47.7%
Taylor expanded in t around inf 32.7%
Final simplification44.7%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (or (<= U -2e+17) (not (<= U 1.32e+118))) (sqrt (* 2.0 (* t (* n U)))) (sqrt (* (* 2.0 n) (* U 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 <= -2e+17) || !(U <= 1.32e+118)) {
tmp = sqrt((2.0 * (t * (n * U))));
} else {
tmp = sqrt(((2.0 * n) * (U * 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 <= (-2d+17)) .or. (.not. (u <= 1.32d+118))) then
tmp = sqrt((2.0d0 * (t * (n * u))))
else
tmp = sqrt(((2.0d0 * n) * (u * 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 <= -2e+17) || !(U <= 1.32e+118)) {
tmp = Math.sqrt((2.0 * (t * (n * U))));
} else {
tmp = Math.sqrt(((2.0 * n) * (U * t)));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if (U <= -2e+17) or not (U <= 1.32e+118): tmp = math.sqrt((2.0 * (t * (n * U)))) else: tmp = math.sqrt(((2.0 * n) * (U * t))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if ((U <= -2e+17) || !(U <= 1.32e+118)) tmp = sqrt(Float64(2.0 * Float64(t * Float64(n * U)))); else tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * 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 <= -2e+17) || ~((U <= 1.32e+118))) tmp = sqrt((2.0 * (t * (n * U)))); else tmp = sqrt(((2.0 * n) * (U * t))); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[Or[LessEqual[U, -2e+17], N[Not[LessEqual[U, 1.32e+118]], $MachinePrecision]], N[Sqrt[N[(2.0 * N[(t * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;U \leq -2 \cdot 10^{+17} \lor \neg \left(U \leq 1.32 \cdot 10^{+118}\right):\\
\;\;\;\;\sqrt{2 \cdot \left(t \cdot \left(n \cdot U\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t\right)}\\
\end{array}
\end{array}
if U < -2e17 or 1.3199999999999999e118 < U Initial program 70.1%
Simplified60.6%
Taylor expanded in t around inf 53.9%
associate-*r*58.8%
Simplified58.8%
if -2e17 < U < 1.3199999999999999e118Initial program 46.3%
Simplified54.9%
Taylor expanded in t around inf 34.7%
Final simplification42.0%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (<= l_m 6e-125) (sqrt (* 2.0 (* t (* n U)))) (pow (* (* 2.0 U) (* n 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 (l_m <= 6e-125) {
tmp = sqrt((2.0 * (t * (n * U))));
} else {
tmp = pow(((2.0 * U) * (n * 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 (l_m <= 6d-125) then
tmp = sqrt((2.0d0 * (t * (n * u))))
else
tmp = ((2.0d0 * u) * (n * 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 (l_m <= 6e-125) {
tmp = Math.sqrt((2.0 * (t * (n * U))));
} else {
tmp = Math.pow(((2.0 * U) * (n * t)), 0.5);
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if l_m <= 6e-125: tmp = math.sqrt((2.0 * (t * (n * U)))) else: tmp = math.pow(((2.0 * U) * (n * t)), 0.5) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (l_m <= 6e-125) tmp = sqrt(Float64(2.0 * Float64(t * Float64(n * U)))); else tmp = Float64(Float64(2.0 * U) * Float64(n * 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 (l_m <= 6e-125) tmp = sqrt((2.0 * (t * (n * U)))); else tmp = ((2.0 * U) * (n * 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[l$95$m, 6e-125], N[Sqrt[N[(2.0 * N[(t * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Power[N[(N[(2.0 * U), $MachinePrecision] * N[(n * t), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;l\_m \leq 6 \cdot 10^{-125}:\\
\;\;\;\;\sqrt{2 \cdot \left(t \cdot \left(n \cdot U\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;{\left(\left(2 \cdot U\right) \cdot \left(n \cdot t\right)\right)}^{0.5}\\
\end{array}
\end{array}
if l < 5.99999999999999981e-125Initial program 57.5%
Simplified58.7%
Taylor expanded in t around inf 41.6%
associate-*r*44.1%
Simplified44.1%
if 5.99999999999999981e-125 < l Initial program 44.6%
Simplified52.0%
Taylor expanded in t around inf 26.9%
pow1/231.9%
associate-*r*32.0%
Applied egg-rr32.0%
Final simplification40.3%
l_m = (fabs.f64 l) (FPCore (n U t l_m Om U*) :precision binary64 (if (<= t -5e-47) (sqrt (* 2.0 (* U (* n t)))) (sqrt (* 2.0 (* t (* n U))))))
l_m = fabs(l);
double code(double n, double U, double t, double l_m, double Om, double U_42_) {
double tmp;
if (t <= -5e-47) {
tmp = sqrt((2.0 * (U * (n * t))));
} else {
tmp = sqrt((2.0 * (t * (n * U))));
}
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 <= (-5d-47)) then
tmp = sqrt((2.0d0 * (u * (n * t))))
else
tmp = sqrt((2.0d0 * (t * (n * u))))
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 <= -5e-47) {
tmp = Math.sqrt((2.0 * (U * (n * t))));
} else {
tmp = Math.sqrt((2.0 * (t * (n * U))));
}
return tmp;
}
l_m = math.fabs(l) def code(n, U, t, l_m, Om, U_42_): tmp = 0 if t <= -5e-47: tmp = math.sqrt((2.0 * (U * (n * t)))) else: tmp = math.sqrt((2.0 * (t * (n * U)))) return tmp
l_m = abs(l) function code(n, U, t, l_m, Om, U_42_) tmp = 0.0 if (t <= -5e-47) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t)))); else tmp = sqrt(Float64(2.0 * Float64(t * Float64(n * U)))); 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 <= -5e-47) tmp = sqrt((2.0 * (U * (n * t)))); else tmp = sqrt((2.0 * (t * (n * U)))); end tmp_2 = tmp; end
l_m = N[Abs[l], $MachinePrecision] code[n_, U_, t_, l$95$m_, Om_, U$42$_] := If[LessEqual[t, -5e-47], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(2.0 * N[(t * N[(n * U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l_m = \left|\ell\right|
\\
\begin{array}{l}
\mathbf{if}\;t \leq -5 \cdot 10^{-47}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot \left(t \cdot \left(n \cdot U\right)\right)}\\
\end{array}
\end{array}
if t < -5.00000000000000011e-47Initial program 54.9%
Simplified59.2%
Taylor expanded in t around inf 54.2%
if -5.00000000000000011e-47 < t Initial program 52.8%
Simplified55.5%
Taylor expanded in t around inf 29.7%
associate-*r*33.4%
Simplified33.4%
Final simplification39.7%
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 53.5%
Simplified56.6%
Taylor expanded in t around inf 37.1%
herbie shell --seed 2024163
(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*))))))