# Commutative ring $R$ with no nontrivial idempotents, with a localization $R_r$ with infinitely many idempotents

I am looking for a commutative ring $$R$$ with $$1$$ such that $$R$$ has no idempotents and there exists $$r\in R$$ such that the localization ring $$R_r$$ has infinitely many idempotents.

• What is the relevance of algebraic geometry tag here? Do you have anything in mind which you did not say here? Apr 21, 2020 at 15:44
• @PraphullaKoushik the algebraic geometry tag is often relevant to commutative algebra questions. Here there's an obvious reformulation of the question in terms of affine schemes.
– YCor
Apr 21, 2020 at 16:05
• @YCor Oh. Answer of SashaP also supports your comment.. I can not see immediately the affine scheme version of this question.. I will think little more to see if I can write this in terms of affine schemes $\text{Spec}(R)$.. Apr 21, 2020 at 16:59

Let $$k$$ be a field and take $$R=\{(a_i)\in\prod\limits_{i\in\mathbb{N}}k[t]\mid a_i(0)=a_j(0)\text{ for all }i,j\}$$
An idempotent in this ring has to be sent to $$0$$ or $$1$$ under the map $$R\xrightarrow{(a_i)\mapsto a_i(0)}k$$ hence has to be equal to $$(0,0,...)$$ or $$(1,1,..)$$. However, if we invert $$r=(t,t,t,..)$$ then each of the elements $$(0,\dots,0,t,0,\dots)r^{-1}$$ gives an idempotent in the localization.