DSP Blockset    

Example: Creating Signals with the DSP Constant Block

The DSP Constant block has the following parameters:

To generate a constant matrix signal, simply enter the desired matrix in the Constant value parameter using standard MATLAB notation. Some common examples of the MATLAB matrix notation are shown below:

As with all numerical parameters, you can also enter any valid MATLAB variable or expression that evaluates to a matrix. See the MATLAB documentation for a thorough introduction to constructing and indexing matrices.

The Interpret vector parameters as 1-D and Frame-based output parameters are discussed following the example below. See the DSP Constant block's reference page for information about the Sample mode and Sample time parameters.

The model below shows five DSP Constant blocks, each generating one of the constant signals listed above. Two of the blocks have nondefault settings for the other parameters: The third block (DSP Constant2) has the Frame-based output check box selected, and the fourth block (DSP Constant3) has the Interpret vector parameters as 1-D check box selected.

In addition to the various output dimensions in the model, you can observe three different kinds of signals:

See Multichannel Signals for more information about the representation of sample-based and frame-based data.


  Creating Signals Using Constant Blocks Creating Signals Using Signal Generator Blocks