Answer
$\int {{{\sec }^n}x} dx = \frac{1}{{n - 1}}{\sec ^{n - 2}}x\tan x + \frac{{n - 2}}{{n - 1}}\int {{{\sec }^{n - 2}}x} dx$
Work Step by Step
$$\eqalign{
& \int {{{\sec }^n}x} dx \cr
& \cr
& {\text{Split the integrand}}{\text{, recall that }}{a^{m + n}} = {a^m}{a^n} \cr
& = \int {{{\sec }^{n + 2 - 2}}x} dx = \int {{{\sec }^{n - 2}}x{{\sec }^2}x} dx \cr
& \cr
& {\text{Integrating by parts}} \cr
& {\text{Let }}u = {\sec ^{n - 2}}x,{\text{ }}du = \left( {n - 2} \right){\sec ^{n - 2 - 1}}x\sec x\tan dx \cr
& {\text{ }}du = \left( {n - 2} \right){\sec ^{n - 2}}x\tan dx \cr
& dv = {\sec ^2}x,{\text{ }}v = \tan x \cr
& {\text{By the integration by parts formula }}\int {udv} = uv - \int {vdu} \cr
& \int {{{\sec }^n}x} dx = \left( {{{\sec }^{n - 2}}x} \right)\left( {\tan x} \right) - \int {\left( {\tan x} \right)} \left( {n - 2} \right){\sec ^{n - 2}}x\tan dx \cr
& \int {{{\sec }^n}x} dx = {\sec ^{n - 2}}x\tan x - \left( {n - 2} \right)\int {{{\tan }^2}x} {\sec ^{n - 2}}xdx \cr
& \cr
& {\text{Pythagorean identity }}{\tan ^2}x = {\sec ^2}x - 1 \cr
& \int {{{\sec }^n}x} dx = {\sec ^{n - 2}}x\tan x - \left( {n - 2} \right)\int {\left( {{{\sec }^2}x - 1} \right)} {\sec ^{n - 2}}xdx \cr
& \int {{{\sec }^n}x} dx = {\sec ^{n - 2}}x\tan x - \left( {n - 2} \right)\int {\left( {{{\sec }^n}x - {{\sec }^{n - 2}}x} \right)} dx \cr
& \int {{{\sec }^n}x} dx = {\sec ^{n - 2}}x\tan x - \left( {n - 2} \right)\int {{{\sec }^n}x} dx \cr
& {\text{ }} + \left( {n - 2} \right)\int {{{\sec }^{n - 2}}x} dx \cr
& {\text{Collect the terms of integrals }}\int {{{\sec }^n}x} dx{\text{ into left side}} \cr
& \int {{{\sec }^n}x} dx + \left( {n - 2} \right)\int {{{\sec }^n}x} dx = {\sec ^{n - 2}}x\tan x \cr
& {\text{ }} + \left( {n - 2} \right)\int {{{\sec }^{n - 2}}x} dx \cr
& \cr
& {\text{Factoring left side}} \cr
& \int {{{\sec }^n}x} dx\left( {1 + n - 2} \right) = {\sec ^{n - 2}}x\tan x + \left( {n - 2} \right)\int {{{\sec }^{n - 2}}x} dx \cr
& \int {{{\sec }^n}x} dx\left( {n - 1} \right) = {\sec ^{n - 2}}x\tan x + \left( {n - 2} \right)\int {{{\sec }^{n - 2}}x} dx \cr
& \cr
& {\text{Solve for }}\int {{{\sec }^n}x} dx \cr
& \int {{{\sec }^n}x} dx = \frac{1}{{n - 1}}{\sec ^{n - 2}}x\tan x + \frac{{n - 2}}{{n - 1}}\int {{{\sec }^{n - 2}}x} dx \cr} $$