Evaluate: $\int \frac{{\sin(x)}}{{\sin(x) - \cos(x)}}\,dx$

468 Views Asked by At

I'm trying to evaluate the following integral:$$\int \frac{{\sin(x)}}{{\sin(x) - \cos(x)}}\,dx$$ Here's my approach so far:
$$$$I've multiplied the numerator and denominator by $-csc^3(x)$, resulting in $$\int -\frac{{\csc^2(x)}}{{\cot(x)\csc^2(x) - \csc^2(x)}}\,dx$$ Next I substituted $u = cotx $, giving me $$\frac{{du}}{{dx}} = -csc^2(x), du = -csc^2(x)dx$$ therefore in $\int -\frac{{\csc^2(x)}}{{\cot(x)\csc^2(x) - \csc^2(x)}}\,dx$ by replacing $cotx$ with $u$, I obtained, $$\int \frac{-1}{{u\left(u^2+1\right) - \left(u^2+1\right)}}\,du$$ $$\int (\frac{1}{{4\left(u+1\right)}} - \frac{1}{{4\left(u-1\right)}} - \frac{1}{{2\left(u-1\right)^2}})\,du$$

I would greatly appreciate any insights or techniques that could help me make progress with this integral. Are there specific strategies or mathematical tools that I should consider? Are there any useful properties or identities related to this type of expression?

Thank you for your attention and assistance.

6

There are 6 best solutions below

4
On BEST ANSWER

Alternatively, you can proceed as follows:

\begin{align*} \int\frac{\sin(x)}{\sin(x) - \cos(x)}\mathrm{d}x & = \frac{1}{2}\int\frac{2\sin(x)}{\sin(x) - \cos(x)}\mathrm{d}x\\\\ & = \frac{1}{2}\int\frac{(\sin(x) - \cos(x)) + (\sin(x) + \cos(x))}{\sin(x) - \cos(x)}\mathrm{d}x\\\\ & = \frac{x}{2} + \frac{1}{2}\int\frac{(\sin(x) - \cos(x))'}{\sin(x) - \cos(x)}\mathrm{d}x\\\\ & = \frac{x}{2} + \frac{1}{2}\ln\left(\sin(x) - \cos(x)\right) + C \end{align*}

1
On

Use the substitution $x=\frac{\pi}{4}+v \Rightarrow dx=dv$

Now use the following facts: $$\begin{aligned} &\sin\left(x+\frac{\pi}{4}\right)=\frac{\sin x+\cos x}{\sqrt{2}} \\ & \cos \left(x+\frac{\pi}{4}\right)=\frac{\cos x-\sin x}{\sqrt{2}} \end{aligned}$$

So we get $$\begin{aligned} I= & \int \frac{\sin x d x}{\sin x-\cos x}=\int \frac{\left(\frac{\sin v+\cos v}{\sqrt{2}}\right) d v}{\left(\frac{2 \sin v}{\sqrt{2}}\right)} \\ & \Rightarrow I=\frac{1}{2} \int \frac{\sin v}{\sin v} d v+\frac{1}{2} \int \cot v d v \\ & \Rightarrow I=\frac{v}{2}+\frac{1}{2} \ln |\sin v|+C \end{aligned}$$ Where $v=x-\frac{\pi}{4}$.

Method $2:$

Use the identities $$\begin{aligned} \cos ^2 x-\sin ^2 x & =\cos 2 x=1-2 \sin ^2 x \\ \sin 2 x & =2 \sin x \cos x \end{aligned}$$

$$\begin{aligned} f(x) & =\frac{\sin x}{\sin x-\cos x}=\frac{-\sin x(\cos x+\sin x)}{\cos ^2 x-\sin ^2 x} \\ & \Rightarrow f(x)=\frac{-1}{2}\left(\frac{2 \sin x \cos x+2 \sin ^2 x}{\cos 2x}\right) \\ & \Rightarrow f(x)=\frac{-1}{2}\left(\frac{\sin 2x+1-\cos 2 x}{\cos 2 x}\right) \\ & \Rightarrow f(x)=\frac{-1}{2}(\tan (2 x)+\sec (2 x)-1) \end{aligned}$$

Hope you can proceed from here.

1
On

It is not clear what you are asking for (see comments) but if it is a verification of your solution, here is one. You did very well with your substitution choice, and were quite near to the solution. I only have three remarks.

  1. You did a small sign mistake when you "obtained, $\int \frac{\color{red}-1}{{u\left(u^2+1\right) - \left(u^2+1\right)}}\,du$": it should be $$\int \frac{\color{green}+1}{{u\left(u^2+1\right) - \left(u^2+1\right)}}\,du.$$
  2. Next, your partial fraction decomposition was wrong. The correct one is: $$\frac1{\left(u-1\right)\left(u^2+1\right)}=\frac12\left(\frac1{u-1}-\frac{u+1}{u^2+1}\right).$$
  3. Incomprehensibly, you did not dare integrating it. $$\begin{align}\frac12\int\left(\frac1{u-1}-\frac{u+1}{u^2+1}\right)du&=\frac12\left(\ln|u-1|-\frac12\ln\left(u^2+1\right)- \arctan u+C\right)\\&=\frac12\left(\ln\frac{|u-1|}{\sqrt{u^2+1}}+ \operatorname{arccot}u+D\right)\qquad(D=C-\frac\pi2)\\&=\frac12\Big(\ln|\cos x-\sin x|+x+D\Big).\end{align}$$
1
On

$1/2(\ln |\sin(x)-\cos(x)|)+x/2+c$

$\sin(x)$ can be written as $1/2(2\sin(x))$ and then $2\sin(x)$ should be written as $\sin(x)+\cos(x)+\sin(x)-\cos(x)$. Then integrating we get the above result.

0
On

Let $$ A=\int \frac{{\sin(x)}}{{\sin(x) - \cos(x)}}\,dx, B=\int \frac{{\cos(x)}}{{\sin(x) - \cos(x)}}\,dx. $$ Clearly $$ A-B=\int \;dx=x+C_1. \tag1$$ Note $$ A=-\int \frac{1}{{\sin(x) - \cos(x)}}\,d\cos(x), B=\int \frac{1}{{\sin(x) - \cos(x)}}\,d\sin(x) $$ and hence $$ B+A=\int \frac{1}{{\sin(x) - \cos(x)}}\,d(\sin(x)-\cos(x))=\ln|\sin(x)-\cos(x)|+C_2. \tag2$$ From (1) and (2), it is easy to obtain $A$. In fact, $$ A=\frac12 x+\frac12\ln|\sin(x)-\cos(x)|+C. $$

0
On

Multiplying the numerator and the denominator of the integrand by $\sin x+\cos x$ we get the integral of $\frac12-\frac12\sec2x-\frac12\tan2x$ which is $$\frac x2-\frac14\ln|\sec2x+\tan2x|-\frac14\ln|\cos2x|+c$$ and $$\frac x2-\frac14\ln|1+\sin2x|+c.$$