Sunteți pe pagina 1din 3

Fact Sheet

SimulationX Interfaces to MATLAB/Simulink


As a partner in The MathWorks Connections Program, ITI offers a
variety of interfaces in SimulationX to integrate models and data in
a MATLAB/Simulink environment. These interfaces have
proven their capabilities in many industrial applications.

1. C-Code Export to Simulink


The option Code Export S-Function translates the functionality of an entire
SimulationX model into source code for an S-Function. The generated S-Function
can also be processed by the Real-Time Workshop in order to create real-time
code for one of the supported hardware targets (e.g. dSpace).

Complete
integration of
SimulationX models
into
MATLAB/Simulink
C-Code export from
SimulationX to
Simulink
FMI Target for
Simulink Coder
Result processing in
MATLAB and
SimulationX
Simulation with
MATLAB/Simulink
Solvers
Export of
SimulationX models
to Real-Time
Workshop
Import of
MATLAB/Simulink
models

You select inputs, outputs, parameters, and the code export generates the
corresponding platform independent source code. The MATLAB mex
command creates an executable S-Function.
The SimulationX model is exported as a generic differential equation. That means
the calculation is completely done in Simulink. In contrast to Co-Simulation, this
approach is the more efficient and numerically better solution to integrate a
SimulationX model in MATLAB/Simulink.

Page 2 of 3

2. FMI Target for Simulink Coder


For the exchange of models across different platforms, the FMI Target for Simulink Coder enables the
export of models from Simulink as FMUs for Co-Simulation. That allows for a continuous workflow in a
closed toolchain throughout the entire product lifecycle. The generated FMU is fully FMI 1.0 compliant and
includes the models functionality and the Simulink solver, which enables any tool supporting FMUs for CoSimulation to run the unit without Simulink. Sensitive model data, however, remains protected since the
source code is not exported.

FMI Target for Simulink Coder is available as part of SimulationX or as a standalone add-on for
Matlab/Simulink which requires a separate license. Supported platforms are Windows based 32 bit and 64
bit environments.

3. Co-Simulation with Simulink


If the user has access to both programs, subsystems modeled in SimulationX and MATLAB/Simulink can be
linked together and can be simulated simultaneously in a co-simulation.
Online co-simulation between SimulationX and MATLAB/Simulink requires the SimulationX library CoSimulation. This library provides the Coupling Element which establishes the communication link with
MATLAB/Simulink and performs the exchange of vector signals with the corresponding S-Function block in
Simulink. This allows defining interactions of varying complexity. A communication interval defines the
frequency of the data exchange. Simulink and SimulationX can run on different computers using a TCP/IP
connection for the communication.

The results generated in the two simulators are valid for the overall model and can be evaluated online.
Both sub-models can be easily modified in their corresponding environments and the simulation can be immediately restarted afterwards without any intermediate operations. Result evaluation is possible in
Simulink as well as in SimulationX.

ITI Headquarters
SimulationX

Schweriner Strae 1 01067 Dresden Germany T +49 (0) 351.260 50 - 0 F +49 (0) 351.260 50 - 155 sales@simulationx.com
For your local representative please visit www.simulationx.com/global
ITI and SimulationX are registered trademarks of ITI GmbH Dresden. ITI GmbH, Dresden, Germany, 2013. All rights reserved.

Page 3 of 3

4. Integration of MATLAB Code via DLL


The MATLAB Compiler (mcc) can create DLLs from MATLAB Code. These DLLs can then be integrated in
SimulationX without a MATLAB installation. The Integration of the MATLAB DLLs is realized by an external
function. The external function can be called from within SimulationX without any restrictions. External
functions are part of the Modelica specification and come with the standard configuration of SimulationX.

5. Conclusion
SimulationX models can interact with MATLAB/Simulink in different ways. The following table shows the
available interfaces and their specifics.
Interface

Comment

C-Code Export to Simulink

Best numerical solution for the integration of SimulationX models in


Simulink.

FMI Target for Simulink Coder

Export Simulink models as standalone FMUs for Co-Simulation based on


the FMI 1.0 standard. The Simulink solver is included in the FMU, so
Simulink is not required to run the FMU.

Co-Simulation with Simulink

Straightforward interface solution; needs a valid license for SimulationX and


Simulink. Numerically critical solution for the connection of two strongly
dependent, continuous models.

DLL-Integration of MATLAB DLLs

Integration of state-free MATLAB functions and algorithms in SimulationX.


MATLAB Compiler required.

ITI Headquarters
SimulationX

Schweriner Strae 1 01067 Dresden Germany T +49 (0) 351.260 50 - 0 F +49 (0) 351.260 50 - 155 sales@simulationx.com
For your local representative please visit www.simulationx.com/global
ITI and SimulationX are registered trademarks of ITI GmbH Dresden. ITI GmbH, Dresden, Germany, 2013. All rights reserved.

S-ar putea să vă placă și