improving readability for cachematrix.R