LTH-image

Synchronous Control and State Machines in Modelica

Hilding Elmqvist, Dassault Systèmes AB

Abstract:

The scope of Modelica has been extended from a language primarily intended for physical systems modeling to modeling of complete systems by allowing the modeling of control systems and by enabling automatic code generation for embedded systems. Much focus has been given to safe constructs and intuitive and well-defined semantics.

The presentation will describe the fundamental synchronous language primitives introduced for increased correctness of control systems implementation. The approach is based on associating clocks to the variable types. Special operators are needed when accessing variables of another clock. This enables clock inference and increased correctness of the code since many more checks can be done during translation. Furthermore, the sampling period of a clocked partition needs to be defined only at one place (either in absolute time or relatively to other clocked partitions). The principles of partitioning a system model into different clocks (continuous, periodic, non-periodic, multi-rate) will be explained.

The new language elements follow the synchronous approach. They are based on the clock calculus and inference system of Lucid Synchrone. However, the Modelica approach also uses multi-rate periodic clocks based on rational arithmetic and also non-periodic and event based clocks are supported.

Parallel and hierarchical state machines will be introduced including submodels within states. The supporting Modelica library will also be introduced.

Presentation slides  (ppt)

Biography:

Elmqvist’s Ph.D. thesis from the Department of Automatic Control, Lund Institute of Technology contains the design of a novel object-oriented and equation based modelling language, Dymola, and algorithms for symbolic model manipulation.

In 1992, Elmqvist founded Dynasim AB and in 1996 he took the initiative to organize the international effort to design the next generation object-oriented language for physical modelling, Modelica. Elmqvist is the chief architect of the Multi-Engineering Modelling and Simulation software used in Dymola Product Line and CATIA Systems DBM and responsible for Technology within the board of Modelica Association.