Sie sind auf Seite 1von 56

CHAPTER - 1 INTRODUCTION

1.1 INTRODUCTION

Evolutionary Computation is a rapidly expanding area of artificial intelligence research, with more than twenty international events per year and at least half a dozen journals, over a thousand EC related papers are published per year [Schwefel and Kursawe, 1998] Within EC there are three classes of EA; Evolutionary Programming, Evolution Strategies, and Genetic Algorithms. These classifications are based on the level in the hierarchy of evolution being modeled by the algorithm. Evolutionary Programming (EP) models evolution as a process of adaptive species. Evolution Strategies (ESs) models evolution as a process of the adaptive behavior of individuals. Thirdly, Genetic Algorithms (GAs) models evolution at the level of genetic chromosomes i.e. the basic instructions for making things. Evolutionary Computation (EC) is the study of computing techniques based on the guiding evolutionary principle of survival of the fittest. Evolutionary Algorithms (EAs) are powerful generic search algorithms capable of giving good solutions to complex problems. Some example areas in which EAs have been applied for problem solving and modeling include; optimization, automatic programming, machine learning, economics, immune systems, ecology, population genetics, evolution and learning, and social systems (see [Goldberg, 1989], [Ross and Corne, 1994], [Alander, 1995] and[Mitchell, 1996] for examples).

Genetic algorithms are search algorithms based on the mechanics of natural selection and natural genetics. They combine survival of the fittest among string structures with a structured yet randomized information exchange to form a search algorithm with some of the innovative flair human search. In every generation, a new set of artificial creatures (strings) is created using bits and pieces of the fittest of the old; an occasional new part is tried for good measure. while randomized, genetic algorithms are no simple random walk. They efficiently exploit historical information to speculate on new search points with expected improved performance. GAS developed by John Holland in the 1960s and subsequently studied by De-Jong, GoIdberg , Davis, Koza , Mitchell , to name only a few, have been originally proposed as a general model of adaptive processes, but by far the largest application of the techniques is in the domain of optimization . The original GAs (classical or canonical GAs) were typified by fixed-length binary representation of individuals, and fixed domain-independent operators. The central theme of research on genetic algorithms has been robustness, the balance between efficiency and efficacy necessary for survival in many different environments. The implications of robustness for artificial systems are manifold. If artificial systems can be made more robust, costly redesigns can be reduced or eliminated. If higher levels of adaptation can be achieved, existing systems can perform their functions longer and better. Designer of artificial systems-both software and hardware, whether engineering systems, computer systems or business systems-can only marvel at the robustness, the efficiency, and the flexibility of biological systems. Features for self-repair, self-guidance, and reproduction are the rule in biological systems, whereas they barely exist in the most sophisticated artificial systems.

1.2 GENETIC ALGORITHMS: DEFINITIONS

In general, any abstract task to be accomplished can be thought of as solving a problem, which in turn can be perceived as a search through a space of potential solutions. Since we

are after "the best" solution, we can view this task as an optimization process. For small spaces, classical exhaustive methods usually suffice: for larger spaces, special A.I. techniques must be employed. GAs are among such techniques. They are cast in different perspectives as follows: GAs are stochastic algorithms whose search methods model some natural phenomena: genetic inheritance and Darwinian strive for survival. GAs are search algorithms based on the mechanics of natural selection and natural genetics. They combine survival of the fittest among string structures with a structured yet randomized information exchange to form a search algorithm with some of the innovative flair of human search. In every generation, a new set of artificial creatures (strings) is created using bits and pieces of the fittest of the old; an occasional new part is tried for good measure. While randomized, GAs are no simple random walk. They efficiently exploit historical information to speculate on new search points with expected improved performance. A GA is a method for searching fitness landscapes for highly fit strings. The central theme of GAs has been robustness: the balance between efficiency and efficacy

necessary for survival in many different environments. GAs are a class of general purpose (domain independent) search methods which strike a

remarkable balance between exploration and exploitation of the search space. GAs belong to the class of probabilistic algorithms, yet they are very different from random algorithms as they combine elements of directed and stochastic search. Because of this, GAs are more robust than existing directed search methods. Another important property of such genetic-based search methods is that they maintain a population of potential solutions - all other methods process a single point of the search space. A GA performs a multidirectional search by maintaining a population of potential

solutions and encourages information formation and exchange between these directions. The population undergoes a simulated evolution: at each generation, the relatively "good" solutions reproduce, while the relatively "bad" ones die. To distinguish between different solutions, an objective (evaluation) function is used which plays the role of an environment.

1.3 TERMINOLOGY In the context of GAs, some biological terms are used in the spirit of analogy with real biology, though the entities they refer to are much simpler than the real biological ones. All living organisms consist of cells, and each cell contains the same set of one or more chromosomes - strings of DNA - that serve as a "blue print" for the organism. A chromosome can be conceptually divided into genes (features, characters, decoders or detectors) - functional blocks of DNA, each of which encodes a particular protein. Very roughly, one can think of a gene as encoding a 'trait', such as eye colour; every gene every gene controls the inheritance of one or several characters. The different possible "settings" for a trait (e.g., blue, brown, etc.) are called 'alleles'. In other words, gene is said to be in several states, called alleles (feature values). Each gene is located at a particular locus (position) on the chromosome i.e. genes of different characters are located at certain places of the chromosome, which are called loci (string positions). Many organisms have multiple chromosomes in each cell (e.g., man has 46 of them). The complete collection of genetic material (all chromosomes taken together) is called the organism's 'genome'. The term 'genotype' refers to the particular set of genes contained in a genome. Two individuals that have identical genomes are said to have the same 'genotype'. The genotype gives rise, under fetal and later development, to the organism's 'phenotype' its physical and mental characteristics, such as eye colour, height, intelligence, etc. Organisms, whose chromosomes are arrayed in pairs are called 'diploid'; while those having chromosomes unpaired are called 'haploid'. In nature, most sexually reproducing species are diploid, including human being; who each have 23 pairs of chromosomes in each somatic (non-germ) cell in the body. During sexual. reproduction, 'recombination' (or 'crossover') occurs: in each parent, genes are exchanged between each pair of chromosomes to form a 'gamete' (a single chromosome), and then gametes from the two parents pair up to form a full set of diploid chromosomes. In haploid sexual reproduction, genes are exchanged between the two parents' single-strand chromosomes. Further, offspring are subject to 'mutation' in which nucleotides (elementary bits of DNA) are changed from parent to offspring, the charges often resulting from copying errors. The 'fitness' of an organism is typically defined as the

probability that the organism will live to reproduce ('viability') or as a function of the number of offspring the organism has (fertility). In GAs, the term chromosome typically refers to a candidate solution to a problem, often encoded as a bit string (but other codings are also possible). The 'genes' are either single bits or short blocks of adjacent bits that encode a particular element of the candidate solution (e.g., in the context of multi-parameter function optimization, the bits encoding a particular parameter might be considered to be a gene). An allele in a bit string is either 0 or I; for larger alphabets more alleles are possible at each locus, such as 1, 2, 3, -1, 10,270 etc. or a, b, l, z, k etc. Most applications of GAs employ haploid individuals, particularly single-chromosome individuals. Crossover then typically consists of exchanging genetic material between two single-chromosome haploid parents. Mutation consists of flipping the bit at a randomly chosen locus (or, for larger alphabets, replacing a symbol at a randomly chosen locus with a randomly chosen new symbol). The "genotype" of an individual in a GA using bit strings is simply the configuration of bits in that individual's chromosome. Often, there is no notion of "phenotype" in the context of GAs, although more recently, many workers have experimented with GAs in which there is both a genotypic level and a phenotypic level (e.g., the bit-string encoding of a neural network and the neural network itself).

Sr. No. 1. 2. 3. 4. 5. 6. 7.

Table 1. 1 Comparison of Natural and G A Terminology Natural GA Chromosome String Gene Feature, character, detector or decoder Aliele Feature value Locus String position Genotype Structure Parameter set, alternative solution, a Phenotype decoded structure or point (in solution space) Epistasis Non linearity

1.4 BASIC ELEMENTS OF GA

