A Review of Optimization Algorithms for University Timetable Scheduling

The university course timetabling problem looks for the best schedule, to satisfy given criteria as a set of given resources, which may contain lecturers, groups of students, classrooms, or laboratories. Developing a timetable is a fundamental requirement for the healthy functioning of all educational and administrative parts of an academic institution. However, factors such as the availability of hours, the number of subjects, and the allocation of teachers make the timetable problem very complex. This study intends to review several optimization algorithms that could be applied as possible solutions for the university student course timetable problem. The reviewed algorithms take into account the demands of institutional constraints for course timetable management. Keywords-timetabling; genetic algorithms; Particle Swarm


INTRODUCTION
Many higher education institutions have teaching staff from various fields, who work together to meet the educational goals set. However, creating a timetable with no conflicts, which these lecturers can use is one of the challenges most universities face. Generally, a timetable is a table of various events and their schedule [1]. Therefore, in a university timetable, the institution assigns the courses taken by students and delivered by tutors to a defined finite set of resources, which include time slots and classrooms. This process presents many challenges. For example, in a typical school, there are several student groups who may or may not be taking the same course at the same time [2]. Thus, when scheduling lectures, one has to ensure that learners, lecturers, and lecture halls do not conflict. This need makes the timetabling of university courses to be a complex and time-consuming task to complete. University timetabling committees cannot perform this distribution randomly as they must consider several decisive factors. There are several constraints that guide the process of making an effective timetable. These constraints, which are rules, policies, and preferences of universities, lecturers, and students, can be categorized as hard, soft, or medium. Hard constraints are those guidelines that should not be violated or overlapped at all, soft constraints are desires of the involved stakeholders that can be ignored without any serious consequences, and medium constraints are preferences that they are preferred to not be violated [3]. The committee handling the timetabling must consider all these requirements to create an optimal outcome. Due to the complexity of this problem, timetable coordinators spend a considerable amount of time looking for the best solution. However, even if they have a lot of experience, the resolution found may not be optimal due to the large number of possible combinations. Thus, the distribution of workload among the various lecturers in an academic institution constitutes a problem of combinatorial nature. In general, resolving such challenges and obtaining exact optimal solutions is computationally intractable. Therefore, the university timetabling problem is an example of a Non-Polynomial (NP)-hard problem [4]. These are problems with no particular efficient solutions. In the case of timetabling where there is no specific algorithm that can be utilized to schedule classes since each institution has its special constraints [5,6]. At the same time, when done manually, the obtained result depends on both the initial approach and the experience of the timetabling committee.
Public universities typically take days to manually schedule all the classes that students should take depending on the availability of lecturers and classrooms [7]. Thus, the proposal to automate this process intends to meet real needs, with the main aim to reduce the time taken to complete it efficiently. Describing the real problem by mathematical functions, the study seeks the values of such models with the use of optimization techniques. This way, it will provide a solution that maximizes the use of available human resources and satisfies the needs of all involved parties. This approach becomes very complex as more restrictions arise, such as the number of courses in the school and the availability of essential resources like lecturers, students, and classrooms. The presented solutions behave inefficiently when there is an expansion of the institution and their accuracy suffers as the number of courses and classes grow [8]. Thus, a personalized computational approach to address the issue becomes important and a priority. Due to the importance of the problem, several formalizations and solution methods have been proposed. The approaches based on meta-heuristics are considered to be particularly relevant. However, these optimization algorithms are not mutually exclusive. Instead, they combine ideas from different areas, with the main aim of providing different solutions to the timetabling issue [9]. One of the most popular approaches is acquiring solutions based on Genetic Algorithms (GAs) due to their high degree of computational parallelization and enhanced computational performance. Overall, university course timetabling can be treated as organizing a group of classes to meet the specifications of particular institutions. Over the years, various researchers have created various algorithms to find an optimal solution to this issue. For instance, authors in [9] created graph coloring schemes for timetable scheduling in 1967. Their work formed the foundation upon which more sophisticated techniques have been based. One of these models is linear programming, which was used to solve a labor scheduling problem in [10].
Moreover, a GA presents one of the best possible methods to address NP-complete problems. At its core, a GA is a parameter optimization strategy that iterates over a population, seeking the best fit for a problem until it obtains an optimal solution [11]. Several works have been completed with this algorithm for the treatment of timesheets. The GA borrows heavily from the field of natural sciences on the way it works. In particular, it allows observing events from the lens of natural phenomena, such as mutations and natural selection [12]. Hence, it helps developing computational mechanisms, which resemble these processes. Therefore, GAs use and specify biological terminologies, such as crossing-over and mutation, in a precise and specialized way [13]. In particular, through the process of cross-over, the fittest generations pass on their attributes to their offspring. In turn, mutation helps to prevent stagnation within a population and is essential for the proper functioning of the algorithm. Along this line, this study will use surveys to understand the general foundations for the problem of university lesson planning. This activity will assist in formulating the optimization model and describing the manner in which the algorithm can be adapted to make it applicable to the problem under investigation.
II. RELATED WORDK Because university course timetabling is an NP-hard problem, there are several methods that have been explored in attempts to find optimal solutions. The manual approach requires several days of work and often results in inefficient outcomes [4,14]. However, there are several other procedures that can be used to schedule academic activities and in which restrictions related to the type of problem considered must be respected. Nonetheless, the objective often involves distributing teachers and students in a particular course depending on time and resource availability, while also respecting their desires. Educational timetables are of three types: school, course, and exam timetables [1]. Scheduling the course timetable presents the most difficulties among the three as it is utilized frequently through a typical university semester and it covers only particular days within a week. University timetabling is not simple due to various constraints that would be applied to produce effective course timetabling [15][16][17]. Eventually, the timetabling constraints can be classified as hard and soft; the hard constraints are considered as mandatory while the soft constrains are optional [18][19][20]. Table I summarizes the most important soft and hard constraints of course timetabling.

