inverse() and transpose() for matrices