- 博客(0)
- 资源 (1)
- 收藏
- 关注
遗传算法(Genetic Algorithm Developed by Prof. Kalyanmoy Deb)
Genetic Algorithm Developed By : Prof. Kalyanmoy Deb with assistance from his Students.
This is a GA implementation using binary and real coded
variables. Mixed variables can be used. Constraints can also be
handled. All constraints must be greater-than-equal-to type (g >= 0)
and normalized (see the sample problem in prob1 in objective()).
There are three sample input file (inp-r for real-coded variables only,
inp-b for binary-coded variables only, and inp-rb for a mixed real and binary
variables) which can be used to run this code. The template file for
each input data file is also included (input-real, input-binary, and
input-real+binary).
Code your objective function and constraints at the end of the code
(in objective())
Variable boundaries for real-coded variables can be fixed or flexible.
Following selection opeartor is coded:
Tournament selection: Set MINM=1 for minimization and -1 for maximization
in objective().
For binary strings, single-point crossover and for real parameters
simulated binary crossover (SBX) are used.
Mutation: bit-wise for Binary coded GAs and polynomial mutation (with eta) for
Real coded GAs
Constraints are handled using Deb's paramater-less
approach (see CMAME, 2000 paper)
Niching allows restricted tournament selection. Recommended for
complex and disconnected feasible regions. (Niching parameter of 0.1 is
recommended.)
The execution creates a file `result.out' which contains the input
data and best solution obtained by the GA. The feasiblilty of the best
solution and constraint values are also marked.
The report.out contains population record of each generation.
The file 'plot.out' contains a gnuplot-compatibale data file for
plotting best, avg, and worst population fitness versus generation number.
2014-10-03
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人