⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 multiverificationobjfunc.m

📁 this file is a zip file for multi objective optimization by matlab.
💻 M
字号:
function [fitness] = multiVerificationObjFunc(u, opts)
% This objective function was used to verify the capabilities of
% the multiple variable representation possibilities of the
% multiGA code

% It is a basically a Riccati equation using 10 floating point
% and/or dependent integer design variables and 6 independent or
% binary design variables (whose absolute value is only added to
% the overall value).

% By Kerry W. Lothrop <kerry@lothrop.de>%% Lothrop, K.W.: Conceptual Design Optimization of a Cis-Lunar% Transportation Architecture Using Genetic Algorithms, Universit鋞% Stuttgart, University of Colorado, 2003%% This program is free software; you can redistribute it and/or modify% it under the terms of the GNU General Public License as published by% the Free Software Foundation; either version 1, or (at your option)% any later version.%% This program is distributed in the hope that it will be useful,% but WITHOUT ANY WARRANTY; without even the implied warranty of% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the% GNU General Public License for more details. A copy of the GNU % General Public License can be obtained from the % Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
generation = opts(1);
x = zeros(10, 1);
x(1) = opts(2);
fitness = x(1)^2 + u(1)^2;

for k = 2:10
	x(k) = x(k - 1) + u(k - 1);
	fitness = fitness + x(k)^2 + u(k)^2;
end
fitness = fitness + (x(k) + u(k))^2;
for digit = 11:16
    fitness = fitness + abs(u(digit));
end
% Minimizing means maximizing the negative
fitness = -fitness;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -