一、鳑鲏魚優化算法
鳑鲏魚優化算法(Bitterling Fish Optimization,BFO)由Lida Zareian 等人于2024年提出。鳑鲏魚在交配中,雄性和雌性物種相互接近,然后將精子和卵子釋放到水中,但這種方法有一個很大的缺點。幼魚暴露在各種外部危害中,很容易成為其他動物的獵物。換句話說,這些卵中只有少數會變成魚——不幸的是,大多數魚都是被其他水生動物獵殺的。苦魚有不同的繁殖機制。這種魚從牡蠣開始。尋找合適的產卵殼的任務是雄性物種的責任。他們需要找到更大的牡蠣,并有更多的空間來容納它們的卵。當這些魚找到一個或多個受害者(牡蠣)時,它們就會與敵人對抗。雄性物種具有攻擊性行為的原因是其他一些雄性物種也傾向于將牡蠣用于自己。在戰斗模式中,雄魚的體色變暗,并盡其所能保衛自己的領地。在交配階段,會發生一種稱為性選擇的現象。在性選擇過程中,雌性物種根據顏色和體力選擇雄性魚。
該算法通過創建初始種群、更新參數、評估解決方案、搜索和捕獲牡蠣、從其他魚類中逃脫、走向魚類積累、魚類生產、繁殖和不需要的魚類滅絕,實現優化。
參考文獻:
[1] Zareian, L., Rahebi, J. & Shayegan, M.J. Bitterling fish optimization (BFO) algorithm. Multimed Tools Appl (2024). https://doi.org/10.1007/s11042-024-18579-0.
二、23個函數介紹
參考文獻:
[1] Yao X, Liu Y, Lin G M. Evolutionary programming made faster[J]. IEEE transactions on evolutionary computation, 1999, 3(2):82-102.
三、BFO求解23個函數
3.1部分代碼
close all ; clear clc Npop=30;? ? ? ? ? ? ? ?? Function_name='F1';? ? ?% Name of the test function that can be from F1 to F23 (? Tmax=300;? ? ? ? ? ? ?? [lb,ub,dim,fobj]=Get_Functions_details(Function_name); [Best_fit,Best_pos,Convergence_curve]=BFO(Npop,Tmax,lb,ub,dim,fobj); figure('Position',[100 100 660 290]) %Draw search space subplot(1,2,1); func_plot(Function_name); title('Parameter space') xlabel('x_1'); ylabel('x_2'); zlabel([Function_name,'( x_1 , x_2 )']) %Draw objective space subplot(1,2,2); semilogy(Convergence_curve,'Color','r','linewidth',3) title('Search space') xlabel('Iteration'); ylabel('Best score obtained so far'); axis tight grid on box on legend('BFO') saveas(gca,[Function_name '.jpg']);display(['The best solution is ', num2str(Best_pos)]); display(['The best fitness value is ', num2str(Best_fit)]);
3.2部分結果
四、完整MATLAB代碼
文件夾夾內包含該算法求解23個函數的完整MATLAB代碼,點擊main.m即可運行。