Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.
-
Upload
elizabeth-gilbert -
Category
Documents
-
view
226 -
download
1
Transcript of Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.
![Page 1: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/1.jpg)
Genetic Algorithms as a Tool for General Optimization
Angel Kuri2001
![Page 2: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/2.jpg)
Optimization
Genetic Algorithms are meta-heuristics based on an analogy with evolutionary processes, where three ideas outstand:
a) That any optimizable problem is amenable to an (usually digital) encoding process.
b) That a problem thusly encoded is more easily tackled than its non-encoded couterpart.
c) That genetic operators called natural selection, crossover and mutation are enough to fully and efficiently explore the solution landscape.
![Page 3: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/3.jpg)
Optimization(Any problem is encodable)
For this to be true we have to restrict the solution landscapes to a finite subset of the original ones.
This is not a source of serious conceptual or practical trouble since, in all cases, the computational solution of any given problem is digitally encoded.
![Page 4: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/4.jpg)
Optimization (An encoded problem is more easily tackled)
This dictum is not obvious. However, the ample evidence supporting it leaves little room for doubt.
More importantly, theoretical arguments seem to leave no doubt:
a) Genetic Algorithms always converge to the best solution
b) Convergence is usually quite efficient
![Page 5: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/5.jpg)
Optimization(Genetic operators yield efficient performance)
Our aim when designing Gas is to make the abovementioned convergence as efficient as possible.
Two sources of inefficiency have been clearly determined:
a) Deceptive functions
b) Spurious correlation
![Page 6: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/6.jpg)
Optimization
Before discussing how to overcome the aforementioned limitations we shall analyze a canonical GA (or SGA).
Then we will describe a non-standard GA (VGA) which was designed to avoid the pifalls of the SGA.
![Page 7: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/7.jpg)
The Simple Genetic Algorithm
Although there are many possible varia-tions, the best understood and more widely treated sort of GA is called “Simple”.
![Page 8: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/8.jpg)
Simple Genetic Algorithm
It considers:» Genetic haploid representation» Proportional selection» 1-point crossover» Mutation with low probability» No elitism» Binary strings» Constant sized population» Bounded number of generations
![Page 9: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/9.jpg)
SGA
The SGA starts from a set of binary strings
![Page 10: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/10.jpg)
Evaluation
Every candidate solution is evaluated
![Page 11: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/11.jpg)
Evaluation
Strings are sorted best to worst
![Page 12: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/12.jpg)
Selection
Every string is asigned a probability proportional to its performance
![Page 13: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/13.jpg)
Selection
Probability of Selection
![Page 14: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/14.jpg)
Crossover
A couple of individuals is randomly chosen; a locus is also randomly chosen
![Page 15: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/15.jpg)
Crossover
Genetic contents are exchanged
![Page 16: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/16.jpg)
Crossover
The process is repeated m/2 times, yielding m descendants.
The idea is that best genes survive giving rise to better fit individuals.
![Page 17: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/17.jpg)
Mutation
Once the new population is set, some genes are mutated.
Mutation is effected on a very low probability basis (typically, from 0.1% to 0.5%).
![Page 18: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/18.jpg)
Population’s Behavior
m H t m H tf H
fp
H
lp o Hc m( , ) ( , )
( )[
( )( )]
_
1 1
1
The number of schemata “m” of a given schema (H) at time “t” is given by:
![Page 19: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/19.jpg)
SGA
yprobabilitmutationp
yprobabilitcrossoverp
orderschemaHo
lengthdefiningH
m
c
)(
)(
where:
HoffitnessHf )(
populationtheoffitnessaveragef _
![Page 20: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/20.jpg)
SGA
We now illustrate with a simple example. Keep in mind that the purpose of the example
is to transmit the feeling of how a SGA works. The point to be stressed is that this Gas solve
equally well trivial problems as well as very complex ones.
We illustrate both kinds.
![Page 21: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/21.jpg)
Illustrating the SGA
Problem:What is the largest possible value for the
expression ?
To make the question meaningful we further impose:
32 2 x
120 10 x
![Page 22: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/22.jpg)
Encoding
In this case, the GA’s population consists of a set of binary strings of length 10 which we assume to be encoded in positional weighted binary.
![Page 23: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/23.jpg)
![Page 24: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/24.jpg)
![Page 25: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/25.jpg)
![Page 26: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/26.jpg)
![Page 27: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/27.jpg)
![Page 28: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/28.jpg)
![Page 29: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/29.jpg)
![Page 30: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/30.jpg)
![Page 31: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/31.jpg)
![Page 32: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/32.jpg)
![Page 33: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/33.jpg)
SGA’s Limitations
The SGA, as described, does not converge. In fact, if run indefinitely, it will find and loose the solution an infinite number of times.
Furhtermore, in some cases it will get stuck in a local optimum.
![Page 34: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/34.jpg)
Vasconcelos Algorithm
To overcome the limitations of a SGA we introduced the so called Vasconcelos GA.
It displays:
a) Deterministic (i -> n-i+1) coupling
b) Annular crossover
c) Uniform mutation
d) Full elitism
![Page 35: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/35.jpg)
Deterministic Coupling
![Page 36: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/36.jpg)
Annular Crossover
![Page 37: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/37.jpg)
Full Elitism
![Page 38: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/38.jpg)
Application Example
Optimization of a function subject to constraints» Linear functions» Linear constraints» Non-linear functions» Non-linear constraints
![Page 39: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/39.jpg)
Fitness Function
where s is the number of constraints which are satisfied and
otherwises
fulfilledareconditionsallifxxxf
)1025(10
96)( 79
21
40 s
![Page 40: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/40.jpg)
Numerical Representation
![Page 41: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/41.jpg)
Numerical Example
![Page 42: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/42.jpg)
Sample Run
![Page 43: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/43.jpg)
Sample Run
![Page 44: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/44.jpg)
Sample Run
![Page 45: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/45.jpg)
Sample Run
![Page 46: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/46.jpg)
Sample Run
![Page 47: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/47.jpg)
Sample Run
![Page 48: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/48.jpg)
Non-Numerical ExampleTraveling Salesman Problem
![Page 49: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/49.jpg)
Non-Numerical Example
In this type of problem it is needed to repair the solutions, since invalid proposals arise on two accounts:
a) Because no two cities may be repeated
b) Because not all binary combinations are necessarily utilized. Hence, some individuals are unfeasible.
![Page 50: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/50.jpg)
Repair Algorithm
To following individual is unfeasible on two accounts:
a) One city is off limits (7)
b) One city repeats itself (2)
![Page 51: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/51.jpg)
Repair Algorithm
Step 1:
Identify cities off limits
![Page 52: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/52.jpg)
Repair Algorithm
Step 2:
Identify repeated cities:
![Page 53: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/53.jpg)
Repair Algorithm
Step 3:
Establish a list of candidates for replacement.
In this case, the list is:
a) 1
b) 2
c) 5
![Page 54: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/54.jpg)
Repair Algorithm
for i=1 to number of cities to repair
a) randomly select a vacant position
b) randomly select a candidate from the list
c) eliminate the selected candidate from the list
d) Fill in the selected position
endfor
![Page 55: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/55.jpg)
Repair Algorithm
One possible repaired individual:
![Page 56: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/56.jpg)
Non-Numerical ExampleTraveling Salesman Problem
![Page 57: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/57.jpg)
Non-Numerical Example
![Page 58: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/58.jpg)
Non-Numerical Example
![Page 59: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/59.jpg)
Non-Numerical Example
![Page 60: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/60.jpg)
Non-Numerical Example
![Page 61: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/61.jpg)
Traveling Salesman Problem(Solution)
![Page 62: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/62.jpg)
Non-Numerical Example
![Page 63: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/63.jpg)
Conclusions
In the problems we illustrated there is essentially no change in the GA itself. That is, the same algorithm works on essentially different probems.
The methodology, therefore, is applicable to a wide range of possible probelms.
![Page 64: Genetic Algorithms as a Tool for General Optimization Angel Kuri 2001.](https://reader030.fdocuments.net/reader030/viewer/2022020106/56649d155503460f949ea047/html5/thumbnails/64.jpg)
Now See the Program!