# Why won't Limit evaluate, and what can be done about it

I am trying to evaluate $$\lim_{n\to \infty }\sqrt{n}{{n}\choose {[np + \sqrt{np(1-p)}]}}p^{[np + \sqrt{np(1-p)}]}(1-p)^{(n-[np + \sqrt{np(1-p)}])}$$ where $0<p<1$ and $[\cdot ]$ denotes the nearest integer (if it greatly simplifies things at no cost, I don't mind if $[\cdot]$ is removed):

Limit[Sqrt[n ] Binomial[n, Round[n p + Sqrt[n p (1 - p)]]] p^
Round[n p + Sqrt[n p (1 - p)]] (1 - p)^(
n -  Round[n p - Sqrt[n p (1 - p)]] ), n -> Infinity]


Mathematica (version 11.0, Student Edition) gives the input as the answer. This limit is of the type $0\times \infty$.

In hopes of simplifying things, I removed the nearest integer function in both of the exponents, but the same issue occurs:

Limit[Sqrt[n ] Binomial[n, Round[n p + Sqrt[n p (1 - p)]]] p^(
n p + Sqrt[n p (1 - p)]) (1 - p)^(n -  n p - Sqrt[n p (1 - p)] ),
n -> Infinity, Assumptions -> 0 < p < 1]


Other Ideas: (1) I tried computing limits of products separately, but $\sqrt{n}p^{np + \sqrt{np(1-p)}}\to 0$ while the remaining product tends ComplextInfinity.

(2) I tried using bounds on the binomial coeffiecient: ${{a}\choose{b}}\le \frac{a^b}{b!}\le (\frac{a *e}{b})^b$, but the same issue occurs here when I use either of these upper bounds in place of the binomial coefficient:

Limit[Sqrt[n ] (n ^(n p + Sqrt[n p (1 - p)])/
Gamma[1 + n p + Sqrt[n p (1 - p)]]) p^(
n p + Sqrt[n p (1 - p)]) (1 - p)^(n -  n p - Sqrt[n p (1 - p)] ),
n -> Infinity, Assumptions -> 0 < p < 1]


and

Limit[Sqrt[n ] ((n E)/(n p + Sqrt[n p (1 - p)]))^(
n p + Sqrt[n p (1 - p)]) p^(n p + Sqrt[n p (1 - p)]) (1 - p)^(
n -  n p - Sqrt[n p (1 - p)] ), n -> Infinity,
Assumptions -> 0 < p < 1]


Follow up: Is there other software that is better at evaluating limits?

• Judging from the interpolation function I made of this, I don't think there's an answer to be honest. – Feyre Dec 31 '16 at 13:13
• @Feyre .5? Are you getting that from your interpolation? Can you post the code for what you did? – The Substitute Dec 31 '16 at 13:39
• Oh, that was with later code, the original code tends clearly to 0. Just try tab = Table[{p, Sqrt[n] Binomial[n, Round[n p + Sqrt[n p (1 - p)]]] p^ Round[n p + Sqrt[n p (1 - p)]] (1 - p)^(n - Round[n p - Sqrt[n p (1 - p)]])} /. n -> 10^7, {p, 0.01, 0.99, 0.01}];,ListPlot[tab, PlotRange -> All] – Feyre Dec 31 '16 at 13:48
• Make sure you seperate the two codes, first the tab=table[], then in different line the Listplot[] – Feyre Dec 31 '16 at 14:02
• maybe try math.stackexchange, it might be enlightening to learn how to formally,rigorously take the limit. – george2079 Jan 2 '17 at 14:29

If we remove Round, Series (around $n\to\infty$) does the trick:

$Assumptions = n \[Element] Integers && n > 2 && 0 < p < 1; Series[Sqrt[n] Binomial[n,(n p+Sqrt[n p(1-p)])] p^(n p+Sqrt[n p(1-p)])(1-p)^(n-(n p-Sqrt[n p(1-p)])), {n, Infinity, 0}] Simplify[%] // Normal Limit[%, n -> \[Infinity]] (*0*)  This works for all$0<p<1$. For$p\equiv0$, Limit[Sqrt[n] Binomial[n,(n p+Sqrt[n p(1-p)])] p^(n p+Sqrt[n p(1-p)]) (1-p)^(n-(n p-Sqrt[n p(1-p)])), p -> 0] (*Sqrt[n]*)  and therefore the limit diverges (the exact same thing happens for$p\equiv 1$). • Thank you! What do you mean by "around$n \to \infty$?" Does that mean that the center of the series is changing? If so, are we still allowed to apply the divergence test to my sequence in that case? – The Substitute Jan 2 '17 at 20:22 • @TheSubstitute around$n\to\infty$means that we execute Series[...,{n,∞,0}]. In more mathematical terms,$f(n)\overset{n\to\infty}=f(\infty)+\mathcal O(1/n)$. – AccidentalFourierTransform Jan 2 '17 at 20:24 expr = Sqrt[n] * Binomial[n, Round[n p + Sqrt[n p (1 - p)]]] * p^Round[n p + Sqrt[n p (1 - p)]] * (1 - p)^(n - Round[n p - Sqrt[n p (1 - p)]]); Needs["NumericalCalculus"]; Table[ {p, NLimit[expr, n -> Infinity, WorkingPrecision -> #] & /@ {15, 20, 25}} // Flatten, {p, 1/10, 9/10, 1/20}] // Grid Increasing the WorkingPrecision produces progressively smaller values which supports the Limit being zero. • although this is very helpful, I really want to see if the limit is 0 for all$p$in$(0,1)\$. – The Substitute Jan 2 '17 at 8:40

Actually Limit works if you just get rid of the Round.

Limit[Sqrt[n] Binomial[n, n p + Sqrt[n p (1 - p)]]
p^(n p + Sqrt[n p (1 - p)]) (1 - p)^(n - (n p - Sqrt[n p (1 - p)])),
n -> Infinity, Assumptions -> 0 < p < 1]
`

0

Note for p near zero the limit is approached very slowly (just looking at it numerically)

• When I enter this into Mathematica (11.0, student edition), the output is the same as the input. – The Substitute Jan 3 '17 at 23:29
• 10.1 here, must be a version issue. – george2079 Jan 3 '17 at 23:38