A pan balance is made up of a rigid, massless rod with a hanging pan attached at each end. The rod is supported at and free to rotate about a point not at its center. It is balanced by unequal masses placed in the two pans. When an unknown mass $m$ is placed in the left pan, it is balanced by a mass $m_{1}$ placed in the right pan; when the mass $m$ is placed in the right pan, it is balanced by a mass $m_{2}$ in the left pan. Show that $m=\sqrt{m_{1} m_{2}}$.