I am unable to factorize this over $\mathbb{Z}:$ $$(x^2+y^2+z^2)(x+y+z)(x+y-z)(y+z-x)(z+x-y)-8x^2y^2z^2$$
Since, this from an exercise of a book (E. J. Barbeau, polynomials) it must have a neat factorization.
I tried to guess some factors by putting $x-y=0$, $x+y=0$, $x=0$.
I also notice that the expression is symmetric with respect to $x, y, z$.
I am trying to factor it without expanding the whole thing though the process of expansion can be eased by observing that $(x+y+z)(x+y-z)(y+z-x)(z+x-y)$ is a well known expression (Heron's formula), so one already knows it is
$$2(x^2y^2+y^2z^2+z^2x^2)-x^4-y^4-z^4$$ But I think there should be a way to do this without expanding the thing.
So, can someone tell me the factorization (preferably with the steps) or any hints as to how should I approach this problem.
Analyzing the last line and looking for a substitution for $z^2$ which makes this polynomial vanish it's not too hard to see that \begin{align*} z^2=x^2+y^2 \end{align*} does the job.
Division of $P(x,y,z)$ by this factor gives
\begin{align*} \frac{-z^6+(x^2+y^2)z^4+(x^2-y^2)^2z^2-(x^2-y^2)^2(x^2+y^2)}{-z^2+x^2+y^2}=z^4-(x^2-y^2)^2 \end{align*}
From the RHS we derive the other irreducible factors of $P(x,y,z)$ \begin{align*} z^2-(x^2-y^2)\qquad\text{and}\qquad z^2+(x^2-y^2) \end{align*}