TITLE: Spectrum of idempotent element
QUESTION [7 upvotes]: Let $A$ be some unitary algebra over $\mathbb{C}$. If $a^2=a$ and $0\ne a\ne 1$ then $\{0,1\}\subset \sigma_A(a)$ ($\sigma_A(a)$ is the spectrum if $a$). I believe that also $\sigma_A(a)\subset \{0,1\}$. For examlpe, if $A=\mathbb{C}\times\mathbb{C}\times...\times\mathbb{C}$ with pointwise multiplication then each idempotent is $(\epsilon_1,\epsilon_2,...,\epsilon_n)$ where $\epsilon_i\in \{0,1\}$ and $(\epsilon_1-\lambda,\epsilon_2-\lambda,...,\epsilon_n-\lambda)$ is invertible iff $\epsilon_i\ne \lambda$ i.e. $\lambda\notin \{0,1\}$. Also, if $K\subset \mathbb{R}^2$ is a compact set then the space of continuous functions $A=C(K,\mathbb{C})$ is also a $\mathbb{C}$-algebra and $f$ is idempotent iff $f(K)\subset \{0,1\}$. But $\sigma_A(f)=f(K)$. 
First, I am stuck on to find some easy trick to prove that the spectrum of an idempotent element (not $0$ and not $1$) is $\{0,1\}$. Secondly, this statement is easy for $\mathbb{C}^S$ (this is the algebra of all functions and $\sigma(f)=f(S)$), perhaps there is a nice way to reduce our problem to the case of $\mathbb{C}^S$?

REPLY [4 votes]: Let's consider $f(x)=x-x^{2}$ and $a^{2}=a$, then since  polynomials preserve the spectrum, $f(\sigma(a))=\sigma(f(a)) = \sigma(0) = 0$, so $f(\sigma(a))=0$, then $\sigma(a) = \{0, 1 \}$