Skip to content

Results & Visualization

  1. Once a simulation has been executed, a result is added to the list in SIMULATIONS heading/browser (via Result mode).

  2. For each result, the results item (a file) can be renamed , deleted , or downloaded .The simulation and compilation logs can be viewed from the menu option.

  3. By default, the latest result is selected when a simulation was executed.

  4. The variables from the selected Result are shown under the CALCULATED VARIABLES header. The variables are organized in a tree structure which follows the hierarchy. Like in the model browser, there is a text filter and a type filter to help you explore the results tree.

  5. Select All option is available to delete all the results at once. This option pops up when is selected for one of the results.

  6. The name of the selected Result will appear above the model canvas, near the class path. This is useful when working with multiple simulation results.

  7. The name/title of a Result can be edited/customized to assign it to a specific context or simply to make it more understandable/familiar/convenient.


Visualizing results🔗

Execution results can be visualized in the following ways:

  • Plots - standard way to visualize transient result
  • Stickies - display variables and parameters on the model canvas
  • Built in model animation - display built-in model animation on the model canvas

Plots🔗

  1. Create a plot by dragging a variable from the result browser into the model canvas.

  2. A new plot is created if the variable is dragged to an empty space in the canvas.

  3. If dragged onto an existing plot the variable is added to the same plot. It’s also possible to drag variables between plots.

  4. The color of individual plots can be changed. Hover the cursor over dot to the left of the name of the plot. Left-click to see menu option. Choose Line color.

  5. Click and drag mouse over plot to augment the view. Repeat to further augment view.

  6. The Time Slider at the bottom of the canvas can also be used to show a line marker in each plot.

  7. A plotted variable can be removed by clicking the button near its legend. It is possible to hide the legends (when not hovering) in a plot window by pressing the button.

Create plots automation


Pin Plots🔗

Pin plots help compare results between different models. Pinned plots remain on the canvas when switching between models. The legend will include the model name for the origin of the plotted variables.

  1. Click on the pin icon to retain a plot in the canvas.

Stickies🔗

Stickies are used to visualize parameters and variables in the model canvas. For parameters, values can also be changed directly in the stickies. A selection of the most frequently used parameters can be added as stickies to facilitate model configuration.

  1. Display a result on the model canvas, by going to the variable of interest in the Calculated Values panel and pressing the button.

  2. Use the Time Slider to view the values of the variables at a particular point in time.

  3. Move a stickies on the canvas by dragging them using the left mouse button.

  4. The stickies can be pinned down to the canvas using button in the stickies.

How to use stickies animation


Stickies for entire tabs🔗

Stickies can also be enabled for entire tabs.

  1. Go to PROPERTIES > Toggle filters icon
  2. This filtering feature is dedicated for modelling mode and it allows to view only parameters with stickies.
Stickies for tabs


Moving stickies🔗

  1. Stickies can be repositioned by dragging them. By default, they will move with their component.
  2. The model properties can be filtered to only show components that are shown on stickies using the category filters.

Diagram animation🔗

Models with built-in diagram animation will be shown on the model canvas.

  1. Use the bottom scroll bar to walk through the time based animation.
Diagram animation


Views🔗

  • Views are used to save a set of plots and stickies for a model. This includes the variables plotted and shown in stickies as well as the positioning of plots and stickies.
  • Views are saved in the context of the active workspace for the workspace package and global libraries. The eye button toggles the default view on and off.
  • The dropdown allows to select preconfigured views or to open the right panel to access all the details.

Create a view🔗

  1. To create a view, at least one plot or sticky must be enabled.
  2. On the right side of the canvas, the view button is used to see the list of available views.
Create a view

  1. Click Save as... to add a view and give it a name. The new view is then saved and is available in the list

Update a view🔗

  1. An updated setup of plots and stickies can be saved to an existing view.
Update a view animation

  1. The view is then overwritten with the current setup of plots and stickies.

Delete a view🔗

  1. To delete a view, press the button.

Component view🔗

Views can be defined as part of a component, will be available when this component is added to a model.

  1. Drag variables from the Model browser to create plots even if there are no results for the active model.
  2. In the case below, a View is defined for the Inertia component showing J and phi in a sticky. This view is then shown in the list with the [Inertia] prefix to show that this is a component view.
  3. Component view can be enabled directly from the component in the canvas when component is selected.
Component view


System view🔗

