edited cachematrix.R file