Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

For example, how many times ($N$) do I need to flip a coin ($p=0.5$) to have a $P=90\%$ probability of having observed $20$ heads. I empirically found that I need $N=20+28=48$. Is it correct?

Is there an explicit formula for the Negative binomial inverse cumulative function?

share|cite|improve this question
If you have MATLAB, see – Shai Covo Jan 26 '11 at 1:23
I use Maple (statevalf,idcdf,negativebinomial) but I would like to know if there is an explicit formula. – Jean-Pierre Jan 26 '11 at 1:47
up vote 1 down vote accepted

We know that $F(k) = P(X \leq k) = 1-I_{p}(k+1,r)$ where $I_{p}(k+1,r)$ is the incomplete beta function. So $0.9 = 1-I_{0.5}(k+1,r)$. From this, I believe you have enough information to get $k$ and $r$ and hence $n$.

share|cite|improve this answer
Thank you for your answer. I know how to compute the incomplete beta from k and r but I can not see how to compute k and r from the value of the incomplete beta. what did I miss? – Jean-Pierre Jan 26 '11 at 1:41

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.