Matrix inverse cache implementation