Tournament Schedule - Golf pairing

JT123

New Member
Joined
Jul 20, 2024
Messages
1
Office Version
  1. 2021
Platform
  1. Windows
We have 12 players, divided into 2 teams of 6, playing 6 rounds of golf. I want each player to play at least once with every player in their own team. In every fourball, there should be 2 players from each team. The matchups against the opposing team should be as evenly distributed as possible.

Can someone please help me with this?
 

Excel Facts

Lock one reference in a formula
Need 1 part of a formula to always point to the same range? use $ signs: $V$2:$Z$99 will always point to V2:Z99, even after copying
Welcome to the MrExcel forum!
We get a lot of these kind of golf pairing questions. Every one is a little different. And as you've found out, these questions are usually really hard! So I ended up just writing a program that randomly set up the pairings, calculated how good it was, and repeat until I found something decent. I ran over 100,000 iterations, and I actually got a result better than I expected. Here it is:

Book1
LMNOPQR
1Team 1Team 2RoundFoursome 1Foursome 2Foursome 3
2AU1DFWYACXZBEUV
3BV2EFUWBDYZACVX
4CW3DEUXABYZCFVW
5DX4AFWZCEVYBDUX
6EY5BFWXCDVYAEUZ
7FZ6ADXYBCUWEFVZ
Sheet2


This works quite well. Every player on team 1 plays with every other player on team 1 at least once. Every player on team 2 plays with every player on team 2 at least once, except for U and Y. Moreover, every player on team one plays with every player on team 2 at least once, and vice versa.

Hope this helps! 🏌️
 
Upvote 0
I ran a few more iterations, and I got another option:

Book1
LMNOPQR
1Team 1Team 2RoundFoursome 1Foursome 2Foursome 3
2AU1CDUWEFXYABVZ
3BV2ACUXBFVWDEYZ
4CW3BCWXDFVYAEUZ
5DX4AEXZCFWYBDUV
6EY5CFVXBEWZADUY
7FZ6CEUVBDXYAFWZ
Sheet3


This one has every player on team 1 playing with every player on team 1 at least once, and every player on team 2 playing with each player on team 2 at least once. But C is never in a foursome with Z, and F is never in a foursome with U. So it just depends on what your priorities are. I may play around a bit more, but I think it's unlikely I can improve on these.

🏌️🏌️🏌️🏌️
 
Upvote 0
After a few million iterations, I found one where everyone plays with everyone at least once:

Book1
LMNOPQR
1Team 1Team 2RoundFoursome 1Foursome 2Foursome 3
2AU1EFXZABUVCDWY
3BV2BFVYDEUZACWX
4CW3BEWXCFUYADVZ
5DX4BDYZAFUWCEVX
6EY5DEUVABXYCFWZ
7FZ6BCVWAEYZDFUX
Sheet3


OK, no more tonight.
 
Upvote 0
Here is my attempt:

You just need 5 rounds for one team to play with each other. But as requested there are 6 round. The Pseudo-random generated sequence can be changed, changing the cell B2 (which can be any number. It is just formated as date).

It is guaranteed that each player is playing every other team member within the first 5 rounds. Last round is random (actually just the first row of a new sequence of 5 rows).

