﻿ 基于量子粒子群算法的船舶机舱布局方法
 舰船科学技术  2022, Vol. 44 Issue (18): 51-56    DOI: 10.3404/j.issn.1672-7649.2022.18.011 PDF

1. 海军工程大学 舰船与海洋学院，湖北 武汉 430033;
2. 中国人民解放军92942部队，北京 100161

A method of ship engine room layout based on quantum particle swarm algorithm
CUI Ao1,2, HUANG Jin-e2, HUANG Xiang-bing1, JIANG Jie2, MIN Shao-song1
1. Academy of Naval Architecture and Ocean, Naval University of Engineering, Wuhan 430033, China;
2. No. 92942 Unit of PLA, Beijing 100161, China
Abstract: In the process of using intelligent algorithm for ship cabin layout, the main research direction focuses on the improvement of existing intelligent algorithm, but ignores the problem of generating initial solution. Referring to the way of dividing layout space in three-dimensional packing problem, this paper proposed a method for generating initial solution of ship cabin layout in two-dimensional space. Genetic algorithm (GA), particle swarm optimization algorithm (PSO) and quantum particle swarm optimization algorithm (QPSO) were used to arrange the cabin equipment. Compared with the results referred to other research conclusions, the results showed that the advantages and disadvantages of the intelligent algorithm are different when using different initial solution generation methods to solve the layout problem. Compared with genetic algorithm and particle swarm optimization algorithm, quantum particle swarm optimization algorithm had stronger applicability. The research results could provide a reference for the layout and design of ship cabins.
Key words: engine room layout     heuristic algorithm     quantum particle swarm optimization algorithm     ship cabin
0 引　言

1 问题描述与模型建立 1.1 问题描述与模型的简化

1）在舱室布置时，主要考虑对舱室布局有较大影响的设施，管路、电缆以及壁挂式部件不做考虑。

2）将具有复杂形状的设备简化为规则的长方体。

3）通过垂直投影将三维布局问题简化为以舱室甲板为平面的二维布局问题。

4）舱室内部一些大型设备在设计初期已经固定，如柴油机等。

5）舱室入口和可拆板以及吊装通道的位置已经确定。

6）对不同设备、维修和操作位置可能会有所不同，但是每个设备的维修和操作位置相对为设备本身而言是固定的。

7）设备的摆放朝向问题仅考虑设备的长边与船舶长度方向平行和垂直的2种情况，即αi={0,1}。

