Evaluate the following. intfrac{cos^5(3z)dz}{sin^2(3z)}

Trigonometry
Evaluate the following.
$$\displaystyle\int{\frac{{{{\cos}^{{5}}{\left({3}{z}\right)}}{\left.{d}{z}\right.}}}{{{{\sin}^{{2}}{\left({3}{z}\right)}}}}}$$

2020-10-26
We have to find the integral of: $$\displaystyle\int{\frac{{{{\cos}^{{5}}{\left({3}{x}\right)}}}}{{{{\sin}^{{2}}{\left({3}{x}\right)}}}}}{\left.{d}{x}\right.}$$
Substitute $$\displaystyle{u}={3}{x}\Rightarrow{\frac{{{d}{u}}}{{{\left.{d}{x}\right.}}}}={3}\Rightarrow{\frac{{{d}{u}}}{{{3}}}}$$, we obtain $$\displaystyle\int{\frac{{{{\cos}^{{5}}{\left({3}{x}\right)}}}}{{{{\sin}^{{2}}{\left({3}{x}\right)}}}}}{\left.{d}{x}\right.}={\frac{{{1}}}{{{3}}}}\int{\frac{{{{\cos}^{{5}}{\left({3}{u}\right)}}}}{{{{\sin}^{{2}}{\left({3}{u}\right)}}}}}{d}{u}$$
Now solving: $$\displaystyle\int{\frac{{{{\cos}^{{5}}{\left({3}{u}\right)}}}}{{{{\sin}^{{2}}{\left({3}{u}\right)}}}}}{d}{u}=\int{\frac{{{{\cos}^{{5}}{\left({U}\right)}}}}{{{{\sin}^{{2}}{\left({U}\right)}}}}}{d}{U}$$
Preparing for substitution, we use: $$\displaystyle{{\cos}^{{2}}{U}}={1}-{{\sin}^{{2}}{U}}$$, we obtain
$$\displaystyle\int{\frac{{{{\cos}^{{5}}{\left({U}\right)}}}}{{{{\sin}^{{2}}{\left({U}\right)}}}}}{d}{U}$$
$$\displaystyle=\int{\cos{{\left({U}\right)}}}{\frac{{{\left({{\sin}^{{2}}{\left({U}\right)}}-{1}\right)}^{{2}}}}{{{{\sin}^{{2}}{\left({U}\right)}}}}}{d}{U}$$
Substitute $$\displaystyle{v}={\sin{{\left({U}\right)}}}\Rightarrow{\frac{{{d}{v}}}{{{d}{U}}}}={\cos{{\left({u}\right)}}}\Rightarrow{d}{u}={\frac{{{1}}}{{{\cos{{\left({u}\right)}}}}}}{d}{v}$$, we obtain:
$$\displaystyle=\int{\frac{{{\left({v}^{{2}}-{1}\right)}^{{2}}}}{{{v}^{{2}}}}}{d}{v}$$
$$\displaystyle=\int{\left({v}^{{2}}+{\frac{{{1}}}{{{v}^{{2}}}}}-{2}\right)}{d}{v}$$
$$\displaystyle=\int{\left({v}^{{2}}\right)}{d}{v}+\int{\left({\frac{{{1}}}{{{v}^{{2}}}}}\right)}{d}{v}-{2}\int{d}{v}$$
$$\displaystyle={\frac{{{v}^{{3}}}}{{{3}}}}-{\frac{{{1}}}{{{v}}}}+{v}$$
Now, we can undo the substitution $$\displaystyle{v}={\sin{{\left({u}\right)}}}$$, we obtain:
$$\displaystyle={\frac{{{v}^{{3}}}}{{{3}}}}-{\frac{{{1}}}{{{v}}}}-{2}{v}$$
$$\displaystyle={\frac{{{{\sin}^{{3}}{\left({u}\right)}}}}{{{3}}}}-{\frac{{{1}}}{{{\sin{{\left({u}\right)}}}}}}-{2}{\sin{{\left({u}\right)}}}$$
Plug in solved integrals,
$$\displaystyle{\frac{{{1}}}{{{3}}}}\int{\frac{{{{\cos}^{{5}}{\left({u}\right)}}}}{{{{\sin}^{{2}}{\left({u}\right)}}}}}{d}{u}$$
$$\displaystyle={\frac{{{{\sin}^{{3}}{\left({3}{x}\right)}}}}{{{9}}}}-{\frac{{{2}{\sin{{\left({3}{x}\right)}}}}}{{{3}}}}-{\frac{{{1}}}{{{3}{\sin{{\left({3}{x}\right)}}}}}}$$
which is the solution to our problem.
Hence, $$\displaystyle{\frac{{{1}}}{{{3}}}}\int{\frac{{{{\cos}^{{5}}{\left({u}\right)}}}}{{{{\sin}^{{2}}{\left({u}\right)}}}}}{d}{u}={\frac{{{{\sin}^{{3}}{\left({3}{x}\right)}}}}{{{9}}}}-{\frac{{{2}{\sin{{\left({3}{x}\right)}}}}}{{{3}}}}-{\frac{{{1}}}{{{3}{\sin{{\left({3}{x}\right)}}}}}}+{C}$$