Added new functions to caching the inverse of the given matrix