TITLE: Find all values x, y and z which satisfy the equation $(x^2 + 1)(y^2 + 1) = z^2 + 1$ given that $(x^2 + 1)$ and $(y^2 + 1)$ are both primes.
QUESTION [9 upvotes]: Find all positive integers x, y, z which satisfy the equation $(x^2 + 1)(y^2 + 1) = z^2 + 1$ given that $(x^2 + 1)$ and $(y^2 + 1)$ are both primes.
It seems trivial that the only set of integers x, y and z that work are $(1^2 + 1)(2^2 + 1) = 3^2 + 1$, which is equivalent to $2 * 5 = 10$, but how would I go about proving this, or are there any other sets for which the following equation works out?
Thanks in advance.

REPLY [4 votes]: Suppose without loss of generality $x \ge y$. Then $z^2+1 \le (x^2+1)^2$, so $z < x^2+1$. 
Note that $x^2+1 \mid (z^2+1)-(x^2+1)=(z-x)(z+x)$. 
Since $(x^2+1)$ is a prime number and
$$0 < z-x < z+x < x^2+x+1<2(x^2+1),$$
we must have $x+z = x^2+1$ and $z-x=1$, from which we obtain $x=2$, and then $z=3, y=1$.