# non-trivial solutions to $x^2=x$ in a ring?

We know that when a ring is an integral domain, we have that:

$$x^2=x \implies x^2-x = 0 \implies x(x-1) = 0$$

Since this is an integral domain, a product giving $0$ forces one of the the terms in the product to be $0$, therefore the solutions are:

$$x=0, x -1 = 0$$

However, what about when we have a ring but that's not an integral domain, can we find solutions to this equations such that neither of the two terms are $0$?

Yep. In $\mathbb{Z}_6$ let $x=3$. Then $x^2 - x = 9-3 = 6 = 0$. Of course $3\neq 0\wedge (3-1)\neq 0$.

It is possible in $\mathbb{Z}_n$, if $n = k(k-1)$ for some $k\in\mathbb{N}$.

This means the ring has a non-trivial idempotent. It corresponds to a decomposition of the ring, let's call it $R$ as a product of rings. If $e$ is such an idempotent, we have $$R\simeq Re\times R(1-e)$$ $e$ and $1-e$ are the units of the rings $Re$ and $R(1-e)$ respectively. W.r.t. the ring $R$, they're orthogonal idempotents. A simple example is the product of two fields.

Topologically, $\DeclareMathOperator{\spec}{Spec}\spec R=\spec(Re)\cup\spec R(1-e)$ is a partition of $\spec R$ in two open sets. We see $\;\spec R\;$ is connected if and only if $R$ has non non-trivial idempotents. bg)

In the domain of non-commutative algebra, the results are analog, but correspond to a decomposition of $R$ as a module. We obtain a ring decomposition if we have central idempotents.

• In case anyone interprets the question in noncommutative context, it should be said that idempotents correspond to module decompositions of $R$, while the ring decompositions correspond to central idempotents – rschwieb Sep 23 '15 at 16:47
• @rschwieb: I'll add that, thanks for explaining. I don't know well non commutative algebra, and I seldom venture on these lands… – Bernard Sep 23 '15 at 16:58

Take $A=A_1\times A_2$ a product of two rings. Then $(1,0)^2=(1,0)$ and $(0,1)^2=(0,1)$.

A Boolean ring is, by definition, a ring in which every element is idempotent. Since any Boolean algebra defines a Boolean rings (and conversely), there are plenty of examples.