Most GAs have at least the following elements in common: population of chromosomes, selection according to fitness, randomized crossover to produce new offspring, and randomized mutation of new offspring. 'Inversion' - Holland's fourth element of GAs - is rarely used in today's implementations as its advantages, if any, are not well established. The chromosomes in a simple GA population typically take the form of bit strings. Each locus in the chromosome has two possible alleles: 0 and 1. Each chromosome can be thought of as a point (solution) in the search space of candidate solutions. The GA processes populations of chromosomes, successfully replacing one such population with another. Each chromosome (solution) is evaluated, through a fitness (objective) function that assigns a score (fitness) to it in the current population. The fitness of a chromosome depends on how well it solves the problem. A fitness landscape is a representation of the space of all possible genotypes along with their fitnesses. Evolution causes populations to move along such fitness landscapes in particular ways and 'adaptation' can be seen as the movement toward peaks. Likewise, in GAs, the operators of selection, crossover and mutation can be seen as ways of moving a population around on the landscape defined by the fitness function. Thus, GA is a method for searching such fitness landscapes for highly fit strings. GAs have the following structure: Algorithm. t := 0; Compute initial population B0 = (b1,0, . . . , bm,0); WHILE (stopping condition not fulfilled) DO BEGIN FOR i := 1 TO m DO select an individual bi,t+1 from Bt;

FOR i := 1 TO m 1 STEP 2 DO IF Random[0, 1] _ pC THEN cross bi,t+1 with bi+1,t+1; FOR i := 1 TO m DO eventually mutate bi,t+1; t := t + 1 END Obviously, selection, crossover (done only with a probability of pC here), and mutation are still degrees of freedom, while the sampling operation is already specified. As it is easy to see, every selected individual is replaced by one of its children after crossover and mutation; unselected individuals die immediately. This is a rather common sampling operation, although other variants are known and reasonable. In the following, we will study the three remaining operations selection, crossover, and mutation. 1.4.1 Encoding Encoding of chromosomes is one of the problems, when you are starting to solve problem with GA. Encoding very depends on the problem. In this section will be introduced some encodings, which have been already used with some success. Binary encoding Binary encoding is the most common, mainly because first works about GA used this type of encoding. In binary encoding every chromosome is a string of bits, 0 or 1.

Chromosome A 101100101100101011100101 Chromosome B 111111100000110000011111 Fig: Example of chromosomes with binary encoding

Binary encoding gives many possible chromosomes even with a small number of alleles. On the other hand, this encoding is often not natural for many problems and sometimes corrections must be made after crossover and/or mutation. . Permutation encoding Permutation encoding can be used in ordering problems, such as travelling salesman problem or task ordering problem. In permutation encoding, every chromosome is a string of numbers, which represents number in a sequence. Chromosome A 1 5 3 2 6 4 7 9 8 Chromosome B 8 5 6 7 2 3 1 4 9 Fig: Example of chromosomes with permutation encoding Permutation encoding is only useful for ordering problems. Even for this problems for some types of crossover and mutation corrections must be made to leave the chromosome consistent (i.e. have real sequence in it). Example of Problem: Travelling salesman problem (TSP)

The problem: There are cities and given distances between them.Travelling salesman has to visit all of them, but he does not to travel very much. Find a sequence of cities to minimize travelled distance. Encoding: Chromosome says order of cities, in which salesman will visit them.

Value encoding Direct value encoding can be used in problems, where some complicated value, such as real numbers, are used. Use of binary encoding for this type of problems would be very difficult.

In value encoding, every chromosome is a string of some values. Values can be anything connected to problem, form numbers, real numbers or chars to some complicated objects.

Chromosome A 1.2324 5.3243 0.4556 2.3293 2.4545 Chromosome B ABDJEIFJDHDIERJFDLDFLFEGT Chromosome C (back), (back), (right), (forward), (left) Fig: Example of chromosomes with value encoding Value encoding is very good for some special problems. On the other hand, for this encoding is often necessary to develop some new crossover and mutation specific for the problem. Example inputs of of neurons Problem: Finding to train the weights network for for neural wanted network output.

The problem: There is some neural network with given architecture. Find weights for Encoding: Real values in chromosomes represent corresponding weights for inputs. Tree encoding Tree encoding is used mainly for evolving programs or expressions, for genetic programming. In tree encoding every chromosome is a tree of some objects, such as functions or commands in programming language.

Chromosome A 9

Chromosome B

(+ x (/ 5 y))

( do_until step wall )

Fig: Example of chromosomes with tree encoding


Tree encoding is good for evolving programs. Programing language LISP is often used to this, because programs in it are represented in this form and can be easily parsed as a tree, so the crossover and mutation can be done relatively easily.

Example

of

Problem: Finding

function

from

given

values

The problem: Some input and output values are given. Task is to find a function, which will give the best (closest to wanted) output to all inputs. Encoding: Chromosome are functions represented in a tree.

1.4.2 Selection This operator selects chromosomes form the old (current) population to form a new population. The individual strings chromosomes are copied according to their objective (fitness) function, f, values. Intuitively, f is some measure of profit, utility, or goodness that we want to optimize. Copying strings according to their fitness values means that strings with higher values have higher probability of contributing one or more offspring in the next generation. This operator is an artificial version of the natural selection, a Darwinian survival of the fittest. The fitter the chromosomes, more copies of it are made. So, some chromosomes would be selected more than once. But since total number of

10

chromosomes stays the same in a population, so certain chromosomes (usually the ones poorer in fitness) are not selected at ill. Thus, best chromosomes get more copies, the average stay even, and the worst die off. Selection is the component which guides the algorithm to the solution by preferring individuals with high fitness over low-fitted ones. It can be a deterministic operation, but in most implementations it has random components. One variant, which is very popular nowadays (we will give a theoretical explanation of its good properties later), is the following scheme, where the probability to choose a certain individual is proportional to its fitness. It can be regarded as a random experiment with

