Intelligent Techniques Lesson 4 (Examples about Genetic Algorithm)

Similar documents
Introduction to Artificial Intelligence. Prof. Inkyu Moon Dept. of Robotics Engineering, DGIST

2. Genetic Algorithms - An Overview

Evolutionary Algorithms

Genetic Algorithms for Optimizations

GENETIC ALGORITHMS. Narra Priyanka. K.Naga Sowjanya. Vasavi College of Engineering. Ibrahimbahg,Hyderabad.

Evolutionary Computation. Lecture 3. Evolutionary Computation. X 2 example: crossover. x 2 example: selection

Introduction To Genetic Algorithms

Introduction to Genetic Algorithm (GA) Presented By: Rabiya Khalid Department of Computer Science

College of information technology Department of software

Machine Learning. Genetic Algorithms

Machine Learning. Genetic Algorithms

Genetic Algorithms and Shape Grammars

Part 1: Motivation, Basic Concepts, Algorithms

COMPARATIVE STUDY OF SELECTION METHODS IN GENETIC ALGORITHM

Optimisation and Operations Research

Evolutionary Computation

VISHVESHWARAIAH TECHNOLOGICAL UNIVERSITY S.D.M COLLEGE OF ENGINEERING AND TECHNOLOGY. A seminar report on GENETIC ALGORITHMS.

Introduction To Genetic Algorithms

Genetic algorithms. History

The Metaphor. Individuals living in that environment Individual s degree of adaptation to its surrounding environment

Genetic Algorithm: An Optimization Technique Concept

Machine Learning: Algorithms and Applications

EVOLUTIONARY ALGORITHMS AT CHOICE: FROM GA TO GP EVOLŪCIJAS ALGORITMI PĒC IZVĒLES: NO GA UZ GP

Intro. ANN & Fuzzy Systems. Lecture 36 GENETIC ALGORITHM (1)

CapSel GA Genetic Algorithms.

CHAPTER 4 MAINTENANCE OPTIMIZATION USING GENETIC ALGORITHM

Keywords Genetic Algorithm (GA), Evolutionary, Representation, Binary, Floating Point, Operator

Artificial Evolution. FIT3094 AI, A-Life and Virtual Environments Alan Dorin

Genetic'Algorithms'::' ::'Algoritmi'Genetici'1

Processor Scheduling Algorithms in Environment of Genetics

initial set of random solutions called population satisfying boundary and/or system

Evolutionary Computation. Lecture 1 January, 2007 Ivan Garibay

Genetic Algorithms. Moreno Marzolla Dip. di Informatica Scienza e Ingegneria (DISI) Università di Bologna.

Comparative Study of Different Selection Techniques in Genetic Algorithm

10. Lecture Stochastic Optimization

Journal of Global Research in Computer Science PREMATURE CONVERGENCE AND GENETIC ALGORITHM UNDER OPERATING SYSTEM PROCESS SCHEDULING PROBLEM

Recessive Trait Cross Over Approach of GAs Population Inheritance for Evolutionary Optimisation

From Genetics to Genetic Algorithms

What is Evolutionary Computation? Genetic Algorithms. Components of Evolutionary Computing. The Argument. When changes occur...

An introduction to genetic algorithms for neural networks

IMPLEMENTATION OF AN OPTIMIZATION TECHNIQUE: GENETIC ALGORITHM

Genetic Algorithm: A Search of Complex Spaces

An introduction to evolutionary computation

Energy management using genetic algorithms

CSE /CSE6602E - Soft Computing Winter Lecture 9. Genetic Algorithms & Evolution Strategies. Guest lecturer: Xiangdong An

Genetic Algorithms. Part 3: The Component of Genetic Algorithms. Spring 2009 Instructor: Dr. Masoud Yaghini

Design and Implementation of Genetic Algorithm as a Stimulus Generator for Memory Verification

OBJECTIVE To design an algorithm that can be used for planning the location of distribution substations in a network.

Study of Optimization Assigned on Location Selection of an Automated Stereoscopic Warehouse Based on Genetic Algorithm

Computational Intelligence Lecture 20:Intorcution to Genetic Algorithm

GENETIC ALGORITHM BASED APPROACH FOR THE SELECTION OF PROJECTS IN PUBLIC R&D INSTITUTIONS

OPTIMIZATION OF TEST CASES BY PRIORITIZATION

Genetic Algorithm for Variable Selection. Genetic Algorithms Step by Step. Genetic Algorithm (Holland) Flowchart of GA

Logistics. Final exam date. Project Presentation. Plan for this week. Evolutionary Algorithms. Crossover and Mutation

A Genetic Algorithm for Order Picking in Automated Storage and Retrieval Systems with Multiple Stock Locations

An Evolutionary Solution to a Multi-objective Scheduling Problem

Genetic Algorithm. Presented by Shi Yong Feb. 1, 2007 Music McGill University

Feature Selection for Predictive Modelling - a Needle in a Haystack Problem

PARALLEL LINE AND MACHINE JOB SCHEDULING USING GENETIC ALGORITHM

Evolutionary Algorithms - Population management and popular algorithms Kai Olav Ellefsen

