If $S$ is a linear transformation from $\mathbb{R}^2$ to $\mathbb{R}^2$ such that $S \circ S = S$, prove that $S$ can be: We have that $S \circ S = S$, I want to prove that $S$ can be

*

*$S = 0$ (The zero transformation) or

*$S(x) = x$ (The Identity transformation) or

*$S$ can have a basis $A$ such that $[S]_{A}^{A} = \begin{pmatrix}
1 && 0 \\
0 && 0
\end{pmatrix}$
I have that all of the three propositions are True, 3 is like to say that S can be a projection, in this case, over the $x$-axis, 2 can be done by see that $S(x) = S(S(x)) = x$, but what do you think? I try to find more about in the some books (I study for myself, not attending a school for now, but I love math, I try to solve the most, but some are really strange for me) thanks
 A: There are 3 mutually exclusive and exhaustive cases. One is, kernel is of dimension 2 in which case you get the zero operator i.e. S=0, second case,  when kernel is of dimension zero in which case you get the identity operator i.e. S=I and third case,  kernel is of dimension one in which case image is of dimension one and you get the matrix you have given in your third case.
A: If $\text{im}(S)$, the image of $S$, is $0$-dimensional then $S=0$.
If $\text{im}(S)$ is $2$-dimensional then any vector in $\mathbb{R}^2$ can be written as $S(x)$ for some $x\in \mathbb{R}^2$, so the relation $S(S(x))=I(S(x))$ implies that $S=I$.
Consider the final case where $\text{im}(S)$ is $1$-dimensional. We claim there is a non-zero vector which $S$ fixes. Indeed, take an $x\in \mathbb{R}^2$. If $S(x)=x$ we are done. If not, then the relation $S\circ S=S$ implies that $S$ fixes $y=x-S(x)$. Now take any vector in $\mathbb{R}^2$ which is linearly independent of this $S$-fixed vector and you have the basis for the final case.
A: If $S$ is such that $S^2 = S$ then
$$
S^2 - S = 0
$$
and so $S$ is annihilated by the polynomial $x^2 - x = x(x - 1)$. Therefore, the minimal polynomial $\mu_S(x)$ of $S$ divides $x(x - 1)$. This leaves only three possibilities:

*

*$\mu_S(x) = x$ which means that $S = 0$.

*$\mu_S(x) = x - 1$ which means that $S = I$.

*$\mu_S(x) = x(x - 1)$ which means that both $0$ and $1$ are the eigenvalues of $S$ and therefore we have

$$
S = \begin{pmatrix}
1 & 0 \\
0 & 0
\end{pmatrix}
$$
in the eigenbasis of $S$.
A: As others have already pointed out, this is really just a classification of the possible ranks of $S$ ("rank" here meaning the dimension of the image $S(\mathbb{R}^2)$, which can only equal $0,1$ or $2$). Here is a detailed argument that avoids using minimal polynomials:
If $S$ is rank $0$, then $S(\mathbb{R}^2)$ has dimension zero and is hence $\{0\}$, meaning $S$ is the $0$ transformation.
If $S$ is rank $2$, then it is invertible (it has trivial kernel by rank-nullity), so precomposing the equation $S^2 = S$ with $S^{-1}$ gives $S = I$, the identity.
Finally, suppose $S$ is rank $1$. The space $S(\mathbb{R}^2)$ is a subspace of $\mathbb{R}^2$, so take a basis vector $u$ of this subspace. Also note $S(u)=u$ (which can be seen by writing $u=S(x)$ and using $S^2=S$). Since the kernel of $S$ also has dimension $1$, we can pick a basis vector $v$ of this subspace as well. We claim $\{u,v\}$ is a basis of $\mathbb{R}^2$. By dimension it suffices to show $\{u,v\}$ is a linearly independent set. If $\lambda_1u+\lambda_2v=0$, then applying $S$ to this equation gives $\lambda_1u = 0$, so $\lambda_1=0$. But then $\lambda_2v = 0$, so $\lambda_2=0$ as well. This proves the claim.
Finally, put $A = \{u,v\}$. Since $S(u) = (1)u+(0)v$ and $S(v) = (0)u+(0)v$, it has the desired matrix representation
$$[S]_A^A = \begin{bmatrix}1 & 0 \\ 0 & 0\end{bmatrix}.$$
As a final remark: the property $S^2=S$ is called idempotence, and this result generalizes to higher dimension. See, for example, this question.
