@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Encoding of the predicates used to generate the timetable.
These include:
_timesteps which represent a full week (1 timestep = 2 hours, 5 timesteps per day)
_units, how many hours they should be taught per week and how many hours each student enrolled should attend,
_students, who take units and attend lectures,
_lecturers, who teach units (at preferred teaching times and not when they have other commitments),
_rooms and their student capacity.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Encoding of Timetabling logic.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Schedules H lectures in a room at a specified timestep, where lecturers teach their unit and students attend it H times.
Also satisfies some requirements for the basic functional system stated in the coursework specification, including:
_ students should have all their units scheduled,
_ lecturers should have all their units scheduled.
Note: by including the atoms generated in the first generator into the second one, the rules/constraints applied to schedule lectures for lectures
are inherited by students since they can only attend lectures which are correctly scheduled (fit all the requirements specified).
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Schedules H lectures to be taught by a lecturer L, in a room R (with student capacity C), for a unit U, at timestep T.
H corresponds to the H of the 'hoursUnit(H,U)' predicate found in 'atoms.lp', which corresponds to the number of lectures that should be scheduled for each unit.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Schedules which lectures a student S should attend for units U he is enrolled in, in a room R (with student capacity C), at timestep T.
Each student must attend H lectures for a unit he takees, where H corresponds to the H of the 'hoursStudentUnit(H,U)' predicate found in 'atoms.lp',
which corresponds to the number of lectures that a student should attend for each unit he is enrolled in.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Constraints & rules are used to satisfy the requirements for the basic functional system stated in the coursework specification, including:
_ students should not be forced to attend two lectures at the same time,
_ lecturers cannot teach two units at the same time,
_ rooms can only be used for one lecture at the time,
_ lecturers cannot teach when they have other commitments.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Removes answers where the lecturer is different for a lecture scheduled in the same room for the same unit.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Removes answers where the room is different for a same lecture scheduled in at same timestep for the same unit.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Removes answers where the room is different for a same lecture scheduled in at same timestep with the same lecturer.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Removes answers where the unit is different for a same lecture scheduled in at same timestep in the same room.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Removes answers where a lecturer teaches a unit that is not his.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Removes answers where a lecturer teaches at a timestep identical to the timesteps when he has other commitments.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
First counts number of students in a specific room R at a timestep T,
Then removes answer where the number of students in a room exceeds the room's student capacity.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Weak constraints are used to satisfy the requirements for extension 1 stated in the coursework specification, including:
_ lecturers can have preferred teaching times and the timetables take this into account as much as possible.
_ timetables offer a lunch break where possible.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Adds 10 penalty points for each lecture that is scheduled during the lunchbreak timesteps.
Lunch breaks are at timesteps 3, 8, 13, 18 and 23
Weak constraints are used to schedule a lecture during the lunch break if needed, otherwise lectures are scheduled outside lunchbreaks.
For each lecture scheduled during a lunch break period, 10 penalty points are added to the current model.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Adds 10 penalty points for each lecturer who doesn't teach at his preferred timestep.
Preferred teaching times are specified in the 'atoms.lp' file under the 'preferred(P,L)' atoms.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Extra feature taking into account breaks on Wednesday afternoons for extra activities.
The rule wednesdayOff books a room at the timesteps corresponding to a wednesday afternoon, thus making sure no lectures can be scheduled during that time.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display
Outputs only the roomBooked and attendance atoms to the terminal.
@block DEFAULT |_@block Timetable_Data |_@block Timetable |_@block Generators |_@block Room_Booking |_@block Student_Attendance |_@block Basic_Functional_System |_@block Different_Lecturer |_@block Different_Room |_@block Different_Room_Bis |_@block Different_Unit |_@block Lecturer_not_Teach_Unit |_@block Other_Commitments |_@block Room_Capacity |_@block Extension_1 |_@block LunchBreak |_@block PreferredTeachingTime |_@block ExtraFeature |_@block Display