# Why can't $x^2+y^2+z^2$ be prime?

If $x,y,z, a$ are non-zero integers such that

$$\frac{x}{z}=\frac{x^2+y^2}{z^2 + a^2}$$

why can't $x^2+y^2+z^2$ be prime? We assume that $x \ne z$.

This seems to hold but I can't see how to prove it.

• 1 + 36 + 4 = 41 which is prime
– Dan
Jan 8, 2014 at 9:58
• @user115998: If there is no restriction on $a$, there would be a lot of counterexamples... Jan 8, 2014 at 10:01

If $\left ( x,y,z,a \right )=\left ( 5,15,1,7 \right )$ then $$\frac{x}{z} = \frac{5}{1} = 5$$ $$\frac{x^2+y^2}{z^2+a^2}=\frac{5^2+15^2}{1^2+7^2}=\frac{250}{50}=5$$ and $$x^2+y^2+z^2 = 5^2+15^2+1^2=251$$
$x^2+y^2=\dfrac{x(z^2+a^2)}{z} \implies z=pq, x=mp,z^2+a^2=nq ,a^2=(n-p^2q)q\implies \\case 1:n=hq \implies x^2+y^2=mhq \implies x^2+y^2+z^2=(mh+p^2)q \\case2: q=q'^2 \implies x^2+y^2+z^2=h'q'$
if $q=1$,then $x=k'z$ or $z^2+a^2=k''z$, I left these two cases for op.