Documente Academic
Documente Profesional
Documente Cultură
Satyajeet S. Bhonsale
Roll Number : 20090405 Under the Guidance of : Dr. V. S. Sathe
1/46
Outline
1. What are Genetic Algorithms?
1.1 Its Applications..
2. Optimization
2.1 Traditional Methods of Optimization
3. 4. 5. 6. 7. 8. 9.
Dierence between GAs and Traditional Algorithms A Simple Genetic Algorithm Pseudo-Code Encoding of Parameters Fitness Genetic Operators Case Study 1 Optimization of CSTRs in series Case Study 2 Tuning of A PID Controller
2/46
search algorithms based on the mechanics of natural selection search heuristic that mimic the process of natural evolution inspired by Darwins theory of Survival of the Fittest
3/46
It has a wide range of application Robotics Signal Processing Automatic Programing Economics Optimization etc.
4/46
Optimization
a process that nds the best solution for a problem An Optimization Problem revolves around three parameters 1. Objective Function 2. Unknown Variables 3. Constraints
5/46
Optimization
a process that nds the best solution for a problem An Optimization Problem revolves around three parameters 1. Objective Function 2. Unknown Variables 3. Constraints Thus optimization problem dened as Finding values of the variables that minimize or maximize the objective function, while satisfying the constraints
5/46
Traditional Methods
Four traditional methods used Analytical Methods Calculus Based Methods Enumerative Methods Random Methods
6/46
Given y = f (x), nd derivative wrt. x, equate to zero and solve for x work perfectly, but only for simple analytical functions
7/46
move in direction of the local gradient climb the hill in steepest possible direction are local in scope require the existence of derivative
8/46
work within a discreet search space Enumerative algorithms test every point in the space in order Random algorithms test every point in the space randomly lack eciency, as practical search spaces are too large
9/46
GAs work with coding of parameter set, not parameters GAs search from a population of points, not single point Use payo information, no auxiliary knowledge required Use probabilistic transition rules, not deterministic
10/46
11/46
11/46
11/46
11/46
11/46
11/46
11/46
11/46
Encoding of Parameters
The potential solutions have to be encoded so that a computer can process them. Types of encodings : Binary Encoding Value Encoding Permutation Encoding Tree Encoding
12/46
Encoding of Parameters
Binary Encodings
Most commonly used because of its simplicity Every chromosome is a string of bits: 1s and 0s A n-bit chromosome can represent integers from 0 to 2n1 , a total on 2n integers any bit string represents a point in search space according to a mapping rule xi = xiL + xiU xiL decoded value(si ) 2n 1
13/46
Encoding of Parameters
Binary Encodings
l1 i i=0 2 si
The accuracy that can be achieved by a 4-bit string is only 1/16 If length is increased by one, accuracy increases exponentially to 1/32 The approximate accuracy is
xiU xiL 2n
14/46
Fitness
it quanties the optimality of the solution objective scores are scaled to produce tness score if problem is a maximization, objective scores can be used directly for minimization problems, objective scores have to be scaled The oftenly used scaling is F (x) = 1/(1 + f (x))
15/46
determines how the individuals are chosen for mating selection is done on the basis of survival of the ttest It basically picks from the population, the above average chromosomes, and inserts its multiple copies
16/46
To maintain diversity in the population, the following selection schemes are employed Rank : Select the best value every time Roulette Wheel : Probability of selection proportional to the tness Tournament : Initial large number selected by Roulette Wheel, then the best among those selected
17/46
also known as Fitness Proportionate Selection probability of being selected is directly proportional to the tness can be thought of as a game of Roulette, with wheel biased on basis of its tness the individual with highest tness occupies largest area on the wheel
18/46
The rouletter wheel is spun n times Each time the string corresponding to the area on the wheel is selected
19/46
Point Fitness Probability Cumulative Probability 1 25 0.25 0.00 0.25 2 5 0.05 0.25 0.30 3 40 0.40 0.30 0.70 4 30 0.30 0.70 1.00 Total 100 1 The probbaility of selecting i-th string is pi = Fi n j=1 Fj
Point Cumulative Probability 1 0.00 0.25 2 0.25 0.30 3 0.30 0.70 4 0.70 1.00 a random number is generated between 0 and 1 the string corresponding to the range in which the number lies is selected Thus, if the random number generated = 0.46, point number 3 is selected This is repeated n times for a population of size n
Genetic Algorithms in Optimization 21/46 Satyajeet Bhonsale, Dr. B. A. T. University
combines two chromosomes to produce a new chromosome the ospring may be better than the parents if not, it is taken care of during selection operation of next generations crossover occurs according to a user dened crossover probability
22/46
23/46
selects one crossover point randomly from rst parent, everything before the point is copied from second, everything after the point is copied The crossover would look as shown below
24/46
used to maintain diversity in the population mutation alter one or more gene value in a chromosome mutation occurs according to an user dened probability mutation probability is usually kept low
25/46
used to maintain diversity in the population prevents premature convergence of the algorithm prevents population from stagnating in local optima
26/46
Flip-bit is the most commonly used mutation operator INITIAL CHROMOSOME 11001001
27/46
Flip-bit is the most commonly used mutation operator INITIAL CHROMOSOME 1 1 0 0 1 0 0 1 FINAL CHROMOSOME 11001101 other operators include Boundary, non-uniform, uniform, Gaussian selection of operators depends upon encoding used
27/46
Parameters to Choose
population size crossover & mutation probabilities selection scheme type of crossover & mutation operator termination criteria
28/46
Benets of GAs
concept is easy to understand supports multiobjective optimization can run in parallel Genetic Algorithms are best used when the objective function is discontinuous highly nonlinear or noisy stochastic has unrealistic or undened derivative
29/46
Performance
GAs can provide solutions for highly complex search spaces GAs can be outperformed by more eld specic algorithms
The solution given by the GA can be used as an initial guess for the algorithm
30/46
31/46
GAs can handle any general kinetic expression GA is used as function optimizer to solve following objective min c4 V1 , . . . , V4 Subject to, V1 + V2 + V3 + V4 = 20
Genetic Algorithms in Optimization 32/46 Satyajeet Bhonsale, Dr. B. A. T. University
SYMBOL F Vi , i = 1, . . . , 4 ci , i = 1, . . . , 4 c0 ri , i = 1, . . . , 4 n k
MEANING feedrate volume of i th reactor concentration of A in i th reactor concentration of A in feed rate of dissapearance of A in i th reactor reaction order reaction constant
VALUE 71m3 /hr variable variable 20kmol/m3 = kcin 2.5 0.00625 {m3 /kmol}1.5 s 1
Satyajeet Bhonsale, Dr. B. A. T. University
33/46
Variable c4 V1 V2 V3 V4
34/46
35/46
36/46
IISE =
0
e 2 dt |e(t)|dt
0
IIAE = IITAE =
0
t|e(t)|dt 1 n
n
IMSE =
Genetic Algorithms in Optimization
e(t)2
t=1
Satyajeet Bhonsale, Dr. B. A. T. University
37/46
38/46
39/46
Conclusion
GA though randomized, eciently utilize the historical information to converge quickly. With proper objective function, can be applied to most Chemical Engineering problems B.Tech Project
Would try to apply GA to a conventional Chemical Engineering problem the results would veried using a traditional method the results would also be validated experimentaly
40/46
THANK YOU
42/46
43/46
local optima is the optimal point only in a particular neighbourhood or locality there may be a point better than the local optima global optima is the optimal point in the entire search space there is no point in the entire search space that is better than the global optima
Genetic Algorithms in Optimization 44/46 Satyajeet Bhonsale, Dr. B. A. T. University
Types of Encodings
Value Encoding any value pertaining to the problem e.g. CHROMOSOME 1: 1.09 2.88 4.12 6.22 CHROMOSOME 2: (BACK) (LEFT) (LEFT) (RIGHT) Permutation Encoding used in ordering problems e.g. CHROMOSOME 1: 1 3 2 8 5 6 4 7 CHROMOSOME 2: 8 2 5 1 6 4 3 7
45/46
46/46