1 00:00:15,810 --> 00:00:20,550 Well, thank you for that excellent introduction, it's going to be hard to compete with that. 2 00:00:20,550 --> 00:00:26,790 So this is my question then and will the mathematician ever manage a football team? 3 00:00:26,790 --> 00:00:33,390 And I probably mean a little bit more than that because maybe a mathematician has managed an amateur football team, 4 00:00:33,390 --> 00:00:37,830 but will a mathematician at some point manage a Premier League team? 5 00:00:37,830 --> 00:00:45,690 That's my question. So let's start with our prejudice because I think a lot of my title plays on those prejudices. 6 00:00:45,690 --> 00:00:54,000 This is a football manager. Now this one in particular, 7 00:00:54,000 --> 00:01:03,990 who I didn't like for many reasons because I'm a Liverpool fan and he has a style which is probably the antithesis of mathematics. 8 00:01:03,990 --> 00:01:08,850 It's all about getting the players to be as passionate as possible and disregarding 9 00:01:08,850 --> 00:01:13,500 any kind of statistics which say that he's failing and he just keeps going and going, 10 00:01:13,500 --> 00:01:17,340 and he uses this sort of least mathematical approach to football. 11 00:01:17,340 --> 00:01:21,060 I think that might be. That's my prejudice. I'm going to own up. 12 00:01:21,060 --> 00:01:28,300 This is my prejudice. So we'll put that against another person who we might have some prejudices about. 13 00:01:28,300 --> 00:01:38,050 And this is Andrew Wiles, of course. And when we think of mathematicians, we think of a very logical structure to everything, 14 00:01:38,050 --> 00:01:44,740 very carefully thinking through and answering questions in a very, very precise type of way. 15 00:01:44,740 --> 00:01:51,280 And so our prejudices really tell us that Moreno and Wiles are somehow polar opposites. 16 00:01:51,280 --> 00:01:59,200 So how can we expect to unite these two and have a mathematician manage a football team? 17 00:01:59,200 --> 00:02:05,320 Well, I've got some suggestions or I'm going to work towards some suggestions. 18 00:02:05,320 --> 00:02:10,420 This is a starting point. This is another type of managerial style that we've heard about. 19 00:02:10,420 --> 00:02:15,820 This is Pep Guardiola and Guardiola. He's certainly passionate about the game, 20 00:02:15,820 --> 00:02:21,430 but he likes to sort of portray himself more as the kind of intellectual the man who's opening 21 00:02:21,430 --> 00:02:27,370 up space for his team and planning carefully about tactical decisions against the opposition. 22 00:02:27,370 --> 00:02:36,210 So there is this kind of idea also of the football manager as the intellectual who's trying to solve a problem. 23 00:02:36,210 --> 00:02:44,070 And then there's also a type of mathematician, not the pure mathematician, but there's also the type of applied mathematician. 24 00:02:44,070 --> 00:02:51,180 And this brings us to Philip, who's sitting up there in the back row and this is Philip Hare, and he's very kindly. 25 00:02:51,180 --> 00:02:53,760 This is this is the team he's been playing for. 26 00:02:53,760 --> 00:02:58,720 He's very kindly instructed the rest of the team exactly how you should stand when you have a photograph. 27 00:02:58,720 --> 00:03:05,550 So he's got his managerial style here, and he's got most of them seem to have listened to his advice. 28 00:03:05,550 --> 00:03:12,780 And Philip is just one of several mathematicians who are accomplished football players. 29 00:03:12,780 --> 00:03:17,370 I don't know what league it was. You played in, Philip, can you tell us? 30 00:03:17,370 --> 00:03:25,870 OK. But we actually have another professor at Oxford who has played at a much higher level. 31 00:03:25,870 --> 00:03:31,710 So this is Ruth Baker, who's also a professor of applied of applied mathematics mathematical biology, 32 00:03:31,710 --> 00:03:37,440 and she wears the number eight shirt or has worn the number eight shot for Oxford. 33 00:03:37,440 --> 00:03:44,430 So this must be a vast was Ruth. OK, this must be a varsity match, and this was the one you won. 34 00:03:44,430 --> 00:03:51,270 I take it. Yeah. Did you get the ball in that run? Can you remember what happened? 35 00:03:51,270 --> 00:03:57,840 So it is possible to be a mathematician and to be a successful football player. 36 00:03:57,840 --> 00:04:03,120 You have been you were described to me earlier today as the most successful football player in the whole maths institute. 37 00:04:03,120 --> 00:04:07,640 So very impressive. 38 00:04:07,640 --> 00:04:19,100 And I'm going to describe a little bit about my own background, so how I have gone from being a mathematician to becoming more involved in football, 39 00:04:19,100 --> 00:04:25,310 I thought I'd start with a picture of myself when I was a kid. I'm I'm the one. 40 00:04:25,310 --> 00:04:29,150 This one has this cute one. That's my little brother, Colin, and this is me. 41 00:04:29,150 --> 00:04:34,010 I think I must have been about eight or nine when this photograph was taken. 42 00:04:34,010 --> 00:04:38,180 And unfortunately, I wasn't any good at football. 43 00:04:38,180 --> 00:04:41,660 I liked having the strap on and I thought I looked very good in it. 44 00:04:41,660 --> 00:04:46,220 But I found out that I wasn't particularly talented football player. 45 00:04:46,220 --> 00:04:55,520 But what? I was much better at with mathematics, and I have this picture of myself a few years later when I, as Alan, said, 46 00:04:55,520 --> 00:05:00,230 I worked here as a Royal Society Research Fellow and I was particularly interested 47 00:05:00,230 --> 00:05:06,290 in one type of mathematics how you could apply maths to understand the real world. 48 00:05:06,290 --> 00:05:11,150 And a lot of my research here, I was only half time based here at the maths department. 49 00:05:11,150 --> 00:05:19,310 I was also based at the zoology department, and I work together with people who were studying locusts who were studying ants and pigeons. 50 00:05:19,310 --> 00:05:24,250 Think of a picture of the pigeons here. These are actually pigeons from from just outside Oxford. 51 00:05:24,250 --> 00:05:29,390 This Mr Ribeiro, who was one of my biologist colleagues who took these photographs and I studied 52 00:05:29,390 --> 00:05:35,090 how they interact and how they produce different types of collective behaviour. 53 00:05:35,090 --> 00:05:38,000 And oh yes, this gets onto the next picture. 54 00:05:38,000 --> 00:05:43,670 And I needed to put this in because I was at Wolfson College and this is a picture of my daughter blowing bubbles in Wolfson College. 55 00:05:43,670 --> 00:05:51,680 I just wanted to have that in there as well. And then I became a professor in Uppsala. 56 00:05:51,680 --> 00:05:59,660 And then it turned out that my son Henrik, who's this one here, he started playing a lot of football, 57 00:05:59,660 --> 00:06:04,130 and it turned out that he had a lot more talent in the game than I did. 58 00:06:04,130 --> 00:06:06,890 And they needed people to manage or manage his team. 59 00:06:06,890 --> 00:06:18,380 So I ended up partly with a bunch of other dads who were, like, overly enthusiastic, trying to relive their own failed dreams through their children. 60 00:06:18,380 --> 00:06:23,000 We started training as a team and I'm still actually training his team. 61 00:06:23,000 --> 00:06:30,080 He's now 14 years old and he's still still plays football on a regular basis, despite me embarrassing him and talks like this. 62 00:06:30,080 --> 00:06:38,510 He's still involved with that. And then I ended up because I became interested in football again, and I'd always had that in the background. 63 00:06:38,510 --> 00:06:47,390 I ended up writing the book Soccer Mattox, thinking about how we can use maths to explain different parts of football. 64 00:06:47,390 --> 00:06:53,000 And in the book, I look at game theory for strategy. I look at randomness in the game. 65 00:06:53,000 --> 00:06:57,680 I look at passing networks, all aspects of mathematics that I knew. 66 00:06:57,680 --> 00:07:03,920 I tried to break down into the into the soccer maths textbook, but this was mainly an academic. 67 00:07:03,920 --> 00:07:09,620 That was part of it was how you might apply it in reality, but it was mainly an academic exercise. 68 00:07:09,620 --> 00:07:15,710 And then I, as you'd get asked to do, you get asked to do kind of talks when you write a book like this? 69 00:07:15,710 --> 00:07:21,920 I got asked to do a TED talk. And in that TED talk, or it was a TED talk, you should make a distinction here. 70 00:07:21,920 --> 00:07:29,660 But in that talk, I put my hand up to with the telephone and told Jürgen Klopp Being a Liverpool fan, 71 00:07:29,660 --> 00:07:38,990 I told you again, Klopp, Well, you know, you can ring me any time. I'm I'll help Liverpool get promoted or win the Champions League or whatever. 72 00:07:38,990 --> 00:07:51,070 And he didn't call. But strangely, actually, quite a few other clubs did call me and I have had a visit in Uppsala from two Premier League clubs, 73 00:07:51,070 --> 00:07:55,390 they made me write non-disclosure agreements. I can't say which. 74 00:07:55,390 --> 00:08:07,030 And I've also visited a few clubs here in the UK, and another club that called me is the club Hammarby and in Stockholm. 75 00:08:07,030 --> 00:08:12,550 And they were very open and they said that I can actually go and work their work together 76 00:08:12,550 --> 00:08:19,630 with the coaches and with the players and help them develop their play with analytics. 77 00:08:19,630 --> 00:08:28,150 And so now I'm actually working part time together with a big football club trying to improve their game with mathematics. 78 00:08:28,150 --> 00:08:36,310 So that's a kind of brief history of me. But what I'm now going to answer is I don't think I'm quite there. 79 00:08:36,310 --> 00:08:40,210 I'm not actually managing Hammarby. I'm a long way from there. 80 00:08:40,210 --> 00:08:48,580 But what I want to get at is the basis of why applied mathematics is useful to to a football team. 81 00:08:48,580 --> 00:08:57,240 Why? What is it that applied mathematicians have got that allows them to get somewhere and in helping a football team? 82 00:08:57,240 --> 00:09:04,320 And I think I've been told that when you do a talk like this, you should like be extremely clear what your messages. 83 00:09:04,320 --> 00:09:10,230 And so I've just written down precisely what my messages and I'm going to repeat it at the end of the talk. 84 00:09:10,230 --> 00:09:16,010 This is precisely what an applied mathematician has to has to give. 85 00:09:16,010 --> 00:09:24,410 We base what we say on data. When we talk about something, we collect data and we we base what we see on data. 86 00:09:24,410 --> 00:09:27,740 We formulate models to understand that data. 87 00:09:27,740 --> 00:09:36,680 It's a essential part of everything that we do, that we have a model which describes how we think the data works and how we understand the data. 88 00:09:36,680 --> 00:09:42,030 And then we fit our models to the data in order to make predictions of the future. 89 00:09:42,030 --> 00:09:46,530 So that's the rules that we follow, is applied mathematicians. 90 00:09:46,530 --> 00:09:53,520 What I'm going to spend the rest of the talk doing is explaining how we put this into practise exactly in football. 91 00:09:53,520 --> 00:10:02,570 And hopefully by the end of our persuade you that well may be applied, mathematicians can be trusted to run a football team. 92 00:10:02,570 --> 00:10:05,860 So let me get to the get to the base of this idea, right? 93 00:10:05,860 --> 00:10:20,830 Let's start with some goals. So I'm going to ask you a question then out of these two goals, which do you think is the best goal? 94 00:10:20,830 --> 00:10:24,460 So let's put our hands up hands up for the top goal. 95 00:10:24,460 --> 00:10:32,520 Is that the best goal? And who thinks that the bottom one is the best goal? 96 00:10:32,520 --> 00:10:42,180 OK, so we've got a I think, a slight majority for the top, the top goal now, the top goal is a very long distance shot. 97 00:10:42,180 --> 00:10:46,500 There is a mistake by the goalkeeper here left in the end. I don't like this goal. 98 00:10:46,500 --> 00:10:51,270 Obviously, being a Liverpool fan, this was the reason we didn't win the Champions League last season. 99 00:10:51,270 --> 00:10:55,500 And but the Boston one is a very, very messy goal. 100 00:10:55,500 --> 00:11:00,300 There's a lot of sort of things. There's a claim there by the goalkeeper that was a foul. 101 00:11:00,300 --> 00:11:07,080 It clearly wasn't a foul and the ball bumps into the into the back of the net. 102 00:11:07,080 --> 00:11:12,420 And so it's a much more messy type of goal. Well, what does maths have to say about this? 103 00:11:12,420 --> 00:11:17,610 Well, what we do is we start with this idea. We start by looking at the data. 104 00:11:17,610 --> 00:11:28,410 And now here is some data over lots and lots of goals in football matches, not just one these this is actually all in a season of La Liga. 105 00:11:28,410 --> 00:11:32,670 This was the season before Neymar went to PSG. 106 00:11:32,670 --> 00:11:42,660 All of these little dots are shots that have been taken by these players, Lionel Messi, Neymar and Luis Suarez, so this yellow is a shot from here. 107 00:11:42,660 --> 00:11:49,680 These are long distance shots and if there's a black circle around it, then that means that it was a goal. 108 00:11:49,680 --> 00:12:00,690 So this is where the goals were scored from. And the important takeaway message from this is that if you see where the shots are, where are the goals? 109 00:12:00,690 --> 00:12:07,950 Nearly all of the goals are very close to the goal mouth, even namely as close. 110 00:12:07,950 --> 00:12:11,130 Messi has to, which are slightly long distance, 111 00:12:11,130 --> 00:12:21,060 but almost every goal scored by Barcelona in La Liga is scored very close to the goal and that was exactly like Manhas goal at the bottom. 112 00:12:21,060 --> 00:12:28,500 And not like Gareth Bale's goal at the top. So typically, goals scored from much, much nearer to the goal. 113 00:12:28,500 --> 00:12:32,340 They're not scored at long distance. And this isn't just true of Barcelona. 114 00:12:32,340 --> 00:12:35,820 There are teams which shoot from a longer distance. This is for the same season. 115 00:12:35,820 --> 00:12:39,960 This is Real Madrid and Gareth Bale who scored the video. 116 00:12:39,960 --> 00:12:44,970 The goal in the video I showed you. You see, he's got two long, long distance goals. 117 00:12:44,970 --> 00:12:51,450 Cristiano Ronaldo, he has shot. I think it's 60 times from outside the box. 118 00:12:51,450 --> 00:12:53,340 And he scored twice. 119 00:12:53,340 --> 00:13:03,390 So when he scores these goals and you often see them as the highlights on on TV afterwards, he's actually scores only one out of 30 efforts. 120 00:13:03,390 --> 00:13:08,250 And you often see a YouTube compilation of all of the goals that he's scored. 121 00:13:08,250 --> 00:13:12,150 Well, they should really have in these YouTube compilations is all of the misses 122 00:13:12,150 --> 00:13:17,040 that he's made because he misses a lot of the time where Ronaldo scores a lot. 123 00:13:17,040 --> 00:13:23,260 It's actually very close to the goal. Most of his goals come from very nearby. 124 00:13:23,260 --> 00:13:27,310 And that's a that's our data. 125 00:13:27,310 --> 00:13:35,790 So we've got our data. Next step is the model. And I want to start, and I think this is always what applied mathematicians tried to do. 126 00:13:35,790 --> 00:13:40,920 We start with the simplest possible model and then we build from there. 127 00:13:40,920 --> 00:13:48,330 And I want to start with the idea of this angle and the angle is how much of the face of the goal can you see? 128 00:13:48,330 --> 00:13:53,370 So if you're looking if if we take this podium, for example, 129 00:13:53,370 --> 00:13:58,860 the people who are sitting straight on at that podium can see it much more clearly than the people who are sitting there. 130 00:13:58,860 --> 00:14:06,570 There's a much wider angle. The people who are sitting at the back, they have a narrower angle than the people who are sitting at the front. 131 00:14:06,570 --> 00:14:16,020 And so our basic idea is this angle to the goalposts is going to be the model of the probability that you can score. 132 00:14:16,020 --> 00:14:25,670 Bale's shot is a long way out. So here's a little angle. Money shot is very close in, so it has a very large angle. 133 00:14:25,670 --> 00:14:33,540 And so the quality of a chance in football can be assessed by the angle to the goalmouth here. 134 00:14:33,540 --> 00:14:36,090 And then you have this nice property that, well, you can go around, 135 00:14:36,090 --> 00:14:42,870 as I mentioned that people sitting out there looking at this thing have a very narrow angle, even though they're closer to me. 136 00:14:42,870 --> 00:14:47,580 But people sitting up there, they might have a similar somewhere around there. They would have a similar angle. 137 00:14:47,580 --> 00:14:56,820 And it's actually a circle which stretches out from the goal. All of those points on the circle are that this is a segment of the circle here, 138 00:14:56,820 --> 00:15:02,290 and there's a circle that goes all the way round, and all of those points are on the circle. 139 00:15:02,290 --> 00:15:05,230 And so now we can define basically this. 140 00:15:05,230 --> 00:15:11,250 This is the essential bit of applied mathematics and applied mathematicians are always going on about how many parameters they have in their model. 141 00:15:11,250 --> 00:15:19,470 Here we just have a one parameter model. This angle, which defines the probability of scoring. 142 00:15:19,470 --> 00:15:26,700 A little bit of trigonometry. This is something I did by hand, you can actually work out from the X y coordinates of the shot. 143 00:15:26,700 --> 00:15:37,550 You can work out the angle. I won't go through the calculation, but you end up finding that these circles all have exactly the same angle. 144 00:15:37,550 --> 00:15:44,450 And now the next thing we're going to do is we're going to actually take data into this, and what we do is we do a thing called logistic regression, 145 00:15:44,450 --> 00:15:50,720 where we take all of the shots that have been taken in LaLiga on the Premier League 146 00:15:50,720 --> 00:15:55,940 and we calculate the angle for them and we calculate using logistic regression. 147 00:15:55,940 --> 00:16:04,100 We calculate the probability of them scoring a goal as a function of this angle and by computer fitting, I get these two parameters three point five, 148 00:16:04,100 --> 00:16:13,040 four times the angle theta and then this constant here, and they can then tell us the probability of scoring from different angles. 149 00:16:13,040 --> 00:16:22,340 It turns out the one parameter model isn't perfect. It turns out you do need to actually put in the X coordinate to get the best fit to this data. 150 00:16:22,340 --> 00:16:33,050 But this roughly gives a universal rule for scoring in football that there is a 30 percent chance here, a 50 percent chance here. 151 00:16:33,050 --> 00:16:41,530 And then there's a seven percent chance out in this in this circle, and that's roughly true across a wide range of leagues. 152 00:16:41,530 --> 00:16:49,690 And if you have if you have looked at things like football analytics, which has lots of this is the basis of what's called the expected goals model. 153 00:16:49,690 --> 00:16:58,120 Basically, this probability gives the probability on an average day of football that you'll score a goal in these different situations. 154 00:16:58,120 --> 00:17:02,090 So it's called the expected goals model. 155 00:17:02,090 --> 00:17:08,090 And it works very well, it turns out the teams that have the best expected goals in the long term, they do well. 156 00:17:08,090 --> 00:17:13,190 And so this is an example. There's an online app if you want to go in and look at your team's expected goals, 157 00:17:13,190 --> 00:17:18,110 it works for the Premier League, for the last few seasons, the Champions League and so on. 158 00:17:18,110 --> 00:17:24,290 You can go into our 12 football analytics app and you can actually look at the shots that the players have got. 159 00:17:24,290 --> 00:17:30,920 And here you see why Liverpool won the Champions League. Mané took so many shots from very close to the goal. 160 00:17:30,920 --> 00:17:35,330 Lots of them were misses, but lots of them with goals and the same thing with Mohamed Salah. 161 00:17:35,330 --> 00:17:39,950 So they've specialised in getting extremely close to the goal before they shoot, 162 00:17:39,950 --> 00:17:47,500 getting inside those circles and producing a lot of goals as a result. 163 00:17:47,500 --> 00:17:54,430 I've got something similar for an elder. Now I've got I've got one more thing here for Philip, who's a Leeds United fan. 164 00:17:54,430 --> 00:18:04,000 If you use this measure, Leeds United's last season they failed to qualify for the Premiership. 165 00:18:04,000 --> 00:18:10,960 But it turns out when I calculated or when Opta calculated the expected goals for Leeds United, 166 00:18:10,960 --> 00:18:16,150 it turns out they were extremely unlucky if it wasn't for randomness. 167 00:18:16,150 --> 00:18:19,570 Leeds United would have won the Championship last season. 168 00:18:19,570 --> 00:18:25,870 If you look at this chart, they scored more expected goals had better chances than any other team. 169 00:18:25,870 --> 00:18:31,180 They conceded fewer chances than any other team. But they still weren't promoted. 170 00:18:31,180 --> 00:18:37,390 So there's a lot of unfair randomness in football that we can't really get away from. 171 00:18:37,390 --> 00:18:45,580 But we can get an over overall underlying idea of how good teams are, and Leeds United are actually doing very well this season again. 172 00:18:45,580 --> 00:18:54,440 So I think that they because they're good in this measure, they will eventually if they can keep it up and get promoted. 173 00:18:54,440 --> 00:18:57,740 OK, so I want to go back to some of our pledges. 174 00:18:57,740 --> 00:19:05,420 This is because I think what's very interesting when you've got a statistical tool like this or a mathematical tool for understanding the world, 175 00:19:05,420 --> 00:19:12,680 how can you use it? Well, one way you can use it is the following. So this is Raheem Sterling, who plays for Manchester City. 176 00:19:12,680 --> 00:19:19,520 And this is the type of headline that you see about Raheem Sterling in certain newspapers. 177 00:19:19,520 --> 00:19:29,300 This is the headline from the Daily Mail. Manchester City star Raheem Sterling earns two hundred thousand a week but takes an £80 easyJet flight, 178 00:19:29,300 --> 00:19:33,860 and apparently this is somehow really bad behaviour on the part of Raheem Sterling. 179 00:19:33,860 --> 00:19:36,410 How dare you take an easyJet flight? 180 00:19:36,410 --> 00:19:45,800 But even worse, the son found out that Raheem Sterling he hired a private jet and headed out for two holidays in a week. 181 00:19:45,800 --> 00:19:51,410 So Raheem Sterling can't win if he goes on a cheap easyJet flight. 182 00:19:51,410 --> 00:19:57,890 That's really bad. You know, cheap football player. He earns so much money, but if he hires a private jet, then that's something. 183 00:19:57,890 --> 00:20:07,370 There's something wrong about that. And what you'll often hear is this sort of justification of why they say bad things about Raheem Sterling 184 00:20:07,370 --> 00:20:12,830 is that he's not playing very well or he's not doing all he can for the team that he plays for. 185 00:20:12,830 --> 00:20:19,250 I'm Vinnie. Jones came out and said if Raheem Sterling didn't have pace, he would be playing for Exeter and Vinnie Jones. 186 00:20:19,250 --> 00:20:25,730 So despite the fact they got to the semi the semi-final of the World Cup with Raheem Sterling playing in every match, 187 00:20:25,730 --> 00:20:30,310 Vinnie Jones was worried that he was wasting too many chances, so Raheem was to blame. 188 00:20:30,310 --> 00:20:36,650 And so you get these types of headlines about players all the time. And. 189 00:20:36,650 --> 00:20:41,510 What a collie or another person who's interested in football analytics. 190 00:20:41,510 --> 00:20:45,410 Bobby Gardner did, is he actually study this statistically? 191 00:20:45,410 --> 00:20:50,540 Is Raheem Sterling wasting lots of chances like Vinnie Jones says, and it turns out he is. 192 00:20:50,540 --> 00:20:55,700 And if you compare is expected goals with his actual goals, he's spot on. 193 00:20:55,700 --> 00:21:02,000 So the chances that he gets, he converts as an average striker or a top level striker would. 194 00:21:02,000 --> 00:21:07,880 So you have people who are overperform, for example, Harry Kane of overperformance. 195 00:21:07,880 --> 00:21:12,080 Mohamed Salah over performs. But Raheem Sterling plays out on the left. 196 00:21:12,080 --> 00:21:16,790 He isn't their top striker. That's actually a Guerra who's up there on the on the list. 197 00:21:16,790 --> 00:21:24,500 So Raheem Sterling is actually just slightly above average in conversion, so you can actually do that statistical test and show that. 198 00:21:24,500 --> 00:21:30,350 And we find actually this season that Raheem Sterling is the top striker who has the best chances, 199 00:21:30,350 --> 00:21:33,950 and he's scored quite a lot of them if we do the statistics. 200 00:21:33,950 --> 00:21:43,070 But even if you don't believe any of the statistics, I now have the final proof that Raheem Sterling actually is a good striker. 201 00:21:43,070 --> 00:21:53,360 I take it back. Vinnie Jones admits he was wrong about Raheem Sterling after Manchester City put in a fantastic display against Southampton. 202 00:21:53,360 --> 00:22:00,290 And so that's a lot of the time. What we're up against this idea that, yeah, there's this idea that it's all about some sort of passion. 203 00:22:00,290 --> 00:22:06,440 And it's not just to do with with statistics, but there's often statistics underlying why certain players are the best players. 204 00:22:06,440 --> 00:22:11,930 And I would say Raheem Sterling is the best. Statistically, he's the best England player. 205 00:22:11,930 --> 00:22:22,160 We have just now. And this goes on, so it's another example, this is Paul Pogba and the son's Old Trafford correspondent, 206 00:22:22,160 --> 00:22:29,260 and he said that it basically compared Paul Pogba to Roy Keane and poor shows and said that he 207 00:22:29,260 --> 00:22:34,420 wasn't doing his job for the team and he should try harder and do better for Manchester United. 208 00:22:34,420 --> 00:22:40,960 And this type of thing is slightly more difficult to test because it's easy when it comes to goals. 209 00:22:40,960 --> 00:22:45,730 But how do you test a midfield player? Paul Pogba plays deep in midfield. 210 00:22:45,730 --> 00:22:49,750 He plays sometimes assists, but he doesn't always score all of the goals. 211 00:22:49,750 --> 00:22:51,280 So how do you test this? 212 00:22:51,280 --> 00:23:02,710 Well, a solution to this was suggested by Sarah Rudds, who has not sure if she's a mathematician, but she has a strong applied mathematics background. 213 00:23:02,710 --> 00:23:08,020 And her idea was to use something called a mark off chain to assess, assess midfielders. 214 00:23:08,020 --> 00:23:13,330 And the idea is you basically build up a model of that in a typical game of football. 215 00:23:13,330 --> 00:23:17,080 What's the percentage chance that a ball in midfield goes out to the wing? 216 00:23:17,080 --> 00:23:18,880 What's the chance that it goes into the box? 217 00:23:18,880 --> 00:23:27,520 What's the chance that it goes into the goal and you can build up an overall model, assuming that passes in the past don't affect the future. 218 00:23:27,520 --> 00:23:32,740 You can build up an overall model of the quality of different types of passes. 219 00:23:32,740 --> 00:23:37,560 And that framework is something that we've worked with quite a bit and developed. 220 00:23:37,560 --> 00:23:41,100 Again, coming back to the idea of modelling data, 221 00:23:41,100 --> 00:23:46,260 the idea is that we use all of the ball actions in the group and we group them into possession chains, 222 00:23:46,260 --> 00:23:52,440 so each one of these these messy lines here is a possession chain ending in a shot. 223 00:23:52,440 --> 00:23:55,260 So it might be a sequence of passes dribbles. 224 00:23:55,260 --> 00:24:01,380 The ball might be lost for a few seconds, but then regained, says a chain of a possession landing in the shot. 225 00:24:01,380 --> 00:24:10,920 Then what we do is we find the probability that a certain path in this chain ended in a shot and this is really extending. 226 00:24:10,920 --> 00:24:15,720 The expected goal was model over the entire pitch. So we're looking at all the passes. 227 00:24:15,720 --> 00:24:19,380 What was the chance that they ended in the shot? Then we work out. 228 00:24:19,380 --> 00:24:26,130 Was it a goal? If you have all of these past coordinates in the shot and then we did a similar thing, 229 00:24:26,130 --> 00:24:30,720 but in reverse, we did a similar thing for dribbles and then we do the reverse for tackles. 230 00:24:30,720 --> 00:24:39,900 So if you prevent a attempt on goal by the opposition, then you can actually evaluate how dangerous that type of attempt was. 231 00:24:39,900 --> 00:24:43,770 And this allows us to build up a model of the whole game of football, 232 00:24:43,770 --> 00:24:53,300 assuming that everything is memory loss that we go from just from one place to the other, not remembering the sequence that they were in before. 233 00:24:53,300 --> 00:25:01,370 And that could then find us we actually could find that Paul Pogba was one of the most important players at the World Cup. 234 00:25:01,370 --> 00:25:06,020 He made a lot of passes from deep here in midfield. 235 00:25:06,020 --> 00:25:09,140 And these are multiple evaluated is extremely valuable. 236 00:25:09,140 --> 00:25:14,960 If you can pass the ball from here to here, then you're going to be able to launch a very quick counterattack counterattack. 237 00:25:14,960 --> 00:25:22,360 And so he makes a lot of passes that are of extremely high value. 238 00:25:22,360 --> 00:25:26,680 And we made a ranking actually for last season based on this measure. 239 00:25:26,680 --> 00:25:33,190 The green one is the attack value, the red one is defence and the blue one is scoring goals. 240 00:25:33,190 --> 00:25:38,830 And I just wanted I wanted to really rub it into Manchester United fans about who the best players were. 241 00:25:38,830 --> 00:25:48,100 So I use this as an excuse. I just ran Liverpool and Manchester United players last season, ranked according to our Markov chain model. 242 00:25:48,100 --> 00:25:56,170 And it's interesting. See that Virgil van Dijk, who won European Player of the Year, came out top mainly because of his defensive contributions. 243 00:25:56,170 --> 00:26:00,280 But then in second place you have Paul Pogba and he does everything. 244 00:26:00,280 --> 00:26:07,540 He produces lots of effective passes. He defends very well and he has lots of very good shots and goals. 245 00:26:07,540 --> 00:26:12,250 Then you have a whole row of Liverpool players all the way down to market share. 246 00:26:12,250 --> 00:26:18,520 And so we can actually measure the scale of the players and this is what I like to think of. 247 00:26:18,520 --> 00:26:22,390 If you are, I'm going to come to Barcelona now where I went to visit. 248 00:26:22,390 --> 00:26:29,650 But Barcelona were for a while very interested in signing Paul Pogba and I don't think that they think, well, Pogba doesn't have as much passion, 249 00:26:29,650 --> 00:26:40,250 is keen, does what they're thinking in their mind is Pogba passes the ball up from midfield in a much more effective way than any other player. 250 00:26:40,250 --> 00:26:48,830 So now I'm going to come to my own contribution and how what I've been doing and in football, as I said before, 251 00:26:48,830 --> 00:26:54,530 I think we've gone over that a lot of my work was on collective animal behaviour, trying to understand the movements of animals. 252 00:26:54,530 --> 00:27:04,070 And then when I started writing Soccer Matic's, I became very interested in exactly this type of movement on the pitch. 253 00:27:04,070 --> 00:27:10,790 So if you watched Barcelona, maybe on our show, this is the Barcelona team of 20, 10 11. 254 00:27:10,790 --> 00:27:19,050 Lionel Messi, you see him. But what you also see is some very, very nice, ticky tack of passing that they did during that time. 255 00:27:19,050 --> 00:27:24,640 And what we could do is we could break down those types of passes. 256 00:27:24,640 --> 00:27:32,230 By we used something called a de looney triangulation, and this is where you connect the nearest neighbours, 257 00:27:32,230 --> 00:27:39,130 the most direct neighbours, the neighbours who have a border with each other, whether with a line, and that gives you a triangulation. 258 00:27:39,130 --> 00:27:44,170 And what you see is that message opens up a lot of passing to John Vitol example. 259 00:27:44,170 --> 00:27:48,730 He has an open past in the East. He has one hair out to the right. 260 00:27:48,730 --> 00:27:56,230 And if they do this, if they stand in this way where they're kind of maximally distant from other players around them, 261 00:27:56,230 --> 00:28:02,980 they're still only triangulation opens up automatically. And so this is called a veterinary diagram. 262 00:28:02,980 --> 00:28:12,940 And it turns out that a lot of what Barcelona do is that they stand in a way which puts their opposition on the edges of the veterinary diagram, 263 00:28:12,940 --> 00:28:17,500 which means that they're maximally distant from them at any given point. 264 00:28:17,500 --> 00:28:24,130 And as a result, this triangulation opens up where they can actually pass the ball very effectively to each other. 265 00:28:24,130 --> 00:28:30,850 So there's a kind of mathematical principle underlying the Tic TAC of football that Barcelona have been playing, 266 00:28:30,850 --> 00:28:35,500 and I was very excited about this and I wrote a lot about it in schematics. 267 00:28:35,500 --> 00:28:45,730 And then I was lucky enough to be invited down to Barcelona and see this is Messi up close and personal, so I got to see Messi really near in action. 268 00:28:45,730 --> 00:28:50,650 I didn't get to meet him, unfortunately. I was probably at one point I was at the training group. 269 00:28:50,650 --> 00:28:56,830 I was at this training ground, so I was probably a few hundred metres away from Messi when he was training and 100 metres away. 270 00:28:56,830 --> 00:29:05,470 But I didn't get the introduction, unfortunately, but I did get to meet the data scientists who work at Barcelona and they actually have a team. 271 00:29:05,470 --> 00:29:09,790 It's a little bit like a sort of university department there with all the sports science they do, 272 00:29:09,790 --> 00:29:14,500 it's really impressive placed to see what they're trying to do. 273 00:29:14,500 --> 00:29:25,660 And I met this guy here. This is Javier Fernandez, and I was, of course, very pleased with all my glowingly triangulation and border noy diagrams, 274 00:29:25,660 --> 00:29:32,020 and I gave a presentation there and told them all about it. And they were like, Yeah, yeah, of course we know all of that. 275 00:29:32,020 --> 00:29:39,070 They're there. And I was very surprised to hear that they were they already use that type of technique. 276 00:29:39,070 --> 00:29:47,920 And what Javier had developed was an even better technique for measuring basically who's going to come to the ball first. 277 00:29:47,920 --> 00:29:57,010 So here is a here is Barcelona playing in a purple and the green areas show where a Barcelona player will come to first. 278 00:29:57,010 --> 00:30:01,240 The red area show where the opposition players will come to first. 279 00:30:01,240 --> 00:30:07,000 And this they track for every match and they're able to see how the team controls space. 280 00:30:07,000 --> 00:30:11,890 And the whole of Barcelona's game is built up about how you can control space. 281 00:30:11,890 --> 00:30:15,550 And Javier is sitting there after the match looking well. 282 00:30:15,550 --> 00:30:19,150 Have they controlled space in the way that they said they would control space and 283 00:30:19,150 --> 00:30:25,140 he can actually give feedback and so on about how they're controlling space? 284 00:30:25,140 --> 00:30:29,670 And so I took a lot of what I learnt to Barcelona, 285 00:30:29,670 --> 00:30:36,300 and now now I have a research project together with them and wanted to put that into work in Hammarby. 286 00:30:36,300 --> 00:30:44,690 As I said, this started with me phoning virtually, phoning you by the way, Juergen, you know, you can actually still come and contact me. 287 00:30:44,690 --> 00:30:48,600 I'm I am a Liverpool fan, so I would rather be working for you. 288 00:30:48,600 --> 00:30:55,920 So yeah. But so they started with me making this and Hammarby did ring me up, and they were local team in Stockholm, 289 00:30:55,920 --> 00:31:00,840 so it was much more easy for me to start working with them and their coach, Stefan Bellbottom. 290 00:31:00,840 --> 00:31:07,710 He was very open to this type of this type of collaboration, and now I often go to the trainings. 291 00:31:07,710 --> 00:31:09,870 We have development things here. 292 00:31:09,870 --> 00:31:18,750 And what's most fun is that we have a feedback cycle where we can present what we've learnt to the players and show the mathematical models. 293 00:31:18,750 --> 00:31:24,450 And they say whether they think that this works or that we can actually give them feedback on their performance. 294 00:31:24,450 --> 00:31:27,470 And I'm going to give a few examples of this. 295 00:31:27,470 --> 00:31:34,670 One is exactly as I said, this was Javier's method that he's been developing, we've we've been developing along that idea. 296 00:31:34,670 --> 00:31:42,310 This is a goal that we scored recently. Where the green team here. 297 00:31:42,310 --> 00:31:48,740 So you're cheering for the green team now, right? OK, so if the blue team score is bad, green team need to score. 298 00:31:48,740 --> 00:31:57,370 So oh good. We've got the ball back. This is Mojo Jankovic shoes our best ranked player just now, according to our system. 299 00:31:57,370 --> 00:32:01,330 Alex Kuczynski, who played for Fulham. Both of them play for Fulham at one point. 300 00:32:01,330 --> 00:32:06,820 Get the ball out to Nico. Nico gets it back into the middle and Moyo, who got the ball back in the first place. 301 00:32:06,820 --> 00:32:15,430 He manages to score a goal and is very happy. And what I like about this goal in particular and now going to do the same thing, 302 00:32:15,430 --> 00:32:22,600 but analyse it from this top down view and I'll just let it play to start with so you can get a feeling for it. 303 00:32:22,600 --> 00:32:26,710 So this is the opposition. It's stones foul attacking. They take the shot, the ball comes back. 304 00:32:26,710 --> 00:32:31,300 Moyo is twenty two. He collects it. Nico opens up space here. 305 00:32:31,300 --> 00:32:35,710 Alex opens up space here. Nico still got this lovely space here. 306 00:32:35,710 --> 00:32:43,360 All the time, keeps it, keeps it keeps that. Then the attacking players come in and score a goal and so we can actually 307 00:32:43,360 --> 00:32:48,790 see how they're controlling and using space in the build up for those goals. 308 00:32:48,790 --> 00:32:54,460 These points are very important because one thing we talked about a lot was defence. 309 00:32:54,460 --> 00:33:01,150 You need to come back and defend. Even as an attacking midfielder, Moyo is a player who always wants to run up and score goals. 310 00:33:01,150 --> 00:33:03,520 But if he's standing around here, 311 00:33:03,520 --> 00:33:11,080 then we actually when when the shot comes in and it's controlled by the defender or it's headed away by the defender, 312 00:33:11,080 --> 00:33:15,910 we control a lot of the area outside our box and they don't control that. 313 00:33:15,910 --> 00:33:20,320 And so if you think of the ball is just sort of bouncing out a random direction, 314 00:33:20,320 --> 00:33:24,760 we're going to control a lot of the places where it could balance out, too. 315 00:33:24,760 --> 00:33:29,830 And here's another where a few seconds later, you see Alex controls the space in front of him. 316 00:33:29,830 --> 00:33:32,560 Alex is No. 20. He's running in this direction. 317 00:33:32,560 --> 00:33:39,310 Nico is number 40 running in this direction, and they've started to control the attacking space on their way out. 318 00:33:39,310 --> 00:33:43,690 And so you can actually get an idea about what spaces we're controlling. 319 00:33:43,690 --> 00:33:50,440 Another thing you can do is you can look at past probabilities. This is when Alex sent the pass out to Nico. 320 00:33:50,440 --> 00:33:54,820 This is basically 100 percent success rate expected from our model. 321 00:33:54,820 --> 00:34:03,850 We calculate all the possible passes he could make, and we could say Alex could have tried to play the ball through to Moyo straight away. 322 00:34:03,850 --> 00:34:11,590 We have a 60 percent on that, but he has a 98 percent chance if he passes through to Nico. 323 00:34:11,590 --> 00:34:19,030 Then a few seconds later, we have this situation, and then we found out that now Nico has a 65 percent chance to Moyo. 324 00:34:19,030 --> 00:34:25,270 He could have also taken the post further away, but if he takes the post further away, 325 00:34:25,270 --> 00:34:31,900 then he's got a worse angle for the striker that so the best decision is to take the 65 percent chance which he takes. 326 00:34:31,900 --> 00:34:38,890 And on this score. And so we can use this type of technique basically to improve the positioning. 327 00:34:38,890 --> 00:34:42,880 This is a project together with Fran Peralta, who did. 328 00:34:42,880 --> 00:34:49,990 This is a master's thesis. I've been I've become incredibly popular in my university when it comes to writing master's thesis. 329 00:34:49,990 --> 00:34:55,810 Like, I get a lot of requests to do this and I know that most of them do. 330 00:34:55,810 --> 00:35:01,390 I do manage to find the time for them because it's so many exciting cycling projects to do in maths and football. 331 00:35:01,390 --> 00:35:06,010 But Fran wrote a master's thesis doing this and what our idea was. 332 00:35:06,010 --> 00:35:15,760 We can actually feedback and improve the performance of play, and I feel I take another example from Barcelona. 333 00:35:15,760 --> 00:35:19,810 I think this is a lovely. So what do you think is the most important? 334 00:35:19,810 --> 00:35:25,520 Maybe I'll have? This is a sort of test. What's the most important thing that happens in this sequence? 335 00:35:25,520 --> 00:35:32,150 Have I got any suggestions, anyone? So the girl, the that guy in the left is very important. 336 00:35:32,150 --> 00:35:40,630 He runs and gets the ball. Is this the one? You mean it's going to spread the cost? 337 00:35:40,630 --> 00:35:51,440 Him here. Yes, he's very he gets the bullets, so he's very important, but I think that the absolute most important thing is this run here. 338 00:35:51,440 --> 00:36:00,350 Because what that run does is it opens up space for the for the player on the left so he can run through onto it, 339 00:36:00,350 --> 00:36:09,120 and you can actually see that in this picture. So here is the top down view again, 340 00:36:09,120 --> 00:36:19,140 the ball is coming from here in the past is going to there and you can see as the player as the player here moves inwards, 341 00:36:19,140 --> 00:36:28,820 it opens up a green space for an elbow on the left. And so it's the movement actually opens up for the other players. 342 00:36:28,820 --> 00:36:32,990 And we can actually simulate how the football players move. 343 00:36:32,990 --> 00:36:37,100 And this idea comes from a lot of what we worked on with animal behaviour. 344 00:36:37,100 --> 00:36:44,270 We can simulate one or two seconds into the future because when animals try and avoid colliding with each other, 345 00:36:44,270 --> 00:36:49,730 they tend to anticipate where other animals are moving to and move into open space. 346 00:36:49,730 --> 00:36:53,140 And so we can anticipate what happens into the future. 347 00:36:53,140 --> 00:37:01,280 We can say to the players, you can anticipate what's going to happen into the future, where should you move optimally in such situations? 348 00:37:01,280 --> 00:37:06,830 And we can simulate that. This is an example of a right back. He was quite a long way from the play. 349 00:37:06,830 --> 00:37:14,990 We have an optimal position. He should move out here. In fact, he moves quite centrally, so he doesn't really move in an optimal position. 350 00:37:14,990 --> 00:37:23,150 But what we actually find about the attacking midfielder here is he did move in a perfectly optimal way. 351 00:37:23,150 --> 00:37:29,690 So his run where he if you look at the run, it starts, he runs like this and then he stops like that, 352 00:37:29,690 --> 00:37:34,130 and you could classify that as being quite lazy that you then kind of, yeah, OK. 353 00:37:34,130 --> 00:37:39,410 But he actually, the way he stops when we calculated it in the model was optimal. 354 00:37:39,410 --> 00:37:46,500 He had the best stopping position. And this is the sort of thing that we can use with the players, and we've been doing this, 355 00:37:46,500 --> 00:37:55,140 how maybe we're basically starting doing this, maybe just now where we can give them feedback. 356 00:37:55,140 --> 00:37:58,650 Now I have to. Yeah, so this was this was a very nice example where we got the ball back. 357 00:37:58,650 --> 00:38:03,810 You shouldn't shoot from there, actually, but so we'll forget, we'll forget about the shot. 358 00:38:03,810 --> 00:38:13,080 We talked about that, too. What I'd like to point out here is that the press play here, so they've got the ball and we organised. 359 00:38:13,080 --> 00:38:15,330 So we've got man marking very nearby. 360 00:38:15,330 --> 00:38:22,860 But we also control all of the space so we can measure how we're managing to press them and how we're controlling the space around the team. 361 00:38:22,860 --> 00:38:30,060 And we could calculate with this was their actual position is a shadow picture, the shadow dot and their real position. 362 00:38:30,060 --> 00:38:36,150 And we could actually show the players afterwards that you were pretty much optimally positioned in that type of press. 363 00:38:36,150 --> 00:38:41,180 I'll take the question afterwards. 364 00:38:41,180 --> 00:38:48,770 There's lots we can do, this was this was this was one of my favourites, because can I say another thing about football players? 365 00:38:48,770 --> 00:38:56,090 They're so sweet, like you see them out on the pitch and they're like, really angry and angry, and I should have been a foul referee. 366 00:38:56,090 --> 00:39:00,770 But like, when you meet them, they're like the nicest people you left me. 367 00:39:00,770 --> 00:39:06,920 They're really sweet and mild mannered. And David's, you know, it's OK if you tell me about this or something. 368 00:39:06,920 --> 00:39:12,560 And this is an example. So this this what I was just showing here. This is Emad Khalili. 369 00:39:12,560 --> 00:39:18,490 He played the following pass. And it went out there and it didn't get to the player. 370 00:39:18,490 --> 00:39:26,800 And if you want to show this one more time, here we go. 371 00:39:26,800 --> 00:39:35,530 If you look at Moyo, there is like really annoyed with Armand because he wanted the ball and Imat didn't pass into. 372 00:39:35,530 --> 00:39:42,430 And so afterwards, Imad asked me, You know, did I make the right decision in making this pass? 373 00:39:42,430 --> 00:39:48,320 And you could actually see that given the percentages. There was a very small margin that he could get it to. 374 00:39:48,320 --> 00:39:55,210 Moyo And though the board didn't quite get to their left back, it was the right decision to play that pass. 375 00:39:55,210 --> 00:40:02,670 So you can actually use the model to evaluate how you're playing after after the game. 376 00:40:02,670 --> 00:40:10,910 Right. That's a lot in my experience and how it's been working out in using this type of mathematics, this type of applied mathematics. 377 00:40:10,910 --> 00:40:17,600 And now I come back to my major point, what is it that applied mathematicians have got in all of these examples? 378 00:40:17,600 --> 00:40:23,660 We start with data. We start building up models and then we try and fit our models to data. 379 00:40:23,660 --> 00:40:30,110 And that's basically how we cycle through in everything that we do, all of the projects that we study. 380 00:40:30,110 --> 00:40:34,940 And that's really what I think makes applied mathematicians quite quite special. 381 00:40:34,940 --> 00:40:43,310 And we have got one very special applied mathematician here, and I learnt I myself learnt a lot of this art from from Philip. 382 00:40:43,310 --> 00:40:54,290 And I had a room of Philip that you have actually written to Premier League clubs and said you've lost him or, you know, you've sacked your manager, 383 00:40:54,290 --> 00:41:01,940 you need a new manager and you have a collection of you don't have any any except unless you have a collection of rejection letters. 384 00:41:01,940 --> 00:41:09,500 Is that correct? They're not rejection letters. They're considered, Oh, they're considering it, right? 385 00:41:09,500 --> 00:41:15,110 Well, I think if anyone would like to pose the question we can ask, ask Philip about the contents and some of these letters afterwards. 386 00:41:15,110 --> 00:41:20,150 But I think unfortunately, Philip, I mean, we're here to celebrate your 40th birthday. 387 00:41:20,150 --> 00:41:25,640 Was it way? Unfortunately, I think it might be too late for you because one thing I've learnt, 388 00:41:25,640 --> 00:41:30,530 for example, Stefan Billboard, who's the manager of Hammarby, is quite an analytic person. 389 00:41:30,530 --> 00:41:35,330 Actually, I think Marino is a bit more analytic than I gave him credit for at the start. 390 00:41:35,330 --> 00:41:42,050 And certainly, Claudia is an analytic person. Plus, it's an incredibly difficult job. 391 00:41:42,050 --> 00:41:48,020 So we've probably got quite a lot of academics here in the room. And you know how it is when you get your paper rejected, 392 00:41:48,020 --> 00:41:53,840 how horrible it is for your fellow students who've written spent so much time working on it and so on. 393 00:41:53,840 --> 00:41:59,450 Think about being a manager and how you have to go into work after losing a match and get everyone. 394 00:41:59,450 --> 00:42:01,850 You've got twenty two students to take care of. 395 00:42:01,850 --> 00:42:08,300 In this case, 20 to 30 students and lift up their morals is a really, really difficult job to keep going. 396 00:42:08,300 --> 00:42:14,060 I've got a lot of respect now for being a football manager, but I do think. 397 00:42:14,060 --> 00:42:22,940 That there is this future, I think that there will be some point in the future where these types of mathematicians like Bob and Sarah and Javier, 398 00:42:22,940 --> 00:42:31,020 there is a chance that they might be managing football clubs or be very close to being an important decision making roles within those clubs. 399 00:42:31,020 --> 00:42:40,470 So I do think there's this inspiring possibility for a future where an applied mathematician can make a difference at a football club. 400 00:42:40,470 --> 00:43:04,404 And I think that was all I have to say. Thank you very much.