Integrate $\int \frac {x^4}{\sqrt {x^2-9}} \,dx$ Integrate $\int \dfrac {x^4}{\sqrt {x^2-9}} dx$
My Attempt:
Let $x=3\sec (\theta )$
$$dx=3\sec (\theta).\tan (\theta).d\theta$$
Then,
$$=\int \dfrac {x^4}{\sqrt {x^2-9}}$$
$$=\int \dfrac {81. \sec^4 (\theta)}{\sqrt {(3\sec (\theta))^2 - 9}} 3\sec (\theta).\tan (\theta).d\theta $$
$$=\int \dfrac {81 \sec^5 (\theta). 3\tan (\theta).d\theta}{3\tan (\theta)}$$
$$=81\int \sec^5 (\theta) d\theta$$

To integrate $\int \sec^5 (\theta) d\theta$, use integration by parts.
u = $\sec^3 (\theta)$
dv = $\sec^2 (\theta) d\theta$
And so du = $\sec^3\theta\tan\theta d \theta$
and $v = \tan\theta$
Thus $$\int \sec^5 (\theta) d\theta = \sec^3 (\theta) \tan \theta - \int 3\sec^3\theta(sec^2\theta-1)d\theta = \sec^3 (\theta) \tan \theta - 3\int \sec^5\theta d\theta + 3\int \sec^3\theta d\theta$$
Move the $3\int \sec^5\theta d\theta$ to the left
$$4\int sec^5\theta d\theta = \sec^3\theta \tan \theta + 3\int sec^3 \theta d\theta$$
Now we have to find $\int \sec^3 \theta d\theta $, which can be done by using integration by parts as well. I skipped a step where you convert $\tan^2 \theta$ to $\sec^2 \theta -1$ so that one of the terms have an integral with secant to the power of the original integral you are looking for.
$$u = \sec \theta$$
$$dv = \sec^2 \theta d \theta$$
$$\int sec^3 \theta d \theta = \sec \theta \tan \theta - \int \sec \theta \tan^2 \theta d \theta$$
$$\int \sec^3 \theta d \theta = \sec \theta \tan \theta - \int \sec^3 \theta d \theta + \int \sec \theta d \theta $$
$$ 2\int \sec^3 \theta d\theta = \sec \theta \tan \theta + \int \sec \theta d \theta$$
$$ \int \sec^3 \theta d \theta = \frac{1}{2} \sec \theta \tan \theta + \frac{1}{2} \ln\left|sec \theta + \tan \theta \right| + C$$
Sub the value of $\int \sec^3 \theta d \theta $ back to the original equation, we get:
$$ \int sec^5\theta d\theta = \frac{1}{4} \sec^3 \theta \tan \theta + \frac{3}{8} \sec \theta \tan \theta + \frac{3}{8} ln\lvert \sec \theta + \tan \theta \rvert + C $$
Since $\theta = arcsec \frac{x}{3}$, we can simply plug it in. Note that according to the Pythagorean theorem, $\cos \theta = \frac{3}{x}$ implies that $\tan \theta = \frac{\sqrt{x^2-9}}{3}$.
$$ \int sec^5\theta d\theta = \frac{x^3\sqrt{x^2-9}}{4*81} + \frac{x\sqrt{x^2-9}}{8*3} + \frac{3}{8}\ln \left| \frac{x+\sqrt{x^2-9}}{3}\right| + C$$
Multiply both sides by 81
$$ 81 \int sec^5\theta d\theta = \frac{x^3\sqrt{x^2-9}}{4} + \frac{27x\sqrt{x^2-9}}{8} + \frac{243}{8}\ln \left|\frac{x+\sqrt{x^2-9}}{3} \right|t + C$$
So the answer is: 
$$ \int \dfrac {x^4}{\sqrt {x^2-9}} dx = \frac{x^3\sqrt{x^2-9}}{4} + \frac{27x\sqrt{x^2-9}}{8} + \frac{243}{8}\ln \left| \frac{x+\sqrt{x^2-9}}{3}\right| + C$$
Notice that you can split $\ln \left| \frac{x+\sqrt{x^2-9}}{3} \right|$ into the difference of two natural logs, but it is probably not necessary. 
I found out that some people already posted the generalized form of this method, but this is more elaborate if you want the detailed steps. 
