Update cachematrix.R

Second upload. Needed to fork from rdpeng first before committing...