Next: , Previous: , Up: Matrix Functions   [Contents][Index]


16.4.2.4 Minimum, Maximum, and Sum Functions

Matrix Function: CMIN (M)
Matrix Function: CMAX (M)
Matrix Function: CSUM (M)
Matrix Function: CSSQ (M)

Returns a row vector with the same number of columns as M, in which each element is the minimum, maximum, sum, or sum of squares, respectively, of the elements in the same column of M.

CMIN({1, 2, 3; 4, 5, 6; 7, 8, 9} ⇒ {1, 2, 3}
CMAX({1, 2, 3; 4, 5, 6; 7, 8, 9} ⇒ {7, 8, 9}
CSUM({1, 2, 3; 4, 5, 6; 7, 8, 9} ⇒ {12, 15, 18}
CSSQ({1, 2, 3; 4, 5, 6; 7, 8, 9} ⇒ {66, 93, 126}

Matrix Function: MMIN (M)
Matrix Function: MMAX (M)
Matrix Function: MSUM (M)
Matrix Function: MSSQ (M)

Returns the minimum, maximum, sum, or sum of squares, respectively, of the elements of M.

MMIN({1, 2, 3; 4, 5, 6; 7, 8, 9} ⇒ 1
MMAX({1, 2, 3; 4, 5, 6; 7, 8, 9} ⇒ 9
MSUM({1, 2, 3; 4, 5, 6; 7, 8, 9} ⇒ 45
MSSQ({1, 2, 3; 4, 5, 6; 7, 8, 9} ⇒ 285

Matrix Function: RMIN (M)
Matrix Function: RMAX (M)
Matrix Function: RSUM (M)
Matrix Function: RSSQ (M)

Returns a column vector with the same number of rows as M, in which each element is the minimum, maximum, sum, or sum of squares, respectively, of the elements in the same row of M.

RMIN({1, 2, 3; 4, 5, 6; 7, 8, 9} ⇒ {1; 4; 7}
RMAX({1, 2, 3; 4, 5, 6; 7, 8, 9} ⇒ {3; 6; 9}
RSUM({1, 2, 3; 4, 5, 6; 7, 8, 9} ⇒ {6; 15; 24}
RSSQ({1, 2, 3; 4, 5, 6; 7, 8, 9} ⇒ {14; 77; 194}

Matrix Function: SSCP (M)

Returns M^T × M.

SSCP({1, 2, 3; 4, 5, 6}) ⇒ {17, 22, 27; 22, 29, 36; 27, 36, 45}

Matrix Function: TRACE (M)

Returns the sum of the elements along M’s main diagonal, equivalent to MSUM(DIAG(M)).

TRACE(MDIAG(1:5)) ⇒ 15


Next: Matrix Property Functions, Previous: Matrix Construction Functions, Up: Matrix Functions   [Contents][Index]