GENETIC ALGORITHM A NOBLE APPROACH FOR ECONOMIC LOAD DISPATCH

GENETIC ALGORITHM CHAPTER 2

Genetic approach to solve non-fractional knapsack problem S. M Farooq 1, G. Madhavi 2 and S. Kiran 3

Assoc. Prof. Rustem Popa, PhD

Minimizing Makespan for Machine Scheduling and Worker Assignment Problem in Identical Parallel Machine Models Using GA

Genetic Algorithm for Predicting Protein Folding in the 2D HP Model

Selecting Genetic Algorithm Operators for CEM Problems

TRAINING FEED FORWARD NEURAL NETWORK USING GENETIC ALGORITHM TO PREDICT MEAN TEMPERATURE

Designing High Thermal Conductive Materials Using Artificial Evolution MICHAEL DAVIES, BASKAR GANAPATHYSUBRAMANIAN, GANESH BALASUBRAMANIAN

Genetically Evolved Solution to Timetable Scheduling Problem

Fig Flowchart of bacterial evolutionary algorithm

Keywords Genetic, pseudorandom numbers, cryptosystems, optimal solution.

Novel Encoding Scheme in Genetic Algorithms for Better Fitness

TIMETABLING EXPERIMENTS USING GENETIC ALGORITHMS. Liviu Lalescu, Costin Badica

A HYBRID ALGORITHM TO MINIMIZE THE NUMBER OF TARDY JOBS IN SINGLE MACHINE SCHEDULING

Plan for today GENETIC ALGORITHMS. Randomised search. Terminology: The GA cycle. Decoding genotypes

Evolutionary Algorithms - Introduction and representation Jim Tørresen

Deterministic Crowding, Recombination And Self-Similarity

Ultimate and serviceability limit state optimization of cold-formed steel hat-shaped beams

Generational and steady state genetic algorithms for generator maintenance scheduling problems

Implementation of CSP Cross Over in Solving Travelling Salesman Problem Using Genetic Algorithms

Parameter identification in the activated sludge process

Genetic Algorithms and Genetic Programming Lecture 14

CHAPTER 4 LINEAR ANTENNA ARRAY SYNTHESIS USING GENETIC ALGORITHM

DEVELOPMENT OF MULTI-OBJECTIVE SIMULATION-BASED GENETIC ALGORITHM FOR SUPPLY CHAIN CYCLIC PLANNING AND OPTIMISATION

Timetabling with Genetic Algorithms

CHAPTER 3 RESEARCH METHODOLOGY

What is an Evolutionary Algorithm? Presented by: Faramarz Safi (Ph.D.) Faculty of Computer Engineering Islamic Azad University, Najafabad Branch

A Genetic Algorithm Applying Single Point Crossover and Uniform Mutation to Minimize Uncertainty in Production Cost

ESQUIVEL S.C., LEIVA H. A., GALLARD, R.H.

A Study on Transportation Algorithm of Bi-Level Logistics Nodes Based on Genetic Algorithm

Introduction Evolutionary Algorithm Implementation

Changing Mutation Operator of Genetic Algorithms for optimizing Multiple Sequence Alignment

Hybridization of Genetic Algorithm and Neural Network for Optimization Problem

Routing Optimization of Fourth Party Logistics with Reliability Constraints based on Messy GA

Genetic Algorithms and Genetic Programming Lecture 13

Genetic Algorithm and Application in training Multilayer Perceptron Model

Evolutionary Computation for Minimizing Makespan on Identical Machines with Mold Constraints

Using Multi-chromosomes to Solve. Hans J. Pierrot and Robert Hinterding. Victoria University of Technology

INFLUENCE OF DATA QUANTITY ON ACCURACY OF PREDICTIONS IN MODELING TOOL LIFE BY THE USE OF GENETIC ALGORITHMS

Transcription:

Intelligent Techniques Lesson 4 (Examples about Genetic Algorithm) Numerical Example A simple example will help us to understand how a GA works. Let us find the maximum value of the function (15x - x 2 ) where parameter x varies between 0 and 15. For simplicity, we may assume that x takes only integer values. Thus, chromosomes can be built with only four genes: Suppose that the size of the chromosome population N is 6, the crossover probability p c equals 0.7, and the mutation probability p m equals 0.001. (The values chosen for pc and pm are fairly typical in GAs.) The fitness function in our example is defined by: f(x) =15x - x 2 The GA creates an initial population of chromosomes by filling six 4- bit strings with randomly generated ones and zeros. The initial population might look like that shown in Table 1. The chromosomes initial locations on the fitness function are illustrated in Figure 1. 1

Table 1. The initial randomly generated population of chromosomes Figure 1. The fitness function and chromosome locations: (a) chromosome initial locations; (b) chromosome final locations The next step is to calculate the fitness of each individual chromosome. The results are also shown in Table 1. The average fitness of the initial population is 36. In order to improve it, the initial population is modified by using selection, crossover and mutation, the genetic operators. In natural selection, only the fittest species can survive, breed, and thereby pass their genes on to the next generation. GAs use a similar approach, but unlike nature, the size of the chromosome population remains unchanged from one generation to the next. 2

