Help with this problem in number theory $$xy = z^{2} + 1, (x, y, z) \in \mathbb{N}$$
Prove that there exists integers $$a, b, c, d$$ such that $$x = a^2 + b^2, y = c^2 + d^2, z = ac + bd$$
Could someone give me a hint on how to go about this? I've tried factorising with the equations given and simplifying, but the best I can do is proving with example and can't prove a general case :S 
Thanks very much.
 A: Detailed Hint: As Calvin Lin has pointed out, the proof of this fact (implicitly) relies on the properties of the Gaussian Integers
, in particular, it uses the fact that $\mathbb{Z}[i]$ is a 
Unique factorization domain

 and has prime elements:


*

*$p\in\mathbb{N}$ where $p\equiv 3$(mod 4)

*$a+bi$, $a,b\in\mathbb{Z}$, where $a^2+b^2\equiv 1$(mod 4), and $a^2+b^2$ is a prime number in $\mathbb{N}$

*$1+2i$ (up to multiplication by units $1,-1,i,-i$)


This effectively gives us an analagous structure to the Gaussian Integers that the Fundamental Theorem of Arithmetic gives to Natural numbers (allows us to break into 'prime' elements), so we can now consider divisors of the RHS of the equation.
Back to the question, we can express the RHS as $(z-i)(z+i)$, and deduce properties about the prime element divisors of $z-i$ and $z+i$. 
A: \begin{align}
   (a^2+b^2)(c^2+d^2)
   &= (ac)^2 + (bd)^2 + (ad)^2 + (bc)^2 \\
   &= (a^2 c^2 + 2abcd + b^2 d^2) + (a^2 d^2 - 2abcd + b^2 c^2) \\
   &= (ac+bd)^2 + (ad-bc)^2
\end{align}
