are search
techniques based
on the mechanism
of natural
selection.
1.
2.
3.
4.
5.
Termination criteria
Representation
1.Binary
strings
2.Real number coding
3.Integer coding
Binary strings
Difficult
coding.
01110011
This is a chromosome.
Gene
Integer coding
Mainly
Decoding
Coding space
Solution space
Genetic
Operation
s
Evaluation
and
Selection
Encoding
feasibility of a chromosome.
2.The legality of chromosome.
3.The uniqueness of mapping.
Illegal
one
Infeasible one
Solution Space
Coding
space
Feasible
one
1 to n
mapping
Coding
space
n to 1
mapping
Solution
space
1 to 1
mapping
search
3.Feasible solution
But in most of the cases initial population is
randomly generated.
Parent no
Fitness
value
14.3567
9.3245
21.7632
17.6543
16.5463
18.2453
space
2.Sampling mechanism
3.Selection probability
Crossove
r
Mutation
Initial sample
space
Offspring
New sample
space
Crossover
Mutation
Offspring
pk
fk
pop _ size
j 1
Zone of kth
individual
fj
2- Deterministic sampling
select best popsize individuals from the
parents and offspring
No duplication of the individuals
3- Mixed sampling
1.
2.
3.
4.
Uniform crossover
h
A
Arithmetic crossover
a
(e+E)/2 (f+F)/2
Chromosomes
0
1
1
0
Compariso Chromosom
n of
e selected
crossover
or not
probability
0.56
< 0.8
no
0.92 > 0.8
yes
0.74 < 0.8
no
0.21 < 0.8
no
0.84 > 0.8
yes
0.87 > 0.8
0.2
1
0.4
5
0.0
4
0.6
1
Less than
0.1
1
0.4
6
0.8
4
0.0
5
0.7
3
0.1
9
0.4
4
Mutation
0
1
1.
2.
Generational replacement
In generational replacement the new generation
completely replaces the old generation.
But this replacement scheme has a big
disadvantage. If one replaces the whole
generation the risk of dismissing a very
promising solution is high.
So De Jong introduced the concept of elitism
within Generational replacement.
The most promising solution is always kept in the
population termed as elite.
Steady-State Replacement
In steady-state replacement only one
solution is replaced rest all remains the
same.
of maximum no of generations
as given in problem.
2.No improvement for some generations.
3.A solution is found that satisfies minimum
criteria.
1.Genetic
DV
f(x)
01001
0.91
2
0.791
10100
20
2.02
7
00001
0.10
1
fi/favg
AC
Mating
Pool
1.39
01001
0.898
1.58
10100
0.101
0.18
10100
11010
11010
26
2.63 0.485 0.85
DV
Decoded
5 value
AC
Actual count of strings in the
favg
0.569
population
For string 1
Decoded value
01001 0 24 1 23 0 22 0 21 1 20 9
Thestring value
x xmin (( xmax xmin ) /(2l 1)) DV
0
0 9 5 0.912
2 1
theFunction value
f ( x) sin(0.912) 0.791
fi
0.791
1.39
f avg 0.569
Stri
ng
No.
Initial
Decod
Populatio ed
n
value
1
2
3
4
5
6
100101
011010
010110
111010
101100
001101
37
26
22
58
44
13
x
f(x)=
value (x)1/2
9.81
7.19
6.24
14.81
11.48
4.09
3.13
2.68
2.50
3.85
3.39
2.02
Pselection
f
0.18
0.15
0.14
0.22
0.19
0.12
sum=17.57
Average f=2.92
maximum f=3.85
f
Avg=.16
6
Expecte
d count
(fi/f)
1.07
0.91
0.85
1.31
1.16
0.69
100101 = 1*25+0*24+0*23+1*22+0*21+1*20 = 37
The value of x
1 37
16 1
9.81
26 1
Parents
Cross
over
point
Crossov
er site
Children
String
Mutatio
n
1
1
0
2
2
0
10010
1
11101
0
01101
0
10110
0
11101
0
2
2
3
3
3
3
10010
1
11101
0
01101
0
10110
0
11101
0
10101
0
11010
1
01110
0
10100
0
11110
0
10101
0
11010
1
01110
0
10100
0
11110
0
10010
1
01101
0
11101
0
11101
0
10110
0
Decoding
Decoded
value
42
53
28
40
60
42
X
Value
11.00
13.62
7.67
10.52
15.28
11.00
f(x)=(X)1/2
3.32
3.69
2.77
3.24
3.91
3.32
Sum
=20.25
Average
f=3.37
Custome
r Zone
1
Custome
r Zone
2
Custome
r Zone
3
Custome
r Zone
4
Plant 1
20
25
17
22
Plant 2
14
19
Plant 3
13
15
23
30
Plant 4
25
12
Average fitness of
all string
Random
Randomno
noofofString
String
13and
and24isisless
lessthan
than
CC
So
So
String
String
1
3and
and
24
p, p,
isisselected
selectedfor
for
crossover
crossover
Crossover Procedure
Ch1
Pr1
Pr1
Ch2
After crossover
Before crossover
Selection Criteria:String No
Let , Crossover Probability (CP) = 0.8
Random no. used for crossover:-
Iteration 1
Iteration 2
0.98
0.47
0.93
0.55
0.45
0.88
0.57
0.93
Initial Population
String
1)
2)
3)
4)
For string 4
D = 8 +15 +19+22 = 64
fitness (f) = (100-64) = 100 -64 = 36
String
Objective
function value
(D)
Fitness
value(f)
Expected
count
1 2 3 4
59
41
1.21 1
2 4 1 3
86
14
0.41 0
3 1 4 2
56
44
1.302
4 3 2 1
64
36
1.07 1
ftotal= 135
favg=
33.75
Mating Pool
String
1)
2)
3)
4)
2)
3)
4)
String
Objective
function value
(D)
Fitness
value(f)
Expected
count
1 2 3 4
59
41
1.14 1
3 1 4 2
56
44
1.23 2
1 3 2 4
61
39
1.031
2 1 4 3
81
19
0.53 0
Mating Pool
1)1 2 3
2)3 1 4
3)3 1 4
4)1 3 2
ftotal= 143
favg=
35.75
4
2
2
4
Ch2 4
3
3
After Crossover
String
1)
2)
3)
4)
String
Objective
function value
(D)
Fitness
value(f)
Expected
count
2 1 4 3
81
19
0.54 0
4 2 3 1
62
38
1.08 1
3 1 4 2
56
44
1.252
1 3 2 4
61
39
1.11 1
ftotal= 140
favg= 35
For m1
(12.1-(-3)) x 10,000 = 1,51,000
217 < 1,51,000 < 218 1
So m1 = 18 and
Similarly m2 = 15
Binary Number
Number
Decimal
Chromosome
No
Probability
Cumulative
probability
0.111180
0.111180
0.097515
0.208695
0.053839
0.262534
0.165077
0.427611
0.088057
0.515668
0.066806
0.582475
0.100815
0.683290
0.110945
0.794234
0.148211
0.942446
10
0.057554
1.000000
0.322062
0.350871
0.343242
0.766505
0.583392
0.032685
bit_ no
Chromosome Bit no of
no
chromoso
me
Random
no
105
0.009857
164
32
0.003113
199
0.000946
329
10
32
0.001282
Tournament Selection
In tournament selection, tournaments are
played between two solution and the better
solution is chosen and placed in the mating
pool.
Proportionate Selection method
Solutions are assigned copies, the number
of which is proportional to their fitness value.
Based on Roulette-Wheel Selection method
Here,
Fi
pi
Pi
j 1
Fi
i (1, N )
j 1
Solution ,
i
Fi
pi
Pi
piN
25.0
0.25
0.25
1.25
5.0
0.05
0.30
0.25
40.0
0.40
0.70
2.00
10.0
0.10
0.80
0.50
For solution 1:
Total sum of fitness(F) = 25+5+40+10+20=100
The probability pi = 25/100 = 0.25
Pi N = 5 * 0.25 = 1.25
1.
2.
3.
0 1 0 1 0 0 0 1 1 0
0 1 1 1 0 0 0 1 1 0
0 1 1 0 0 0 1 0 1 0
Parent Strings
Strings
Offspring
0 1 0 1 0 0 0 0 1 0
0 1 1 1 0 0 0 1 1 0
0 1 1 0 0 0 1 1 1 0
Parent Strings
Strings
Offspring
0 1 0 0 0 0 1 0 1 0
0 1 1 1 0 0 1 1 1 0
0 1 1 1 0 0 0 1 1 0
0 1 0 0 0 0 0 0 1 0
Parent Strings
Strings
Offspring
Parent Strings
Strings
0 1 1 0 0 0 1 0 1 0
Mutated
1
pm
Definition:
Leftmost position
= 6 2 =4
f(H)
(H)
m(H,t+1) m(H,t)
1 - pc
- p m O(H)
f avg
l 1
Where,
m(H,t) = Number of copies of Schema H in generation t
f(H)
f avg
= Fitness of Schema H
= Average fitness of population
pc
= Crossover probability
pm
= Mutation probability
Example:
Maximize Sin(X), Variable bound 0Xpi
Initial population
String
DV
(decoded
Value)
Sin(X)
fi/favg.
01001
0.912
0.791
1.39
01001
10100 (H1)
20
2.027
0.898
1.58
10100
00001 (H2)
0.101
0.101
0.18
10100
11010
26
2.635
0.485
0.85
11010
Pc= 1, pm=0,
H1= ( 1 0 * * * )
AC
Mating pool
(actual count)
favg=0.569
, H2 = ( 0 0 * * * )
m(H1,1)(1)(0.898/0.569)[1-{11/(5-1)}-02]
1.184, H1 must increase.
m(H2,1)0.133
Mating
pool
CS
(Cross
site)
New population
String
DV
Sin(X)
01001
01000
0.811
0.725
10100
10101
21
2.128
0.849
10100
10010
18
1.824
0.968
11010
11100
28
2.838
0.299
favg.= 0.710
For H1=(1 0 * * *)
m(H1, 0) = 1
Crossover operation = pc = 1
Mutation operation = pm = 0
f(H1) = 0.898
Order of string o(H1) = 2
Defining length = (H ) = 2-1 = 1
The average fitness = f avg = 0.569
m( H1 ,1) (1)
1.184
0.898
1
[1 (1.0)
0 (2)]
0.569
5 1
For H2=(0 0 * * *)
m(H2, 0) = 1
Crossover operation = pc = 1
Mutation operation = pm = 0
f(H2) = 0.101
Order of string o(H2) = 2
Defining length = (H ) = 2-1 = 1
The average fitness = f avg = 0.569
m( H 2 ,1) (1)
0.133
0.101
1
[1 (1.0)
0 (2)]
0.569
5 1
0.1
0.2
H0
0.3
Figure0.5
1
0.4
average value
0.6
0.7
H1
0.8
0.9
f(x)
1.5
1
0.5
0
0
Figure 2.
0.1
0.2
H0
0.3
0.4
0.5
Fig. 2
0.6
0.7
0.8
0.9
H1
f(x)
2
1.5
1
0.5
0
0
0.1
0.2
H0
0.3
0.4
H1
0.5
0.6
H2
0.7
0.8
0.9
H3
3.5
3
2.5
f(x)
1.5
1
0.5
0
0
0.1
H0
0.2
H1
0.3
0.4
H2
0.5
H3
0.6
H4
0.7
0.8
H5
0.9
H6
H7
Crossover
2. Nave crossover
3. Blend Crossover
4. Simulated Binary Crossover
5. Unimodal Normally Distributed Crossover
6. Simplex Crossover
7. Fuzzy Connectives Based Crossover
8. Unfair Average crossover
Linear Crossover:
Three Solutions are generated from two
parent solution.
Best two are chosen as offspring.
Parents
Offspring
xi(1,t)
xi(2,t)
Spread Factor
It is the ratio of the absolute difference
in offspring values to that of the parents.
It is denoted
.
i by
i
Procedure:
xi( 2,t 1)
for
i 1,..., j
for i j 1,..., n
for
i 1,..., j
for i j 1,..., n
Xj
x (1, t+1)
x (2, t)
x (2, t+1)
x (1, t)
Xi
1.
2.
Random Mutation
Non-uniform Mutation
Normally distributed distribution
Polynomial Mutation
1.
2.
3.
1.
2.
Methods:
1. By adding Generation dependent
penalty term in static penalty term.
F(x)= f(x) + R [ <gi(x)> + |hk(x)| ] + (t,
x).
(t, x) is the difference between the static
penalty function between best infeasible
solution and worst feasible solution.
1
.
5
)
(
x
4
)
2
Minimize 1
2
4
.
5
x
x
18 0
1
2
subject to
2 x1 x2 1 0
0 x1 , x2 4
(b)
qi
2
(
1
)
i
1
c 1
qi
2(1 0.723)
1
3
We get,
(1,t 1)
i
( 2 ,t 1)
i
x
x
and
1.218
( 2)
0.5( 1)
P( )
2
0.5( 1) /
1
1
Where
and c1,c2 are children solutions
(c 2 c1) /( p 2 p1)
created from parent solution p1,p2
(a)
Considering x1
Range of x1 for children solution is (0,3) and
parent solution varies from (5,10) so the spread
factor will be,
(3 0) /(10 5) 0.6
Considering x2
Range of x2 for children solution is (0,3) and
parent solution varies from (3,5) so the spread factor
will be,
(3 0) /(5 3) 1.5 greater than 1
Calculating probability for by P ( ) 0.5( 1) /
2
c 2
(b) Considering x1
x1 for parent solution is (10,5), Calculating
children solutions with 0.67
x1(1,t 1) [10 0.67 * (5 10)] 13.35
x1( 2,t 1) [5 0.67 * (5 10)] 1.65
Considering x2
x2 for parent solution is (3,5), Calculating children
solutions with 0.67
x1(1,t 1) [3 0.67 * (5 3)] 1.66
x1( 2,t 1) [3 0.67 * (5 3)] 4.34
Therefore Probability =
ri 0.675 ,
y ( t 1) x (t ) [ x (u ) x ( L ) ] i
Where,
i 1 [2(1 ri )]1/( m 1)
if ri 0.5
x 5.0 x 10 x ( L ) 0
(t )
(u )
i 1,........., N obj
Subject to,
g k ( x) 0, k 1,........., K
hl ( x) 0, l 1,.........., L
Where,
f i is the objective function, x is a
decision vector that represents a
solution
N obj
and
is the number of objectives. K
and L are the number of equality and
inequality constraints respectively.
Non-Pareto Techniques
Pareto Techniques
Aggregating approaches
Vector evaluated genetic algorithm (VEGA)
Lexicographic ordering
The
- constraint Method
Target-vector
approaches
Pareto front
Pareto front
y2 approximation
Pareto set
Pareto set
Decision
approximation
X2
Objective
Space
Space
y1
X1
(X1,X2,, Xn
)
Sear
ch
(y1,y2,
,yn)
Evaluatio
n
f2
Convergence
Diversity
f1
Convergence to
pareto optimal
frontier
Diversity
(representation of
the entire pareto
optimal frontier)
f2
Third front
Second front
First front
f1
Minimization of f1 and
f2
Fitness assignment:
Solutions in the
same front have the
same fitness (they
all have the same
rank)
Diversity preservation
f2
i-1
cuboi
d
i
i+1
f1
Sharing in NSGA is
replaced with
crowded
comparison
Crowded distance of
solution i in a front is
the average side
length of the cuboids'.
1.
f m ( xi 1 ) f m ( xi 1 )
CDim
, i 2,......l 1
f m ( xmax ) f m ( xmin )
1.
CD
m 1
im
Between two solution with different nondomination ranks, the one with lower (better)
rank is preferred
When two solutions have the same nondomination rank (belong to the same front), the
one located in a less crowded region of the
front is preferred
n
1
n
2
n
3
n
4
n
5
n
6
n
7
n
8
n
9
n
10
------
X represents gene
Index 1, 2, 3..18 indicates activities
n represents alternative of activity.
Each alternative represents different time, cost and quality.
n
X18
START
Population
Initialization
Evaluate Fitness
Child
populati
on
No
Combine parent
population of size N
with child population of
size N
Fast non-dominated
sorting on combined
population
Create new population
of size N using crowding
comparison operator
Yes
Fast non-dominated
Sorting
Calculate crowding
distance
Yes
Last
generatio
n
No
Next generation
STOP
Randomly
Local search
Feasible Solutions
Decisi
on
Variab
le
Fitness
value
Activity
Soluti
alternative
on
Tim
e
No
4 5 1 3 4 3 1 1 1 1 1 2 3 2 1 3 1 1
1
12
2
2 1 2 1 2 1 1 1 1 1 1 1 3 1 1 3 1 1 3
3
2 4 1 3 4 3 1 1 3 1 1 1 1 1 1 5 1 1 10
4
30
0
1 1 1 3 4 3 1
2 2 1 3 4 3 1
Cost Quali
ty
1146
20
73.6
3
1483
65
85.4
6
1 2
1 1 4 3 2 1 5 1 2 8
2 2
12
1 1 1 3 2 1 4 1 1 0
13
1
1179
50
75.9
3
1153
60
73.5
11
1166
74.5
Integer
F1: Rank=1
F2: Rank=2
Crossover
Point
Parent 1
Parent 2
Offspring 1
Offspring 2
Let pm = 1/18 =
0.055
.. 2
0.4
1
Mutation
.. 2
Pt
F1
F2
F3
Using crowding
comparison
operator
Qt
Combined
population
(R t )
Pt
Qt
Pt+1
Rejected
solutions
= Parent population
= Offspring
population
Pt+1 = Population for next
NSGA-II Parameter
Parameter value
Population size
300
Number of generations
1000
Crossover probability
(Pc)
0.8
Mutation probability
(Pm)
0.1
Time-cost-quality tradeoff
surface