The smooth and level parade ground of the First Ruritanian Infantry Divison is ornamented by two tall vertical flagpole of heights $h_1$ and $h_2$ a distance d apart. As part of an initiative test a soldier has to march in a such a way that he keeps the angles of elevation of the tops of the two flagpoles equal to one another. Show that if the two flag poles are of different heights he will march in a circle.
To celebrate the King's birthday a third flagpole is added. Soldiers are then assigned to each of the three different pairs of flagpoles and are told to march in such a way that they always keep the tops of their two assigned flagpoles at equal angles of elevation to one another. Show that, if the three flagpoles have different heights $h_1, h_2$ and $h_3$ and the circles in which the soldiers march have centres at $(x_{ij},y_{ij})$ (for the flagpoles of height $h_i$ and $h_j$) relative to Cartesian coordinates fixed in the parade ground, then $x_{ij}$ satisfy $$h_3^2(h_1^2-h_2^2)x_{12}+h_1^2(h_2^2-h_3^2)x_{23}+h_2^2(h_3^2-h_1^2)x_{31}=0.$$ Deduce that the three centres lie in a straight line.
The question is much shorter than it looks. The first part is easy, by drawing a quick diagram you get that, with coordinates relative to one of the flagpoles and both of flags on the $y$-axis, $$(h_1^2-h_2^2)x^2+(h_1^2-h_2^2)y^2-2h_1^2dx+h_1^2d^2=0$$ as the locus of the soldiers. For the second part I'm pretty sure you just have to use this equation three times. Completing the square gives the centre of the circle having coordinates $\left(\frac{dh_1^2}{h_1^2-h_2^2},0\right)$ i.e. a distance $\frac{d_{12}h_1^2}{h_1^2-h_2^2}$ along the line connecting pole 1 and 2 where $d_{12}$ is the distance between them(and analogous equations can be written down the other pairs of poles). However, this isn't really $x_{12}$ due to our choice of axes, we can only say, in terms of vectors $$(x_{12},y_{12})=X_1+\frac{dh_1^2}{h_1^2-h_2^2}{(X_2-X_1)}$$ where $X_1$ is the absolute position vector of the first flag pole, $X_2$ of the second. Writing down the equations of this form for the other circles gives a nasty system of vector equations, which you could probably solve to eliminate $X_1,X_2,X_3$, but have no hope of getting rid of $d_{12}$ et al. and is no way the question is supposed to be approached. There is a "model" answer here if this has some more details that may be useful to you, but it is totally unintelligible to me.
I would like to know how to proceed in generalising the first result as is required, to get the required answer. The question is question 7 here should it be needed.
EDIT: I have solved the question in the manner set out above(thanks to a comment below), I will let the bounty go to the most upvoted answer(of which all so far have been wonderful) in a couple of days

