Integral related sum How to calculate this integral ?
$$ I =\int \frac{\sin 7x}{{\sin x}} dx .$$
I don't have any idea. Please help me.
 A: Hint:
$$\frac{\sin{7 x}}{\sin{x}} = 1 + 2 \cos{2 x}+ 2 \cos{4 x} + 2 \cos{6 x}$$
A: With addition theorems of $\sin$ you get
$$\frac{\sin(7x)}{\sin(x)}=1+2\cos(2x)+2\cos(4x)+2\cos(6x)$$
\begin{align*}
\sin(7x)&=\sin(6x+x)=\sin(6x)\cdot \cos(x)+ \cos(6x) \cdot \sin(x)
\end{align*}
So 
$$\frac{\sin(7x)}{\sin(x)}=\frac{\sin(6x)\cdot \cos(x)}{\sin(x)}+\cos(6x)$$
Now 
$$\sin(6x)=\sin(5x+x)=\sin(5x)\cos(x)+\cos(5x)\sin(x)$$
We use $$2 \cos(\alpha)\cdot \cos(\beta)=\cos(\alpha+\beta)+\cos(\alpha-\beta)$$
Which gives us 
$$\frac{\sin(6x)\cos(x)}{\sin(x)}=\frac{\sin(5x)\cos^2(x)}{\sin(x)}+ \frac{1}{2} \cos(6x) + \frac{1}{2}\cos(4x)$$
Now we use $\cos^2(x)=1-\sin^2(x)$, so 
$$\frac{\sin(5x) \cdot \cos^2(x)}{\sin(x)} = \frac{\sin(5x)}{\sin(x)} - \sin(5x)\sin(x)$$
We use 
$$2\sin(\alpha)\cdot \sin(\beta) =\cos(\alpha+\beta)-\cos(\alpha-\beta)$$
So we have 
$$\frac{\sin(5x)\cos^2(x)}{\sin(x)}=\frac{\sin(5x)}{\sin(x)}-\frac{1}{2} \cos(6x) +\frac{1}{2} \cos(4x)$$ 
Continuing this gives us the result
A: If you don't like trigonometry, you can do it with exponentials via the formula 
$$
e^{ix} = \cos x + i \sin x.
$$ 
Then 
$$
\begin{split}
\sin x = \frac{e^{ix}-e^{-ix}}{2i} =\Im(e^{ix})\\
\cos x = \frac{e^{ix}+e^{-ix}}{2} = \Re(e^{ix}).
\end{split}
$$
So, using the binomial formula 
$$
(a+b)^7=\sum_{k=0}^7\binom{7}{k}a^{7-k}b^k
$$ 
we have
$$
\begin{split}
\sin 7x &= \Im(e^{7x}) = \Im((\cos x+i\sin x)^7)
\\ &= \Im(\sum_{k=0}^7 i^k \binom{7}{k}\cos^{7-k}\sin^k x) \\
&=\cdots
\end{split}
$$
A: As $\sin y=\frac{e^{iy}-e^{-y}}{2i},$ 
putting $y=x$ and $nx$ we get, $$\frac{\sin nx}{\sin x}=\frac{(e^{inx}-e^{-inx})}{2i}\cdot \frac{2i}{(e^{ix}-e^{-ix})}$$
$$=\frac{(a^n-a^{-n})}{(a-a^{-1})}\text{ putting } a=e^{ix}$$
$$=\frac1{a^{n-1}}\frac{(a^{2n}-1)}{(a^2-1)}$$
$$=\frac{a^{2n-2}+a^{2n-4}+a^{2n-6}+\cdots+a^4+a^2+1}{a^{n-1}}$$
$$=a^{n-1}+a^{-(n-1)}+a^{n-2}+a^{-(n-2)}+\cdots$$
$$=2\cos(n-1)x+2\cos(n-2)x+\cdots$$
If $n$ is odd, $=2m+1$(say), the last term will be $1$
$\implies \frac{\sin(2m+1)x}{\sin x}=1+2\sum_{1\le r\le 2m}\cos rx$
If $n$ is even, $=2m$(say), the last term will be $2\cos x$
$\implies \frac{\sin 2mx}{\sin x}=2\sum_{1\le r\le 2m-1}\cos rx$
Now, use $\int\cos mxdx=\frac{\sin mx}m$
