
(FPCore (n U t l Om U*) :precision binary64 (sqrt (* (* (* 2.0 n) U) (- (- t (* 2.0 (/ (* l l) Om))) (* (* n (pow (/ l Om) 2.0)) (- U U*))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
return sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * pow((l / Om), 2.0)) * (U - U_42_)))));
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
code = sqrt((((2.0d0 * n) * u) * ((t - (2.0d0 * ((l * l) / om))) - ((n * ((l / om) ** 2.0d0)) * (u - u_42)))))
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
return Math.sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * Math.pow((l / Om), 2.0)) * (U - U_42_)))));
}
def code(n, U, t, l, Om, U_42_): return math.sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * math.pow((l / Om), 2.0)) * (U - U_42_)))))
function code(n, U, t, l, Om, U_42_) return sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l * l) / Om))) - Float64(Float64(n * (Float64(l / Om) ^ 2.0)) * Float64(U - U_42_))))) end
function tmp = code(n, U, t, l, Om, U_42_) tmp = sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * ((l / Om) ^ 2.0)) * (U - U_42_))))); end
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U - U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
\\
\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)}
\end{array}
Sampling outcomes in binary64 precision:
Herbie found 21 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (n U t l Om U*) :precision binary64 (sqrt (* (* (* 2.0 n) U) (- (- t (* 2.0 (/ (* l l) Om))) (* (* n (pow (/ l Om) 2.0)) (- U U*))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
return sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * pow((l / Om), 2.0)) * (U - U_42_)))));
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
code = sqrt((((2.0d0 * n) * u) * ((t - (2.0d0 * ((l * l) / om))) - ((n * ((l / om) ** 2.0d0)) * (u - u_42)))))
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
return Math.sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * Math.pow((l / Om), 2.0)) * (U - U_42_)))));
}
def code(n, U, t, l, Om, U_42_): return math.sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * math.pow((l / Om), 2.0)) * (U - U_42_)))))
function code(n, U, t, l, Om, U_42_) return sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l * l) / Om))) - Float64(Float64(n * (Float64(l / Om) ^ 2.0)) * Float64(U - U_42_))))) end
function tmp = code(n, U, t, l, Om, U_42_) tmp = sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * ((l / Om) ^ 2.0)) * (U - U_42_))))); end
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U - U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
\\
\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)}
\end{array}
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1
(*
(* (* 2.0 n) U)
(+
(- t (* 2.0 (/ (* l l) Om)))
(* (* n (pow (/ l Om) 2.0)) (- U* U))))))
(if (<= t_1 0.0)
(sqrt
(*
(* 2.0 n)
(* U (+ t (* (/ l Om) (fma l -2.0 (* (/ l Om) (* n (- U* U)))))))))
(if (<= t_1 4e+305)
(sqrt t_1)
(*
(sqrt 2.0)
(* l (sqrt (* (* U (/ n Om)) (+ -2.0 (* (- U* U) (/ n Om)))))))))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = ((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) + ((n * pow((l / Om), 2.0)) * (U_42_ - U)));
double tmp;
if (t_1 <= 0.0) {
tmp = sqrt(((2.0 * n) * (U * (t + ((l / Om) * fma(l, -2.0, ((l / Om) * (n * (U_42_ - U)))))))));
} else if (t_1 <= 4e+305) {
tmp = sqrt(t_1);
} else {
tmp = sqrt(2.0) * (l * sqrt(((U * (n / Om)) * (-2.0 + ((U_42_ - U) * (n / Om))))));
}
return tmp;
}
l = abs(l) function code(n, U, t, l, Om, U_42_) t_1 = Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l * l) / Om))) + Float64(Float64(n * (Float64(l / Om) ^ 2.0)) * Float64(U_42_ - U)))) tmp = 0.0 if (t_1 <= 0.0) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l / Om) * fma(l, -2.0, Float64(Float64(l / Om) * Float64(n * Float64(U_42_ - U))))))))); elseif (t_1 <= 4e+305) tmp = sqrt(t_1); else tmp = Float64(sqrt(2.0) * Float64(l * sqrt(Float64(Float64(U * Float64(n / Om)) * Float64(-2.0 + Float64(Float64(U_42_ - U) * Float64(n / Om))))))); end return tmp end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t$95$1, 0.0], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l / Om), $MachinePrecision] * N[(l * -2.0 + N[(N[(l / Om), $MachinePrecision] * N[(n * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t$95$1, 4e+305], N[Sqrt[t$95$1], $MachinePrecision], N[(N[Sqrt[2.0], $MachinePrecision] * N[(l * N[Sqrt[N[(N[(U * N[(n / Om), $MachinePrecision]), $MachinePrecision] * N[(-2.0 + N[(N[(U$42$ - U), $MachinePrecision] * N[(n / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
t_1 := \left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right)\\
\mathbf{if}\;t_1 \leq 0:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell}{Om} \cdot \mathsf{fma}\left(\ell, -2, \frac{\ell}{Om} \cdot \left(n \cdot \left(U* - U\right)\right)\right)\right)\right)}\\
\mathbf{elif}\;t_1 \leq 4 \cdot 10^{+305}:\\
\;\;\;\;\sqrt{t_1}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2} \cdot \left(\ell \cdot \sqrt{\left(U \cdot \frac{n}{Om}\right) \cdot \left(-2 + \left(U* - U\right) \cdot \frac{n}{Om}\right)}\right)\\
\end{array}
\end{array}
if (*.f64 (*.f64 (*.f64 2 n) U) (-.f64 (-.f64 t (*.f64 2 (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) 2)) (-.f64 U U*)))) < 0.0Initial program 16.1%
Simplified51.9%
if 0.0 < (*.f64 (*.f64 (*.f64 2 n) U) (-.f64 (-.f64 t (*.f64 2 (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) 2)) (-.f64 U U*)))) < 3.9999999999999998e305Initial program 98.4%
if 3.9999999999999998e305 < (*.f64 (*.f64 (*.f64 2 n) U) (-.f64 (-.f64 t (*.f64 2 (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) 2)) (-.f64 U U*)))) Initial program 18.8%
Simplified39.3%
distribute-rgt-in39.3%
Applied egg-rr39.3%
Taylor expanded in l around inf 28.1%
associate-/l*24.9%
*-commutative24.9%
sub-neg24.9%
associate-/l*25.9%
metadata-eval25.9%
Simplified25.9%
add-cbrt-cube22.2%
add-sqr-sqrt22.2%
associate-/r/22.2%
+-commutative22.2%
associate-/r/22.2%
associate-/r/23.9%
+-commutative23.9%
associate-/r/24.7%
Applied egg-rr24.7%
Taylor expanded in l around 0 28.1%
associate-*l*28.0%
*-commutative28.0%
sub-neg28.0%
*-commutative28.0%
associate-*r/28.9%
metadata-eval28.9%
+-commutative28.9%
associate-*l/30.8%
associate-*r*31.6%
Simplified31.6%
Final simplification61.8%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 1.5e+77)
(sqrt
(*
(* 2.0 n)
(* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
(*
(sqrt 2.0)
(* l (sqrt (* (* U (/ n Om)) (+ -2.0 (* (- U* U) (/ n Om)))))))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 1.5e+77) {
tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else {
tmp = sqrt(2.0) * (l * sqrt(((U * (n / Om)) * (-2.0 + ((U_42_ - U) * (n / Om))))));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (l <= 1.5d+77) then
tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
else
tmp = sqrt(2.0d0) * (l * sqrt(((u * (n / om)) * ((-2.0d0) + ((u_42 - u) * (n / om))))))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 1.5e+77) {
tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else {
tmp = Math.sqrt(2.0) * (l * Math.sqrt(((U * (n / Om)) * (-2.0 + ((U_42_ - U) * (n / Om))))));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): tmp = 0 if l <= 1.5e+77: tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))) else: tmp = math.sqrt(2.0) * (l * math.sqrt(((U * (n / Om)) * (-2.0 + ((U_42_ - U) * (n / Om)))))) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 1.5e+77) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om))))); else tmp = Float64(sqrt(2.0) * Float64(l * sqrt(Float64(Float64(U * Float64(n / Om)) * Float64(-2.0 + Float64(Float64(U_42_ - U) * Float64(n / Om))))))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (l <= 1.5e+77) tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))); else tmp = sqrt(2.0) * (l * sqrt(((U * (n / Om)) * (-2.0 + ((U_42_ - U) * (n / Om)))))); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 1.5e+77], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[2.0], $MachinePrecision] * N[(l * N[Sqrt[N[(N[(U * N[(n / Om), $MachinePrecision]), $MachinePrecision] * N[(-2.0 + N[(N[(U$42$ - U), $MachinePrecision] * N[(n / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 1.5 \cdot 10^{+77}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2} \cdot \left(\ell \cdot \sqrt{\left(U \cdot \frac{n}{Om}\right) \cdot \left(-2 + \left(U* - U\right) \cdot \frac{n}{Om}\right)}\right)\\
\end{array}
\end{array}
if l < 1.4999999999999999e77Initial program 56.7%
Simplified62.4%
Taylor expanded in U around 0 64.5%
if 1.4999999999999999e77 < l Initial program 17.2%
Simplified46.2%
distribute-rgt-in46.2%
Applied egg-rr46.2%
Taylor expanded in l around inf 67.7%
associate-/l*58.3%
*-commutative58.3%
sub-neg58.3%
associate-/l*63.2%
metadata-eval63.2%
Simplified63.2%
add-cbrt-cube55.4%
add-sqr-sqrt55.4%
associate-/r/52.9%
+-commutative52.9%
associate-/r/52.9%
associate-/r/57.8%
+-commutative57.8%
associate-/r/57.8%
Applied egg-rr57.8%
Taylor expanded in l around 0 67.7%
associate-*l*67.6%
*-commutative67.6%
sub-neg67.6%
*-commutative67.6%
associate-*r/70.0%
metadata-eval70.0%
+-commutative70.0%
associate-*l/70.6%
associate-*r*72.9%
Simplified72.9%
Final simplification65.8%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 4e+87)
(sqrt
(*
(* 2.0 n)
(* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
(* (* l (sqrt 2.0)) (sqrt (/ n (/ Om (* U (- (/ (* n U*) Om) 2.0))))))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 4e+87) {
tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else {
tmp = (l * sqrt(2.0)) * sqrt((n / (Om / (U * (((n * U_42_) / Om) - 2.0)))));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (l <= 4d+87) then
tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
else
tmp = (l * sqrt(2.0d0)) * sqrt((n / (om / (u * (((n * u_42) / om) - 2.0d0)))))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 4e+87) {
tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else {
tmp = (l * Math.sqrt(2.0)) * Math.sqrt((n / (Om / (U * (((n * U_42_) / Om) - 2.0)))));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): tmp = 0 if l <= 4e+87: tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))) else: tmp = (l * math.sqrt(2.0)) * math.sqrt((n / (Om / (U * (((n * U_42_) / Om) - 2.0))))) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 4e+87) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om))))); else tmp = Float64(Float64(l * sqrt(2.0)) * sqrt(Float64(n / Float64(Om / Float64(U * Float64(Float64(Float64(n * U_42_) / Om) - 2.0)))))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (l <= 4e+87) tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))); else tmp = (l * sqrt(2.0)) * sqrt((n / (Om / (U * (((n * U_42_) / Om) - 2.0))))); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 4e+87], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(n / N[(Om / N[(U * N[(N[(N[(n * U$42$), $MachinePrecision] / Om), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 4 \cdot 10^{+87}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt{\frac{n}{\frac{Om}{U \cdot \left(\frac{n \cdot U*}{Om} - 2\right)}}}\\
\end{array}
\end{array}
if l < 3.9999999999999998e87Initial program 56.7%
Simplified62.8%
Taylor expanded in U around 0 64.8%
if 3.9999999999999998e87 < l Initial program 15.3%
Simplified43.2%
distribute-rgt-in43.2%
Applied egg-rr43.2%
Taylor expanded in l around inf 68.5%
associate-/l*58.6%
*-commutative58.6%
sub-neg58.6%
associate-/l*63.8%
metadata-eval63.8%
Simplified63.8%
Taylor expanded in U around 0 58.6%
Final simplification63.9%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 3.6e+79)
(sqrt
(*
(* 2.0 n)
(* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
(* (* l (sqrt 2.0)) (sqrt (/ (* n (* U (- (/ (* n U*) Om) 2.0))) Om)))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 3.6e+79) {
tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else {
tmp = (l * sqrt(2.0)) * sqrt(((n * (U * (((n * U_42_) / Om) - 2.0))) / Om));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (l <= 3.6d+79) then
tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
else
tmp = (l * sqrt(2.0d0)) * sqrt(((n * (u * (((n * u_42) / om) - 2.0d0))) / om))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 3.6e+79) {
tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else {
tmp = (l * Math.sqrt(2.0)) * Math.sqrt(((n * (U * (((n * U_42_) / Om) - 2.0))) / Om));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): tmp = 0 if l <= 3.6e+79: tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))) else: tmp = (l * math.sqrt(2.0)) * math.sqrt(((n * (U * (((n * U_42_) / Om) - 2.0))) / Om)) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 3.6e+79) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om))))); else tmp = Float64(Float64(l * sqrt(2.0)) * sqrt(Float64(Float64(n * Float64(U * Float64(Float64(Float64(n * U_42_) / Om) - 2.0))) / Om))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (l <= 3.6e+79) tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))); else tmp = (l * sqrt(2.0)) * sqrt(((n * (U * (((n * U_42_) / Om) - 2.0))) / Om)); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 3.6e+79], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(N[(n * N[(U * N[(N[(N[(n * U$42$), $MachinePrecision] / Om), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 3.6 \cdot 10^{+79}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt{\frac{n \cdot \left(U \cdot \left(\frac{n \cdot U*}{Om} - 2\right)\right)}{Om}}\\
\end{array}
\end{array}
if l < 3.5999999999999999e79Initial program 56.7%
Simplified62.4%
Taylor expanded in U around 0 64.5%
if 3.5999999999999999e79 < l Initial program 17.2%
Simplified46.2%
distribute-rgt-in46.2%
Applied egg-rr46.2%
Taylor expanded in U around 0 46.2%
Taylor expanded in l around inf 67.7%
Final simplification65.0%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 9e+69)
(sqrt
(*
(* 2.0 n)
(* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
(if (<= l 2.2e+202)
(sqrt
(+
(* 2.0 (* n (* U t)))
(*
2.0
(/
(* (+ (* l -2.0) (* (* n l) (* (- U U*) (/ -1.0 Om)))) (* n (* U l)))
Om))))
(if (<= l 2.05e+264)
(* (* l (sqrt 2.0)) (sqrt (* -2.0 (/ (* n U) Om))))
(sqrt
(*
-2.0
(/ n (/ Om (* (- 2.0 (/ n (/ Om (- U* U)))) (* l (* U l)))))))))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 9e+69) {
tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else if (l <= 2.2e+202) {
tmp = sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om))));
} else if (l <= 2.05e+264) {
tmp = (l * sqrt(2.0)) * sqrt((-2.0 * ((n * U) / Om)));
} else {
tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (l <= 9d+69) then
tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
else if (l <= 2.2d+202) then
tmp = sqrt(((2.0d0 * (n * (u * t))) + (2.0d0 * ((((l * (-2.0d0)) + ((n * l) * ((u - u_42) * ((-1.0d0) / om)))) * (n * (u * l))) / om))))
else if (l <= 2.05d+264) then
tmp = (l * sqrt(2.0d0)) * sqrt(((-2.0d0) * ((n * u) / om)))
else
tmp = sqrt(((-2.0d0) * (n / (om / ((2.0d0 - (n / (om / (u_42 - u)))) * (l * (u * l)))))))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 9e+69) {
tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else if (l <= 2.2e+202) {
tmp = Math.sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om))));
} else if (l <= 2.05e+264) {
tmp = (l * Math.sqrt(2.0)) * Math.sqrt((-2.0 * ((n * U) / Om)));
} else {
tmp = Math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): tmp = 0 if l <= 9e+69: tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))) elif l <= 2.2e+202: tmp = math.sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om)))) elif l <= 2.05e+264: tmp = (l * math.sqrt(2.0)) * math.sqrt((-2.0 * ((n * U) / Om))) else: tmp = math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l))))))) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 9e+69) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om))))); elseif (l <= 2.2e+202) tmp = sqrt(Float64(Float64(2.0 * Float64(n * Float64(U * t))) + Float64(2.0 * Float64(Float64(Float64(Float64(l * -2.0) + Float64(Float64(n * l) * Float64(Float64(U - U_42_) * Float64(-1.0 / Om)))) * Float64(n * Float64(U * l))) / Om)))); elseif (l <= 2.05e+264) tmp = Float64(Float64(l * sqrt(2.0)) * sqrt(Float64(-2.0 * Float64(Float64(n * U) / Om)))); else tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(Float64(2.0 - Float64(n / Float64(Om / Float64(U_42_ - U)))) * Float64(l * Float64(U * l))))))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (l <= 9e+69) tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))); elseif (l <= 2.2e+202) tmp = sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om)))); elseif (l <= 2.05e+264) tmp = (l * sqrt(2.0)) * sqrt((-2.0 * ((n * U) / Om))); else tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l))))))); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 9e+69], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 2.2e+202], N[Sqrt[N[(N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(2.0 * N[(N[(N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * l), $MachinePrecision] * N[(N[(U - U$42$), $MachinePrecision] * N[(-1.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(n * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 2.05e+264], N[(N[(l * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] * N[Sqrt[N[(-2.0 * N[(N[(n * U), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(N[(2.0 - N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 9 \cdot 10^{+69}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\
\mathbf{elif}\;\ell \leq 2.2 \cdot 10^{+202}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right) + 2 \cdot \frac{\left(\ell \cdot -2 + \left(n \cdot \ell\right) \cdot \left(\left(U - U*\right) \cdot \frac{-1}{Om}\right)\right) \cdot \left(n \cdot \left(U \cdot \ell\right)\right)}{Om}}\\
\mathbf{elif}\;\ell \leq 2.05 \cdot 10^{+264}:\\
\;\;\;\;\left(\ell \cdot \sqrt{2}\right) \cdot \sqrt{-2 \cdot \frac{n \cdot U}{Om}}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\left(2 - \frac{n}{\frac{Om}{U* - U}}\right) \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)}}}\\
\end{array}
\end{array}
if l < 8.9999999999999999e69Initial program 56.5%
Simplified62.3%
Taylor expanded in U around 0 64.3%
if 8.9999999999999999e69 < l < 2.19999999999999978e202Initial program 33.2%
Simplified59.6%
Taylor expanded in t around inf 59.6%
div-inv59.6%
associate-*r*59.7%
Applied egg-rr59.7%
associate-*l*64.8%
Simplified64.8%
if 2.19999999999999978e202 < l < 2.05e264Initial program 10.9%
Simplified30.7%
distribute-rgt-in30.7%
Applied egg-rr30.7%
Taylor expanded in l around inf 82.4%
associate-/l*73.5%
*-commutative73.5%
sub-neg73.5%
associate-/l*73.5%
metadata-eval73.5%
Simplified73.5%
Taylor expanded in n around 0 62.4%
if 2.05e264 < l Initial program 1.9%
Simplified42.9%
distribute-rgt-in42.9%
Applied egg-rr42.9%
Taylor expanded in l around -inf 42.9%
associate-/l*42.9%
associate-*r*42.9%
*-commutative42.9%
associate-*r*42.9%
*-commutative42.9%
*-commutative42.9%
unpow242.9%
mul-1-neg42.9%
unsub-neg42.9%
associate-/l*42.9%
Simplified42.9%
Taylor expanded in U around 0 42.9%
*-commutative42.9%
unpow242.9%
associate-*l*52.5%
*-commutative52.5%
*-commutative52.5%
Simplified52.5%
Final simplification63.8%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 1.6e+67)
(sqrt
(*
(* 2.0 n)
(* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
(sqrt
(+
(* 2.0 (* n (* U t)))
(*
2.0
(/
(* (+ (* l -2.0) (* (* n l) (* (- U U*) (/ -1.0 Om)))) (* n (* U l)))
Om))))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 1.6e+67) {
tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else {
tmp = sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om))));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (l <= 1.6d+67) then
tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
else
tmp = sqrt(((2.0d0 * (n * (u * t))) + (2.0d0 * ((((l * (-2.0d0)) + ((n * l) * ((u - u_42) * ((-1.0d0) / om)))) * (n * (u * l))) / om))))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 1.6e+67) {
tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else {
tmp = Math.sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om))));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): tmp = 0 if l <= 1.6e+67: tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))) else: tmp = math.sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om)))) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 1.6e+67) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om))))); else tmp = sqrt(Float64(Float64(2.0 * Float64(n * Float64(U * t))) + Float64(2.0 * Float64(Float64(Float64(Float64(l * -2.0) + Float64(Float64(n * l) * Float64(Float64(U - U_42_) * Float64(-1.0 / Om)))) * Float64(n * Float64(U * l))) / Om)))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (l <= 1.6e+67) tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))); else tmp = sqrt(((2.0 * (n * (U * t))) + (2.0 * ((((l * -2.0) + ((n * l) * ((U - U_42_) * (-1.0 / Om)))) * (n * (U * l))) / Om)))); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 1.6e+67], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(2.0 * N[(N[(N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * l), $MachinePrecision] * N[(N[(U - U$42$), $MachinePrecision] * N[(-1.0 / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(n * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 1.6 \cdot 10^{+67}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right) + 2 \cdot \frac{\left(\ell \cdot -2 + \left(n \cdot \ell\right) \cdot \left(\left(U - U*\right) \cdot \frac{-1}{Om}\right)\right) \cdot \left(n \cdot \left(U \cdot \ell\right)\right)}{Om}}\\
\end{array}
\end{array}
if l < 1.59999999999999991e67Initial program 56.5%
Simplified62.3%
Taylor expanded in U around 0 64.3%
if 1.59999999999999991e67 < l Initial program 19.3%
Simplified47.5%
Taylor expanded in t around inf 52.1%
div-inv52.1%
associate-*r*54.7%
Applied egg-rr54.7%
associate-*l*57.2%
Simplified57.2%
Final simplification63.2%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 6.5e+68)
(sqrt
(*
(* 2.0 n)
(* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
(pow
(*
2.0
(+
(* n (* U t))
(/ (+ (* l -2.0) (/ (* (- U* U) (* n l)) Om)) (/ Om (* n (* U l))))))
0.5)))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 6.5e+68) {
tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else {
tmp = pow((2.0 * ((n * (U * t)) + (((l * -2.0) + (((U_42_ - U) * (n * l)) / Om)) / (Om / (n * (U * l)))))), 0.5);
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (l <= 6.5d+68) then
tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
else
tmp = (2.0d0 * ((n * (u * t)) + (((l * (-2.0d0)) + (((u_42 - u) * (n * l)) / om)) / (om / (n * (u * l)))))) ** 0.5d0
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 6.5e+68) {
tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else {
tmp = Math.pow((2.0 * ((n * (U * t)) + (((l * -2.0) + (((U_42_ - U) * (n * l)) / Om)) / (Om / (n * (U * l)))))), 0.5);
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): tmp = 0 if l <= 6.5e+68: tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))) else: tmp = math.pow((2.0 * ((n * (U * t)) + (((l * -2.0) + (((U_42_ - U) * (n * l)) / Om)) / (Om / (n * (U * l)))))), 0.5) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 6.5e+68) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om))))); else tmp = Float64(2.0 * Float64(Float64(n * Float64(U * t)) + Float64(Float64(Float64(l * -2.0) + Float64(Float64(Float64(U_42_ - U) * Float64(n * l)) / Om)) / Float64(Om / Float64(n * Float64(U * l)))))) ^ 0.5; end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (l <= 6.5e+68) tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))); else tmp = (2.0 * ((n * (U * t)) + (((l * -2.0) + (((U_42_ - U) * (n * l)) / Om)) / (Om / (n * (U * l)))))) ^ 0.5; end tmp_2 = tmp; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 6.5e+68], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Power[N[(2.0 * N[(N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision] + N[(N[(N[(l * -2.0), $MachinePrecision] + N[(N[(N[(U$42$ - U), $MachinePrecision] * N[(n * l), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] / N[(Om / N[(n * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 6.5 \cdot 10^{+68}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;{\left(2 \cdot \left(n \cdot \left(U \cdot t\right) + \frac{\ell \cdot -2 + \frac{\left(U* - U\right) \cdot \left(n \cdot \ell\right)}{Om}}{\frac{Om}{n \cdot \left(U \cdot \ell\right)}}\right)\right)}^{0.5}\\
\end{array}
\end{array}
if l < 6.5000000000000005e68Initial program 56.5%
Simplified62.3%
Taylor expanded in U around 0 64.3%
if 6.5000000000000005e68 < l Initial program 19.3%
Simplified47.5%
Taylor expanded in t around inf 52.1%
pow1/252.5%
distribute-lft-out52.5%
associate-/l*52.5%
associate-*r*50.2%
*-commutative50.2%
*-commutative50.2%
Applied egg-rr50.2%
Final simplification62.1%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1 (+ (* l -2.0) (/ (* n (* l U*)) Om))))
(if (<= l 1.06e+76)
(sqrt (* (* 2.0 n) (* U (+ t (/ (* l t_1) Om)))))
(sqrt (+ (* 2.0 (* n (* U t))) (* 2.0 (/ (* t_1 (* n (* U l))) Om)))))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = (l * -2.0) + ((n * (l * U_42_)) / Om);
double tmp;
if (l <= 1.06e+76) {
tmp = sqrt(((2.0 * n) * (U * (t + ((l * t_1) / Om)))));
} else {
tmp = sqrt(((2.0 * (n * (U * t))) + (2.0 * ((t_1 * (n * (U * l))) / Om))));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: t_1
real(8) :: tmp
t_1 = (l * (-2.0d0)) + ((n * (l * u_42)) / om)
if (l <= 1.06d+76) then
tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * t_1) / om)))))
else
tmp = sqrt(((2.0d0 * (n * (u * t))) + (2.0d0 * ((t_1 * (n * (u * l))) / om))))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = (l * -2.0) + ((n * (l * U_42_)) / Om);
double tmp;
if (l <= 1.06e+76) {
tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * t_1) / Om)))));
} else {
tmp = Math.sqrt(((2.0 * (n * (U * t))) + (2.0 * ((t_1 * (n * (U * l))) / Om))));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): t_1 = (l * -2.0) + ((n * (l * U_42_)) / Om) tmp = 0 if l <= 1.06e+76: tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * t_1) / Om))))) else: tmp = math.sqrt(((2.0 * (n * (U * t))) + (2.0 * ((t_1 * (n * (U * l))) / Om)))) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) t_1 = Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om)) tmp = 0.0 if (l <= 1.06e+76) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * t_1) / Om))))); else tmp = sqrt(Float64(Float64(2.0 * Float64(n * Float64(U * t))) + Float64(2.0 * Float64(Float64(t_1 * Float64(n * Float64(U * l))) / Om)))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) t_1 = (l * -2.0) + ((n * (l * U_42_)) / Om); tmp = 0.0; if (l <= 1.06e+76) tmp = sqrt(((2.0 * n) * (U * (t + ((l * t_1) / Om))))); else tmp = sqrt(((2.0 * (n * (U * t))) + (2.0 * ((t_1 * (n * (U * l))) / Om)))); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[l, 1.06e+76], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * t$95$1), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(2.0 * N[(N[(t$95$1 * N[(n * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
t_1 := \ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\\
\mathbf{if}\;\ell \leq 1.06 \cdot 10^{+76}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot t_1}{Om}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t\right)\right) + 2 \cdot \frac{t_1 \cdot \left(n \cdot \left(U \cdot \ell\right)\right)}{Om}}\\
\end{array}
\end{array}
if l < 1.06e76Initial program 56.5%
Simplified62.3%
Taylor expanded in U around 0 64.3%
if 1.06e76 < l Initial program 19.3%
Simplified47.5%
Taylor expanded in t around inf 52.1%
Taylor expanded in U* around inf 52.3%
Final simplification62.4%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 3e-150)
(sqrt (* 2.0 (* U (* n t))))
(if (<= l 8.2e+68)
(sqrt (* (* (* 2.0 n) U) (+ t (* -2.0 (* l (/ l Om))))))
(if (<= l 5e+140)
(sqrt
(*
-2.0
(* (* n (* U (* l l))) (+ (/ 2.0 Om) (/ n (/ (* Om Om) (- U U*)))))))
(sqrt
(*
-2.0
(/ n (/ Om (* (- 2.0 (/ n (/ Om (- U* U)))) (* l (* U l)))))))))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 3e-150) {
tmp = sqrt((2.0 * (U * (n * t))));
} else if (l <= 8.2e+68) {
tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
} else if (l <= 5e+140) {
tmp = sqrt((-2.0 * ((n * (U * (l * l))) * ((2.0 / Om) + (n / ((Om * Om) / (U - U_42_)))))));
} else {
tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (l <= 3d-150) then
tmp = sqrt((2.0d0 * (u * (n * t))))
else if (l <= 8.2d+68) then
tmp = sqrt((((2.0d0 * n) * u) * (t + ((-2.0d0) * (l * (l / om))))))
else if (l <= 5d+140) then
tmp = sqrt(((-2.0d0) * ((n * (u * (l * l))) * ((2.0d0 / om) + (n / ((om * om) / (u - u_42)))))))
else
tmp = sqrt(((-2.0d0) * (n / (om / ((2.0d0 - (n / (om / (u_42 - u)))) * (l * (u * l)))))))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 3e-150) {
tmp = Math.sqrt((2.0 * (U * (n * t))));
} else if (l <= 8.2e+68) {
tmp = Math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
} else if (l <= 5e+140) {
tmp = Math.sqrt((-2.0 * ((n * (U * (l * l))) * ((2.0 / Om) + (n / ((Om * Om) / (U - U_42_)))))));
} else {
tmp = Math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): tmp = 0 if l <= 3e-150: tmp = math.sqrt((2.0 * (U * (n * t)))) elif l <= 8.2e+68: tmp = math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om)))))) elif l <= 5e+140: tmp = math.sqrt((-2.0 * ((n * (U * (l * l))) * ((2.0 / Om) + (n / ((Om * Om) / (U - U_42_))))))) else: tmp = math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l))))))) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 3e-150) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t)))); elseif (l <= 8.2e+68) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om)))))); elseif (l <= 5e+140) tmp = sqrt(Float64(-2.0 * Float64(Float64(n * Float64(U * Float64(l * l))) * Float64(Float64(2.0 / Om) + Float64(n / Float64(Float64(Om * Om) / Float64(U - U_42_))))))); else tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(Float64(2.0 - Float64(n / Float64(Om / Float64(U_42_ - U)))) * Float64(l * Float64(U * l))))))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (l <= 3e-150) tmp = sqrt((2.0 * (U * (n * t)))); elseif (l <= 8.2e+68) tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om)))))); elseif (l <= 5e+140) tmp = sqrt((-2.0 * ((n * (U * (l * l))) * ((2.0 / Om) + (n / ((Om * Om) / (U - U_42_))))))); else tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l))))))); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 3e-150], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 8.2e+68], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 5e+140], N[Sqrt[N[(-2.0 * N[(N[(n * N[(U * N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(N[(2.0 / Om), $MachinePrecision] + N[(n / N[(N[(Om * Om), $MachinePrecision] / N[(U - U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(N[(2.0 - N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 3 \cdot 10^{-150}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\
\mathbf{elif}\;\ell \leq 8.2 \cdot 10^{+68}:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\
\mathbf{elif}\;\ell \leq 5 \cdot 10^{+140}:\\
\;\;\;\;\sqrt{-2 \cdot \left(\left(n \cdot \left(U \cdot \left(\ell \cdot \ell\right)\right)\right) \cdot \left(\frac{2}{Om} + \frac{n}{\frac{Om \cdot Om}{U - U*}}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\left(2 - \frac{n}{\frac{Om}{U* - U}}\right) \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)}}}\\
\end{array}
\end{array}
if l < 3.0000000000000002e-150Initial program 54.5%
Simplified61.0%
distribute-rgt-in61.0%
Applied egg-rr61.0%
Taylor expanded in t around inf 44.9%
associate-*r*46.0%
Simplified46.0%
if 3.0000000000000002e-150 < l < 8.1999999999999998e68Initial program 66.4%
Taylor expanded in Om around inf 61.0%
unpow261.0%
associate-*r/61.0%
Simplified61.0%
if 8.1999999999999998e68 < l < 5.00000000000000008e140Initial program 56.5%
Taylor expanded in l around inf 55.5%
*-commutative55.5%
*-commutative55.5%
unpow255.5%
+-commutative55.5%
associate-*r/55.5%
metadata-eval55.5%
associate-/l*64.7%
unpow264.7%
Simplified64.7%
if 5.00000000000000008e140 < l Initial program 5.1%
Simplified40.8%
distribute-rgt-in40.8%
Applied egg-rr40.8%
Taylor expanded in l around -inf 27.8%
associate-/l*27.8%
associate-*r*27.8%
*-commutative27.8%
associate-*r*27.8%
*-commutative27.8%
*-commutative27.8%
unpow227.8%
mul-1-neg27.8%
unsub-neg27.8%
associate-/l*27.8%
Simplified27.8%
Taylor expanded in U around 0 27.8%
*-commutative27.8%
unpow227.8%
associate-*l*41.3%
*-commutative41.3%
*-commutative41.3%
Simplified41.3%
Final simplification48.4%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 3.4e-149)
(sqrt (* 2.0 (* U (* n t))))
(if (<= l 0.48)
(sqrt (* (* (* 2.0 n) U) (+ t (* -2.0 (* l (/ l Om))))))
(if (<= l 4.1e+96)
(sqrt (* (* 2.0 n) (+ (* U t) (* -2.0 (/ (* l l) (/ Om U))))))
(sqrt
(*
-2.0
(/ n (/ Om (* (- 2.0 (/ n (/ Om (- U* U)))) (* U (* l l)))))))))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 3.4e-149) {
tmp = sqrt((2.0 * (U * (n * t))));
} else if (l <= 0.48) {
tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
} else if (l <= 4.1e+96) {
tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
} else {
tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (U * (l * l)))))));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (l <= 3.4d-149) then
tmp = sqrt((2.0d0 * (u * (n * t))))
else if (l <= 0.48d0) then
tmp = sqrt((((2.0d0 * n) * u) * (t + ((-2.0d0) * (l * (l / om))))))
else if (l <= 4.1d+96) then
tmp = sqrt(((2.0d0 * n) * ((u * t) + ((-2.0d0) * ((l * l) / (om / u))))))
else
tmp = sqrt(((-2.0d0) * (n / (om / ((2.0d0 - (n / (om / (u_42 - u)))) * (u * (l * l)))))))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 3.4e-149) {
tmp = Math.sqrt((2.0 * (U * (n * t))));
} else if (l <= 0.48) {
tmp = Math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
} else if (l <= 4.1e+96) {
tmp = Math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
} else {
tmp = Math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (U * (l * l)))))));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): tmp = 0 if l <= 3.4e-149: tmp = math.sqrt((2.0 * (U * (n * t)))) elif l <= 0.48: tmp = math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om)))))) elif l <= 4.1e+96: tmp = math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U)))))) else: tmp = math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (U * (l * l))))))) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 3.4e-149) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t)))); elseif (l <= 0.48) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om)))))); elseif (l <= 4.1e+96) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(Float64(U * t) + Float64(-2.0 * Float64(Float64(l * l) / Float64(Om / U)))))); else tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(Float64(2.0 - Float64(n / Float64(Om / Float64(U_42_ - U)))) * Float64(U * Float64(l * l))))))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (l <= 3.4e-149) tmp = sqrt((2.0 * (U * (n * t)))); elseif (l <= 0.48) tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om)))))); elseif (l <= 4.1e+96) tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U)))))); else tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (U * (l * l))))))); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 3.4e-149], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 0.48], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 4.1e+96], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(N[(U * t), $MachinePrecision] + N[(-2.0 * N[(N[(l * l), $MachinePrecision] / N[(Om / U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(N[(2.0 - N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(U * N[(l * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 3.4 \cdot 10^{-149}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\
\mathbf{elif}\;\ell \leq 0.48:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\
\mathbf{elif}\;\ell \leq 4.1 \cdot 10^{+96}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + -2 \cdot \frac{\ell \cdot \ell}{\frac{Om}{U}}\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\left(2 - \frac{n}{\frac{Om}{U* - U}}\right) \cdot \left(U \cdot \left(\ell \cdot \ell\right)\right)}}}\\
\end{array}
\end{array}
if l < 3.3999999999999999e-149Initial program 54.5%
Simplified61.0%
distribute-rgt-in61.0%
Applied egg-rr61.0%
Taylor expanded in t around inf 44.9%
associate-*r*46.0%
Simplified46.0%
if 3.3999999999999999e-149 < l < 0.47999999999999998Initial program 64.0%
Taylor expanded in Om around inf 60.2%
unpow260.2%
associate-*r/60.2%
Simplified60.2%
if 0.47999999999999998 < l < 4.09999999999999998e96Initial program 69.3%
Simplified80.4%
distribute-rgt-in80.4%
Applied egg-rr80.4%
Taylor expanded in Om around inf 54.6%
associate-/l*69.2%
unpow269.2%
Simplified69.2%
if 4.09999999999999998e96 < l Initial program 13.1%
Simplified42.7%
distribute-rgt-in42.7%
Applied egg-rr42.7%
Taylor expanded in l around -inf 37.4%
associate-/l*34.7%
associate-*r*34.7%
*-commutative34.7%
associate-*r*34.7%
*-commutative34.7%
*-commutative34.7%
unpow234.7%
mul-1-neg34.7%
unsub-neg34.7%
associate-/l*37.4%
Simplified37.4%
Final simplification47.6%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 6.5e-149)
(sqrt (* 2.0 (* U (* n t))))
(if (<= l 1250.0)
(sqrt (* (* (* 2.0 n) U) (+ t (* -2.0 (* l (/ l Om))))))
(if (<= l 3.45e+96)
(sqrt (* (* 2.0 n) (+ (* U t) (* -2.0 (/ (* l l) (/ Om U))))))
(sqrt
(*
-2.0
(/ n (/ Om (* (- 2.0 (/ n (/ Om (- U* U)))) (* l (* U l)))))))))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 6.5e-149) {
tmp = sqrt((2.0 * (U * (n * t))));
} else if (l <= 1250.0) {
tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
} else if (l <= 3.45e+96) {
tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
} else {
tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (l <= 6.5d-149) then
tmp = sqrt((2.0d0 * (u * (n * t))))
else if (l <= 1250.0d0) then
tmp = sqrt((((2.0d0 * n) * u) * (t + ((-2.0d0) * (l * (l / om))))))
else if (l <= 3.45d+96) then
tmp = sqrt(((2.0d0 * n) * ((u * t) + ((-2.0d0) * ((l * l) / (om / u))))))
else
tmp = sqrt(((-2.0d0) * (n / (om / ((2.0d0 - (n / (om / (u_42 - u)))) * (l * (u * l)))))))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 6.5e-149) {
tmp = Math.sqrt((2.0 * (U * (n * t))));
} else if (l <= 1250.0) {
tmp = Math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
} else if (l <= 3.45e+96) {
tmp = Math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
} else {
tmp = Math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): tmp = 0 if l <= 6.5e-149: tmp = math.sqrt((2.0 * (U * (n * t)))) elif l <= 1250.0: tmp = math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om)))))) elif l <= 3.45e+96: tmp = math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U)))))) else: tmp = math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l))))))) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 6.5e-149) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t)))); elseif (l <= 1250.0) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om)))))); elseif (l <= 3.45e+96) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(Float64(U * t) + Float64(-2.0 * Float64(Float64(l * l) / Float64(Om / U)))))); else tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(Float64(2.0 - Float64(n / Float64(Om / Float64(U_42_ - U)))) * Float64(l * Float64(U * l))))))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (l <= 6.5e-149) tmp = sqrt((2.0 * (U * (n * t)))); elseif (l <= 1250.0) tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om)))))); elseif (l <= 3.45e+96) tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U)))))); else tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l))))))); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 6.5e-149], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 1250.0], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 3.45e+96], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(N[(U * t), $MachinePrecision] + N[(-2.0 * N[(N[(l * l), $MachinePrecision] / N[(Om / U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(N[(2.0 - N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 6.5 \cdot 10^{-149}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\
\mathbf{elif}\;\ell \leq 1250:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\
\mathbf{elif}\;\ell \leq 3.45 \cdot 10^{+96}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + -2 \cdot \frac{\ell \cdot \ell}{\frac{Om}{U}}\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\left(2 - \frac{n}{\frac{Om}{U* - U}}\right) \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)}}}\\
\end{array}
\end{array}
if l < 6.50000000000000019e-149Initial program 54.5%
Simplified61.0%
distribute-rgt-in61.0%
Applied egg-rr61.0%
Taylor expanded in t around inf 44.9%
associate-*r*46.0%
Simplified46.0%
if 6.50000000000000019e-149 < l < 1250Initial program 64.0%
Taylor expanded in Om around inf 60.2%
unpow260.2%
associate-*r/60.2%
Simplified60.2%
if 1250 < l < 3.44999999999999999e96Initial program 69.3%
Simplified80.4%
distribute-rgt-in80.4%
Applied egg-rr80.4%
Taylor expanded in Om around inf 54.6%
associate-/l*69.2%
unpow269.2%
Simplified69.2%
if 3.44999999999999999e96 < l Initial program 13.1%
Simplified42.7%
distribute-rgt-in42.7%
Applied egg-rr42.7%
Taylor expanded in l around -inf 37.4%
associate-/l*34.7%
associate-*r*34.7%
*-commutative34.7%
associate-*r*34.7%
*-commutative34.7%
*-commutative34.7%
unpow234.7%
mul-1-neg34.7%
unsub-neg34.7%
associate-/l*37.4%
Simplified37.4%
Taylor expanded in U around 0 37.4%
*-commutative37.4%
unpow237.4%
associate-*l*48.5%
*-commutative48.5%
*-commutative48.5%
Simplified48.5%
Final simplification49.2%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1 (- 2.0 (/ n (/ Om (- U* U))))))
(if (<= l 1.25e-149)
(sqrt (* 2.0 (* U (* n t))))
(if (<= l 2.3e+69)
(sqrt (* (* (* 2.0 n) U) (+ t (* -2.0 (* l (/ l Om))))))
(if (<= l 3.5e+141)
(sqrt (/ (* -2.0 (* (* n (* l l)) (* U t_1))) Om))
(sqrt (* -2.0 (/ n (/ Om (* t_1 (* l (* U l))))))))))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = 2.0 - (n / (Om / (U_42_ - U)));
double tmp;
if (l <= 1.25e-149) {
tmp = sqrt((2.0 * (U * (n * t))));
} else if (l <= 2.3e+69) {
tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
} else if (l <= 3.5e+141) {
tmp = sqrt(((-2.0 * ((n * (l * l)) * (U * t_1))) / Om));
} else {
tmp = sqrt((-2.0 * (n / (Om / (t_1 * (l * (U * l)))))));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: t_1
real(8) :: tmp
t_1 = 2.0d0 - (n / (om / (u_42 - u)))
if (l <= 1.25d-149) then
tmp = sqrt((2.0d0 * (u * (n * t))))
else if (l <= 2.3d+69) then
tmp = sqrt((((2.0d0 * n) * u) * (t + ((-2.0d0) * (l * (l / om))))))
else if (l <= 3.5d+141) then
tmp = sqrt((((-2.0d0) * ((n * (l * l)) * (u * t_1))) / om))
else
tmp = sqrt(((-2.0d0) * (n / (om / (t_1 * (l * (u * l)))))))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = 2.0 - (n / (Om / (U_42_ - U)));
double tmp;
if (l <= 1.25e-149) {
tmp = Math.sqrt((2.0 * (U * (n * t))));
} else if (l <= 2.3e+69) {
tmp = Math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
} else if (l <= 3.5e+141) {
tmp = Math.sqrt(((-2.0 * ((n * (l * l)) * (U * t_1))) / Om));
} else {
tmp = Math.sqrt((-2.0 * (n / (Om / (t_1 * (l * (U * l)))))));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): t_1 = 2.0 - (n / (Om / (U_42_ - U))) tmp = 0 if l <= 1.25e-149: tmp = math.sqrt((2.0 * (U * (n * t)))) elif l <= 2.3e+69: tmp = math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om)))))) elif l <= 3.5e+141: tmp = math.sqrt(((-2.0 * ((n * (l * l)) * (U * t_1))) / Om)) else: tmp = math.sqrt((-2.0 * (n / (Om / (t_1 * (l * (U * l))))))) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) t_1 = Float64(2.0 - Float64(n / Float64(Om / Float64(U_42_ - U)))) tmp = 0.0 if (l <= 1.25e-149) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t)))); elseif (l <= 2.3e+69) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om)))))); elseif (l <= 3.5e+141) tmp = sqrt(Float64(Float64(-2.0 * Float64(Float64(n * Float64(l * l)) * Float64(U * t_1))) / Om)); else tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(t_1 * Float64(l * Float64(U * l))))))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) t_1 = 2.0 - (n / (Om / (U_42_ - U))); tmp = 0.0; if (l <= 1.25e-149) tmp = sqrt((2.0 * (U * (n * t)))); elseif (l <= 2.3e+69) tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om)))))); elseif (l <= 3.5e+141) tmp = sqrt(((-2.0 * ((n * (l * l)) * (U * t_1))) / Om)); else tmp = sqrt((-2.0 * (n / (Om / (t_1 * (l * (U * l))))))); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(2.0 - N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[l, 1.25e-149], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 2.3e+69], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 3.5e+141], N[Sqrt[N[(N[(-2.0 * N[(N[(n * N[(l * l), $MachinePrecision]), $MachinePrecision] * N[(U * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(t$95$1 * N[(l * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
t_1 := 2 - \frac{n}{\frac{Om}{U* - U}}\\
\mathbf{if}\;\ell \leq 1.25 \cdot 10^{-149}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\
\mathbf{elif}\;\ell \leq 2.3 \cdot 10^{+69}:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\
\mathbf{elif}\;\ell \leq 3.5 \cdot 10^{+141}:\\
\;\;\;\;\sqrt{\frac{-2 \cdot \left(\left(n \cdot \left(\ell \cdot \ell\right)\right) \cdot \left(U \cdot t_1\right)\right)}{Om}}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{t_1 \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)}}}\\
\end{array}
\end{array}
if l < 1.24999999999999992e-149Initial program 54.5%
Simplified61.0%
distribute-rgt-in61.0%
Applied egg-rr61.0%
Taylor expanded in t around inf 44.9%
associate-*r*46.0%
Simplified46.0%
if 1.24999999999999992e-149 < l < 2.30000000000000017e69Initial program 66.4%
Taylor expanded in Om around inf 61.0%
unpow261.0%
associate-*r/61.0%
Simplified61.0%
if 2.30000000000000017e69 < l < 3.5e141Initial program 56.5%
Simplified65.1%
Taylor expanded in l around -inf 56.0%
associate-*r/56.0%
associate-*r*55.9%
unpow255.9%
*-commutative55.9%
mul-1-neg55.9%
unsub-neg55.9%
associate-/l*55.9%
Simplified55.9%
if 3.5e141 < l Initial program 5.1%
Simplified40.8%
distribute-rgt-in40.8%
Applied egg-rr40.8%
Taylor expanded in l around -inf 27.8%
associate-/l*27.8%
associate-*r*27.8%
*-commutative27.8%
associate-*r*27.8%
*-commutative27.8%
*-commutative27.8%
unpow227.8%
mul-1-neg27.8%
unsub-neg27.8%
associate-/l*27.8%
Simplified27.8%
Taylor expanded in U around 0 27.8%
*-commutative27.8%
unpow227.8%
associate-*l*41.3%
*-commutative41.3%
*-commutative41.3%
Simplified41.3%
Final simplification48.0%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 3e-149)
(sqrt (* 2.0 (* U (* n t))))
(if (<= l 1250.0)
(sqrt (* (* (* 2.0 n) U) (+ t (* -2.0 (* l (/ l Om))))))
(if (<= l 3e+96)
(sqrt (* (* 2.0 n) (+ (* U t) (* -2.0 (/ (* l l) (/ Om U))))))
(sqrt
(* -2.0 (/ n (/ Om (* U (* (* l l) (- 2.0 (/ n (/ Om U*)))))))))))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 3e-149) {
tmp = sqrt((2.0 * (U * (n * t))));
} else if (l <= 1250.0) {
tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
} else if (l <= 3e+96) {
tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
} else {
tmp = sqrt((-2.0 * (n / (Om / (U * ((l * l) * (2.0 - (n / (Om / U_42_)))))))));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (l <= 3d-149) then
tmp = sqrt((2.0d0 * (u * (n * t))))
else if (l <= 1250.0d0) then
tmp = sqrt((((2.0d0 * n) * u) * (t + ((-2.0d0) * (l * (l / om))))))
else if (l <= 3d+96) then
tmp = sqrt(((2.0d0 * n) * ((u * t) + ((-2.0d0) * ((l * l) / (om / u))))))
else
tmp = sqrt(((-2.0d0) * (n / (om / (u * ((l * l) * (2.0d0 - (n / (om / u_42)))))))))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 3e-149) {
tmp = Math.sqrt((2.0 * (U * (n * t))));
} else if (l <= 1250.0) {
tmp = Math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
} else if (l <= 3e+96) {
tmp = Math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U))))));
} else {
tmp = Math.sqrt((-2.0 * (n / (Om / (U * ((l * l) * (2.0 - (n / (Om / U_42_)))))))));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): tmp = 0 if l <= 3e-149: tmp = math.sqrt((2.0 * (U * (n * t)))) elif l <= 1250.0: tmp = math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om)))))) elif l <= 3e+96: tmp = math.sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U)))))) else: tmp = math.sqrt((-2.0 * (n / (Om / (U * ((l * l) * (2.0 - (n / (Om / U_42_))))))))) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 3e-149) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t)))); elseif (l <= 1250.0) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om)))))); elseif (l <= 3e+96) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(Float64(U * t) + Float64(-2.0 * Float64(Float64(l * l) / Float64(Om / U)))))); else tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(U * Float64(Float64(l * l) * Float64(2.0 - Float64(n / Float64(Om / U_42_))))))))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (l <= 3e-149) tmp = sqrt((2.0 * (U * (n * t)))); elseif (l <= 1250.0) tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om)))))); elseif (l <= 3e+96) tmp = sqrt(((2.0 * n) * ((U * t) + (-2.0 * ((l * l) / (Om / U)))))); else tmp = sqrt((-2.0 * (n / (Om / (U * ((l * l) * (2.0 - (n / (Om / U_42_))))))))); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 3e-149], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 1250.0], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 3e+96], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(N[(U * t), $MachinePrecision] + N[(-2.0 * N[(N[(l * l), $MachinePrecision] / N[(Om / U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(U * N[(N[(l * l), $MachinePrecision] * N[(2.0 - N[(n / N[(Om / U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 3 \cdot 10^{-149}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\
\mathbf{elif}\;\ell \leq 1250:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\
\mathbf{elif}\;\ell \leq 3 \cdot 10^{+96}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + -2 \cdot \frac{\ell \cdot \ell}{\frac{Om}{U}}\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{U \cdot \left(\left(\ell \cdot \ell\right) \cdot \left(2 - \frac{n}{\frac{Om}{U*}}\right)\right)}}}\\
\end{array}
\end{array}
if l < 3.0000000000000002e-149Initial program 54.5%
Simplified61.0%
distribute-rgt-in61.0%
Applied egg-rr61.0%
Taylor expanded in t around inf 44.9%
associate-*r*46.0%
Simplified46.0%
if 3.0000000000000002e-149 < l < 1250Initial program 64.0%
Taylor expanded in Om around inf 60.2%
unpow260.2%
associate-*r/60.2%
Simplified60.2%
if 1250 < l < 3e96Initial program 69.3%
Simplified80.4%
distribute-rgt-in80.4%
Applied egg-rr80.4%
Taylor expanded in Om around inf 54.6%
associate-/l*69.2%
unpow269.2%
Simplified69.2%
if 3e96 < l Initial program 13.1%
Simplified42.7%
distribute-rgt-in42.7%
Applied egg-rr42.7%
Taylor expanded in l around -inf 37.4%
associate-/l*34.7%
associate-*r*34.7%
*-commutative34.7%
associate-*r*34.7%
*-commutative34.7%
*-commutative34.7%
unpow234.7%
mul-1-neg34.7%
unsub-neg34.7%
associate-/l*37.4%
Simplified37.4%
Taylor expanded in U around 0 34.7%
associate-*r*34.7%
unpow234.7%
associate-/l*34.7%
Simplified34.7%
Final simplification47.3%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(if (<= l 3.5e+87)
(sqrt
(*
(* 2.0 n)
(* U (+ t (/ (* l (+ (* l -2.0) (/ (* n (* l U*)) Om))) Om)))))
(sqrt
(* -2.0 (/ n (/ Om (* (- 2.0 (/ n (/ Om (- U* U)))) (* l (* U l)))))))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 3.5e+87) {
tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else {
tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (l <= 3.5d+87) then
tmp = sqrt(((2.0d0 * n) * (u * (t + ((l * ((l * (-2.0d0)) + ((n * (l * u_42)) / om))) / om)))))
else
tmp = sqrt(((-2.0d0) * (n / (om / ((2.0d0 - (n / (om / (u_42 - u)))) * (l * (u * l)))))))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (l <= 3.5e+87) {
tmp = Math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om)))));
} else {
tmp = Math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l)))))));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): tmp = 0 if l <= 3.5e+87: tmp = math.sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))) else: tmp = math.sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l))))))) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (l <= 3.5e+87) tmp = sqrt(Float64(Float64(2.0 * n) * Float64(U * Float64(t + Float64(Float64(l * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om))) / Om))))); else tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(Float64(2.0 - Float64(n / Float64(Om / Float64(U_42_ - U)))) * Float64(l * Float64(U * l))))))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (l <= 3.5e+87) tmp = sqrt(((2.0 * n) * (U * (t + ((l * ((l * -2.0) + ((n * (l * U_42_)) / Om))) / Om))))); else tmp = sqrt((-2.0 * (n / (Om / ((2.0 - (n / (Om / (U_42_ - U)))) * (l * (U * l))))))); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[l, 3.5e+87], N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * N[(t + N[(N[(l * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[(N[(2.0 - N[(n / N[(Om / N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] * N[(l * N[(U * l), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;\ell \leq 3.5 \cdot 10^{+87}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot \left(t + \frac{\ell \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)}{Om}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\left(2 - \frac{n}{\frac{Om}{U* - U}}\right) \cdot \left(\ell \cdot \left(U \cdot \ell\right)\right)}}}\\
\end{array}
\end{array}
if l < 3.49999999999999986e87Initial program 56.7%
Simplified62.8%
Taylor expanded in U around 0 64.8%
if 3.49999999999999986e87 < l Initial program 15.3%
Simplified43.2%
distribute-rgt-in43.2%
Applied egg-rr43.2%
Taylor expanded in l around -inf 35.6%
associate-/l*33.0%
associate-*r*33.0%
*-commutative33.0%
associate-*r*33.0%
*-commutative33.0%
*-commutative33.0%
unpow233.0%
mul-1-neg33.0%
unsub-neg33.0%
associate-/l*35.6%
Simplified35.6%
Taylor expanded in U around 0 35.6%
*-commutative35.6%
unpow235.6%
associate-*l*46.1%
*-commutative46.1%
*-commutative46.1%
Simplified46.1%
Final simplification62.1%
NOTE: l should be positive before calling this function (FPCore (n U t l Om U*) :precision binary64 (sqrt (* (* 2.0 n) (+ (* U t) (/ (* l (* U (+ (* l -2.0) (/ (* n (* l U*)) Om)))) Om)))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
return sqrt(((2.0 * n) * ((U * t) + ((l * (U * ((l * -2.0) + ((n * (l * U_42_)) / Om)))) / Om))));
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
code = sqrt(((2.0d0 * n) * ((u * t) + ((l * (u * ((l * (-2.0d0)) + ((n * (l * u_42)) / om)))) / om))))
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
return Math.sqrt(((2.0 * n) * ((U * t) + ((l * (U * ((l * -2.0) + ((n * (l * U_42_)) / Om)))) / Om))));
}
l = abs(l) def code(n, U, t, l, Om, U_42_): return math.sqrt(((2.0 * n) * ((U * t) + ((l * (U * ((l * -2.0) + ((n * (l * U_42_)) / Om)))) / Om))))
l = abs(l) function code(n, U, t, l, Om, U_42_) return sqrt(Float64(Float64(2.0 * n) * Float64(Float64(U * t) + Float64(Float64(l * Float64(U * Float64(Float64(l * -2.0) + Float64(Float64(n * Float64(l * U_42_)) / Om)))) / Om)))) end
l = abs(l) function tmp = code(n, U, t, l, Om, U_42_) tmp = sqrt(((2.0 * n) * ((U * t) + ((l * (U * ((l * -2.0) + ((n * (l * U_42_)) / Om)))) / Om)))); end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(N[(U * t), $MachinePrecision] + N[(N[(l * N[(U * N[(N[(l * -2.0), $MachinePrecision] + N[(N[(n * N[(l * U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
l = |l|\\
\\
\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t + \frac{\ell \cdot \left(U \cdot \left(\ell \cdot -2 + \frac{n \cdot \left(\ell \cdot U*\right)}{Om}\right)\right)}{Om}\right)}
\end{array}
Initial program 50.7%
Simplified59.9%
distribute-rgt-in59.9%
Applied egg-rr59.9%
Taylor expanded in U around 0 61.8%
Final simplification61.8%
NOTE: l should be positive before calling this function
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1 (+ t (* -2.0 (* l (/ l Om))))))
(if (<= l 9.2e-150)
(sqrt (* 2.0 (* U (* n t))))
(if (<= l 3e-22)
(sqrt (* (* (* 2.0 n) U) t_1))
(if (<= l 3.25e+174)
(sqrt (* 2.0 (* n (* U t_1))))
(sqrt
(* -2.0 (/ n (/ Om (/ (- n) (/ Om (* (* l l) (* U U*)))))))))))))l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = t + (-2.0 * (l * (l / Om)));
double tmp;
if (l <= 9.2e-150) {
tmp = sqrt((2.0 * (U * (n * t))));
} else if (l <= 3e-22) {
tmp = sqrt((((2.0 * n) * U) * t_1));
} else if (l <= 3.25e+174) {
tmp = sqrt((2.0 * (n * (U * t_1))));
} else {
tmp = sqrt((-2.0 * (n / (Om / (-n / (Om / ((l * l) * (U * U_42_))))))));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: t_1
real(8) :: tmp
t_1 = t + ((-2.0d0) * (l * (l / om)))
if (l <= 9.2d-150) then
tmp = sqrt((2.0d0 * (u * (n * t))))
else if (l <= 3d-22) then
tmp = sqrt((((2.0d0 * n) * u) * t_1))
else if (l <= 3.25d+174) then
tmp = sqrt((2.0d0 * (n * (u * t_1))))
else
tmp = sqrt(((-2.0d0) * (n / (om / (-n / (om / ((l * l) * (u * u_42))))))))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = t + (-2.0 * (l * (l / Om)));
double tmp;
if (l <= 9.2e-150) {
tmp = Math.sqrt((2.0 * (U * (n * t))));
} else if (l <= 3e-22) {
tmp = Math.sqrt((((2.0 * n) * U) * t_1));
} else if (l <= 3.25e+174) {
tmp = Math.sqrt((2.0 * (n * (U * t_1))));
} else {
tmp = Math.sqrt((-2.0 * (n / (Om / (-n / (Om / ((l * l) * (U * U_42_))))))));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): t_1 = t + (-2.0 * (l * (l / Om))) tmp = 0 if l <= 9.2e-150: tmp = math.sqrt((2.0 * (U * (n * t)))) elif l <= 3e-22: tmp = math.sqrt((((2.0 * n) * U) * t_1)) elif l <= 3.25e+174: tmp = math.sqrt((2.0 * (n * (U * t_1)))) else: tmp = math.sqrt((-2.0 * (n / (Om / (-n / (Om / ((l * l) * (U * U_42_)))))))) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) t_1 = Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om)))) tmp = 0.0 if (l <= 9.2e-150) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t)))); elseif (l <= 3e-22) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * t_1)); elseif (l <= 3.25e+174) tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * t_1)))); else tmp = sqrt(Float64(-2.0 * Float64(n / Float64(Om / Float64(Float64(-n) / Float64(Om / Float64(Float64(l * l) * Float64(U * U_42_)))))))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) t_1 = t + (-2.0 * (l * (l / Om))); tmp = 0.0; if (l <= 9.2e-150) tmp = sqrt((2.0 * (U * (n * t)))); elseif (l <= 3e-22) tmp = sqrt((((2.0 * n) * U) * t_1)); elseif (l <= 3.25e+174) tmp = sqrt((2.0 * (n * (U * t_1)))); else tmp = sqrt((-2.0 * (n / (Om / (-n / (Om / ((l * l) * (U * U_42_)))))))); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]}, If[LessEqual[l, 9.2e-150], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 3e-22], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * t$95$1), $MachinePrecision]], $MachinePrecision], If[LessEqual[l, 3.25e+174], N[Sqrt[N[(2.0 * N[(n * N[(U * t$95$1), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(n / N[(Om / N[((-n) / N[(Om / N[(N[(l * l), $MachinePrecision] * N[(U * U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
t_1 := t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\\
\mathbf{if}\;\ell \leq 9.2 \cdot 10^{-150}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\
\mathbf{elif}\;\ell \leq 3 \cdot 10^{-22}:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot t_1}\\
\mathbf{elif}\;\ell \leq 3.25 \cdot 10^{+174}:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot t_1\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{-2 \cdot \frac{n}{\frac{Om}{\frac{-n}{\frac{Om}{\left(\ell \cdot \ell\right) \cdot \left(U \cdot U*\right)}}}}}\\
\end{array}
\end{array}
if l < 9.20000000000000011e-150Initial program 54.5%
Simplified61.0%
distribute-rgt-in61.0%
Applied egg-rr61.0%
Taylor expanded in t around inf 44.9%
associate-*r*46.0%
Simplified46.0%
if 9.20000000000000011e-150 < l < 2.9999999999999999e-22Initial program 67.3%
Taylor expanded in Om around inf 67.3%
unpow267.3%
associate-*r/67.3%
Simplified67.3%
if 2.9999999999999999e-22 < l < 3.2500000000000001e174Initial program 49.1%
Simplified64.9%
Taylor expanded in n around 0 45.5%
*-commutative45.5%
unpow245.5%
associate-*r/55.1%
Simplified55.1%
if 3.2500000000000001e174 < l Initial program 6.0%
Simplified37.6%
distribute-rgt-in37.6%
Applied egg-rr37.6%
Taylor expanded in l around -inf 33.8%
associate-/l*33.8%
associate-*r*33.8%
*-commutative33.8%
associate-*r*33.8%
*-commutative33.8%
*-commutative33.8%
unpow233.8%
mul-1-neg33.8%
unsub-neg33.8%
associate-/l*33.8%
Simplified33.8%
Taylor expanded in U* around inf 32.1%
mul-1-neg32.1%
associate-/l*32.1%
distribute-neg-frac32.1%
*-commutative32.1%
unpow232.1%
Simplified32.1%
Final simplification47.8%
NOTE: l should be positive before calling this function (FPCore (n U t l Om U*) :precision binary64 (if (<= t 850000000000.0) (sqrt (* 2.0 (* n (* U (+ t (* -2.0 (* l (/ l Om)))))))) (sqrt (* 2.0 (* U (* n t))))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 850000000000.0) {
tmp = sqrt((2.0 * (n * (U * (t + (-2.0 * (l * (l / Om))))))));
} else {
tmp = sqrt((2.0 * (U * (n * t))));
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (t <= 850000000000.0d0) then
tmp = sqrt((2.0d0 * (n * (u * (t + ((-2.0d0) * (l * (l / om))))))))
else
tmp = sqrt((2.0d0 * (u * (n * t))))
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 850000000000.0) {
tmp = Math.sqrt((2.0 * (n * (U * (t + (-2.0 * (l * (l / Om))))))));
} else {
tmp = Math.sqrt((2.0 * (U * (n * t))));
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): tmp = 0 if t <= 850000000000.0: tmp = math.sqrt((2.0 * (n * (U * (t + (-2.0 * (l * (l / Om)))))))) else: tmp = math.sqrt((2.0 * (U * (n * t)))) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= 850000000000.0) tmp = sqrt(Float64(2.0 * Float64(n * Float64(U * Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om)))))))); else tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * t)))); end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (t <= 850000000000.0) tmp = sqrt((2.0 * (n * (U * (t + (-2.0 * (l * (l / Om)))))))); else tmp = sqrt((2.0 * (U * (n * t)))); end tmp_2 = tmp; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, 850000000000.0], N[Sqrt[N[(2.0 * N[(n * N[(U * N[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq 850000000000:\\
\;\;\;\;\sqrt{2 \cdot \left(n \cdot \left(U \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}\\
\end{array}
\end{array}
if t < 8.5e11Initial program 49.4%
Simplified58.5%
Taylor expanded in n around 0 42.8%
*-commutative42.8%
unpow242.8%
associate-*r/44.8%
Simplified44.8%
if 8.5e11 < t Initial program 54.8%
Simplified64.6%
distribute-rgt-in64.5%
Applied egg-rr64.5%
Taylor expanded in t around inf 62.7%
associate-*r*64.2%
Simplified64.2%
Final simplification49.5%
NOTE: l should be positive before calling this function (FPCore (n U t l Om U*) :precision binary64 (if (<= t 4.5e+23) (sqrt (* (* (* 2.0 n) U) (+ t (* -2.0 (* l (/ l Om)))))) (pow (* 2.0 (* n (* U t))) 0.5)))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 4.5e+23) {
tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
} else {
tmp = pow((2.0 * (n * (U * t))), 0.5);
}
return tmp;
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (t <= 4.5d+23) then
tmp = sqrt((((2.0d0 * n) * u) * (t + ((-2.0d0) * (l * (l / om))))))
else
tmp = (2.0d0 * (n * (u * t))) ** 0.5d0
end if
code = tmp
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 4.5e+23) {
tmp = Math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om))))));
} else {
tmp = Math.pow((2.0 * (n * (U * t))), 0.5);
}
return tmp;
}
l = abs(l) def code(n, U, t, l, Om, U_42_): tmp = 0 if t <= 4.5e+23: tmp = math.sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om)))))) else: tmp = math.pow((2.0 * (n * (U * t))), 0.5) return tmp
l = abs(l) function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= 4.5e+23) tmp = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(t + Float64(-2.0 * Float64(l * Float64(l / Om)))))); else tmp = Float64(2.0 * Float64(n * Float64(U * t))) ^ 0.5; end return tmp end
l = abs(l) function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (t <= 4.5e+23) tmp = sqrt((((2.0 * n) * U) * (t + (-2.0 * (l * (l / Om)))))); else tmp = (2.0 * (n * (U * t))) ^ 0.5; end tmp_2 = tmp; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, 4.5e+23], N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(t + N[(-2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Power[N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]]
\begin{array}{l}
l = |l|\\
\\
\begin{array}{l}
\mathbf{if}\;t \leq 4.5 \cdot 10^{+23}:\\
\;\;\;\;\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(t + -2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;{\left(2 \cdot \left(n \cdot \left(U \cdot t\right)\right)\right)}^{0.5}\\
\end{array}
\end{array}
if t < 4.49999999999999979e23Initial program 50.2%
Taylor expanded in Om around inf 43.0%
unpow243.0%
associate-*r/45.9%
Simplified45.9%
if 4.49999999999999979e23 < t Initial program 52.4%
Simplified64.8%
Taylor expanded in t around inf 62.9%
pow1/263.1%
associate-*r*63.1%
Applied egg-rr63.1%
Final simplification49.8%
NOTE: l should be positive before calling this function (FPCore (n U t l Om U*) :precision binary64 (pow (* 2.0 (* n (* U t))) 0.5))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
return pow((2.0 * (n * (U * t))), 0.5);
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
code = (2.0d0 * (n * (u * t))) ** 0.5d0
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
return Math.pow((2.0 * (n * (U * t))), 0.5);
}
l = abs(l) def code(n, U, t, l, Om, U_42_): return math.pow((2.0 * (n * (U * t))), 0.5)
l = abs(l) function code(n, U, t, l, Om, U_42_) return Float64(2.0 * Float64(n * Float64(U * t))) ^ 0.5 end
l = abs(l) function tmp = code(n, U, t, l, Om, U_42_) tmp = (2.0 * (n * (U * t))) ^ 0.5; end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := N[Power[N[(2.0 * N[(n * N[(U * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]
\begin{array}{l}
l = |l|\\
\\
{\left(2 \cdot \left(n \cdot \left(U \cdot t\right)\right)\right)}^{0.5}
\end{array}
Initial program 50.7%
Simplified59.9%
Taylor expanded in t around inf 42.2%
pow1/242.2%
associate-*r*42.2%
Applied egg-rr42.2%
Final simplification42.2%
NOTE: l should be positive before calling this function (FPCore (n U t l Om U*) :precision binary64 (sqrt (* 2.0 (* U (* n t)))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
return sqrt((2.0 * (U * (n * t))));
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
code = sqrt((2.0d0 * (u * (n * t))))
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
return Math.sqrt((2.0 * (U * (n * t))));
}
l = abs(l) def code(n, U, t, l, Om, U_42_): return math.sqrt((2.0 * (U * (n * t))))
l = abs(l) function code(n, U, t, l, Om, U_42_) return sqrt(Float64(2.0 * Float64(U * Float64(n * t)))) end
l = abs(l) function tmp = code(n, U, t, l, Om, U_42_) tmp = sqrt((2.0 * (U * (n * t)))); end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
l = |l|\\
\\
\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}
\end{array}
Initial program 50.7%
Simplified59.9%
distribute-rgt-in59.9%
Applied egg-rr59.9%
Taylor expanded in t around inf 42.2%
associate-*r*41.4%
Simplified41.4%
Final simplification41.4%
NOTE: l should be positive before calling this function (FPCore (n U t l Om U*) :precision binary64 (sqrt (* (* 2.0 n) (* U t))))
l = abs(l);
double code(double n, double U, double t, double l, double Om, double U_42_) {
return sqrt(((2.0 * n) * (U * t)));
}
NOTE: l should be positive before calling this function
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
code = sqrt(((2.0d0 * n) * (u * t)))
end function
l = Math.abs(l);
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
return Math.sqrt(((2.0 * n) * (U * t)));
}
l = abs(l) def code(n, U, t, l, Om, U_42_): return math.sqrt(((2.0 * n) * (U * t)))
l = abs(l) function code(n, U, t, l, Om, U_42_) return sqrt(Float64(Float64(2.0 * n) * Float64(U * t))) end
l = abs(l) function tmp = code(n, U, t, l, Om, U_42_) tmp = sqrt(((2.0 * n) * (U * t))); end
NOTE: l should be positive before calling this function code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * N[(U * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
l = |l|\\
\\
\sqrt{\left(2 \cdot n\right) \cdot \left(U \cdot t\right)}
\end{array}
Initial program 50.7%
Simplified59.9%
Taylor expanded in t around inf 42.2%
Final simplification42.2%
herbie shell --seed 2023230
(FPCore (n U t l Om U*)
:name "Toniolo and Linder, Equation (13)"
:precision binary64
(sqrt (* (* (* 2.0 n) U) (- (- t (* 2.0 (/ (* l l) Om))) (* (* n (pow (/ l Om) 2.0)) (- U U*))))))