Let $U$ be an orthogonal matrix consisting of eigenvectors of $AA^{T}$, and $V$ be an orthogonal matrix consisting of eigenvectors of $A^{T}A$. Here $A$ is an $m\times n$ matrix which has rank $r$.
I want to show that $\operatorname{rank}(AA^{T})=\operatorname{rank}(A^{T}A)$. It says that since $\dim(N(AA^{T}))=m-r$, we can find independent $u_1,\ldots,u_m$ from $N(AA^{T})$ such that $U=[u_1 \ldots u_m]$ is orthogonal.
But I can't understand why $\dim(N(AA^{T}))=m-r$ guarantees there exist $m$ independent column vectors and that the matrix $U$ is orthogonal.
I studied rank theorem before but a little confused in here.