IMatrix and its implementation and unit test.