|
Input/output data format is XML, with the following structure:
<?xml version="1.0" encoding="UTF-8"?>
<!--Purdue University Timetabling-->
<timetable version="2.1" term="2006Fal" created="Tue Mar 28 14:20:34 EST 2006" nrDays="7" slotsPerDay="288">
Header attributes:
attribute | description |
version | data format version |
term | term (e.g., 2004Fal or 2005Spr) |
created | date of generation of this file |
nrDays | number of days per week |
slotsPerDay | number of time slots per day |
<rooms>
<room id="1" capacity="40" location="460,438"/>
<room id="2" capacity="44" location="465,485"/>
<room id="3" capacity="49" location="451,435"/>
...
<room id="51" capacity="474" location="476,445"/>
</rooms>
Room attributes:
attribute | description |
id | room identification |
capacity | room capacity |
location | room location coordinates [x,y] |
Distance between rooms in meters: 10 * ((x2-x1)^2 + (y2-y1)^2)^1/2
<classes>
<class id="1" course="1" expectedCapacity="127" roomCapacity="127" nrRooms="1" department="1" startDay="233" endDay="344">
<instructor id="1" solution="true"/>
<room id="51" pref="0"/>
<room id="50" pref="0"/>
<room id="37" pref="0" solution="true"/>
<room id="36" pref="0"/>
<time days="1010100" start="90" length="12" pref="32"/>
<time days="1010100" start="102" length="12" pref="0"/>
<time days="1010100" start="114" length="12" pref="0"/>
<time days="1010100" start="126" length="12" pref="0" solution="true"/>
<time days="1010100" start="138" length="12" pref="0"/>
<time days="1010100" start="150" length="12" pref="0"/>
<time days="1010100" start="162" length="12" pref="0"/>
<time days="1010100" start="174" length="12" pref="0"/>
<time days="1010100" start="186" length="12" pref="0"/>
<time days="1010100" start="198" length="12" pref="8"/>
</class>
<class id="2" course="2" expectedCapacity="58" roomCapacity="58" nrRooms="1" department="1" startDay="233" endDay="344">
<instructor id="2" solution="true"/>
<room id="29" pref="0"/>
...
<time days="1010100" start="90" length="12" pref="13"/>
...
</class>
...
<class id="822" course="638" expectedCapacity="52" roomCapacity="52" nrRooms="1" department="64" startDay="233" endDay="344">
<instructor id="466" solution="true"/>
<room id="20" pref="-2" solution="true"/>
...
<days="1000000" start="90" length="12" pref="4" solution="true"/>
...
</class>
</classes>
Class attributes:
attribute | description |
id | class identification |
course | course identification (classes are grouped into courses) |
expectedCapacity | expected number of students attending the class |
roomCapacity | minimal size of the room that can be used |
nrRooms | number of rooms the class needs (it is usually 1, but there are some cases where a class needs two rooms) |
department | department identification (each class belongs to a department) |
startDay endDay | interval of days when the class is being taught (e.g., there are some classes that take place only in the first half of the term) |
A class can contain an instructor. It also contains one or more rooms and one or more times where it can take place.
Only the valid instructors, rooms and times are listed (e.g., there is no need to check class.roomCapacity with room.capacity).
If there is a solution (class is placed somewhere), it consists from a selection of one instructor (if there is one), class.nrRooms rooms and one time.
Instructor attributes:
attribute | description |
id | instructor identification |
solution | true, if this instructor belongs to the solution (i.e., placement of this class that is in the solution contain this instructor) |
Room attributes:
attribute | description |
id | room identification |
pref | room preference (combined from room preference, building preference and preferences on room features) |
solution | true, if this room belongs to the solution (i.e., placement of this class that is in the solution contains this room) |
Time attributes:
attribute | description |
days | a bitmap of days (first Monday, second Tuesday, ...), e.g., 1010100 means Monday+Wednesday+Friday |
start | stating slot (0 ... timetable.nrSlotsPerDay-1) |
length | length of class, in the number of slots (it's here because there can be alternatives, e.g., 2x75 or 3x50) |
pref | normalized time preference on the given time |
solution | true, if this time belongs to the solution (i.e., placement of this class that is in the solution contain this time) |
<groupConstraints>
<constraint id="1" type="BTB" pref="R">
<class id="390"/>
<class id="391"/>
</constraint>
...
<constraint id="25" type="BTB_TIME" pref="2">
<class id="509"/>
<class id="510"/>
<class id="511"/>
<class id="512"/>
</constraint>
...
<constraint id="177" type="DIFF_TIME" pref="R">
<class id="115"/>
<class id="114"/>
<class id="113"/>
<class id="112"/>
</constraint>
</groupConstraints>
Group (distribution) constraint attributes:
Each group constraint has defined its type, its preference or requirement and a list of classes.
attribute | description |
id | constraint identification |
type | constraint type (see [Group Constraint Types]) |
pref | constraint is either required or prohibited (hard constraint):
R .. constraint is required,
P .. constraint is prohibited
or it is preferred or discouraged (soft constraint):
-2 .. strongly preferred,
-1 .. preferred,
1 .. discouraged,
2 .. strongly discouraged |
<students>
<student id="1">
<class id="786"/>
<class id="791"/>
</student>
<student id="2">
<class id="583"/>
</student>
...
<student id="29035">
<class id="630"/>
</student>
</students>
Each student contains a list of classes s/he is enrolled in.
In order to keep number of student conflicts as low as possible, enrollments of two students which are enrolled in different classes of the same course can be swapt.
</timetable>
|