Integrating $\int \frac{r^3}{\sqrt{16 + r^2}} dr$ I need to calculate: $$\int \frac{r^3}{\sqrt{16 + r^2}} dr$$
I am currently in the midst of learning AP Calculus BC and the lesson from which this problem came from goes over integration by parts.
Basically, it utilizes that : $$\frac{d}{dx} \left[ f(x)g(x) \right] = f'(x)g(x) + f(x)g'(x)$$ in order to get: $$\int f'(x)g(x) dx = f(x)g(x) - \int f(x)g'(x) dx.$$
Sometimes, we have to apply this process multiple times.
However, for this question, I cannot seem to figure out what to set $f(x)$ and $g(x)$ to. So far, I have tried setting $f(x) = x \rightarrow f'(x) = 1$ and $g(x) = \frac{x^3}{\sqrt{16 + x^2}}$.
This left me needing to calculate $$\int x \cdot \frac{2x^2 (x^2 + 24)}{ (16 + x^2)^{\frac{3}{2}}}$$ which I have no idea how to do.
For my second attempt, I tried letting $f(x) = \frac{1}{4} x^4 \rightarrow f'(x) = x^3$ and $g(x) = \frac{1}{\sqrt{16 + x^2}}.$
This led to me needing to calculate: $$\int \frac{1}{4} x^4 \cdot \bigg(- \frac{x}{(16 + x^2)^{\frac{3}{2}}} \bigg)$$ which I have also been unable to compute.
What should I set $f(x)$ and $g(x)$ to? Thank you in advance for any help.
 A: First substitution: $x=r^2$ with $\mathrm{d}x = 2r \mathrm{d}r$, giving you:
$$\int \frac 12 \frac{x}{\sqrt{16 + x}} \mathrm{d}x$$.
Now shifting: $y=x+16$ with $\mathrm{d}y = \mathrm{d}x$:
$$\frac 12\int\sqrt{y}\mathrm{d}y - 8\int\frac 1{\sqrt{y}}\mathrm{d}y$$.
If you really want integration by parts use: $f(r)=r^2$ and $g(r)=\frac{r}{\sqrt{r^2+16}}$. $f'(r)=2r$ and $G(r)=\int g(r)\mathrm{d}r = \sqrt{r^2 + 16}  + C$.
You are left with evaluation $\int r\sqrt{r^2+16}\mathrm{d}r$. Here IBP with $f(r)=r$ and $g(r)=\sqrt{r^2+16}$ yields the result or noting that $f(r)$ is proportional to the derivative of the interior of the square root.
A: The fastest way to solve this integral (IMO), does not use IBP.  We let
\begin{align*}
u &= \sqrt{16 + r^2} &&\implies \boxed{r^2 = u^2 - 16}\\
\frac{du}{dr} &= \frac{2r}{2\sqrt{16+r^2}}&&\implies\boxed{du = {\frac{r}{\sqrt{16+r^2}}}\,dr.}
\end{align*}
Making this substitution:
\begin{align*}\int \frac{r^{3}}{\sqrt{16+r^2}}\,dr &= \int r^2\,du\\
&= \int (u^2-16)\,du\\
&= \frac{u^{3}}{3} - 16u + C\\
&= \boxed{\frac{(16+r^2)^{3/2}}{3} - 16\sqrt{16+r^2} + C.}
\end{align*}
A: With a bit of experience, it becomes easy to recognize
$$\int{r\over\sqrt{16+r^2}}\,dr=\sqrt{16+r^2}+C$$
Integration by parts now suggests letting $u=r^2$ and $dv=r/\sqrt{16+r^2}$, so that
$$\int{r^3\over\sqrt{16+r^2}}\,dr=r^2\sqrt{16+r^2}-\int2r\sqrt{16+r^2}\,dr=r^2\sqrt{16+r^2}-{2\over3}(16+r^2)^{3/2}+C$$
where the final integration is again made easy through experience.
By "experience" all I mean is that after you've differentiated functions of the form $(a+x^2)^{k/2}$ a few times, getting $kx(a+x^2)^{k/2-1}$, you know that an integral of the form $\int x(a+x^2)^{k/2}\,dx$ will integrate to a multiple of $(a+x^2)^{k/2+1}$, so it becomes easy to write that part down and then figure out what the multiplying coefficient in front of it has to be.
A: Use substitution $z=16+r^2,~\text{d}z=2r\text{d}r$. You get
\begin{align}
\frac{1}{2}\int z^{\frac{1}{2}}\,\text{d}z-8\int z^{-\frac{1}{2}}\,\text{d}z
\end{align}
which yields then easily  the result $\sqrt{16+r^2}\frac{r^2-32}{3}+C$.
