Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

For a Homework, I need $\int \frac{x}{(x-1)^2} dx$ as an intermediate result. Using partial integration, I derive $x$ and integrate $\frac{1}{(x-1)^2}$, getting: $$ \frac{-x}{x-1} + \int \frac{1}{x-1} dx = \ln(x-1)+\frac{x}{x-1} $$ WolframAlpha tells me this is wrong (it gives me $\frac{1}{1-x}$ where I have $\frac{x}{x-1}$). If I and WA disagree the error is usually somewhere on my side. Unfortunately WA uses partial fractions there instead of partial integration, so I'm not sure which step I screwed up. Supposedly $\int f'g dx = fg - \int fg' dx$ right?

(I leave the constant +C out because it's not relevant for the problem I need this for).

share|cite|improve this question
You lost the $-$ in going from $-x/(x-1)$ to $x/(x-1)$. Apart from that, you and WA agree: note that $x/(x-1)$ and $1/(x-1)$ differ by a constant – Robert Israel Jun 17 '12 at 15:53
$\dfrac{x}{x-1}$ is the same as $\dfrac{1}{x-1}+\text{constant}$, where the "constant" is $1$. – Michael Hardy Jun 17 '12 at 17:41
By the way, it might have been easier to substitute $u=x-1$, then divide through and integrate. – Mike Jun 17 '12 at 18:49
up vote 4 down vote accepted

You’ve a sign error: you should have $$\ln(x-1)-\frac{x}{x-1}\;.$$

Now note that


so your (corrected) answer can be written $$\ln(x-1)-1-\frac1{x-1}=\ln(x-1)+\frac1{1-x}-1\;.$$

Your (corrected) answer differs from WA’s by a constant, which is absorbed in the constant of integration; both are perfectly good antiderivatives of the given function.

share|cite|improve this answer
Thanks. I "fixed" the sign when I wrote this by accident (I had it right in my notes, then for some reason when I wrote it here I thought it was wrong). – Cubic Jun 17 '12 at 19:11

the result is : $\ln|x-1| - \frac x{x-1} + C$ where $C$ is some constant. If $C=1$ you get : $\ln |x-1| + \frac 1{1-x}$ The finaly result can be expressed : $$F(x) = \ln |x-1| + \frac 1{1-x} + \lambda$$ where $\lambda$ is some constant. Precesely : $$F(x) = \ln (x-1) + \frac 1{1-x} + \lambda$$ on the intervale $]1,+\infty[$ and: $$F(x) = \ln (1-x) + \frac 1{1-x} + \lambda$$ on the intervale: $]-\infty ,1[$

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.