4
$\begingroup$

$$\int \frac{dx}{x^2 - 2x}$$

I know that I have to complete the square so the problem becomes.

$$\int \frac{dx}{(x - 1)^2 -1}dx$$

Then I set up my A B and C stuff

$$\frac{A}{x-1} + \frac{B}{(x-1)^2} + \frac{C}{-1}$$

With that I find $A = -1, B = -1$ and $C = 0$ which I know is wrong.

I must be setting up the $A, B, C$ thing wrong but I do not know why.

  • 0
    Does your book require to use partial fractions in this case?2012-06-10
  • 5
    To use partial fractions, you have to factor the denominator completely and use the **factors** of the denominator. Is $(x-1)^2-1$ equal to $(x-1)^2(-1)$? No. If you are going to use partial fractions, you need to factor, and factoring here gives, either from $x^2-2x = x(x-2)$, or using difference of squares, $$(x-1)^2 -1 = \Bigl((x-1)+1\Bigr)\Bigl((x-1)-1\Bigr) = x(x-2).$$So if you are going to use partial fractions, you would need to set it up as $$\frac{1}{x^2-2x} = \frac{A}{x} + \frac{B}{x-2},$$not the mess you have.2012-06-12

4 Answers 4

2

I suppose that you could have also used trigonometric substitutions. Completing the square as you have done, we get that $$\displaystyle \int \frac{dx}{x^2-2x} = \int \frac{dx}{(x-1)^2 - 1}.$$

We now let $x-1 = \sec \theta.$ Notice then that $dx = \tan \theta \sec \theta \ d\theta.$ We now have $$ \int \frac{dx}{(x-1)^2 - 1} = \int \frac{\tan \theta \sec \theta \ d\theta}{\sec^2\theta-1} = \int \frac{\tan \theta \sec \theta \ d\theta}{\tan^2 \theta} = \int \frac{\sec \theta \ d\theta}{\tan \theta} = \int \csc \theta \ d\theta. $$ And, $$ \int \csc \theta \ d\theta = \ln (\csc \theta - \cot \theta) + C = \ln \left(\frac{\sqrt{x-2}}{\sqrt{x}} \right) + C,$$ as desired.

(This is because from $x-1 = \sec \theta,$ we get $1/(x-1) = \cos \theta$ and thus $\sin \theta = (\sqrt{x^2-2x})/(x-1)$, and we just make the necessary substitutions in $\csc \theta - \cot \theta$).

6

Added: "I know that I have to complete the square" is ambiguous. I interpreted it as meaning that the OP thought that completing the square was necessary to solve the problem.

Completing the square is not a universal tool. To find the integral efficiently, you certainly do not need to complete the square.

The simplest approach is to use partial fractions. The bottom factors as $x(x-2)$. Find numbers $A$ and $B$ such that $$\frac{1}{x^2-2x}=\frac{A}{x-2}+\frac{B}{x}.$$

  • 0
    My book is telling me that I have to complete the square though.2012-06-10
  • 1
    That is a truly weird recommendation. If you complete the square, the next step would be to let $u=x-1$, then you want $\int\frac{du}{u^2-1}$, for which the standard method is partial fractions!2012-06-10
  • 0
    @AndréNicolas: It's not weird, it has the same approach with an additional step. See my answer.2012-06-10
  • 2
    @Gigili: You used completing the square to factor $x^2-2x$?2012-06-10
  • 3
    I disagree with the advice not to complete the square. Certainly it is trivial to factor $x^2-2x$ without completing the square, but it may also be worthwhile to know how completing the square leads to the factorization. There is a lesson to be drawn from it. Completing the square gives you $(x-1)^2 - 1$. That can of course be factored as a difference of two squares. If you complete the square and get $a(x-h)^2+k$ then you do the problem one way if $k>0$, another if $k<0$, and another if $k=0$. That's a thing one should be aware of.2012-06-10
  • 0
    @AndréNicolas: That's what I did (as you can see), assuming the OP insists on completing the square.2012-06-10
  • 0
    @MichaelHardy: If one were lucky enough to meet this integral on a test, direct factorization would be the efficient way. Certainly for denominator $x^2+x-5$, completing the square or Quadratic Formula would be necessary.2012-06-10
  • 4
    @AndréNicolas : I wouldn't recomment completing the square if this appeared as a test question. But as an exercise, it's sometimes useful to learn several different ways of looking at something, and what can be learned from each.2012-06-10
6

My book is telling me that I have to complete the square

$$I=\begin{eqnarray*} \int \frac{dx}{x^{2}-2x} &=&\int \frac{dx}{\left( x-1\right) ^{2}-1}\overset{ u=x-1}{=}\int \frac{1}{u^{2}-1}\,du=-\text{arctanh }u+C \end{eqnarray*},$$ $$\tag{1}$$

