TITLE: Show if these Gaussian integers are irreducible or not
QUESTION [7 upvotes]: Gaussian integers are the set $\mathbb{Z}[i]$ such that $\mathbb{Z}[i] = \{ a + bi | a, b \in \mathbb{Z} \}$. Unique factorisation does hold over the Gaussian integers.
(a) Which of the following are irreducible in $\mathbb{Z}[i]$:  $ 4 , 2, 1+i$ ?
 ( prove that the given element is irreducible or write it as product of two non units.)
(b) Express each of the following elements of  $\mathbb{Z}[i]$ as a product of irreducibles:
i. $6$
ii. $1+3i$
Right for (a) 
$4=2\cdot 2=(1+i)(1+i)$ hence not irreducible
$2=(1+i)(1-i)$.
Suppose that $(a+bi)(c+di) = 1 + i $ for some integers $a,b,c,d$.
Taking conjugates yields $(a-bi)(c-di) = 1 - i.$
Multiply the equations together:
$(a^2 + b^2)(c^2 + d^2) = 2 $
Now, we have an equation in the integers. Since $2$ is prime, we have
$a^2 + b^2 = 1$ and $c^2 + d^2 = 2$ or vice versa.
The first equation implies that $a = \pm1$ and $b = 0$ or $a = 0$ and $b = \pm1$
$\Rightarrow a + bi = \pm1$ or $\pm i$, a unit. The second implies that $c= \pm1$ and $d= \pm1$ hence $c+di=(1-i)$ or $(1+i)$ which are units. So $1+ i$ must be irreducible.
Is that right?
(b) $6=2\cdot3$ from previous results, $ 2=(1+1)(1-i)$ so can be written as product of irreducibles. But what about $3$? How can I show it is irreducible?
$1+3i=(1+i)(2+i)$.
$1+i$ is an irreducible, as previously shown. 
Is $2 +i$, too?

REPLY [4 votes]: There are a few facts that are useful here.
One is that if the norm of an element is a prime integer, then the element is irreducible in the Gaussian integers. This shows that $1 \pm i$ and $2 \pm  i$ are irreducible. (But note that the converse does not hold; $3$ is irreducible in the Gaussian integers (see below), but has norm $9$.)
The other is that there no elements of norm $\equiv 3 \pmod{4}$; just check that the sum of two squares is congruent to $0, 1, 2$ modulo $4$. This shows that all prime integers which are congruent to $3$ modulo $4$ remain irreducible in the Gaussian integers.