Update cachematrix.R

Original file forked from rdpeng repository and edited for programming assignment 2 - rprog