(1.1) Of course, this formula only makes sense if all the fitness values are positive. If this is not the case, a non-decreasing transformation in the simplest case). Then the probabilities can be expressed as must be applied (a shift

(1.2) We can force the property (1.1) to be satisfied by applying a random experiment which is, in some sense, a generalized roulette game. In this roulette game, the slots are not equally wide, i.e. the different outcomes can occur with different probabilities. Figure 2.1 gives a graphical hint how this roulette wheel game works. The algorithmic formulation of the selection scheme (2.1) can be written down as follows, analogously for the case of (1.2): Algorithm. For obvious reasons, this method is often called proportional selection

11

1.4.3 Crossover This operator has pure randomness as well as probabilistic nature. As a matter of fact, the operator 'selection' itself selects parents from the current population, the probability of selection being an increasing function of fitness. Thus, from an active pool, chromosomes are randomly (and not serially) selected, but with a bias towards fitter strings. Now for crossover, strings from the active pool (got after 'selection') could be mated randomly, but since the 'select' operator itself has selected strings from the old population probabilistically, so the mate selection may not be random now and the crossover operator can directly pick the first pair of chromosomes. But whether to perform crossover over the current pair, the decision rests with probability of crossover (a GA parameter, supplied by the user), pc, (also called crossover rate). Cross rate or crossover probability is defined to be the probability that two parents will cross over in a single point. There can also be "multipoint crossover" versions of the GA in which the crossover rate for a pair of parents is the number of points at which crossover takes place. For the moment, we restrict ourselves to single point crossover. In no crossover takes place, form two offspring that are exact replicas (copies) of their respective parents. Further, within the chosen pairs, a randomly chosen point (chosen with uniform probability i.e. using fair coin tossing) is selected as the crossing site. If, however, the crossing site does not fall between the first and the last bit (i.e. within the chromosome length) (as the crossing site is selected only randomly and not even a single such site may be allocated to a chromosome pair), then again the two off springs are exact copies of respective parents. But, if the randomly chosen locus(Crossover site) is within the chromosome, then this crossover operator exchanges the subsequences before and after

12

that locus (crossover site) between two chromosomes to create two offspring, e.g., the strings 10000100 and 11111111 could be crossed over after the third locus in each to produce the two offspring 10011111 and :: 100100. Crossover is a structured yet randomized information exchange between strings. Crossover creates new structures with a minimum of disruption to the allocation strategy dictated by reproduction alone. Hadamard hints that a proper role for chance in a more humanlike discovery mechanism is to cause the juxtaposition of different notions. Exchanging of notions to form new ideas is appealing intuitively, if we think in terms of the process of innovation. What is an innovative idea? As Hadamard suggests, most often it is a juxtaposition of things that have worked well in the past. In much the same way, reproduction (i.e. selection) and crossover combine to search potentially pregnant new ideas. Each chromosome can be viewed as a complete idea or prescription for performing a particular task. While a chromosome is a complete idea, the substrings within each string (idea) contain various notions of what is important or relevant to the task. Viewed in this way, the population contains now just a sample of n complete ideas; rather it contains a multitude of notions and rankings of those notions for task performance. GAs ruthlessly exploit this wealth of information by (1) reproducing high-quality notions according to their performance and (2) crossing these notions with many other high-performance notions from other strings. Thus the action of crossover with previous reproduction speculates on new ideas constructed from the high performance building blocks (notions) of past trials. The experience of emphasis (through fitness-proportionate selection) and crossing is analogous to the human interaction. In a GA too, high performance notions are repeatedly tested and exchanged in the search for better and better performance. In sexual reproduction, as it appears in the real world, the genetic material of the two parents is mixed when the gametes of the parents merge. Usually, chromosomes are randomly split and merged, with the consequence that some genes of a child come from one parent while others come from the other parents. This mechanism is called crossover. It is a very powerful tool for introducing new genetic material and maintaining genetic diversity, but with the outstanding property that good parents also produce well-performing children or even better ones. Several investigations have come to the conclusion that crossover is the

13

reason why sexually reproducing species have adapted faster than asexually reproducing ones. Basically, crossover is the exchange of genes between the chromosomes of the two parents. In the simplest case, we can realize this process by cutting two strings at a randomly chosen position and swapping the two tails. This process, which we will call one-point crossover in the following, is visualized in Figure ..

Fig a: One Point Cross over Crossover and mutation are two basic operators of GA. Performance of GA very depends on them. Type and implementation of operators depends on encoding and also on a problem. There are many ways how to do crossover and mutation. In this chapter are only some examples and suggestions how to do it for several encoding. Crossover for Binary Encoding Single point crossover - one crossover point is selected, binary string from beginning of chromosome to the crossover point is copied from one parent, the rest is copied from the second parent

14

Two point crossover - two crossover point are selected, binary string from beginning of chromosome to the first crossover point is copied from one parent, the part from the first to the second crossover point is copied from the second parent and the rest is copied from the first parent

Uniform crossover - bits are randomly copied from the first or from the second parent

Crossover for Permutation Encoding Single point crossover - one crossover point is selected, till this point the permutation is copied from the first parent, then the second parent is scanned and if the number is not yet in the offspring it is added Note: there are more ways how to produce the rest after crossover point

(1 2 3 4 5 6 7 8 9) + (4 5 3 6 8 9 7 2 1) = (1 2 3 4 5 6 8 9 7)

Crossover value encoding

All crossovers from binary encoding can be used.

15

Crossover tree encoding

Tree crossover - in both parent one crossover point is selected, parents are divided in that point and exchange part below crossover point to produce new offspring

1.4.4 Mutation This operator randomly (with probability of mutation, pm, _ a GA parameter supplied by the user) flips bits in a chromosome. Mutation is the occasional (with small probability) random alteration of the value of a string position. In the binary coding, this simply means changing al to a 0 and vice-versa. In other coding schemes, it may be addition/subtraction of a random number from a randomly chosen position such mat the number at the position remains within the permitted range. Mutation can occur at each bit position in a string with probability, pm , (usually this probability is very small, e.g. 0.001) The last ingredient of our simple genetic algorithm is mutationthe random deformation of the genetic information of an individual by means of radioactive radiation or other environmental influences. In real reproduction, the probability that a certain gene is mutated is almost equal for all genes. So, it is near at hand to use the following mutation

16

technique for a given binary string s, where Pm is the probability that a single gene is modified: Algorithms for mutations is

Of course, Pm should be rather low in order to avoid that the GA behaves chaotically like a random search. Again, similar to the case of crossover, the choice of the appropriate mutation technique depends on the coding and the problem itself. We mention a few alternatives, more details can be found in [20] and [22] again: Inversion of single bits: With probability Pm, one randomly chosen bit is negated. Bitwise inversion: The whole string is inverted bit by bit with prob. Pm. Random selection: With probability Pm, the string is replaced by a randomly chosen one. 1.4.5 Roulette wheel sampling Holland's original GA used fitness-proportionate selection in which the "expected value" of an individual (i.e. the "expected number of times" an individual will be selected to reproduce) is that individuals fitness divided by the average fitness of the population (this is equivalent to what biologists call "viability selection").The most common method of implementing this is "roulette wheel" sampling: each individual (chromosome) is assigned a slice of a circular "roulette wheel", the size (area) of the slice being proportionate to the individual's fitness. Such a roulette wheel may also be termed as a biased or weighted Roulette wheel

17

Marker

Slice Areas 1: 11% 2: 24% 3: 6% 4: 15% 5: 7%

18

6: 36% Total = 100% Fig. 1.4.4 Roulette wheel Selection

The wheel is spun N or popsize times ((where N or popsize number of individuals in the population), with a random force (and not just constant force as that would turn the wheel each time by same number of degrees and thus yielding the same chromosome); this force being of such random magnitude that could rotate the wheel to anywhere between Oo and 360o (i.e. between nil to full one rotation). On each spin, the individual (slice) that comes under the wheel's marker is selected to be in the pool of parents for the next generation. In other words, once a string is selected (via roulette wheel) for reproduction, an exact replica of the string is made and this replica is then entered into a mating pool, a tentative new population, for further genetic operator action.Thus roulette wheel selects a tentative new population with respect to the probability distribution based on fitness values. In the figure shown is an example wherein each spin would turn up string 1 with probability 0.131, string 2 with probability 0.343, string 3 with probability 0.04, ..., and so on. Each spin of the wheel yields one reproduction candidate and if the wheel were spun many times (upper bound, of course, is N or popsize), the average results would be closer to the expectedvalues. Notable point however is that even the fittest string might be eliminated but it is only too true that fitter strings have greater probability of being selected and thus may have more (than one) copies in the succeeding tentative

19

generation. Also the poorest string have least probability of selection and may not have even a single copy as offspring.

A Very Simple Example Consider the problem of finding the global maximum of the following function:

Of course, the solution is obvious, but the simplicity of this problem allows us to compute some steps by hand in order to gain some insight into the principles behind genetic algorithms.The first step on the checklist of things, which have to be done in order to make a GA work, is, of course, to specify a proper string space along with an appropriate coding and decoding scheme. In this example, it is near at hand to consider S = {0, 1}5, where a value from {0, . . . , 31} is coded by its binary representation. Correspondingly, a string is decoded Of course, the solution is obvious, but the simplicity of this problem allows us to compute some steps by hand in order to gain some insight into the principles behind genetic algorithms. The first step on the checklist of things, which have to be done in order to make a GA work, is, of course, to specify a proper string space along with an appropriate coding and decoding scheme. In this example, it is near at hand to consider S

20

= {0, 1}5, where a value from {0, . . . , 31} is coded by its binary representation. Correspondingly, a string is decoded as

Like in [1], let us assume that we use Algorithm as it is, with a population size of m = 4, a crossover probability Pc = 1 and a mutation probability of Pm= 0.001. If we compute the initial generation randomly with uniform distribution over {0, 1}5, we obtain the following in the first step:

One can compute easily that the sum of fitness values is 1170, where the average is 293 and the maximum is 576. We see from the last column in which way proportional selection favors high-fitted individuals (such as no. 2) over low-fitted ones (such as no. 3). A random experiment could, for instance, give the result that individuals no. 1 and no. 4 are selected for the new generation, while no. 3 dies and no. 2 is selected twice, and we obtain the second generation as follows So, we obtain a new generation with a sum of fitness values of 1754, an average of 439, and a maximum of 729. We can see from this very basic example in which way selection favors high-fitted individuals and how crossover of two parents can produce an offspring which is even better than both of its parents. It is left to the reader for the reason of simplicity of the steps ahead and it will be trivial to give many iterations to continue this example.

21

Fig: The function f2

1.5

GOALS OF THE THESIS


GA-based routing algorithm has been found to be more scalable and insensitive to

variations in network topologies. However, it is also known that GA-based routing algorithm is not fast enough for real-time computation [14]. minimum spanning tree (MST) of a graph is an important concept in the communication network design and other network-related problem. Given a graph with cost (or weight) associated with each edge, the MST problem is to find a spanning tree of the graph with minimal total cost. When the graphs edge costs are fixed and the search is unconstrained, the well-known algorithm of Krushal [12] and Prim [13] can identify MST in times that are polynomial in the number of nodes [15]. We intend to use this huge stochastic optimization tool Optimum Path Routing 22

Problem. GA may be used for optimization of searching process for optimum path routing in a network for optimization of both the distance and the congestion problem in a network. Congestion problem in a network is not treated for in reference [14], which we intend to take care of in the proposed GA structure for the problem at hand. The possible optimum path is one which is having minimum distance as well as the congestion factor is to be minimized through the path, a path with less congestion but having relatively larger distance may be selected as per the objective function, which takes care of both distance as well as the congestion in the path

Selected Solution Initialization Parent population Evaluation

1 0 1 1 0 1 0 0 1 0 1 1 1 0 1 0 1 1 0 1 0 0 1 1

fitnes s 2 Selection 2 4 3

1 0 1 0 1 1 0 1 0 0 1 1 0 1 0 0 1 1 1 0 1 1 0 1
Crossover After Crossover

1 0 0 0 1 1 0 1 1 0 1 1 0 1 0 1 0 1

Repeat iteration

After mutation

fitness

1 0 1 0 1 1

1 0 0 0 1 0 0 1 1 0 1 1 0 1 0 1 0 1 1 0 1 0 1 1

1 2 6 4
Mutation

Fig1 Basic structure of a Genetic Algorithms

23

CHAPTER - 2 LITERATURE SURVEY

2.1 INTRODUCTION
Evolutionary computation is a form of computation in which stochastic or probabilistic operators are used in some or the other form to mimic the natural evolutionary process for using in some engineering/technological purpose.. Evolutionary computation has its origins in 1950s [3,4]. Due to the lack of fast computing machines this field was relatively unknown for several decades, but now a days with the availability super fast computing machines last two decades have seen a surge in applications of this field of computations to diversified fields. Now a days one finds applications of this field of computations to medicine, aerospace, evolvable hardware, physical sciences, economic systems, financial forecasting, space applications, control systems, medical diagnosis, artificial intelligence, computer networks and virtually all fields where optimization comes into play.

Evolutionary computing (EC) comprises a family of global optimization techniques that start with a random population of potential solutions and then evolve more fit solutions over many generations. To accomplish this increase in fitness, EC uses basic operations like selection, recombination, and mutation. Because of its compute24

intensive nature, EC research is an obvious candidate for hosting on HPC clusters or systems.[21] 2.2 EVOLUTION OF GENETIC ALGORITHMS
The origins of evolutionary computations can be traced back to the late 1950s[3, 4], but the field remained relatively unknown to the broader scientific community for almost three decades, largely due to the lack of powerful computing platforms at that time, & in part due to methodological limitations of those early approaches [31]. The fundamental work of Holland [3, 4], Rechenberg [28], Schewefel [29], & Fogel [27] served to slowly change this picture during the 1970s. The major new areas of research that have sprung up out of this resurgence are: Artificial Neural Networks, Machine Learning, & Evolutionary Computation. Genetic Algorithms developed by Holland in the 1960s [3, 4] & subsequently studied by De-Jong [8], Goldberg [1], Davis [9], Koza [30] to name only a few, have been originally proposed as a general model of adaptive processes, but by far the largest application of the techniques is in the domain of optimization [5]. The original Genetic Algorithms (classical or canonical Genetic Algorithms) were typified by fixed-length binary representation of individuals, & fixed domain-independent operators (unary mutation & single-point crossover). Evolutionary Programming introduced by Fogel [27] & extended in Burgin [3] & Atmar [26] was originally offered as an attempt to create artificial intelligence.

Natural selection, crossover & mutation are the basic concepts with natural evolution providing foundations for genetic algorithms. The evolutionary process of the Genetic Algorithms takes place on chromosomes, which are the biological edifices, that contains encoded genetic material, which determines the structure of living beings. In Genetic Algorithms, chromosomes are the typically encoded binary strings with allele values of zero or one at each bit position (loci). Natural selection is the process by which chromosomes having more fit encoding have greater probability of reproducing than those having weaker encoding. Once selected for reproduction, chromosomes exchange genetic material by the cross over of alleles from one chromosome to another creating quite different offsprings. Mutation introduces variability by altering chromosomes making them different from their parents. Evolution strategies, as developed by Rechenberg [28] & Schwefel [29] & extended by Herdy [7], Kursawe [32] & others were

25

initially designed with a goal of discrete & continuous parameter optimization problems. Numerous variants of the above three canonic approaches have been derived, their main differences lie in the representation of individuals; the design of variation operators; the selection/ reproduction mechanism. Michalewicz [5] clarifies the difference between Genetic Algorithms & Evolution Programme as: in the latter, we allow any data structure (that is chromosome representation) suitable for a problem together with any set of genetic operators, whereas Genetic Algorithms use fixed-length binary strings (as a chromosome, data structure, S) for its individuals & two operators: unary mutation & binary crossover. In other words, the structure of Genetic Algorithms is the same as that of an Evolution Programme & the differences are hidden on the lower level [9]. 2.3 NETWORK ROUTING GA-based routing algorithm has been found to be more scalable and insensitive to variations in network topologies. However, it is also known that GA-based routing algorithm is not fast enough for real-time computation [14]. minimum spanning tree (MST) of a graph is an important concept in the communication network design and other network-related problem. Given a graph with cost (or weight) associated with each edge, the MST problem is to find a spanning tree of the graph with minimal total cost. When the graphs edge costs are fixed and the search is unconstrained, the well-known algorithm of Krushal [12] and Prim [13] can identify MST in times that are polynomial in the number of nodes [15].Congestion problem in a network is not treated for in reference [14], which we intend to take care of in the proposed GA structure for the problem at hand. One such problem within the field of spatial analysis is that of the routing problem addressed in [17]. This reference focuses on the development of algorithmic solutions for the best path problem. Finding optimum path has many practical applications within the fields of operations research, logistics, distribution, supply chain management and transportation. In general, best path routing involves finding efficient routes for travellers along transportation networks, in order to minimize route length, service cost, travel time, number of vehicles, etc. This is a combinatorial optimization

26

problem for which no simple solutions exist. As an alternative, solution techniques from the field of evolutionary computation is implemented and tested for solving instances of the best path. The field of evolutionary computation (EC) has developed to integrate several previously researched fields of related study into one. EC, used as a means of quickly evolving optimal or near-optimal solutions to a problem within a computational framework designed to represent a relevant search space. Reference [17] scientifically reviews evolutionary algorithms in solving GIS problems. Based on their advantages and drawbacks of the methods a new algorithm called pseudo GA was developed. The algorithm is tested for various case studies. The result of performance analysis of the new algorithm is encouraging. Cauvery N K et [18] explains Routing in dynamic network as challenging one, because the topology of the network is not fixed. This issue is addressed in this presentation using ant algorithm to explore the network using intelligent packets. The paths generated by ants are given as input to genetic algorithm. The genetic algorithm finds the set of optimal routes. The importance of using ant algorithm is to reduce the size of routing table. The significance of genetic algorithm is based on the principle evolution of routes rather than storing the precomputed routes. In [20] a coarse-grained parallel genetic algorithm is proposed for solving the shortest path routing problem with the aim to reduce its computation time. The migration scheme, which is commonly used in coarsegrained parallel genetic algorithm, is also employed in the proposed algorithm. This algorithm is developed and run on an MPI cluster. This paper [20] studies the effect of migration on the proposed algorithm and the performance of the algorithm as compared to its serial counterpart. One of the earliest GA-based shortest path routing algorithms is the one proposed by Munetomo et al. [33], 3[4]. Munetomo proposed a GA-based routing algorithm to generate alternate paths that can be quickly used in the case of link failures. In the proposed algorithm, the algorithm chromosome is encoded as a list of node IDs that are on the path from the source node to the destination node. Since different paths can have different number of nodes, the chromosomes are of variable length. This algorithm employs crossover, mutation and migration genetic operators in generating the next generation of solutions. Chang et. al [35] also proposed a GA-based routing algorithm for

27

solving

the shortest path routing problem. Similar to Munetomos algorithm, the

chromosome in this algorithm consists of a sequence of node IDs that are on the path from source to destination. However, there are several differences in the details of the GA implementation such as in the crossover and mutation operations. Some researchers implemented a hybrid GA algorithm where GA is combined with another algorithm to solve the shortest path routing problem. One example of this is the algorithm proposed by Hamdan et. al [36] who combined GA with the Hopfield network. Another example would be an algorithm proposed by Riedl [37] who combined GA with a local heuristics search. Chang et. al [35] has shown that using GA for the shortest path routing problem has several advantages. The first advantage is that GA is insensitive to variations in network topologies with respect to route optimality and convergence speed. The second advantage is that GA-based routing algorithm is scalable in the sense that the real computation size does not increase very much as the network size gets larger. However this literature also pointed out that GA is not fast enough for real-time computation and in order to achieve a really fast computation time in GA, a hardware implementation of GA is required. In reference [38] multiple destination routing (MDR) problem can be formulated as finding a minimal cost tree which contains designated source and multiple destination nodes so that certain constraints in a given communication network are satisfied. The MDR problems can essentially be classified into two categories [40]: they are the single-originmultipledestinations (SOMD) problems and the multiple-originsmultiple destinations(MOMD) problems. In SOMD problems, there is only one source that disseminates its signals to destination nodes. In MOMD problems, there is more than one source that disseminate signals. An MOMD problem, however, can be decomposed into a group of SOMD problems [40]. in this paper, only SOMD is focus.

28

Figure: A randomly generated network of 20 nodes with the average connecting degree of 4.5, as in reference[40]. In [40], a new genetic algorithm for the MDR problems without constraints has been developed. By transforming a network to its distance complete form, a correspondence between fixed-length binary strings in the GA and feasible solutions of the problem is established. 2.4 METHODS OF SOLVING THE TSP Traveling Salesman Problem is on of the classical optimization problem, and is similar to shortest path routing, so it is worthwhile to discuss it here. Homaifar [23] states that one approach which would certainly find the optimal solution of any TSP is the application of exhaustive enumeration and evaluation. The procedure consists of

29

generating all possible tours and evaluating their corresponding tour length. The tour with the smallest length is selected as the best, which is guaranteed to be optimal. If we could identify and evaluate one tour per nanosecond (or one billion tours per second), it would require almost ten million years (number of possible tours = 3.21023) to evaluate all of the tours in a 25-city TSP. Obviously we need to find an algorithm that will give us a solution in a shorter amount of time. As we said before, the traveling salesman problem is NP-hard so there is no known algorithm that will solve it in polynomial time. We will probably have to sacrifice optimality in order to get a good answer in a shorter time. Many algorithms have been tried for the traveling salesman problem. We will explore a few of these in this section. 24 Greedy Algorithms [25] are a method of finding a feasible solution to the traveling salesman problem. The algorithm creates a list of all edges in the graph and then orders them from smallest cost to largest cost. It then chooses the edges with smallest cost first, providing they do not create a cycle. The greedy algorithm gives feasible solutions however they are not always good. The Nearest Neighbor [25] algorithm is similar to the greedy algorithm in its simple approach. We arbitrarily choose a starting city and then travel to the city closest to it that does not create cycle. We continue to do this until all cities are in the tour. This algorithm also does not always give good solutions because often the last edge added to the tour (that is, the edge en1 where n is the number of cities) can be quite large. A minimum spanning tree [25] and [24]) is a set of n 1 edges (where again n is the number of cities) that connect all cities so that the sum of all the edges used is minimized. Once we have found a minimum spanning tree for our graph we can create a tour by treating the edges in our spanning tree as bidirectional edges. We then start from a city that is only connected to one other city (this is known as a leaf city) and continue following untraversed edges to new cities. If there is no untraversed edge we go back along the previous edge. We continue to do this until we return to the starting city. This will give us an upper bound for the optimal traveling salesman tour. Note, however, that we will visit some cities more than once. We are able to fix this if whenever we need to traverse back to a city we have already been to, we instead go to the next unvisited city. When all cities have been visited we go directly back to the starting city.

30

2.5 CONCLUDING REMARKS

Although biology and computer communication networks have grown and evolved independent of each other, there are many common similarities among the two subjects. Both consist of a large number of relatively autonomous entities interacting with each other in a complex manner. Both form organizations that are hierarchical and simple to describe, yet result in tremendous complexity and emergent phenomena. It is only logical to expect that bringing together ideas from both fields would result in significant benefits to both[19].

_________ __ _________

31

CHAPTER - 3 IMPLEMENTATION

3.1 INTRODUCTION

Routing is a process of finding paths between nodes. There are mainly two types of routing policies viz., static routing and dynamic routing. In static routing, the routes between the nodes are precomputed based on certain factors and are stored in routing table [22]. All packets between any two nodes follow the same path. If topology of the network changes, then the path between two nodes may also change, and hence in dynamic routing policy, the routes are not stored but are generated when required. The new routes are generated based on the factors like traffic, link utilization etc which is aimed at having maximum performance. Routing policy may be centralized or distributed. In thecase of centralized routing, only centralized node, generates routes between any pair of nodes. In distributed routing, each node generates routes independently between pair of nodes as and when required. Other classification of routing policy is optimal routing (globalrouting) and shortest path routing (local routing). Some ofthe shortest path algorithms are distance vector algorithm and link state algorithm. Characteristics of routing policy are distributed-ness, stochastic and time varying, multiobjectve and multiconstraint. Genetic Algorithm (GA) is a programming technique that depicts the biological evolution as the problem solving technique. GA works on the search space called population [1]. Each element in the population is called as chromosome. GA begins with randomly selecting set of feasible solution from population. Each chromosome is a

32

solution by itself. Each chromosome is evaluated for fitness and this fitness defines the quality of solution. GA uses adaptive heuristic

search technique which finds theset of best solution from the population. New offsprings are generated /evolved from the chromosomes using operators like selection, crossover and mutation. Most fit chromosomes are moved to next generation. The weaker candidates get less chance for moving to next generation. This is because GA is based on the principle of Darwin theory of evolution, which states that the survival is the best. This process repeats until the chromosomes have best fit solution to the given problem [9]. The summary is that the average fitness of the population increases at each iteration, so by repeating the process for many iterations, better results are discovered. Genetic Algorithms are a family of computational models inspired by evolution. These algorithms encode a potential solution to a specific problem on a simple chromosome like data structure and apply recombination operators to these structures so as to preserve critical information Genetic algorithms are often viewed as function optimizers, although the range of problems to which genetic algorithms have been applied is quite broad. An implementation of a genetic algorithm begins with a population of typically random chromosomes. One then evaluates these structures and allocates reproductive opportunities in such a way that those chromosomes which represent a better solution to the target problem are given more chances to reproduce than those chromosomes which are poorer solutions. The goodness of a solution is typically defined with respect to the current population This particular description of a genetic algorithm is intentionally abstract because in some sense the term genetic algorithm has two meanings. In a strict interpretation the genetic algorithm refers to a model introduced and investigated by John Holland [3, 4] and by students of Holland D. DeJong. It is still the case that most of the existing theory for genetic algorithms applies either solely or primarily to the model introduced by Holland as well as variations on what will be referred to in this paper as the canonical genetic algorithm Recent theoretical advances in modeling genetic algorithms also apply primarily to the canonical genetic algorithm .

33

3.2 OPTIMIZATION
One of the most fundamental principles in our world is the search for an optimal state. It begins in the microcosm where atoms in physics try to form bonds1 in order to minimize the energy of their electrons [5]. When molecules form solid bodies during the process of freezing, they try to assume energy-optimal crystal structures. These processes, of course, are not driven by any higher intention but purely result from the laws of physics. The same goes for the biological principle of survival of the fittest [19] which, together with the biological evolution [4l], leads to better adaptation of the species to their environment. Here, a local optimum is a well-adapted species that dominates all other animals in its surroundings. Homo sapiens have reached this level, sharing it with ants, bacteria, flies, cockroaches, and all sorts of other creepy creatures. As long as humankind exists, we strive for perfection in many areas. We want to reach a maximum degree of happiness with the least amount of effort. In our economy, profit and sales must be maximized and costs should be as low as possible. Therefore, optimization is one of the oldest of sciences which even extends into daily life . If something is important, general, and abstract enough, there is always a mathematical discipline dealing with it. Global optimization2 is the branch of applied mathematics and numerical analysis that focuses on, well, optimization. The goal of global optimization is to find the best possible elements x from a set X according to a set of criteria F = {f1, f2, .., fn}. These criteria are expressed as mathematical functions3, the so-called objective functions.

34

Fig: The taxonomy of global optimization algorithms.

Classification of Optimization Algorithms 35

In this sectin, we will only be able to discuss a small fraction of the wide variety of global optimization techniques . Before digging any deeper into the matter, I will attempt to provide a classification of these algorithms as overview and discuss some basic use cases. Classification According to Method of Operation is given here. Figure sketches a rough taxonomy of global optimization methods. Generally, optimization algorithms can be divided in two basic classes: deterministic and probabilistic algorithms. Deterministic algorithms are most often used if a clear relation between the characteristics of the possible solutions and their utility for a given problem exists. Then, the search space can efficiently be explored using for example a divide and conquer scheme4. If the relation between a solution candidate and its fitness are not so obvious or too complicated, or the dimensionality of the search space is very high, it becomes harder to solve a problem deterministically. Trying it would possible result in exhaustive enumeration of the search space, which is not feasible even for relatively small problems. Then, probabilistic algorithms5 come into play. The initial work in this area which now has become one of most important research fields in optimization was started about 55 years ago.An especially relevant family of probabilistic algorithms are the Monte Carlo based approaches. They trade in guaranteed correctness of the solution for a shorter runtime. This does not mean that the results obtained using them are incorrect they may just not be the global optima. On the other hand, a solution a little bit inferior to the best possible one is better than one which needs 10100 years to be found. Heuristics used in global optimization are functions that help decide which one of a set of possible solutions is to be examined next. On one hand, deterministic algorithms usually employ heuristics in order to define the processing order of the solution candidates. Probabilistic methods, on the other hand, may only consider those elements of the search space in further computations that have been selected by the heuristic.

3.3 ALGORITHMS FOR IMPLIMENTATION


36

We intend to use this huge stochastic optimization tool Optimum Path Routing Problem. GA may be used for optimization of searching process for optimum path routing in a network for optimization of both the distance and the congestion problem in a network. Congestion problem in a network is not treated for in reference [14], which we intend to take care of in the proposed GA structure for the problem at hand. Algorithm for optimum path Routing: Real values for genes are used in the coding for this problem. The chromosome size is variable for each chromosome and each chromosome represents a probable rout having some distance and total congestion in the path. Number of nodes is fixed in the network with each node having a congestion factor associated to it having value between 0 and 1; 0 represents a totally free node while a 1 represents a totally congested node.. The following algorithm is used to encode the proposed GA for this problem: i) Select the nodes with their x and y coordinates and associated congestion factors. ii) Designate initial and final nodes. iii) Initialize the initial population having each chromosome, with its first gene as the starting node and last gene as the terminating node, so as each chromosome represents a probable path with varying number of nodes encountered in each path. iv) Evaluate the fitness of the population by the objective function, which calculates the distances between nodes from the starting node to terminating node and also sums up the congestion factors of all the nodes in the path. Objective function assigns fitness to each chromosome by way of calculating the total path distance and the total congestion factor of the path represented by the chromosome. v) Perform roulette Wheel selection on the population. vi) Perform crossover on the new population obtained after selection, with a probability of crossover 0.8, which may be increased or decreased for faster convergence of GA. vi) Perform Mutation with a probability of mutation between 0.001 to 0.003. Probability of mutation may be varied for faster convergence of GA. vi) Evaluate the fitness of the population by the objective function. vii) Check convergence of GA, stopping citation may average fitness or predefined number of runs for the GA. If stopping criterion is met, stop the GA else go to (v), Iterations continued till stopping criterion is met.

