Is there someone show me how I evaluate this integral:$$\int\frac{\mathrm{d}x}{1+\sin x−\cos x} $$

I used $t=\tan\frac{x}{2}$ but i didn't succeed .

Thank you for any help .

  • $\begingroup$ This substitution always works because will transform the integral in a rational function. $\endgroup$ – user 1987 Jul 4 '15 at 16:21

$$\int\frac {\mathrm{dx}}{1+\sin x -\cos x}= \int\frac {\mathrm{dx}}{2\sin^2 \frac{x}{2}+2\sin \frac{x}{2} \cos \frac{x}{2}}\\= \frac{1}{2}\int\frac {\mathrm{dx}}{\sin^2 \frac{x}{2}+\sin \frac{x}{2} \cos \frac{x}{2}}= \frac{1}{2}\int\frac{\sec^2 \frac{x}{2}}{\tan^2 \frac{x}{2} +\tan \frac{x}{2}}\mathrm{dx}$$

put, $\tan \frac{x}{2} =t$

Hence $\displaystyle \int\frac{\mathrm{dt}}{t^2+t}$

$$ = \int\frac{\mathrm{dt}}{t}- \int\frac{\mathrm{dt}}{t+1}= \log \frac{t}{t+1}+C$$ We must substitute $\tan \frac{x}{2}=t$ back into $\log \frac{t}{t+1}+C$ to get $\boxed{\log \tan \frac{x}{2}-\log\left(\tan \frac{x}{2}+1\right)+C}$ as the final answer .

  • $\begingroup$ In your final answer, I think $1$ should be added to $\tan x/2$, not to $x/2$ itself. $\endgroup$ – Empy2 Jul 4 '15 at 16:26
  • $\begingroup$ thank you ,i dident get attention for sec !!!! $\endgroup$ – Ani Fier Jul 4 '15 at 23:28

You can dot it directly : if $t=\tan(\frac x2)$, $\sin(x)=\frac{2t}{1+t^2}$, $\cos(x)=\frac{1-t^2}{1+t^2}$, $dt=\frac{2}{1+t^2}$, so $$I=\int\frac {{dx}}{1+\sin x -\cos x}= \int\frac{dt}{t(1+t)}=\int\Big(\frac{1}{t}-\frac{1}{t+1}\Big) dt$$ $$I=\log(t)-\log(1+t)+C=\log\frac{t}{1+t}+C$$


Hint: $$\int \frac{dx}{1+\sin x-\cos x}=\int \frac{\frac{dx}{1+\sin x}}{1+\frac{-\cos x}{1+\sin x}}=\int \frac{d \left(1+\frac{-\cos x}{1+\sin x} \right)}{1+\frac{-\cos x}{1+\sin x}}=\log\left(1+\frac{-\cos x}{1+\sin x}\right)+C$$


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.