Implemented Functions for creation and update of matrices with cached inverses