Refactoring to make getRow and getColumn return primitive vectors for
primitive matrices