## You're reading: Posts Tagged: combinatorics

### 27 tickets that guarantee a win on the UK National Lottery – but what prize?

The recent preprint ‘You need 27 tickets to guarantee a win on the UK National Lottery‘ by David Cushing and David I. Stewart presents a list of 27 lottery tickets which will guarantee to match at least two numbers on the UK National Lottery, along with a proof that this is the minimum number you need to buy. The argument is clever and makes delightful use of the Fano plane.

I wrote some Python code that runs all 45,057,474 possible draws against these 27 tickets.

All draws had between 1 and 9 winning tickets from the set (crucially, none had zero!). Obviously for 27 of the draws one of the winning tickets matched all six numbers, but about 75% of the draws saw a maximum of 2 balls matched by the winning tickets, and a further 23.5% had at most 3 balls matched. This means almost 99% of the time the 27 tickets match just two or three balls, earning prizes which may not exceed the cost of the 27 tickets! (I recommend reading Remark 1.2 in the paper.)

Update 1: Tom Briggs asked what’s the expected return for buying these 27 tickets. I think the average return is about £20, which is a £34 loss (and of course this is an average from a set of numbers that includes some big wins). Assumptions and details in the GitHub.

Update 2: Matt Parker prompted me to investigate what percentage of draws end in profit. Even though 99% of the time the tickets match just two or three balls, if more than one ticket matches three balls that would still be a small profit. In fact, a profit is returned in 5% of draws, though as noted above the expected return is a loss. Matt included this result in a fun video about the 27 tickets. Again, assumptions and details in the GitHub.

### An incorrect model of the lottery, and when it doesn’t matter

Recently I came across an interesting idea about little mistakes in counting problems that actually don’t amount to much. In A Problem Squared 030, Matt Parker was investigating the question “What are the odds of having the same child twice?” and made some simplifying assumptions when thinking about DNA combinatorics. He justified leaving out a small number of things when counting an astronomical number of things by going through an example from the lottery.

The current UK lottery uses 59 balls and draws 6 of these, so the one in 45 million figure arises from $$\binom{59}{6}=45,\!057,\!474$$, and the probability of winning is a tiny

$\frac{1}{45057474} = 0.00000002219387620 \text{.}$

Matt posits the idea that somewhere along the way we forget to include some tickets.

But let’s say along the way while I’m working it out, for strange reasons I go ‘oh you know what, I’m going to ignore all the options which are all square numbers. You know, I just can’t be bothered including them. Yeah, they’re legitimate lottery tickets, but just to make the maths easier I’m going to ignore them’. And people are getting up in arms, and they’re like ‘you can’t ignore them, they’re real options’.

### Mobile Numbers: Truchet Tiling

In this series of posts, Katie investigates simple mathematical concepts using the Google Sheets spreadsheet app on her phone. If you have a simple maths trick, pattern or concept you’d like to see illustrated in this series, please get in touch.

Since apparently I’m now a maven for interesting fun things built using Google Sheets, someone tagged me in to suggest I might like to see this Truchet Tiling Generator, built in Google Sheets using images generated in Google Drawing.

### Mathematical Objects: Lottery machine

A conversation about mathematics inspired by a lottery machine. Presented by Katie Steckles and Peter Rowlett.

### Mathematical Objects: Robot caterpillar

A conversation about combinatorics, the mathematics of counting, inspired by a robot caterpillar. Presented by Katie Steckles and Peter Rowlett.

### The smallest unique Cheshire Cat

At the MathsJam annual gathering, one of the many activities attendees can participate in is a competition competition – entrants each come up with a competition and submit it into a larger competition, other attendees enter each of the competitions within the competition competition, and the organisers get the chance to make long and confusing (but strictly correct) announcements that contain the word competition a lot of times.

This year, we decided, after a spectacular last-minute MathsJam bake-off entry failure on the behalf of Katie, to enter a joint competition into the competition competition. Inspired by the ‘lowest unique answer’ style of competition, which has previously featured in various MathsJam Competition Competitions (and our recent lecture on game theory) we came up with an idea – what about a competition seeking a unique entry in a non-ordered set?