Revert "Update cachematrix.R"

This reverts commit 47bd49ad893dfff567c4f2042a6ce0340d52f51d.
Revert "Revert "Update cachematrix.R""

This reverts commit d480685827ab0ea6b4e940dee07c6959a618ff51.