# Problem related to the ring $\mathbb Z[\sqrt{d}]$

Let $d \in \mathbb Z$ and let $\sqrt{d} \in \mathbb C$ be a square root of $d$. Consider the subring of $\mathbb C$, $$\mathbb Z[{d}]=\{a+b\sqrt{d}: a,b \in \mathbb Z \}$$ and we define the norm of an element in $\mathbb Z[\sqrt{d}]$ by $N(a+b\sqrt{d})=a^2-db^2$.

Prove the following:

1) $z \in \mathbb Z[\sqrt{d}]$ is a unit if and only if $N(z)=\pm1$.

2) The ring $\mathbb Z[\sqrt{d}]$ is prefactorial, i.e., every non zero element which is not a unit can be written as product of irreducible elements.

I'll write what I could do:

1) Suppose $N(z)=\pm 1$, where $z=a+b\sqrt{d}$. Then $(a+b\sqrt{d})\dfrac{a-b\sqrt{d}}{a^2-b^2d}=1$, so the candidate for $z^{-1}$ is $\dfrac{a-b\sqrt{d}}{a^2-b^2d}$. From here it is clear that if $N(z)=\pm 1 \implies z^{-1} \in Z[\sqrt{d}]$. I couldn't prove the other implication.

I don't know what to do in 2), I would appreciate suggestions.

• Prove that $N(z\cdot w) = N(z)\cdot N(w)$. That helps a lot for all parts. Commented Nov 6, 2014 at 22:15
• $1=N(1)=N(z)N(z^{-1})$, since $N(z) \in \mathbb Z$, from that equation it follows $N(z) \in \mathcal U(\mathbb Z)$ iff $N(z)=\pm 1$. I will think 2) some more, thanks! Commented Nov 6, 2014 at 22:22

The proof for 2) is very similar to the analogous theorem in $\mathbb{Z}$. Consider the set $S= \{x \mid x\text{ cannot be written as a product of irreducibles}\}$. Suppose the set is non-empty and notice that $\{|N(x)| \mid x\in S\}$ is a subset of $\mathbb{N}$ so you can use the Well-Ordering princple to choose a least element. Note that the least element that you pick can factor into two numbers that are strictly less than it (otherwise it would not be in the set).

Can you find the contradiction from there?

• I have some doubts: $S=\{N(x): x \in S\}$ is not necessarily a subset of $\mathbb N$, it is of $\mathbb Z$, but maybe I can consider the absolute value of $N(x)$ to fix that problem. As you say, I can pick the least element, say $|N(y)|$, if $|N(y)|$ is $\pm 1$ or a prime, then $y$ is a unit or irreducible (I've just proved this), which is absurd. Then, by the fundamental theorem of arithmetic, $|N(y)|=ab$, where $a,b$ are primes or composites. I don't know how to deduce that $y$ is product of irreducibles from here. Commented Nov 6, 2014 at 22:55
• @user16924 Sorry, adding an absolute sign fixes things. Perhaps I should have been more clear about which set you are choosing from. You are choosing $x\in S$ such that $|N(x)|$ is as small as possible. Since $x$ is not irreducible then you can factor $x$ as $x=ab$ where both $a$ and $b$ are strictly less than $x$ (and thus not in $S$). Then $a$ and $b$ can be written as a product of irreducibles. Hopefully that clears things up. Commented Nov 6, 2014 at 23:04
• Thanks for the edition and all the help, now I understand your solution except for one thing: by assumption $x$ is not a product of irreducibles but how do you know that $x$ can be written as product $x=ab$? (btw, when you say $a$ and $b$ are strictly less than $x$ you mean that $|N(a)|<|N(x)|$ and $|N(b)|<|N(x)|$, right? Commented Nov 6, 2014 at 23:15
• @user16924 By our assumption, $x$ is not irreducible itself and $x$ cannot be written as a product of irreducibles so $x$ can be written as a product $ab$ where neither $a$ or $b$ are equal to $x$ (since $x$ is not irreducible). If you are unconvinced or would like more rigour you can try to prove that every element element of $\mathbb{Z}[\sqrt{d}]$ has a prime divisor. And yes, I mean $|N(a)|<|N(x)|$ and $|N(b)| < |N(x)|$ when I say strictly less than. Commented Nov 6, 2014 at 23:29

Observe or show, as noted in a comment, that $N(\cdot)$ is compatible with multiplication (you can do this "by hand" or better using properties of complex numbers you know) and that $N(z)$ is always an integer.

Then for 1. you can show that if $z$ is invertible, then $N(z)$ must be invertible (in the integers).

For 2. you could proceed by induction on $N(z)$ or establish a link between product decompositions of $z$ and $N(z)$.