Main Content

Model Multirate Signal Processing Systems Using Dataflow

This example shows how to model multirate signal processing systems using the dataflow subsystem. When you set the domain of a subsystem to dataflow and enable the Automatic frame size calculation parameter, the software calculates the signal sizes of frame-based multirate models and inserts buffers so that the model compiles with no frame size propagation errors.

For more information on dataflow domains, see Dataflow Domain.

  1. To begin, open the model.

    addpath (fullfile(docroot, 'toolbox', 'dsp', 'examples'));
    ex_multistage_filter

    The subsystem of this model contains several rate conversion blocks.

  2. When you update the model diagram, Simulink® generates an error due to a port dimension mismatch in the model. To fix this error, set the domain of the subsystem to dataflow.

  3. If the Property Inspector is not visible, in the Modeling tab, under Design, select Property Inspector.

    With the subsystem selected, in the Execution tab of the Property Inspector, select Set execution domain. Set the Domain to Dataflow.

  4. Select Automatic frame size calculation to have the software automatically calculate frame sizes and insert buffers where needed.

  5. Update the diagram again. The model now updates successfully.

Badges on the model canvas at the input of the subsystem indicate where buffers are inserted.

See Also

Related Topics