inverse matrix cache functions