cached inverse matrix in R