Answer
$$\frac{1}{3}\left(x^{3}+x\right)^3+c$$
Work Step by Step
Given $$\int\left(3 x^{2}+1\right)\left(x^{3}+x\right)^{2} d x$$
Let
$$u=x^{3}+x \ \ \ \Rightarrow \ \ du=(3x^2+1)dx $$
then
\begin{align*}
\int\left(3 x^{2}+1\right)\left(x^{3}+x\right)^{2} d x&= \int u^2du \\
&=\frac{1}{3}u^3+c\\
&=\frac{1}{3}\left(x^{3}+x\right)^3+c\\
\end{align*}