0
$\begingroup$

$$\frac{-x+2}{x^{2}+x-2}=\frac{-4}{3(x+2)}+\frac{1}{3(x-1)}$$

Wolphram Alpha states that one can do this with long division, I cannot immediately realize it. Could someone show the trick to simplify the LHD to RHD?

Context: Trying to compute $$\int \frac{x^2}{x^2+x-2}\,dx$$

  • 1
    This is called "partial fraction decomposition", not "mock-long-division". You can verify it by performing the operation on the right hand side; the "trick" to do the decomposition is to factor $x^2+x-2=(x-1)(x+2)$ and solve the equation $$\frac{-x+2}{x^2+x-2} = \frac{A}{x+1}+\frac{B}{x-2}.$$Look around here for "partial fraction decomposition". And what is "WA"?2012-02-03
  • 0
    @ArturoMagidin I was about to ask what is "WA" too. I believe it is Wolfram Alpha.2012-02-03
  • 0
    @ArturoMagidin: WA (=wolframalpha) stated me that one needs to use long-division to deduce this, I was flaggergasted, hence "mock-long-division".2012-02-03
  • 0
    *Where* did Wolfram alpha state this? When doing integrals of rational functions, the first step is *often* to do long division, and then a partial fraction decomposition using the remainder. What's the context?2012-02-03
  • 0
    @ArturoMagidin: [here](http://www.wolframalpha.com/input/?i=Integrate%28x^2%2F%28x^2%2Bx-2%29%2Cx%29) when you press `"show steps"`. This problem is a slight variation but I think it is misleading instructed as "long-division".2012-02-03
  • 0
    @hhh: No, it's correct. The **first** step in solving $\int\frac{x^2}{x^2+x-2}\,dx$ is to perform the long division to get $\frac{x^2}{x^2+x-2} = 1 + \frac{-x+2}{x^2+x-2}$. The **second** step is to decompose the latter fraction using partial fractions. The "Long divison" refers to the first step in solving the integration, **not** to the step of performing the partial fraction decomposition.2012-02-03
  • 0
    @ArturoMagidin: I see now, overlooked the fine print -- did the long-division so spontaneously that did not think about it. Very well you right, good to get it clear then, thank you for clarification.2012-02-03

1 Answers 1

2

The trick is to realise that the denominator can be factored as

$x^2 + x - 2 = (x+2)(x-1)$.

Then you make an ansatz (educated guess) that the right hand side can be written as

$$\frac{A}{x+2} + \frac{B}{x-1}$$

and solve for $A$ and $B$. In fact if you do this, you get after making denominators common the equation

$2 - x = A(x-1) + B(x+2)$.

From which substituting in $x = 1$ gives $3B = 1$, or $B = 1/3$. Similarly substituting in $x = -2$ gives $4 = -3A$, so that $A = -4/3$.