37

viii) Display the optimum path with coordinates and corresponding congestion factors of the nodes. The possible optimum path is one which is having minimum distance as well as the congestion factor is to be minimized through the path, a path with less congestion but having relatively larger distance may be selected as per the objective function, which takes care of both distance as well as the congestion in the path.

38

Fig: Flow Chart for GA

39

CHAPTER - 4 RESULTS

4.1 INTRODUCTION
The present application of GA is programmed in MATLAB. Variable length chromosomes with real coding are used. For the particular example taken here, a population size of 10 is taken. The algorithm explained in previous section is programmed for a network of total 56 nodes. Shortest path routing is the type of routing widely used in computer networks nowadays. Even though shortest path routing algorithms are well established, other alternative methods may have their own advantages. One such alternative is to use a GA-based routing algorithm. Based on previous research, GA-based routing algorithm has been found to be more scalable and insensitive to variations in network topologies. However, it is also known that GA-based routing algorithm is not fast enough for real-time computation [14]. We intend to use this huge stochastic optimization tool Optimum Path Routing Problem. GA may be used for optimization of searching process for optimum path routing in a network for optimization of both the distance and the congestion problem in a network.
.

4.2 IMPLIMENATION OF PROPOSED ALGORITHMS IN MATLAB


The present example is coded in Matlab. Real coding with variable length chromosomes is used. The chromosome size is variable for each chromosome and each chromosome represents a probable rout having some distance and total congestion in the path. Number of nodes is fixed in the network with each node having a congestion factor associated to it having value between 0 and 1; 0 represents a totally free node while a 1

