What is the value of $x^2 + y^2 + z^2$ if $x^2 y + y^2 z + z^2 x=2186$ and $xy^2 + y z^2 + z x^2=2188$ 
What is the value of $x^2 + y^2 + z^2$ if $x^2 y + y^2 z + z^2 x=2186$ and $xy^2 + y z^2 + z x^2=2188$, where $x,y,z$ are integers.  

My Attempt 
$(x^2 y + y^2 z + z^2 x) +(x^2 y + y^2 z + z^2 x) =2186+2188=4374$. 
From this we can derive $(x+y+z)(xy+yz+zx)-3xyz=4374$ . We can subtract the given equations to get $xy(x-y)+yz(y-z)+zx(z-x)=-2$. But after this , I can't figure out how to proceed.
Any help is appreciated. Thanks in advance.
 A: Subtracted the first equation from the second:
$$\left(x^2 z+x y^2+y z^2\right)-\left(x^2 y+x z^2+y^2 z\right)=2$$
Simplify and factor:
$$-x^2 y+x^2 z+x y^2-x z^2-y^2 z+y z^2=(x-z)(-x y+x z+y^2-y z)= (x - z)(y - x) (y - z)$$
Because $x$, $y$ and $z$ are integers, $x-z$, $x-y$ and $z-y$ must be integers too, and the only integers possible are $\pm 1$ and $\pm 2$, so $x$, $y$ and $z$ must also be consecutive integers.
Because the equations are symmetrical in interchange of $x$, $y$, and $z$, without loss of generality, we can choose $x$ to be the largest.
This gives us $y-x=-2,\;x-z=1,\;y-z=-1$ that is $y = x-2 , \;z =x -1 $
Plug these results in one of the two equations $x^2 y+x z^2+y^2 z=2186$ to get
$$x^2 (x-2)+(x-1)^2 x+(x-1) (x-2)^2-2186=0$$
Expand and simplify
$$x^3-3 x^2+3 x-730=0$$
$$(x-1)^3 - 729 = 0$$
Since $729=9^3$, the solution is $x=10$.
Substituting in the other equations gives $y=8$ and $z=9$.
$x^2+y^2+z^2=10^2+8^2+9^2=245$
A: $$\sum_{cyc}(x^2y-x^2z)=(x-y)(x-z)(y-z)=-2$$
and the rest for you.
A: I know this is cheating, but I put it into a computer program and got that $x, y, z = (8, 9, 10)$, and $x^2 + y^2 + z^2 = 245$.
#include <stdio.h>
int main ()
{
unsigned a = 2186;
unsigned b = 2188;
unsigned max = 120;
unsigned x, y, z;
for (x = 1; x < max; x++) {
for (y = 1; y < max; y++) {
for (z = 1; z < max; z++) {
unsigned p = x*x*y + y*y*z + z*z*x;
unsigned q = x*x*z + y*y*x + z*z*y;
if (p == a && q == b) {
printf ("%d %d %d\n", x, y, z);
printf ("%d\n", x*x + y*y + z*z);
}
}
}
}
}

Output is
8 9 10
245
9 10 8
245
10 8 9
245

Sorry that is not a mathematical answer to the question.
