Find all values of $x$ such that $\sin(2x) = \sin(x)$ and $x \in [0, 2\pi]$ The answers are $0, \frac{\pi}{3}, \pi, \frac{5\pi}{3}$ and $2\pi$.  I found $\frac{\pi}{3}$ and $\frac{5\pi}{3}$ algebraically, I overlooked $0$ and $2\pi$, but understood once I looked at the answer, but I'm missing how I could have found $\pi$.  Here's what I did.
I noticed that $\sin(2x) = 2\sin(x)\cos(x)$, so we can multiply both sides by $\frac{1}{\sin(x)}$ and we eventually get $\cos(x) = \frac12$, which set me looking for the solutions of this last equation, but the $\cos(\pi) = -1$ which is not $\frac12$, so I would have concluded that $\pi$ does not solve the original problem.
I must be losing information with this algebra, but I can't spot what step is wrong.  I believe I'm making a mistake of the sort that we do with square roots.  For instance, if $x^2 = 4$, I could incorrectly conclude that $x = 2$ and overlook that $x = -2$ also works.
So my question is more than how to solve this particular problem.  My question is what should I look out for when I replace one trigonometric equation for another.  (If I'm on the right track here, that is.)  Thank you.
Reference. This is problem 8 in Stewart's Calculus 6th edition, tests of algebra D.  (The verification tests so we know what we'll need in reading the book.)
 A: $\sin(2x)=2\sin(x)\cos(x)=\sin(x)$
$\implies \sin(x)=0$ or $\cos(x)=\frac12$
$\implies x \in \{0, \frac{\pi}{3}, \pi, \frac{5\pi}{3}, 2\pi \}$
You did almost the same thing except you forgot to consider the fact that $\sin(x)$ can be $0$ as well and in that case you cannot cancel it.
A similar problem comes when you solve $x^2=2x$, in this case also, $x$ can be both $0$ and $2$.
So, instead of doing this you can consider$x^2=2x$ as $(x-2)x=0$, then one of the factors on the RHS must be 0 which implies $x$ can be $2$ or $0$.
Similarly, $2\sin(x)\cos(x)=\sin(x) \implies \sin(x)(\cos(x)-\frac12)=0$ and then you can proceed.
Hope this helps you.
A: You can multiply both sides of an equation by any nonzero number and you don't lose information.
But you're multiplying both sides by $1/\sin x$ without taking into account that this might be undefined, which it is when $\sin x=0$.
So you can remove the common factor $\sin x$ after having noted that $\sin x=0$ is a solution of the equation.
It's like when you have $x^2=x$. You cannot multiply by $1/x$, unless you first note that $x=0$ is a solution.
It's much better to rewrite this equation as $x^2-x=0$, factorize $x(x-1)=0$ and conclude that either $x=0$ or $x=1$.

Now let's see some ways that can be used to solve the equation
You should know that
$$
\sin\alpha=\sin\beta
$$
if and only if

*

*$\alpha$ and $\beta$ differ by an integral multiple of $2\pi$, or

*$\alpha+\beta$ differs from $\pi$ by an integral multiple of $2\pi$.

Thus your equation becomes

*

*$2x=x+2k\pi$, or

*$2x+x=\pi+2k\pi$
In the first case we find $x=2k\pi$, accounting for the solutions $x=0$ or $x=2\pi$ in the specified interval.
In the second case we find $x=\pi/3+2k\pi/3$, accounting for the solutions
$$
x=\dfrac{\pi}{3},\quad x=\pi,\quad x=\dfrac{5\pi}{3}
$$
in the specified interval. Putting things together, we find
$$
0,\quad \dfrac{\pi}{3},\quad \pi,\quad \dfrac{5\pi}{3},\quad 2\pi
$$
In a different way, rewrite the equation as
$$
\sin x(2\cos x-1)=0
$$
and solve separately $\sin x=0$ and $\cos x=1/2$.
In the particular case this is perhaps easier. But what if you had $\sin 7x=\sin5x$?
Another way, recall the sum-to-product formula
$$
\sin\alpha-\sin\beta=2\cos\dfrac{\alpha+\beta}{2}\sin\dfrac{\alpha-\beta}{2}
$$
(I always go and look up for them). In your case you get
$$
2\cos\dfrac{3x}{2}\sin\dfrac{x}{2}=0
$$
and you solve separately $\cos(3x/2)=0$ and $\sin(x/2)=0$. The former yields $3x/2=\pi/2+k\pi$, so $x=\pi/3+2k\pi/3$; the latter yields $x/2=k\pi$, so $x=2k\pi$ and you go as before to identify those that belong to $[0,2\pi]$.
Take your pick.
A: You lose information when you divide by $\sin x$.  Keep in mind that division by $\sin x$ is only permissible when you know that $\sin x \neq 0$.  Rather than dividing, you should factor.
\begin{align*}
\sin(2x) & = \sin x\\
2\sin x\cos x & = \sin x\\
2\sin x\cos x - \sin x & = 0\\
\sin x(2\cos x - 1) & = 0
\end{align*}
Since a product is equal to zero if and only if one of its factors is equal to zero, we obtain
\begin{align*}
\sin x & = 0 & \text{or} & & 2\cos x - 1 & = 0\\
x & = 0, \pi, 2\pi & & & 2\cos x & = 1\\
  & & & & \cos x & = \frac{1}{2}\\
  & & & & x & = \frac{\pi}{3}, \frac{5\pi}{3}
\end{align*}
