Genetic Algorithm
Genetic Algorithm
Debasis Samanta
IIT Kharagpur
dsamanta@sit.iitkgp.ernet.in
06.03.2018
Today’s Topics
Concept of optimization problem
Defining an optimization problem
Various types of optimization problems
Traditional approaches to solve optimization problems
Limitations of the traditional approaches
Example:
2x − 6y = 11
or
y = (2x − 11) ÷ 6
Can we determine an optimum value for y ?
Similarly, in the following case
3x + 4y ≥ 56.
Diameter d
Length l
Example:
Minimize y = f (x1 , x2 ) = (x1 − 5)2 + (x2 − 3)3
where x1 , x2 ≥ 0
Example:
Maximize y = f (x1 , x2 , · · · , xn )
Subject to
gi (x1 , x2 , · · · , xni ) ≥ ci
where i = 1, 2, · · · , k and k > 0
and
x1 , x2 , · · · , xn are design parameters.
Example:
Minimize y = f (x1 , x2 ) = 2x1 + x2
Subject to
x1 + x2 ≤ 3
5x1 + 2x2 ≤ 9
and
x1 , x2 are integer variables.
Real-valued problem
If all the design variables are bound to take real values.
If either the objective function or any one of the functional constraints are
non-linear function of design variables.
Example:
Maximize y = f (x1 , x2 ) = x12 + 5x23
Subject to
x14 + 3x22 ≤ 629
2x13 + 4x23 ≤ 133
and
x1 , x2 ≥ 0
Optimization Methods
Note:
An inflection point is a point, that is, neither a maximum nor a minimum
at that point.
Following figure explains the concepts of minimum, maximum and saddle
point.
Maximum
Saddle Points
Minimum
x1 * x2*
x
Optimal Solution
x=x2*
x=x1* x=x3* x
Principle
A Minimization (Maximization) problem is said to have dual problem if it
is converted to the maximization (Minimization) problem.
The usual conversion from maximization ⇔ minimization
y = f (x) ⇔ y ∗ = −f (x)
y = f (x) ⇔ y ∗ = f (x)
1
Maximization Problem
y = f(x)
y x
Minimization Problem
y* = f(x)
Computationally expensive.
For a discontinuous objective function, methods may fail.
Method may not be suitable for parallel computing.
Discrete (integer) variables are difficult to handle.
Methods may not necessarily adaptive.
Biologic behaviors:
Genetics and Evolution –> Genetic Algorithms (GA)
Behavior of ant colony –> Ant Colony Optimization (ACO)
Human nervous system –> Artificial Neural Network (ANN)
Firs time itriduced by Ptrof. John Holland (of Michigan University, USA,
1965).
But, the first article on GA was published in 1975.
Chromosome
Reproduction
+ = Organism’s cell :
Cell division
x y
gamete diploid
Kinetochore
Information from
two different Combined into so that diversity
organism’s body in information is possible
cells
Random crossover points
makes infinite diversities
Mutation:
Genetics
Definition of GA:
Genetic algorithm is a population-based probabilistic search and
optimization techniques, which works based on the mechanisms of
natural genetics and natural evaluation.
Start
Note:
An individual in the
population is
corresponding to a
Initial Population possible solution
No
Converge ? Selection
Yes
Reproduction
Stop
Note:
1 GA is an iterative process.
2 It is a searching technique.
3 Working cycle with / without convergence.
4 Solution is not necessarily guranteed. Usually, terminated with a
local optima.
Start
Define parameters
Parameter representation
Create population
Initialize population
Apply cost
function to each of
the population
No
Converge ? Evaluate the fitness
Selection
Yes
Select Mate
Stop
Crossover
Reproduction
Mutation
Inversion
Objective function(s)
Constraint(s)
Input parameters
Encoding
Decoding
Start
Convergence
Yes Return the individual(s) with
Criteria meet ? best fitness value
No
Select Np individuals
(with repetition) Stop
Perform inversion on
the offspring
SGA Parameters
Convergence threshold δ
Mutation µ
Inversion η
Crossover ρ
Simple GA features:
Computationally expensive.
Crossover
Mutation
Inversion
No
Convergence
meet ?
Stop
SGA Features:
It is applicable when
Limitations in SSGA:
Any Questions??