Prove this formula $\dfrac{r\sin(x)}{1-2r\cos(x)+r^2}= \sum_{n=1}^{+\infty}r^{n}\sin\left(nx\right)$ I wish to use geometric power series of $\dfrac{1}{1-x}$ to prove this formula by Euler
$$\dfrac{r\sin(x)}{1-2r\cos(x)+r^2}=r\sin(x)+r^2\sin(2x)+r^{3}\sin(3x)...=1+\sum_{n=1}^{+\infty}r^{n}\sin\left(nx\right)$$
In this thread, I have understood how to prove the same formula for $\cos(nx)$
Please see the answer of A-Level Student to see, his answer is:

Let
$$\begin{align}
C&=1+r\cos x+r^2\cos2x+r^3\cos3x+\cdots\\
S&=r\sin x+r^2\sin2x+r^3\sin3x+\cdots\\
\end{align}$$
Then
$$\begin{align}
C+iS&=1+r(\cos x+i\sin x)+r^2(\cos 2x+i\sin2x)+r^3(\cos3x+i\sin3x)+\cdots\\
&=1+re^{ix}+(re^{ix})^2+(re^{ix})^3+\cdots\\
&=\frac{1}{1-re^{ix}}=\frac{(1-re^{-ix})}{(1-re^{ix})(1-re^{-ix})}=\frac{1-r\cos x+ri\sin x}{1-2r\cos x+r^2}
\end{align}$$
Hence, equating real and imaginary parts we obtain
$$\begin{align}
C&=\frac{1-r\cos x}{1-2r\cos x+r^2}\\
S&=\frac{r\sin x}{1-2r\cos x+r^2}\\
\end{align}$$

I wish to use a similar method to prove the above mentioned series for $\sin(nx)$, but I am not sure value which series for of $C$ and $S$, should I choose.
I have chosen $C=1+r\sin(x)+r^2\sin(2x)+r^{3}\sin(3x)...$
$S=rcos(x)+r^2cos(2x)+r^3cos(3x)+...$
And I let $1 + S + iC$, with $i$ being imaginary number.
So I have
$1 +S + iC = 1+r(\cos(x)+i\sin(x))+r^2(\cos(2x)+i\sin(2x)+...$
= $1 + S +iC = 1+ re^{ix} + (re^{ix})^2+ (re^{ix})^3+ (re^{ix})^4+ (re^{ix})^5+...$
And the $1+ re^{ix} + (re^{ix})^2+ (re^{ix})^3+ (re^{ix})^4+ (re^{ix})^5+... =  \dfrac{1}{1-e^{ix}}$
It is here that I am stuck, I don't think my choice of $S$ and $C$ is correct. I know that the Euler identity for $\sin(x)=\dfrac{e^{ix}-e^{-ix}}{2i}$, but I don't know how to apply this formula.

Use infinite GP:
$$S=\sum_{n=1}^{\infty} r^n \sin nx=\Im \sum_{n=1}^{\infty} r^ne^{inx}=\Im \frac{re^{ix}}{1-re^{ix}}$$
$$\implies S=\Im \frac{re^{ix}(1-re^{-ix})}{(1-re^{ix})(1-re^{-ix})}=\frac{r\sin x}{1-2r\cos x+r^2}$$
This result has been check with Mathematica numerically. For instance for $r=1/2,x=\pi/3$, we get $S=1/\sqrt{3}$
