invertMatrix
Computes the inverse of a given square matrix.
The method uses a linear system solver to determine the inverse by solving the equation AX = I, where A is the input matrix, I is the identity matrix, and X is the resulting inverse matrix.
Return
A new matrix representing the inverse of the input matrix.
Parameters
m
The square matrix to be inverted. Must have equal number of rows and columns.
Throws
If the input matrix is not square or if it is singular.