| DSP Blockset | Search  Help Desk |
Understanding Matrices
One of the most powerful features of the DSP Blockset is its full support of matrix data and matrix operations. Every block in the DSP Blockset that accepts vector inputs also accepts matrix inputs. Additionally, a large number of blocks, including all of those in the Matrix Functions and Linear Algebra libraries, are provided specifically to enable sophisticated matrix-based algorithms. A DSP Blockset matrix is the traditional rectangular array of M rows and N columns used by MATLAB,
[1 2 3;4 5 6] % a 2-by-3 matrix [1 2 3;4 5 6]' % the transpose, a 3-by-2 matrix randn(2,3) % a 2-by-3 matrix with random elements [1:10;-1:-1:-10] % a 2-by-10 matrixSee Chapter 4 of Using MATLAB for a thorough introduction to constructing and indexing matrices. Matrices provide a versatile and efficient way to organize data, and find a variety of uses in DSP Blockset models. For example, you can use the matrix format to represent the state-space realization of a digital filter, or as a container for a collection of experimental measurements. One illustration of creative matrix usage is provided by the factorization blocks in the Linear Algebra library, which package the factors of the input matrix into a single composite output matrix. The output of the LDL Factorization block, for example, is a composite matrix containing the factorized lower triangle, diagonal, and upper triangle, as shown below.

The matrix format is also ideal for the transmission and storage of multichannel signals, which are a common feature in many DSP systems. To facilitate parallel operations on multiple signal channels, the DSP Blockset recognizes two special classes of signal-oriented matrices:
What differentiates these matrices from each other is their contents: Sample-based matrices contain sample-based signals, while frame-based matrices contain frame-based signals. The following sections elaborate on this distinction. See "Understanding Samples and Frames," later in this chapter for a full discussion of signal-oriented matrix usage.