
(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 19 alternatives:
| Alternative | Accuracy | Speedup |
|---|
(FPCore (n U t l Om U*) :precision binary64 (sqrt (* (* (* 2.0 n) U) (- (- t (* 2.0 (/ (* l l) Om))) (* (* n (pow (/ l Om) 2.0)) (- U U*))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
return sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * pow((l / Om), 2.0)) * (U - U_42_)))));
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
code = sqrt((((2.0d0 * n) * u) * ((t - (2.0d0 * ((l * l) / om))) - ((n * ((l / om) ** 2.0d0)) * (u - u_42)))))
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
return Math.sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * Math.pow((l / Om), 2.0)) * (U - U_42_)))));
}
def code(n, U, t, l, Om, U_42_): return math.sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * math.pow((l / Om), 2.0)) * (U - U_42_)))))
function code(n, U, t, l, Om, U_42_) return sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l * l) / Om))) - Float64(Float64(n * (Float64(l / Om) ^ 2.0)) * Float64(U - U_42_))))) end
function tmp = code(n, U, t, l, Om, U_42_) tmp = sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) - ((n * ((l / Om) ^ 2.0)) * (U - U_42_))))); end
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - N[(N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U - U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
\\
\sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) - \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U - U*\right)\right)}
\end{array}
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1 (* n (pow (/ l Om) 2.0)))
(t_2
(sqrt
(*
(* (* 2.0 n) U)
(+ (- t (* 2.0 (/ (* l l) Om))) (* t_1 (- U* U)))))))
(if (<= t_2 0.0)
(*
(sqrt (* 2.0 n))
(sqrt (* U (- t (fma 2.0 (/ (pow l 2.0) Om) (* t_1 (- U U*)))))))
(if (<= t_2 INFINITY)
(sqrt
(*
(* 2.0 (* n U))
(fma
n
(* (/ l Om) (* (/ l Om) (- U* U)))
(fma (* l -2.0) (/ l Om) t))))
(sqrt
(*
-2.0
(/ (* U (* (pow l 2.0) (* n (+ 2.0 (/ (* n (- U U*)) Om))))) Om)))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = n * pow((l / Om), 2.0);
double t_2 = sqrt((((2.0 * n) * U) * ((t - (2.0 * ((l * l) / Om))) + (t_1 * (U_42_ - U)))));
double tmp;
if (t_2 <= 0.0) {
tmp = sqrt((2.0 * n)) * sqrt((U * (t - fma(2.0, (pow(l, 2.0) / Om), (t_1 * (U - U_42_))))));
} else if (t_2 <= ((double) INFINITY)) {
tmp = sqrt(((2.0 * (n * U)) * fma(n, ((l / Om) * ((l / Om) * (U_42_ - U))), fma((l * -2.0), (l / Om), t))));
} else {
tmp = sqrt((-2.0 * ((U * (pow(l, 2.0) * (n * (2.0 + ((n * (U - U_42_)) / Om))))) / Om)));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) t_1 = Float64(n * (Float64(l / Om) ^ 2.0)) t_2 = sqrt(Float64(Float64(Float64(2.0 * n) * U) * Float64(Float64(t - Float64(2.0 * Float64(Float64(l * l) / Om))) + Float64(t_1 * Float64(U_42_ - U))))) tmp = 0.0 if (t_2 <= 0.0) tmp = Float64(sqrt(Float64(2.0 * n)) * sqrt(Float64(U * Float64(t - fma(2.0, Float64((l ^ 2.0) / Om), Float64(t_1 * Float64(U - U_42_))))))); elseif (t_2 <= Inf) tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * fma(n, Float64(Float64(l / Om) * Float64(Float64(l / Om) * Float64(U_42_ - U))), fma(Float64(l * -2.0), Float64(l / Om), t)))); else tmp = sqrt(Float64(-2.0 * Float64(Float64(U * Float64((l ^ 2.0) * Float64(n * Float64(2.0 + Float64(Float64(n * Float64(U - U_42_)) / Om))))) / Om))); end return tmp end
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[Sqrt[N[(N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision] * N[(N[(t - N[(2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(t$95$1 * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$2, 0.0], N[(N[Sqrt[N[(2.0 * n), $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(U * N[(t - N[(2.0 * N[(N[Power[l, 2.0], $MachinePrecision] / Om), $MachinePrecision] + N[(t$95$1 * N[(U - U$42$), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$2, Infinity], N[Sqrt[N[(N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision] * N[(n * N[(N[(l / Om), $MachinePrecision] * N[(N[(l / Om), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(l * -2.0), $MachinePrecision] * N[(l / Om), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(N[(U * N[(N[Power[l, 2.0], $MachinePrecision] * N[(n * N[(2.0 + N[(N[(n * N[(U - U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\\
t_2 := \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) + t\_1 \cdot \left(U* - U\right)\right)}\\
\mathbf{if}\;t\_2 \leq 0:\\
\;\;\;\;\sqrt{2 \cdot n} \cdot \sqrt{U \cdot \left(t - \mathsf{fma}\left(2, \frac{{\ell}^{2}}{Om}, t\_1 \cdot \left(U - U*\right)\right)\right)}\\
\mathbf{elif}\;t\_2 \leq \infty:\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \mathsf{fma}\left(n, \frac{\ell}{Om} \cdot \left(\frac{\ell}{Om} \cdot \left(U* - U\right)\right), \mathsf{fma}\left(\ell \cdot -2, \frac{\ell}{Om}, t\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{-2 \cdot \frac{U \cdot \left({\ell}^{2} \cdot \left(n \cdot \left(2 + \frac{n \cdot \left(U - U*\right)}{Om}\right)\right)\right)}{Om}}\\
\end{array}
\end{array}
if (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) < 0.0Initial program 8.9%
pow1/28.9%
associate-*l*31.3%
unpow-prod-down45.1%
pow1/245.1%
Applied egg-rr45.1%
unpow1/245.1%
associate-*l*45.1%
Simplified45.1%
if 0.0 < (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) < +inf.0Initial program 73.8%
Simplified77.4%
*-commutative77.4%
unpow277.4%
associate-*r*78.9%
Applied egg-rr78.9%
if +inf.0 < (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) Initial program 0.0%
Simplified4.7%
Taylor expanded in Om around -inf 23.3%
mul-1-neg23.3%
unsub-neg23.3%
+-commutative23.3%
mul-1-neg23.3%
unsub-neg23.3%
associate-/l*23.3%
Simplified23.3%
Taylor expanded in l around 0 31.7%
Taylor expanded in t around 0 41.8%
Final simplification68.7%
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1
(sqrt
(*
(* (* 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)) (sqrt (* U t)))
(if (<= t_1 INFINITY)
(sqrt
(*
(* 2.0 (* n U))
(fma
n
(* (/ l Om) (* (/ l Om) (- U* U)))
(fma (* l -2.0) (/ l Om) t))))
(sqrt
(*
-2.0
(/ (* U (* (pow l 2.0) (* n (+ 2.0 (/ (* n (- U U*)) Om))))) Om)))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = sqrt((((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)) * sqrt((U * t));
} else if (t_1 <= ((double) INFINITY)) {
tmp = sqrt(((2.0 * (n * U)) * fma(n, ((l / Om) * ((l / Om) * (U_42_ - U))), fma((l * -2.0), (l / Om), t))));
} else {
tmp = sqrt((-2.0 * ((U * (pow(l, 2.0) * (n * (2.0 + ((n * (U - U_42_)) / Om))))) / Om)));
}
return tmp;
}
function code(n, U, t, l, Om, U_42_) t_1 = 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_42_ - U))))) tmp = 0.0 if (t_1 <= 0.0) tmp = Float64(sqrt(Float64(2.0 * n)) * sqrt(Float64(U * t))); elseif (t_1 <= Inf) tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * fma(n, Float64(Float64(l / Om) * Float64(Float64(l / Om) * Float64(U_42_ - U))), fma(Float64(l * -2.0), Float64(l / Om), t)))); else tmp = sqrt(Float64(-2.0 * Float64(Float64(U * Float64((l ^ 2.0) * Float64(n * Float64(2.0 + Float64(Float64(n * Float64(U - U_42_)) / Om))))) / Om))); end return tmp end
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = 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$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$1, 0.0], N[(N[Sqrt[N[(2.0 * n), $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(U * t), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$1, Infinity], N[Sqrt[N[(N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision] * N[(n * N[(N[(l / Om), $MachinePrecision] * N[(N[(l / Om), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + N[(N[(l * -2.0), $MachinePrecision] * N[(l / Om), $MachinePrecision] + t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(N[(U * N[(N[Power[l, 2.0], $MachinePrecision] * N[(n * N[(2.0 + N[(N[(n * N[(U - U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \sqrt{\left(\left(2 \cdot n\right) \cdot U\right) \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) + \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\right)}\\
\mathbf{if}\;t\_1 \leq 0:\\
\;\;\;\;\sqrt{2 \cdot n} \cdot \sqrt{U \cdot t}\\
\mathbf{elif}\;t\_1 \leq \infty:\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \mathsf{fma}\left(n, \frac{\ell}{Om} \cdot \left(\frac{\ell}{Om} \cdot \left(U* - U\right)\right), \mathsf{fma}\left(\ell \cdot -2, \frac{\ell}{Om}, t\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{-2 \cdot \frac{U \cdot \left({\ell}^{2} \cdot \left(n \cdot \left(2 + \frac{n \cdot \left(U - U*\right)}{Om}\right)\right)\right)}{Om}}\\
\end{array}
\end{array}
if (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) < 0.0Initial program 8.9%
Simplified8.8%
Taylor expanded in l around 0 26.7%
*-commutative26.7%
Applied egg-rr26.7%
associate-*l*26.7%
Simplified26.7%
pow1/226.7%
associate-*r*27.0%
unpow-prod-down35.1%
pow1/235.1%
*-commutative35.1%
pow1/235.1%
*-commutative35.1%
Applied egg-rr35.1%
if 0.0 < (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) < +inf.0Initial program 73.8%
Simplified77.4%
*-commutative77.4%
unpow277.4%
associate-*r*78.9%
Applied egg-rr78.9%
if +inf.0 < (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) Initial program 0.0%
Simplified4.7%
Taylor expanded in Om around -inf 23.3%
mul-1-neg23.3%
unsub-neg23.3%
+-commutative23.3%
mul-1-neg23.3%
unsub-neg23.3%
associate-/l*23.3%
Simplified23.3%
Taylor expanded in l around 0 31.7%
Taylor expanded in t around 0 41.8%
Final simplification67.6%
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1 (* (* n (pow (/ l Om) 2.0)) (- U* U)))
(t_2 (* (* 2.0 n) U))
(t_3 (sqrt (* t_2 (+ (- t (* 2.0 (/ (* l l) Om))) t_1)))))
(if (<= t_3 0.0)
(* (sqrt (* 2.0 n)) (sqrt (* U t)))
(if (<= t_3 INFINITY)
(sqrt (* t_2 (- t_1 (- (* 2.0 (* l (/ l Om))) t))))
(sqrt
(*
-2.0
(/ (* U (* (pow l 2.0) (* n (+ 2.0 (/ (* n (- U U*)) Om))))) Om)))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = (n * pow((l / Om), 2.0)) * (U_42_ - U);
double t_2 = (2.0 * n) * U;
double t_3 = sqrt((t_2 * ((t - (2.0 * ((l * l) / Om))) + t_1)));
double tmp;
if (t_3 <= 0.0) {
tmp = sqrt((2.0 * n)) * sqrt((U * t));
} else if (t_3 <= ((double) INFINITY)) {
tmp = sqrt((t_2 * (t_1 - ((2.0 * (l * (l / Om))) - t))));
} else {
tmp = sqrt((-2.0 * ((U * (pow(l, 2.0) * (n * (2.0 + ((n * (U - U_42_)) / Om))))) / Om)));
}
return tmp;
}
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = (n * Math.pow((l / Om), 2.0)) * (U_42_ - U);
double t_2 = (2.0 * n) * U;
double t_3 = Math.sqrt((t_2 * ((t - (2.0 * ((l * l) / Om))) + t_1)));
double tmp;
if (t_3 <= 0.0) {
tmp = Math.sqrt((2.0 * n)) * Math.sqrt((U * t));
} else if (t_3 <= Double.POSITIVE_INFINITY) {
tmp = Math.sqrt((t_2 * (t_1 - ((2.0 * (l * (l / Om))) - t))));
} else {
tmp = Math.sqrt((-2.0 * ((U * (Math.pow(l, 2.0) * (n * (2.0 + ((n * (U - U_42_)) / Om))))) / Om)));
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): t_1 = (n * math.pow((l / Om), 2.0)) * (U_42_ - U) t_2 = (2.0 * n) * U t_3 = math.sqrt((t_2 * ((t - (2.0 * ((l * l) / Om))) + t_1))) tmp = 0 if t_3 <= 0.0: tmp = math.sqrt((2.0 * n)) * math.sqrt((U * t)) elif t_3 <= math.inf: tmp = math.sqrt((t_2 * (t_1 - ((2.0 * (l * (l / Om))) - t)))) else: tmp = math.sqrt((-2.0 * ((U * (math.pow(l, 2.0) * (n * (2.0 + ((n * (U - U_42_)) / Om))))) / Om))) return tmp
function code(n, U, t, l, Om, U_42_) t_1 = Float64(Float64(n * (Float64(l / Om) ^ 2.0)) * Float64(U_42_ - U)) t_2 = Float64(Float64(2.0 * n) * U) t_3 = sqrt(Float64(t_2 * Float64(Float64(t - Float64(2.0 * Float64(Float64(l * l) / Om))) + t_1))) tmp = 0.0 if (t_3 <= 0.0) tmp = Float64(sqrt(Float64(2.0 * n)) * sqrt(Float64(U * t))); elseif (t_3 <= Inf) tmp = sqrt(Float64(t_2 * Float64(t_1 - Float64(Float64(2.0 * Float64(l * Float64(l / Om))) - t)))); else tmp = sqrt(Float64(-2.0 * Float64(Float64(U * Float64((l ^ 2.0) * Float64(n * Float64(2.0 + Float64(Float64(n * Float64(U - U_42_)) / Om))))) / Om))); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) t_1 = (n * ((l / Om) ^ 2.0)) * (U_42_ - U); t_2 = (2.0 * n) * U; t_3 = sqrt((t_2 * ((t - (2.0 * ((l * l) / Om))) + t_1))); tmp = 0.0; if (t_3 <= 0.0) tmp = sqrt((2.0 * n)) * sqrt((U * t)); elseif (t_3 <= Inf) tmp = sqrt((t_2 * (t_1 - ((2.0 * (l * (l / Om))) - t)))); else tmp = sqrt((-2.0 * ((U * ((l ^ 2.0) * (n * (2.0 + ((n * (U - U_42_)) / Om))))) / Om))); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(N[(n * N[Power[N[(l / Om), $MachinePrecision], 2.0], $MachinePrecision]), $MachinePrecision] * N[(U$42$ - U), $MachinePrecision]), $MachinePrecision]}, Block[{t$95$2 = N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]}, Block[{t$95$3 = N[Sqrt[N[(t$95$2 * N[(N[(t - N[(2.0 * N[(N[(l * l), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] + t$95$1), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]}, If[LessEqual[t$95$3, 0.0], N[(N[Sqrt[N[(2.0 * n), $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(U * t), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], If[LessEqual[t$95$3, Infinity], N[Sqrt[N[(t$95$2 * N[(t$95$1 - N[(N[(2.0 * N[(l * N[(l / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] - t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(-2.0 * N[(N[(U * N[(N[Power[l, 2.0], $MachinePrecision] * N[(n * N[(2.0 + N[(N[(n * N[(U - U$42$), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := \left(n \cdot {\left(\frac{\ell}{Om}\right)}^{2}\right) \cdot \left(U* - U\right)\\
t_2 := \left(2 \cdot n\right) \cdot U\\
t_3 := \sqrt{t\_2 \cdot \left(\left(t - 2 \cdot \frac{\ell \cdot \ell}{Om}\right) + t\_1\right)}\\
\mathbf{if}\;t\_3 \leq 0:\\
\;\;\;\;\sqrt{2 \cdot n} \cdot \sqrt{U \cdot t}\\
\mathbf{elif}\;t\_3 \leq \infty:\\
\;\;\;\;\sqrt{t\_2 \cdot \left(t\_1 - \left(2 \cdot \left(\ell \cdot \frac{\ell}{Om}\right) - t\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{-2 \cdot \frac{U \cdot \left({\ell}^{2} \cdot \left(n \cdot \left(2 + \frac{n \cdot \left(U - U*\right)}{Om}\right)\right)\right)}{Om}}\\
\end{array}
\end{array}
if (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) < 0.0Initial program 8.9%
Simplified8.8%
Taylor expanded in l around 0 26.7%
*-commutative26.7%
Applied egg-rr26.7%
associate-*l*26.7%
Simplified26.7%
pow1/226.7%
associate-*r*27.0%
unpow-prod-down35.1%
pow1/235.1%
*-commutative35.1%
pow1/235.1%
*-commutative35.1%
Applied egg-rr35.1%
if 0.0 < (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) < +inf.0Initial program 73.8%
associate-/l*78.5%
clear-num78.5%
un-div-inv78.5%
Applied egg-rr78.5%
associate-/r/78.5%
Simplified78.5%
if +inf.0 < (sqrt.f64 (*.f64 (*.f64 (*.f64 #s(literal 2 binary64) n) U) (-.f64 (-.f64 t (*.f64 #s(literal 2 binary64) (/.f64 (*.f64 l l) Om))) (*.f64 (*.f64 n (pow.f64 (/.f64 l Om) #s(literal 2 binary64))) (-.f64 U U*))))) Initial program 0.0%
Simplified4.7%
Taylor expanded in Om around -inf 23.3%
mul-1-neg23.3%
unsub-neg23.3%
+-commutative23.3%
mul-1-neg23.3%
unsub-neg23.3%
associate-/l*23.3%
Simplified23.3%
Taylor expanded in l around 0 31.7%
Taylor expanded in t around 0 41.8%
Final simplification67.3%
(FPCore (n U t l Om U*)
:precision binary64
(let* ((t_1 (* n (pow l 2.0))))
(if (<= t -2.1e-263)
(sqrt (* 2.0 (* U (* n (- t (* 2.0 (/ (pow l 2.0) Om)))))))
(if (<= t 4e-178)
(sqrt (/ (* -2.0 (* U (* t_1 (- 2.0 (* U* (/ n Om)))))) Om))
(if (<= t 3.5e+150)
(sqrt (* U (+ (* -4.0 (/ t_1 Om)) (* 2.0 (* n t)))))
(* (sqrt (* (* 2.0 n) U)) (sqrt t)))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = n * pow(l, 2.0);
double tmp;
if (t <= -2.1e-263) {
tmp = sqrt((2.0 * (U * (n * (t - (2.0 * (pow(l, 2.0) / Om)))))));
} else if (t <= 4e-178) {
tmp = sqrt(((-2.0 * (U * (t_1 * (2.0 - (U_42_ * (n / Om)))))) / Om));
} else if (t <= 3.5e+150) {
tmp = sqrt((U * ((-4.0 * (t_1 / Om)) + (2.0 * (n * t)))));
} else {
tmp = sqrt(((2.0 * n) * U)) * sqrt(t);
}
return tmp;
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: t_1
real(8) :: tmp
t_1 = n * (l ** 2.0d0)
if (t <= (-2.1d-263)) then
tmp = sqrt((2.0d0 * (u * (n * (t - (2.0d0 * ((l ** 2.0d0) / om)))))))
else if (t <= 4d-178) then
tmp = sqrt((((-2.0d0) * (u * (t_1 * (2.0d0 - (u_42 * (n / om)))))) / om))
else if (t <= 3.5d+150) then
tmp = sqrt((u * (((-4.0d0) * (t_1 / om)) + (2.0d0 * (n * t)))))
else
tmp = sqrt(((2.0d0 * n) * u)) * sqrt(t)
end if
code = tmp
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double t_1 = n * Math.pow(l, 2.0);
double tmp;
if (t <= -2.1e-263) {
tmp = Math.sqrt((2.0 * (U * (n * (t - (2.0 * (Math.pow(l, 2.0) / Om)))))));
} else if (t <= 4e-178) {
tmp = Math.sqrt(((-2.0 * (U * (t_1 * (2.0 - (U_42_ * (n / Om)))))) / Om));
} else if (t <= 3.5e+150) {
tmp = Math.sqrt((U * ((-4.0 * (t_1 / Om)) + (2.0 * (n * t)))));
} else {
tmp = Math.sqrt(((2.0 * n) * U)) * Math.sqrt(t);
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): t_1 = n * math.pow(l, 2.0) tmp = 0 if t <= -2.1e-263: tmp = math.sqrt((2.0 * (U * (n * (t - (2.0 * (math.pow(l, 2.0) / Om))))))) elif t <= 4e-178: tmp = math.sqrt(((-2.0 * (U * (t_1 * (2.0 - (U_42_ * (n / Om)))))) / Om)) elif t <= 3.5e+150: tmp = math.sqrt((U * ((-4.0 * (t_1 / Om)) + (2.0 * (n * t))))) else: tmp = math.sqrt(((2.0 * n) * U)) * math.sqrt(t) return tmp
function code(n, U, t, l, Om, U_42_) t_1 = Float64(n * (l ^ 2.0)) tmp = 0.0 if (t <= -2.1e-263) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * Float64(t - Float64(2.0 * Float64((l ^ 2.0) / Om))))))); elseif (t <= 4e-178) tmp = sqrt(Float64(Float64(-2.0 * Float64(U * Float64(t_1 * Float64(2.0 - Float64(U_42_ * Float64(n / Om)))))) / Om)); elseif (t <= 3.5e+150) tmp = sqrt(Float64(U * Float64(Float64(-4.0 * Float64(t_1 / Om)) + Float64(2.0 * Float64(n * t))))); else tmp = Float64(sqrt(Float64(Float64(2.0 * n) * U)) * sqrt(t)); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) t_1 = n * (l ^ 2.0); tmp = 0.0; if (t <= -2.1e-263) tmp = sqrt((2.0 * (U * (n * (t - (2.0 * ((l ^ 2.0) / Om))))))); elseif (t <= 4e-178) tmp = sqrt(((-2.0 * (U * (t_1 * (2.0 - (U_42_ * (n / Om)))))) / Om)); elseif (t <= 3.5e+150) tmp = sqrt((U * ((-4.0 * (t_1 / Om)) + (2.0 * (n * t))))); else tmp = sqrt(((2.0 * n) * U)) * sqrt(t); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := Block[{t$95$1 = N[(n * N[Power[l, 2.0], $MachinePrecision]), $MachinePrecision]}, If[LessEqual[t, -2.1e-263], N[Sqrt[N[(2.0 * N[(U * N[(n * N[(t - N[(2.0 * N[(N[Power[l, 2.0], $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t, 4e-178], N[Sqrt[N[(N[(-2.0 * N[(U * N[(t$95$1 * N[(2.0 - N[(U$42$ * N[(n / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]], $MachinePrecision], If[LessEqual[t, 3.5e+150], N[Sqrt[N[(U * N[(N[(-4.0 * N[(t$95$1 / Om), $MachinePrecision]), $MachinePrecision] + N[(2.0 * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]], $MachinePrecision] * N[Sqrt[t], $MachinePrecision]), $MachinePrecision]]]]]
\begin{array}{l}
\\
\begin{array}{l}
t_1 := n \cdot {\ell}^{2}\\
\mathbf{if}\;t \leq -2.1 \cdot 10^{-263}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot \left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right)\right)\right)}\\
\mathbf{elif}\;t \leq 4 \cdot 10^{-178}:\\
\;\;\;\;\sqrt{\frac{-2 \cdot \left(U \cdot \left(t\_1 \cdot \left(2 - U* \cdot \frac{n}{Om}\right)\right)\right)}{Om}}\\
\mathbf{elif}\;t \leq 3.5 \cdot 10^{+150}:\\
\;\;\;\;\sqrt{U \cdot \left(-4 \cdot \frac{t\_1}{Om} + 2 \cdot \left(n \cdot t\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot U} \cdot \sqrt{t}\\
\end{array}
\end{array}
if t < -2.10000000000000003e-263Initial program 51.2%
Taylor expanded in n around 0 49.5%
if -2.10000000000000003e-263 < t < 3.9999999999999998e-178Initial program 43.7%
Simplified46.5%
Taylor expanded in Om around -inf 39.8%
mul-1-neg39.8%
unsub-neg39.8%
+-commutative39.8%
mul-1-neg39.8%
unsub-neg39.8%
associate-/l*45.4%
Simplified45.4%
Taylor expanded in l around 0 52.5%
Taylor expanded in U around 0 52.5%
associate-/l*52.5%
associate-/l*58.1%
Simplified58.1%
Taylor expanded in t around 0 47.3%
associate-*r/47.3%
associate-*r*50.0%
associate-*r/50.0%
Simplified50.0%
if 3.9999999999999998e-178 < t < 3.49999999999999984e150Initial program 59.9%
Simplified61.5%
Taylor expanded in Om around inf 50.9%
Taylor expanded in U around 0 52.4%
if 3.49999999999999984e150 < t Initial program 60.1%
Simplified67.3%
Taylor expanded in l around 0 62.2%
associate-*r*62.5%
*-commutative62.5%
Applied egg-rr62.5%
pow1/265.0%
associate-*r*65.0%
metadata-eval65.0%
unpow-prod-down78.5%
metadata-eval78.5%
pow1/276.1%
associate-*r*76.1%
*-commutative76.1%
metadata-eval76.1%
pow1/276.1%
Applied egg-rr76.1%
Final simplification54.5%
(FPCore (n U t l Om U*)
:precision binary64
(if (<= t -6.4e-264)
(sqrt (* 2.0 (* U (* n (- t (* 2.0 (/ (pow l 2.0) Om)))))))
(if (<= t 8e-178)
(sqrt (* -2.0 (/ (* U (* (pow l 2.0) (* n (- 2.0 (/ (* n U*) Om))))) Om)))
(if (<= t 7e+151)
(sqrt (* U (+ (* -4.0 (/ (* n (pow l 2.0)) Om)) (* 2.0 (* n t)))))
(* (sqrt (* (* 2.0 n) U)) (sqrt t))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= -6.4e-264) {
tmp = sqrt((2.0 * (U * (n * (t - (2.0 * (pow(l, 2.0) / Om)))))));
} else if (t <= 8e-178) {
tmp = sqrt((-2.0 * ((U * (pow(l, 2.0) * (n * (2.0 - ((n * U_42_) / Om))))) / Om)));
} else if (t <= 7e+151) {
tmp = sqrt((U * ((-4.0 * ((n * pow(l, 2.0)) / Om)) + (2.0 * (n * t)))));
} else {
tmp = sqrt(((2.0 * n) * U)) * sqrt(t);
}
return tmp;
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (t <= (-6.4d-264)) then
tmp = sqrt((2.0d0 * (u * (n * (t - (2.0d0 * ((l ** 2.0d0) / om)))))))
else if (t <= 8d-178) then
tmp = sqrt(((-2.0d0) * ((u * ((l ** 2.0d0) * (n * (2.0d0 - ((n * u_42) / om))))) / om)))
else if (t <= 7d+151) then
tmp = sqrt((u * (((-4.0d0) * ((n * (l ** 2.0d0)) / om)) + (2.0d0 * (n * t)))))
else
tmp = sqrt(((2.0d0 * n) * u)) * sqrt(t)
end if
code = tmp
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= -6.4e-264) {
tmp = Math.sqrt((2.0 * (U * (n * (t - (2.0 * (Math.pow(l, 2.0) / Om)))))));
} else if (t <= 8e-178) {
tmp = Math.sqrt((-2.0 * ((U * (Math.pow(l, 2.0) * (n * (2.0 - ((n * U_42_) / Om))))) / Om)));
} else if (t <= 7e+151) {
tmp = Math.sqrt((U * ((-4.0 * ((n * Math.pow(l, 2.0)) / Om)) + (2.0 * (n * t)))));
} else {
tmp = Math.sqrt(((2.0 * n) * U)) * Math.sqrt(t);
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if t <= -6.4e-264: tmp = math.sqrt((2.0 * (U * (n * (t - (2.0 * (math.pow(l, 2.0) / Om))))))) elif t <= 8e-178: tmp = math.sqrt((-2.0 * ((U * (math.pow(l, 2.0) * (n * (2.0 - ((n * U_42_) / Om))))) / Om))) elif t <= 7e+151: tmp = math.sqrt((U * ((-4.0 * ((n * math.pow(l, 2.0)) / Om)) + (2.0 * (n * t))))) else: tmp = math.sqrt(((2.0 * n) * U)) * math.sqrt(t) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= -6.4e-264) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * Float64(t - Float64(2.0 * Float64((l ^ 2.0) / Om))))))); elseif (t <= 8e-178) tmp = sqrt(Float64(-2.0 * Float64(Float64(U * Float64((l ^ 2.0) * Float64(n * Float64(2.0 - Float64(Float64(n * U_42_) / Om))))) / Om))); elseif (t <= 7e+151) tmp = sqrt(Float64(U * Float64(Float64(-4.0 * Float64(Float64(n * (l ^ 2.0)) / Om)) + Float64(2.0 * Float64(n * t))))); else tmp = Float64(sqrt(Float64(Float64(2.0 * n) * U)) * sqrt(t)); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (t <= -6.4e-264) tmp = sqrt((2.0 * (U * (n * (t - (2.0 * ((l ^ 2.0) / Om))))))); elseif (t <= 8e-178) tmp = sqrt((-2.0 * ((U * ((l ^ 2.0) * (n * (2.0 - ((n * U_42_) / Om))))) / Om))); elseif (t <= 7e+151) tmp = sqrt((U * ((-4.0 * ((n * (l ^ 2.0)) / Om)) + (2.0 * (n * t))))); else tmp = sqrt(((2.0 * n) * U)) * sqrt(t); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, -6.4e-264], N[Sqrt[N[(2.0 * N[(U * N[(n * N[(t - N[(2.0 * N[(N[Power[l, 2.0], $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t, 8e-178], N[Sqrt[N[(-2.0 * N[(N[(U * N[(N[Power[l, 2.0], $MachinePrecision] * N[(n * N[(2.0 - N[(N[(n * U$42$), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], If[LessEqual[t, 7e+151], N[Sqrt[N[(U * N[(N[(-4.0 * N[(N[(n * N[Power[l, 2.0], $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision] + N[(2.0 * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]], $MachinePrecision] * N[Sqrt[t], $MachinePrecision]), $MachinePrecision]]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -6.4 \cdot 10^{-264}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot \left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right)\right)\right)}\\
\mathbf{elif}\;t \leq 8 \cdot 10^{-178}:\\
\;\;\;\;\sqrt{-2 \cdot \frac{U \cdot \left({\ell}^{2} \cdot \left(n \cdot \left(2 - \frac{n \cdot U*}{Om}\right)\right)\right)}{Om}}\\
\mathbf{elif}\;t \leq 7 \cdot 10^{+151}:\\
\;\;\;\;\sqrt{U \cdot \left(-4 \cdot \frac{n \cdot {\ell}^{2}}{Om} + 2 \cdot \left(n \cdot t\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot U} \cdot \sqrt{t}\\
\end{array}
\end{array}
if t < -6.3999999999999999e-264Initial program 51.2%
Taylor expanded in n around 0 49.5%
if -6.3999999999999999e-264 < t < 7.9999999999999996e-178Initial program 43.7%
Simplified46.5%
Taylor expanded in Om around -inf 39.8%
mul-1-neg39.8%
unsub-neg39.8%
+-commutative39.8%
mul-1-neg39.8%
unsub-neg39.8%
associate-/l*45.4%
Simplified45.4%
Taylor expanded in l around 0 52.5%
Taylor expanded in U around 0 52.5%
associate-/l*52.5%
associate-/l*58.1%
Simplified58.1%
Taylor expanded in t around 0 47.3%
if 7.9999999999999996e-178 < t < 7.0000000000000006e151Initial program 59.9%
Simplified61.5%
Taylor expanded in Om around inf 50.9%
Taylor expanded in U around 0 52.4%
if 7.0000000000000006e151 < t Initial program 60.1%
Simplified67.3%
Taylor expanded in l around 0 62.2%
associate-*r*62.5%
*-commutative62.5%
Applied egg-rr62.5%
pow1/265.0%
associate-*r*65.0%
metadata-eval65.0%
unpow-prod-down78.5%
metadata-eval78.5%
pow1/276.1%
associate-*r*76.1%
*-commutative76.1%
metadata-eval76.1%
pow1/276.1%
Applied egg-rr76.1%
Final simplification54.2%
(FPCore (n U t l Om U*) :precision binary64 (if (or (<= U* -850.0) (not (<= U* 7400000.0))) (sqrt (* (* 2.0 (* n U)) (+ t (/ (* U* (* (pow l 2.0) (/ n Om))) Om)))) (sqrt (* U (* (* 2.0 n) (+ t (* (/ (pow l 2.0) Om) -2.0)))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if ((U_42_ <= -850.0) || !(U_42_ <= 7400000.0)) {
tmp = sqrt(((2.0 * (n * U)) * (t + ((U_42_ * (pow(l, 2.0) * (n / Om))) / Om))));
} else {
tmp = sqrt((U * ((2.0 * n) * (t + ((pow(l, 2.0) / Om) * -2.0)))));
}
return tmp;
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if ((u_42 <= (-850.0d0)) .or. (.not. (u_42 <= 7400000.0d0))) then
tmp = sqrt(((2.0d0 * (n * u)) * (t + ((u_42 * ((l ** 2.0d0) * (n / om))) / om))))
else
tmp = sqrt((u * ((2.0d0 * n) * (t + (((l ** 2.0d0) / om) * (-2.0d0))))))
end if
code = tmp
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if ((U_42_ <= -850.0) || !(U_42_ <= 7400000.0)) {
tmp = Math.sqrt(((2.0 * (n * U)) * (t + ((U_42_ * (Math.pow(l, 2.0) * (n / Om))) / Om))));
} else {
tmp = Math.sqrt((U * ((2.0 * n) * (t + ((Math.pow(l, 2.0) / Om) * -2.0)))));
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if (U_42_ <= -850.0) or not (U_42_ <= 7400000.0): tmp = math.sqrt(((2.0 * (n * U)) * (t + ((U_42_ * (math.pow(l, 2.0) * (n / Om))) / Om)))) else: tmp = math.sqrt((U * ((2.0 * n) * (t + ((math.pow(l, 2.0) / Om) * -2.0))))) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if ((U_42_ <= -850.0) || !(U_42_ <= 7400000.0)) tmp = sqrt(Float64(Float64(2.0 * Float64(n * U)) * Float64(t + Float64(Float64(U_42_ * Float64((l ^ 2.0) * Float64(n / Om))) / Om)))); else tmp = sqrt(Float64(U * Float64(Float64(2.0 * n) * Float64(t + Float64(Float64((l ^ 2.0) / Om) * -2.0))))); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if ((U_42_ <= -850.0) || ~((U_42_ <= 7400000.0))) tmp = sqrt(((2.0 * (n * U)) * (t + ((U_42_ * ((l ^ 2.0) * (n / Om))) / Om)))); else tmp = sqrt((U * ((2.0 * n) * (t + (((l ^ 2.0) / Om) * -2.0))))); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[Or[LessEqual[U$42$, -850.0], N[Not[LessEqual[U$42$, 7400000.0]], $MachinePrecision]], N[Sqrt[N[(N[(2.0 * N[(n * U), $MachinePrecision]), $MachinePrecision] * N[(t + N[(N[(U$42$ * N[(N[Power[l, 2.0], $MachinePrecision] * N[(n / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[Sqrt[N[(U * N[(N[(2.0 * n), $MachinePrecision] * N[(t + N[(N[(N[Power[l, 2.0], $MachinePrecision] / Om), $MachinePrecision] * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;U* \leq -850 \lor \neg \left(U* \leq 7400000\right):\\
\;\;\;\;\sqrt{\left(2 \cdot \left(n \cdot U\right)\right) \cdot \left(t + \frac{U* \cdot \left({\ell}^{2} \cdot \frac{n}{Om}\right)}{Om}\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{U \cdot \left(\left(2 \cdot n\right) \cdot \left(t + \frac{{\ell}^{2}}{Om} \cdot -2\right)\right)}\\
\end{array}
\end{array}
if U* < -850 or 7.4e6 < U* Initial program 52.4%
Simplified54.3%
Taylor expanded in Om around -inf 46.4%
mul-1-neg46.4%
unsub-neg46.4%
+-commutative46.4%
mul-1-neg46.4%
unsub-neg46.4%
associate-/l*48.9%
Simplified48.9%
Taylor expanded in l around 0 51.2%
Taylor expanded in U* around inf 52.4%
mul-1-neg52.4%
associate-/l*53.8%
associate-/l*55.0%
Simplified55.0%
if -850 < U* < 7.4e6Initial program 55.8%
Simplified61.2%
*-commutative61.2%
associate-*r*61.3%
associate-*r*64.3%
*-commutative64.3%
Applied egg-rr64.3%
Taylor expanded in n around 0 60.2%
Final simplification57.1%
(FPCore (n U t l Om U*)
:precision binary64
(if (<= t 1.95e+151)
(sqrt
(* 2.0 (* U (* n (+ t (/ (* (pow l 2.0) (- (/ (* n U*) Om) 2.0)) Om))))))
(* (sqrt (* (* 2.0 n) U)) (sqrt t))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 1.95e+151) {
tmp = sqrt((2.0 * (U * (n * (t + ((pow(l, 2.0) * (((n * U_42_) / Om) - 2.0)) / Om))))));
} else {
tmp = sqrt(((2.0 * n) * U)) * sqrt(t);
}
return tmp;
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (t <= 1.95d+151) then
tmp = sqrt((2.0d0 * (u * (n * (t + (((l ** 2.0d0) * (((n * u_42) / om) - 2.0d0)) / om))))))
else
tmp = sqrt(((2.0d0 * n) * u)) * sqrt(t)
end if
code = tmp
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 1.95e+151) {
tmp = Math.sqrt((2.0 * (U * (n * (t + ((Math.pow(l, 2.0) * (((n * U_42_) / Om) - 2.0)) / Om))))));
} else {
tmp = Math.sqrt(((2.0 * n) * U)) * Math.sqrt(t);
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if t <= 1.95e+151: tmp = math.sqrt((2.0 * (U * (n * (t + ((math.pow(l, 2.0) * (((n * U_42_) / Om) - 2.0)) / Om)))))) else: tmp = math.sqrt(((2.0 * n) * U)) * math.sqrt(t) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= 1.95e+151) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * Float64(t + Float64(Float64((l ^ 2.0) * Float64(Float64(Float64(n * U_42_) / Om) - 2.0)) / Om)))))); else tmp = Float64(sqrt(Float64(Float64(2.0 * n) * U)) * sqrt(t)); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (t <= 1.95e+151) tmp = sqrt((2.0 * (U * (n * (t + (((l ^ 2.0) * (((n * U_42_) / Om) - 2.0)) / Om)))))); else tmp = sqrt(((2.0 * n) * U)) * sqrt(t); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, 1.95e+151], N[Sqrt[N[(2.0 * N[(U * N[(n * N[(t + N[(N[(N[Power[l, 2.0], $MachinePrecision] * N[(N[(N[(n * U$42$), $MachinePrecision] / Om), $MachinePrecision] - 2.0), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]], $MachinePrecision] * N[Sqrt[t], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq 1.95 \cdot 10^{+151}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot \left(t + \frac{{\ell}^{2} \cdot \left(\frac{n \cdot U*}{Om} - 2\right)}{Om}\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot U} \cdot \sqrt{t}\\
\end{array}
\end{array}
if t < 1.94999999999999988e151Initial program 52.5%
Simplified55.2%
Taylor expanded in Om around -inf 49.6%
mul-1-neg49.6%
unsub-neg49.6%
+-commutative49.6%
mul-1-neg49.6%
unsub-neg49.6%
associate-/l*51.4%
Simplified51.4%
Taylor expanded in l around 0 53.1%
Taylor expanded in U around 0 56.4%
if 1.94999999999999988e151 < t Initial program 60.1%
Simplified67.3%
Taylor expanded in l around 0 62.2%
associate-*r*62.5%
*-commutative62.5%
Applied egg-rr62.5%
pow1/265.0%
associate-*r*65.0%
metadata-eval65.0%
unpow-prod-down78.5%
metadata-eval78.5%
pow1/276.1%
associate-*r*76.1%
*-commutative76.1%
metadata-eval76.1%
pow1/276.1%
Applied egg-rr76.1%
Final simplification59.5%
(FPCore (n U t l Om U*)
:precision binary64
(if (<= t -4e-182)
(pow (* 2.0 (* U (* n t))) 0.5)
(if (<= t 1.75e-162)
(* (/ (* l (* n (sqrt 2.0))) Om) (sqrt (* U U*)))
(* (sqrt (* (* 2.0 n) U)) (sqrt t)))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= -4e-182) {
tmp = pow((2.0 * (U * (n * t))), 0.5);
} else if (t <= 1.75e-162) {
tmp = ((l * (n * sqrt(2.0))) / Om) * sqrt((U * U_42_));
} else {
tmp = sqrt(((2.0 * n) * U)) * sqrt(t);
}
return tmp;
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (t <= (-4d-182)) then
tmp = (2.0d0 * (u * (n * t))) ** 0.5d0
else if (t <= 1.75d-162) then
tmp = ((l * (n * sqrt(2.0d0))) / om) * sqrt((u * u_42))
else
tmp = sqrt(((2.0d0 * n) * u)) * sqrt(t)
end if
code = tmp
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= -4e-182) {
tmp = Math.pow((2.0 * (U * (n * t))), 0.5);
} else if (t <= 1.75e-162) {
tmp = ((l * (n * Math.sqrt(2.0))) / Om) * Math.sqrt((U * U_42_));
} else {
tmp = Math.sqrt(((2.0 * n) * U)) * Math.sqrt(t);
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if t <= -4e-182: tmp = math.pow((2.0 * (U * (n * t))), 0.5) elif t <= 1.75e-162: tmp = ((l * (n * math.sqrt(2.0))) / Om) * math.sqrt((U * U_42_)) else: tmp = math.sqrt(((2.0 * n) * U)) * math.sqrt(t) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= -4e-182) tmp = Float64(2.0 * Float64(U * Float64(n * t))) ^ 0.5; elseif (t <= 1.75e-162) tmp = Float64(Float64(Float64(l * Float64(n * sqrt(2.0))) / Om) * sqrt(Float64(U * U_42_))); else tmp = Float64(sqrt(Float64(Float64(2.0 * n) * U)) * sqrt(t)); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (t <= -4e-182) tmp = (2.0 * (U * (n * t))) ^ 0.5; elseif (t <= 1.75e-162) tmp = ((l * (n * sqrt(2.0))) / Om) * sqrt((U * U_42_)); else tmp = sqrt(((2.0 * n) * U)) * sqrt(t); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, -4e-182], N[Power[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], If[LessEqual[t, 1.75e-162], N[(N[(N[(l * N[(n * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision] * N[Sqrt[N[(U * U$42$), $MachinePrecision]], $MachinePrecision]), $MachinePrecision], N[(N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]], $MachinePrecision] * N[Sqrt[t], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4 \cdot 10^{-182}:\\
\;\;\;\;{\left(2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)}^{0.5}\\
\mathbf{elif}\;t \leq 1.75 \cdot 10^{-162}:\\
\;\;\;\;\frac{\ell \cdot \left(n \cdot \sqrt{2}\right)}{Om} \cdot \sqrt{U \cdot U*}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot U} \cdot \sqrt{t}\\
\end{array}
\end{array}
if t < -4.0000000000000002e-182Initial program 52.7%
Simplified55.5%
Taylor expanded in l around 0 49.0%
pow1/250.0%
Applied egg-rr50.0%
if -4.0000000000000002e-182 < t < 1.74999999999999995e-162Initial program 44.2%
Simplified47.6%
Taylor expanded in U* around inf 15.2%
if 1.74999999999999995e-162 < t Initial program 60.5%
Simplified64.5%
Taylor expanded in l around 0 49.0%
associate-*r*48.8%
*-commutative48.8%
Applied egg-rr48.8%
pow1/249.8%
associate-*r*49.8%
metadata-eval49.8%
unpow-prod-down56.7%
metadata-eval56.7%
pow1/255.6%
associate-*r*55.7%
*-commutative55.7%
metadata-eval55.7%
pow1/255.7%
Applied egg-rr55.7%
Final simplification44.3%
(FPCore (n U t l Om U*)
:precision binary64
(if (<= t -4.8e-182)
(pow (* 2.0 (* U (* n t))) 0.5)
(if (<= t 1e-144)
(* (sqrt (* U U*)) (* l (* n (/ (sqrt 2.0) Om))))
(* (sqrt (* (* 2.0 n) U)) (sqrt t)))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= -4.8e-182) {
tmp = pow((2.0 * (U * (n * t))), 0.5);
} else if (t <= 1e-144) {
tmp = sqrt((U * U_42_)) * (l * (n * (sqrt(2.0) / Om)));
} else {
tmp = sqrt(((2.0 * n) * U)) * sqrt(t);
}
return tmp;
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (t <= (-4.8d-182)) then
tmp = (2.0d0 * (u * (n * t))) ** 0.5d0
else if (t <= 1d-144) then
tmp = sqrt((u * u_42)) * (l * (n * (sqrt(2.0d0) / om)))
else
tmp = sqrt(((2.0d0 * n) * u)) * sqrt(t)
end if
code = tmp
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= -4.8e-182) {
tmp = Math.pow((2.0 * (U * (n * t))), 0.5);
} else if (t <= 1e-144) {
tmp = Math.sqrt((U * U_42_)) * (l * (n * (Math.sqrt(2.0) / Om)));
} else {
tmp = Math.sqrt(((2.0 * n) * U)) * Math.sqrt(t);
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if t <= -4.8e-182: tmp = math.pow((2.0 * (U * (n * t))), 0.5) elif t <= 1e-144: tmp = math.sqrt((U * U_42_)) * (l * (n * (math.sqrt(2.0) / Om))) else: tmp = math.sqrt(((2.0 * n) * U)) * math.sqrt(t) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= -4.8e-182) tmp = Float64(2.0 * Float64(U * Float64(n * t))) ^ 0.5; elseif (t <= 1e-144) tmp = Float64(sqrt(Float64(U * U_42_)) * Float64(l * Float64(n * Float64(sqrt(2.0) / Om)))); else tmp = Float64(sqrt(Float64(Float64(2.0 * n) * U)) * sqrt(t)); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (t <= -4.8e-182) tmp = (2.0 * (U * (n * t))) ^ 0.5; elseif (t <= 1e-144) tmp = sqrt((U * U_42_)) * (l * (n * (sqrt(2.0) / Om))); else tmp = sqrt(((2.0 * n) * U)) * sqrt(t); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, -4.8e-182], N[Power[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], If[LessEqual[t, 1e-144], N[(N[Sqrt[N[(U * U$42$), $MachinePrecision]], $MachinePrecision] * N[(l * N[(n * N[(N[Sqrt[2.0], $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]], $MachinePrecision] * N[Sqrt[t], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.8 \cdot 10^{-182}:\\
\;\;\;\;{\left(2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)}^{0.5}\\
\mathbf{elif}\;t \leq 10^{-144}:\\
\;\;\;\;\sqrt{U \cdot U*} \cdot \left(\ell \cdot \left(n \cdot \frac{\sqrt{2}}{Om}\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot U} \cdot \sqrt{t}\\
\end{array}
\end{array}
if t < -4.7999999999999997e-182Initial program 52.7%
Simplified55.5%
Taylor expanded in l around 0 49.0%
pow1/250.0%
Applied egg-rr50.0%
if -4.7999999999999997e-182 < t < 9.9999999999999995e-145Initial program 43.1%
Simplified46.2%
Taylor expanded in U* around inf 16.0%
associate-/l*16.0%
Simplified16.0%
*-commutative16.0%
associate-/l*16.0%
Applied egg-rr16.0%
if 9.9999999999999995e-145 < t Initial program 62.0%
Simplified66.1%
Taylor expanded in l around 0 49.9%
associate-*r*49.7%
*-commutative49.7%
Applied egg-rr49.7%
pow1/250.7%
associate-*r*50.7%
metadata-eval50.7%
unpow-prod-down57.9%
metadata-eval57.9%
pow1/256.8%
associate-*r*56.8%
*-commutative56.8%
metadata-eval56.8%
pow1/256.8%
Applied egg-rr56.8%
Final simplification44.3%
(FPCore (n U t l Om U*)
:precision binary64
(if (<= t -2.7e-182)
(pow (* 2.0 (* U (* n t))) 0.5)
(if (<= t 5.1e-161)
(* (sqrt (* U U*)) (* l (/ (* n (sqrt 2.0)) Om)))
(* (sqrt (* (* 2.0 n) U)) (sqrt t)))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= -2.7e-182) {
tmp = pow((2.0 * (U * (n * t))), 0.5);
} else if (t <= 5.1e-161) {
tmp = sqrt((U * U_42_)) * (l * ((n * sqrt(2.0)) / Om));
} else {
tmp = sqrt(((2.0 * n) * U)) * sqrt(t);
}
return tmp;
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (t <= (-2.7d-182)) then
tmp = (2.0d0 * (u * (n * t))) ** 0.5d0
else if (t <= 5.1d-161) then
tmp = sqrt((u * u_42)) * (l * ((n * sqrt(2.0d0)) / om))
else
tmp = sqrt(((2.0d0 * n) * u)) * sqrt(t)
end if
code = tmp
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= -2.7e-182) {
tmp = Math.pow((2.0 * (U * (n * t))), 0.5);
} else if (t <= 5.1e-161) {
tmp = Math.sqrt((U * U_42_)) * (l * ((n * Math.sqrt(2.0)) / Om));
} else {
tmp = Math.sqrt(((2.0 * n) * U)) * Math.sqrt(t);
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if t <= -2.7e-182: tmp = math.pow((2.0 * (U * (n * t))), 0.5) elif t <= 5.1e-161: tmp = math.sqrt((U * U_42_)) * (l * ((n * math.sqrt(2.0)) / Om)) else: tmp = math.sqrt(((2.0 * n) * U)) * math.sqrt(t) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= -2.7e-182) tmp = Float64(2.0 * Float64(U * Float64(n * t))) ^ 0.5; elseif (t <= 5.1e-161) tmp = Float64(sqrt(Float64(U * U_42_)) * Float64(l * Float64(Float64(n * sqrt(2.0)) / Om))); else tmp = Float64(sqrt(Float64(Float64(2.0 * n) * U)) * sqrt(t)); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (t <= -2.7e-182) tmp = (2.0 * (U * (n * t))) ^ 0.5; elseif (t <= 5.1e-161) tmp = sqrt((U * U_42_)) * (l * ((n * sqrt(2.0)) / Om)); else tmp = sqrt(((2.0 * n) * U)) * sqrt(t); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, -2.7e-182], N[Power[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], If[LessEqual[t, 5.1e-161], N[(N[Sqrt[N[(U * U$42$), $MachinePrecision]], $MachinePrecision] * N[(l * N[(N[(n * N[Sqrt[2.0], $MachinePrecision]), $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]], $MachinePrecision] * N[Sqrt[t], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -2.7 \cdot 10^{-182}:\\
\;\;\;\;{\left(2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)}^{0.5}\\
\mathbf{elif}\;t \leq 5.1 \cdot 10^{-161}:\\
\;\;\;\;\sqrt{U \cdot U*} \cdot \left(\ell \cdot \frac{n \cdot \sqrt{2}}{Om}\right)\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot U} \cdot \sqrt{t}\\
\end{array}
\end{array}
if t < -2.69999999999999999e-182Initial program 52.7%
Simplified55.5%
Taylor expanded in l around 0 49.0%
pow1/250.0%
Applied egg-rr50.0%
if -2.69999999999999999e-182 < t < 5.1000000000000003e-161Initial program 44.2%
Simplified47.6%
Taylor expanded in U* around inf 15.2%
associate-/l*15.2%
Simplified15.2%
if 5.1000000000000003e-161 < t Initial program 60.5%
Simplified64.5%
Taylor expanded in l around 0 49.0%
associate-*r*48.8%
*-commutative48.8%
Applied egg-rr48.8%
pow1/249.8%
associate-*r*49.8%
metadata-eval49.8%
unpow-prod-down56.7%
metadata-eval56.7%
pow1/255.6%
associate-*r*55.7%
*-commutative55.7%
metadata-eval55.7%
pow1/255.7%
Applied egg-rr55.7%
Final simplification44.3%
(FPCore (n U t l Om U*)
:precision binary64
(if (<= t -4.2e-182)
(pow (* 2.0 (* U (* n t))) 0.5)
(if (<= t 1.85e-187)
(* l (* (sqrt (* U U*)) (* n (/ (sqrt 2.0) Om))))
(* (sqrt (* (* 2.0 n) U)) (sqrt t)))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= -4.2e-182) {
tmp = pow((2.0 * (U * (n * t))), 0.5);
} else if (t <= 1.85e-187) {
tmp = l * (sqrt((U * U_42_)) * (n * (sqrt(2.0) / Om)));
} else {
tmp = sqrt(((2.0 * n) * U)) * sqrt(t);
}
return tmp;
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (t <= (-4.2d-182)) then
tmp = (2.0d0 * (u * (n * t))) ** 0.5d0
else if (t <= 1.85d-187) then
tmp = l * (sqrt((u * u_42)) * (n * (sqrt(2.0d0) / om)))
else
tmp = sqrt(((2.0d0 * n) * u)) * sqrt(t)
end if
code = tmp
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= -4.2e-182) {
tmp = Math.pow((2.0 * (U * (n * t))), 0.5);
} else if (t <= 1.85e-187) {
tmp = l * (Math.sqrt((U * U_42_)) * (n * (Math.sqrt(2.0) / Om)));
} else {
tmp = Math.sqrt(((2.0 * n) * U)) * Math.sqrt(t);
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if t <= -4.2e-182: tmp = math.pow((2.0 * (U * (n * t))), 0.5) elif t <= 1.85e-187: tmp = l * (math.sqrt((U * U_42_)) * (n * (math.sqrt(2.0) / Om))) else: tmp = math.sqrt(((2.0 * n) * U)) * math.sqrt(t) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= -4.2e-182) tmp = Float64(2.0 * Float64(U * Float64(n * t))) ^ 0.5; elseif (t <= 1.85e-187) tmp = Float64(l * Float64(sqrt(Float64(U * U_42_)) * Float64(n * Float64(sqrt(2.0) / Om)))); else tmp = Float64(sqrt(Float64(Float64(2.0 * n) * U)) * sqrt(t)); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (t <= -4.2e-182) tmp = (2.0 * (U * (n * t))) ^ 0.5; elseif (t <= 1.85e-187) tmp = l * (sqrt((U * U_42_)) * (n * (sqrt(2.0) / Om))); else tmp = sqrt(((2.0 * n) * U)) * sqrt(t); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, -4.2e-182], N[Power[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], If[LessEqual[t, 1.85e-187], N[(l * N[(N[Sqrt[N[(U * U$42$), $MachinePrecision]], $MachinePrecision] * N[(n * N[(N[Sqrt[2.0], $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], N[(N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]], $MachinePrecision] * N[Sqrt[t], $MachinePrecision]), $MachinePrecision]]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq -4.2 \cdot 10^{-182}:\\
\;\;\;\;{\left(2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)}^{0.5}\\
\mathbf{elif}\;t \leq 1.85 \cdot 10^{-187}:\\
\;\;\;\;\ell \cdot \left(\sqrt{U \cdot U*} \cdot \left(n \cdot \frac{\sqrt{2}}{Om}\right)\right)\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot U} \cdot \sqrt{t}\\
\end{array}
\end{array}
if t < -4.2000000000000001e-182Initial program 52.7%
Simplified55.5%
Taylor expanded in l around 0 49.0%
pow1/250.0%
Applied egg-rr50.0%
if -4.2000000000000001e-182 < t < 1.85000000000000005e-187Initial program 42.6%
Simplified46.3%
Taylor expanded in U* around inf 16.7%
associate-/l*16.7%
Simplified16.7%
associate-*l*16.7%
associate-/l*16.7%
*-commutative16.7%
Applied egg-rr16.7%
if 1.85000000000000005e-187 < t Initial program 60.4%
Simplified64.1%
Taylor expanded in l around 0 46.3%
associate-*r*47.0%
*-commutative47.0%
Applied egg-rr47.0%
pow1/248.0%
associate-*r*48.0%
metadata-eval48.0%
unpow-prod-down54.4%
metadata-eval54.4%
pow1/253.5%
associate-*r*53.5%
*-commutative53.5%
metadata-eval53.5%
pow1/253.5%
Applied egg-rr53.5%
Final simplification44.7%
(FPCore (n U t l Om U*) :precision binary64 (if (<= t 1.55e+152) (sqrt (* U (* (* 2.0 n) (+ t (* (/ (pow l 2.0) Om) -2.0))))) (* (sqrt (* (* 2.0 n) U)) (sqrt t))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 1.55e+152) {
tmp = sqrt((U * ((2.0 * n) * (t + ((pow(l, 2.0) / Om) * -2.0)))));
} else {
tmp = sqrt(((2.0 * n) * U)) * sqrt(t);
}
return tmp;
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (t <= 1.55d+152) then
tmp = sqrt((u * ((2.0d0 * n) * (t + (((l ** 2.0d0) / om) * (-2.0d0))))))
else
tmp = sqrt(((2.0d0 * n) * u)) * sqrt(t)
end if
code = tmp
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 1.55e+152) {
tmp = Math.sqrt((U * ((2.0 * n) * (t + ((Math.pow(l, 2.0) / Om) * -2.0)))));
} else {
tmp = Math.sqrt(((2.0 * n) * U)) * Math.sqrt(t);
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if t <= 1.55e+152: tmp = math.sqrt((U * ((2.0 * n) * (t + ((math.pow(l, 2.0) / Om) * -2.0))))) else: tmp = math.sqrt(((2.0 * n) * U)) * math.sqrt(t) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= 1.55e+152) tmp = sqrt(Float64(U * Float64(Float64(2.0 * n) * Float64(t + Float64(Float64((l ^ 2.0) / Om) * -2.0))))); else tmp = Float64(sqrt(Float64(Float64(2.0 * n) * U)) * sqrt(t)); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (t <= 1.55e+152) tmp = sqrt((U * ((2.0 * n) * (t + (((l ^ 2.0) / Om) * -2.0))))); else tmp = sqrt(((2.0 * n) * U)) * sqrt(t); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, 1.55e+152], N[Sqrt[N[(U * N[(N[(2.0 * n), $MachinePrecision] * N[(t + N[(N[(N[Power[l, 2.0], $MachinePrecision] / Om), $MachinePrecision] * -2.0), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]], $MachinePrecision] * N[Sqrt[t], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq 1.55 \cdot 10^{+152}:\\
\;\;\;\;\sqrt{U \cdot \left(\left(2 \cdot n\right) \cdot \left(t + \frac{{\ell}^{2}}{Om} \cdot -2\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot U} \cdot \sqrt{t}\\
\end{array}
\end{array}
if t < 1.55e152Initial program 52.5%
Simplified55.2%
*-commutative55.2%
associate-*r*55.2%
associate-*r*56.4%
*-commutative56.4%
Applied egg-rr56.4%
Taylor expanded in n around 0 46.0%
if 1.55e152 < t Initial program 60.1%
Simplified67.3%
Taylor expanded in l around 0 62.2%
associate-*r*62.5%
*-commutative62.5%
Applied egg-rr62.5%
pow1/265.0%
associate-*r*65.0%
metadata-eval65.0%
unpow-prod-down78.5%
metadata-eval78.5%
pow1/276.1%
associate-*r*76.1%
*-commutative76.1%
metadata-eval76.1%
pow1/276.1%
Applied egg-rr76.1%
Final simplification50.8%
(FPCore (n U t l Om U*) :precision binary64 (if (<= t 5.6e+152) (sqrt (* 2.0 (* U (* n (- t (* 2.0 (/ (pow l 2.0) Om))))))) (* (sqrt (* (* 2.0 n) U)) (sqrt t))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 5.6e+152) {
tmp = sqrt((2.0 * (U * (n * (t - (2.0 * (pow(l, 2.0) / Om)))))));
} else {
tmp = sqrt(((2.0 * n) * U)) * sqrt(t);
}
return tmp;
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (t <= 5.6d+152) then
tmp = sqrt((2.0d0 * (u * (n * (t - (2.0d0 * ((l ** 2.0d0) / om)))))))
else
tmp = sqrt(((2.0d0 * n) * u)) * sqrt(t)
end if
code = tmp
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 5.6e+152) {
tmp = Math.sqrt((2.0 * (U * (n * (t - (2.0 * (Math.pow(l, 2.0) / Om)))))));
} else {
tmp = Math.sqrt(((2.0 * n) * U)) * Math.sqrt(t);
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if t <= 5.6e+152: tmp = math.sqrt((2.0 * (U * (n * (t - (2.0 * (math.pow(l, 2.0) / Om))))))) else: tmp = math.sqrt(((2.0 * n) * U)) * math.sqrt(t) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= 5.6e+152) tmp = sqrt(Float64(2.0 * Float64(U * Float64(n * Float64(t - Float64(2.0 * Float64((l ^ 2.0) / Om))))))); else tmp = Float64(sqrt(Float64(Float64(2.0 * n) * U)) * sqrt(t)); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (t <= 5.6e+152) tmp = sqrt((2.0 * (U * (n * (t - (2.0 * ((l ^ 2.0) / Om))))))); else tmp = sqrt(((2.0 * n) * U)) * sqrt(t); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, 5.6e+152], N[Sqrt[N[(2.0 * N[(U * N[(n * N[(t - N[(2.0 * N[(N[Power[l, 2.0], $MachinePrecision] / Om), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision], N[(N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]], $MachinePrecision] * N[Sqrt[t], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq 5.6 \cdot 10^{+152}:\\
\;\;\;\;\sqrt{2 \cdot \left(U \cdot \left(n \cdot \left(t - 2 \cdot \frac{{\ell}^{2}}{Om}\right)\right)\right)}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot U} \cdot \sqrt{t}\\
\end{array}
\end{array}
if t < 5.6000000000000004e152Initial program 52.5%
Taylor expanded in n around 0 46.0%
if 5.6000000000000004e152 < t Initial program 60.1%
Simplified67.3%
Taylor expanded in l around 0 62.2%
associate-*r*62.5%
*-commutative62.5%
Applied egg-rr62.5%
pow1/265.0%
associate-*r*65.0%
metadata-eval65.0%
unpow-prod-down78.5%
metadata-eval78.5%
pow1/276.1%
associate-*r*76.1%
*-commutative76.1%
metadata-eval76.1%
pow1/276.1%
Applied egg-rr76.1%
Final simplification50.8%
(FPCore (n U t l Om U*) :precision binary64 (if (<= t 2.3e-221) (pow (* 2.0 (* U (* n t))) 0.5) (* (sqrt (* (* 2.0 n) U)) (sqrt t))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 2.3e-221) {
tmp = pow((2.0 * (U * (n * t))), 0.5);
} else {
tmp = sqrt(((2.0 * n) * U)) * sqrt(t);
}
return tmp;
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (t <= 2.3d-221) then
tmp = (2.0d0 * (u * (n * t))) ** 0.5d0
else
tmp = sqrt(((2.0d0 * n) * u)) * sqrt(t)
end if
code = tmp
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (t <= 2.3e-221) {
tmp = Math.pow((2.0 * (U * (n * t))), 0.5);
} else {
tmp = Math.sqrt(((2.0 * n) * U)) * Math.sqrt(t);
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if t <= 2.3e-221: tmp = math.pow((2.0 * (U * (n * t))), 0.5) else: tmp = math.sqrt(((2.0 * n) * U)) * math.sqrt(t) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (t <= 2.3e-221) tmp = Float64(2.0 * Float64(U * Float64(n * t))) ^ 0.5; else tmp = Float64(sqrt(Float64(Float64(2.0 * n) * U)) * sqrt(t)); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (t <= 2.3e-221) tmp = (2.0 * (U * (n * t))) ^ 0.5; else tmp = sqrt(((2.0 * n) * U)) * sqrt(t); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[t, 2.3e-221], N[Power[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], N[(N[Sqrt[N[(N[(2.0 * n), $MachinePrecision] * U), $MachinePrecision]], $MachinePrecision] * N[Sqrt[t], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;t \leq 2.3 \cdot 10^{-221}:\\
\;\;\;\;{\left(2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)}^{0.5}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{\left(2 \cdot n\right) \cdot U} \cdot \sqrt{t}\\
\end{array}
\end{array}
if t < 2.3e-221Initial program 49.8%
Simplified53.0%
Taylor expanded in l around 0 36.1%
pow1/236.7%
Applied egg-rr36.7%
if 2.3e-221 < t Initial program 59.1%
Simplified62.8%
Taylor expanded in l around 0 44.6%
associate-*r*45.4%
*-commutative45.4%
Applied egg-rr45.4%
pow1/246.3%
associate-*r*46.3%
metadata-eval46.3%
unpow-prod-down52.9%
metadata-eval52.9%
pow1/252.0%
associate-*r*52.1%
*-commutative52.1%
metadata-eval52.1%
pow1/252.1%
Applied egg-rr52.1%
Final simplification43.2%
(FPCore (n U t l Om U*) :precision binary64 (if (<= n 2.15e-223) (pow (* 2.0 (* U (* n t))) 0.5) (* (sqrt (* 2.0 n)) (sqrt (* U t)))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (n <= 2.15e-223) {
tmp = pow((2.0 * (U * (n * t))), 0.5);
} else {
tmp = sqrt((2.0 * n)) * sqrt((U * t));
}
return tmp;
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (n <= 2.15d-223) then
tmp = (2.0d0 * (u * (n * t))) ** 0.5d0
else
tmp = sqrt((2.0d0 * n)) * sqrt((u * t))
end if
code = tmp
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (n <= 2.15e-223) {
tmp = Math.pow((2.0 * (U * (n * t))), 0.5);
} else {
tmp = Math.sqrt((2.0 * n)) * Math.sqrt((U * t));
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if n <= 2.15e-223: tmp = math.pow((2.0 * (U * (n * t))), 0.5) else: tmp = math.sqrt((2.0 * n)) * math.sqrt((U * t)) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (n <= 2.15e-223) tmp = Float64(2.0 * Float64(U * Float64(n * t))) ^ 0.5; else tmp = Float64(sqrt(Float64(2.0 * n)) * sqrt(Float64(U * t))); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (n <= 2.15e-223) tmp = (2.0 * (U * (n * t))) ^ 0.5; else tmp = sqrt((2.0 * n)) * sqrt((U * t)); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[n, 2.15e-223], N[Power[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], N[(N[Sqrt[N[(2.0 * n), $MachinePrecision]], $MachinePrecision] * N[Sqrt[N[(U * t), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;n \leq 2.15 \cdot 10^{-223}:\\
\;\;\;\;{\left(2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)}^{0.5}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{2 \cdot n} \cdot \sqrt{U \cdot t}\\
\end{array}
\end{array}
if n < 2.15e-223Initial program 53.8%
Simplified57.3%
Taylor expanded in l around 0 42.0%
pow1/242.7%
Applied egg-rr42.7%
if 2.15e-223 < n Initial program 53.7%
Simplified57.0%
Taylor expanded in l around 0 36.8%
*-commutative36.8%
Applied egg-rr36.8%
associate-*l*36.7%
Simplified36.7%
pow1/237.6%
associate-*r*37.6%
unpow-prod-down44.5%
pow1/244.5%
*-commutative44.5%
pow1/243.6%
*-commutative43.6%
Applied egg-rr43.6%
Final simplification43.1%
(FPCore (n U t l Om U*) :precision binary64 (if (<= n 1.75e-223) (pow (* 2.0 (* U (* n t))) 0.5) (* (sqrt n) (sqrt (* 2.0 (* U t))))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (n <= 1.75e-223) {
tmp = pow((2.0 * (U * (n * t))), 0.5);
} else {
tmp = sqrt(n) * sqrt((2.0 * (U * t)));
}
return tmp;
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
real(8) :: tmp
if (n <= 1.75d-223) then
tmp = (2.0d0 * (u * (n * t))) ** 0.5d0
else
tmp = sqrt(n) * sqrt((2.0d0 * (u * t)))
end if
code = tmp
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
double tmp;
if (n <= 1.75e-223) {
tmp = Math.pow((2.0 * (U * (n * t))), 0.5);
} else {
tmp = Math.sqrt(n) * Math.sqrt((2.0 * (U * t)));
}
return tmp;
}
def code(n, U, t, l, Om, U_42_): tmp = 0 if n <= 1.75e-223: tmp = math.pow((2.0 * (U * (n * t))), 0.5) else: tmp = math.sqrt(n) * math.sqrt((2.0 * (U * t))) return tmp
function code(n, U, t, l, Om, U_42_) tmp = 0.0 if (n <= 1.75e-223) tmp = Float64(2.0 * Float64(U * Float64(n * t))) ^ 0.5; else tmp = Float64(sqrt(n) * sqrt(Float64(2.0 * Float64(U * t)))); end return tmp end
function tmp_2 = code(n, U, t, l, Om, U_42_) tmp = 0.0; if (n <= 1.75e-223) tmp = (2.0 * (U * (n * t))) ^ 0.5; else tmp = sqrt(n) * sqrt((2.0 * (U * t))); end tmp_2 = tmp; end
code[n_, U_, t_, l_, Om_, U$42$_] := If[LessEqual[n, 1.75e-223], N[Power[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision], N[(N[Sqrt[n], $MachinePrecision] * N[Sqrt[N[(2.0 * N[(U * t), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]), $MachinePrecision]]
\begin{array}{l}
\\
\begin{array}{l}
\mathbf{if}\;n \leq 1.75 \cdot 10^{-223}:\\
\;\;\;\;{\left(2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)}^{0.5}\\
\mathbf{else}:\\
\;\;\;\;\sqrt{n} \cdot \sqrt{2 \cdot \left(U \cdot t\right)}\\
\end{array}
\end{array}
if n < 1.75000000000000005e-223Initial program 53.8%
Simplified57.3%
Taylor expanded in l around 0 42.0%
pow1/242.7%
Applied egg-rr42.7%
if 1.75000000000000005e-223 < n Initial program 53.7%
Simplified57.0%
Taylor expanded in l around 0 36.8%
associate-*r*36.5%
*-commutative36.5%
Applied egg-rr36.5%
pow1/237.4%
associate-*r*37.4%
associate-*r*37.4%
*-commutative37.4%
associate-*r*37.6%
metadata-eval37.6%
associate-*l*37.6%
unpow-prod-down44.5%
metadata-eval44.5%
pow1/244.5%
metadata-eval44.5%
Applied egg-rr44.5%
unpow1/243.6%
Simplified43.6%
(FPCore (n U t l Om U*) :precision binary64 (pow (* 2.0 (* U (* n t))) 0.5))
double code(double n, double U, double t, double l, double Om, double U_42_) {
return pow((2.0 * (U * (n * t))), 0.5);
}
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 * (u * (n * t))) ** 0.5d0
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
return Math.pow((2.0 * (U * (n * t))), 0.5);
}
def code(n, U, t, l, Om, U_42_): return math.pow((2.0 * (U * (n * t))), 0.5)
function code(n, U, t, l, Om, U_42_) return Float64(2.0 * Float64(U * Float64(n * t))) ^ 0.5 end
function tmp = code(n, U, t, l, Om, U_42_) tmp = (2.0 * (U * (n * t))) ^ 0.5; end
code[n_, U_, t_, l_, Om_, U$42$_] := N[Power[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision], 0.5], $MachinePrecision]
\begin{array}{l}
\\
{\left(2 \cdot \left(U \cdot \left(n \cdot t\right)\right)\right)}^{0.5}
\end{array}
Initial program 53.8%
Simplified57.1%
Taylor expanded in l around 0 39.7%
pow1/240.5%
Applied egg-rr40.5%
(FPCore (n U t l Om U*) :precision binary64 (sqrt (* (* n t) (* 2.0 U))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
return sqrt(((n * t) * (2.0 * U)));
}
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(((n * t) * (2.0d0 * u)))
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
return Math.sqrt(((n * t) * (2.0 * U)));
}
def code(n, U, t, l, Om, U_42_): return math.sqrt(((n * t) * (2.0 * U)))
function code(n, U, t, l, Om, U_42_) return sqrt(Float64(Float64(n * t) * Float64(2.0 * U))) end
function tmp = code(n, U, t, l, Om, U_42_) tmp = sqrt(((n * t) * (2.0 * U))); end
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(N[(n * t), $MachinePrecision] * N[(2.0 * U), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
\\
\sqrt{\left(n \cdot t\right) \cdot \left(2 \cdot U\right)}
\end{array}
Initial program 53.8%
Simplified57.1%
Taylor expanded in l around 0 39.7%
associate-*r*39.7%
Applied egg-rr39.7%
Final simplification39.7%
(FPCore (n U t l Om U*) :precision binary64 (sqrt (* 2.0 (* U (* n t)))))
double code(double n, double U, double t, double l, double Om, double U_42_) {
return sqrt((2.0 * (U * (n * t))));
}
real(8) function code(n, u, t, l, om, u_42)
real(8), intent (in) :: n
real(8), intent (in) :: u
real(8), intent (in) :: t
real(8), intent (in) :: l
real(8), intent (in) :: om
real(8), intent (in) :: u_42
code = sqrt((2.0d0 * (u * (n * t))))
end function
public static double code(double n, double U, double t, double l, double Om, double U_42_) {
return Math.sqrt((2.0 * (U * (n * t))));
}
def code(n, U, t, l, Om, U_42_): return math.sqrt((2.0 * (U * (n * t))))
function code(n, U, t, l, Om, U_42_) return sqrt(Float64(2.0 * Float64(U * Float64(n * t)))) end
function tmp = code(n, U, t, l, Om, U_42_) tmp = sqrt((2.0 * (U * (n * t)))); end
code[n_, U_, t_, l_, Om_, U$42$_] := N[Sqrt[N[(2.0 * N[(U * N[(n * t), $MachinePrecision]), $MachinePrecision]), $MachinePrecision]], $MachinePrecision]
\begin{array}{l}
\\
\sqrt{2 \cdot \left(U \cdot \left(n \cdot t\right)\right)}
\end{array}
Initial program 53.8%
Simplified57.1%
Taylor expanded in l around 0 39.7%
herbie shell --seed 2024096
(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*))))))