In this section some simple matrix algebraic terms are introduced. These terms
are used in the next sections to illustrate and discuss partial
specializations of class templates.  Readers proficient in matrix algebra may
skip this section without loss of continuity.




    A matrix is commonly thought of as a table of some rows and columns,
filled with numbers. Immediately we recognize an opening for using templates:
the numbers might be plain tt(double) values, but they could also be complex
numbers, for which our complex container (cf. section ref(COMPLEX)) might
prove useful. Our class template is therefore provided with a tt(DataType)
template type parameter. It is  specified when a
matrix is constructed. Some simple matrices using tt(double) values, are:
        verb(
    1   0   0           An identity matrix,
    0   1   0           (a 3 x 3 matrix).
    0   0   1

    1.2  0    0    0    A rectangular matrix,
    0.5  3.5  18  23    (a 2 x 4 matrix).

    1   2   4   8       A matrix of one row
                        (a 1 x 4 matrix), also known as a
                        `row vector' of 4 elements.
                        (column vectors are analogously defined)
        )


    Various operations are defined on matrices. They may, for example be
added, subtracted or multiplied. Here we will not focus on these
operations. Rather, we concentrate on some simple operations: computing
marginals and sums.

Marginals are the sums of row elements or the sums of column elements of a
matrix. These two kinds of marginals are also known as, respectively,
em(row marginals) and
em(column marginals).


    itemization(
    it() em(Row marginals) are obtained by adding, for each row,
all the row's elements and putting these (tt(Rows)) sums in corresponding
elements of a (column) vector of tt(Rows) elements.
    it() Column marginals are
obtained by adding, for each column, all the column's elements and putting
these (tt(Columns)) sums in corresponding elements of a (row) vector of
tt(Columns) elements.
    it() The sum of all elements of a matrix can of course be computed as the
sum of the elements of one of its marginals.
    )
    The following example shows a matrix, its marginals, and the sum of its
values:
        verb(
    -------------------------------------
                                row
                matrix          marginals
                ---------
                1   2   3        6
                4   5   6       15
                ---------
    column      5   7   9       21  (sum)
    marginals
    -------------------------------------
        )