Hard constraints Soft constraints
Ref.
-Courses having common students cannot be allotted at the same time slot on the same day.
-The total number of available periods of the daily timetable is 8 hours (maximum) Honours and general courses need to be scheduled in nonoverlapping time-slots. [15] -A room cannot be assigned to more than one lecture in a given period.
-Courses belonging to a curriculum must be assigned to different periods.
-Courses taught by a lecturer must be assigned to different periods.
-The number of students taking a course must fit into the assigned room.
-Each additional student over the capacity of the room counts as a violation.
-Lectures for a given curriculum must be consecutive. [16] The timetable should be scheduled based on the university calendar To open the course, a minimum number of students should be registered [17] -Considers the workload of the lecturers.
-Takes into account the free time (i.e. office hours and resets) of the lecturers. [18] -Every course should be assigned to a venue at a particular timeslot.
-The scheduled courses must not exceed the venue capacity. [19] -Lecture rooms must not be booked twice at the same time.
-All lecture venues and rooms must be scheduled once not twice.
-Break periods must be allocated before other courses.
-Faculty general courses must be allocated to slots before departmental courses. [20] -No student group has two events at the same time.
-No lecturer has two events at the same time.
-No event is in a room with less capacity than the number of students at the event. [21] Hard and soft constrains are related to many factors such as courses, lecturers, students, classrooms, and operational dates and hours [16,18,19,21]. Thus, it is important to apply optimization algorithms for effective scheduling of the course timetable. The use of optimization techniques in problemsolving dates back several decades. Nonetheless, it has recently been boosted by the advent of computers and the increase in their processing capacity, which has led to a rise of the number of scheduling approaches. However, the application of these methods to solve practical problems has not been verified at the same proportion as the rate of their development. One of the reasons is the complexities of the real behavior and the model generated, which are described by non-linear behavior functions and whose solution space may be non-convex [14]. On the other hand, they demand a large number of calculations as stated by authors in [22], who argue that instead of performing many additional computations to determine a gradient with mathematical programming techniques, it may be more beneficial to use this time and resources to explore the search space more intensively. Among the heuristic optimization techniques, there are metaheuristic methods, which promise accurate and optimal solutions to the timetable scheduling issue. Notable approaches of this nature include Greedy Randomized Adaptive Search (GRASP), simulated annealing, tabu search, GAs, microchanonic annealing, and microchanonic optimization [23]. Scheduling problems are usually addressed by heuristic techniques due to their structure and complexity [22]. For instance, authors in [23] state that the simulated annealing scheme provides an efficient solution when applied to scenarios that require some form of programming. Several authors present comparisons and evaluations of the performance of different metaheuristics in solving scheduling problems [24]. Some of the common metaheuristic strategies include evolutionary algorithms, ant colony, local search, simulated annealing, and tabu search, but none of them can be singled out as the best. Table II shows a summary of some of these algorithms, including their advantages, disadvantages, and tools that can be applied to develop them. Using this Table, it is possible to identify the methodologies that can be applied to develop a solution to the university timetabling problem effectively. The problem of scheduling can be found in many areas, e.g. in the assignment of drivers to vehicles in a public transport company or in the development of school timetables. However, conflicts are common due to competing interests among the stakeholders involved and the existence of constraints that should be satisfied. In order to find the best possible solution to such issues, a swarm-intelligent algorithm, named Particle Swarm Optimization (PSO), can be used. This meta-heuristic was developed to find and optimize solutions for continuous problems. Nonetheless, it turned out to be a very suitable method for achieving quick and good solutions within these applications. At this point, however, the process must be adapted to the given circumstances for this discrete problem. Simple to implement and works fast when applied to small datasets.
Hyperparameters need to be tuned manually. Hence, people not familiar with it find it challenging to use.

