Written are two functions that store a matrix and cache its inverse