draw icon indicating copy to clipboard operation
draw copied to clipboard

Algorithm for UCL League Phase draw

Open rolux opened this issue 10 months ago • 0 comments

Can anyone give me a concise description of the algorithm for the UCL League Phase draw?

I have read the code in src/engine/dfs/ls, but I find it hard to understand.

Specifically, is it possible to draw valid matches first (1 home + 1 away match per pot, no opponent from the same country, not more than two opponents from any other country), and then reliably compute a valid schedule later (no "HH" or "AA" in rounds 1+2 and 7+8, no "HHH" or "AAA" in any three rounds, each team plays once in each round)?

(I have a working python script that simulates the draw round by round, match by match, but it has taken several hours to find a valid solution.)

Thanks in advance!

rolux avatar Feb 03 '25 22:02 rolux