计算机科学 ›› 2014, Vol. 41 ›› Issue (11): 227-232.doi: 10.11896/j.issn.1002-137X.2014.11.044

• 软件与数据库技术 • 上一篇    下一篇

基于Simulink模型确定计算顺序的研究

李俊,朱长皓,陆梦寒   

  1. 中国科学技术大学自动化系 合肥230027;中国科学技术大学自动化系 合肥230027;中国科学技术大学自动化系 合肥230027
  • 出版日期:2018-11-14 发布日期:2018-11-14
  • 基金资助:
    本文受国家自然基金重点项目(61331017)资助

Research of Confirming Calculate Order Based on Simulink Model

LI Jun,ZHU Chang-hao and LU Meng-han   

  • Online:2018-11-14 Published:2018-11-14

摘要: 将Simulink仿真与代码生成相结合具有很大的实用价值。通过分析Simulink模型特点,将模型转变为C语言代码可达到模型仿真和代码生成相结合的目的,而其中亟需解决的问题是在生成代码过程中计算顺序的确定。通过提取Simulink模型文件中的信息来分析Simulink模型中模块的特性,并将模块间的关系以图的形式存储进而得到Simulink模型中模块间的依赖关系。由模块特性和模块间依赖关系得出两种计算顺序:考虑到底层模块的模块化计算顺序和顾及子系统的层次化计算顺序。通过分析比较这两种计算顺序,发现层次化计算顺序优于模块化计算顺序。最后对Simulink自带的f14模型的测试说明了两种计算顺序是可行的。

关键词: 计算顺序,层次化,Simulink仿真,基于模型,依赖关系

Abstract: The combination of Simulink simulation and code generation has great practical value.By analyzing the feature of models,Simulink models can be converted into C language code,which realizes the purpose of combination of Simulink simulation and code generation.And the primary problem is the confirmation of calculate order during the code generation process.From the information extracted from Simulink models file,the feature of module in Simulink model is analyzed and the dependence between modules from the relationship of the modules which is stored in graphsis is gotten.From the feature of module in Simulink model and dependence,two calculated orders are goten:the calculate order based on module which takes into account the underlying module and the calculate order based on hierarchy with consideration of subsystem.By analyzing and comparing the two calculate order,it was found that the calculate order based on hierarchy is better than the calculate order based on module.Finally by testing the model of f14 in Simulink,it was found that the two calculate orders are feasible.

Key words: Calculation order,Hierarchy,Simulink simulation,Based-models,Dependence

[1] Mokhtari M,Marie M.MATLAB与SIMULINK工程应用[M].北京:电子工业出版社,2002
[2] 黄永安,马路,刘慧敏.MATLAB7.0/Simulink6.0建模仿真开发与高级工程应用[M].北京:清华大学出版社,2005
[3] 李颖.Simulink动态系统建模与仿真(第2版)[M].西安:西安电子科技大学出版社,2009
[4] Works M.MathWorks Automotive Advisory Board ControlAlgorithm Modeling Guidelines Using MATLAB,Simulink,and Stateflow.R2011b.http://www.docin.com/p-173565475.html
[5] Shen E,Zhang Tao,Huang Liang-wei,et al.A real-time simulation system for satellite based on RTW and VxWorks[C]∥2010 3rd International Symposium on Systems and Control in Aeronautics and Astronautics (ISSCAA).IEEE,2010:859-864
[6] 王勃.Real-time Workshop机制研究——动态数据流模型代码生成器的研究与实现[D].成都:电子科技大学,2008
[7] 任传俊,蒋志文.Real-Time Workshop 实时仿真研究与应用 [J].计算机仿真,2007,24(8):268-271
[8] 卞学飞.基于 DSP 的 RTW 代码自动生成技术研究[D].成都:电子科技大学,2012
[9] Math Works.Real-Time Workshop 7 Target Language Compiler.http://www.docin.com/p-81745259.html
[10] 魏丽侠,王涛.图论及其应用[M].徐州:中国矿业大学出版社,2012
[11] 王桂平,王衍,任嘉辰.图论算法理论、实现及应用[M].北京:北京大学出版社,2011
[12] 徐俊明.图论及其应用[M].合肥:中国科学技术大学出版社,2010
[13] 邱杰,原渭兰.数字计算机仿真中消除代数环问题的研究[J].计算机仿真,2003,20(7):33-35

No related articles found!
Viewed
Full text


Abstract

Cited

  Shared   
  Discussed   
No Suggested Reading articles found!