织梦笑话网站,做一个大型网站,江西有色建设集团公司 网站,最近在线观看免费完整版高清韩剧文章目录 【获取资源请见文章第5节#xff1a;资源获取】1. 原始POA算法2. 改进后的IPOA算法2.1 随机对立学习种群初始化2.2 动态权重系数2.3 透镜成像折射方向学习 3. 部分代码展示4. 仿真结果展示5. 资源获取 【获取资源请见文章第5节#xff1a;资源获取】 1. 原始POA算法… 文章目录 【获取资源请见文章第5节资源获取】1. 原始POA算法2. 改进后的IPOA算法2.1 随机对立学习种群初始化2.2 动态权重系数2.3 透镜成像折射方向学习 3. 部分代码展示4. 仿真结果展示5. 资源获取 【获取资源请见文章第5节资源获取】 1. 原始POA算法
此算法详细介绍请参考POA算法介绍
2. 改进后的IPOA算法
2.1 随机对立学习种群初始化
采用随机方法初始化POA种群生成的种群不均匀影响了收敛速度和精度。为了获得更好的初始种群本文采用了随机对立学习策略来进行种群初始 X i , n e w ( l u ) − k X i (1) X_{i,new}(lu)-kX_{i}\tag1 Xi,new(lu)−kXi(1) 其中 X i X_{i} Xi为原解 X i , n e w X_{i,new} Xi,new为随机对立学习生成的反向解 k k k为[0,1]之间的随机数。 经过随机对立学习策略后生成了 N N N个反向解如果反向解的适应度值优于原解就用反向解替代原解否则保留原解。
2.2 动态权重系数
基本鹈鹕优化算法的开发阶段在迭代后期会存在陷入局部最优的情况使搜索失败。为克服这一弊端再在其位置更新公式中加入动态权重系数 ω让它在迭代初期具有较大值促进全局搜索迭代后期自适应变小促进局部搜索并加快收敛速度。
2.3 透镜成像折射方向学习
透镜成像折射反向学习策略的思想来自于凸透镜成像的原理。通过基于当前坐标生成一个反向位置来扩展搜索范围如图1所示。 图1 透镜成像折射反向学习原理图 在二维坐标中x轴的搜索范围为(a, b) y轴表示一个凸透镜。假设物体A在x轴上的投影为x高度为h通过透镜成像另一侧的图像为A* A在x轴上的投影为x高度为h*。通过以上分析我们可以得到如下公式 ( a b ) / 2 − x x ∗ − ( a b ) / 2 h h ∗ (2) \frac{(ab)/2-x}{x^{*}-(ab)/2 }\frac{h}{h^{*}} \tag2 x∗−(ab)/2(ab)/2−xh∗h(2) 对公式(2)进行转换即可得到反向解x*的表达式为 x ∗ a b 2 a b 2 k − x k (3) x^{*} \frac{ab}{2}\frac{ab}{2k}-\frac{x}{k} \tag3 x∗2ab2kab−kx(3) 其中 k h / h ∗ kh/h^{*} kh/h∗ a a a和 b b b可以视为某维度的上下限。本文中的 k k k是一个与迭代次数相关的动态自适应值。
3. 部分代码展示
%%
clc
clear
close all%%
Fun_nameF1; % number of test functions: F1 to F23
SearchAgents30; % number of Pelicans (population members)
Max_iterations500; % maximum number of iteration
[lb,ub,dim,fobj]Get_Functions_details(Fun_name); % Object function information
[Best_score_POA,Best_pos_POA,POA_curve]POA(SearchAgents,Max_iterations,lb,ub,dim,fobj);
[Best_score_SSA,Best_pos_SSA,SSA_curve]SSA(SearchAgents,Max_iterations,lb,ub,dim,fobj);
[Best_score_WOA,Best_pos_WOA,WOA_curve]WOA(SearchAgents,Max_iterations,lb,ub,dim,fobj);
[Best_score_GWO,Best_pos_GWO,GWO_curve]GWO(SearchAgents,Max_iterations,lb,ub,dim,fobj);
[Best_score_IPOA,Best_pos_IPOA,IPOA_curve]IPOA(SearchAgents,Max_iterations,lb,ub,dim,fobj);%%
figure(Position,[454 445 694 297]);
subplot(1,2,1);
func_plot(Fun_name);
title(Parameter space)
xlabel(x_1);
ylabel(x_2);
zlabel([Fun_name,( x_1 , x_2 )])subplot(1,2,2);
t 1:Max_iterations;
semilogy(t, POA_curve, b-, t, SSA_curve, k-, t, WOA_curve, g-, t, GWO_curve, m-, t, IPOA_curve, r-,linewidth, 1.5);title(Fun_name)
xlabel(Iteration);
ylabel(Best fitness function);
axis tight
legend(POA,SSA,WOA,GWO,IPOA)display([The best solution obtained by POA for [num2str(Fun_name)], is : , num2str(Best_pos_POA)]);
display([The best optimal value of the objective funciton found by POA for [num2str(Fun_name)], is : , num2str(Best_score_POA)]);
display([The best solution obtained by SSA for [num2str(Fun_name)], is : , num2str(Best_pos_SSA)]);
display([The best optimal value of the objective funciton found by SSA for [num2str(Fun_name)], is : , num2str(Best_score_SSA)]);
display([The best solution obtained by WOA for [num2str(Fun_name)], is : , num2str(Best_pos_WOA)]);
display([The best optimal value of the objective funciton found by WOA for [num2str(Fun_name)], is : , num2str(Best_score_WOA)]);
display([The best solution obtained by GWO for [num2str(Fun_name)], is : , num2str(Best_pos_GWO)]);
display([The best optimal value of the objective funciton found by GWO for [num2str(Fun_name)], is : , num2str(Best_score_GWO)]);
display([The best solution obtained by IPOA for [num2str(Fun_name)], is : , num2str(Best_pos_IPOA)]);
display([The best optimal value of the objective funciton found by IPOA for [num2str(Fun_name)], is : , num2str(Best_score_IPOA)]);4. 仿真结果展示 5. 资源获取
可以获取完整代码资源。