Sunday, December 3, 2023
Relationship

Navigating your way through life can often feel like playing a complex board game. Every scenario you encounter has a set of rules that represents some sort of obstacle to you arriving at your destination. Indeed, it has been suggested that the human species started playing games as a safe space for experimenting with the best way to plan a strategy to get to our goals in life.

As soon as we began to realise that the universe was governed by rules, we started to create games to explore those rules. Many animals play games when they are young, but our species is probably unique in continuing to play games into adulthood. The role of games in the evolution of our species has even led to the proposal that we be called Homo ludens rather than homo sapiens.

Alongside the games we have created to explore our place in the universe, we have also developed a powerful tool to get us to the winning square quickly and efficiently and, more importantly, in front of our fellow players: mathematics. Because games are defined by a set of rules that constrains the way you play the game, mathematics is a very natural language to explore the logical implications of these rules and to find the optimal path to get to your destination.

Since life is itself simply a game in disguise, having a few mathematical tricks up your sleeve can also give you an edge in the game of life. Let me share with you some of my mathematical hacks for tackling some of life’s challenges and coming out on top.

The casino is usually a place to lose millions. But, armed with some mathematical calculations, there are ways to try to beat the bank, or at least lose your money as slowly as possible.

The whole concept of the casino is based on the discovery that mathematics can give you an edge when it comes to playing games of chance, a discovery made by Pierre de Fermat and Blaise Pascal in the second half of the 17th century. Their mathematical analysis allowed the casino to rig games such that, although they might lose to punters every now and again, in the long run they would always come out on top. So the best trick to win your millions is to own the casino.

But there are still some things it is worth knowing as a punter if you are hoping to beat the casino. Here’s a little challenge for you by way of example. You have £20. Your goal is to try to double your money on the roulette wheel. If you put money on red and it comes up, then you get double your money back. Which strategy is more likely to work? Strategy A: put all your money in one go on red; or Strategy B: put down £1 on red on each spin of the wheel.

At first sight it might not seem to matter, but there is a slight twist to the roulette wheel. There are 36 numbers, half red, half black, but then there is also a 37th number: the zero, which is green. If the ball lands here you lose your money, whether you bet on red or black. This is the place where the house beats everyone. It looks pretty innocent, but the casino has calculated that in the long run this makes them their millions.

For the punter it means that there isn’t an evens chance of you winning your bet if you put your money on red. You have a slightly smaller than evens chance: 18/37. It means that essentially every time you play you pay the house £1/37 = £0.027 for each £1 you bet. The house has an edge of 2.7%. The more you play the more you pay.

In Strategy A the chance of you doubling your money in one go by putting down your £20 is 18/37 or 48%, just less than evens. But if you play Strategy B, because you are paying for each £1 bet you make, it means that this strategy is gradually getting you further and further from your goal of doubling your money. In fact, there is only a 25% chance that this strategy nets you double your money in the long run.

Although Strategy A is the best bet it does mean you have rather a short time in the casino. Strategy B might be a more fun evening, but you pay for your entertainment.

How to win a pub quiz

A very powerful tool if you don’t know the answer to something is to ask the crowd. The wisdom of the crowd, where you aggregate the collective knowledge of the group, is an amazing way to know everything from the number of jelly beans in a jar to the number of goals scored in the last World Cup. A good example of the wisdom of the crowd crops up in the famous gameshow Who Wants to be a Millionaire? Most of the time you’re on your own answering questions in your attempt to get 15 of them correct and then bag the £1m prize. However, there are a couple of lifelines you can cling to if you haven’t a clue. One of them allows you to phone a friend, while a second option is to ask the audience. A team of academics from Switzerland gathered data on the German version of the show, which revealed that in 1,337 times that the audience was asked, they only got it wrong 147 times. That is a remarkable hit rate of 89%. Compare that to the statistic for phoning a friend, which failed to get the right answer 46% of the time.

How to win a race

I am going to challenge you and a friend to a race. You are both given a map of a town, which neither of you have ever visited. There is a finishing line marked on the map, but no starting point. Instead, I will set you down at random points in the town, but you won’t know where you are located on the map. There are no street names to help you. Some of the streets are one way and you must obey the rules of the road. How can you plan a strategy to get you to the finishing line before your friend?

In 2007, Israeli mathematician Avraham Trakhtman proved that sometimes you can prepare a map of the mystery town in advance and a set of instructions so that, no matter where you start, the instructions will get you to the finishing line. Each road on the map is represented by two lines with arrows on: one line to represent going up the road and another line if you are allowed to go down the road. If the road is one-way there is only one line with an arrow indicating which direction to go in.

Now here comes the really clever bit. Each of these lines is a different colour. Some lines are red, some blue, some another colour. The instructions consist of a set of directions of the following type: “First take a blue road. At the next junction take a red road. At the next junction take a blue road.” Remember you can only go up a road if the direction allows you. Amazingly, whereever you start in the town, provided you complete these instructions, the journey will get you to the finishing line. Meanwhile, your friend who doesn’t know their maths is still randomly wandering the streets, hoping to stumble on the finishing line by luck.

I recently helped with the creation of a new card game called 21X. It’s a very nerdy take on blackjack in which the cards have algebraic formulas on them, which determine your score, according to your choice of the variable X. The company that came up with the idea decided to create a Kickstarter fund to make the game a reality. But, in order to ensure that the whole enterprise would be profitable, they needed to guarantee a certain number of sales. After all, the cost of creating one bespoke pack for a single customer would have been prohibitively expensive.

