# Showing when quadratic integer rings are isomorphic

## Homework Statement

Let ##a,b## be squarefree integers and set ##R = \mathbb{Z}[\sqrt{a}]## and ##S = \mathbb{Z}[\sqrt{b}]##. Prove that

a) There is an isomorphism of abelian groups ##(R,+) \cong (S,+)##.

b) There is an isomorphism of rings ##R\cong S## if and only if ##a=b##.

## The Attempt at a Solution

a) Proof: Let ##\varphi : R \to \mathbb{Z} \times \mathbb{Z}## be a map of groups such that ##\varphi(x+y\sqrt{a}) = (x,y)##. This is a homomorphism since if ##x+y\sqrt{a}, w+z\sqrt{a} \in R##, then $$\varphi ((x+y\sqrt{a}) + (w+z\sqrt{a})) = \varphi((x+w) + (y+z)\sqrt{a}) = (x+w,y+z) = (x,y)+(w,z) = \varphi(x+y\sqrt{a}) + \varphi(w+z\sqrt{a}).$$

Now, let ##x+y\sqrt{a}\in \ker(\varphi)##. Then ##\varphi(x+y\sqrt{a}) = (x,y) = 0##, which is true if and only if ##x=0## and ##y=0##, i.e. ##x+y\sqrt{a} = 0##, and so the kernel is trivial, and the map is injective.

The map is certainly surjective since ##\varphi(x+y\sqrt{a}) = (x,y)##, and ##(x,y)## is a general element of ##\mathbb{Z} \times \mathbb{Z}##. Hence ##R \cong \mathbb{Z} \times \mathbb{Z}##.

Note that this proof did not depend on the value of ##a##, only that it was squarefree. Hence we also have that ##S \cong \mathbb{Z} \times \mathbb{Z}##, and so ##R \cong S## as groups under addition.

b) I think that the proof for a) is correct, but I am not sure where to start here. Clear if ##a=b##, then ##R\cong S##, so it is the other direction that I am confused by. How should I get started with this direction?

fresh_42
Mentor
b) I think that the proof for a) is correct, but I am not sure where to start here. Clear if ##a=b##, then ##R\cong S##, so it is the other direction that I am confused by. How should I get started with this direction?
Always start with what you have. No assumptions, not jumping to conclusions, just a gathering of facts.

So let's assume we have an isomorphism ##\varphi\, : \,R=\mathbb{Z}[\sqrt{a}] \longrightarrow \mathbb{Z}[\sqrt{b}] =S##.
I would start to find out, what ##\varphi(\sqrt{a})## can possibly be. Once we know that, we can consider ##\varphi((x+y\sqrt{a})\cdot (u+v\sqrt{b}))##.

We already know that ##\varphi(0)=0## and ##\varphi(1)=1## because both rings are integral domains. We also know, that ##(\sqrt{a})^2-a=0##.

Always start with what you have. No assumptions, not jumping to conclusions, just a gathering of facts.

So let's assume we have an isomorphism ##\varphi\, : \,R=\mathbb{Z}[\sqrt{a}] \longrightarrow \mathbb{Z}[\sqrt{b}] =S##.
I would start to find out, what ##\varphi(\sqrt{a})## can possibly be. Once we know that, we can consider ##\varphi((x+y\sqrt{a})\cdot (u+v\sqrt{b}))##.

We already know that ##\varphi(0)=0## and ##\varphi(1)=1## because both rings are integral domains. We also know, that ##(\sqrt{a})^2-a=0##.

Here is some of my reasoning.

If ##\varphi (1) = 1##, then ##\varphi (a) = a##, since ##\varphi## is a homomorphism, and ##a## is just an integer.

Now, suppose that ##\varphi (\sqrt{a}) = r + s\sqrt{b}## for some ##r,s\in \mathbb{Z}##. Then, squaring both sides, we get ##\varphi (\sqrt{a})^2 = r^2 + 2rs\sqrt{b} + bs^2##. Now we can use the homomorphism property to put the square inside, so that ##\varphi (a) = r^2 + 2rs\sqrt{b} + bs^2##, and so ##a= r^2 + 2rs\sqrt{b} + bs^2##. We have to somehow eliminate the ##\sqrt{b}## term on the RHS, since the LHS is just an integer, and we can do this in two ways: either ##s=0## or ##r=0##. In the first case we get that ## a = r^2##, and in the second case we get ##a=bs^2##, but I'm not exactly sure what to do with either of these equations, or whether I am on the right track or not...

