Prove, for real $X$, that $\text{rank}(X^TX)=\text{rank}(X)$.
Could anyone please help me with this problem? I've tried to use full-rank factorization and rank-related theorems mentioned in my book but still failed to solve this. I am learning linear algebra by myself and my book has no solutions manual so I find it really hard to get used to solve linear algebra problems.
Many thanks in advance for your help!
Assume $u$ is in the null space of $\mathbf{X}^T\mathbf{X}$.
Then $\mathbf{X}^T\mathbf{X}u=0 \implies u^T\mathbf{X}^T\mathbf{X}u = u^T0=0$.
Then assume, $u$ is not in the null space of $\mathbf{X}$.
Then $\mathbf{X}u=v$, (notice $u^T\mathbf{X}^T = v^T$).
But $u^T\mathbf{X}^T\mathbf{X}u = 0 \implies v^Tv=0$, which implies $v=\mathbf{X}u=0$.
Thus, $null(\mathbf{X}^T\mathbf{X})\subset null(\mathbf{X})$.
Proving the reverse inclusion is trivial.
So, $null(\mathbf{X}^T\mathbf{X}) = null(\mathbf{X})$.
By the rank and nullity theorem (Nullity of A + Rank of A = Total number of columns in A),
rank$(\mathbf{X}^T\mathbf{X})$ = rank$(\mathbf{X})$.