matrixCache solution