Main Content

Initial state is array

Description

Message behavior when the initial state is an array

Category: Diagnostics

Settings

Default: warning

warning

Simulink® software displays a warning when the initial state is an array. If the order of the elements in the array do not match the order in which blocks initialize, the simulation can produce unexpected results.

error

Simulink software displays an error message when the initial state is an array.

none

Simulink software does not display a message when the initial state is an array.

Tips

  • Avoid using an array for the initial state. If the order of the elements in the array does not match the order in which blocks initialize, the simulation can produce unexpected results. To promote deterministic simulation results, use the default setting or set the diagnostic to error.

  • Instead of using array format for the initial state, use a format such as structure, structure with time, or Dataset.

Command-Line Information

Parameter:InitInArrayFormatMsg
Value: 'none' | 'warning' | 'error'
Default: 'warning'

Recommended Settings

ApplicationSetting
DebuggingUse the default setting of warning.
TraceabilityUse the default setting of warning.
EfficiencyUse the default setting of warning.
Safety precautionUse the default setting of warning.

Related Topics