fresh_42
Mentor
If ##\varphi (1) = 1##, then ##\varphi (a) = a##, since ##\varphi## is a homomorphism, and ##a## is just an integer.
O.k., let me see.

##\varphi(a)=\varphi(1\cdot a)=\varphi(1)\cdot \varphi(a) \Longrightarrow 0=\varphi(a)\cdot (1-\varphi(1)) \stackrel{(*)}{\Longrightarrow} 1=\varphi(1)##
##(*)## since ##0 \neq S## is an integral domain and thus ##\varphi(a)=\underbrace{\varphi(1)+\ldots +\varphi(1)}_{a\text{ times }}=\underbrace{1+\ldots +1}_{a\text{ times }}=a\,.##

Now, suppose that ##\varphi (\sqrt{a}) = r + s\sqrt{b}## for some ##r,s\in \mathbb{Z}##. Then, squaring both sides, we get ##\varphi (\sqrt{a})^2 = r^2 + 2rs\sqrt{b} + bs^2.## Now we can use the homomorphism property to put the square inside, so that ##\varphi (a) = r^2 + 2rs\sqrt{b} + bs^2,## and so ##a= r^2 + 2rs\sqrt{b} + bs^2.## We have to somehow eliminate the ##\sqrt{b}## term on the RHS, since the LHS is just an integer, and we can do this in two ways: either ##s=0## or ##r=0.## In the first case we get that ##a = r^2,## and in the second case we get ##a=bs^2,## but I'm not exactly sure what to do with either of these equations, or whether I am on the right track or not...
From ##s=0## we get ##\varphi(\sqrt{a})=r## and so ##\varphi^{-1}(r)=r=\sqrt{a}## by the same argument as in the beginning, this time for ##\varphi^{-1}##, but ##\sqrt{a}\notin \mathbb{Z}##.
From ##r=0## we get - as you said - ##a=bs^2##. However, ##a## is squarefree, so ##s=\pm 1##.

O.k., let me see.

##\varphi(a)=\varphi(1\cdot a)=\varphi(1)\cdot \varphi(a) \Longrightarrow 0=\varphi(a)\cdot (1-\varphi(1)) \stackrel{(*)}{\Longrightarrow} 1=\varphi(1)##
##(*)## since ##0 \neq S## is an integral domain and thus ##\varphi(a)=\underbrace{\varphi(1)+\ldots +\varphi(1)}_{a\text{ times }}=\underbrace{1+\ldots +1}_{a\text{ times }}=a\,.##

From ##s=0## we get ##\varphi(\sqrt{a})=r## and so ##\varphi^{-1}(r)=r=\sqrt{a}## by the same argument as in the beginning, this time for ##\varphi^{-1}##, but ##\sqrt{a}\notin \mathbb{Z}##.
From ##r=0## we get - as you said - ##a=bs^2##. However, ##a## is squarefree, so ##s=\pm 1##.
So am I done, since what I wanted to show was that ##a=b##? (And given that is there a way to eliminate the ##s=-1## case?)

fresh_42
Mentor
So am I done, since what I wanted to show was that ##a=b##? (And given that is there a way to eliminate the ##s=-1## case?)
That's easy to check, isn't it. Is ##\varphi(x+y\sqrt{a})=x-y\sqrt{b}## a ring isomorphism or not? My guess is, it is, so they are two possibilities, but I haven't done the math. But ##\mathbb{Z}[\sqrt{a}]=\mathbb{Z}[-\sqrt{a}]## is strong evidence.

Mr Davis 97
That's easy to check, isn't it. Is ##\varphi(x+y\sqrt{a})=x-y\sqrt{b}## a ring isomorphism or not? My guess is, it is, so they are two possibilities, but I haven't done the math. But ##\mathbb{Z}[\sqrt{a}]=\mathbb{Z}[-\sqrt{a}]## is strong evidence.
So would the following be a complete solution to part b)?

