find the integral:

∫tan^6 (x) dx

Put tan(x) = u ---->

x = arctan(u) ---->

dx = du/(1+u^2)

Integral of u^6/(1+u^2) du =

Integral of

(u^6 + u^4 - u^4 - u^2 + u^2 + 1 -1)/
(u^2 + 1) du =

Integral of

(u^4 - u^2 + 1) du - Integral of
1/(1+u^2) du =

1/5 u^5 - 1/3 u^3 + u - arctan(u) + c=

1/5 tan^5(x) - 1/3 tan^3(x) + tan(x) - x + c