Create a Results File

Capture and review simulation results including the signals of all the blocks in a model.

  1. On the ribbon, select Simulation > Output:
    The Output File Parameters dialog appears with options to create and define a results file.
  2. Select Create results file.
    Note: A notice icon is displayed on the ribbon when this option is selected. For convenience, if you wish to disable the option, you can click the icon rather than deslecting the option from the dialog.

  3. Select the file location for the results:
    • Same directory as model file. Select this option to save the file in the current model directory. The file is automatically named with the model name.
    • Enter a file name and directory. Specifiy the file name and path.
  4. Optional: Select View results file to automatically launch the Results File Viewer and open the .mtsf file after the simulation is completed. You can also view the file from Tools > Results Viewer.
    Note: A notice icon is displayed on the ribbon when this option is selected. For convenience, if you wish to disable the option, you can click the icon rather than deslecting the option from the dialog.

  5. Optional: Select Create profiling file to generate a .csv file in the model's temporary directory when the simulation is run. The .csv file contains the flag information for the simulation blocks.
  6. Select OK.

Results Viewer

The Results File Viewer lets you visualize the data from the .mtsf files that are generated when you run a simulation after selecting the Create results file option in the Simulation Preferences.

On the ribbon, select the Tools > Results Viewer, then navigate to a .mtsf file to do the following:

  • Gain access to all of the signals in a model.
  • Plot any signal in the model hierarchy such as results vs. time.
  • Plot multiple signals on the same plot. For example, view a signal before entering and after exiting a block.
  • View results files from two iterations and plot the files together to assess how modifications in a given iteration affect the simulation results.
  • Right-click to open a context menu, then select from the options to show, hide or modify the plot legend and tooltip display.

    The Results Viewer lets you display the values of all blocks, including the Modelica blocks. Since Modelica blocks are processed by the Modelica Compiler, they appear in the Blocks pane of the Results Viewer in a branch starting with the prefix FMU_.

    Similarly, any FMU blocks included in your model are displayed in the FMU_ branches in the Results Viewer tree.

Figure 1. Simulation Results for a Control Plant Model Displayed in the Results Viewer


Figure 2. Simulation Results for the ActiveRC Demo Model with Modelica/Electrical Components Displayed in the Results Viewer