3

I was solving a probability problem and I got a different answer than the one given in the book. Seems the authors were using a different way of counting/arguing.

For the two answers to be equal, the following equality should hold true.

$$\sum_{k=0}^{b-1} \binom{a+k-1}{a-1} p^a (1-p)^k = \sum_{k=a}^{a+b-1} \binom {a+b-1}{k} p^{k} (1-p)^{a+b-k-1}$$

How can this be proved?

And the problem itself was: in a series of Bernoulli trials with probability for success in a single trial equal to $p$, what is the probability to get $a$ successes before getting $b$ failures?

I think you guys will reverse engineer how I counted and how the authors counted.

peter.petrov
  • 12,568
  • @callculus I think the address function works even if there are no comments from the person in question. Not sure about that... – lulu Sep 03 '18 at 21:13
  • @callculus it works! That is, I got notified of your comment. – lulu Sep 03 '18 at 21:19
  • @callculus Ah, true. I missed one. But, on reflection, I sometimes cite other users responses to other posts and I use the address system to refer to them so they know they are being quoted. That appears to work. – lulu Sep 03 '18 at 21:24
  • @lulu It sounds tricky. – callculus42 Sep 03 '18 at 21:27
  • @peter.petrov Perhaps I am making arithmetic blunders but this seems false. If we take $p=\frac 12$ and $a=b$ the answer should clearly be $\frac 12$ by symmetry. If we take $a=b=2$ we do indeed get $\frac 12$ on the left, But on the right we get $\frac 68$. Or have I messed it up? – lulu Sep 03 '18 at 21:38
  • 1
    @lulu Hmm, interesting. OK, I'll also try a few corner cases. By the way my answer is on the left. No wait, it is not 6/8, it is 4/8 on the right in that corner case you described. – peter.petrov Sep 03 '18 at 21:44
  • I was able to verify it also for $a=2, b=4, p=1/2$. In this case both sides are equal to $13/16$. So it seems like it is a true equality indeed. – peter.petrov Sep 03 '18 at 22:00
  • I was also able to verify it for $a=3, b=2, p=3/4$ Well, OK. I have no proof yet but at least I am more confident now in the correctness of my answer. It would be great if someone can provide a general proof. Interesting indeed... – peter.petrov Sep 03 '18 at 22:08
  • Right, I had my example wrong. – lulu Sep 03 '18 at 23:05

3 Answers3

3

This is a nice question!

The short answer is: You've already proved it! By showing that the two sides are different counts of the same thing, you've proved that they're equal.

On the assumption that you're looking for an algebraic proof, here's a longer answer. Since on the left you only consider as many trials as you need until the result is decided, whereas on the right the authors consider all $a+b-1$ trials until the result is decided no matter what it is, we can transform your sum into their sum by adding the missing irrelevant $b-k-1$ trials:

\begin{eqnarray*} \sum_{k=0}^{b-1}\binom{a+k-1}{a-1}p^a(1-p)^k &=& \sum_{k=0}^{b-1}\binom{a+k-1}{a-1}p^a(1-p)^k1^{b-k-1} \\ &=& \sum_{k=0}^{b-1}\binom{a+k-1}{a-1}p^a(1-p)^k(p+(1-p))^{b-k-1} \\ &=& \sum_{k=0}^{b-1}\binom{a+k-1}{a-1}p^a(1-p)^k\sum_{j=0}^{b-k-1}\binom{b-k-1}jp^j(1-p)^{b-k-1-j} \\ &=& \sum_{k=0}^{b-1}\sum_{j=0}^{b-k-1}\binom{a+k-1}{a-1}p^a(1-p)^k\binom{b-k-1}jp^j(1-p)^{b-k-1-j} \\ &=& \sum_{j=0}^{b-1}\sum_{k=0}^{b-j-1}\binom{a+k-1}{a-1}p^a(1-p)^k\binom{b-k-1}jp^j(1-p)^{b-k-1-j} \\ &=& \sum_{j=0}^{b-1}p^ap^j(1-p)^{b-1-j}\sum_{k=0}^{b-j-1}\binom{a+k-1}{a-1}\binom{b-k-1}j \\ &=& \sum_{j=0}^{b-1}p^ap^j(1-p)^{b-1-j}\sum_{k=0}^{b-j-1}\binom{b-k-1}{b-j-1-k}\binom{a+k-1}k \\ &=& \sum_{j=0}^{b-1}p^ap^j(1-p)^{b-1-j}\binom{a+b-1}{b-j-1} \\ &=& \sum_{j=0}^{b-1}p^ap^j(1-p)^{b-1-j}\binom{a+b-1}{a+j} \\ &=& \sum_{k=a}^{a+b-1}\binom{a+b-1}kp^k(1-p)^{a+b-k-1}\;, \end{eqnarray*}

where the inner sum is evaluated using the relationship

