Main Content

Detect overflow

Diagnostic action to take when fixed-point constant overflow occurs

Model Configuration Pane: Diagnostics / Type Conversion


The Detect overflow parameter specifies the diagnostic action to take when a fixed-point constant overflow occurs during simulation.


This parameter requires a Fixed-Point Designer™ license.


none (default) | warning | error

Simulink® software takes no action.


Simulink software displays a warning.


Simulink software terminates the simulation and displays an error message.


  • This diagnostic applies only to fixed-point constants (net slope and net bias).

  • Overflow occurs when the Simulink software converts a fixed-point constant to a data type whose range is not large enough to accommodate the ideal value of the constant. The ideal value is either too large or too small to be represented by the data type. For example, suppose that the ideal value is 200 and the converted data type is int8. Overflow occurs in this case because the maximum value that int8 can represent is 127.

  • Fixed-point constant overflow differs from fixed-point constant precision loss. Precision loss occurs when the ideal fixed-point constant value is within the range of the data type and scaling being used, but cannot be represented exactly.

Recommended Settings

DebuggingNo impact
TraceabilityNo impact
EfficiencyNo impact
Safety precautionNo impact

Programmatic Use

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

Version History

Introduced in R2009b