Algorithm

Description

Specifies the algorithm to detect zero crossings when a variable-step solver is used.

Category: Solver

Settings

Default: Nonadaptive

Adaptive

Use an improved zero-crossing algorithm which dynamically activates and deactivates zero-crossing bracketing. With this algorithm you can set a zero-crossing tolerance. See Signal threshold to learn how to set the zero-crossing tolerance.

Nonadaptive

Use the nonadaptive zero-crossing algorithm present in the Simulink® software prior to Version 7.0 (R2008a). This option detects zero-crossings accurately, but might cause longer simulation run times for systems with strong “chattering” or Zeno behavior.

Tips

  • The adaptive zero-crossing algorithm is especially useful in systems having strong “chattering”, or Zeno behavior. In such systems, this algorithm yields shorter simulation run times compared to the nonadaptive algorithm. See Zero-Crossing Detection for more information.

Dependencies

  • This parameter is enabled only if the solver Type is set to Variable-step.

  • Selecting Adaptive enables the Signal threshold parameter.

Command-Line Information

Parameter: ZeroCrossAlgorithm
Value: 'Nonadaptive' | 'Adaptive'
Default: 'Nonadaptive'

Recommended Settings

ApplicationSetting
DebuggingNo impact
TraceabilityNo impact
EfficiencyNo impact
Safety precautionNo impact

Related Topics