How to solve $1 +e^{ix}+e^{iy}=0$ for $x,y \in [-\pi,\pi]$

I want to solve $1 +e^{ix}+e^{iy}=0$ for $x,y \in [-\pi,\pi]$ and wolframalpha revealed (in a plot) that the only choices are $x = \pm \frac{2 \pi}{3}$ and $y = \mp \frac{2 \pi}{3}$ respectively. But I was unable to show this myself.

Hint: Whenever you have an equation with complex variables, you immediately get two equations. Consider the real and imaginary parts.

By considering the imaginary parts of both sides of $1+e^{ix}+e^{iy}=0$ we have $\sin(x)+\sin(y)=0$, hence $y=-x$ and the equation boils down to $$1+2\cos(x) = 0$$ from which $x=\pm\frac{2\pi}{3}$.

• What is wrong with this answer? Sep 11 '16 at 21:07
• D'Auirizio: Given that the answer by user..... has been upvoted, it may be because it was thought that you supplied the answer to a homework problem?
– jim
Sep 11 '16 at 21:10
• I have no idea why you were downvoted. It's almost good enough, but $\sin(x) + \sin(y) = 0$ has also the solution $y = \pi + x$, which must be dispensed with. Sep 11 '16 at 21:11
• That case can be left to the reader, I think, it is not difficult to deal with it, given the restrictions $x,y\in[-\pi,\pi]$. Sep 11 '16 at 21:14

Multiply both sides by $e^{-ix}$, getting $$e^{-ix}+1+e^{i(y-x)}=0 \tag{1}$$ Multiply by $e^{-iy}$, getting $$e^{-iy}+e^{i(x-y)}+1=0 \tag{2}$$ The conjugate of $(2)$ is $e^{iy}+e^{i(y-x)}+1=0$ and the comparison with $(1)$ gives $e^{iy}=e^{-ix}$.

Thus you have $e^{ix}+e^{-ix}+1=0$ and, setting $z=e^{ix}$, the equation becomes $$z+\frac{1}{z}+1=0$$ Can you go on?