TITLE: Showing that $\int_{0}^{\pi/2}\frac{1+\sin(x)-\sin^2x}{e^{\sin(x)}+\cos(x)}=\log 2$
QUESTION [5 upvotes]: I don't see how to prove that
$$\int\limits_{0}^{\pi/2}\frac{1+\sin(x)-\sin^2(x)}{e^{\sin(x)}+\cos(x)}\,\mathrm dx=\log 2$$
Integrating by parts is of no help. The same with variable change. Should I use Taylor series? But how?

REPLY [8 votes]: Hint:
$$\frac{d}{dx}\ln\left(e^{\sin x}+\cos x\right)=\frac{e^{\sin x}\cos x-\sin x}{e^{\sin x}+\cos x}=\cos x-\frac{\cos^2 x+\sin x}{e^{\sin x}+\cos x}.$$