40

represents a totally congested node.. The following process is used to encode the proposed GA for this problem.

4.2.1 initialization of population In the present example a network of 56 nodes is taken, which are assigned a congestion factor. Number of nodes is fixed in the network with each node having a congestion factor associated to it having value between 0 and 1; 0 represents a totally free node while a 1 represents a totally congested node. Select the nodes with their x and y coordinates and associated congestion factors to form a path. Designate initial and final nodes of each path same as the starting node and the terminating node. Initialize the initial population in this way, having each chromosome, with its first gene as the starting node and last gene as the terminating node, so as each chromosome represents a probable path with varying number of nodes encountered in each path. Also in this step, Evaluate the fitness of the population by the objective function, this calculates the distances between nodes from the starting node to terminating node and also sums up the congestion factors of all the nodes in the path. Objective function assigns fitness to each chromosome by way of calculating the total path distance and the total congestion factor of the path represented by the chromosome. The starting node is taken as E=[10.0,2.0,0.1]. Following are 56 nodes of the Network S=[0.0,5.0,0.1]; and the ending node is

[0.0, 5.0, 0.10] [0.0, 0.0, 0.15] [0.0, 1.0, 0.83] [0.0, 2.0, 0.25] [0.0, 8.0, 0.62] [1.0, 0.0, 0.78] [1.0, 1.0, 0.98]

