Rotating the matrix.