Information Technology Reference
In-Depth Information
Fig. 3. Simple example of an interlocking function
with an example shown in figure 3. Ports contained by classes, such as interlocks, are
special kind of classes in Modelica and finally typed by type definitions in ModelicaML
profile. When creating ModelicaML classes based on UML AP classes, instances of
such special port classes can be created based on ports used in the UML AP model so
that their naming will be maintained and the suitable type chosen based on the type of
the port. This applies to both input and output ports.
Figure 3 contains only three kinds of logical operations of the 11 presented in figure
1: two NOT and two OR operations and one delay. The transformation processes logi-
cal operations by creating a property (variable) for each operation instance. In case of
Boolean operations (NOT, AND, NAND, OR, NOR, XOR), the type of the property is
always Boolean. In case of other operations, the type needs to be defined in the UML
AP model so that the corresponding ModelicaML type can be chosen by the transfor-
mation. The equations determining the values of the properties are created based on the
kind of the operation (for example NOT or AND) and the connections coming into the
operation which can be followed to another operation or port, for which there will also
be a property (variable) with the same name. In case of the example interlock presented
in figure 3, the value of the first OR operation (from left in the figure) can be defined
to be equal to the logical OR of the values of the NOT operations and the second OR
operation to equal to the logical OR of the first OR operation and the delay operation.
The transformation, thus, tries to define the values of properties with equations. How-
ever, if a model contains loops, this may not be possible. For example, figure 3 contains
a loop the purpose of which is to keep the interlock activated if it once activates so that
the output of the second OR operation (from left) is true. Certain kinds of loops may
produce errors due to discontinuation of the variables, at least with the OpenModelica
tool that we use for simulating. The problem was solved by using algorithms in which
operations are applied in an order (instead of equations that apply all the time). This is
also one of the interactive features of our transformation. If the transformation detects
a loop within an interlock or other kind of AF, it creates algorithmic statements instead
of equations based on the model, shows the statements to the user of the tool and lets
the user arrange the order in which they will be executed in the model.
Another interactive feature of the transformation is related to connecting parts of the
simulation model created based on the UML AP control system model to the exist-
ing parts of the process to be controlled. These connections are necessary for, for ex-
ample, connecting measurement and actuating functions of control systems to sensors
and actuators of the process models, respectively. By default, the transformation uses
Search WWH ::




Custom Search