41

[1.0, 4.0, 0.99] [1.0, 8.0, 0.97] [1.0, 10.0, 0.87] [2.0, 0.0, 0.88] [2.0, 3.0, 0.98] [2.0, 4.0, 0.99] [2.0, 5.0, 0.97] [2.0, 7.0, 0.02] [3.0, 1.0, 0.43] [3.0, 3.0, 0.92] [3.0, 4.0, 0.99] [3.0, 9.0, 0.75] [4.0, 0.0, 0.65] [4.0, 4.0, 0.13] [4.0, 6.0, 0.91] [4.0, 7.0, 0.95] [4.0, 8.0, 0.76] [4.0, 9.0, 0.83] [4.0, 10.0, 0.43] [5.0, 0.0, 0.68] [5.0, 1.0, 0.88] [5.0, 2.0, 0.96] [5.0, 7.0, 0.67] [6.0, 2.0, 0.28] [6.0, 3.0, 0.97] [6.0, 5.0, 0.09] [6.0, 6.0, 0.98]

42

[6.0, 7.0, 0.89] [6.0, 8.0, 0.74] [7.0, 0.0, 0.98] [7.0, 1.0, 0.99] [7.0, 2.0, 0.97] [7.0, 3.0, 0.87] [7.0, 6.0, 0.78] [7.0, 7.0, 0.98] [7.0, 8.0, 0.99] [8.0, 1.0, 0.64] [8.0, 3.0, 0.93] [8.0, 5.0, 0.97] [8.0, 7.0, 0.92] [8.0, 8.0, 0.83] [9.0, 0.0, 0.98] [9.0, 2.0, 0.99] [9.0, 3.0, 0.07] [9.0, 8.0, 0.57] [9.0, 9.0, 0.78] [9.0, 10.0, 0.08] [10.0, 2.0, 0.10] [10.0, 7.0, 0.25] [10.0, 1.0, 0.03] Initial population is as given below(comprises of 10 chromosomes of variable lengths) Chromosome 1:

