# Efficient numeric routines for computing $_2F_0$

As part of a project related to kinematic fluid dynamics, the following integral appeared in the moment expansion $$\int_0^{\alpha} t^m\,_2F_0\left(\begin{matrix}-\ell-\frac{1}{2},m+2\\-\end{matrix};\frac{t-1}{\epsilon}\right)dt$$ Now while I have no illusions that this has a closed form, it is sufficient to be able to evaluate it numerically. Since $\alpha$ is usually positive and not large compared to 1, a numeric integration should be fairly efficient provided there is an efficient way to calculate $_2F_0$. Unfortunately, I can't seem to find good routines to do that. Most special function packages have the related function $_1U_1$, but that often requires evaluating it at very large arguments, raising concerns about accuracy.

Does anyone know of a good numerical method for calculation $_2F_0$ directly?

• "that often requires evaluating it at very large arguments" - well, the asymptotic behavior of the Tricomi function is rather well-known, so why not just convert your integral for ${}_2 F_0$ into an integral for $U$ and then use an integrator that is robust to singularities? – J. M. isn't a mathematician Oct 27 '17 at 3:10

I use the following, which is quite efficient for computing $_2F_0(a,b,z)$:
-- If z is real, return $(-z)^{-a}U(a,1+a-b,-1/z)$, where $U$ is the function you mention.
-- Otherwise (or if z is too close to 0) use the double-exponential method to compute $$\int_0^\infty e^{-t}t^{a-1}(1-zt)^{-b}\,dt/\Gamma(a)$$