The reverse direction is easy, since if ##a=b## then by the reflexive property of isomorphisms, ##\mathbb{Z}[\sqrt{a}] \cong \mathbb{Z}[\sqrt{b}]##, so we will focus on the other direction. Suppose that ##\mathbb{Z}[\sqrt{a}] \cong \mathbb{Z}[\sqrt{b}]##. We want to show that ##a=b##. Let ##\phi : R \to S## be an isomorphism. Since both ##R## and ##S## are integral domains, we know that ##\phi (1) = 1##. Hence we then know that ##\phi(a)=\underbrace{\phi(1)+\ldots +\phi(1)}_{a\text{ times }}=\underbrace{1+\ldots +1}_{a\text{ times }}=a\,##. Now, suppose that ##\varphi (\sqrt{a}) = r + s\sqrt{b}## for some ##r,s\in \mathbb{Z}##. Then, squaring both sides, we get ##\varphi (\sqrt{a})^2 = r^2 + 2rs\sqrt{b} + bs^2##. Now we can use the homomorphism property to put the square inside, so that ##\varphi (a) = r^2 + 2rs\sqrt{b} + bs^2##, and so ##a= r^2 + 2rs\sqrt{b} + bs^2##. We have to somehow eliminate the ##\sqrt{b}## term on the RHS, since the LHS is just an integer, and we can do this in two ways: either ##s=0## or ##r=0##. In the first case we get that ##a = r^2##, and in the second case we get ##a=bs^2##. If ##a=r^2##, then ##\phi (\sqrt{a}) = r##, and so ##\phi^{-1}(r) = \sqrt{a}##. But this is a contradiction since ##\phi^{-1}## is a homomorphism and so must map to another integer. So we must have that ##a=bs^2##. But it was given that ##a## is squarefree, so it must be the case that ##s =\pm 1##. Either way, we have that ##a=b##.

fresh_42
Mentor
So would the following be a complete solution to part b)?

The reverse direction is easy, since if ##a=b## then by the reflexive property of isomorphisms, ##\mathbb{Z}[\sqrt{a}] \cong \mathbb{Z}[\sqrt{b}]##, so we will focus on the other direction. Suppose that ##\mathbb{Z}[\sqrt{a}] \cong \mathbb{Z}[\sqrt{b}]##. We want to show that ##a=b##. Let ##\phi : R \to S## be an isomorphism. Since both ##R## and ##S## are integral domains, we know that ##\phi (1) = 1##. Hence we then know that ##\phi(a)=\underbrace{\phi(1)+\ldots +\phi(1)}_{a\text{ times }}=\underbrace{1+\ldots +1}_{a\text{ times }}=a\,##. Now, suppose that ##\varphi (\sqrt{a}) = r + s\sqrt{b}## for some ##r,s\in \mathbb{Z}##. Then, squaring both sides, we get ##\varphi (\sqrt{a})^2 = r^2 + 2rs\sqrt{b} + bs^2##. Now we can use the homomorphism property to put the square inside, so that ##\varphi (a) = r^2 + 2rs\sqrt{b} + bs^2##, and so ##a= r^2 + 2rs\sqrt{b} + bs^2##.
The last three occurrences of ##\varphi## should probably be ##\phi##.
We have to somehow eliminate the ##\sqrt{b}## term on the RHS, since the LHS is just an integer, and we can do this in two ways: either ##s=0## or ##r=0##. In the first case we get that ##a = r^2##, and in the second case we get ##a=bs^2##. If ##a=r^2##, then ##\phi (\sqrt{a}) = r##, and so ##\phi^{-1}(r) = \sqrt{a}.##
I wouldn't use this, as it looks like taking the square root, and I don't see at once that this is without trouble, resp. further argumentation. You can either use that ##a## is squarefree so it can't be equal to ##r^2##, or directly that by ##s=0## we have ##\phi(\sqrt{a})=r## and thus ##\phi^{-1}(r)=r=\sqrt{a}## by the previous argument, that all integers are fix points of ##\phi## and accordingly of ##\phi^{-1}## which also leads to the squarefree-ness of ##a## in a way.

I don't immediately get your argument: ##\phi(\sqrt{a})^2=r^2 \Longrightarrow \phi(\sqrt{a})=r## why this has to be true. Theoretically there can be plenty of elements which squared resulted in ##a## or ##\phi(a)##. And even if it was only ##r##, there is still the ##-r## case to be mentioned. Saying ##a=r^2 \in \mathbb{Z}## can't be, since ##a## is squarefree is much easier.
But this is a contradiction since ##\phi^{-1}## is a homomorphism and so must map to another integer. So we must have that ##a=bs^2##. But it was given that ##a## is squarefree, so it must be the case that ##s =\pm 1##. Either way, we have that ##a=b##.
So the only thing I didn't understand was "If ##a=r^2## then ##\phi(\sqrt{a})=r.##"
If you had written "If ##s=0## then ##\phi(\sqrt{a})=r##" everything would have been perfect. Except the "##\varphi##" typo of course.

Mr Davis 97