UML-HLA collaborative modeling method and its application in multi-train simulation system
-
摘要: 针对复杂实时大系统分布式交互性特点, 通过综合对比UML与HLA的特点, 提出了基于UML-HLA的列控系统建模仿真方法。在传统建模方法的基础上, 采用提出的UML-HLA建模方法, 从多个不同的角度建立多车仿真系统的分析模型, 包括用例建模、活动建模、结构建模、交互建模和状态建模等, 构建起高层体系架构资源库。在分析模型的基础上, 建立多车仿真系统体系结构, 得到多车仿真系统的设计模型。从性能和功能上对多车仿真系统进行了仿真验证。仿真结果表明: 基于UML-HLA的建模方法具有较强的可交互性和可操作性, 通过对原有线程机制与定时器控制机制进行优化, 采用线程管理机制将原有系统的CPU占有率由50%降低至15%以下, 定时器误差控制在0.02ms范围内, 满足了列控系统的仿真要求。Abstract: Aimed at the distributed and interactive properties of complex real-time large system, through a comprehensive comparison of unified modeling language (UML) and high level architecture (HLA) features, a modeling and simulating method of train control system was proposed based on high level architecture with unified modeling language (UML-HLA).On the basis of traditional modeling method, an analysis model of multi-train simulation system was constructed from different perspectives by using UML-HLA modeling method.The model consisted of use case modeling, activity modeling, structural modeling, interactive modeling and state-based modeling, and the high level architecture resource library was constructed.Based on the analysis model, a multi-train simulation system structure was established, and a design model of multi-train simulation system was obtained finally.The functions and performances of multitrain simulation system were validated.Simulation result shows that the modeling method based on UML-HLA has strong interactivity and maneuverability.With the optimization of original thread management mechanism and timer control mechanism, the CPU occupancy of original system reduces from 50% to below 15% by using thread management method, the timer error in the system is below 0.02 ms, and the simulation requirement of train control system is satisfied.
-
表 1 多车仿真系统实体类
Table 1. Entity class of multi-train simulation system
-
[1] MA Zong-min, ZHANG Fu, YAN Li, et al. Representing and reasoning on fuzzy UML models: a description logic approach[J]. Expert Systems with Applications, 2011, 38 (3): 2536-2549. doi: 10.1016/j.eswa.2010.08.042 [2] LEES M, LOGAN B, THEODOROPOULOS G. Distributed simulation of agent-based systems with HLA[J]. ACM Transactions on Modeling and Computer Simulation, 2007, 17 (3): 1-25. [3] DISTEFANO S, SCARPA M, PULIAFITO A. From UML to Petri nets: the PCM-based methodology[J]. IEEE Transactions on Software Engineering, 2011, 37 (1): 65-79. doi: 10.1109/TSE.2010.10 [4] 王帅, 吉吟东, 杨士元. 一种基于场景的CTCS-3列车控制系统建模方法研究[J]. 铁道学报, 2011, 33 (9): 55-61. doi: 10.3969/j.issn.1001-8360.2011.09.010WANG Shuai, JI Yin-dong, YANG Shi-yuan. A kind of modeling method for CTCS-3based on operation scenario[J]. Journal of the China Railway Society, 2011, 33 (9): 55-61. (in Chinese). doi: 10.3969/j.issn.1001-8360.2011.09.010 [5] 王悉, 唐涛. 基于UML的列控系统车载人机界面设计和实现[J]. 系统仿真学报, 2006, 18 (2): 338-342, 361. doi: 10.3969/j.issn.1004-731X.2006.02.019WANG Xi, TANG Tao. Design and realization of train operation control system onboard MMI based on UML[J]. Journal of System Simulation, 2006, 18 (2): 338-342, 361. (in Chinese). doi: 10.3969/j.issn.1004-731X.2006.02.019 [6] 韩胤, 张勇. CTCS3级仿真系统中无线闭塞中心的仿真[J]. 铁路计算机应用, 2007, 16 (3): 43-45. doi: 10.3969/j.issn.1005-8451.2007.03.015HAN Yin, ZHANG Yong. Computer simulation of radio block center in CTCS level 3[J]. Railway Computer Application, 2007, 16 (3): 43-45. (in Chinese). doi: 10.3969/j.issn.1005-8451.2007.03.015 [7] 卢衍丹, 唐涛. 面向对象的列车自动驾驶仿真系统建模[J]. 系统仿真学报, 2002, 14 (1): 8-10. doi: 10.3969/j.issn.1004-731X.2002.01.003LU Yan-dan, TANG Tao. Object-oriented modeling of automatic train operation simulation system[J]. Journal of System Simulation, 2002, 14 (1): 8-10. (in Chinese). doi: 10.3969/j.issn.1004-731X.2002.01.003 [8] 邵维忠, 蒋严冰, 麻志毅. UML现存的问题和发展道路[J]. 计算机研究与发展, 2003, 40 (4): 509-516.SHAO Wei-zhong, JIANG Yan-bing, MA Zhi-yi. The present problems and roadmap of UML[J]. Journal of Computer Research and Development, 2003, 40 (4): 509-516. (in Chinese). [9] 上官伟, 蔡伯根, 刘振国, 等. 基于HLA的列控系统多车仿真策略研究[J]. 铁道学报, 2012, 34 (8): 57-63. doi: 10.3969/j.issn.1001-8360.2012.08.010SHANGGUAN Wei, CAI Bai-gen, LIU Zhen-guo, et al. Research of HLA-based simulation strategy for multi-train simulation of train control system[J]. Journal of the China Railway Society, 2012, 34 (8): 57-63. (in Chinese). doi: 10.3969/j.issn.1001-8360.2012.08.010 [10] 郭宁, 杨巍, 吴亮. CTCS2级列车运行控制系统超速防护仿真研究[J]. 交通运输工程与信息学报, 2007, 5 (4): 122-126. https://www.cnki.com.cn/Article/CJFDTOTAL-JTGC200704024.htmGUO Ning, YANG Wei, WU Liang. Simulation of the automatic train protection based on Chinese train control system-2[J]. Journal of Transportation Engineering and Information, 2007, 5 (4): 122-126. (in Chinese). https://www.cnki.com.cn/Article/CJFDTOTAL-JTGC200704024.htm [11] 张宇宏, 胡亚海, 彭晓源, 等. 基于HLA的防空导弹武器系统仿真平台研究[J]. 北京航空航天大学学报, 2003, 29 (1): 1-4. https://www.cnki.com.cn/Article/CJFDTOTAL-BJHK200301000.htmZHANG Yu-hong, HU Ya-hai, PENG Xiao-yuan, et al. Simulation platform based on HLA for air defense missile weapon system[J]. Journal of Beijing University of Aeronautics and Astronautics, 2003, 29 (1): 1-4. (in Chinese). https://www.cnki.com.cn/Article/CJFDTOTAL-BJHK200301000.htm [12] 黄健, 冯润明, 黄柯棣. HLA联邦运行管理的分析与设计[J]. 系统工程与电子技术, 2000, 22 (5): 83-86. https://www.cnki.com.cn/Article/CJFDTOTAL-XTYD200005026.htmHUANG Jian, FENG Run-ming, HUANG Ke-di. Analysis and design on the runtime management of HLA federation[J]. Systems Engineering and Electronics, 2000, 22 (5): 83-86. (in Chinese). https://www.cnki.com.cn/Article/CJFDTOTAL-XTYD200005026.htm [13] 宋恒杰, 杨明, 王子才. 基于高级体系结构的联邦集成测试平台的研究[J]. 北京邮电大学学报, 2005, 28 (4): 32-36. https://www.cnki.com.cn/Article/CJFDTOTAL-BJYD200504007.htmSONG Heng-jie, YANG Ming, WANG Zi-cai. Research on federation integrated test rlatform based on HLA[J]. Journal of Beijing University of Posts and Telecommunications, 2005, 28 (4): 32-36. (in Chinese). https://www.cnki.com.cn/Article/CJFDTOTAL-BJYD200504007.htm [14] 王宏刚, 张一军, 张琦, 等. 基于UML的列车运行调度系统软件模型[J]. 中国铁道科学, 2005, 26 (5): 107-111. https://www.cnki.com.cn/Article/CJFDTOTAL-ZGTK200505024.htmWANG Hong-gang, ZHANG Yi-jun, ZHANG Qi, et al. UML based software model of train traffic control system[J]. China Railway Science, 2005, 26 (5): 107-111. (in Chinese). https://www.cnki.com.cn/Article/CJFDTOTAL-ZGTK200505024.htm [15] 赵志崑, 盛秋戬, 史忠植. UML活动图描述工作流模型的执行语义[J]. 计算机研究与发展, 2005, 42 (2): 300-307. https://www.cnki.com.cn/Article/CJFDTOTAL-JFYZ200502017.htmZHAO Zhi-kun, SHENG Qiu-jian, SHI Zhong-zhi. An execution semantics of UML activity view for workflow modeling[J]. Journal of Computer Research and Development, 2005, 42 (2): 300-307. (in Chinese). https://www.cnki.com.cn/Article/CJFDTOTAL-JFYZ200502017.htm [16] 刘金涛, 唐涛, 徐天华, 等. 基于UML的CTCS-3级列控系统需求规范形式化验证方法[J]. 中国铁道科学, 2011, 32 (3): 93-99. https://www.cnki.com.cn/Article/CJFDTOTAL-ZGTK201103019.htmLIU Jin-tao, TANG Tao, XU Tian-hua, et al. Formal verification of CTCS-3system requirements specification based UML model[J]. China Railway Science, 2011, 32 (3): 93-99. (in Chinese). https://www.cnki.com.cn/Article/CJFDTOTAL-ZGTK201103019.htm