Equilateral triangles in the complex plane
The complex numbers \(a_1, a_2, a_3\) are vertices of an equilateral triangle in the complex plane if and only if \(a_1^2+a_2^2+a_3^2=a_1a_2+a_2a_3+a_3a_1\).
Proof
The expression \(a_1^2+a_2^2+a_3^2=a_1a_2+a_2a_3+a_3a_1\) is equivalent to
\[(a_1-a_2)^2+(a_2-a_3)^2+(a_3-a_1)^2=0.\]If the three points form an equilateral triangle, then the three lengths \(|a_i-a_j|\), \(i,j=1,2,3\), are all equal, and the angles made by these lines are at \(120^\circ\) to each other, so \begin{align} a_1-a_2&=re^{i\phi}\\ a_2-a_3&=re^{i(\phi+\tau)}\\ a_3-a_1&=re^{i(\phi+2\tau)}\\ \end{align} where \(\tau=2\pi/3\equiv120^\circ\). Then \[ (a_1-a_2)^2+(a_2-a_3)^2+(a_3-a_1)^2=r^2e^{2i\phi}(1+e^{2i\tau}+e^{4i\tau})=0 \] because \(e^{4i\tau}=e^{i\tau}=\frac12(-1+i\sqrt{3})\) and \(e^{2i\tau}=\frac12(-1-i\sqrt3)\).
Conversely, if there are three points \(a_1, a_2\) and \(a_3\) which fulfil the relation, since the relation involves only the differences of the numbers, we can assume that \(a_1=0\) without loss of generality. Our relation then becomes \[a_2^2+a_3^2-a_2a_3=0.\] This is a quadratic and \[ a_3=\frac12(-1\pm i\sqrt3)a_2, \] so, since \(|\frac12(-1\pm i\sqrt3)|=1\), \(|a_3|=|a_2|\), and multiplication by this number rotates by an angle of angle of \(120^\circ\) around the origin, by elementary geometry \(a_2\) and \(a_3\) form the other two vertices of an equilateral triangle.