Has better convergence than most algorithms
Performs poorly in the context of nonsmooth optimization.
Software tools, such as KDSimStudio and Simulated Conversation Development tool.
Gradually converges to a global optimal solution and, thereby, escapes from a local solution.
Requires enhancements to function effectively.
[38] 2020 Tabu search algorithm Available frameworks, such as the Tabu Search Framework written in C++.
Together with a memory concept, it can be utilized to explore iteration problems more precisely than other algorithms.
It performs poorly in large dimension problems.
[39] 2020 Tabu search algorithm Frameworks, such as the Tabu Search Framework.
Ignores recently explored neighborhoods to avoid settling on a local optimum solution.
As it does not have memory, it requires other algorithms or additional components to function effectively. [40] 2020

A. Genetic Algorithms
The main task of scheduling algorithms in solving the university course timetabling problem is to find a solution that satisfies a set of restrictions. These limitations are either essential or nonessential. Essential restrictions are those that generate an unworkable timetable if they are not satisfied. On the other hand, the nonessential ones improve the quality of the framework. GAs are a strategy class that can be employed to resolve these conditions efficiently. They are based on the principles of genetics and natural selection, with the central idea being the selection of the fittest individuals in a population, who then recombine with others or mutate into new forms to generate new groups [41]. GAs are particularly applied to complex optimization problems, which are challenges that have different parameters or characteristics that need to be combined in search of the best solution and, at the same time, cannot be represented mathematically [42,43]. Figure 1 illustrates the flowchart of the GA algorithm, from the initial population to when a suitable result is obtained. Over the years, several researchers have applied GAs to solve such problems. For instance, authors in [44] dealt applied the GA to address the issue of scheduling class timetables. The differential feature in this work is the use of crossover operators only between rows and, later, columns. Many authors also utilize several methods to treat infective solutions, which are those that do not meet the essential restrictions. In [45], the algorithm was applied to resolve the problem in two phases. First, a GA was applied to generate solutions that only meet the essential restrictions, and, in the second stage, based on the initial population generated in the initial step, GAs were employed to satisfy the non-essential conditions. In [46], a greedy approach was proposed to generate a robust initial population. Subsequently, the authors applied the GA to optimize this solution further. Other works, such as [47], propose the application of a repair function, which is introduced after crossover and mutation operations, to deal with infactible solutions. In [48], it is proposed to use local search methods to improve the solution, which, consequently, reduces the number of violations of non-essential restrictions. These methods are usually applied after the generation of each population in the evolution process. Often, GAs are implemented in the Delphi 5.0 programming environment and the problem input data are imported from the Saber Software Database.
The problem of timetabling consists of scheduling a sequence of classes between teachers and students in a limited period of time, while satisfying a set of restrictions. This problem exists in any educational institution, but it becomes increasingly complex as the size of the establishments grows. Primarily, this phenomenon arises because the timetabling of courses belongs to the NP-hard class, for which polynomialtime algorithms have been unable to obtain optimal solutions [49]. The timetabling problem has been studied for several years, with pioneering solutions forming the foundation for more effective techniques. The literature reveals several types of solutions, such as graph-based techniques and other approaches that find a maximal sequence of pairings in the bipartite graph composed of teachers and classes. Authors in [50] used programming by applying a Lagrangian relaxation technique, while authors in [23] formulated and solved the problem as an allocation challenge. Authors in [51] used flow resolution techniques in networks. As mentioned above, many authors divided the restrictions between hard and soft, where the hard restrictions define the feasible solutions, and the soft restrictions are included in the objective function. While satisfying the hard conditions means that the solution addresses the problem successfully, its quality is dependent on the procedure to blocks of different durations. Another popular approach is the employment of a multiobjective GA, which combines two points of view: student-oriented and teacheroriented. Moreover, one can use a two-stage GRASP algorithm. Others formulated another model for the problem, also using soft constraints in the objective function. One can explore a hyperheuristics framework based on graphs, researching local search algorithms based on low-level coloring algorithms. Other approaches can also apply a tabu search, using domain-independent neighborhood structures to penalize neighborhoods unable to generate better solutions. A combination of the bee colony meta-heuristic with an assimilation policy to guide the search process has also been proposed. Therefore, there are several approaches that can be followed to solve the university course timetabling issue, although they all have their advantages and disadvantages.

