Wolfram Computation Meets Knowledge

Interacting with the System Modeler Kernel

Kernel Command ViewClearing the View
Kernel Commands

Kernel Command View

The Kernel Command view is available in both Model Center and Simulation Center. It provides a way to interact with the System Modeler kernel by executing commands and evaluating Modelica expressions. When opening the Kernel Command view by choosing View Kernel Command, it will appear in the bottom area of the main window.


Executing commands in the Kernel Command view.

Kernel Commands

To interact with the kernel, the commands described in this section can be used.


Variables and Evaluation

The Kernel Command view can also be used as a Modelica expression evaluator. This is an example of a session, showing evaluation of expressions and functions and assignment of variables. Inputs are shown in bold:

1 + 2
a := 2
b := Modelica.Constants.pi / 2
a + Modelica.Math.sin(b)
ndims({{1, 2}, {3, 4}})
size({{1, 2}, {3, 4}})

These commands can be used to handle variables defined in the kernel session:

Clearing the View

The Kernel Command view can be cleared by right-clicking anywhere within the view and choosing Clear All.