Matrices as containers

Matrices are used for other things than describing linear operators. A matrix may hold any kind of data which can be stored in a 2-dimensional table. Common examples are images and pairwise relations such as correlation coefficients, forces, distances, etc.

BBTools is primarily concerned with data when operators are acting on them. Consider an image where the some common editing is wanted, say cropping or sharpenening. Although BBTools can create operators that performs such operations, it does not understand the notion of an image.

To apply the operation the data must be in canonical form, i.e. a vector (usually a column-vector). That is, a data-matrix it must be expanded in terms of a basis before BBTools can do anything with it.

In practice it is necessary to convert between these representations as follows:

The recipe above can be used for any array, regardless of the number of dimensions. We shall use the term hypercube to emphasize that data-matrices and other arrays are the same to BBTools. We could have used a number of different words:

  1. Hypercubes
  2. Multi-dimensional arrays
  3. Data matrices

Matrix categories

We saw in the above that a matrix may represent a linear tranform or simply be a container for data. To confuse matters further, a matrix may also represent a collection of column vectors:

X=[x1, x2, ...]

In this case an operator may be applied en masse:

A*X=[A*x1, A*x2, ...]

It may occasionally be difficult to decide what category a matrix belongs to. From a practical point of view it usually suffice to distinguish between operators and data-arrays.

To recap, in Matlab the word "matrix" is ambigous and can have (at least) the following meanings:

  1. A linear operator
  2. A data-matrix, including