Schedule creation utility

For Fantasy Football related chat that doesn't come under any of other forum categories.

Moderator: TFF Mods

Post Reply
User avatar
christer
Star Player
Star Player
Posts: 565
Joined: Sat Jun 08, 2002 8:54 am
Location: Stockholm, Sweden
Contact:

Schedule creation utility

Post by christer »

Heh.. I can't find the thread I promised to make this available.. :oops:

Anyway, Here's a link to my small schedule creation utility. It's nowhere near finished or anything.. Mostly just a small hack...

http://trollcave.no-ip.org/Schedule.zip

This is Java, so you need a java runtime environment (JRE or JDK)..
Also, I included the sourcecode if anyone's interested in how I did it.

Some notes about the program:

* All references to graphs, colours, edges and vertices come from the fact that the scheduling problem is equivalent to a well-known class of problems which can be derived from "graph colouring". For you who don't care about math: Graph = Schedule, Colour = Round, Edge = Match and Vertex = Team

* This program uses an iterative algorithm (iterated greedy graph colouring), which means that it can take quite a while to generate some schedules. On my system (athlon 500MHz), it normally takes less than 10 seconds to generate a 16-team schedule. 17 teams should be possible within a reasonable amount of time. 18 or more will probably take quite a bit of time. One thing to remember though. There is a random element to the algorithm so if you're lucky, you could generate a 30 team schedule instantly (No, don't try.. It's very unlikely)

* You run the program by typing "java Schedule 12", where the 12 is the number of teams you have. You exit the program by pressing ctrl-c in the console window. I haven't bothered to add the three-line quit code into the program. Remember, this is a hack.. :)

* When you run it, you'll get a window with lots and lots of checkboxes. Basically, this is a table of which matches you want to schedule, with the teams being on both the x and the y axis. You check the boxes you want to prevent from being scheduled. When you're done selecting you press the "Create" button.

* The output will be displayed in the console window, looking something like this:

Colour 1:
1 - 2
3 - 4

Colour 2:
1 - 3
2 - 4

Colour 3:
1 - 4
2 - 3

Again, replace colour with round, and you'll have a table of matches to be played for every round.

* There is no way to "stop" searching and display the current "best" solution. The program will continue to run until it finds an optimal (or what the program considers optimal. Read the source if you're interested) solution.

Questions, comments, ideas.. feel free to vent. I can't guarantee I'll modify the program though.. But if enough people think it would be useful, I might consider polishing it a bit...

-- Christer

Reason: ''
User avatar
neoliminal
Ex-Mega Star, now just a Super Star
Ex-Mega Star, now just a Super Star
Posts: 1472
Joined: Thu Jan 01, 1970 12:00 am
Location: Utrecht
Contact:

hi!

Post by neoliminal »

Will it do swiss format?

Reason: ''
User avatar
christer
Star Player
Star Player
Posts: 565
Joined: Sat Jun 08, 2002 8:54 am
Location: Stockholm, Sweden
Contact:

Post by christer »

I have no idea.. What's that? A schedule with holes in it?

Sorry.. Couldn't resist.. And I honestly don't know what swiss format is..

-- Christer

Reason: ''
longfang
Legendz Bedo Legend
Posts: 1822
Joined: Wed Jun 27, 2001 12:00 am
Location: T5
Contact:

Post by longfang »

I'm sure an explanation will be along shortly!

Reason: ''
[size=75]Del. [color=red]Tramp Champ. Media Tart.[/color][/size]

[url=http://www.talkbloodbowl.com/phpBB2/viewtopic.php?t=14334#t=14334]Hall of Famer[/url]
Deathwing
The Voice of Reason
Posts: 6449
Joined: Tue Jun 26, 2001 12:00 am
Contact:

Post by Deathwing »

Ladder system, where the teams pair off from the top for the following round. So winners play winners, losers play losers etc. All you need is the ranking system!

Reason: ''
Image

"Deathwing treats newcomers like sh*t"
"...the brain dead Mod.."
longfang
Legendz Bedo Legend
Posts: 1822
Joined: Wed Jun 27, 2001 12:00 am
Location: T5
Contact:

Post by longfang »

Told you :roll:

Reason: ''
[size=75]Del. [color=red]Tramp Champ. Media Tart.[/color][/size]

[url=http://www.talkbloodbowl.com/phpBB2/viewtopic.php?t=14334#t=14334]Hall of Famer[/url]
User avatar
christer
Star Player
Star Player
Posts: 565
Joined: Sat Jun 08, 2002 8:54 am
Location: Stockholm, Sweden
Contact:

Post by christer »

Ok.. This utility will not make swiss format scheduling.

You can use this utility for predetermined schedules. What it does is to schedule matches in as few rounds as possible while allowing only one game per team and round.

-- Christer

Reason: ''
User avatar
Anthony_TBBF
Da Painta
Posts: 1822
Joined: Mon Jun 25, 2001 12:00 am
Location: Toronto, Canada

Post by Anthony_TBBF »

If you can get it to do Swiss format scheduling that would rock. Doing it by hand at the Orion tournament was a pain in the a**. In fact, a good tournament manager would be amazing. *hint* ;)

Reason: ''
Image
The TBBf is back! http://tbbf.obblm.com/
User avatar
christer
Star Player
Star Player
Posts: 565
Joined: Sat Jun 08, 2002 8:54 am
Location: Stockholm, Sweden
Contact:

Post by christer »

I will not make this tool do swiss-format scheduling. This tool is more a "proof of concept" app, and has no knowledge of ratings, teams, standings or anything.

Now, suppose I were to create a tournament manager.. What kind of features would you want?

-- Christer

Reason: ''
User avatar
christer
Star Player
Star Player
Posts: 565
Joined: Sat Jun 08, 2002 8:54 am
Location: Stockholm, Sweden
Contact:

Post by christer »

Created a new thread for league manager issues.

http://www.talkbloodbowl.com/phpBB2/vie ... hp?p=13569

-- Christer

Reason: ''
User avatar
Anthony_TBBF
Da Painta
Posts: 1822
Joined: Mon Jun 25, 2001 12:00 am
Location: Toronto, Canada

Post by Anthony_TBBF »

Hmm for tournament management, my wish list would be:

- automatic pairings based on format (Swiss, round robin etc.)
- calculation of rankings from round to round
- summary of different stats (most TDs etc)

That's off the top of my head.

Reason: ''
Image
The TBBf is back! http://tbbf.obblm.com/
Post Reply