where I have used the substitution $u=x-1$ and the standard derivative $$\frac{d}{du}\text {arctanh}=\frac{1}{1-u^{2}}\tag{2}$$

You just need to substitute $u=x-1$ to write $\text{arctanh }u$ in terms of $x$.

Added 2: Remark. If we use the logarithmic representation of the inverse hyperbolic function $\text{arctanh }u$ $$\begin{equation*} \text{arctanh }u=\frac{1}{2}\ln \left( u+1\right) -\frac{1}{2}\ln \left( 1-u\right),\qquad (\text{real for }|u|<1)\tag{3} \end{equation*}$$ we get for $u=x−1 $ $$\begin{eqnarray*} I &=&-\text{arctanh }u+C=-\text{arctanh }\left( x-1\right) +C \\ &=&-\frac{1}{2}\ln x+\frac{1}{2}\ln \left( 2-x\right) +C \\ &=&\frac{1}{2}\left( \ln \frac{2-x}{x}\right) +C\qquad (0

Added. If your book does require using partial fractions then you can proceed as follows $$\begin{equation*} \int \frac{1}{u^{2}-1}\,du=\int \frac{1}{\left( u-1\right) \left( u+1\right) }\,du=\int \frac{1}{2\left( u-1\right) }-\frac{1}{2\left( u+1\right) }du. \end{equation*}$$ $$\tag{5}$$

5

$$\begin{align} & {} \quad \int \frac{dx}{x^2 - 2x}\\ &=\int \frac{dx}{(x - 1)^2 -1}dx\\ &=\int \frac{dx}{(x - 1-1) (x-1+1)} \\ &=\int \frac{dx}{x(x-2)}\end{align}$$

The rest is easy (partial fractions):

$$\frac 12 \left[\int \frac {dx}{x-2} - \int \frac {dx}x\right]=\frac 12 \ln|x-2| -\frac 12 \ln |x| +C$$

  • 4
    Why didn't you just take $x$ as a common multiplier? Why did you need all those middle steps?2012-06-10
  • 0
    @ThomasE.: "All those middle steps"? I see only one additional step there.2012-06-10
  • 0
    You start from $\frac{1}{x^{2}-2x}$ and end up with $\frac{1}{x(x-2)}$ with 2 unnecessary middle-steps. You could just take $x$ as common multiplier in the first place.2012-06-10
  • 0
    @ThomasE.: Umm, you're quite right but the point is if one doesn't see the common factor $x$ at first (like the OP), it appears after those two middle steps as $x(x-2)$. I don't see what you're complaining about.2012-06-10
  • 2
    My intention is not to complain, if it seemed like that then I am glad I can correct the misunderstanding. I'm just having hard time seeing why this answer is useful. Do you really think that $x^{2}-2x=x(x-2)$ is what the OP is having hard time to figure out?2012-06-10
  • 0
    @ThomasE.: I don't know what else should I add to my previous explanations. I "completed" the square, and it's factored out and ready to use partial fraction.2012-06-10
  • 3
    I think this helpfully shows how the partial fraction method relates to completing the square. It is useful to know different methods and the kinds of functions they produce. Similarly, it is sometimes useful to know that an expression in terms of logs may be the same as an arctanh, because the standard answer in the mark scheme or at the back of the book or given in in an exam question may be in a different form - and there have been a number of recent questions where two apparently different expressions have proved to be equal apart from a constant of integration.2012-06-10
  • 0
    @MarkBennet: The latter part to the answer was included after all the previous comments took place. And the first part, it is purely unnecessary steps to obtain $\frac{1}{x(x-2)}$ from $\frac{1}{x^{2}-2x}$.2012-06-10
  • 0
    @ThomasE.: I added that part after Mark's comment, for your information. Other answerers are editing their answers, I'm allowed to do it as well. You're not making any points.2012-06-10
  • 0
    @Gigili: in the last formula, you can use **\left[** and **\right]** in the LaTeX code so that the size of the brackets is adjusted according to the expression inside it: $\frac 12 \left[\int \frac {dx}{x-2} - \int \frac {dx}x\right]=\frac 12 \ln(x-2) -\frac 12 \ln x +C$.2012-06-10
  • 0
    Thank you for the tip @anonymous.2012-06-11
  • 0
    @Gigili: Don't forget the absolute values in the antiderivatives. $\int\frac{dx}{x} = \ln|x|+C$, etc.2012-06-12
  • 0
    Done, thank you @ArturoMagidin.2012-06-12