Question:medium

$\int \frac{x+\sin x}{1+\cos x} d x=$

Show Hint

This problem perfectly follows the integration template $\int [f(x) + xf'(x)]dx = xf(x) + c$. If you rewrite the expression, it reveals itself as $\int [\tan(x/2) + x \cdot \frac{1}{2}\sec^2(x/2)]dx$. Recognizing this template allows you to instantly write down the answer $x\tan(x/2)$ without doing any integration steps!
Updated On: Jun 3, 2026
  • $x \tan\left(\frac{x}{2}\right) + c$
  • $\log(x + \sin x) + c$
  • (x2) + c
  • $\log(1 + \cos x) + c$
Show Solution

The Correct Option is A

Solution and Explanation

Step 1: Use half-angle forms.
Write $1+\cos x=2\cos^2\frac{x}{2}$ and $\sin x=2\sin\frac{x}{2}\cos\frac{x}{2}$.

Step 2: Split the integral.
\[ \int\frac{x+\sin x}{2\cos^2\frac{x}{2}}\,dx=\frac{1}{2}\int x\sec^2\frac{x}{2}\,dx+\int\tan\frac{x}{2}\,dx \]

Step 3: Do the first piece by parts.
Take $u=x$ and $dv=\sec^2\frac{x}{2}\,dx$, so $v=2\tan\frac{x}{2}$. This gives $x\tan\frac{x}{2}-\int\tan\frac{x}{2}\,dx$.

Step 4: Combine.
The two $\int\tan\frac{x}{2}\,dx$ terms cancel, leaving \[ x\tan\frac{x}{2}+c \] \[ \boxed{x\tan\left(\frac{x}{2}\right)+c} \]
Was this answer helpful?
0