#### Explain solution RD Sharma Class12 Chapter Definite Integrals exercise 19.2 question 29 maths.

Answer: $\frac{\pi}{2}$

Hint: We use indefinite integral formula then put limits to solve this integral.

Given: $\int_{0}^{\frac{\pi}{2}}\frac{x+2\sin \frac{x}{2} \cos \frac{x}{2}}{2\cos ^2 \frac{x}{2}}dx$

Solution:  $I=\int_{0}^{\frac{\pi}{2}}\frac{x+2\sin \frac{x}{2} \cos \frac{x}{2}}{2\cos ^2 \frac{x}{2}}dx$

\begin{aligned} &=\int_{0}^{\frac{\pi}{2} x+2 \sin \frac{x}{2} \cos \frac{x}{2}}{2 \cos ^{2} \frac{x}{2}} d x \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \quad\left[1+\cos 2 x=2 \cos ^{2} x, \sin 2 x=2 \sin x \cos x\right] \\ &=\int_{0}^{\frac{\pi}{2}}\left(\frac{x}{2 \cos ^{2} \frac{x}{2}}+\frac{2 \sin \frac{x}{2} \cos \frac{x}{2}}{2 \cos ^{2} \frac{x}{2}}\right) d x \; \; \; \; \; \; \; \; \; \; \; \; \; \; \quad\left[\cos x=\frac{1}{\sec x}\right] \\ &=\int_{0}^{\frac{\pi}{2}}\left(\frac{x \sec ^{2} \frac{x}{2}}{2}+\frac{\sin \frac{x}{2}}{\cos \frac{x}{2}}\right) d x \end{aligned}

\begin{aligned} &=\int_{0}^{\frac{\pi}{2}}\left(\frac{x \sec ^{2} \frac{x}{2}}{2}+\frac{\sin \frac{x}{2}}{\cos \frac{x}{2}}\right) d x \\ &=\frac{1}{2} \int_{0}^{\frac{\pi}{2}} x \sec ^{2} \frac{x}{2} d x+\int_{0}^{\frac{\pi}{2}} \frac{\sin \frac{x}{2}}{\cos \frac{x}{2}} d x \\ &=\frac{1}{2} \int_{0}^{\frac{\pi}{2}} x \sec ^{2} \frac{x}{2} d x+\int_{0}^{\frac{\pi}{2}} \tan \frac{x}{2} d x \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \quad\left[\frac{\sin x}{\cos x}=\tan x\right] \end{aligned}

Applying integration by parts method to first part of integral then,

\begin{aligned} &=\frac{1}{2}\left\{\left[x \int \sec ^{2} \frac{x}{2} d x\right]_{0}^{\frac{\pi}{2}}-\int_{0}^{\frac{\pi}{2}}\left(\frac{d}{d x}(x) \int \sec ^{2} \frac{x}{2} d x\right) d x\right\}+\int_{0}^{\frac{\pi}{2}} \tan \frac{x}{2} d x \\ &=\frac{1}{2}\left\{\left[\frac{x \tan \frac{x}{2}}{\frac{1}{2}}\right]_{0}^{\frac{\pi}{2}}-\int_{0}^{\frac{\pi}{2}} 1 \frac{\tan \frac{x}{2}}{\frac{1}{2}} d x\right\}+\int_{0}^{\frac{\pi}{2}} \tan \frac{x}{2} d x \mid \end{aligned}

\begin{aligned} &\left.=\frac{1}{2}\left\{2\left[x \tan \frac{x}{2}\right]_{0}^{\frac{\pi}{2}}-2 \int_{0}^{\frac{\pi}{2}} \tan \frac{x}{2} d x\right\}+\int_{0}^{\frac{\pi}{2}} \tan \frac{x}{2} d x \quad \int \sec ^{2} \frac{x}{a} d x=\frac{\tan \frac{x}{a}}{\frac{1}{a}}, \frac{d(x)}{d x}=1\right] \\ &=\left[x \tan \frac{x}{2}\right]_{0}^{\frac{\pi}{2}}-\int_{0}^{\frac{\pi}{2}} \tan \frac{x}{2} d x+\int_{0}^{\frac{\pi}{2}} \tan \frac{x}{2} d x \\ &=\left[\frac{\pi}{2} \tan \frac{\pi}{2 \times 2}-0 \times \tan \frac{0}{2}\right]-0 \end{aligned}

\begin{aligned} &=\left[\frac{\pi}{2} \tan \frac{\pi}{4}-0\right] \\ &=\frac{\pi}{2} \times 1\; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \; \quad\left[\tan \frac{\pi}{4}=1, \tan 0=0\right] \\ &=\frac{\pi}{2} \end{aligned}