Abstract
Although widely used in embedded systems design, Matlab/Simulink is not considered a state-of-the-art design environment by the software engineering community. This paper is aimed at improving design with Simulink from the software engineering perspective by developing automated support for the application of some traditional software engineering principles when developing with Simulink. We present four tools: the Signature Tool, the Reach/Coreach Tool, the Data Store Rescope Tool, and the Auto Layout Tool. The Signature Tool extracts the interface of a Simulink subsystem, enabling developers to better understand the implicit data flow in Simulink models and use it more effectively, while also producing useful documentation. The Data Store Rescope Tool improves modularity of Simulink models by properly scoping data stores, the Simulink equivalent of variables in traditional languages. The Reach/Coreach Tool highlights data and control dependencies in Simulink models, making them easier to understand. Also, the tool supports debugging, reverse-engineering, refactoring, and static analysis of the models. Finally, the Auto Layout Tool automatically improves the layout of Simulink models, reducing the effort developers invest in graphical layout to comply with modeling guidelines and improve readability of their models.
Similar content being viewed by others
Notes
It might seem that the input and output signals of a block in Simulink are obvious from the block diagram; however, there is hidden data flow in Simulink not evident on the diagram as will be discussed in Sect. 2.
A referenced model is a model referenced from another model using a Model block.
At the beginning of a time step, if the IC input does not hold, the subsystem is not executed in that time step. If the IC input does hold, the subsystem gets executed, and then, if the cond input is true, the iterator executes the subsystem again. The iterations continue while cond input is true and the number of iterations is less than or equal to the Maximum number of iterations.
References
Auto Layout Tool: http://www.mathworks.com/matlabcentral/fileexchange/51228-auto-layout-tool (2015) (online). Accessed Feb 2016
Bender, M., Laurin, K., Lawford, M., Ong, J., Postma, S., Pantelic, V.: Signature required: making Simulink data flow and interfaces explicit. In: Proceedings of 2nd International Conference on Model-Driven Engineering and Software Development (MODELSWARD 2014), pp. 119–131. SCITEPRESS (2014)
Bender, M., Laurin, K., Lawford, M., Pantelic, V., Korobkine, A., Ong, J., Mackenzie, B., Bialy, M., Postma, S.: Signature required: making Simulink data flow and interfaces explicit. Sci. Comput. Program. 113(Part 1), 29–50 (2015)
Chen, C.q., Ji, Y.: Modular aircraft simulation platform based on Simulink. In: IEEE International Conference on Mechatronics and Automation (ICMA 2010), pp. 1454–1459 (2010). doi: 10.1109/ICMA.2010.5589162
Data Store Rescope Tool: http://www.mathworks.com/matlabcentral/fileexchange/51160-data-store-rescope-tool (2015) (online). Accessed Sept 2016
Dajsuren, Y., van den Brand, M.G.J., Serebrenik, A., Roubtsov, S.: Simulink models are also software: modularity assessment. In: Proceedings of the 9th International ACM Sigsoft Conference on Quality of Software Architectures (QoSA), pp. 99–106. ACM (2013)
Fehér, P., Mészáros, T., Mosterman, P.J., Lengyel, L.: Flattening virtual Simulink subsystems with graph transformation. CoSMoS 2013, 39 (2013)
Gansner, E.R., Koutsofios, E., North, S.C., Vo, K.P.: A technique for drawing directed graphs. IEEE Trans. Softw. Eng. 19(3), 214–230 (1993)
Ghezzi, C., Jazayeri, M., Mandrioli, D.: Fundamentals of Software Engineering, 2nd edn. Prentice-Hall, Englewood Cliffs (2002)
Hunt, A., Thomas, D.: Ubiquitous automation. IEEE Softw. 19(1), 11 (2002)
Klauske, L.K., Dziobek, C.: Improving modeling usability: automated layout generation for Simulink. In: Proceedings of the MathWorks Automotive Conference. MAC (2010)
Klauske, L.K., Schulze, C.D., Spönemann, M., von Hanxleden, R.: Improved layout for data flow diagrams with port constraints. In: Cox, P., Plimmer, B., Rodgers, P. (eds.) Diagrammatic Representation and Inference. Lecture Notes in Computer Science, vol. 7352, pp. 65–79. Springer, Berlin (2012)
Model Engineering Solutions: MES Model Examiner (MXAM DRIVE). http://www.model-engineers.com/en/model-examiner.html (2014) (online). Accessed Sept 2014
Pantelic, V., Postma, S., Lawford, M., Korobkine, A., Mackenzie, B., Ong, J., Bender, M.: A toolset for Simulink: improving software engineering practices in development with Simulink. In: Proceedings of 3rd International Conference on Model-Driven Engineering and Software Development (MODELSWARD 2015), pp. 50–61. SCITEPRESS (2015)
Quante, J.: Views for efficient program understanding of automotive software. Softwaretechnik-Trends 33(2) (2013)
Reach/Coreach Tool: http://www.mathworks.com/matlabcentral/fileexchange/51180-reach-coreach-tool (2015) (online). Accessed Feb 2016
Rau, A.: On model-based development: a pattern for strong interfaces in Simulink. Gesellschaft für Informatik, FG 2(1), 12 (2002)
Reicherdt, R., Glesner, S.: Slicing MATLAB Simulink models. In: Proceedings of the 2012 International Conference on Software Engineering (ICSE 2012), pp. 551–561. IEEE Press, Piscataway, NJ, USA (2012)
Signature Tool: http://www.mathworks.com/matlabcentral/fileexchange/49897-signature-tool (2015) (online). Accessed Feb 2016
Sankaranarayanan, H., Kulkarni, P.A.: Source-to-source refactoring and elimination of global variables in C programs. J. Softw. Eng. Appl. 6(4), 264–273 (2013)
Smith, A.R., Kulkarni, P.A.: Localizing globals and statics to make C programs thread-safe. In: Proceedings of the 14th International Conference on Compilers, Architectures and Synthesis for Embedded Systems (CASES 2011), pp. 205–214. ACM, New York, NY, USA (2011). doi:10.1145/2038698.2038730
The MathWorks: Model Advisor: http://www.mathworks.com/help/simulink/ug/consulting-the-model-advisor.html (2014) (online). Accessed Sept 2014
The MathWorks: Verification and Validation Toolbox. http://www.mathworks.com/products/simverification/ (2014) (online). Accessed Sept 2014
The MathWorks: BOT. http://www.mathworks.com/matlabcentral/fileexchange/45670-bot (2015) (online). Accessed Oct 2015
The MathWorks: Data Store Diagnostics. http://www.mathworks.com/help/simulink/ug/using-data-store-diagnostics.html (2015) (online). Accessed Oct 2015
The MathWorks: Japan MathWorks Automotive Advisory Board (JMAAB): Control Algorithm Modeling Guidelines Using MATLAB, Simulink, and Stateflow, Version 4.01. www.mathworks.com/solutions/automotive/standards/maab.html (2015) (online). Accessed Feb 2016
The MathWorks: Simulink User’s Guide. http://www.mathworks.com/help/releases/R2015b/pdf_doc/simulink/sl_using (2015) (online). Accessed Sept 2015
The MathWorks: The MathWorks Automotive Advisory Board, Version 3.0. http://www.mathworks.com/automotive/standards/maab.html (2015) (online). Accessed Feb 2016
Tran, Q.M., Wilmes, B., Dziobek, C.: Refactoring of Simulink diagrams via composition of transformation steps. In: The 8th International Conference on Software Engineering Advances (ICSEA 2013), pp. 140–145 (2013)
Author information
Authors and Affiliations
Corresponding author
Rights and permissions
About this article
Cite this article
Pantelic, V., Postma, S., Lawford, M. et al. Software engineering practices and Simulink: bridging the gap. Int J Softw Tools Technol Transfer 20, 95–117 (2018). https://doi.org/10.1007/s10009-017-0450-9
Published:
Issue Date:
DOI: https://doi.org/10.1007/s10009-017-0450-9