cachematrix functions - adding comments