edited cacheMatrix.R