How to Integrate Tangent/Secant Problems with an Even, Positive Power of Secant
Here’s how you integrate a trig integral that contains tangents and secants where the secant power is even and positive. Like with all tangent/secant integrals, you use the tangent-secant version of the Pythagorean identity,
Lop off a secant-squared(x) factor and move it to the right.
Convert the remaining secants to tangents with the Pythagorean identity,
Solve by substitution, where u = tan(x) and