MATLAB: What is the significance of the ‘Execute (enter) chart at initialization’ option in the chart properties in Stateflow 6.0 (R13)

chart;defaultenterexecuteinitializationstateflowtransition

This option is briefly explained in the Stateflow documentation page at the following URL:
Please provide more information regarding this option.

Best Answer

This enhancement has been incorporated in Release 2006a (R2006a). For previous product releases, read below for any possible workarounds:
Detailed information on the 'Execute (enter) chart at Initialization' option is missing from the 'Chart Properties' section of the Stateflow documentation.
Here is additional information about this option:
In a chart containing states, turning on the option "Execute (enter) chart at Initialization" causes the default transition paths of the chart
to be executed during the model initialization phase at time t=0.
Due to the transient nature of the initialization phase, it is unsafe to perform the following actions in the default transition paths of the chart (and the associated
state entry actions) for which this option is enabled:
1. Accessing chart input data is unsafe as the blocks connected to Stateflow via input ports have not initialized their outputs yet.
2. Calling exported graphical functions from other charts is unsafe as the other charts may not have been initialized yet.
3. Broadcasting function-call output events is unsafe as the calling subsystems have not been initialized yet.
In Stateflow 6.2 (R14SP2), a warning is thrown for (1) and (2) and an error message is generated for (3).
This option should not be enabled in a chart that does not contain states.