Cannot understand an Integral $$\displaystyle \int _{ \pi /6 }^{ \pi /3 }{ \frac { dx }{ \sec x+\csc x } } $$
I had to solve the integral and get it in this form. 
My attempt:
$$\int _{ \pi /6 }^{ \pi /3 }{ \frac { dx }{ \sec x+\csc x } } $$
$$=\int _{\frac{\pi}{6}}^{ \frac{\pi}{3}} \dfrac{\sin x \cos x }{ \sin x+\cos x }dx $$ 
Substituting $t=\tan(\frac{x}{2})$,
$$\int_{\tan(\frac{\pi}{12})}^{\tan(\frac{\pi}{6})} \dfrac{2t}{1+t^2}\times\dfrac{1-t^2}{1+t^2}\times\dfrac{2}{1+t^2}dt$$
$$2\int_{2-\sqrt{3}}^{\frac{1}{\sqrt{3}}} \dfrac{2t(1-t^2)}{(1+t^2)^3}dt$$
Substituting $u=1+t^2$, $2t dt=du$, $1-t^2 = 2-u$
$$2\int_{8-4\sqrt{3}}^\frac{4}{3} \dfrac{(2-u)}{u^3}du$$
$$\displaystyle 4\int_{8-4\sqrt{3}}^\frac{4}{3} \dfrac{du}{u^3} \displaystyle -2\int_{8-4\sqrt{3}}^\frac{4}{3} \dfrac{du}{u^2}$$ Could somebody please tell me where I have gone wrong? Also could someone please tell me how to change the limits of the definite integral throughout? 

Here is an alternate method you could use:
Multiply $\displaystyle\int\frac{\sin x\cos x}{\sin x+\cos x}dx$ on the top and bottom by $\cos x-\sin x$ to get 
$\hspace{.6 in}\displaystyle\int\frac{\cos^2x\sin x}{2\cos^2 x-1}dx-\int\frac{\sin^2x\cos x}{1-2\sin^2 x}dx$.
Now substitute $u=\cos x$ in the first integral and $u=\sin x$ in the second integral to get
$\displaystyle\int\frac{u^2}{1-2u^2}du=\frac{1}{2}\int\big(-1+\frac{1}{1-2u^2}\big)du=\frac{1}{2}\bigg[-u+\frac{\sqrt{2}}{4}\ln\bigg|\frac{1+\sqrt{2}u}{1-\sqrt{2}u}\bigg|\bigg]+C$
using partial fractions.
Now you can let $u=\cos x$ in the first term and $u=\sin x$ in the second to get
$\displaystyle\frac{1}{2}\bigg[-u+\frac{\sqrt{2}}{4}\ln\bigg|\frac{1+\sqrt{2}u}{1-\sqrt{2}u}\bigg|\bigg]_{\frac{\sqrt{3}}{2}}^{\frac{1}{2}}-\frac{1}{2}\bigg[-u+\frac{\sqrt{2}}{4}\ln\bigg|\frac{1+\sqrt{2}u}{1-\sqrt{2}u}\bigg|\bigg]_{\frac{1}{2}}^{\frac{\sqrt{3}}{2}}$

Notice that substituting $t=\tan\frac{x}{2}$ gives
$\displaystyle\int{\frac{\sin x\cos x}{\sin x+ \cos x} dx=\int\frac{\frac{2t}{1+t^2}\cdot\frac{1-t^2}{1+t^2}}{\frac{2t}{1+t^2}+\frac{1-t^2}{1+t^2}}}\cdot\frac{2}{1+t^2}dt=\int\frac{4t(1-t^2)}{(1+t^2)^2(1+2t-t^2)}dt$,
and now you can use partial fractions to continue.