B. Particle Swarm Optimization
PSO was originally developed in 1995 to solve continuous problems [52]. The idea of simulating a swarm of bees has evolved into a meta-heuristic and presented an optimization procedure with some basic extensions. Based on this premise, the PSO procedure can be further modified to solve combinatorial problems [53,54]. The boids (bird-like objects) model has been introduced, whereby each boid represents an individual who obeys three implemented rules in order to simulate swarm behavior for computer graphics and films, since it was found that the choreography of flocks of birds was aesthetic. The alignment ensures that individuals move in the same direction as their neighbors. Merging several boids enables cohesion, in which a single boid moves in the middle of a defined group, whereas separation causes boids to diverge in a small space. Depending on a given rule, a marked boid is aligned with the other boids. Later on, rest areas were added to www.etasr.com Alghamdi et al.: A Review of Optimization Algorithms for University Timetable Scheduling the boids model [55]. The individuals also have a need to remain within the swarm. The more a boid approaches a resting place, the greater the desire to move towards it, pulling more boids in this direction. Later, Kennedy and Eberhart developed the Swarm Optimization [55]. Theoretically, individuals can benefit from the discoveries and past experiences of their colleagues when searching for food [56]. This advantage can become critical and outweigh the disadvantages of food competition if the resource is unpredictably patched [57]. Kennedy and Eberhart followed this hypothesis that information exchange between group members offers an evolutionary advantage in the further development of the PSO by implementing social behavior in the birds and, hence, making them mass-and collision-free particles. They also extended the model by not only having them look for a rest area but also using a "cornfield vector" on which the best feeding place exists. These particles now have a memory of their best position in relation to such a feeding place and a knowledge of the best position so far within the entire swarm [57]. Based on these considerations, the classic PSO for continuous problems was developed. Figure 2 shows the flowchart of the PSO algorithm. To optimize the solution, the PSO developed for continuous problems was modified in such a way that it was suitable for solving combinatorial problems. Various compositions of parameters were examined for their performance and it was observed that the attempt to modify the PSO in such a way that it was able to solve a combinatorial problem without the characteristics of swarm-intelligence [59]. The PSO significantly improved the quality of the solution of the manually created timetable with reasonable computing effort. In particular, the influence of an individual event can be emphasized in combination with swapping a random time window of the current solution. This exercise suggests a good current solution [60]. This exercise suggests a good balance between exploration and exploration of the solution space. Since the method presented primarily deals with continuous problems, further research is needed to determine its suitability in addressing the university timetable problem.
While formulating a time table, it is important to consider the context of the problem within the educational institution in question. The problem may vary according to the institution and its business model, as, for example, in public and private educational establishments. Public schools usually have an open timetable model, in which subjects are offered and courses are built around them [60]. Thus, students are free to choose the subjects and they want to take and at what times. As the subjects are free, there is no requirement for rooms where it should be taught, and this allocation is also part of the process as a whole [59,61]. Thus, it is possible for a course to be taught in several different classrooms throughout the week. In contrast, most private institutions follow a closed model. In this case, a course coordinator allocates the subjects that a student will take. Eventually, the learner has to approve the given set of units according to the level of study. In addition, the subjects are linked to courses they are being offered, and they are completely free as in the case of public institutions. As a result, subjects should not be allocated to classrooms, as they have a fixed location. That is, the classroom to which they are assigned. Thus, lecturers can switch rooms but not the student since teachers in private institutions can teach several subjects, although there is no requirement that a subject should always be taught by the same instructor. However, in public institutions, it is common for a teacher to be hired for one or more specific subjects.

