淮安百度网站建设,站内优化包括哪些,适合设计师看的设计网站,工作服定制电话#x1f4a5;#x1f4a5;#x1f49e;#x1f49e;欢迎来到本博客❤️❤️#x1f4a5;#x1f4a5; #x1f3c6;博主优势#xff1a;#x1f31e;#x1f31e;#x1f31e;博客内容尽量做到思维缜密#xff0c;逻辑清晰#xff0c;为了方便读者。 ⛳️座右铭欢迎来到本博客❤️❤️ 博主优势博客内容尽量做到思维缜密逻辑清晰为了方便读者。 ⛳️座右铭行百里者半于九十。 本文目录如下 目录 1 概述 2 运行结果 3 参考文献 4 Matlab代码及详细文章 1 概述 受孔雀群智能行为的启发POA的设计包括有效和高效的探索性和剥削性搜索算子以在全球探索和局部开发之间提供适当的权衡以避免局部最优例如孔雀独特的旋转舞蹈操作孔雀和孔雀幼崽在不同搜索阶段的自适应搜索行为以及不同搜索阶段的相互作用 孔雀;代表当前最优解的五只孔雀也会通过旋转跳动机制在附近的搜索空间中搜索而不是静止不动。孔雀独特的旋转跳舞机制包含两种不同的旋转模式即原位旋转和围绕食物源盘旋。首先采用当前最优解仍会进行就近搜索的机制这在以前的算法中从未考虑过有利于跳出局部最优;孔雀幼崽和孔雀幼崽在整个搜索过程中都倾向于采用适应性搜索和接近机制动态调整其不同阶段的行为从而实现局部开发与全球探索之间的适当平衡。
2 运行结果
部分代码
% Peafowl Optimization Algorithm (POA) function [BestSolution, ConvergenceCurve, Dim]POA(NumAgents, MaxIterations, BenchmarkFunFlag) % --------------------------Return Parameters-------------------------- % BestSolution: The best solution % ConvergenceCurve: Convergence curve % Dim: The dimensionality of prloblem % --------------------------Input Parameters--------------------------- % NumAgents: The number of search individuals % MaxIterations: The number of maximum iterations % BenchmarkFunFlag: Objective function (1-23) % --------------------------------------------------------------------- ConvergenceCurvezeros(1,MaxIterations); NumPeacock5; % the number of leader (Peacock) NumPeahenround((NumAgents-NumPeacock)*0.3); % the number of peahen NumPeacockCubNumAgents-NumPeacock-NumPeahen; % the number of peacock cub [LowerBound, UpperBound, Dim]BenchmarkFunctionRange(BenchmarkFunFlag); LowerBoundLowerBound*ones(1,Dim); UpperBoundUpperBound*ones(1,Dim); SearchRadius0(UpperBound-LowerBound)*0.2; % initial dance radius of peacock % initialization empty_peacock.Position[]; empty_peacock.Fitness[]; PeacockPopulation0repmat(empty_peacock,[NumAgents,1]); Peahenrepmat(empty_peacock,[NumPeahen,1]); PeacockCubrepmat(empty_peacock,[NumPeacockCub,1]); for k1:NumAgents PeacockPopulation0(k).PositionLowerBound(UpperBound-LowerBound).*rand(1,Dim); PeacockPopulation0(k).FitnessBenchmarkFunction(PeacockPopulation0(k).Position, BenchmarkFunFlag, Dim); end PeacockPopulationPeacockPopulation0; [~,index]sort([PeacockPopulation.Fitness]); PeacockPopulationPeacockPopulation(index); ConvergenceCurve(1)PeacockPopulation(1).Fitness; % main loop for it2:MaxIterations SearchRadiusSearchRadius0-(SearchRadius0-0)*(it/MaxIterations)^0.01; alpha0.9-(0.9-0.4)*(it/MaxIterations)^2; delta0.1(1-0.1)*(it/MaxIterations)^0.5; step0.1(1-0.1)*(it/MaxIterations); PeacockPeacockPopulation(1:NumPeacock); if rand1 X_random2*rand(1,Dim)-1; Peacock(1).PositionPeacock(1).Position1*SearchRadius.*X_random/(epsnorm(X_random)); end if rand0.9 X_random2*rand(1,Dim)-1; Peacock(2).PositionPeacock(2).Position1.5*SearchRadius.*X_random/(epsnorm(X_random)); end if rand0.8 X_random2*rand(1,Dim)-1; Peacock(3).PositionPeacock(3).Position2*SearchRadius.*X_random/(epsnorm(X_random)); end if rand0.6 X_random2*rand(1,Dim)-1; Peacock(4).PositionPeacock(4).Position3*SearchRadius.*X_random/(epsnorm(X_random)); end if rand0.3 X_random2*rand(1,Dim)-1; Peacock(5).PositionPeacock(5).Position5*SearchRadius.*X_random/(epsnorm(X_random)); end for k1:NumPeacock flag4ubPeacock(k).PositionUpperBound; flag4lbPeacock(k).PositionLowerBound; Peacock(k).Position~(flag4ubflag4lb).*Peacock(k).Positionflag4ub.*UpperBoundflag4lb.*LowerBound; Peacock(k).FitnessBenchmarkFunction(Peacock(k).Position, BenchmarkFunFlag, Dim); if Peacock(k).Fitness PeacockPopulation(k).Fitness PeacockPopulation(k)Peacock(k); end end for k1:NumPeahen r1rand(); if r1 1 r1 0.6 Peahen(k).PositionPeacockPopulation(NumPeacockk).Position3*step*(PeacockPopulation(1).Position-PeacockPopulation(NumPeacockk).Position); end if r1 0.6 r1 0.4 Peahen(k).PositionPeacockPopulation(NumPeacockk).Position3*step*(PeacockPopulation(2).Position-PeacockPopulation(NumPeacockk).Position); end if r1 0.4 r1 0.2 Peahen(k).PositionPeacockPopulation(NumPeacockk).Position3*step*(PeacockPopulation(3).Position-PeacockPopulation(NumPeacockk).Position); end if r1 0.2 r1 0.1 Peahen(k).PositionPeacockPopulation(NumPeacockk).Position3*step*(PeacockPopulation(4).Position-PeacockPopulation(NumPeacockk).Position); end if r1 0.1 r1 0 Peahen(k).PositionPeacockPopulation(NumPeacockk).Position3*step*(PeacockPopulation(5).Position-PeacockPopulation(NumPeacockk).Position); end flag4ubPeahen(k).PositionUpperBound; flag4lbPeahen(k).PositionLowerBound; Peahen(k).Position~(flag4ubflag4lb).*Peahen(k).Positionflag4ub.*UpperBoundflag4lb.*LowerBound; Peahen(k).FitnessBenchmarkFunction(Peahen(k).Position, BenchmarkFunFlag, Dim); if Peahen(k).Fitness PeacockPopulation(NumPeacockk).Fitness PeacockPopulation(NumPeacockk)Peahen(k); end end for k1:NumPeacockCub PeacockCub(k)PeacockPopulation(NumPeacockNumPeahenk); r2rand; if r20.8 r21 SelectedPeacockPeacockPopulation(1); elseif r20.6 r20.8 SelectedPeacockPeacockPopulation(2); elseif r20.4 r20.6 SelectedPeacockPeacockPopulation(3); elseif r20.2 r20.4 SelectedPeacockPeacockPopulation(4); else SelectedPeacockPeacockPopulation(5); end PeacockCub(k).PositionPeacockCub(k).Positionalpha*Levy(Dim).*( PeacockPopulation(1).Position - PeacockCub(k).Position )delta*( SelectedPeacock.Position - PeacockCub(k).Position ); flag4ubPeacockCub(k).PositionUpperBound; flag4lbPeacockCub(k).PositionLowerBound; PeacockCub(k).Position~(flag4ubflag4lb).*PeacockCub(k,:).Positionflag4ub.*UpperBoundflag4lb.*LowerBound; PeacockCub(k).FitnessBenchmarkFunction(PeacockCub(k).Position, BenchmarkFunFlag, Dim); if PeacockCub(k).Fitness PeacockPopulation(NumPeacockNumPeahenk).Fitness PeacockPopulation(NumPeacockNumPeahenk)PeacockCub(k,:); end end PeacockPeacockPopulation(1:NumPeacock); Xrandom2*rand(1,Dim)-1; Direction1Peacock(1,:).Position-Peacock(2,:).Position; Direction2Xrandom-(Xrandom*Direction1)/(Direction1*Direction1eps)*Direction1; Direction2Direction2/norm(Direction2eps)*norm(Direction1); Peacock(2,:).PositionPeacock(2,:).Positionstep*Direction1rand*Direction2; Xrandom2*rand(1,Dim)-1; Direction1Peacock(1,:).Position-Peacock(3,:).Position; Direction2Xrandom-(Xrandom*Direction1)/(Direction1*Direction1eps)*Direction1; Direction2Direction2/norm(Direction2eps)*norm(Direction1); Peacock(3,:).PositionPeacock(3,:).Positionstep*Direction1rand*Direction2; Xrandom2*rand(1,Dim)-1; Direction1Peacock(1,:).Position-Peacock(4,:).Position; Direction2Xrandom-(Xrandom*Direction1)/(Direction1*Direction1eps)*Direction1; Direction2Direction2/norm(Direction2eps)*norm(Direction1); Peacock(4,:).PositionPeacock(4,:).Positionstep*Direction1rand*Direction2; Xrandom2*rand(1,Dim)-1; Direction1Peacock(1,:).Position-Peacock(5,:).Position; Direction2Xrandom-(Xrandom*Direction1)/(Direction1*Direction1eps)*Direction1; Direction2Direction2/norm(Direction2eps)*norm(Direction1); Peacock(5,:).PositionPeacock(5,:).Positionstep*Direction1rand*Direction2; for k1:NumPeacock flag4ubPeacock(k).PositionUpperBound; flag4lbPeacock(k).PositionLowerBound; Peacock(k).Position~(flag4ubflag4lb).*Peacock(k).Positionflag4ub.*UpperBoundflag4lb.*LowerBound; Peacock(k).FitnessBenchmarkFunction(Peacock(k).Position, BenchmarkFunFlag, Dim); if Peacock(k).Fitness PeacockPopulation(k).Fitness PeacockPopulation(k)Peacock(k); end end [~,index]sort([PeacockPopulation.Fitness]); PeacockPopulationPeacockPopulation(index); ConvergenceCurve(1,it)PeacockPopulation(1).Fitness; end BestSolutionPeacockPopulation(1); end
3 参考文献 部分理论来源于网络如有侵权请联系删除。 [1] Jingbo Wang, Bo Yang, Yijun Chen, Kaidi Zeng, Hao Zhang, Hongchun Shu, Yingtong Chen, Novel phasianidae inspired peafowl (Pavo muticus/cristatus) optimization algorithm: Design, evaluation, and SOFC models parameter estimation, Sustainable Energy Technologies and Assessments https://doi.org/10.1016/j.seta.2021.101825
4 Matlab代码及详细文章