Completed R functions, cached inverse matrix