Can someone walk me through how to evaluate the integral $$\int \sin^2 (x+\frac{\pi}{6}) dx?$$
I get as far as $$\int \frac {1 - \cos(x + \frac{\pi}{6})}2dx,$$ but I am not sure how to proceed.
Can someone walk me through how to evaluate the integral $$\int \sin^2 (x+\frac{\pi}{6}) dx?$$
I get as far as $$\int \frac {1 - \cos(x + \frac{\pi}{6})}2dx,$$ but I am not sure how to proceed.
On
Careful with formula $$ \sin^2\left(t\right)=\frac{1-\cos\left(2t\right)}{2} $$
Then using linearity $$ \int \frac{1-\cos\left(2x+\frac{\pi}{3}\right)}{2}\text{d}x=\int \frac{1}{2}-\frac{1}{2}\int \cos\left(2x+\frac{\pi}{3}\right) $$ Hence
$$ \int \frac{1-\displaystyle \cos\left(2x+\frac{\pi}{3}\right)}{2}\text{d}x=\frac{x}{2}-\frac{1}{4}\sin\left(2x+\frac{\pi}{3}\right)+K$$
On
Note that in the particular case of $\sin^2(x)$ and $\cos^2(x)$ there is a trick you can use.
$\begin{cases}\cos^2(x)+\sin^2(x)=1\\\cos^2(x)-\sin^2(x) = \big(\sin(x)\cos(x)\big)' \end{cases}$
Thus if we call $C=\int\cos^2$ and $S=\int\sin^2$ we get the system below
$\begin{cases}C(x)+S(x)=x+cst\\C(x)-S(x)=\sin(x)\cos(x)+cst\end{cases}$
Which easily solves to
$\begin{cases}C(x)=\frac x2+\frac 12\sin(x)\cos(x)+cst\\S(x)=\frac x2-\frac 12\sin(x)\cos(x)+cst\end{cases}$
In your problem, you just translate by $\frac\pi6$ and get $I = \frac{x+\frac\pi6}2-\frac 12\sin(x+\frac\pi6)\cos(x+\frac\pi6)+cst$
I let convince yourself it is the same answer than Atmos's ($\frac{\pi}{12}$ is absorbed by the $cst$ term, and $\sin\cos$ is transformed using the doubled angle).
On
$$\int sin^2(x+\frac{\pi}{6})dx$$
Apply u-substitution: $u=x+\frac{\pi}{6}$ $$=\int sin^2(u)du$$ Use the following identity: $sin^2(x)=\frac{1-cos(2x)}{2}$ $$=\int \frac{1-cos(2u)}{2}du$$ $$=\frac12 \int 1-cos(2u)du$$ $$=\frac12(\int 1du-\int cos(2u)du)$$ $$=\frac12(u-\frac12)sin(2u)$$ Substitute back $u=x+\frac{\pi}{6}$ $$\int sin^2(x+\frac{\pi}{6})dx=\frac12(x+\frac{\pi}{6}-\frac12sin(2(x+\frac{\pi}{6})))+C$$
You've made a slight error which would affect your overall answer, but you can evaluate the integral you achieved, but got stuck with. I'll show you how, so you can apply it to the correct integral
$$\int{\frac{1-\cos(x+\frac\pi6)}{2}dx}=\frac12\int1-\cos(x+\frac\pi6)dx$$ $$=\frac12\bigg[x-\sin(x+\frac\pi6)\bigg]=\frac x2-\frac12\sin(x+\frac\pi6)+C$$
I'll show you your mistake, then you can follow similar steps to solve its integral:
$$\cos(2x)=1-2\sin^2(x)\to 2\sin^2(x)=1-\cos(2x)\to\sin^2(x)=\frac{1-\cos(2x)}{2}$$ So you are integrating: $$\int{\frac{1-\cos(2x+\frac\pi3)}{2}dx}$$ Hint if you get stuck: $\int{\cos(2x)dx}=\frac 12\sin2x+C$