Title: GENETIC ALGORITHMS AND GENETIC PROGRAMMING
1GENETIC ALGORITHMS AND GENETIC PROGRAMMING
Ehsan Khoddam Mohammadi
2DEFINITION OF THE GENETIC ALGORITHM (GA)
The genetic algorithm is a probabilistic search
algorithm that iteratively transforms a set
(called a population) of mathematical objects
(typically fixed-length binary character
strings), each with an associated fitness value,
into a new population of offspring objects using
the Darwinian principle of natural selection and
using operations that are patterned after
naturally occurring genetic operations, such as
crossover (sexual recombination) and mutation.
3Biological Background
- Chromosome (Genome)
- Genes
- Proteins (A T G C)
- Trait
- Allele
- Natural Selection (survival of fittest)
4GA FLOWCHART
5Which problems could be solved by GA?
- Nonlinear dynamical systems - predicting, data
analysis - Designing neural networks, both architecture and
weights - Robot trajectory
- Evolving LISP programs (genetic programming)
- Strategy planning
- Finding shape of protein molecules
- TSP and sequence scheduling
- ?All Optimization Problems (Knapsack,Graph
coloring,)
6GA Operations
- Encodings
- Initiate Population
- Selection
- Reproduction
- Crossover (sexual reproduction)
- Mutation
7GA Operations (Cont.)ENCODING(1/3)
- Fixed-Length encoding
- 1D encoding arrays, lists, strings,
- 2D encoding matrices,graphs
- Variable-Length encoding
- Tree encoding binary parser trees like
postfix,infix,
8GA Operations (Cont.)ENCODING (2/3)
- Permutation Encoding
- Map Coloring problem , TSP,
- Array in size of regions, each cell has an
integer corresponding to available colors. - R1 G2 B3 W4
- Binary Encoding
- Knapsack problem, equation solving ()
- Chromosome A 101100101100101011100101 Chromosome
B 111111100000110000011111
1 2 2 3 1 4 4 1 2 2
9GA Operations (Cont.)ENCODING (3/3)
- Tree encoding
- Genetic programming, finding function of given
values (elementry system identification)
( do_until  step  wall )
(  x  ( /  5  y ) )
10GA Operations (Cont.)SELECTION (1/3)
- In GA ,the object is to Maximizing or Minimizing
fitness values of population of Chromes. - Fitness Function should be applicable to any
Chromes (bounded). - Mostly a positive number, showing a distance
between present state to goal state. - In NP-Complete or partially defined problems
should relatively be computed . - Two important parameters
- Population diversity (exploring new areas)
- Selective pressure ( degree to which better
individuals are favoured)
11GA Operations (Cont.)SELECTION (2/3)
- Roulette Wheel Selection (improved by Ranking)
- Sum Calculate sum of all chromosome fitnesses
in population - sum S. - Select Generate random number from interval
(0,S) - r. - Loop Go through the population and sum
fitnesses from 0 - sum s. When the sum s is
greater then r, stop and return the chromosome
where you are - Not suitable for highly variance populations
- Using RANK Selection
- The worst will have fitness 1, second worst 2
etc. and the best will have fitness N (number of
chromosomes in population). - Converge Slowly
1
2
12GA Operations (Cont.)SELECTION (3/3)
- Steady-state Selection (threshold)
- Fittest just survived
- Elitism
- Fittest selected, for others we use other
selection manners - Boltzmann Selection
- P(E)exp(-E/kT), like SA. Number of selections
reduces in order of growing of age - Tournament Selection
13F.Nitzche
14GA Operations (Cont.)REPRODUCTION(1/1)
- Reproduction rate
- Selected gene transfers directly to new
Generation without any change.
15GA Operations (Cont.)CROSSOVER(1/1)
- CROSSOVER rate
- Single Child
- Single-Point
- 1100101111011111 11001111
- Multi-Point
- Uniform
- Arithmetic
- 11001011 11011111 11001001 (AND)
- Multi Children
16GA Operations (Cont.)MUTATION(1/1)
- Mutation rate
- Inversion
- Deletion and Regeneration
-
- For TSP is proved that some kind of mutation
causes to most efficient solution
11001001 gt  10001001
17GA EXTENTIONS (part 1)
- GENETIC PROGRAMMING
- solve a problem without explicitly programming
- Writing program to compute X2X1
18GENETIC PROGRAMMING
19Genetic Programming (1/4)PREPARATORY STEPS
Objective Find a computer program with one input (independent variable X) whose output equals the given data
1 Terminal set T X, Random-Constants
2 Function set F , -, ,
3 Fitness The sum of the absolute value of the differences between the candidate programs output and the given data (computed over numerous values of the independent variable x from 1.0 to 1.0)
4 Parameters Population size M 4
5 Termination An individual emerges whose sum of absolute errors is less than 0.1
20Genetic Programming (2/4) initial population
21Genetic Programming (3/4)FITNESS OF THE 4
INDIVIDUALS IN GEN 0
22GENETIC PROGRAMMING (4/4)
23REPRESENTATIONS
- Binary decision diagrams
- Formal grammars
- Coefficients for polynomials
- Reinforcement learning tables
- Conceptual clusters
- Classifier systems
- Decision trees
- If-then production rules
- Horn clauses
- Neural nets
- Bayesian networks
- Frames
- Propositional logic
24GA EXTENTIONS (part 2)
- Multi Modal GA
- SOCIAL MODEL religion based
- Hybrid Methods ( associate with FL and ANN)
25REFRENCES
- Neural Networks, Fuzzy Logic and Genetic
Algorithms ,Synthesis and Applications - S.Rajasekaran
- G.A.Vijayalakshmi Pai
- PSG College of Technology,Coimbatore
- http//www.smi.stanford.edu/people/koza
- Doctor John R. Koza
- Department of Electrical Engineering
- School of Engineering
- Stanford University
- Stanford California 94305
- http//cs.felk.cvut.cz/xobitko/ga/
- Marek Obitko, obitko_at_email.cz
26???? ????? ?? ????? ???? ?????!
?? ????