# Using Mathematics to Win the Lottery

Lottery Basics

Many of you are probably familiar how lottery works.  A lottery is a game where a smaller group of numbers is chosen from a larger group. If you bet on the right combination, you win the jackpot prize, which is usually staggering.

Although there is a common concept about lottery, there are variations in different places or countries.  In this post, I will use ours as an example. In the Philippines, as of this writing, we have three types of lottery: 6/42, 6/45 and 6/49. Yes, you guessed it right, 6/42 means 6 numbers are randomly chosen from a set of numbers from 1 through 42. We use the 6/42 lottery in the following discussion.

In our country, the process of choosing numbers in a lottery is shown on television.  First, balls of the same weight numbered from 1 through 42 are placed in a machine-operated transparent container. Next, the balls are mixed using a blower located at the bottom of the container. These balls are light enough to be floated by the air from the blower. Finally to determine the winning combination, a button is pushed to eject 6 balls, one after the other. See video below.

Now, suppose we bought a ticket of the 6/42 lottery, what is our chance of winning? Is there a way that we can win for sure?

We will answer the first question later. For the second question, yes, there is a way and, in principle, it’s simple. Just bet on all the possible number combinations.

Okay, so you’re not a math major and you do not know what I am talking about. Well, let me explain it in plain language. Suppose a mini-lottery has 5 numbers, say 1 through 5, and two numbers are drawn to determine the winner. The pair, {1,2} is a possible bet as well as {4,3}.  It is clear that the order of the numbers chosen does not matter, so betting on {5,2} is the same as betting on {2,5}.

Finding all the possible pairs or combinations in the 2/5 mini-lottery is a bit easy.  As we can see from the table, if we choose two numbers from 5 choices, we have 10 possible combinations or pairs (see red text). The pairs in black texts are just the reverse of those in red.  We did not also include the pair having the same number, say (2,2), because in a lottery draw, drawn balls are not returned back into the container before drawing the next ball.

If we buy 10 tickets and bet on all the 10 pairs on the table, surely, we will win. We will use the same principle in winning the 6/42 lottery draw.

Systematic Betting

It is very hard to use the strategy above if we have six numbers taken from 42.  There is no easy way to tally our bets.  However, we can use a computer in finding all the possible number combinations. The method below maybe done:

1. We can start with 1,2,3,4,5,6, then 1,2,3,4,5, 7, and then 1,2,3,4,5,6,8 all the way up to 1, 2, 3, 4, 5, 42.
2. After that, we can increase the fifth digit by 1 and we start with 1, 2, 3, 4, 6, 7, and then 1, 2, 3, 4, 6, 8, and so on. We can do this all the way to 1, 2, 3, 4, 6, 42.
3. When our sixth digit reached 42, we now increase the fifth digit by 1; that is, 1, 2, 3, 4, 7, 8; 1, 2, 3, 4, 7, 9 all the way up to 1, 2, 3, 4, 5, 7, 42.
4. Every time we increase the fifth digit by 1, we get the sixth digit by adding the fifth digit by 1, and then keep adding 1 until the sixth digit reached 42. For instance, 1, 2, 3, 4, 8, 9; 1, 2, 3, 4, 8, 10 all the way up to 1, 2, 3, 4, 8, 42. In varying the fifth digit, our last number would be 1, 2, 3, 4, 41, 42.
5. After the last combination is finished, we change the third digit: 1, 2, 4, 5, 6,  7 and so on…

Exercise:

Another mini-lottery has 5 balls and 3 balls to be drawn. List all the possible combinations. How many tickets should we buy for a sure win?

Winning the 6/42 lottery

In the 2/5 mini-lottery example above, we have two numbers chosen from a group of 5 numbers. This is equivalent to the combination of 5 numbers taken 2 at time.  We have learned from the Introduction to Combination post that 5 taken 2 at a time is equal to $\frac{5!}{(5-2)!2!} = 10$, and that can be verified from the table above. In the 6/42 lottery, 42 taken 6 is equal to $\frac{42!}{(42-6!)6!} =5,245,786$.  This means if we want a sure win, we must buy 5,245,786 tickets.

The Difficulties of Winning

