Array bounds exceeded
Diagnostic action to take when S-function writes beyond array bounds assigned in allocated memory
Model Configuration Pane: Diagnostics / Data Validity
Description
The Array bounds exceeded parameter specifies the diagnostic action to take when an S-function writes to memory locations that are not allocated for the block. Writing outputs, states, or work vectors outside of the memory allocated for the block indicates a bug in the S-function. For more information, see Handle Errors in S-Functions.
Setting this parameter to a value other than none degrades simulation performance. Set the parameter value to warning or error only to debug an S-function in your model.
The software ignores this parameter for referenced models that simulate in accelerator mode. You can use the Model Advisor to check for diagnostic parameters that are ignored for referenced models that simulate in accelerator mode.
Settings
none (default) | warning | errornoneThe software does not issue a diagnostic.
warningThe software issues a warning.
errorThe software issues an error and terminates the simulation.
Recommended Settings
| Application | Setting |
|---|---|
| Debugging | warning |
| Traceability | No impact |
| Efficiency | none |
| Safety precaution | No impact |
Programmatic Use
Parameter:
ArrayBoundsChecking |
| Type: string | character vector |
Values:
"none" | "warning" |
"error" |
Default:
"none" |
Version History
Introduced in R2006a