cachematrix.R updated for submission.