Main Content

Simulink® Model Discretizer

This interactive example shows how to discretize the Actuator Model in the slexAircraftExample model. Click Open Model to open the model.

Open the Model Discretizer

To open the Model Discretizer, in the Simulink Editor, on the Apps tab, under Apps, under Control Systems, click Model Discretizer. This opens the Model Discretizer.

The Simulink model window and the Model Discretizer GUI are laid out in the screen for easy navigation.

  • The model tree is shown in the left panel of the Model Discretizer GUI.

  • Discretization parameters are set through the right panel of the Model Discretizer GUI.

  • Discretization status is shown in the lower part of the right panel.

  • By default, only continuous blocks are shown in the Model Discretizer GUI.

  • In the Simulink model window, blocks in red color are continuous blocks.

You can browse through the continuous blocks one by one using the model tree view. In the Simulink Model Discretizer, select the View > Next continuous block. This highlights the Actuator Model.

Before discretizing the Actuator Model block, set the discretization parameters: transform method, sample time, critical frequency. Critical frequency has to be specified if the transform method 'tustin with prewarping' is selected.

After setting the discretization parameters, select Discretize > Discretize current block in the Model Discretizer. Or you can just click the s->z button icon in the tool bar. The discretized Actuator Model is highlighted in blue color in the model.

By default, the Actuator Model was replaced by a discrete block beneath a continuous block dialog, allowing you to continue entering the Actuator Model parameters in the s-domain. In the model window, double-click the Actuator model. Two new fields 'Sample time' and 'Method' were added to the block dialog window. These parameters are used to automatically convert the continuous parameters to equivalent discrete parameters.

Related Topics