43

[0.0, 5.0, 0.10], [0.0, 5.0, 0.10], [4.0, 10.0, 0.43], [3.0, 4.0, 0.99],[7.0, 1.0, 0.99], [8.0, 8.0, 0.83], [9.0, 9.0, 0.78], [10.0, 2.0, 0.10]. Chromosome 2: [0.0, 5.0, 0.10], [1.0, 1.0, 0.98], [2.0, 5.0, 0.97], [4.0, 7.0, 0.95], [9.0, 0.0, 0.98], [10.0, 2.0, 0.10]. Chromosome 3: [0.0, 5.0, 0.10], [1.0, 10.0, 0.87], [2.0, 0.0, 0.88], [4.0, 9.0, 0.83], [5.0, 0.0, 0.68],[10.0, 2.0, 0.10]. Chromosome 4: [0.0, 5.0, 0.10], [0.0, 8.0, 0.62], [1.0, 0.0, 0.78], [2.0, 7.0, 0.02], [3.0, 1.0, 0.43], [6.0, 8.0, 0.74], [7.0, 0.0, 0.98], [10.0, 2.0, 0.10]. Chromosome 5: [0.0, 5.0, 0.10], [2.0, 4.0, 0.99], [3.0, 3.0, 0.92], [4.0, 8.0, 0.76], [5.0, 1.0, 0.88], [9.0, 10.0, 0.08], [10.0, 7.0, 0.25], [10.0, 2.0, 0.10]. Chromosome 6: [0.0, 5.0, 0.10], [0.0, 2.0, 0.25], [1.0, 4.0, 0.99], [4.0, 6.0, 0.91], [5.0, 2.0, 0.96], [8.0, 1.0, 0.64], [10.0, 2.0, 0.10]

44

Chromosome 7: [0.0, 5.0, 0.10], [2.0, 3.0, 0.98], [3.0, 9.0, 0.75], [5.0, 7.0, 0.67], [6.0, 2.0, 0.28], [8.0, 7.0, 0.92], [9.0, 2.0, 0.99], [10.0, 2.0, 0.10]. Chromosome 8: [0.0, 5.0, 0.10], [0.0, 1.0, 0.83], [1.0, 8.0, 0.97], [4.0, 4.0, 0.13], [6.0, 3.0, 0.97], [7.0, 8.0, 0.99], [8.0, 3.0, 0.93], [9.0, 3.0, 0.07], [10.0, 2.0, 0.10]. Chromosome 9: [0.0, 5.0, 0.10], [0.0, 0.0, 0.15], [4.0, 0.0, 0.65], [6.0, 7.0, 0.89], [7.0, 2.0, 0.97], [8.0, 5.0, 0.97], [9.0, 8.0, 0.57], [10.0, 2.0, 0.10]. Chromosome 10: [0.0, 5.0, 0.10], [6.0, 6.0, 0.98], [7.0, 3.0, 0.87], [6.0, 5.0, 0.09], [7.0, 6.0, 0.78], [7.0, 7.0, 0.98], [10.0, 1.0, 0.03], [10.0, 2.0, 0.10].
The Network of 56 nodes for the example undertaken is given in figure--

45

4.2.2 objective function Objective function calculates the distances between nodes from the starting node to terminating node and also sums up the congestion factors of all the nodes in the path. Objective function assigns fitness to each chromosome by way of calculating the total path distance and the total congestion factor of the path represented by the chromosome. GA maximizes the objective function, which is reciprocal of the total sum of distance from starting node to ending node and total congestion factor through this path. T .D =
i=S E

( xi xi +1 ) 2 + ( yi yi +1 ) 2
+ w. C i
i=S E

T .DF =
i =S

( xi xi +1 ) 2 + ( yi yi +1 ) 2

ObjFun = 1

( xi xi+1 ) 2 + ( yi yi +1 ) 2
i=S

+ w. C i
i=S

So the objective function calculates the above factor for each and every potential path i.e. the chromosome in a population.

46

Figure: Network consisting of 56 nodes

4.2.3 optimized path and convergence curve for ga The starting node is taken as S=[0.0,5.0,0.1]; and the ending node is
E=[10.0,2.0,0.1].

The Algorithm selected a path which optimizes the distance

between the starting and ending node alongwith minimizing the total congestion on the path. The optimum path found by GA in present example is

S=[0.0,5.0,0.1]; [2.0,7.0,0.0]; [4.0,4.0,0.2]; [6.0,4.0,0.1]; [9.0,3.0,0.2]; E=[10.0,2.0,0.1].

47

The nodes are selected by the algorithm for optimizing the distance along with the congestion on the path. A shorter path with higher congestion may be neglected while longer path with lesser congestion may be selected. The path selected is shown in the figure by bold line. GA Converges when it reaches to a optimal solution. There may be many criterions to access the convergence of GA. When the average fitness of subsequent generations stops growing then GA either converged to a optimal solution or might have struck at some suboptimal point. A predefined number of runs may be taken as the stopping criterion for the GA. Here we have tested both the stopping criterion. In this particular application fixed number of runs may be used as the optimality of the solution is visible from the output if all the chromosomes in the final population are same. The convergence curve for the GA is shown in figure--

48

Figure: Optimized path

49

Figure: Convergence curve for GA

_________ __ _________

50

CHAPTER - 5 CONCLUSIONS AND FUTURE DIRECTIONS

The GA is an optimization tool suitable for vast search spaces. We have developed this application of GA using Matlab for static conditions in the Network. That is the congestion factor is taken stationary for the optimization problem at hand, but this application can be programmed for online environment, where congestion factors of the nodes may be changing with time according to the traffic conditions in the network. Other Intelligent tools may be probed in synergism with GA for online applications. GA is specifically suitable for large search spaces, so we can go for optimization of the routing path in networks containing many hundred/thousands or more nodes. For any feasible solution of the problem, in [38] there is only a binary string corresponding to it. Moreover, a binary string can evidently indicate which nondestination nodes are selected as intermediate nodes. The proposed algorithm is simple and can easily be implemented in practice. Not only it is of lower computational complexity than the GAs in [41] and [42], but it can also be theoretically assured to find the optimal solution with probability one as the evolution goes to infinity. Coding schemes may also be altered for faster convergence and increasing the efficiency of the optimization process. We have used one point crossover, instead we may test multipoint crossover. A number of techniques has been proposed in various references enlisted at the end, so we can test other intelligent technique like ACO, PSO, along with GA to make the technique more robust and efficient.

51

