2025最新智能优化算法:鲸鱼迁徙算法(Whale Migration Algorithm,WMA)求解23个经典函数测试集,MATLAB

一、鲸鱼迁徙算法

鲸鱼迁徙算法(Whale Migration Algorithm,WMA)是2025年提出的一种新颖生物启发式元启发式优化方法,其灵感来源于座头鲸的协作迁徙行为。该算法通过模拟座头鲸的迁徙和捕食行为,实现了在优化过程中的高效搜索和优化能力。WMA通过整合领导者-追随者动态和自适应迁徙策略,平衡了探索和开发之间的关系,从而提高了算法避免局部最优和有效收敛的能力。WMA通过模拟座头鲸的迁徙行为,实现了在搜索空间中的有效探索和开发。这种平衡使得算法能够在避免陷入局部最优的同时,快速收敛到全局最优解。WMA的自适应迁徙策略使其能够根据问题的复杂性和搜索空间的特性动态调整搜索策略,从而在不同的优化问题中表现出良好的适应性。



参考文献:

1Ghasemi, M., Deriche, M., Trojovský, P., Mansor, Z., Zare, M., Trojovská, E., Abualigah, L.M., Ezugwu, A.E., & Mohammadi, S.K. (2025). An efficient bio-inspired algorithm based on humpback whale migration for constrained engineering optimization. Results in Engineering.

二、23个函数介绍

参考文献:

1 Yao X, Liu Y, Lin G M. Evolutionary programming made fasterJ. IEEE transactions on evolutionary computation, 1999, 3(2):82-102.

三、部分代码及结果

dart 复制代码
clear;
clc;
close all;
warning off all;

SearchAgents_no=50;    %Number of search solutions
Max_iteration=500;    %Maximum number of iterations

Func_name='F1'; % Name of the test function

% Load details of the selected benchmark function
[lb,ub,dim,fobj]=Get_F(Func_name); 

tic;
[Best_score,Best_pos,cg_curve]=SGA(SearchAgents_no,Max_iteration,lb,ub,dim,fobj); 
tend=toc;

% figure('Position',[500 500 901 345])
%Draw search space
subplot(1,2,1);
func_plot(Func_name);
title('Parameter space')
xlabel('x_1');
ylabel('x_2');
zlabel([Func_name,'( x_1 , x_2 )'])

%Draw objective space
subplot(1,2,2);
semilogy(cg_curve,'Color','m',LineWidth=2.5)
title(Func_name)

% title('Objective space')
xlabel('Iteration');
ylabel('Best score obtained so far');

axis tight
grid on
box on
legend('SGA')

display(['The running time is:', num2str(tend)]);
display(['The best fitness is:', num2str(Best_score)]);
display(['The best position is: ', num2str(Best_pos)]);




四、完整MATLAB代码见下方名片

相关推荐
敲代码的嘎仔几秒前
实习日志day6--实习日志day6--title命名规范化&businessType纠正&补充缺失的@Log注解&报警与通信模块补充&产出阶段总结文档
java·开发语言·人工智能·git·python·实习·大二
ZZZMMM.zip2 分钟前
基于鸿蒙HarmonyOS NEXT开发AI英语口语应用:智能口语练习新体验与鸿蒙Flutter框架跨端实
人工智能·flutter·华为·harmonyos·鸿蒙·鸿蒙系统
程序喵大人3 分钟前
【AI专栏】图解Transformer - 第05章:LLM 推理工程
人工智能·深度学习·llm·transformer
甲维斯6 分钟前
差距太大了!GPT5.6Sol 正面战 Fable5,啥也不是!
人工智能·ai编程
杜子不疼.19 分钟前
【Qt初识】信号槽(三):机制意义、断开连接与 Lambda 表达式
开发语言·数据库·qt
Eloudy29 分钟前
LLM 公司提供的 token api 服务输出内容的特点
人工智能
DeepAgent37 分钟前
AI Agent 工程实践(03):Memory 设计——Agent 到底应该记住什么?
人工智能
懂懂笔记1 小时前
老龄化加速下的中国答案:东软用AI思维重构“人生下半场”
人工智能·智慧养老
GitCode官方1 小时前
基于《人工智能 智能体互联》国标的 AIP 开源项目在 AtomGit 正式开源
人工智能·开源·atomgit
万象AI实验室1 小时前
GPT-5.6 正式上线,我们挖到了 3 个隐藏玩法!
人工智能