<s>[INST] If for integer $x_1,x_2,x_3,x_4$ holds $x_i\cdot x_j = y_{ij}^2 - 13$ ($i\neq j$), is it possible that $x_1+x_2+x_3=10^6$? Let $a$, $b$, $c$, $d$ be integers. Given that a product of any two of them equals perfect square minus $13$, is it possible for the sum of some three of them to be equal to $10^6$?
My guess is that it is impossible.
My approach was to use the remainders modulo $5$, as $n^2\equiv0,\pm1\pmod{5}$.
If $a+b+c=10^6$, then $d(a+b+c)=k^2 + l^2 + m^2 - 39 = d \cdot 10^6$ for some $k,l,m$.
It is clear that (with the proper rearrangement of variables), $k^2\equiv l^2 \equiv 0,\; m^2 \equiv -1$ or $k^2\equiv l^2 \equiv -1,\; m^2 \equiv 1$.
One can elaborate a bit further on the possibilities for the remainders, but I can't arrive to any contradiction.
I have also tried solving this for smaller numbers in Wolfram, but it uses to much RAM.
 [/INST] You are incredibly close. Consider the equation $k^2 + l^2 + m^2 -39 = d\cdot 10^6$ modulo $8$.
Note that $n^2 \equiv 0,1,4 \pmod 8$. Hence $k^2 + l^2 + m^2 \not\equiv 7 \pmod 8$. But $39 \equiv 7 \pmod 8$ and $d \cdot 10^6 \equiv 0 \pmod 8$. Hence there are no integer solutions to $k,l,m$.
</s>