求不定积分 $\int\frac{x+\sin x}{1+\cos x}dx$.
求不定积分
\[
\int\frac{x+\sin x}{1+\cos x}dx.
\]
求不定积分
\[
\int\frac{x+\sin x}{1+\cos x}dx.
\]
1
\[
\begin{split}
\int\frac{x+\sin x}{1+\cos x}dx&=\int\frac{x}{1+\cos x}dx+\int\frac{\sin x}{1+\cos x}dx\\
&=\int\frac{x(1-\cos x)}{1-\cos^2 x}dx-\int\frac{d\cos x}{1+\cos x}\\
&=\int\frac{x(1-\cos x)}{\sin^2 x}dx-\int\frac{1}{1+\cos x}d(1+\cos x)\\
&=\int x(1-\cos x)\csc^2 x dx-\ln(1+\cos x)+C
\end{split}
\]
其中
\[
\begin{split}
\int x(1-\cos x)\csc^2 x dx&=\int x(\cos x-1)d\cot x\\
&=\int x\cos xd\cot x-\int xd\cot x\\
&=x\cos x\cot x-\int\cot x d(x\cos x)-\Bigl[x\cot x-\int\cot x dx\Bigr]\\
&=\frac{x\cos^2 x}{\sin x}-\int\frac{\cos x}{\sin x}\bigl(\cos xdx-x\sin xdx\bigr)-\Bigl[x\cot x-\int\frac{\cos x}{\sin x}dx\Bigr]\\
&=\frac{x\cos^2 x}{\sin x}-\int\frac{\cos^2 x}{\sin x}dx+\int x\cos xdx-x\cot x+\int\frac{d\sin x}{\sin x}\\
&=\frac{x\cos^2 x}{\sin x}-\int\frac{1-\sin^2 x}{\sin x}dx+\int xd\sin x-x\cot x+\ln(\sin x)\\
&=\frac{x\cos^2 x}{\sin x}-\int\frac{1}{\sin x}dx+\int\sin xdx+\Bigl[x\sin x-\int\sin xdx\Bigr]-x\cot x+\ln\sin x\\
&=\frac{x\cos^2 x}{\sin x}-\frac{1}{2}\ln\frac{1+\cos x}{1-\cos x}+x\sin x-x\cot x+\ln\sin x+C.
\end{split}
\]
其中
\[
\begin{split}
-\int\frac{1}{\sin x}dx&=-\int\frac{\sin x}{\sin^2 x}dx=\int\frac{d\cos x}{1-\cos^2 x}\\
&=\int\frac{dt}{1-t^2}=\frac{1}{2}\int\Bigl(\frac{1}{1-t}+\frac{1}{1+t}\Bigr)dt\\
&=\frac{1}{2}\ln\biggl|\frac{1+t}{1-t}\biggr|+C\\
&=\frac{1}{2}\ln\frac{1+\cos x}{1-\cos x}+C.
\end{split}
\]
令 $t=\cos x$,
因此, 原不定积分为
\[
\begin{split}
&\frac{x\cos^2 x}{\sin x}+\frac{1}{2}\ln\frac{1+\cos x}{1-\cos x}+x\sin x-x\cot x+\ln\sin x-\ln(1+\cos x)+C\\
=&\frac{x\cos^2 x}{\sin x}+\frac{1}{2}\ln\frac{1+\cos x}{1-\cos x}+x(\sin x-\cot x)+\ln\frac{\sin x}{1+\cos x}+C.
\end{split}
\]