Create Multichannel Frame-Based Signals

Multichannel Frame-Based Signals

When you want to perform the same operations on several independent signals, you can group those signals together as a multichannel signal. For example, if you need to filter each of four independent signals using the same direct-form II transpose filter, you can combine the signals into a multichannel signal, and connect the signal to a single Digital Filter Design block. The block applies the filter to each channel independently.

A frame-based signal with N channels and frame size M is represented by a sequence of M-by-N matrices. Multiple individual frame-based signals, with the same frame rate and size, can be combined into a multichannel frame-based signal using the Simulink® Matrix Concatenate block. Individual signals can be added to an existing multichannel signal in the same way.

Create Multichannel Signals Using Concatenate Block

You can combine existing frame-based signals into a larger multichannel signal by using the Simulink Concatenate block. All signals must have the same frame rate and frame size. In this example, a single-channel frame-based signal is combined with a two-channel frame-based signal to produce a three-channel frame-based signal:

  1. Open the Matrix Concatenate Example 3 model by typing

    ex_combiningfbsigsex_combiningfbsigs

    at the MATLAB® command line.

  2. Double-click the Signal From Workspace block. Set the block parameters as follows:

    • Signal = [1:10;-1:-1:-10]'

    • Sample time = 1

    • Samples per frame = 4

    Based on these parameters, the Signal From Workspace block outputs a frame-based signal with a frame size of four.

  3. Save these parameters and close the dialog box by clicking OK.

  4. Double-click the Signal From Workspace1 block. Set the block parameters as follows, and then click OK:

    • Signal = 5*ones(10,1)

    • Sample time = 1

    • Samples per frame = 4

    The Signal From Workspace1 block has the same sample time and frame size as the Signal From Workspace block. When you combine frame-based signals into multichannel signals, the original signals must have the same frame rate and frame size.

  5. Double-click the Matrix Concatenate block. Set the block parameters as follows, and then click OK:

    • Number of inputs = 2

    • Mode = Multidimensional array

    • Concatenate dimension = 2

  6. Run the model.

    The 4-by-3 matrix output from the Matrix Concatenate block contains all three input channels, and preserves their common frame rate and frame size.

Was this topic helpful?