Difference between dimension and rank of matrix Let $A = \left[ {\begin{array}{cc} 1 & 1 & 1 \\ 3 & -1 & 1 \\1 & 5 & 3\\ \end{array} } \right]$ and $V$ be the vector space of all $X\in \mathbb{R^3}$ such that $AX = 0$. Then what is $dim(V)$ ?
Here when I change the matrix into echelon form I get $\left[ {\begin{array}{cc} 1 & 1 & 1 \\ 0 & -4 & -2 \\0 & 0 & 0\\ \end{array} } \right]$, which means that $rank(A) = 2$; we have one free variable and two basic variables; and $dim(null space) = 1$.
So, is the $dim(V) = rank(A) = 2$? or $dim(V)$ = number of elements in basis of null space = $1$?or we apply sylvester's law $(dim = rank + nullity)$ to get $3$??
Which will be correct and why?? Very confused... Thanks..

The null space is a subspace of the original vector space. Observe that the vector space in question is exactly $N(A)$, the null space of $A$. 
As you observed, $rank(A) + null(A) = dim(V)$. So $2 + null(A) = 3$. 
