Integration by parts: How to choose the constant which make calculations easier? The formula of integration by parts is:
$$\int u(x)v(x) dx = u(x)V(x) - \int u'(x)V(x) dx$$
Which can be re-written  as:
$$\int u(x)v(x) dx = u(x)[V(x)+C] - \int u'(x)[V(x)+C] dx$$ where C is a constant.
It makes some integration calculations simpler, such as:
$$\int x\tan^{-1}(x) dx$$
When we take $ u(x)=\tan^{-1}(x)$ and $v(x)=x .dx$, then $V(x)= \frac {x^2}2 + \frac 12$ instead of $V(x) = \frac {x^2}2$. It make steps calculations easier and simpler.
The question is: How to know and choose this constant? is there some guide or it just experience ?
 A: This is not as hard as it seems to, first note that
$$u(x)(V(x)+C)-\int u'(x)(V(x)+C)dx=u(x)V(x)+Cu(x)-\int\left(u'(x)v(x)+Cu'(x)\right)dx=u(x)V(x)- \int u'(x)V(x)dx+\underbrace{Cu(x)-C\int u'(x)dx}_{\mathrm{\text{these are equal}}}$$
So we can use this trick in every integral (not only in formula of integration by parts), where we know $u(x)$, or it's easy to compute.
The problem is to find such $C$ that
$$\int (u'(x)V(x) +Cu'(x))dx$$
is easier to compute. In your case $u'(x)=\frac{1}{x^2+1}$ and $V(x)=\frac12x^2$
$$\int \left(  \frac{\frac12x^2}{x^2+1} \right)dx\\
=\int \left(  \frac{\frac12x^2}{x^2+1} +\frac{C}{x^2+1}  \right)dx-C\arctan(x)\\
=\frac12 \int \left(  \frac{x^2}{x^2+1} +\frac{2C}{x^2+1}  \right)dx-C\arctan(x)\\
=\frac12 \int \left(  \frac{x^2+2C}{x^2+1} \right)dx-C\arctan(x)$$
It's evident that $2C=1$ will make calculations easier, so $C=\frac12$.
But there are not that much cases where it is useful and in all cases it will not make computations possible, just easier. And yes, this is experience, but if you don't use this trick nothing's wrong.
