System of Equations: Distances from the Torricelli Point to the Vertices of a Triangle I am calculating the length between the Torricelli point and the triangle apex. With the law of cosines I get this system:
$$\left\{\begin{array}{cc}
x^2+y^2+xy&=a^2\,,\\x^2+z^2+xz&=b^2\,,\\z^2+y^2+zy&=c^2\,.\end{array}\right.$$
Please help me solve it.

In @Batominovski's symmetric notation, we have
$$\begin{align}
a^2&=q^2+r^2+q r\\
b^2&=r^2+p^2+r p\\
c^2&=p^2+q^2+p q
\end{align} \tag{1}$$
Using Mathematica's Resultant function (or, equivalently, Groebner bases), we can eliminate, say, $q$ and $r$ to get
$$\begin{align}
0 &= 9 p^4 (a^4 - a^2 b^2 + b^4 - a^2 c^2 - b^2 c^2 + c^4) \\[4pt]
&+3 p^2 (a^6 - 4 a^4 b^2 + 5 a^2 b^4 - 2 b^6 - 4 a^4 c^2 + 3 a^2 b^2 c^2 - 
   b^4 c^2 + 5 a^2 c^4 - b^2 c^4 - 2 c^6) \\[4pt]
&+ \phantom{9p^4}(a^2 - b^2 - b c - c^2)^2 (a^2 - b^2 + b c - c^2)^2 \\
&= 9H (p^2)^2 + 3J (p^2) + K
\end{align} \tag{2}$$
This is ugly, but at least it's a quadratic in $p^2$ that can be readily solved. Conveniently, the discriminant factors nicely.
$$\begin{align}
(3J)^2-4(9H)K &= 27 (a^2 - b^2)^2 (a^2 - c^2)^2 (-a + b + c) (a + b - c) (a - b + c) (a + b + c) \\[4pt]
&= 27 (a^2-b^2)^2(a^2-c^2)^2\cdot 16|\triangle ABC|^2 \tag{3}
\end{align}$$
so that we have
$$p^2 = \frac{-J \pm 4\,|\triangle ABC|\,|a^2-b^2|\,|a^2-c^2|\,\sqrt{3}}{6H} \tag{4}$$
I suspect there's an clean way to write $(4)$, and perhaps even a clever way to derive it, but that'll take a bit more thinking.
