A tower stands vertically in the interior of a field which has the shape of an equilateral triangle of side $a$. If the angles of elevation... 
A tower stands vertically in the interior of a field which has the shape of an equilateral triangle of side $a$. If the angles of elevation of the top of the tower are $\alpha$,$\beta$,$\gamma$ from the corners of the field find the height of the tower.

Answer: $$a\sqrt{\frac{p^2+q^2+r^2-\sqrt{2p^2q^2+2p^2r^2+2q^2r^2 -p^4 -q^4 - r^4}}{2(p^4 + q^4 + r^4 -p^2q^2 -p^2r^2 - q^2r^2)}}$$ where $p= \cot \alpha$, $q = \cot \beta$ and $r = \cot \gamma$

My Attempt
$[.]$ denotes area
$$[APB]+[BPC]+[CPA] = [ABC]$$
$$[ABC] = \frac{\sqrt{3}}{4}a^2$$
I tried finding the area of $\triangle APB$,$\triangle BPC$,$\triangle CPA$ by Heron's formula but the result was too complicated because I had to add square roots : something of the form $\sqrt{x} + \sqrt{y} + \sqrt{z} = w$. Moreover, the $x,y,z$ in this expression are also complicated.
I admit that the answer is complicated too but I am searching for an elegant approach towards the solution (something like substitution or anything else). Is there any elegant approach?
 A: As the figure shows the distances between the base of the tower $P$ and each of the three vertices $A,B,C$ of equilateral $\triangle ABC$ is
$ PA = h \cot \alpha = h p $
$ PB = h \cot \beta = h q $
$ PC = h \cot \gamma = h r $
Now using Barycentric coordinates, and taking $A$ to be the origin, we can express point $P$ in terms of $B $ and $C$ as follows
$ P = c_1 B + c_2 C $
so that
$ AP = P = c_1 B + c_2 C , BP = (c_1 - 1) B + c_2 C , CP = c_1 B + (c_2 - 1) C $
I'll assume that the side length $a = 1$.  Taking the magnitude of these vectors, and noting that $|B| = |C| = 1$ and that $B \cdot C = \dfrac{1}{2} $, then we can write the following three equations
$c_1^2 + c_2^2 + c_1 c_2 = h^2 p^2 \hspace{10pt} (*) $
$(c_1 - 1)^2 + c_2^2 + (c_1 - 1) c_2 = h^2 q^2 $
$ c_1^2 + (c_2 - 1)^2 + c_1 (c_2 - 1) = h^2 r^2 $
We want to eliminate $c_1, c_2$, so subtract each pair of equations, i.e. (1)-(2) , and (1) - (3), we get
$ 2 c_1 + c_2 = h^2 (p^2 - q^2) + 1 $
$ c_1 + 2 c_2 = h^2 (p^2 - r^2) +1$
Solving this $2 \times 2$ system, gives us
$ c_1 = \dfrac{1}{3} (  h^2 (p^2 - 2 q^2 + r^2 ) + 1 )$
$ c_2 = \dfrac{1}{3} ( h^2 (p^2 - 2 r^2 + q^2 ) + 1 )$
substituting $c_1, c_2$ into Eq. $(*)$ and expanding, gives us
$  h^4 K + h^2 L + M = 0  $
where
$K = p^4 + q^4 + r^4 - p^2 q^2 - p^2 r^2 - q^2 r^2 $
$ L = -  ( p^2 + q^2 + r^2 ) $
$ M = 1 $
Combining the $h^2 $ coefficients, we get the quadratic equation (in $h^2$)
From this, using the quadratic formula, the solution is
$ h^2 = \dfrac{ -L \pm \sqrt{ L^2 - 4 K } }{ 2 K } $
we have
$ - L = p^2 + q^2 + r^2 $
and
$L^2 - 4 K = p^4 + q^4 + r^4 + 2 p^2 q^2 + 2 p^2 r^2 + 2 q^2 r^2 - 4 (p^4 + q^4 + r^4 - p^2 q^2 - p^2 r^2 - q^2 r^2) $
And this reduces to
$ L^2 - 4 K = 3 ( 2 p^2 q^2 + 2 p^2 r^2 + 2 q^2 r^2 - p^4 - q^4 - r^4 ) $
Hence,
$ h^2 = \dfrac{ p^2 + q^2 + r^2 \pm \sqrt{3} \sqrt{2 p^2 q^2 + 2 p^2 r^2 + 2 q^2 r^2 - p^4 - q^4 - r^4} }{ 2 (p^4 + q^4 + r^4 - p^2 q^2 - p^2 r^2 - q^2 r^2)}$
