Friday, October 3, 2008

-swErtRez tA diRi-

"Lottery Math"
(come to think of it)
The odds of a "Lotto" style lottery can be found with the formula: n! / (n - r)! r! where n is the highest numbered ball and r is the number of balls chosen. This is called in math a combination. An easier way to think about it is if there are 40 balls and 6 are chosen, there are 40 possible numbers that can come up first, leaving 39 that can come up second, then 38, 37, 36, and finally 35 on the final number. To find out how many numbers that is you multiply 40 ×39 ×38 ×37 ×36 × 35 = 2,763,633,600 making the odds 2 and a half billion to one.
Pretty slim odds, but luckily the order of the balls does not matter, so we can divide this number by how many ways these numbers can be arranged. There are six possibilities for the first ball, five for the second, 4 for the third, 3, 2, and one left over. That is 6 × 5 × 4 × 3 × 2 × 1 = 720 So, the odds are 2,763,633,600 ÷ 720 = 3,838,380 to one.
If I put Php 500 on one lottery, the odds of winning are 3,838,380 ÷ 50 = 76767.6 to one.
That is the easy part!!
The hard part is calculating the odds of winning if I put Php 10 on 50 lotteries. To do this we have to convert to probabilities. A probability is a number between 1 and 0. 1 means a perfect chance, 0 means no chance at all. The probability of winning the lottery with ten pesos is 1 ÷ 3,838,380 = 0.0000002605... in other words, very small. The probability of winning the lottery with 500 pesos is 1 ÷ 76767.6 = 0.0000130263288...
Just for your information, the probability of winning twice in a row is this number squared which is 0.00000000000006. This is not very useful information except that we can use this formula in reverse to get what we want. The cool thing about probabilities, as opposed to odds, is that the probability of winning is one minus the probability of losing. This leads us to a way of calculating what we want by using a double negative.
The probability of winning at least once in 50 tries is the same as the probability of not losing 50 times in a row.
The probability of losing is 1 - 0.0000002605... = 0.9999997394... The probability of losing 50 times in a row is 0.9999997394 to the 50th power = 0.99998697... The probability of not losing 50 times in a row is 1 - 0.99998697 = 0.0000130262457...
So, since the probability of winning at least once in 50 tries is 0.0000130262457 and the probability of winning one lottery with 500 pesos is 0.0000130263288... The odds are very very slightly more favorable by playing all 500 pesos in one lottery than spreading it out among 50 lotteries.
-wacha think?-