Matrix inverse cache functions written