Prove if $z \in \mathbb{Z}{[i]}$ such that $N(z)$ is a prime number then $z$ is irreducible. Let $N:\mathbb{Z}{[i]} \rightarrow \mathbb{Z}$ be defined as $N(a+bi)= a^2+b^2$. Prove  if $z \in \mathbb{Z}{[i]}$ such that $N(z)$ is a prime number then $z$ is irreducible.
I understand that by definition of function $N$ that the result of $N(z)= \text{prime}$. I also know that due to ring structure primes and irreducibility are related but not the same thing. How do I formally show that $z=ab$ for $a,b \in \mathbb{Z}{[i]}$ implies that either $a$ or $b$ is a unit?
 A: Suppose that you have $ z=uv $, then $ N(z)=N(u) N(v) $, since $ N(z) $ is prime by hyphotesis, we get that either $ N(u) $ or $ N(v) $ is equal to $1$. Wlog, suppose that $ N(v)=1$, so if we write $ v=c+di $, we get $ c^2+d^2=1$. From that is easy to deduce that $ v $ is a unit. Therefore $ z $ is irreducible.
A: Hint $ $  If $\,x\mapsto  Nx\, $ is $\rm\color{#c00}{multplicative}$ and $\,\color{#0a0}{x\mid Nx}\,$ then $\,Na$ irreducible $\,\Rightarrow\, a$ irreducible, since
$\ \ a = bc\,\color{#c00}\Rightarrow\, Na = Nb\, Nc,\ $ so $\,Nb\,$ or $\,Nc\,$ is a unit, say $Nc.\,$ Then $\,\color{#0a0}{c\mid Nc}\mid 1$ so $\,c\,$ is unit. 
Yours is special case $Na = aa' = $ norm of $a$
Remark $ $ The key idea is that multiplicative maps preserve multiplicative properties (which is brought to the fore in divisor theory). Above we pullback the "atom" (irreducible) property  along the multiplicative norm map $\,N$. 
In fact much of the multiplicative structure of a number ring is reflected in its monoid of norms. For example, in many favorable contexts (e.g. Galois) a number ring enjoys unique factorization iff its monoid of norms does. See this answer for further discussion, including literature references (Bumby and Dade, Lettl, Coykendall).
