News‎ > ‎

Computer Aided Design of Football Teams

posted Feb 4, 2014, 4:46 AM by Alberto Bartoli   [ updated Feb 4, 2014, 8:31 AM by Eric Medvet ]
This is quite an unusual post. It describes a for-fun application of a topic well-known in engineering and research: multiobjective optimization. We decided to blog about this anyway, because it may be of some interest for our students—and because it is funny.

Three of us are part of a group of friends that (attempt to) play football every week. The group is composed by more or less the same people, but the specific set of players varies each week—injuries, busy day and so on. We organized a tournament with several rankings amongst us: number of goals, number of points and alike.

Big problem: how do we generate balanced teams?

Age ranges in between 28 and 60. Some of us resemble to a midfield, some others resemble to a forward. Some of us run a lot, while others have a more contemplating attitude. Having balanced teams is essential in order to have fun. After a few weeks, our lab came up with a great idea, i.e., a computer-based procedure based on multiobjective optimization (mostly thanks to Eric, both in the design and the implementation).

After one year and a half of weekly matches, the results of the procedure have been really excellent. Nearly all matches have been very balanced, with uncertain result until the very end. Most importantly, the procedure has proven to work well because in many cases the teams appeared to be unbalanced but the match turned out to be much more uncertain than expected, often with a totally unexpected winning team.

Multiobjective optimization is a technique used in many disparate fields of engineering, economy and logistics. It is used when it is necessary to optimize several contrasting objectives. For example, the design of an engine could have 3 objectives: maximizing performance, minimizing fuel consumption, minimizing pollution. These are contrasting objectives. In practice, the designer analyzes many possible designs and chooses the resulting trade-off (compromise) that appears to be better.

Teams are generated a few hours before the match based on the available players. We proceed as follows.

Each player has several attributes. Some of them are fixed and chosen a priori: dynamic / static (i.e., it runs a lot or not...); defender / midfield / forward; age. Other vary during the competition: goals scored, points and alike.

Based on the set of available players for the current day, the system:
  • Generates all possible alignments, i.e., pairs of teams. Each pair is a candidate.
  • For each candidate, it computes 5 numbers. These numbers are the (unsigned) differences between indexes associated with each team based on its players: 
    • Average age.
    • Average number of goals scored for each match.
    • Average number of points for each match.
    • Number of players in each field sector (e.g., if a team has 3 defenders and 2 forwards while the other has 2 defenders and 4 forwards, then this index is |3-2|+|2-4|=3).
    • Number of dynamic and static players.
  • Consider only candidates that, in at least one of these features, are better than all the other candidates. In other words, every candidate that is not better of all the others from any point of view is discarded.
  • Choose one of the remaining candidates at random.
In other words, each candidate is associated with a point in a 5-dimensional space. Ideal candidates are those in the origin and usually they do not exist. At the next-to-last step al "dominated" candidates are discarded and only those on the Pareto front are considered.

Of course, the procedure is not ideal. Features of a player cannot be synthesized by a few numerical quantities: how to capture creativity, genius, luck, occasional lack of sleep or excessive food? Features of a team cannot be obtained by merely assembling parameters of its players. The creativity of a set of players may be much bigger than the mere sum of its components—much like an orchestra. Similarly, two forwards with similar features, or competing among themselves, could not be a good mix.

However, after one year and a half of weekly matches, the results of the procedure have been really excellent, as pointed out above.

The only slightly weak point so far is when a new player comes in: in those cases the system has an insufficient amount of information about that player, hence his contribution to goals and points does not reflect his actual value, which may result in teams slightly more unbalanced than usual.

The figure at the beginning shows the teams generated for today...