GolfPairing.xlsx
ABCDEFG
1
2Rnd Num Gen Seed17/01/2024RoundsFoursome 1Foursome 2Foursome 3
31A4 - A5 - B4 - B5A3 - A6 - B3 - B6A1 - A2 - B1 - B2
42A4 - A2 - B5 - B6A1 - A3 - B4 - B2A5 - A6 - B1 - B3
53A6 - A2 - B6 - B2A5 - A3 - B5 - B3A1 - A4 - B1 - B4
64A6 - A4 - B2 - B3A2 - A3 - B6 - B4A1 - A5 - B1 - B5
75A3 - A4 - B1 - B6A1 - A6 - B2 - B5A2 - A5 - B3 - B4
86A4 - A5 - B3 - B6A1 - A2 - B1 - B2A3 - A6 - B4 - B5
Teams + Calculation
Cell Formulas
RangeFormula
E3:G7E3=LET( comb, LAMBDA(nt,seed, LET(n,nt, i,SEQUENCE(n-1,,0), k,INT((SEQUENCE(,n-2)+1)/2), s,IF(ISODD(SEQUENCE(,n-2)),1,-1), res,HSTACK(EXPAND(1,n-1,,1),i+2,MOD(i+k*s,n-1)+2), rows,WRAPROWS(TOCOL(res),2), pairs,BYROW(rows,LAMBDA(x,CHOOSECOLS(x,1)&" - "&CHOOSECOLS(x,2))), nPairs,(n-1)*(n/2), randomNumbers,DROP(REDUCE(seed*(2^31-1)/73051,SEQUENCE(nPairs),LAMBDA(x,y,VSTACK(x,MOD(48271*CHOOSEROWS(x,-1),2^31-1)))),1)/(2^31-1), randomOrder,INT(SEQUENCE(nPairs,,0)/(n/2))+1+randomNumbers, orderedPairs,SORTBY(pairs,randomOrder), final,WRAPROWS(orderedPairs,n/2), final) ), n, 12, seed, $B$2, GA, "A"&TEXTSPLIT(TEXTJOIN(" - ", ,comb(n/2, seed)), " - "), GB, "B"&TEXTSPLIT(TEXTJOIN(" - ", ,comb(n/2, seed+15)), " - "), GAc, WRAPROWS(GA, 2), GBc, WRAPROWS(GB, 2), AB, HSTACK(GAc, GBc), res, BYROW(AB, LAMBDA(x, TEXTJOIN(" - ",, x))), WRAPROWS(res, 3) )
E8:G8E8=LET( comb, LAMBDA(nt,seed, LET(n,nt, i,SEQUENCE(n-1,,0), k,INT((SEQUENCE(,n-2)+1)/2), s,IF(ISODD(SEQUENCE(,n-2)),1,-1), res,HSTACK(EXPAND(1,n-1,,1),i+2,MOD(i+k*s,n-1)+2), rows,WRAPROWS(TOCOL(res),2), pairs,BYROW(rows,LAMBDA(x,CHOOSECOLS(x,1)&" - "&CHOOSECOLS(x,2))), nPairs,(n-1)*(n/2), randomNumbers,DROP(REDUCE(seed*(2^31-1)/73051,SEQUENCE(nPairs),LAMBDA(x,y,VSTACK(x,MOD(48271*CHOOSEROWS(x,-1),2^31-1)))),1)/(2^31-1), randomOrder,INT(SEQUENCE(nPairs,,0)/(n/2))+1+randomNumbers, orderedPairs,SORTBY(pairs,randomOrder), final,WRAPROWS(orderedPairs,n/2), final) ), n, 12, seed, $B$2+77, GA, "A"&TEXTSPLIT(TEXTJOIN(" - ", ,comb(n/2, seed)), " - "), GB, "B"&TEXTSPLIT(TEXTJOIN(" - ", ,comb(n/2, seed+15)), " - "), GAc, WRAPROWS(GA, 2), GBc, WRAPROWS(GB, 2), AB, HSTACK(GAc, GBc), res, BYROW(AB, LAMBDA(x, TEXTJOIN(" - ",, x))), TAKE(WRAPROWS(res, 3),1) )
Dynamic array formulas.
Cells with Conditional Formatting
CellConditionCell FormatStop If True
E3:G8Expression=SUM((TEXTSPLIT(E3, " - ")=$K$4)*1)textNO
E3:G8Expression=SUM((TEXTSPLIT(E3, " - ")=$K$3)*1)textNO


Here is the working file to download:

GolfPairing.zip

I added some conditional formatting to highlight the players in cells K3 and K4 for an easy check.

1721659326231.png
 
Last edited:
Upvote 0

Forum statistics

Threads
1,223,239
Messages
6,170,947
Members
452,368
Latest member
jayp2104

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top