$$ \sum_{k=0}^n\binom{x+n-k-1}{n-k}\binom{y+k-1}k=\binom{x+y+n-1}n\;, $$

of which several proofs are given at Proving that ${x +y+n- 1 \choose n}= \sum_{k=0}^n{x+n-k-1 \choose n-k}{y+k-1 \choose k} $.

joriki
  • 238,052
2

I didn't post this because joriki posted first and his answer is essentially the same (+1). However, since some explanation of the steps might be useful, I will post mine to provide an explanation for his steps. $$ \begin{align} &\sum_{k=0}^{b-1}\binom{a+k-1}{a-1}p^a(1-p)^k\tag1\\ &=\sum_{k=0}^{b-1}\binom{a+k-1}{a-1}p^a(1-p)^k(p+(1-p))^{b-k-1}\tag2\\ &=\sum_{k=0}^{b-1}\sum_{j=0}^{b-k-1}\binom{a+k-1}{a-1}\binom{b-k-1}{j}p^a(1-p)^kp^j(1-p)^{b-j-k-1}\tag3\\ &=\sum_{j=0}^{b-1}\sum_{k=0}^{b-j-1}\binom{a+k-1}{a-1}\binom{b-k-1}{j}p^{a+j}(1-p)^{b-j-1}\tag4\\ &=\sum_{j=0}^{b-1}\binom{a+b-1}{a+j}p^{a+j}(1-p)^{b-j-1}\tag5\\ &=\sum_{j=a}^{a+b-1}\binom{a+b-1}{j}p^{j}(1-p)^{a+b-j-1}\tag6 \end{align} $$ Explanation:
$(2)$: multiply by $1=(p+(1-p))^{b-k-1}$
$(3)$: apply the Binomial Theorem to $(p+(1-p))^{b-k-1}$
$(4)$: switch order of summation and combine terms
$(5)$: sum in $k$ using $\sum_{k=0}^{b-c}\binom{a+k}{a}\binom{b-k}{c}=\binom{a+b+1}{a+c+1}$
$(6)$: substitute $j\mapsto j-a$

robjohn
  • 345,667
1

Starting from

$$\sum_{k=0}^{b-1} {a+k-1\choose a-1} p^a (1-p)^k = \sum_{k=a}^{a+b-1} {a+b-1\choose k} p^k (1-p)^{a+b-k-1}$$

we simplify to

$$\sum_{k=0}^{b-1} {a+k-1\choose a-1} p^a (1-p)^k = \sum_{k=0}^{b-1} {a+b-1\choose a+k} p^{a+k} (1-p)^{b-k-1}$$

or

$$\sum_{k=0}^{b-1} {a+k-1\choose a-1} (1-p)^k = \sum_{k=0}^{b-1} {a+b-1\choose a+k} p^k (1-p)^{b-k-1}.$$

We get for the LHS

$$\sum_{k\ge 0} {a+k-1\choose a-1} (1-p)^k [[0\le k\le b-1]] \\ = \sum_{k\ge 0} {a+k-1\choose a-1} (1-p)^k [z^{b-1}] \frac{z^k}{1-z} \\ = [z^{b-1}] \frac{1}{1-z} \sum_{k\ge 0} {a+k-1\choose a-1} (1-p)^k z^k \\ = [z^{b-1}] \frac{1}{1-z} \frac{1}{(1-(1-p)z)^a}.$$

The RHS is

$$\sum_{k=0}^{b-1} p^k (1-p)^{b-k-1} [z^{b-1-k}] \frac{1}{(1-z)^{a+k+1}} \\ = [z^{b-1}] \frac{1}{(1-z)^{a+1}} \sum_{k=0}^{b-1} p^k (1-p)^{b-k-1} \frac{z^k}{(1-z)^{k}}.$$

There is no contribution to the coefficient extractor in front when $k\gt b-1$ and we may extend $k$ to infinity, getting

$$(1-p)^{b-1} [z^{b-1}] \frac{1}{(1-z)^{a+1}} \sum_{k\ge 0} p^k (1-p)^{-k} \frac{z^k}{(1-z)^{k}} \\ = (1-p)^{b-1} [z^{b-1}] \frac{1}{(1-z)^{a+1}} \frac{1}{1-pz/(1-p)/(1-z)} \\ = (1-p)^{b-1} [z^{b-1}] \frac{1}{(1-z)^a} \frac{1}{1-z-pz/(1-p)} \\ = [z^{b-1}] \frac{1}{(1-(1-p)z)^a} \frac{1}{1-(1-p)z-pz} \\ = [z^{b-1}] \frac{1}{1-z} \frac{1}{(1-(1-p)z)^a}.$$

The LHS and the RHS are seen to be the same and we may conclude.

Remark. The first one is the easy one and follows by inspection. The Iverson bracket may be of interest here as an example of the method.

Marko Riedel
  • 61,317