In MATLAB/Python, is there a way to compare the subspaces span by two different sets of vectors and check if they are the same?
Utilizing the fact that $A$ and $rref(A)$ has the same row space, check if the two matrices (with the given vectors as row vectors) have the same Reduced Row Echelon Form.
Corrected version following a remark of @Quang Hoang
Here is another way :
If the sets of vectors are the columns of $A$ and $B$ resp., check that the new matrix $C=[A,B]$ is such that
Proof: Let $R(M)$ denote the column space of a matrix $M$.
Equality $rank(A)=rank(C)$ implies $R(A)=R(C)$ Equality $rank(B)=rank(C)$, implies $R(B)=R(C)$. Thus $R(A)=R(B)$. Therefore $rank(A)=rank(B)$.