A limit of the hypergeometric function

120 Views Asked by At

I am hardly a mathematician, but I am trying to compute (in R, if that matters) and for $s, v > 0$ the expression

$_2F_1(s, s, s + 1, -v) \cdot v^s / s$.

(Why? I want to to evaluate $\int \frac{1}{(1 + \exp(-x))^s} dx$ over real $x$ and $s$, and Wolfram Alpha gave me this expression.)

For most numbers, this works fine. I hit problems when "$v = \infty$" (that is, $v > 1e308$), which I solved using the approximation

$\ln(v) - \psi(s) - \gamma$, which I can compute since $v = \exp(x)$.

Now, I hit further trouble in other extreme cases, e.g., $(v, s) = (1e4, 100)$. In this case, the result is approximately 4.04 (Wolfram Alpha), but of course I won't find that since $v^s = 1e400 >> 1e308$. Similarly, I won't be able to find the result of $_2F_1(s, s, s + 1, -v)$: it's pretty much zero for any standard floating point number.

So now I am looking for another approximation for large $s$, and I thought about looking at

$\lim_{s \to \infty} {_2}F_1(s, s, s + 1, -v) \cdot v^s / s$

or

$\lim_{s \to \infty} {_2}F_1(s, s, s + 1, -v) \cdot v^s$.

Can this be simplified? Or will this help in any other way?

2

There are 2 best solutions below

0
On BEST ANSWER

This appeared as a comment, and upon the proper's suggestion, has been converted to an answer:

I would first look at the linear transformation formulas; e.g., Digital Library of Mathematical Functions, 15.8.1 One transformation puts the argument in the form of −v/(1+v), which is close to -1 for large positive v. Another formula, 15.8.2, puts the argument in terms of 1/v, so if v is always large,s bounded and not an integer, then the sum will be short and easy to calculate. Finally, it appears you have a situation where v and s are both large, so you may need to consult section 15.12

4
On

I do not know how much this could help you.

Years ago, I faced a similar problem for large $v$ and used (almost from definition) $$\, _2F_1(s,s;s+1;-v)\,\frac{v^s }{s}=\log(1+v)-\psi (s)-\gamma+\sum_{n=1}^p(-1)^n\frac{ n!-\frac{\Gamma (n+s)}{\Gamma (s)}}{n\, n!}\frac 1 {v^n}+O\left(\frac{1}{v^{p+1}}\right)$$ which, at least for my needs, converges quite fast.

Trying for $v=10^4$ and $s=10^2$, as a function of $p$, we get the following results $$\left( \begin{array}{cc} p & \text{result} \\ 1 & 4.042962849 \\ 2 & 4.042937604 \\ 3 & 4.042937662 \\ 4 & 4.042937661 \end{array} \right)$$ Trying for $v=10^4$ and $s=10^4$ $$\left( \begin{array}{cc} p & \text{result} \\ 1 & 0.4228343309 \\ 2 & 0.1728093359 \\ 3 & 0.2283815593 \\ 4 & 0.2179586415 \\ 5 & 0.2196269754 \\ 6 & 0.2193951465 \\ 7 & 0.2194235507 \\ 8 & 0.2194204418 \\ 9 & 0.2194207491 \\ 10 & 0.2194207214 \\ 11 & 0.2194207237 \\ 12 & 0.2194207236 \end{array} \right)$$

Edit

Doing what you suggest in comments, this could also write as $$\, _2F_1(s,s;s+1;-v)\,\frac{v^s }{s}=\log(v)-\psi (s)-\gamma+s\sum_{n=1}^p (-1)^{n-1}\frac{ (s+1)_{n-1}}{n\,n!}\frac 1 {v^n}+O\left(\frac{1}{v^{p+1}}\right)$$ What we can notice is that, for large values of $s$ $$\frac{ (s+1)_{n-1}}{n\,n!}=(n-1)\log(s)+O\left(\frac{1}{s}\right)$$