Fixed checking if the given matrix is a reduced basis