The last column in Table 1 shows the ratio of the individual chromosome s fitness to the population s total fitness. This ratio determines the chromosome s chance of being selected for mating. Thus, the chromosomes X5 and X6 stand a fair chance, while the chromosomes X3 and X4 have a very low probability of being selected. As a result, the chromosome s average fitness improves from one generation to the next. One of the most commonly used chromosome selection techniques is the roulette wheel selection as shown in figure 2. To select a chromosome for mating, a random number is generated in the interval (0-100), and the chromosome whose segment spans the random number is selected. It is like spinning a roulette wheel where each chromosome has a segment on the wheel proportional to its fitness. Figure 2. Roulette wheel selection 3

In our example, we have an initial population of six chromosomes. Thus, to establish the same population in the next generation, the roulette wheel would be spun six times. The first two spins might select chromosomes X6 and X2 to become parents, the second pair of spins might choose chromosomes X1 and X5, and the last two spins might select chromosomes X2 and X5. Once a pair of parent chromosomes is selected, the crossover operator is applied. How does the crossover operator work? First, the crossover operator randomly chooses a crossover point where two parent chromosomes break, and then exchanges the chromosome parts after that point. As a result, two new offspring are created. For example, the chromosomes X6 and X2 could be crossed over after the second gene in each to produce the two offspring. What does mutation represent? Mutation, which is rare in nature, represents a change in the gene. It may lead to a significant improvement in fitness, but more often has rather harmful results. So why use mutation at all? Its role is to provide a guarantee that the search algorithm is not trapped on a local optimum. The sequence of selection and crossover operations may stagnate at any homogeneous set of solutions. Under such conditions, all chromosomes are identical, and thus the average fitness of the population cannot be improved. 4

However, the solution might appear to become optimal, or rather locally optimal, only because the search algorithm is not able to proceed any further. Mutation is equivalent to a random search, and aids us in avoiding loss of genetic diversity. How does the mutation operator work? The mutation operator flips a randomly selected gene in a chromosome. For example, the chromosome X10 might be mutated in its second gene, and the chromosome X2 in its third gene, as shown in Figure 3. Mutation can occur at any gene in a chromosome with some probability. The mutation probability is quite small in nature, and is kept quite low for GAs, typically in the range between 0.001 and 0.01. Final Result Genetic algorithms assure the continuous improvement of the average fitness of the population, and after a number of generations (typically several hundred) the population evolves to a near-optimal solution. In our example, the final population would consist of only chromosomes [0,1,1,1] and [1,0,0,0]. Figure 3 represents the whole process of applying the main three operations (selection, crossover and mutation), and the repetition of these operations from one generation to another until acquiring the desired fitness. 5

Figure 3. The GA cycle 6

Real Life Example Consider helping the owner of a fast food restaurant to find the best combination of possible solutions that produce the highest profit. The owner want to decide which value of the following parameters is more profitable for him: 1. Price: Should the price of the burger be 1$ or 2$? 2. Drink: Should Coke or Pepsi be served with the burger? 3. Speed of Service: Should the restaurant provide slow, leisurely service by waiter with tuxedos or fast, snappy service by waiters in white polyester uniform? There are 3 decision variables each of which can assume one of two possible values. Assuming K is the possible value for the decision variable so K = 2. Assuming L is the length of string of possible strategy or combination so L = 3. The search space for this problem is 2 3 = 8 possible strategies but we consider only 4 possible combinations. We can represent the problem (decision to make) in binary: 1. Price (0 represents 1$; 1 represents 2$) 2. Drink (0 represents Pepsi; 1 represents Cola) 3. Speed (0 represents Leisurely; 1 represents Fast) Solutions Price Drink Speed Binary 1 1$ Cola Fast 011 2 1$ Pepsi Fast 001 3 2$ Cola Leisurely 110 4 1$ Cola Leisurely 010 7

For Simplicity, the fitness represents the profit and will be evaluated based on the binary value of the solutions. Roulette Wheel Selection 110 has possibility of 0.50 to reproduce so in the wheel it has 180 degree sector of being selected. In theory, it will be selected 2x in next generation. 011 has possibility of 0.25 i.e. ¼ chances to reproduce. The same goes to the other string or individual. BUT since GA is probabilistic, string 110 can be chosen 3X or even none in the next gen. The same applies to others. 8

Crossover Two parents are chosen based on theirs fitness i.e. 011 and 110 are selected. Randomly select a swap locations between 0 the parents. Mutation Parents are chosen randomly i.e. 010 and 110 are selected to be mutated. Randomly select a location in the parents and change its value. 9

Result The final result after applying GA operations for only one generation will be: Advantages and disadvantages of genetic algorithms 1 2 3 Pros It can solve every optimization problem which can be described with the chromosome encoding It solves problems with multiple solutions Genetic algorithm is a method which is very easy to understand and it practically does not demand the knowledge of mathematics Cons Certain optimization problems cannot be solved by means of genetic algorithms. This occurs due to poorly known fitness functions which generate bad chromosome There is no absolute assurance that a genetic algorithm will find a global optimum In large scale environment, it is resource and time consuming 10