-
摘要:
为改善麻雀搜索算法(SSA)初始种群质量和稳定性差,易陷入局部最优的缺点,提出一种基于佳点集的改进麻雀搜索算法(GSSA)。加入佳点集使初始种群更加均匀,提升了种群多样性;结合SSA算法特点引入改进的迭代局部搜索,在不降低原算法收敛速度快的基础上,使算法的搜索能力更加灵活;在算法中加入逐维透镜成像反向学习机制,减少各个维度间的干扰,帮助算法跳出局部最优并加速收敛。经12个测试函数仿真实验,并借助Wilcoxon秩和检验、平均误差
M 等证明了GSSA在寻优精度和稳定性等寻优性能都有较大的提升,且收敛速度更快。Abstract:An enhanced sparrow search algorithm based on a good point set (GSSA) is developed to address the sparrow search algorithm (SSA) weak starting population quality, instability, and susceptibility to local optimization. Firstly, adding a good point set makes the initial population more uniform and improves the population diversity. Second, while retaining the benefits of the original algorithm’s quick convergence speed, an enhanced iterative local search is merged with the features of the SSA algorithm to increase the search capabilities of the latter. Finally, a dimension by dimension lens imaging reverse learning mechanism is added to the algorithm to reduce the interference between various dimensions, help the algorithm jump out of local optimization and accelerate convergence. Through 12 test function simulation experiments, with the help of the Wilcoxon rank sum test and mean error
M , it is proved that GSSA has greatly improved the optimization performance such as optimization accuracy and stability, and the convergence speed is faster. -
表 1 参数设置
Table 1. Parameter settings
算法 a b n S PD DS k GWO 2→0 WOA 1 MWOA 12000 SSA 0.8 0.2 0.2 CSSA 0.8 0.2 0.2 GSSA 0.8 0.2 0.2 12000 表 2 测试函数
Table 2. Test function
函数 维度 搜索区域 理论值 ${F_1}\left( x \right) =\displaystyle\sum \limits_{i = 1}^n x_i^2$ 30 [−100,100] 0 ${F_2}\left( x \right) = \displaystyle\sum \limits_{i = 1}^n \left| { {x_i} } \right| + \displaystyle\prod \limits_{i = 1}^n \left| { {x_i} } \right|$ 30 [−100,100] 0 ${F_3}\left( x \right) = {\max _i}\left\{ {\left| {{x_i}} \right|,1 \leqslant i \leqslant n} \right\}$ 30 [−100,100] 0 ${F_4}\left( x \right) = \displaystyle\sum \limits_{i = 1}^{n - 1} \left[ {100{ {({x_{i + 1} } - x_i^2)}^2} + { {({x_i} - 1)}^2} } \right]$ 30 [−30,30] 0 ${F_5}\left( x \right) = \displaystyle\sum \limits_{i = 1}^n {\left( {\left[ { {x_i} + 0.5} \right]} \right)^2}$ 30 [−100,100] 0 ${F_6}\left( x \right) = \displaystyle\sum \limits_{i = 1}^n - {x_i}\sin \left( {\sqrt {\left| { {x_i} } \right|} } \right)$ 30 [−500,500] −12569.4 ${F_7}\left( x \right) = \dfrac{1}{ {4\;000} }\displaystyle\sum \limits_{i = 1}^n x_i^2 - \displaystyle\prod \limits_{i = 1}^n \cos \left( {\frac{ { {x_i} } }{ {\sqrt i } } } \right) + 1$ 30 [−600,600] 0 $\begin{array}{l} {F_8}\left( x \right) = \dfrac{ {\text{π} } }{n}\Biggr\{ {10{\text{sin} }\left( { {\text{π} }{y_1} } \right) + \displaystyle\sum \limits_{i = 1}^{n - 1} { {\left( { {y_i} - 1} \right)}^2} } \;\cdot \\ \qquad{\left[ {1 + 10{\text{si} }{ {\text{n} }^2}\left( { {\text{π} }{y_{i + 1} } } \right)} \right] + } \\ \qquad{ { {\left( { {y_n} - 1} \right)}^2} } \Biggr\} + \displaystyle\sum \limits_{i = 1}^n u\left( { {x_i},10,100,4} \right) \\ \qquad{y_i} = 1 + \dfrac{ { {x_i} + 1} }{4} \\\end{array}$ 30 [−50,50] 0 $\begin{gathered} {F_9}\left( x \right) = 0.1\Biggr\{ { {\sin }^2}\left( {3{\text{π} }{x_1} } \right) + \displaystyle\sum \limits_{i = 1}^n { {\left( { {x_i} - 1} \right)}^2} \;\cdot \\ \qquad{\left[ {1 + { {\sin }^2}\left( {3{\text{π} }{x_i} + 1} \right)} \right] + } \\ \qquad { {\text{ } }{ {\left( { {x_n} - 1} \right)}^2}\left[ {1 + { {\sin }^2}\left( {2{\text{π} }{x_n} } \right)} \right]} \Biggr\} + \\ \qquad \displaystyle\sum \limits_{i = 1}^n u\left( { {x_i},5,100,4} \right) \\ \end{gathered}$ 30 [−50,50] 0 ${F_{10} }\left( x \right) = {\left( {\dfrac{1}{ {500} } + \displaystyle\sum \limits_{j = 1}^{25} {1}\Bigg/\Bigg({ {j + \displaystyle\sum \limits_{i = 1}^2 { {\left( { {x_i} - {a_{ij} } } \right)}^6} } }\Bigg) } \right)^{-1 } }$ 2 [−65.536,
65.536]0.998 ${F_{11} }\left( x \right) = \displaystyle\sum \limits_{i = 1}^{11} {\left( { {a_i} - \frac{ { {x_1}\left( {b_i^2 + {b_1}{x_2} } \right)} }{ {b_i^2 + {b_1}{x_3} + {x_4} } } } \right)^2}$ 4 [−5,5] 0.0003 ${F_{12} }\left( x \right) = \displaystyle\sum \limits_{i = 1}^{10} {\left[ {\left( {{\boldsymbol{X}} - {a_i} } \right){ {\left( {{\boldsymbol{X}} - {a_i} } \right)}^{\rm{T} } } + {c_i} } \right]^{ - 1} }$ 4 [0,10] −10.5364 表 3 测试函数结果对比
Table 3. Comparison of test function results
函数 算法 最优值 最差值 均值 标准差 排名 函数 算法 最优值 最差值 均值 标准差 排名 F1 GWO 1.75×10−27 2.34×10−25 3.31×10−26 5.42×10−26 6 F7 GWO 0 3.17×10−2 4.59×10−3 9.70×10−3 4 WOA 2.18×10−87 5.74×10−73 2.62×10−74 1.05×10−73 3 WOA 0 1.48×10−1 4.93×10−3 2.70×10−2 5 MWOA 3.13×10−83 3.65×10−71 1.33×10−72 6.66×10−72 4 MWOA 0 1.64×10−1 5.48×10−3 3.00×10−2 6 SSA 0 5.91×10−63 1.97×10−64 1.08×10−63 5 SSA 0 0 0 0 1 CSSA 0 0 0 0 1 CSSA 0 0 0 0 1 GSSA 0 0 0 0 1 GSSA 0 0 0 0 1 F2 GWO 1.33×10−16 2.07×10−15 7.21×10−16 4.63×10−16 6 F8 GWO 5.13×10−7 1.14×10−1 3.90×10−2 2.17×10−2 6 WOA 2.65×10−57 2.69×10−49 9.79×10−51 4.90×10−50 3 WOA 3.55×10−3 9.25×10−2 2.40×10−2 1.86×10−2 5 MWOA 1.06×10−56 1.57×10−48 9.36×10−50 3.45×10−49 4 MWOA 6.06×10−3 6.53×10−2 2.25×10−2 1.45×10−2 4 SSA 0 9.86×10−37 5.16×10−38 1.91×10−37 5 SSA 1.57×10−32 4.18×10−8 2.15×10−9 8.19×10−9 3 CSSA 0 3.51×10−287 1.17×10−288 0 2 CSSA 3.01×10−14 3.32×10−9 2.70×10−10 6.03×10−10 2 GSSA 0 0 0 0 1 GSSA 1.57×10−32 1.04×10−14 3.92×10−16 1.90×10−15 1 F3 GWO 5.77×10−8 3.64×10−6 7.30×10−7 8.46×10−7 4 F9 GWO 1.01×10−1 9.71×10−1 5.42×10−1 1.99×10−1 5 WOA 4.37 90.3 47.4 26.1 6 WOA 1.26×10−1 1.11 5.50×10−1 2.96×10−1 6 MWOA 1.63 85.0 43.4 25.0 5 MWOA 8.24×10−2 9.67×10−1 5.37×10−1 2.11×10−1 4 SSA 0 8.18×10−28 2.73×10−29 1.49×10−28 3 SSA 1.35×10−32 1.89×10−7 1.42×10−8 3.90×10−8 3 CSSA 0 1.10×10−297 4.27×10−299 0 2 CSSA 1.62×10−11 5.14×10−8 3.14×10−9 9.25×10−9 2 GSSA 0 0 0 0 1 GSSA 1.35×10−32 1.23×10−14 6.19×10−16 2.29×10−15 1 F4 GWO 26.1 28.5 27.2 7.68×10−1 4 F10 GWO 9.98×10−1 12.7 3.62 3.36 5 WOA 27.2 28.8 28.3 4.77×10−1 6 WOA 9.98×10−1 10.8 3.22 3.52 3 MWOA 27.0 28.8 28.0 5.22×10−1 5 MWOA 9.98×10−1 10.81 3.61 3.81 4 SSA 0 1.37×10−4 9.74×10−6 2.75×10−5 2 SSA 9.98×10−1 12.7 9.53 4.83 6 CSSA 8.00×10−9 4.20×10−4 4.53×10−5 1.07×10−4 3 CSSA 9.98×10−1 2.98 1.26 6.86×10−1 2 GSSA 0 8.16×10−16 2.72×10−17 1.49×10−16 1 GSSA 9.98×10−1 9.98×10−1 9.98×10−1 1.21×10−14 1 F5 GWO 2.34×10−1 1.67 7.61×10−1 4.05×10−1 6 F11 GWO 3.08×10−4 2.04×10−2 1.77×10−3 5.06×10−3 6 WOA 9.41×10−2 1.18 3.99×10−1 2.27×10−1 4 WOA 3.29×10−4 2.24×10−3 6.62×10−4 4.24×10−4 4 MWOA 5.41×10−2 8.77×10−1 4.07×10−1 2.21×10−1 5 MWOA 3.07×10−4 2.25×10−3 6.73×10−4 4.85×10−4 5 SSA 0 1.85×10−7 2.61×10−8 4.61×10−8 3 SSA 3.07×10−4 3.30×10−4 3.08×10−4 4.14×10−6 2 CSSA 5.28×10−12 6.86×10−8 6.71×10−9 1.45×10−8 2 CSSA 3.07×10−4 1.22×10−3 3.42×10−4 1.68×10−4 3 GSSA 0 3.57×10−16 1.37×10−17 6.55×10−17 1 GSSA 3.08×10−4 3.08×10−4 3.08×10−4 2.68×10−15 1 F6 GWO −7.20×103 −2.66×103 −5.94×103 −1.19×103 6 F12 GWO −10.5 −5.13 −10.4 9.87×10−1 3 WOA −1.26×104 −6.67×103 −1.01×104 −1.92×103 4 WOA −10.5 −1.68 −7.03 3.45 6 MWOA −1.26×104 −8.51×103 −1.09×104 −1.57×103 2 MWOA −10.5 −1.86 −7.15 3.25 5 SSA −1.26×104 −6.50×103 −9.28×103 −2.06×103 5 SSA −10.5 −5.13 −9.99 1.65 4 CSSA −1.26×104 −8.66×103 −1.10×104 −1.11×103 1 CSSA −10.5 −10.5 −10.5 1.44×10−15 1 GSSA −1.16×10+04 −8.64×10+03 −1.06×104 −5.11×102 3 GSSA −10.5 −10.5 −10.5 1.95×10−5 2 表 4 测试函数Wilcoxon秩和检验的p值
Table 4. p-value of Wilcoxon rank sum test of test function
函数 GWO WOA MWOA SSA CSSA F1 1.21×10−12 1.21×10−12 1.21×10−12 6.25×10−10 Na F2 1.21×10−12 1.21×10−12 1.21×10−12 4.57×10−12 8.87×10−7 F3 1.21×10−12 1.21×10−12 1.21×10−12 4.57×10−12 1.37×10−3 F4 3.00×10−11 3.00×10−11 3.00×10−11 5.87×10−07 3.00×10−11 F5 3.01×10−11 3.01×10−11 3.01×10−11 4.81×10−10 3.01×10−11 F6 2.75×10−11 2.51×10−1 6.30×10−2 1.11×10−2 4.47×10−2 F7 1.10×10−2 1.61×10−1 3.34×10−1 Na Na F8 3.02×10−11 3.02×10−11 3.02×10−11 2.36×10−4 3.02×10−11 F9 3.02×10−11 3.02×10−11 3.02×10−11 8.14×10−7 3.02×10−11 F10 8.54×10−11 1.79×10−11 1.79×10−11 1.59×10−9 2.13×10−1 F11 8.48×10−9 3.02×10−11 5.57×10−10 8.48×10−9 8.48×10−9 F12 7.13×10−8 2.69×10−11 2.69×10−11 3.47×10−1 1.10×10−11 表 5 各算法M排名
Table 5. Algorithm M ranking
算法 M 排名 GWO 555.28 6 WOA 210.07 5 MWOA 143.85 3 SSA 174.49 4 CSSA 129.61 2 GSSA 68.02 1 -
[1] XUE J K, SHEN B. A novel swarm intelligence optimization approach: sparrow search algorithm[J]. Systems Science & Control Engineering, 2020, 8(1): 22-34. [2] 李雅丽, 王淑琴, 陈倩茹, 等. 若干新型群智能优化算法的对比研究[J]. 计算机工程与应用, 2020, 56(22): 1-12.LI Y L, WANG S Q, CHEN Q R, et al. Comparative study of several new swarm intelligence optimization algorithms[J]. Computer Engineering and Applications, 2020, 56(22): 1-12(in Chinese). [3] 吕鑫, 慕晓冬, 张钧. 基于改进麻雀搜索算法的多阈值图像分割[J]. 系统工程与电子技术, 2021, 43(2): 318-327.LYU X, MU X D, ZHANG J. Multi-threshold image segmentation based on improved sparrow search algorithm[J]. Systems Engineering and Electronics, 2021, 43(2): 318-327(in Chinese). [4] 吕鑫, 慕晓冬, 张钧, 等. 混沌麻雀搜索优化算法[J]. 北京航空航天大学学报, 2021, 47(8): 1712-1720.LYU X, MU X D, ZHANG J, et al. Chaos sparrow search optimization algorithm[J]. Journal of Beijing University of Aeronautics and Astronautics, 2021, 47(8): 1712-1720(in Chinese). [5] 汤安迪, 韩统, 徐登武, 等. 基于混沌麻雀搜索算法的无人机航迹规划方法[J]. 计算机应用, 2021, 41(7): 2128-2136.TANG A D, HAN T, XU D W, et al. Path planning method of unmanned aerial vehicle based on chaos sparrow search algorithm[J]. Journal of Computer Applications, 2021, 41(7): 2128-2136(in Chinese). [6] 陈义雄, 梁昔明, 黄亚飞. 基于佳点集构造的改进量子粒子群优化算法[J]. 中南大学学报(自然科学版), 2013, 44(4): 1409-1414.CHEN Y X, LIANG X M, HUANG Y F. Improved quantum particle swarm optimization based on good-point set[J]. Journal of Central South University (Science and Technology), 2013, 44(4): 1409-1414(in Chinese). [7] 张达敏, 徐航, 王依柔, 等. 嵌入Circle映射和逐维小孔成像反向学习的鲸鱼优化算法[J]. 控制与决策, 2021, 36(5): 1173-1180.ZHANG D M, XU H, WANG Y R, et al. Whale optimization algorithm for embedded Circle mapping and onedimensional oppositional learning based small hole imaging[J]. Control and Decision, 2021, 36(5): 1173-1180(in Chinese). [8] 华罗庚, 王元. 数论在近代分析中的应用[M]. 北京: 科学出版社, 1978: 1-99.HUA L G, WANG Y. Application of number theory in modern analysis [M]. Beijing: Science Press, 1978: 1-99(in Chinese). [9] GAN C, CAO W H, WU M, et al. A new bat algorithm based on iterative local search and stochastic inertia weight[J]. Expert Systems with Applications, 2018, 104: 202-212. doi: 10.1016/j.eswa.2018.03.015 [10] YANG X S. A new metaheuristic bat-inspired algorithm[C]//Nature Inspired Cooperative Strategies for Optimization (NICSO 2010). Berlin: Springer, 2010: 65-74. [11] MOLINA D, LATORRE A, HERRERA F. SHADE with iterative local search for large-scale global optimization[C]// 2018 IEEE Congress on Evolutionary Computation (CEC). Piscataway: IEEE Press, 2018: 1-8. [12] XIA X W, LIU J N, LI Y X. Particle swarm optimization algorithm with reverse-learning and local-learning behavior[J]. Journal of Software, 2014, 9(2): 350-357. [13] 何杰光, 彭志平, 崔得龙, 等. 一种多反向学习的教与学优化算法[J]. 工程科学与技术, 2019, 51(6): 159-167.HE J G, PENG Z P, CUI D L, et al. Multi-opposition teaching-learning-based optimization[J]. Advanced Engineering Sciences, 2019, 51(6): 159-167(in Chinese). [14] RAHNAMAYAN S, TIZHOOSH H R, SALAMA M M A. Opposition-based differential evolution[J]. IEEE Transactions on Evolutionary Computation, 2008, 12(1): 64-79. doi: 10.1109/TEVC.2007.894200 [15] 龙文, 伍铁斌, 唐明珠, 等. 基于透镜成像学习策略的灰狼优化算法[J]. 自动化学报, 2020, 46(10): 2148-2164.LONG W, WU T B, TANG M Z, et al. Grey wolf optimizer algorithm based on lens imaging learning strategy[J]. Acta Automatica Sinica, 2020, 46(10): 2148-2164(in Chinese). [16] OUYANG C T, ZHU D L, QIU Y X. Lens learning sparrow search algorithm[J]. Mathematical Problems in Engineering, 2021, 2021: 1-17.