There are, however, several difficulties in getting our fortune and becoming a millionaire, although it is definitely possible. Some of them are enumerated below.

1. Ticket Price. One 6/42 lottery ticket is 10 pesos as of this writing (note that it may increase in the future). This means that today we will need 52,457,860 pesos (about 1,165,000 US dollars) to buy all the tickets. Now you really have to be quite rich to have that kind of money.
2. Buying the Tickets. Assuming that we have the money, we also have a problem where to buy 5 million tickets. Suppose each lottery outlet has 5,000 tickets, we need to go to 1000 lottery outlets to buy all the tickets we need.
3. Time Filling Out the Tickets. If you are going to fill out 5,245,786 tickets alone, then you will probably not be able to do it. Assuming that you can fill out 1 ticket in 1 minute, then 5,245,786 minutes is equal to 3642.9 days or nearly 10 years: that is, without doing anything. If you are going to spend 8 hours a day filling out the ticket, like a regular working employee, you will triple the time above. You will finish filling the tickets out in 30 years!
4. Hiring People to Fill out the Tickets. Suppose we hire 100 people to solve problem 3, then, the 100 people will share the 3642.9 days x 24 hours/day = 87,429.6 hours. This means that each of the 100 person will work for about 874.3 hours, or about, 110 days in an 8-hour work day. So, if the salary of 1 person is Php450 a day, then, the money you need to pay them is 450/day x 110 days/person x 100 persons = Php4.9 million pesos. Well, it is not as expensive as the tickets, so we can afford it.
5. Number Combinations. We should also have a way of organizing our number combinations. Note that in the five million plus tickets, we must fill out our numbers accurately and without duplicates. The mini-lottery above can be easily listed, but we will need a computer program to enumerate the 5,245,786 combinations. Well, we can definitely afford a programmer since we are ready to spend more than 50 million pesos.
6. Prize money. Needless to say, if we want to spend 52 million pesos, the jackpot prize should be more than that.
7. More than 1 Jackpot prize winners. Even if the prize money is more than 50 million, we still have one problem.  If another person wins, we are in big trouble.  If the jackpot prize, for instance, is 100 million pesos, and there are three winners, each of the winners will only bag 33 million pesos, and we are 19 million pesos short.

Now, you probably understand why many mathematicians do not bother to buy lottery tickets, despite the fact that they know how to win. The answer to our second question above is that the chance of winning is 1 in 5,245,786.

What does that mean?

That means that if you buy a single 6-42 ticket and bet randomly 5,245,786 times, it is likely that you will win only once (well technically, that is a bit wrong, but I cannot use a better analogy). And, if the chance is so small, why is there that there is always a winner in almost every draw?

The Chance of Winning

Millions of people bet on lottery in each draw, so it is likely, that one or more would win. If 3 million people bet different combinations in one draw, that is equivalent to one person betting 3 million times which results to about 60% probability of winning. That is the reason that most of the time, there are lottery winners.

It has been done

Despite the numerous constraints, in 1995(?), two computer scientists from United States flew to Australia just to bet on a lottery (I saw the documentary several years ago).  They used a computer to systematically bet on all combinations. One employee from a lottery outlet was surprised when they told him that they were going to buy 100,000 tickets. The problem was they didn’t have enough tickets, so they had not bet on all possible number combinations.

They won anyway.

There is no secret to win a lottery.

There are websites that lure and convince people that they have apps or formulas that increase the chance of winning a lottery. These websites are definitely FAKE. Any high school student with good understanding of basic probability will tell you the same thing.

The only secret to increase your chance of winning is to buy more tickets. The more tickets you buy, the higher your chance of winning. In the 6-42 lottery above, if you are going to buy 2, 622, 893 tickets, then you have a 50% chance of winning. That means that in two bets, you are likely to win one jackpot prize.

***

Notes:

1. I am not really sure the process of lottery betting done in other countries, but here, first we buy tickets, then fill up our numbers of choice, then return it to the lottery outlet for processing. They place the ticket in a machine, and the machine ejects the receipt containing our number combinations. The receipt will be our official ticket.
2. Prices and exchange rate discussed in this article are based on the time this article was written. They may change  in the near future.
3. Photos: Money by AMagill, The Thinker by Andrew Horne