System views can be defined for model components.

  1. Right mouse click > Inspect component and plot or sticky creation > save view.
  2. These views will be available under System views.
System view


Limit result size🔗

The presentation of results from an experiment can be limited by filtering to get a better overview. Filtering works by selecting a view or by entering free text to find the corresponding variable.

  1. Go to the Experiment tab.
  2. Choose the experiment on which to apply the filter.
  3. Click on the Outputs tab.
  4. Add a filter by clicking +New filter.
  5. Choose text or view from the drop-down menu.
  6. When choosing text, enter “Free_text” that is matched against existing variable paths. Confirm by clicking the check symbol.
  7. When choosing view, use the drop down menu in the next field to choose appropriate view. Confirm by clicking the check symbol.

Case sliders🔗

Case sliders allows the user to isolate results when running multiple experiments with ranges of variables. Fix one variable and use the case-slider to show results from the cases generated by the range of variables.

  1. This task is performed in the Result view.
  2. Open the Simulations tab in Details panel to the left of the canvas.
  3. Click on the Result to be displayed.
  4. Multi experiment will generate a case slider window displayed at the bottom of the screen.
Case slider

  1. Drag the blue dot between the various cases to see results from the various experiment cases.
  2. Click on Modification tab found by clicking on the EXPERIMENT tab in the Display panel to the right of the model canvas. Case sliders tag to variables activated when using range or choices. It allows user to fix value of a variable when using choices on more than one parameter.
Modification tab

Case labels in the UI🔗

Every result and case from a simulation can be given its own name for easy search and reference.

  1. Expand the Simulations tab in the details panel to display results.
  2. Hover over the intended result or case.
  3. Click on the edit pen symbol to the right of the name.
  4. The field will turn red when using unsupported characters such as ! and ?.
  5. Clicking on the result, displays the name in the top navigation bar .

Download of Results as CSV or MAT files🔗

Note

This feature is available only for Modelon Impact Stable 1.6.0 and above.

To download the simulation result, select the Result, click and select either Download result (.mat) or Download result (.csv) (see figure) and follow the instructions.

Download results

Download CSV files🔗

The CSV file downloaded contains the time and variable vectors as columns. The top rows contain variable names and units and the following rows the values, where the values contain dots as decimal separators. Commas separate the columns.

Download MAT files🔗

The MAT file downloaded is a binary file that can be opened in MATLAB without special handling.

MATLAB MATv4 file format🔗

This result file format conforms to the MATLAB Level 4 MAT file specification as described in the MATLAB documentation. Tools such as MATLAB, Octave, Scilab and SciPy can read it. Modelon Impact writes these files in a form that allows tools like Dymola and DyMat to understand them as well.

Variables

Aclass

  • Aclass(1, :): always Atrajectory

  • Aclass(2, :): = 1.1

  • Aclass(3, :): empty

  • Aclass(4, :): either binTrans or binNormal

Most important here is Aclass(4,:), because the file can also be stored transposed. If Aclass(4,:) is binTrans, then all matrices must be transposed, since the file has not been transposed to read it efficiently. This affects all matrices, even those that do not change during simulation (such as name and description).

name

This is a n x m character (int8) matrix, where n is the number of variables stored in the result-file (including time) and m is the length of the longest variable. Modelon Impact uses spaces for the trailing part.

description

This is also a n x m character (int8) matrix containing the comment-string corresponding to the variable in the name matrix.

dataInfo

This n x 4 integer matrix contains information for each variable, in the same order as the name and description matrices.

  • dataInfo(i,1): = 1 or 2 -> if variable i is stored in the data_1 or data_2 matrix. If it's 0, then it's the abscissa (time variable).
  • dataInfo(i,2): contains the index in the data_1 or data_2 matrix. The index is 1-based and may contain several variables pointing to the same row (alias variables). A negative value means that the variable is a negated alias variable.

data_1
If this is a n x 1 matrix, it contains the values of parameters. If it is a n x 2 matrix, the first and second column identify start- and stopvalues.

data_2
Each row contains the values of a variable at the sampled times. The corresponding time stamps are stored in data_2(1,:). data_2(2,1) is the value of some variable at time data_2(1,1).

Note

If a user enables the dynamic_diagnostics option, diagnostic data and results are also stored in the MAT file. Two different time series are then used for this, which leads to a certain complexity. Please take this into account when using the files, as this differs from the format specified above.