As they were guaranteed more and more sales, the marginal cost for each extra product would change. Initially, the marginal cost would go down because it becomes more and more efficient to make your product. But if you try to push production too far, costs can go up again. Increased production eventually leads to overtime, use of less efficient, older plants and competition for scarce raw materials. As a result, the cost of additional units increases. So what is the sweet spot for balancing cost versus demand? The key to solving this conundrum is calculus.

Calculus was invented as a mathematical tool to navigate a world in flux. But amazingly it can also help you maximise your profits while minimising costs. Rather than using trial and error, mathematics homes in on the optimal solution. It’s a bit like throwing a ball in the air: at first the ball travels far, but each subsequent second the ball slows and covers less ground. The calculus can give a manufacturer the insight to understand how costs of goods are changing as output is varied and to find the sweet spot of how many goods to produce to get the marginal cost to be its smallest.

How to win at economics

Fifteen of the Nobel prizes in Economics since its inception in 1969 have been awarded to mathematicians specialising in game theory, including John Nash, whose life was depicted by Russell Crowe in the film A Beautiful Mind.

One economic scenario that game theorists have analysed is called the Ultimatum Game. Player A is given £1,000 and has to decide a way to divide the money between themselves and Player B. Player B then gets to vote on the division. If Player B rejects the offer, then neither player gets any money. What is Player A’s best strategy?

You might think a 50:50 split would be the clever option. Certainly Player B would accept that as fair. Except Player A realises that surely Player B would accept anything rather than getting nothing. So Player A offers £1 with the hope of pocketing £999. It’s true that Player B should accept this given that £1 is better than nothing. This is called the Nash equilibrium, after John Nash, defined as the position taken by the two players so that no player can increase their own expected payoff by changing their strategy while the other players keep theirs unchanged. But this game analysis is ignoring human psychology.

Player B frankly would rather lose the £1, a small price to pay, than see Player A profit so unfairly. But at what point might Player B be prepared to take the insult of being given less and accept the proposal?

The sweet spot for how much you need to offer your opponent in order to get the proposal accepted is connected to one of the most important numbers in mathematics: the golden ratio. In experiments Player B will often accept an offer from Player A if the ratio of what Player B gets compared to what Player A gets is the same as the ratio of what Player A gets compared to the whole sum on offer. That is A/B = (A+B)/A. Two numbers are in the golden ratio if they satisfy this relationship. This ratio represents what many regard as the perfect proportions in art and nature. This works out at a £618 to £382 split. Clearly Player A is getting more, but there is a sense that since Player A is sitting on the whole pot and dividing it up, Player B feels less screwed over if the proportions match those defining the golden ratio.

How to win at love

Your first boyfriend or girlfriend might be amazing. Do you marry them or is there that nagging feeling that maybe you could do better? There are many more fish in the sea and perhaps someone else out there is “the one”. The trouble is that if you dump your current partner there’s generally no way back. At what point should you just cut your losses and settle?

Mathematics has the answer. Suppose that N is the total number of people you can date in a lifetime. The strategy is to date a proportion of this figure to get an idea of the lay of the land. After this you pick the next person who beats all the people that you have dated so far.

Each person’s N is going to depend on a lot of things. One, your own situation, personality type, stamina, social circle, how you’re willing to look for potential partners. And also your personal preferences: age, gender, location and anything else. Calculating your personal N value will require some data sampling and mathematical modelling based on adding all this up. The key question is: what proportion do you need to date to optimise your chances of getting “the one”.

For example, if N = 3, then you need to date one person and then pick the next person who beats the first person you dated. Out of the six possible ways these three people can be ordered, 50% of the time this strategy finds you “the one”. This is the best you can do. But as N gets larger, what is the proportion you need to date? It turns out that some nifty mathematics proves that the key to optimising your chances of getting the best prize possible is Euler’s number, the second most popular number in mathematics: e = 2.71828. You need to gather data from N/e of the possible partners to get some idea of what the field looks like. 1/e = 0.37. This represents 37% of all possible dates.

Once you have dated all these people, you choose the next person that beats all the people you have dated already. This doesn’t guarantee you “the one”, but it maximises your chance of ending up with the best possible. If you based your decision on seeing fewer or more people then these chances decrease. So 37% is the optimal amount of data to gather before taking the plunge. Though perhaps it’s best not to let your partner know you were so calculating when it came to love.

How to win at games

Humans love playing games. It’s as if the game is a rehearsal for life. But games are really just a way of playing mathematics. And if you understand the maths, it can give you an edge. From Ticket to Ride to backgammon, Risk to Connect-4, maths can give you a strategy to come out on top. For example, in Monopoly you are three times more likely to land on the jail square than anywhere else because there are multiple ways to find yourself being sent to jail. But that isn’t much help because you can’t buy the jail square. But here’s where the maths comes in. What is the most common throw of two dice? It’s 7 because there are six ways to make 7: 6+1, 5+2, 4+3, 3+4, 2+5 and 1+6. A throw of 6 or 8 is also very likely. But there is only one way to throw a 2 or a 12. This means that, out of jail, most players are going to be landing in the orange region of property. These are the properties you should aim to buy. The maths also reveals that building three houses is the fastest way to earn back on your investment. Once you get to the end of the game, if you haven’t got the orange properties, then staying in jail for as long as possible is a good way to avoid paying high rents to your fellow players.

In love and economics, business and games, if you know your maths, you’ll end up the winner.

Marcus du Sautoy is the Simonyi Professor for the Public Understanding of Science and Professor of Mathematics at the University of Oxford and author of Around the World in 80 Games, published by Fourth Estate at £16.99, or buy it for £14.95 from guardianbookshop.com