# Looking for an example of a non PIR commutative ring with every ideal two generated

I am looking for an example, with a direct proof, of a commutative ring with unity , which is not a Principal Ideal ring and every ideal is generated by at most $$2$$ elements.

Any example or proof I can think of goes by some non direct theory like coming up with an example of a non PID Dedekind domain and showing every ideal in a Dedekind domain is generated by two elements .. etc.

Can we find an example with a direct and relatively elementary proof ?

• It's more straightforward to choose one that is rank 2 over $\Bbb{Z}$. That way any ideal is also rank 2 over $\Bbb{Z}$, and thus generated by at most two elements. Then if it's not a PID, you are done. Therefore, choose a non PID quadratic integer ring. For example, $\Bbb{Z}[\sqrt{-5}]$. – jgon Nov 8 '19 at 5:00
• @jgon: yeah but how does one show it has rank $2$ ? – user102248 Nov 8 '19 at 5:12
• @jgon: I can't think of a direct, not high-powered, way of showing every ideal of $\mathbb Z[\sqrt {-5}]$ is two generated – user102248 Nov 8 '19 at 5:13
• To show it has rank 2, observe that $1,\sqrt{-5}$ is a free basis. Is there a problem with saying submodules of finitely generated free modules over a PID are free of rank at most the rank of the original module? What is the target audience here? – jgon Nov 8 '19 at 5:15

For a very easy example, let $$k$$ be a field, let $$V$$ be a $$2$$-dimensional vector space over $$k$$, and let $$R=k\oplus V$$ with multiplication defined by $$(a,v)\cdot(b,w)=(ab,bv+aw)$$. Thinking of $$(a,v)$$ as a formal sum $$a+v$$, this is just the multiplication you get by saying $$vw=0$$ for $$v,w\in V$$.

Now suppose $$I\subseteq R$$ is an ideal. Then $$I$$ is generated by any subset which spans it as a $$k$$-vector space. Since $$R$$ is $$3$$-dimensional as a $$k$$-vector space, this automatically means $$I$$ is generated by at most two elements unless $$I=R$$, but if $$I=R$$ then $$I$$ is generated by the single element $$1$$.

On the other hand, $$\{(0,v):v\in V\}$$ is an ideal in $$R$$ that cannot be generated by one element, since any single element will only generate its span in $$V$$ which is not the whole ideal.

(This ring can also be described as the quotient $$k[x,y]/(x^2,xy,y^2)$$, where $$V$$ is spanned by $$x$$ and $$y$$.)

Expanding on my comment

Example: $$R=\Bbb{Z}[\sqrt{-5}]$$

Proof: $$R$$ is free of rank 2 as a $$\Bbb{Z}$$-module, generated by $$1$$ and $$\sqrt{-5}$$. Thus any $$\Bbb{Z}$$-submodule also has rank at most 2. Hence any ideal of $$R$$ has rank at most 2 as a $$\Bbb{Z}$$-submodule, and is thus generated by at most 2 elements.

It just remains to prove that there is an ideal generated by exactly two elements. Note that $$2\cdot 3 =6= (1+\sqrt{-5})(1-\sqrt{-5}).$$ This suggests that the full factorization of 6 ought to be something like $$(2,1+\sqrt{-5})(2,1-\sqrt{-5})(3,1+\sqrt{-5})(3,1-\sqrt{-5}).$$

It suffices to prove that $$(2,1+\sqrt{-5})$$ is not principal. Suppose $$(2,1+\sqrt{-5})=(\alpha)$$. Then $$\alpha \mid 2$$ and $$\alpha \mid 1+\sqrt{-5}$$, so $$N(\alpha)\mid N(2)=4$$ and $$N(\alpha)\mid N(1+\sqrt{-5})=6$$. Thus $$N(\alpha)\mid 2$$. So $$\alpha = a + b\sqrt{-5}$$, and $$N(\alpha) = a^2 + 5b^2 \le 2$$. Hence $$b=0$$ and $$a=\pm 1$$. Thus $$\alpha = \pm 1$$. So the only way it is possible for $$(2,1+\sqrt{-5})$$ to be principal is if it is the unit ideal. However, it is not, since we have $$\Bbb{Z}[\sqrt{-5}]/(2,1+\sqrt{-5}) \cong \Bbb{Z}/(2) \ne 0.$$ The isomorphism is defined by sending $$\sqrt{-5}$$ to $$1$$.

Note

I will edit if you update with a clearer description of the audience, but I think this should be an appropriate explanation for most undergrads with a first course in algebra that covers rings, ideals and the fundamental theorem of finitely generated abelian groups. (Certainly not all first courses in algebra cover these topics, so that's not a given). Let me know how elementary you require, and I'll see what I can do. I have a hard time imagining making it more elementary from here though.

• Yeah, I was hoping not to use that submodules of free module over a PID of finite rank has rank at most that of the module ... but I guess I really can't avoid that .. – user102248 Nov 8 '19 at 5:25
• @user102248 You can make it slightly more elementary if you say free abelian group, since these are $\Bbb{Z}$-modules, but yeah I really am not sure how to avoid something like that. Not without essentially reproving it in a special case. – jgon Nov 8 '19 at 5:27
• A proof that submodules of free $\mathbb{Z}$-modules are free and of rank at most the ambient module is found in this answer: math.stackexchange.com/questions/548552/… – Ben Blum-Smith Nov 8 '19 at 12:14