From: Ray Vickson on
On Jul 16, 12:06 am, Mike Harrison <mjh...(a)yahoo.co.uk> wrote:
> On Jul 16, 7:08 am, "porky_pig...(a)my-deja.com" <porky_pig...(a)my-
>
> deja.com> wrote:
> > Now. to win exactly 3 out of 8 times means 3 wins and 5 losses,
> > probability of that is
> > (p^3) (q^5) = (0.008^3)(0.992^5). This 3 out of 5 wins can happen in
> > 8C3 ("8 choose 3") ways.
> > You can look up the formula. 8C3 = (8!) / (3! (8-3)!). So you have to
> > multiply by 8C3 and so the answer is
> > (8C3) (0.008^3) (0.992^5).
>
> Thanks. So I make that 2.754e-5 or 1-in-36306, is that right?
>
> And the calculation for at least 3 out of 8 is:
>
> (8C3) (0.008^3) (0.992^5) +
> (8C4) (0.008^4) (0.992^4) +
> (8C5) (0.008^5) (0.992^3) +
> (8C6) (0.008^6) (0.992^2) +
> (8C7) (0.008^7) (0.992^1) +
> (8C8) (0.008^8) (0.992^0)
>
> = 2.782e-5 or 1-in-35942.
>
> Which seems hardly any more likely than the 3 out of 8 on its own. I
> suppose that's because the chances of getting more than 3 quickly
> become extremely small.
>
> I hope I've calculated it right anyway.

Here is the computation in Maple 9.5:
n:=8; p:=1.0/125;
n := 8
p := 0.008000000000

for k from 0 to n do P[k]:=binomial(n,k)*p^k*(1-p)^(n-k): end do:
Here is the formatted output:
k Pr{k}
0 9.377636e-01
1 6.050088e-02
2 1.707686e-03
3 2.754332e-05
4 2.776545e-07
5 1.791319e-09
6 7.223061e-12
7 1.664300e-14
8 1.677722e-17

Pr(>=3) = sum(P[k],k=3..8) = 2.782277689e-03; as you say, this is not
much larger than P{=3} because the other terms P[k] for k from 4 to 8
are small.

R.G. Vickson