Design and Implementation of Students Time Table Mnanagement System
Design and Implementation of Students Time Table Mnanagement System
planned these events will take place. They are applicable to any institution where
From the time schools became organized environments, timetables have been the
framework for all school activities. As a result, schools have devoted time, energy
and human capital to the implementation of nearly optimal timetables which must
(Robertus, 2002).
be a tedious job in every academic institute once or twice a year. The problem
involves the scheduling of classes, students, teachers and rooms at a fixed number
Traditionally, the problem is solved manually by trial and hit method, where a
miss far better solutions. These uncertainties have motivated for the scientific
study of the problem, and to develop an automated solution technique for it. The
problem is being studied for last more than four decades, but a general solution
technique for it is yet to be formulated (Datta D. et.al, 2006).
Timetabling problem is one of the hardest problem areas already proven to NP-
to grow in number and complexity, their resources and events are becoming
Solutions to timetabling problems have been proposed since the 1980s. Research
in this area is still active as there are several recent related papers in operational
research and artificial intelligence journals. This indicates that there are many
The problem was first studied by Gotlieb (1962), who formulated a class-teacher
students, one teacher, and any number of times which could be chosen freely.
Since then the problem is being continuously studied using different methods
under different conditions. Initially it was mostly applied to schools (de Gans,
1981; Tripathy, 1984). Since the problem in schools is relatively simple because
However, the gradual consideration of the cases of higher secondary schools and
been found inadequate to handle the problem, particularly the huge number of
integer and/or real variables, discrete search space and multiple objective
functions.
This inadequacy of classical methods has drawn the attention of the researchers
classical techniques that are being applied to the problem are Genetic Algorithms
(Alberto Colorni et al., 1992), Neural Network (Looi C., 1992), and Tabu Search
the widely used are the genetic/evolutionary algorithms (GAs/EAs). The reason
the objectives and constraints are defined, EAs appear to offer the ultimate free
(Al-Attar A., 1994). A few worth mentioning EAs, used for the school
timetabling problem, are those of Abramson et al. (1992), Piola R.(1994), and
Bufe et al. (2001). Similarly, EAs, used for the university class timetabling
problem, are those of Carrasco et al. (2001), Srinivasan et al. (2002) and Datta et
al...
Since 1995, a large amount of timetabling research has been presented in the
proceedings, see e.g., (Burke & Carter, 1997) and (Burke & Erben, 2000), and
three volumes of selected papers in the Lecture Notes in Computer Science series,
see (Burke & Ross, 1996), (Burke & Carter, 1998), and (Burke & Erben, 2001).
WATT) which meets once a year regularly sends out a digest via e-mail, and
Fang (1994), in his doctoral thesis, investigates the use of genetic algorithms to
institutions. This framework has the following important points, which give you
and use of a function for evaluation of the solutions, advising the use of a genetic
language that can be used to describe timetabling problems and its constraints.
Oliveira (Oliveira and Reis, 2000) presents a language for representation of the
input language for any timetabling system. It enables a clear and natural
a teacher in two classes at the same time) result in an invalid timetable. Violations
to weak constraints result in valid timetable, but affect the quality of the solution
(for example, the preference of teachers for certain hours). The proposed
37 rooms, 1131 a time interval of one hour each and 472 classes. The algorithm
30% of executions.
to solve.
Analyzing the results obtained by the various works published, we can say what
that when compared with the schedules manuals in institutions of learning real,
the times obtained by the algorithms for solving the class-teacher timetabling
There are two main problems in timetabling. The first one is related to the
flexible, adaptable and portable, otherwise the users will not use the system
optimally or even as decision aids such as for storing, retrieving, and printing
students to choose subjects provided that all pre-requisites are satisfied. This
Any given solution to the problem can be verified quickly (in polynomial
Although any given solution to the timetabling problem can be verified quickly,
there is no known efficient way to locate a solution in the first place; indeed, the
them is known. That is, the time required to solve the problem using any currently
known algorithm increases very quickly as the size of the problem grows (Ossam
Chohan; 2009).
When solving the timetabling problem, we are usually looking for some solution,
which will be the best among others. The space of all feasible solutions (series of
desired solutions with some more desirable than others) is called search space
(also state space). Each point in the search space represents one feasible solution
which can be "marked" by its value or fitness for the problem. The solution is
Genetic Algorithms have been the most prominently used in generating near-
of this project.
The earliest instances of what might today be called genetic algorithms appeared
to artificial problems, but that recognition was not long in coming: "Evolutionary
computation was definitely in the air in the formative days of the electronic
G.J. Friedman, W.W. Bledsoe and H.J. Bremermann had all independently
learning, but their work attracted little follow-up. A more successful development
in this area came in 1965, when Ingo Rechenberg, then of the Technical
there was no population or crossover; one parent was mutated to produce one
offspring, and the better of the two was kept and became the parent for the next
round of mutation (Haupt et. al., 1998). Later versions introduced the idea of a
The next important development in the field came in 1966, when L.J. Fogel, A.J.
and keeping the better of the two (Mitchell Melanie, 1996; Goldberg David,
was still lacking in both these methodologies was recognition of the importance
of crossover.
As early as 1962, John Holland's work on adaptive systems laid the foundation
for later developments; most notably, Holland was also the first to explicitly
propose crossover and other recombination operators. However, the seminal work
in the field of genetic algorithms came in 1975, with the publication of the book
this book was the first to systematically and rigorously present the concept of
the notion of schemata (Mitchell Melanie, 1996; Haupt et. al., 1998). That same
by showing that they could perform well on a wide variety of test functions,
David, 1989).
packing and graph coloring to tangible engineering issues such as pipeline flow
control, pattern recognition and classification, and structural optimization
their rise fueled by the exponential growth of computing power and the
and genetic algorithms are "solving problems of everyday interest" (Haupt et. al.,
biology, and scheduling at airports and assembly lines. The power of evolution
has touched virtually any field one cares to name, shaping the world around us
is ongoing. And at the heart of it all lies nothing more than Charles Darwin's
simple, powerful insight: that the random chance of variation, coupled with the
unlimited application.
result of both natural selection and natural genetics. The method which is general
daily basis. The algorithms are simple to understand and the required computer
code easy to write. The Genetic Algorithm (GA) technique has never attracted
much attention like the artificial neural networks, hill climbing, simulate
The reason for this is certainly not because of any inherent limits it has or its lack
for solving any complex problem. The use of GAs have been evident from the
of systems that mimics and duplicate one or more of the attributes of life. The
problems was considered several times during the 1950's and 1960's. However,
the concept of GAs were essentially invented by one man—John Holland—in the
1960's. His reasons for developing such algorithms were to solve problems of
particularly worth reading for its visionary approach. Its application has proven
problems especially those that concern us most like the timetable problem in the
solutions.
solve, the input to the GA is a set of potential solutions to that problem, encoded
in some fashion, and a metric called a fitness function that allows each candidate
to work, with the aim of the GA being to improve them, but more often they are
generated at random.
The GA then evaluates each candidate according to the fitness function. In a pool
of randomly generated candidates, of course, most will not work at all, and these
will be deleted. However, purely by chance, a few may hold promise - they may
show activity, even if only weak and imperfect activity, toward solving the
problem.
These promising candidates are kept and allowed to reproduce. Multiple copies
are made of them, but the copies are not perfect; random changes are introduced
during the copying process. These digital offspring then go on to the next
worsened, or made no better, by the changes to their code are again deleted; but
again, purely by chance, the random variations introduced into the population
may have improved some individuals, making them into better, more complete
individuals are selected and copied over into the next generation with random
changes, and the process repeats. The expectation is that the average fitness of
the population will increase each round, and so by repeating this process for
discovered.
Genetic algorithms have been used in a wide variety of fields to evolve solutions
Moreover, the solutions they come up with are often more efficient, more elegant,
some cases, genetic algorithms have come up with solutions that baffle the
programmers who wrote the algorithms in the first place (Adam, 2004).
binary strings: sequences of 1's and 0's, where the digit at each position
represents the value of some aspect of the solution (Fleming et. al., 2002).
aspect of the solution. This approach allows for greater precision and
numbers only and often "is intuitively closer to the problem space"
where each letter again stands for a specific aspect of the solution. One
approach, where a GA was put to the task of evolving a simple set of rules
define operators that cause the random changes in the selected candidates:
branching data structures called trees (Koza et. al., 2003). In this approach,
the value at a given node in the tree, or replacing one sub-tree with another.
Figure 2.5: Three simple program trees of the kind normally used in genetic
candidate solutions as data strings of fixed length. Though some represent them
this way, but others do not; e.g. Kitano's grammatical encoding discussed above
can be efficiently scaled to create large and complex neural networks, and Koza's
There are many different techniques which a genetic algorithm can use to select
the individuals to be copied over into the next generation, but listed below are
some of the most common methods. Some of these methods are mutually
be selected. (Most GAs doesn’t use pure elitism, but instead use a modified
form where the single best or a few of the best individuals from each
generation are copied into the next generation just in case nothing better
turns up.)
amount by which its fitness is greater or less than its competitors' fitness.
individual gets a slice of the wheel, but more fit ones get larger slices than
less fit ones. The wheel is then spun, and whichever individual "owns" the
strength of the selective pressure also increases and the fitness function
rank based on fitness, and selection is based on this ranking rather than
prevent very fit individuals from gaining dominance early at the expense
of less fit ones, which would reduce the population's genetic diversity and
generation go back into the pre-existing gene pool, replacing some of the
less fit members of the previous generation. Some individuals are retained
between generations.
computation time by using faster, less selective evaluation to weed out the
those who survive this initial test to more rigorous and more
Once selection has chosen fit individuals, they must be randomly altered
in hopes of improving their fitness for the next generation. There are two
location in the two individuals' genomes, and one individual contributes all
its code from before that point and the other contributes all its code from
the value at any given location in the offspring's genome is either the value
of one parent's genome at that location or the value of the other parent's
2.7b.
crossover; the point of exchange is set between the fifth and sixth positions in the
intrinsically parallel. Most other algorithms are serial and can only explore
the solution space to a problem in one direction at a time, and if the solution
all work previously completed and start over. However, since GAs has
directions at once. If one path turns out to be a dead end, they can easily
greater chance each run of finding the optimal solution (Adam, 2004; John,
1992).
following: All the 8-digit binary strings (strings of 0's and 1's) form a
for "either 0 or 1"). The string 01101010 is one member of this space.
the space 0******0, the space 0*1*1*1*, the space 01*01**0, and so on.
for the average fitness of each of these spaces, each of which has many
religious or social group hopes to learn something about the opinions of all
members of that group, and therefore can reliably predict national opinion
while sampling only a small percentage of the population. In the same way,
the GA can "home in" on the space with the highest-fitness individuals and
find the overall best one from that group. In the context of evolutionary
problems where the space of all potential solutions is truly huge - too vast
that fall into this category are known as "nonlinear". In a linear problem,
to say, few real-world problems are like this. Nonlinearity is the norm,
where changing one component may have ripple effects on the entire
system, and where multiple changes that individually are detrimental may
evaluating 21000 possibilities - a number that would take over 300 digits
good results in a short period of time after directly sampling only small
regions of the vast fitness landscape (Forrest, 1993). For example, a genetic
a central part of engineering projects that can take up to five years and cost
over $2 billion; the genetic algorithm discovered this solution after two
problems for which the fitness landscape is complex - ones where the
avoid the local optima - solutions that are better than all the others that are
similar to them, but that are not as good as different ones elsewhere in the
optima: if they reach the top of a hill on the fitness landscape, they will
discover that no better solutions exist nearby and conclude that they have
reached the best one, even though higher peaks exist elsewhere on the map
(Adam, 2004).
escaping local optima and discovering the global optimum in even a very
rugged and complex fitness landscape. (It should be noted that, in reality,
one global optimum or just a very high local optimum. However, even if a
almost always deliver at least a very good solution.) All four of a GA's
initial population, casting a "net" over the fitness landscape. (Koza et. al.,
of a problem's search space, with each one being given orders to find the
(John, 1992).
However, crossover is the key element that distinguishes genetic
individuals can benefit from what others have learned, and schemata can
be mixed and combined, with the potential to produce an offspring that has
the strengths of both its parents and the weaknesses of neither. This point
the right places) but bad sizing (values of inductance and capacitance for
its components that were far too low). The other parent had bad topology,
but good sizing. The result of mating the two through crossover was an
offspring with the good topology of one parent and the good sizing of the
parents.
The problem of finding the global optimum in a space with many local
classic problem for all systems that can adapt and learn" (John, 1992). Once
an algorithm (or a human designer) has found a problem-solving strategy
strategy to look for new ones is almost guaranteed to involve losses and
degradation of performance, at least in the short term. But if one sticks with
a particular strategy to the exclusion of all others, one runs the risk of not
discovering better strategies that exist but have not yet been found. Again,
usually with tradeoffs involved: one can only be improved at the expense
of another. GAs are very good at solving such problems: in particular, their
to the same problem, possibly with one candidate solution optimizing one
1998), and a human overseer can then select one of these candidates to use.
2000).
know nothing about the problems they are deployed to solve. Instead of
designers do, they are "blind watchmakers" (Dawkins, 1996); they make
random changes to their candidate solutions and then use the fitness
The virtue of this technique is that it allows genetic algorithms to start out
missing any novel solutions that may exist there (Koza et. al., 1999).
be done" or what "couldn't possibly work", GAs do not have this problem.
Similarly, any technique that relies on prior knowledge will break down
when such knowledge is not available, but again, GAs is not adversely
many important electronic components today, but one that, when it was
first discovered, was denied a patent for nine years because the concept
problem-solving strategy, they are not a panacea. GAs does have certain
There are two main ways of achieving this. The first, which is used by most
or 1 could stand for the absence or presence of a given feature. If they are
lists of numbers, these numbers could represent many different things: the
weights of the links in a neural network, the order of the cities visited in a
given tour, the spatial placement of electronic components, the values fed
on. Mutation then entails changing these numbers, flipping bits or adding
or subtracting random values. In this case, the actual program code does
not change; the code is what manages the simulation and keeps track of the
individuals, evaluating their fitness and perhaps ensuring that only values
representations that are robust against mutation and can represent many
This issue of representing candidate solutions in a robust way does not arise
the genetic code, is inherently robust: with only a very few exceptions, such
total number of ways one can combine letters of the alphabet, and therefore
(Adam, 2004).
better solution for the given problem. If the fitness function is chosen
a solution to the problem, or may end up solving the wrong problem. (This
although in reality all that is happening is that the GA is doing what it was
told to do, not what its creators intended it to do.) This is not a problem in
fitness function, which is the same for all living things - the drive to survive
competitors are fitter; those which fail to reproduce are unfit (Adam, 2004).
crossover, the type and strength of selection - must be also chosen with
care. If the population size is too small, the genetic algorithm may not
the rate of genetic change is too high or the selection scheme is chosen
poorly, beneficial schema may be disrupted and the population may enter
error catastrophe, changing too fast for selection to ever bring about
Living things do face similar difficulties, and evolution has dealt with
them. It is true that if a population size falls too low, mutation rates are too
The solution has been "the evolution of evolvability" - adaptations that alter
a species' ability to adapt. For example, most living things have evolved
elaborate molecular machinery that checks for and corrects errors during
some bacterial species enter a state of hyper mutation where the rate of
can be evaded, but the enormous diversity and highly complex adaptations
One type of problem that genetic algorithms have difficulty dealing with
would be less fit than 00000111, and so on - with two exceptions: the string
11111111 turned out to have very low fitness, and the string 00000000
turned out to have very high fitness. In such a problem, a GA (as well as
most other algorithms) would be no more likely to find the global optimum
The resolution to this problem is the same for both genetic algorithms and
biological evolution: evolution is not a process that has to find the single
global optimum every time. It can do almost as well by reaching the top of
a high local optimum, and for most situations, this will suffice, even if the
global optimum cannot easily be reached from that point. Evolution is very
appearing in nature. (It is also worth noting that few, if any, real-world
that it drives down the population's diversity too soon, leading the
rather than searching the fitness landscape thoroughly enough to find the
others.
and tournament selection, discussed earlier, are three major means for
mutations that produce such a large fitness gain as to give their possessors
Finally, several researchers (John, 1992; Forrest, 1993; Haupt et. al., 1998)
problems; it is merely that traditional analytic methods take much less time
and computational effort than GAs and, unlike GAs, are usually
2.10 APPLICATION
OF
GENETIC
ALGORITHMS
IN
THIS
RESEARCH
Having considered the basis for a genetic algorithm, the outline below highlights
case study).
also tackle its NP-hardness), hence the introduction of a highly abstract concept
structure with many independent variables. The relation between the choices
made in the discrete domain and the effects on the objective function value are
usually complex and frequently not easy to trace. The unifying framework for
satisfaction (Abramson, 1992). Once the objectives and constraints are specified,
genetic algorithms offer the ultimate scenarios of good timetable solutions
Hence the algorithm considered for use in the proposed system is a scaled down
algorithms, the first finding a non-conflicting set of exams and the second
assigning the selected exam to rooms. The process is repeated until all exams
Figure 2.10: Diagram depicting the Hybrid Genetic Algorithm used in University
Like every other genetic algorithms, this algorithm can quickly produce large
each member of the course population and assigns it to the first period in which
the exam may be placed without conflict. The mutation and crossover
with each course in the assignment are satisfied. The timetables generated by
the algorithm with a starting population size of 200 had an average fitness of