首页 > 化工知识 > 【优化求解】基于平衡优化器算法求解单目标优化问题matlab代码

【优化求解】基于平衡优化器算法求解单目标优化问题matlab代码

时间:2021-12-04 来源: 浏览:

【优化求解】基于平衡优化器算法求解单目标优化问题matlab代码

原创 天天Matlab 天天Matlab
天天Matlab

收录于话题 #智能优化算法及应用 212个 内容

2 部分代码

--------------------------------------------

fobj = @YourCostFunction

dim = number of your variables

Max_iteration = maximum number of iterations

Particles_no = number of particles (search agents)

lb=[lb1,lb2,...,lbn] where lbn is the lower bound of variable n

ub=[ub1,ub2,...,ubn] where ubn is the upper bound of variable n

---------------------------------------------------------

Run_no=30;   Number of independent runs 

Particles_no=30;    Number of particles

Max_iteration=500; Maximum number of iterations

Draw search space

Draw objective space

img =gcf;  获取当前画图的句柄

print(img, ’-dpng’, ’-r600’, ’2.png’)  即可得到对应格式和期望dpi的图像

3 仿真结果

4 参考文献

天天Matlab

已喜欢, 对作者说句悄悄话
最多40字,当前共 字

1 / 3

赞赏二维码

版权:如无特殊注明,文章转载自网络,侵权请联系cnmhg168#163.com删除!文件均为网友上传,仅供研究和学习使用,务必24小时内删除。
相关推荐
Baidu
map