Mats Jirstrand and Johan Gunnarsson
Mjärdevi Science Park
SE-583 30 Linköping Sweden
PELAB – Programming Environment Lab
Department of Computer and Information Science
SE-581 83 Linköping
MathModelica is a Mathematica extension, which provides a modeling, and simulation environment for Mathematica based on the new standard of physical modeling languages called Modelica. Modelica is a new object-oriented multi-domain modeling language based on algebraic and differential equations. In this paper we present a language and an environment, MathModelica, that integrates different phases of the Modelica development lifecycle. This is achieved by using the Mathematica environment and its structured documents, “notebooks”. Simulation models are represented in the form of structured documents, which integrate source code, documentation and code transformation specifications, as well as providing control over simulation and result visualization.
Import and export of Modelica code between internal structured and external textual representation is supported. Mathematica is an interpreted language, which is suitable as a scripting language for controlling simulation and visualization. Mathematica also supports symbolic transformations on equations and algebraic expressions which is useful in building mathematical models.