Make IMatrix interface more generic, to N dimensions.