1.2 数学模型的建立

 $\left\{\begin{array}{l}\mathrm{min}F(x)=({f}_{1}(x),{f}_{2}(x),\cdots \text{，}{f}_{m}(x))\;，\\ {\rm{s.t.}}\left\{\begin{array}{l}{g}_{i}(x)\leqslant 0,i=1,2,\cdots ,p\;，\\ {h}_{j}(x)=0,j=1,2,\cdots ,q\;，\\ {L}_{b}\leqslant x\leqslant {U}_{b}\;。\end{array}\right.\end{array}\right.$ (1)

1.3 目标函数

1）不平衡力矩最小

 ${f_1}(x) = \dfrac{{\left| { \displaystyle \sum\nolimits_{{{i}} = 1}^{{n}} {{m_{{i}}} \times {y_{{i}}}} } \right|}}{{\left| { \displaystyle \sum\nolimits_{{{i}} = 1}^{{n}} {{m_{{i}}} \times {{h}} \times \sin ({\text{π}} /180)} } \right|}}\;。$ (2)

2）维修干涉最小

 $P_{i j}=\left\{\begin{array}{l} 1, d c_{i j} \leqslant D_{i, \min } \;，\\ \dfrac{D_{i, \min }-d c_{i j}}{D_{i, \max }-D_{i, \min }}, D_{i, \min } \leqslant d c_{i j} \leqslant D_{i, \max } \;，\\ 0, d c_{i j} \geqslant D_{i, \max }\;。\end{array}\right.$ (3)

 ${f_2}(x) = \sum\nolimits_{i = 1}^m {{f_i} \times {P_i}}\;。$ (4)

3）人员流通距离最小

 ${f_3}(x) = \dfrac{{ \displaystyle \sum\nolimits_{i = 1}^m { \displaystyle \sum\nolimits_{j = 1}^n {{L_{ij}}} } }}{{ \displaystyle \sum\nolimits_{{{i}} = 1}^{{m}} { \displaystyle \sum\nolimits_{{{j}} = 1}^{{n}} {{L_{\max }}} } }}\;。$ (5)

4）吊装距离最小

 ${f_4}(x) = \frac{{ \displaystyle \sum\nolimits_{k = 1}^k {{m_k} \times {T_k}} }}{{ \displaystyle \sum\nolimits_{{{k}} = 1}^{{k}} {{m_{{k}}} \times {T_{{{k}}\max }}} }} \;。$ (6)

1.4 约束条件

1）设备之间不干涉

 $\left\{ \begin{gathered} \left| {{x_i} - {x_j}} \right| > {l_i} + {l_j}/2 \;，\\ \left| {{y_i} - {y_j}} \right| > {h_i} + {h_j}/2 \;。\\ \end{gathered} \right.$ (7)

2）设备在舱室内

 $\left\{ \begin{gathered} {x_i} - ({l_i}/2) \times {\alpha _i} - ({h_i}/2) \times {\alpha _i} > 0 \;，\\ L - ({x_i} + {l_i}/2 \times {\alpha _i} + {h_i}/2 \times {\alpha _i}) > 0 \;，\\ {y_i} - ({l_i}/2) \times {\alpha _i} - ({h_i}/2) \times {\alpha _i} > 0 \;，\\ H - ({y_i} + {l_i}/2 \times {\alpha _i} + {h_i}/2) > 0 \;。\\ \end{gathered} \right.$ (8)

3）其他约束

 ${g_i}(x) = \{ g({A_i}):{A_i} \in X\} \;。$ (9)

 $Fit = \sum\nolimits_{i = 1}^n {{\omega _i} \times {f_i}(x)} {\text{ + }punish}\;。$ (10)

2 基于量子粒子群算法的布局优化 2.1 遗传算法和粒子群算法

2.2 量子粒子群算法

 $\left\{ \begin{array}{l}mbest = (1/M) \times {\displaystyle {\sum }_{i=1}^{M}{P}_{i}} =(1/M) \times \left( {\displaystyle {\sum }_{i=1}^{M}{P}_{i1}, \cdots ,{\displaystyle {\sum }_{i=1}^{M}{P}_{id}}} \right)\;，\\ P{P}_{ij}(t)=ran{d}_{1j}\times {p}_{ij}(t)+(1-randij)\times {p}_{gj}(t)\;，\\ {x}_{i}{}_{j}(t+1) = P{P}_{ij}(t) \pm \omega \times \left|mbes{t}_{j}(t)-{x}_{ij}(t)\right|\times \mathrm{ln}(1/ran{d}_{2j})\;。\end{array} \right.$ (11)

2.3 初始解的生成

 图 1 空间分割示意图 Fig. 1 Schematic diagram of space division

 图 2 依次选取设备进行布置并更新剩余空间编号 Fig. 2 Select the equipment in turn for layout and update the number of remaining space

 图 3 初始解生成流程图 Fig. 3 Flow chart of initial solution generation
2.4 计算步骤

3 实例分析与算法比较

 图 4 基于量子粒子群算法的机舱设备布局结果 Fig. 4 Layout results of cabin equipment based on quantum particle swarm optimization algorithm

 图 5 基于遗传算法的机舱设备布局结果 Fig. 5 Engine room equipment layout results based on genetic algorithm

 图 6 基于粒子群算法的机舱设备布局结果 Fig. 6 Layout results of cabin equipment based on particle swarm optimization algorithm

 图 7 不同算法的适应度变化 Fig. 7 Fitness changes of different algorithms

4 结　语

1）研究船舶舱室的布局问题时，并不能单纯得出某种智能算法更优的结论，需要将启发式算法与元启发式算法相结合，得到计算结果，进而讨论算法的优劣性。

2）对于机舱布局，在运用本文初始解生成方式的前提下，量子粒子群算法的计算结果优于遗传算法和粒子群算法。

 [1] 徐义春. 卫星舱布局问题的智能求解方法研究[D]. 武汉: 华中科技大学, 2008. [2] 宋婷婷. 二维一刀切装箱问题研究[D]. 哈尔滨: 哈尔滨理工大学, 2020. [3] 姜文英, 林焰, 陈明, 等. 基于粒子群和蚁群算法的船舶机舱规划方法[J]. 上海交通大学学报, 2014, 48(4): 502-507. JIANG Wen-ying, LIN Yan, CHEN Ming, et al. Ship cabin planning method based on particle group and ant colony algorithm[J]. Journal of Shanghai Jiaotong University, 2014, 48(4): 502-507. [4] 周发模. 粒子群算法及其在机舱布置优化的应用研究[D]. 武汉: 武汉理工大学, 2009. [5] LUO X, YANG Y, GE Z, et al. Maintainability-based facility layout optimum design of ship cabin[J]. International Journal of Production Research, 2014, 53(3): 677-694. [6] 赵士光. 消防船机舱优化布置的可视化研究[D]. 大连: 大连理工大学, 2014. [7] SUN J, XU W, FENG B. Adaptive parameter control for quantum-behaved particle swarm optimization on individual level[C] // IEEE International Conference on Systems, Man and Cybernetics. IEEE, 2006: 3049-3054. [8] 赵红超, 周洪庆, 王书湖. 无人机三维航迹规划的量子粒子群优化算法[J]. 航天控制, 2021, 39(1): 40-45. ZHAO Hong-chao, ZHOU Hong-qing, Wang Shu-hu. Quantum particle swarm optimization algorithm for UAV 3D track planning[J]. Aerospace Control, 2021, 39(1): 40-45. DOI:10.3969/j.issn.1006-3242.2021.01.007 [9] 徐方维, 谭洋洋, 杨洪耕, 等. 兼顾不同角色利益的集中型充电站优化布局[J]. 高电压技术, 2017, 43(4): 1256-1262. XU Fang-wei, TAN Yang-yang, YANG Hong-geng, et al. Optimal layout of centralized charging stations taking into account the interests of different roles[J]. High Voltage Technology, 2017, 43(4): 1256-1262. [10] 黄建江, 须文波, 孙俊, 等. 量子行为粒子群优化算法的布局问题研究[J]. 计算机应用, 2006(12): 3015-3018. Huang Jian-jiang, XU Wen-bo, Sun Jun, et al. Research on layout problem of quantum behavior particle swarm optimization algorithm[J]. Computer Applications, 2006(12): 3015-3018. [11] 罗云, 唐丽晴. 粒子群蚁群混合优化算法在船舶机舱布局优化上的应用[J]. 舰船电子工程, 2019, 39(10): 156-161. Luo Yun, Tang Li-qing. Application of particle swarm optimization and ant colony optimization algorithm in ship engine room layout optimization[J]. Ship Electronic Engineering, 2019, 39(10): 156-161. DOI:10.3969/j.issn.1672-9730.2019.10.035 [12] 窦小敏, 秦宁宁. 电力系统经济调度的量子粒子群改进算法[J]. 重庆邮电大学学报(自然科学版), 2020, 32(4): 528-535. DOU Xiao-min, QIN Ning-ning. Improved quantum particle swarm optimization algorithm for economic dispatching of power system[J]. Journal of Chongqing University of Posts and Telecommunications (Natural Science Edition), 2020, 32(4): 528-535. [13] 方伟, 孙俊, 谢振平, 等. 量子粒子群优化算法的收敛性分析及控制参数研究[J]. 物理学报, 2010, 59(6): 3686-3694. FANG Wei, SUN Jun, XIE Zhen-ping, et al. Convergence analysis and control parameters of quantum particle swarm optimization algorithm[J]. Journal of Physics, 2010, 59(6): 3686-3694. DOI:10.7498/aps.59.3686 [14] 张钧, 贺可太. 求解三维装箱问题的混合遗传模拟退火算法[J]. 计算机工程与应用, 2019, 55(14): 32-39. ZHANG Jun, HE Ke-tai. Hybrid genetic simulated annealing algorithm for solving three-dimensional packing problem[J]. Computer Engineering and Application, 2019, 55(14): 32-39. DOI:10.3778/j.issn.1002-8331.1902-0127