Vocabularymath.
matricesInputsOutputsWord descriptionNegate (invert the sign) of every element in the matrix. The resulting matrix is called the
additive inverse of the input matrix.
Notes• | This word is the companion variant of mabs. |
• | This word is intended for use with "flat" (2-dimensional) matrices. |
• | This word assumes that elements of the input matrix are compatible with the following words: neg ( x -- -x ) |
ExamplesUSING: math.matrices prettyprint ;
{ { 5 9 } { 15 -17 } } mneg .
{ { -5 -9 } { -15 17 } }
Definition