\documentclass[a4paper]{article}
\begin{document}
\begin{eqnarray*}
f (x)
 & = & \tan^{7} (ax) \\
& = & \frac{1}{\cot^{7} (ax)} \\
& = & \cot^{-7} (ax) \\
\end{eqnarray*}
\newpage
\begin{eqnarray*}
F (x)
 & = & \int \tan^{7} (ax) \, \mbox{d}x \\
& = & \int \frac{\sin^{7} (ax)}{\cos^{7} (ax)} \, \mbox{d}x \\
& = & \int \frac{\sin (ax) \sin^{6} (ax)}{\cos^{7} (ax)} \, \mbox{d}x \\
& = & \int \frac{\sin (ax) (\sin^{2} (ax))^{3}}{\cos^{7} (ax)} \, \mbox{d}x \\
& = & \int \frac{\sin (ax) (1 - \cos^{2} (ax))^{3}}{\cos^{7} (ax)} \, \mbox{d}x \\
& = & \int \frac{\sin (ax) (1 - 3 \cos^{2} (ax) + 3 \cos^{4} (ax) - \cos^{6} (ax))}{\cos^{7} (ax)} \, \mbox{d}x \\
& = & \int \frac{\sin (ax) - 3 \sin (ax) \cos^{2} (ax) + 3 \sin (ax) \cos^{4} (ax) - \sin (ax) \cos^{6} (ax)}{\cos^{7} (ax)} \, \mbox{d}x \\
& = & \int \left ( \frac{\sin (ax)}{\cos^{7} (ax)} - 3 \frac{\sin (ax) \cos^{2} (ax)}{\cos^{7} (ax)}
 + 3 \frac{\sin (ax) \cos^{4} (ax)}{\cos^{7} (ax)} - \frac{\sin (ax) \cos^{6} (ax)}{\cos^{7} (ax)} \right ) \, \mbox{d}x \\
& = & \int \left ( \frac{\sin (ax)}{\cos^{7} (ax)} - 3 \frac{\sin (ax)}{\cos^{5} (ax)}
 + 3 \frac{\sin (ax)}{\cos^{3} (ax)} - \frac{\sin (ax)}{\cos (ax)} \right ) \, \mbox{d}x \\
& = & \int \left ( \frac{\sin (ax)}{\cos^{7} (ax)} - 3 \frac{\sin (ax)}{\cos^{5} (ax)}
 + 3 \frac{\sin (ax)}{\cos^{3} (ax)} - \tan (ax) \right ) \, \mbox{d}x \\
\end{eqnarray*}
\newpage
\begin{eqnarray*}
F (x)
 & = & \int \left ( \frac{\sin (ax)}{\cos^{7} (ax)} - 3 \frac{\sin (ax)}{\cos^{5} (ax)}
 + 3 \frac{\sin (ax)}{\cos^{3} (ax)} - \tan (ax) \right ) \, \mbox{d}x \\
& = & \frac{1}{6a} \frac{1}{\cos^{6} (ax)} - \frac{3}{4a} \frac{1}{\cos^{4} (ax)}
 + \frac{3}{2a} \frac{1}{\cos^{2} (ax)} + \frac{1}{a} \ln | \, \cos (ax) \, | + c \\
& = & \frac{1}{6a} \sec^{6} (ax) - \frac{3}{4a} \sec^{4} (ax) + \frac{3}{2a} \sec^{2} (ax) + \frac{1}{a} \ln | \, \cos (ax) \, | + c \\
\end{eqnarray*}
\newpage
\begin{eqnarray*}
f (x)
 & = & \frac{\mbox{d}(F (x))}{\mbox{d}x} \\
& = & \frac{\mbox{d}}{\mbox{d}x} \left ( \frac{1}{6a} \sec^{6} (ax) - \frac{3}{4a} \sec^{4} (ax) + \frac{3}{2a} \sec^{2} (ax)
 + \frac{1}{a} \ln | \, \cos (ax) \, | + c \right ) \\
& = & \frac{1}{6a} \cdot 6 \sec^{5} (ax) \frac{\sin (ax)}{\cos^{2} (ax)} a
 - \frac{3}{4a} \cdot 4 \sec^{3} (ax) \frac{\sin (ax)}{\cos^{2} (ax)} a
 + \frac{3}{2a} \cdot 2 \sec (ax) \frac{\sin (ax)}{\cos^{2} (ax)} a \\
 & & \qquad + \, \frac{1}{a} \frac{1}{\cos (ax)} (- \sin (ax)) a + 0 \\
& = & \frac{1}{\cos^{5} (ax)} \frac{\sin (ax)}{\cos^{2} (ax)}
 - 3 \frac{1}{\cos^{3} (ax)} \frac{\sin (ax)}{\cos^{2} (ax)}
 + 3 \frac{1}{\cos (ax)} \frac{\sin (ax)}{\cos^{2} (ax)}
 - \frac{\sin (ax)}{\cos (ax)} \\
& = & \frac{\sin (ax)}{\cos^{7} (ax)} - 3 \frac{\sin (ax)}{\cos^{5} (ax)} + 3 \frac{\sin (ax)}{\cos^{3} (ax)} - \frac{\sin (ax)}{\cos (ax)} \\
& = & \frac{\sin (ax)}{\cos^{7} (ax)} - 3 \frac{\sin (ax) \cos^{2} (ax)}{\cos^{7} (ax)}
 + 3 \frac{\sin (ax) \cos^{4} (ax)}{\cos^{7} (ax)} - \frac{\sin (ax) \cos^{6} (ax)}{\cos^{7} (ax)} \\
& = & \frac{\sin (ax) - 3 \sin (ax) \cos^{2} (ax) + 3 \sin (ax) \cos^{4} (ax) - \sin (ax) \cos^{6} (ax)}{\cos^{7} (ax)} \\
& = & \frac{\sin (ax) (1 - 3 \cos^{2} (ax) + 3 \cos^{4} (ax) - \cos^{6} (ax))}{\cos^{7} (ax)} \\
& = & \frac{\sin (ax) (1 - \cos^{2} (ax))^{3}}{\cos^{7} (ax)} \\
& = & \frac{\sin (ax) (\sin^{2} (ax))^{3}}{\cos^{7} (ax)} \\
& = & \frac{\sin (ax) \sin^{6} (ax)}{\cos^{7} (ax)} \\
& = & \frac{\sin^{7} (ax)}{\cos^{7} (ax)} \\
& = & \tan^{7} (ax) \\
\end{eqnarray*}
\newpage
\begin{eqnarray*}
F (x)
 & = & \frac{1}{a} \ln | \, \cos (ax) \, | + \frac{3}{2a} \sec^{2} (ax) \\
 & & \quad - \, \frac{3}{4a} \sec^{4} (ax) + \frac{1}{6a} \sec^{6} (ax) + c \\
\end{eqnarray*}
\end{document}
