No one asked what I was doing with 120,526,770 records
Kenneth Brody
kenbrody at bestweb.net
Sun Feb 13 11:04:52 PST 2005
Quoting "Jay R. Ashworth" <jra at baylink.com>:
[...]
> > You want _combinations_, not _permutations_. Unless this powerball
> > requires that you pick the numbers in the _same_order_, you need to
> > divide by 5! for a 5-ball game.
> >
> > 14,463,212,400 / 5! = 120,526,770
>
> It's not a permutations thing. It's a "the ball you just picked isn't
> in the hopper anymore" thing. The first pick is 1 ball in 53. The
> second pick is therefore 1 ball in 52, and so forth. IE: the Factorial
> already *handled* that issue, and you don't need to do it again.
>
> I may still be wrong, but I'm afraid it's going to take a bigger 2x4 to
> explain it to me than that, Ken. :-)
But it's important that the order isn't important. ;-)
The number of _permutations_ of X items out of Y is:
Y! / (Y-X)!
The number of _combinations_ of X items out of Y is:
( Y! / (Y-X)! ) / X!
Here's my new 2x4:
Let's simplify the original problem. Rather than 5 items out of 52,
let's take 5 items out of 5.
According to your logic, "the first ball is one in 5", "the second
ball is one in 4", and so on, giving us 1 in (5*4*3*2*1) or 1 in 120.
I think you can see that this is obviously incorrect, since how many
different sets of "winning numbers" would there be? There can only
be one set of "winning numbers" picked, as you picked every number.
If the _order_ made a difference (ie: you specify "this is the first
number to be picked, this is the second, and so on") then there would
be a 1-in-120 chance. However, since order is not significant, and
you only say "this number will be picked at some point", you need to
divide by X!.
--
KenBrody at BestWeb dot net spamtrap: <g8ymh8uf001 at sneakemail.com>
http://www.hvcomputer.com
http://www.fileProPlus.com
More information about the Filepro-list
mailing list