Find the side of an equilateral triangle given only the distance of an arbitrary point to its vertices Triangle $ABC$ is an equilateral triangle and $P$ is an arbitrary point inside it. The distance from $P$ to $A$ is $4$ and the distance from $P$ to $B$ is $6$ and the distance from $P$ to $C$ is $5$. How to find the side of an equilateral triangle from this information?
 A: If you call the distances from $P$ to $A, B, C$, say, $a, b, c$, respectively, then by the Law of Cosines the side length $s$ of the equilateral triangle is given by
$s^2 = a^2 + b^2 - 2 a b \widetilde{C} = b^2 + c^2 - 2 b c \widetilde{A} = c^2 + a^2 - 2 c a \widetilde{B}$ $(\ast)$,
where $\widetilde{A} = \cos \angle BPC$, $\widetilde{B} = \cos \angle CPA$, and $\widetilde{C} = \cos \angle APB$. We don't know these angles, or (almost equivalently) their cosines, so we seek to eliminate these quantities and solve for $s$.
Now, the three angles add up to $2\pi$, and so
$\widetilde{C} = \cos \angle APB = \cos(2 \pi - \angle BPC - \angle CPA) = \cos(\angle BPC + \angle CPA)$
Applying the cosine angle sum identity we get
$\widetilde{C} = \widetilde{A} \widetilde{B} - \sin \angle BPC \sin \angle CPA$.
We can solve for the two sines by introducing square roots, but we can avoid this by rearranging and squaring, giving
$(\widetilde{A} \widetilde{B} - \widetilde{C})^2 = \sin^2 \angle BPC \sin^2 \angle CPA = (1-\widetilde{A}^2)(1-\widetilde{B}^2)$.
Solving for $\widetilde{A}, \widetilde{B}, \widetilde{C}$ in $(\ast)$, and rearranging gives a rational equation in $r_1, r_2, r_3, s$ whose roots $s$ given $r_1, r_2, r_3$ are the potential side lengths. By multiplying through by the common denominator $4 a^2 b^2 c$ we get an equivalent polynomial equation:
$s^2 [s^4 - (a^2 + b^2 + c^2)s^2 + (a^4 + b^4 + c^4 - b^2 c^2 - c^2 a^2 - a^2 b^2)] = 0$.
After discarding the coefficient $s^2$, the resulting equation is quadratic in $s^2$, so we can apply the quadratic equation and take the roots of the resulting expression to find $s$, so in general there may be two solutions that involve two nested radicals (looking back at the only irreversible step, squaring the trigonometric equation, we see that we won't introduce any false solutions). Notice that some of the solutions correspond to triangles for which the distance conditions are satisfied but the reference point lies outside the triangle.
In your example, taking side lengths $4, 5, 6$ give possible side lengths of $\frac{1}{2} \sqrt{154 \pm 30 \sqrt{21}}$. The larger one satisfies the condition that the triangle contain the reference point, since the larger length is larger than $\frac{2}{\sqrt{3}} r$ for $r = a, b, c$, and the smaller solution does not.
Remark We can analyze the quartic polynomial to deduce conditions on $(a, b, c)$ that determine the number of coefficients. Again viewing the polynomial as quadratic in $s^2$, the solutions for $s^2$ are
$s^2 = \tfrac{1}{2}[(a^2 + b^2 + c^2) \pm \sqrt{\Delta}]$,
and we find that its discriminant is
$\Delta = -3 (a + b + c) (a - b - c) (b - c - a) (c - a - b)$.
Analyzing this condition gives that $\Delta$ is


*

*positive iff no one of the three lengths $a, b, c$ is greater than or equal to the sum of the other two

*zero iff one of the lengths is equal to the sum of the other two

*negative iff one of the lengths is greater than the sum of the other two.


This immediately gives the following:


*

*If one of the lengths is larger than the sum of the other two, there are no positive solutions (or even real ones for that matter).

*If one of the lengths is equal to the sum of the other two, say $c = a + b$, there is one positive solution, namely, $s = \sqrt{\frac{1}{2} (a^2 + b^2 + c^2)} = \sqrt{a^2 + ab + b^2}$.


So, henceforth assume that no length is at least the sum of the other two, and so $\Delta > 0$, and $s = \sqrt{\frac{1}{2} \left(a^2 + b^2 + c^2 \pm \sqrt{\Delta}\right)}$ is always a solution when $\pm$ is taken to be $+$. It will give a solution when $\pm$ is taken to be $-$ if $a^2 + b^2 + c^2 > \sqrt{\Delta}$, or equivalently, when $a^2 + b^2 + c^2 - \Delta > 0$. But by definition of $\Delta$, the left-hand side is just $4$ times the constant term in the polynomial, which can be written as 
$\frac{1}{2}[(a^2 - b^2)^2 + (b^2 - c^2)^2 + (c^2 - a^2)^2]$,
which is always positive (and zero iff $a = b = c$).
Putting these facts together gives us that:


*

*If none of the lengths is greater than the sum of the other two but not all three lengths are the same, there are two solutions, namely, $\sqrt{\frac{1}{2}(a^2 + b^2 + c^2) \pm \Delta}$.

*If all three lengths are the same, say $r$, there is one positive solution, namely $\sqrt{3} r$, which corresponds to an equilateral triangle centered on the reference point; $0$ is also a solution, and corresponds to a degenerate triangle of side length $0$, i.e., a point, a distance $r$ from the reference point.

A: Let $P=0\in{\mathbb C}$, and let $M={d\over\sqrt{3}}>0$ be the center of the triangle. When $s$ is the side length of the triangle then there is an argument $\phi$ such that the three vertices are given by
$$A={1\over\sqrt{3}}(d+se^{i\phi}),\quad B={1\over\sqrt{3}}(d+s\omega e^{i\phi}),\quad C={1\over\sqrt{3}}(d+s\bar\omega e^{i\phi})\ ,$$
where $\omega=e^{2\pi i/3}$ is a third root of unity. When $a$, $b$, $c$ are the given distances we therefore have
$$\eqalign{
a^2&={1\over3}(d^2 + ds(e^{i\phi}+e^{-i\phi})+s^2) \cr
b^2&={1\over3}(d^2 + ds(\omega e^{i\phi}+\bar\omega e^{-i\phi})+s^2) \cr
c^2&={1\over3}(d^2 + ds(\bar\omega e^{i\phi}+\omega e^{-i\phi})+s^2) \cr}\tag{1}$$
Adding these three equations gives
$$a^2+b^2+c^2=d^2+s^2\ .\tag{2}$$
Multiplying the equations $(1)$  with $1$, $\omega$, $\bar\omega$ (resp. with $1$, $\bar\omega$, $\omega$), and adding we obtain
$$\eqalign{
a^2+\omega b^2+\bar\omega c^2&=dse^{-i\phi}\cr 
a^2+\bar\omega b^2+\omega c^2&=dse^{i\phi}\ .\cr}\tag{3}$$ 
In order to eliminate $\phi$ we now multiply the two equations $(3)$. Using $\omega+\bar\omega=-1$ we get
$$a^4+b^4+c^4-(a^2b^2+b^2c^2+c^2a^2)=d^2s^2\ .\tag{4}$$
Writing 
$$a^2+b^2+c^2=:\sigma_1,\qquad a^2b^2+b^2c^2+c^2a^2=:\sigma_2$$
we can condense $(2)$ and $(4)$ to
$$d^2+s^2=\sigma_1,\qquad d^2s^2=\sigma_1^2-3\sigma_2\ .$$
This leads to
$$s^4-\sigma_1s^2+\sigma_1^2-3\sigma_2=0\ ,$$
from which $s$ can be determined. 
For the given data we obtain $\sigma_1=77$, $\sigma_2=1876$, and this leads to
$s^4-77s^2+301=0$, or $s_1=8.536$, $s_2=2.0324$. (It seems that $s_2$ corresponds to a solution where $P$ is outside the triangle.)
A: You may be knowing this result for an equilateral triangle of side a and distance from P to vertices as x,y and z.
$$\frac{a^2+x^2-y^2}{2xa} = \frac{\sqrt{3}}{2}\frac{a^2+x^2-z^2}{2xa}+\frac{1}{2} \sqrt{1- \Big(\frac{a^2+x^2-z^2}{2xa}\Big)^2}$$
After putting values $(x,y,z)=(4,5,6)$ it becomes:
$$\frac{a^2+4^2-5^2}{8a} = \frac{\sqrt{3}}{2}\frac{a^2+4^2-6^2}{8a}+\frac{1}{2} \sqrt{1- \Big(\frac{a^2+4^2-6^2}{8a}\Big)^2}$$
Solving we get:
$$a=1/2\sqrt{154\pm30\sqrt{21}}\sim 8,2$$
A: I'll provide a geometric construction of such an equilateral triangle, and in the process deduce an analytic expression for the side length. The names of the points below is for consistency with the question; all triangles are labelled with vertices in clockwise order.
Let $\Delta PCD$ be an equilateral triangle with side length $5$.  We can construct circles with respective radii $4,6$ and centers $P,D$. These intersect at two points; let $A$ be the intersection for which $A$ and the vertex $C$ lie on the opposite sides of the line PD. Then we can find a point $B$ such that the triangle $\Delta ABC$ is equilateral. Observe that the point $P$ is within $\Delta ABC$, and that by construction $|PA|=4$ and $|PC|=5$.
I claim that moreover $|PB|=6$, and do so proving that triangles $\Delta ACD$ and $\Delta BCD$ are congruent. $\overline{BC}$ and $\overline{BC}$ both belong to the equilateral triangle $\Delta ABC$, so they are congruent; the same reasoning yields $\overline{CD}\cong \overline{CP}$ since $\Delta PCD$ is equilateral. But $\angle BCD=\angle BCP+\angle PCA$ and $\angle PCD=\angle PCA+\angle PCD$ are both inner angles of equilaterial triangles, and so each angles are $60^\circ$. Thus $\angle BCP=\angle PCD$ and we conclude that $\Delta ACD$ and $\Delta BCD$ are side-angle-side congruent. Therefore $|PB|=|AD|=6$, and the construction of \Delta ABC is satisfied. The result is shown in the figure below, with shading to distinguish the equilateral triangles.

One could perhaps determine the side lengths of $\Delta ABC$ synthetically as well, but I'll instead do so analytically. We assign coordinates for our initial points as $P(0,0)$, $D(5,0)$, and $C(\frac{5}{2}\frac{5\sqrt{3}}{2})$, which are readily seen to define an equilateral triangle. To find $A$, we solve for the intersection of the circles as
$$\left\{\begin{array}{rr} x^2+y^2=4^2 \\ (x-5)^2+y^2=6^2  \end{array}\right.\implies (x,y)=\left(\frac{1}{2},-\frac{3\sqrt{7}}{2}\right)$$
where in accordance with the construction we have taken $y<0$ since $C$ lies above the line $PD$ i.e. the $x$-axis. Thus the side length is $$|AC|=d(A,C)=\sqrt{\left(\frac{5}{2}-\frac{1}{2}\right)^2+\left(\frac{5\sqrt{3}}{2}+\frac{3\sqrt{7}}{2}\right)^2}=\sqrt{\frac{77}{2}+\frac{15}{2}\sqrt{21}}.$$
