<s>[INST] Integration with substitution I want to integrate (2x+1)/((x^2 - 6x + 14)^3)
I'm guessing you use substitution but im unsure what to substitute, is it best to make u = x^2 or X^2-6x or even x^2 - 6x + 14
I find that it makes turning the top of the fraction into terms of u very difficult
 [/INST] $$\begin{align} \int \frac{2x + 1} {(x^2 - 6x + 14)^3} & = \int \frac{2x - 6 + 6 + 1}{(x^2 - 6x + 14)^3}\,dx \\ \\ & = \int\dfrac{2x - 6}{(x^2 - 6x + 14)^3}\,dx + \int \frac{7}{(x^2 - 6x + 14)^3}\,dx \\ \\ &= \int\dfrac{\overbrace{2x - 6}^{du}}{(\underbrace{x^2 - 6x + 14}_{u})^3}\,dx + \int \frac{7}{(\underbrace{x^2 - 6x + 9}_{(x - 3)^2} + \underbrace{5}_{(\sqrt 5)^2})^3}\,dx \end{align}$$
The left-most integral: using $u = x^2 - 6x + 14 \implies du = 2x - 6, \,dx$
so we integrate $\displaystyle \int \frac {du}{u^3}$.
The right-most integral, we can use the substitution $x - 3 = \sqrt 5\tan \theta \implies dx = \sqrt 5 \sec^2 \theta\,d\theta$, to obtain the integral $$\displaystyle 7\int \frac{\sqrt 5 \sec^2 \theta \,d\theta}{(5 \tan^2 \theta + 5)^3}= 7\int \frac{\sqrt 5 \sec^2 \theta \,d\theta}{(5 (\tan^2 \theta +1))^3} =  7\int \frac{\sqrt 5 \sec^2 \theta \,d\theta}{(5 \sec^2\theta)^3} = \cdots$$
</s>