Main Content

State Explorer

Visualize states in model

Description

Use the State Explorer to view individual state dynamics of your model

Open the State Explorer

  • Profile the model using the Solver Profiler. Ensure that the Continuous States parameter is enabled.

  • Select States in the Explore section of the Solver Profiler toolstrip.

Examples

expand all

This example shows how to use State Explorer to explore Newton Exceptions.

To begin, open the model BouncingBallWithSwitch, click Debug, open the drop down menu of Performance Advisor, select Solver Profiler.

Enable the Continuous States parameter in the Configure section of the toolstrip and run Solver Profiler.

When profiling has completed, open State Explorer. Select Newton/DAE Exception in the Filter section of the State Explorer toolstrip.

The State Explorer shows plots of Newton/DAE Exceptions in the profiling simulation for a model named ex_spi_show_zc.

There is an increase in the density of Newton exceptions through the simulation. Zoom in on the State plot between the 5 and 6 second mark.

The plots of the Newton/DAE exceptions in State Explorer are zoomed to show the data between 5 and 6 seconds.

A closer examination reveals that each bounce causes two Newton iterations to switch from positive to negative corresponding to two zero crossing events. For more details, see Interactively Explore Zero Crossings. Around 5.48 seconds, the bouncing ball being simulated in the model comes to ‘rest’, hence the isolated single Newton iteration exception.

Version History

Introduced in R2016a