Month: February 2014

Lottery Math

Mention the word "lottery" around any mathematician, and you're likely to hear a disparaging outcry to the effect of "lotteries are a tax on the math illiterate!"  But can it ever make sense to buy a ticket?  Let's use some concepts from basic probability to examine this question.

 

For this analysis, I will be examining Mega Millions, a popular national lottery played in 43 states.  In the game, you pick 5 numbers (consistent with their description, I shall call these "white numbers") from 1 to 75 without replication and one number (the "yellow number") from 1 to 15.  A ticket costs $1, and the goal is to match as many numbers as possible to the random numbers drawn and declared winners (How they ensure the true randomness of these winners is a post for another day).  From the Mega Millions website, the payout structure is as follows:

White matched Yellow matched Prize
5 1 Jackpot
5 0 $1000000
4 1 $5000
4 0 $500
3 1 $50
3 0 $5
2 1 $5
1 1 $2
0 1 $1

I will analyze the jackpot and non-jackpot prizes separately, starting with the latter.

 

Non-jackpot Prizes

To begin, consider the case where a player chooses only a single white number and a single white number is declared the winner.  Of course, the probability the chosen number matches the winning number is \frac{1}{75}.  For the general case in which k white numbers from 1 to n are chosen/drawn, using basic counting principles from combinatorics, the number of possible outcomes in which numbers are selected correctly is  {k \choose c}{n-k \choose k-c}. In particular, for our problem we have n = 75, k = 5.  Independently, we have to consider the yellow number (of which there is 1 outcome in which it is matched, and 14 outcomes in which it is no matched).  Dividing by the total number of outcomes {75 \choose 5}{15 \choose 1}, the probability of selecting  correct white numbers and the yellow number is

\frac{{5 \choose c}{70 \choose 5-c}}{{75 \choose 5}{15 \choose 1}}

and the probability of selecting c correct white numbers but not the yellow number is 

\frac{14{5 \choose c}{70 \choose 5-c}}{{75 \choose 5}{15 \choose 1}}

.

These probabilities are calculated for every value of c in the table below.  To calculate the expected value of the non-jackpot prizes, we multiply the probabilities of each outcome by the prize for that outcome, and sum across all outcomes.

White matched Yellow matched Prize Chances of Outcome Expected Value of Outcome
5 0 $1000000 1 in 18492204 $0.0541
4 1 $5000 1 in 739688 $0.00676
4 0 $500 1 in 52835 $0.00946
3 1 $50 1 in 10720 $0.00466
3 0 $5 1 in 765.7 $0.00653
2 1 $5 1 in 472.9 $0.01057
1 1 $2 1 in 56.5 $0.0354
0 1 $1 1 in 21.4 $0.0467
Sum $0.174

So, the expected value from non-jackpot prizes on a $1 ticket is 17 cents.  Hrm, not much reason to buy a ticket.  Let's see if we can do any better with the jackpot.

 

Jackpot Prizes

For our expected value of the ticket to equal $1, we must recover 83 cents ($1 - 17 cents expected from non-jackpot prizes). An immediate calculation in the same style as the previous section reveals the chances of winning the jackpot by matching all 5 white numbers and the yellow number are 1 in 258,890,850. To achieve the 83 cents, the jackpot needs to be ~$215 million.  You might be tempted to think that for jackpots over this $215 million, your total expected value is greater than $1, so you should buy a ticket.  Not so fast!

The complication is that multiple entries can match all 6 numbers and be declared winners.  In such a situation, the pot is split evenly between all winners.  From anecdotal evidence, more people play when the jackpot goes higher, thus reducing your chances of being the only winner if you do win.  To calculate these probabilities, we need some data on the number of entries to the lottery.  The image below shows a scatter plot of the tickets purchased against jackpot prize for 12/03/13-2/18/14, data courtesy of www.lottoreport.com.

Prize vs Tickets

 

This data follows a near perfect exponential curve.  Interpolating from the plot, this means we expect ~43,000,000 tickets to be purchased at the ~$215 million jackpot level.  Using the probability density function of the binomial distribution, we know that the probability of obtaining k successes from trials each with probability is given by  {n \choose k}p^k(1-p)^{n-k} Thus, if you win the jackpot, the probability you are the only winner is ~0.847, the probability there is one other winner is ~0.141, two winners ~0.0117, three winners ~0.000647, four winners ~0.0000269, and insignificant for five or more winners.  Thus we have to modify the expected value of our jackpot winning by these probabilities, and the actual expected value is ~$198 million, below our cutoff to declare purchasing a ticket a rational decision.  If we repeat this analysis for a ~$250 million prize, we interpolate ~51,000,000 tickets are purchased at this jackpot level.  In this case, we find the discounted expected value is ~$227 million, sufficient to declare purchasing a ticket a rational decision!

 

The Conclusion

Regardless of the jackpot, buying a $1 lottery ticket has an expected value of $0.17 in non-jackpot prizes.  If the jackpot prize is ~$250 million, based on interpolating the number of tickets purchased following an exponential curve, we have that the expected value of the jackpot prize is ~$0.87.  If the prize goes higher, the increase in ticket sales will not be enough to lower the expected value of the jackpot prize.  So, I declare if the jackpot is $250 million or more, it is a rational decision to buy a lottery ticket.  Eat that, fellow mathematicians!