Conference article

State Machines in Modelica

Hilding Elmqvist
Dassault Systèmes AB, Ideon Science Park, Lund, Sweden

Fabien Gaucher
Dassault Systèmes, Montbonnot-St-Martin, France

Sven Erik Matsson
Dassault Systèmes AB, Ideon Science Park, Lund, Sweden

Francois Dupont
Dassault Systèmes, Plouzanå, France

Download articlehttp://dx.doi.org/10.3384/ecp1207637

Published in: Proceedings of the 9th International MODELICA Conference; September 3-5; 2012; Munich; Germany

Linköping Electronic Conference Proceedings 76:3, s. 37-46

Show more +

Published: 2012-11-19

ISBN: 978-91-7519-826-2

ISSN: 1650-3686 (print), 1650-3740 (online)

Abstract

The scope of Modelica 3.3 has been extended from a language primarily intended for physical systems modeling to modeling of complete systems by allow the modeling of control systems and enabling automatic code generation for embedded systems.

This paper describes the state machines introduced in Modelica 3.3. Any block without continuous-time equations or algorithms can be a state of a state machine. Transitions between such blocks are new kind of connections associated with transition conditions. The paper gives the details for building state machines and includes many examples. In addition; the complete semantics is described using only 13 Modelica equations.

Keywords

Modelica; State Machines; Control

References

Dormoy F.X. (2008): SCADE 6 A Model Based Solution For Safety Critical Software Development; ERTS EMBEDDED REAL TIME SOFTWARE 2008; TOULOUSE; FRANCE; http://www.esterel-technologies.com/EN-50128/files/ERTS2008-SCADE-6-A-Model-Based-Solution-For-Safety-Critical-Software.pdf

Elmqvist H.; Otter M.; and Mattsson S.E. (2012): Fundamentals of Synchronous Control in Modelica. Proceedings of 9th International Modelica Conference; Munich; Germany; September 3-5.

Friedenthal S.; Moore A.; and Steiner R. (2008): A Practical Guide to SysML –The Systems Modeling Language; Elsevier Inc.

Gaucher F.; Closse E.; Weil D. (2009): The LCM Language Primer; Dassault Systèmes Internal Report; Grenoble; France; 2009

Hamon G.; and Rushby J. (2004). An operational semantics for Stateflow. In Fundamental Approaches to Software Engineering (FASE)’04; volume 2984 of LNCS; pages 229–243; Barcelona; Spain; 2004. Springer. http://fm.csl.sri.com/~rushby/papers/sttt07.pdf

Harel; D. (1987): Statecharts: A Visual Formalism for Complex Systems. Science of Computer Programming 8; 231-274. Department of Applied Mathematics; The Weizmann Institute of Science; Rehovot; Israel. www.inf.ed.ac.uk/teaching/courses/seoc1/2005_2006/resources/statecharts.pdf

Malmheden M.; Elmqvist H.; Mattsson S.E.; Henriksson D.; and Otter M. (2008): ModeGraph - A Modelica Library for Embedded Control Based on Mode-Automata. B. Bachmann (editor); in Proc. of Modelica?2008 conference; Bielefeld; Germany. www.modelica.org/events/modelica2008/Proceedings/sessions/session3a3.pdf

Maraninchi; F. and Rémond; Y. (2002): Mode-Automata: a New Domain-Specific Construct for the Development of Safe Critical Systems. http://wwwverimag.imag.fr/~maraninx/SCP2002.html

MathWorks (2012): R2012a Documentation - Stateflow http://www.mathworks.com/help/toolbox/stateflow/

Modelica Association (2012): Modelica Language Specification Version 3.3. https://www.modelica.org/documents/ModelicaSpec33.pdf.

Mosterman P.; M. Otter; and H. Elmqvist. (1998): Modeling Petri Nets as Local Constraint Equations for Hybrid Systems using Modelica. Proceedings of SCSC?98; Reno; Nevada; USA; Society for Computer Simulation International; pp. 314–319.

Otter M.; K.-E. Årzén; and I. Dressler (2005): StateGraph – A Modelica Library for Hierarchical State Machines. Proceedings of the 4th International Modelica Conference; Hamburg; Germany; ed. G. Schmitz; pp. 569-578. http://www.modelica.org/events/Conference2005/online_proceedings/Session7/Session7b2.pdf

Otter M.; Malmheden M.; Elmqvist H.; S.E. Mattsson; and C. Johnsson (2009): A New Formalism for Modeling of Reactive and Hybrid Systems. Proceedings of the 7th International Modelica Conference; Como; Italy; 20-22 September 2009. http://www.ep.liu.se/ecp/043/041/ecp09430108.pdf

Pouzet M. (2006): Lucid Synchrone; Version 3.0; Tutorial and Reference Manual. http://www.di.ens.fr/~pouzet/lucid-synchrone/

Citations in Crossref