Evaluate $\int \frac{x^2}{x-1} \,dx$ Evaluate $\int \frac{x^2}{x-1} \,dx$
(A) $2x^2+x+\ln|x-1|+C$
(B) $\frac{x^2}{2}+x+\ln|x+1|+C$
(C) $\frac{x^2}{2}+x+\ln|x-1|+C$
(D) $x^2+x+\ln|x-1|+C$
My attempt :
Let $u=x-1$, so : $du=dx$ and $u+1$
$\int \frac{(u+1)^2}{u}\,du\\
=\int u +2+\frac{1}{u}\,du\\
=\frac{u^2}{2}+2u+\ln|u|+C\\
=\frac{(x-1)^2}{2}+2(x-1)+\ln|x-1|+C$
Simplify :
$\frac{x^2-3}{2}+x+\ln|x-1|+C$
It's not on the option.
 A: You have the right answer; you just have a different constant. Using $C_1$ instead of $C$, set your answer
$$\frac{x^2-3}{2}+x+\ln|x-1|+C_1$$
equal to option (C) and simplify. You'll get $C-C_1=-\frac32$, which is fine since the difference is constant.
Now, as an alternative approach to the problem, consider that you could find the derivative of each option and see which one reduces to $\frac{x^2}{x-1}$. Differentiation is typically easier than integration, and with multiple-choice questions it can be helpful to work backwards.

As a side note, it isn't really correct to say that $\int\frac1x\ dx=\ln|x|+C$, because of the discontinuity of $\frac1x$ at $0$. It's a bit more nuanced than that:
$$
\int\frac1x\ dx =
\begin{cases}
\ln|x| + C_1, & \text{if $x > 0$} \\
\ln|x| + C_2, & \text{if $x < 0$}
\end{cases}$$
So in that sense, even the given answers are not entirely right.
A: Your answer is right except for the constant I changed.
$$\frac{x^2-3}{2}+x+\ln|x-1|+C_1 = \frac{x^2}{2}+x+\ln|x-1|+C_1-\frac{3}{2} = \frac{x^2}{2}+x+\ln|x-1|+C$$
A: After some rather basic algebraic manipulations, all you're left with is a pretty simple u-substantiation problem:
$$
\begin{align}
\int \frac{x^2}{x-1} \,dx
&=\int \frac{x^2-1+1}{x-1} \,dx\\
&=\int \left(\frac{x^2-1}{x-1}+\frac{1}{x-1}\right) \,dx\\
&=\int \frac{(x-1)(x+1)}{x-1}\,dx+\int\frac{1}{x-1} \,dx\\
&=\int \left(x+1\right)\,dx+\int\frac{1}{x-1}\frac{d}{dx}\left(x-1\right) \,dx\\
&=\frac{x^2}{2}+x+\int\frac{1}{x-1}\,d\left(x-1\right)\\
&=\frac{x^2}{2}+x+\ln{\left|x-1\right|}+C.\\
\end{align}
$$
