Added Matrix#shrink and corresponding unit-test.