Main Content

Smoothing (fast->slow)

Apply output smoothing when connecting fixed-step networks with different step sizes

Since R2022a

  • Smoothing (fast->slow) block

Simscape / Utilities / Network Couplers / Fundamental Components



Prediction and smoothing algorithms are built into the Network Coupler blocks, and you can enable them by using the check boxes in the block dialogs. The prediction and smoothing blocks in the Fundamental Components sublibrary are provided for your reference only.

When network with faster sampling (Network 1) has high-frequency activity above what the slower network (Network 2) can sample, applying smoothing to the output of Network 1 can sometimes be advantageous because it helps you avoid picking a local peak or trough of the Network 1 activity. The Smoothing (fast->slow) block provides an averaged value of the Network 1 output to Network 2. The block implementation is a masked subsystem shown in the first block diagram. The second diagram shows the contents of the For Each subsystem in the first diagram.

Smoothing (fast->slow) subsystem diagram

For Each subsystem diagram

The smoothing works by averaging the last N samples. You specify N by using the Number of samples over which to smooth parameter.



expand all

Connect this port to the faster network, Network 1, to capture its output.


expand all

Connect this port to the input of the slower network, Network 2.


expand all

Specify the number of samples for averaging the output of the faster network, Network 1.

Specify sample time for the faster network, Network 1, in seconds.

Specify initial output value for the faster network, Network 1.

Extended Capabilities

C/C++ Code Generation
Generate C and C++ code using Simulink® Coder™.

Version History

Introduced in R2022a

expand all