Various types of Genetic Algorithm techniques for solving Network rouitong and TSP have been analyzed and surveyed here. The various operators like mutation, selection, crossover and their combinations used by researchers for finding a solution to these problems have been discussed. The experimental results of their works were also studied and this will be useful for the comparison between existing systems and future works. This survey will serve as future reference for researchers working under this domain. The implementation of the present GA application in Matlab is simple yet encompasses the concept of congestion factor on different nodes. Salman Yousof et.al in reference [14] paid attention to the problem of shortest path routing yet have not discussed about the congestion in the network. Apart from avoiding long distances, it very much important to minimize the congestion in the path once selected in the network, because congestion is a major factor which restricts the data flow drastically, and even much more effect than distances between the transmitting and receiving nodes.

_________ __ _________

52

CHAPTER 6 REFERENCES

[1] D. E. Goldberg, Genetic Algorithms in Search, Optimization, and Machine Learning. Addison-Wesley, Reading, MA, 1989. [2] A. Neubauer, The circular schema theorem for genetic algorithms and two-point crossover, in Proc. of Genetic Algorithms in Engineering Systems: Innovations and Applications, pp. 209214, Sept. 1997. [3]Holland J.H. (1975) Adaptation in Natural & Artificial Systems. Ann. Arbor: The Uni. of Michigan press. [4]Holland J.H. (1962.), Outline for a logical theory of adaptive systems J. Assoc. Computer. Mach., vol.3. Pp.297-314. [5] Michalewicz Z. (1992), Genetic Algorithms + Data Structures = Evolution Programs. Berlin: Springer Verlag. [6]Back T.(1992) The interaction of mutation rate, selection & self adaptationin genetic algorithm, in parallel problem solving from nature2. Manner R et.al., Eds., Amesterdam, The Neatherland: Elsevier. [7]Back T. et.al, (1997) Evolutionary computation: comments on the history & current state, IEEE Transactions on Evolutionary Computations, vol 1, No. 1. [8] De Jong K. A. (1975), An analysis of the behavior of a class of genetic adaptive system, Ph. D. Dissertation, Univ. of Michigan, Ann Arbor, Diss. Abstr. Int [9] Davis L, Ed., (1996) Handbook of Genetic Algorithms, New York: Van Norstand Reinhold. [10] De Jong K. A. (1992), Are Genetic Algorithms Functions Optimizers? in Parallel

53

Problem Solving From Nature 2. Amsterdam, the Netherlands: Elsevier. [11]Vose. M(1993), Modeling Simple Genetic Algorithms. Foundations of Genetic Algorithms -2- D. Whitley., ed., Morgan Kaufmann_ pp 63-73. [12-8] J. B. Kruskal, On the Shortes Spanning Tree of a Graph and the Traveling salesman Problem.. Amer. Math. Soc., vol. 7, pp. 48-50, 1956. [13] R. Prim, Shortest Connection Networks and Some Generalization. Bell Syst. Tech. J., vol. 36, pp. 1389-1401,1957. [14] Salman Yousof et.al. A Parallel Genetic Algorithm for Shortest Path Routing problem. 2009 International Conference on Future Computer and Communication. [15] Lixia Hanr et.al., A Novel Genetic Algorithm for Degree-Constrained Minimum Spanning Tree Problem IJCSNS International Journal of Computer Science and Network Security, VOL.6 No.7A, July 2006. [17] S. Behzadi et al, A PSEUDO GENETIC ALGORITHM FOR SOLVING BEST PATH PROBLEM. The International Archives of the Photogrammetry, Remote Sensing and Spatial Information Sciences. Vol. XXXVII. Part B2. Beijing 2008 [18] Cauvery N K et al, Routing in Dynamic Network using Ants and Genetic Algorithm IJCSNS International Journal of Computer Science and Network Security, VOL.9 No.3, March 2009 [19] Pietro Lio, Dinesh Verma, Biologically Inspired Networking IEEE Network May/June 2010 [20] Salman YussofA Coarse-grained Parallel Genetic Algorithm with Migration for Shortest Path Routing Problem 2009 11th IEEE International Conference on High Performance Computing and Communications. [21] Edwin Nez, High Performance Evolutionary Computing HPCMP Users Group Conference (HPCMP-UGC'06)0-7695-2797-3/06 $20.00 2006 IEEE [22]Andrew S Tannenbaum, Computer Networks,4th Edition, Prentice-Hall of India [23] Abdollah Homaifar, Shanguchuan Guan, and Gunar E. Liepins. Schema analysis of the traveling salesman problem using genetic algorithms. Complex Systems, 6(2):183217, 1992.

54

[24] E.L. Lawler, J.K. Lenstra, A.H.G. Rinnooy Kan, and D.B. Shmoys. The Traveling Salesman. JohnWiley and Sons, 1986. [25] Gerard Reinelt. The Traveling Salesman: Computational Solutions for TSP Applications.Springer-Verlag, 1994. [26] Arnone S. et.al. (1994),Toward a fuzzy government of genetic populations, Proc.6th IEEE conf. on Tools with artificial intelligence, Los Alamitos, CA: IEEE comput. Soc. Press, pp.585-591. [27] Bremermann,H.J (1962),Optimization through evolution & recombination, in Selforganizing Systems, M.C Yovits, et.al., Eds. Washington, DC, Spartan. [28] Baker J.E., (1985) Reducing bias & inefficiency in the selection algorithm, in Proc. 2nd Ann. Conf. Genetic Algorithms, Mass, Inst. Technol., Cambridge, MA, pp.14-21. [29] Beyer H.G,(1992) Some aspects of theevolutionary strategy for solving tsp-like optimization problems appearing at the design studies of a 0.5 TeV e+e- linear collider, in parallel problem solving from nature 2, Amsterdam: Elsevier. [30] Chiang C.K. etal, (1997) A Self-Learning Fuzzy Logic Controller using Genetic Algorithms with Reinforcement IEEE transactions on Fuzzy Systems, Vol. 5, No. 3. [31] Back T. et.al., (1991) Extended selection mechanism genetic algorithms, in Proc. 4th Int. Conf. Genetic Algorithms, Univ. of California, San Diego, CA [32] Burgin G. H., (1973) Systems identification by quasi-linearization & evolutionary programming. J. Cybern., vol. 3, no. 2, pp. 56-75. [33]M. Munetomo, Y. Takai, Y. Sato, A migration scheme for the genetic adaptive routing algorithm, in Proc. IEEE International Conference on Systems, Man and Cybernetics, vol. 3, pp. 2774 2779, October 1998. [34] M. Munetomo, N. Yamaguchi, K. Akama, Y. Sato, Empirical investigations on the genetic adaptive routing algorithm in theInternet, in Proc. Congress on Evolutionary Computation, vol. 2, pp.1236 1243, May 2001. [35] Chang Wook Ahn, R. S. Ramakrishna, A genetic algorithm for shortest path routing problem and the sizing of populations, IEEE Transactions on Evolutionary Computation, vol. 6, issue 6, pp. 1 7, February 1999.

55

[36] M. Hamdan, M. E. El-Hawary, Hopfield-genetic approach for solving the routing problem in computer networks, in Proc.Canadian Conference on Electrical and Computer Engineering, vol. 2, pp. 823 827, May 2002. [37] A. Riedl, A hybrid genetic algorithm for routing optimization in IP networks utilizing bandwidth and delay metrics, in Proc. IEEE Workshop on IP Operations and Management, pp. 166 170, 2002 [38]. Yee Leung, Guo Li et al, A Genetic Algorithm for the Multiple Destination Routing Problems IEEE TRANSACTIONS ON EVOLUTIONARY COMPUTATION, VOL. 2, NO. 4, NOVEMBER 1998. [40] K. J. Lee, A. Gersht, and A. Friedman, Multiple connection routing, Int. J. Digital Analog Commun. Syst., vol. 3, pp. 177186, 1990. [41]A. Kapsalis, V. J. Rayward-Smith, and G. D. Smith, Solving the graphical Steiner tree problem using genetic algorithms, J. Opl. Res. Soc., vol. 44, no. 4, pp. 397406, 1993. [42] H. Esbensen, Computing near-optimal solutions to the Steiner problem in a graph using a genetic algorithm, Networks, vol. 26, pp. 173185,1995.
_________ __ _________

56

Das könnte Ihnen auch gefallen