If $A^2 = A$ then $A$ is diagonalizable I've stumbled upon this question in my assignment:

Prove if $A_{nxn}(\mathbb C)$ with $A^2 = A$, then $A$ is diagonalizable

My first thought is to solve for $p(A)$ where $p(x)  = x^2 - x$ and you get real roots.
Would that be sufficient in showing that $A$ is diagonalizable given you get real roots?
 A: Note that if $A=0$ or $A=I$ then $A$ is trivially diagonalizable. Otherwise, $x(x-1)$ must be the minimal polynomial of this matrix. And there is a known theorem which states that a matrix is diagonalizable if and only if its minimal polynomial splits into a product of distinct linear factors. 
A: If you want to do it without the "known theorem", let $N$ be the null space (=kernel) of $A$ and $R$ the range (=column space) of $A$.  Note that if $y = A x \in R$, 
$A y = A^2 x = Ax = y $, so $N \cap R = \{0\}$.  Moreover, for any $v \in \mathbb C^n$,
$v - A v \in N$ since $A(v - Av) = Av - A^2 v = 0$.  Thus $v = (v - Av) + Av \in N + R$,
i.e. $v$ is the sum of a member of $N$ and a member of $R$.  
To diagonalize $A$, take  the union of a basis of $N$ and a basis of $R$.
Using the fact that $\mathbb C^n = N + R$ with $N \cap R = \{0\}$, this is easily seen to form a basis of $\mathbb C^n$.  Since $A x = 0$ for $x \in N$ and $A x = x$ for $x \in R$, $A$ is diagonal in this basis, with diagonal entries $0$ corresponding to the basis of $N$ and $1$ corresponding to the basis of $R$.
A: $A^2=A$ means that $\operatorname{col}A$ is a subset of the eigenspace of $1$. Moreover, $\ker A$ is the eigenspace of $0$. Therefore, $\operatorname{col} A\cap \ker A=\{0\}$, which means that $\operatorname{col}A+\ker A=\operatorname{col}A\oplus \ker A$. By rank-nullity, $\operatorname{col}A\oplus \ker A=\Bbb R^n=V_1\oplus V_0$ ($n$ being the size of the matrix).
