Updated the functions for caching the Inverse of a Matrix