To add to this, if Ax=Iy is true then getting rref([A y]) will result in the augmented matrix [I x] if there is a solution. If the left square matrix is not identity, then you either have infinite number of solutions or no solution at all (depending the elements)