Hello, this lottery problem has been bothering me for months. I set it up here. Help appreciated.(adsbygoogle = window.adsbygoogle || []).push({});

Here is the setup:

Suppose you have to pick 5 numbers from a set of integers ranging from 1 to 39. The probability of matching x/5 (where x can be 1,2,3,4,5) numbers correctly can be found by computing the hypergeometric distribution formula, as found on wikipedia. we have that:

probability of matching x/5 = {5 choose x}*{(39-5) choose (5-x)} / {39 choose 5}

where {a choose b} = a! / (b!*(a-b)!)

Computing for x = 2,3,4,5 yields:

x=2: probability = 59840/575757 ≈ 0.104

x=3: probability = 1870/191919 ≈ 0.00974

x=4: probability = 170/575757 ≈ 0.000295

x=5:probability = 1/575757 ≈ 1.737e-6

Now here is the problem:

Suppose you buy 8 tickets, assume all of them have distinct sets of 5 integers, and play these 8 combinations for 1,000,000 drawings of the lottery. How many tickets in total (out of 8*1,000,000) do you expect to match x out of 5? i.e. in 8,000,000 plays, how many tickets yield 3 out of 5 matched?

I had originally thought that the solution was simply the probability of matching x/5 multiplied by the total number of plays, in this case 8e6, but this isn't the case. Although, this approach works for 2 out of 5 matches but not for 3 or 4...unsure about 5/5.

Any help is well appreciated.

**Physics Forums | Science Articles, Homework Help, Discussion**

Dismiss Notice

Join Physics Forums Today!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# Calculating lottery probability

**Physics Forums | Science Articles, Homework Help, Discussion**