III. DISCUSSION
Lesson planning deals with the scheduling of classes at a specific time in a given location, with particular participants that have to attend. In the best case, the solution of the problem results in plans that enable all students to take part in the meetings of interest at a certain location and time. There are, however, restrictions to the allocation of resources, which include time, space, and the availability of both teaching staff and the students. No other class should happen at the same time and venue with an ongoing one, and neither should two lessons demand the presence of the same group of students concurrently. Double occupancy of rooms has the same potential for conflict. As mentioned above, creating an efficient timetable is a typical NP-hard problem, which does not have a specific methodology of finding an optimal solution [62,63]. Moreover, course timetables do not consider the preferences of students, as is generally the case in appointment requests.
In the case of university lesson planning, this phenomenon means that lecturers play the role of active agents and students that of passive agents. At the same time, a lecture hall has to be of appropriate size, should possess the required equipment, and be available at an acceptable time for all participants without causing violations of both essential and nonessential constraints [63]. Therefore, the dates of a resulting timetable correspond to The conditions, which a timetable should satisfy can be divided into hard and soft constraints. Violations of hard constraints are not permitted because they could lead to the unavailability of lecturers, e.g. they might be scheduled to attend two concurrent classes. On the other hand, soft constraints can be left unsatisfied since such a case does not affect the admissibility of the timetable. The punishment for non-compliance with soft constraints is included in the assessment of the timetable [14]. Soft constraints occur, for example, when deadline requests for events cannot be met. In this case, these incidents can be shifted from their original desired dates to another time window without affecting the effectiveness of the timetable.
The lesson planning activity in schools is further made difficult by the options that students have while selecting the classes to attend. For instance, one does not have to stick to given subject combinations, but can largely plan study programs independently. The attendance of individual courses does not have to take place in a particular semester, but can usually be integrated into the study period at will. The aim of university timetable scheduling is to use the resulting multitude of subject combinations to create a program, which is as free of overlaps as possible for all [64,65]. Although the problems of school and course timetabling may appear similar at a first glance, they present significantly different problem sets, with the latter's being more complex than those of the former.
While formulating a timetable, it is important to consider the context of the problem faced by the educational institution in question. The issue may vary depending on the establishment and its business model. For example, while they are both institutions of higher learning, public and private universities have different funding models, which affect how they offer their classes and the types of services their students enjoy. Public schools usually have an open structure, in which subjects are offered and courses are built around them, while students are free to choose which subjects they want to take and at what time. As the subjects are free, there is no requirement for rooms where they should be taught, and this allocation is also part of the process as a whole [66]. Thus, it is possible for a course to be taught in several different classrooms throughout the week. On the other hand, most private institutions follow a closed model. In this case, a course coordinator allocates the subjects that a student will take. Eventually, the student has to approve the given set of units according to the level of study. In addition, the subjects are linked to courses in which they are being offered, and they are not completely free as in the case of public institutions. As a result, subjects should not be allocated to classrooms, as they have a fixed location. That is, the classroom to which they are assigned. Thus, lecturers can switch rooms but not the student since teachers in private institutions can teach several subjects, although there is no requirement that a subject should always be taught by the same instructor. However, in public institutions, it is common for a teacher to be hired for one or more specific subjects.
University course timetabling solves the problem of creating assignments given specific time slots, classrooms, teachers, and subjects. The goal is to prevent a room from being occupied by two subjects simultaneously, or two teachers teaching the same class, or a teacher to have to teach two classes at the same time. The quality indicator of a solution varies, with some researchers using the sum of the preferences of a given discipline, such as a teacher allocation, to measure the effectiveness of a timetable [66,67]. Others adopt soft restrictions and utilize them to assess the quality of the solution, while there are instances where student preferences or the spacing between classes has been employed to achieve the same goal. Authors in [4] consider a matrix of conflicts between learners taking two courses i and j simultaneously. The objective function considers the minimization of the number of cases where i and j are scheduled at the same time. Therefore, just as there are several methods of creating an optimal solution to the course timetabling problem, the quality of the resulting solutions can be evaluated in various ways.

IV. CONCLUSION
The problem of planning school hours is described as having to schedule a series of meetings between teachers and students over a set period of time and meet a number of different types of constraints. Since the types of restrictions generally change from one institution to another, different solutions to this problem have been proposed. The problem of school hours, it is a problem of combinatorial optimization with a vast search space and with a generally large number of restrictions. It is considered as an NP-hard problem. For problems like these, there is still no algorithm that tests all the possibilities to find the optimum solution in a timely manner. Therefore, this problem has been approached through heuristic techniques, and more recently by meta-heuristics.