Skip to Main Content Skip to Search
Product Documentation

What Is a SimState?

A SimState is the snapshot of the state of a model at a specific time during simulation. For a Stateflow chart, a SimState includes the following information:

A SimState lists chart objects in hierarchical order:

For example, the following SimState illustrates the hierarchical structure of chart objects.

c = 

  Block:    "shift_logic"    (handle)    (active)
  Path:     sf_car/shift_logic

  Contains:

    + gear_state         "State (AND)"          (active)
    + selection_state    "State (AND)"          (active)
      gear               "Block output data"    double [1, 1]
      down_th            "Local scope data"     double [1, 1]
      up_th              "Local scope data"     double [1, 1]

The tree structure maps graphical and nongraphical objects to their respective locations in the chart hierarchy. If name conflicts exist, one or more underscores appear at the end of a name so that all objects have unique identifiers in the SimState hierarchy.

For information about using a SimState for other blocks in a Simulink model, see Saving and Restoring the Simulation State as the SimState in the Simulink User's Guide.

  


Free Stateflow Interactive Kit

Learn how engineers use Stateflow to model state machines in their Simulink models.


Get free kit

Trials Available

Try the latest version of Stateflow.


Get trial software
 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS