Determinant, Magnitude and Inverse Operators |
Keystroke: [|]
|v| or |M|
Returns the magnitude (norm) of a vector, the absolute value of a scalar, or the determinant of a matrix. When evaluated, Mathcad tries to assign the correct functional meaning to the operator, based on the argument. If Mathcad cannot determine the argument (for example, when it is used as part of a function definition), it defaults to the norm, or absolute value, definition. To force the operator to return the determinant, right-click on it, and choose Square Matrix Determinant from the menu.
During numeric evaluation, Mathcad may change the meaning to resolve an error. When this happens, Mathcad updates the selection on the context menu. During symbolic evaluation, Mathcad may change the meaning of the operator as well, but this change is not indicated on the context menu.
Keystroke: [^] [−]1
M [^] [−] 1
Returns the inverse of a matrix. If M does not have an inverse, an appropriate error message appears. To compute the determinant or inverse, Mathcad performs an LU decomposition of the matrix. The BLAS/LAPACK libraries (http://www.intel.com/software/products/mkl/features/lin_alg.htm) from Intel are used.
v is a column vector or a scalar.
M is a dimensionless square matrix.
In these cases, matrix inversion may give an error, or it may give results that are not a genuine inverse matrix, that is, M·M-1 may not be equal to the identity matrix. When matrix inversion fails, you can try the geninv function. If you get invalid results, you can check the strict singularity check box in Worksheet Options, which uses a slower algorithm that rejects matrices that are nearly singular and gives an error.