资源简介
NSGA-II matlab 遗传算法源码
不错
代码片段和文件信息
function f = evaluate_objective(x M V)
%% function f = evaluate_objective(x M V)
% Function to evaluate the objective functions for the given input vector
% x. x is an array of decision variables and f(1) f(2) etc are the
% objective functions. The algorithm always minimizes the objective
% function hence if you would like to maximize the function then multiply
% the function by negative one. M is the numebr of objective functions and
% V is the number of decision variables.
%
% This functions is basically written by the user who defines his/her own
% objective function. Make sure that the M and V matches your initial user
% input. Make sure that the
%
% An example objective function is given below. It has two six decision
% variables are two objective functions.
% f = [];
% %% objective function one
% % Decision variables are used to form the objective function.
% f(1) = 1 - exp(-4*x(1))*(sin(6*pi*x(1)))^6;
% sum = 0;
% for i = 2 : 6
% sum = sum + x(i)/4;
% end
% %% Intermediate function
% g_x = 1 + 9*(sum)^(0.25);
%
% %% objective function two
% f(2) = g_x*(1 - ((f(1))/(g_x))^2);
%% Kursawe proposed by Frank Kursawe.
% Take a look at the following reference
% A variant of evolution strategies for vector optimization.
% In H. P. Schwefel and R. M鋘ner editors Parallel Problem Solving from
% Nature. 1st Workshop PPSN I volume 496 of Lecture Notes in Computer
% Science pages 193-197 Berlin Germany oct 1991. Springer-Verlag.
%
% Number of objective is two while it can have arbirtarly many decision
% variables within the range -5 and 5. Common number of variables is 3.
f = [];
% objective function one
sum = 0;
for i = 1 : V - 1
sum = sum - 10*exp(-0.2*sqrt((x(i))^2 + (x(i + 1))^2));
end
% Decision variables are used to form the objective function.
f(1) = sum;
% objective function two
sum = 0;
for i = 1 : V
sum = sum + (abs(x(i))^0.8 + 5*(sin(x(i)))^3);
end
% Decision variables are used to form the objective function.
f(2) = sum;
%% Check for error
if length(f) ~= M
error(‘The number of decision variables does not match you previous input. Kindly check your objective function‘);
end
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 2216 2006-03-16 15:28 NSGA-II源程序\evaluate_ob
文件 5695 2006-03-16 15:30 NSGA-II源程序\genetic_operator.m
文件 2024 2006-03-16 15:30 NSGA-II源程序\initialize_variables.m
文件 7102 2006-03-16 15:36 NSGA-II源程序\non_domination_sort_mod.m
文件 8127 2006-03-16 15:29 NSGA-II源程序\nsga_2.m
文件 2200 2006-03-19 19:12 NSGA-II源程序\ob
文件 2719 2006-03-16 15:38 NSGA-II源程序\replace_chromosome.m
文件 3627 2006-03-16 15:38 NSGA-II源程序\tournament_selection.m
文件 7254 2006-03-16 15:28 NSGA-II源程序\html\evaluate_ob
文件 15130 2006-03-16 15:30 NSGA-II源程序\html\genetic_operator.html
文件 6575 2006-03-16 15:30 NSGA-II源程序\html\initialize_variables.html
文件 19336 2006-03-16 15:35 NSGA-II源程序\html\non_domination_sort_mod.html
文件 21283 2006-03-16 15:29 NSGA-II源程序\html\nsga_2.html
文件 6402 2006-03-16 15:31 NSGA-II源程序\html\ob
文件 8174 2006-03-16 15:38 NSGA-II源程序\html\replace_chromosome.html
文件 10253 2006-03-16 15:37 NSGA-II源程序\html\tournament_selection.html
目录 0 2008-04-02 21:35 NSGA-II源程序\html
目录 0 2008-04-02 21:35 NSGA-II源程序
文件 183 2009-02-02 09:47 Matlab中文论坛--助努力的人完成毕业设计.url
文件 3543 2009-02-01 16:19 使用帮助:新手必看.htm
----------- --------- ---------- ----- ----
131843 20
相关资源
- 协同进化遗传算法求解函数优化问题
- 基于遗传算法的旅游全国的路径最优
- 基于遗传算法的机器人路径规划matl
- 多种群遗传算法的函数优化算法(源
- 遗传算法完整MATLAB程序实数法,轮盘
- 遗传算法解决最优路径、选址问题
- 遗传算法GA车间调度Matlab代码
- 求解多旅行商(MTSP)的遗传算法的
- 基于遗传算法的小波神经网络在股票
- matlab开发-基于遗传算法的机器人运动
- 《Matlab遗传算法工具箱及应用》源码
- 遗传算法图像分割matlab+源代码
- 神经网络、遗传算法、支持向量机、
- 谢菲尔德(Sheffield)遗传算法工具箱
- 遗传算法优化支持向量机GASVM
- 遗传算法工具箱
- MATLAB遗传算法工具箱及应用.zip
- 《MATLAB 遗传算法工具箱及应用》PDF完
- 遗传算法(Genetic Algorithm)MATLAB案例详
- MATLAB遗传算法工具箱及应用》pdf版.
- 基于遗传算法的自动排课系统设计
- MATLAB.遗传算法和粒子群算法程序设计
- 多目标优化文档及代码
- Matlab编写NSGA-Ⅱ
- 超完整规范的多目标遗传优化算法M
- Matlab编写多目标优化算法NSGA-Ⅱ的详解
- 遗传算法 -- matlab ga工具箱
- MATLAB遗传算法工具箱及应用 包含PDF电
- 两个经典的多目标优化算法代码:N
- 神经网络的43个源程序及数据
评论
共有 条评论