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

📄 dejong_f2.m

📁 本文是关于粒子群算法(pso)的介绍和相关MATLAB源程序,是智能天线权值优化方面的一种很前沿的算法
💻 M
字号:
% DeJong_f2.m
% De Jong's f2 function, also called a Rosenbrock Variant
% This is a 2D only equation
%
% described by Clerc in ...
% http://clerc.maurice.free.fr/pso/Semi-continuous_challenge/Semi-continuous_challenge.htm
%
% used to test optimization/global minimization problems 
% in Clerc's "Semi-continuous challenge"
%
% f(x,y) = 100*(x.^2 - y).^2 + (1-x).^2;
%
% input = 2 element row vector containing [x, y]
%   each row is processed independently,
%   you can feed in matrices of timeXN no prob
%
% example: cost = DeJong_f2([1,2;3,4;5,6])
% note minimum =0 @ (1,1)

% Brian Birge
% Rev 1.0
% 9/12/04
function [out]=DeJong_f2(in)
 
 x= in(:,1);
 y= in(:,2);

 out = 100*(x.^2 - y).^2 + (1-x).^2;

⌨️ 快捷键说明

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