Find integration of (cosx + sinx)^2 with respect to x

The given function is \( \displaystyle (\cos x + \sin x)^2 \) and we need to find the integration of this function with respect to \( x \).

Solution:

\( \begin{align*} &\int (\cos x + \sin x)^2 \, dx \\ &= \int (\cos^2 x + \sin^2 x + 2 \sin x \cos x) \, dx \\ &= \int (1 + \sin 2x) \, dx \\ &[ \cos^2 x + \sin^2 x = 1 \quad \text{(Pythagorean identity)} \\ &\text{ and } 2 \sin x \cos x = \sin 2x \quad \text{(Double-angle identity)}] \\ &= \int 1 \, dx + \int \sin 2x \, dx \\ &= x -\frac{1}{2} \cos 2x + C, \quad \text{C is a constant} \\ \end{align*} \)

Thus, the integration of the given function is

\( \displaystyle \boxed{\int (\cos x + \sin x)^2 \, dx = x \,- \frac{1}{2} \cos 2x + C} \)

Please let me know in the comments if you find any errors in this solution.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.