added changes to cacheMatrix