Post Reply 
Programming puzzles: processing lists!
08-15-2017, 02:50 PM
Post: #180
RE: Programming puzzles: processing lists!
(08-14-2017 12:12 PM)pier4r Wrote:  edit3:
Ok the new hash function seems to be more robust (although not proven).
4 teams, 3 match days
6 teams, 15 match days
8 teams, 100 match days
10 teams, 870 match days

I've got a work-in-progress version of a routine that attempts to do this on a 50g, but it's still got some major issues. I keep seeing "reflected" match days in the results as the team size grows, and it slows down intolerably at >6 teams.

If I sort and de-dup the results, it appears to come up with reasonable-looking pairings. I haven't validated them beyond checking for duplicates and just visually scanning for "gross and obvious" failures, so I'm not claiming this to be complete or accurate. I had to leave it running for a while on an emulated 50g (I didn't time it but I think it was >1 hour), so the current approach isn't really viable. I'm attaching my 8-team result so that you might be able to compare the match-days with yours. My current test found 105 possible pairings:

Code:
1-2 3-4 5-6 7-8
1-2 3-4 5-7 6-8
1-2 3-4 5-8 6-7
1-2 3-5 4-6 7-8
1-2 3-5 4-7 6-8
1-2 3-5 4-8 6-7
1-2 3-6 4-5 7-8
1-2 3-6 4-7 5-8
1-2 3-6 4-8 5-7
1-2 3-7 4-5 6-8
1-2 3-7 4-6 5-8
1-2 3-7 4-8 5-6
1-2 3-8 4-5 6-7
1-2 3-8 4-6 5-7
1-2 3-8 4-7 5-6
1-3 2-4 5-6 7-8
1-3 2-4 5-7 6-8
1-3 2-4 5-8 6-7
1-3 2-5 4-6 7-8
1-3 2-5 4-7 6-8
1-3 2-5 4-8 6-7
1-3 2-6 4-5 7-8
1-3 2-6 4-7 5-8
1-3 2-6 4-8 5-7
1-3 2-7 4-5 6-8
1-3 2-7 4-6 5-8
1-3 2-7 4-8 5-6
1-3 2-8 4-5 6-7
1-3 2-8 4-6 5-7
1-3 2-8 4-7 5-6
1-4 2-3 5-6 7-8
1-4 2-3 5-7 6-8
1-4 2-3 5-8 6-7
1-4 2-5 3-6 7-8
1-4 2-5 3-7 6-8
1-4 2-5 3-8 6-7
1-4 2-6 3-5 7-8
1-4 2-6 3-7 5-8
1-4 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2-7 3-4 5-6
1-8 2-7 3-5 4-6
1-8 2-7 3-6 4-5
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Programming puzzles: processing lists! - DavidM - 08-15-2017 02:50 PM



User(s) browsing this thread: 1 Guest(s)