In this example, we integrate \(\frac{N(x)}{D(x)}=\frac{x-3}{x^2-3x+2}\text{.}\)
Solution:
- Step 1. We first check to see if a polynomial \(P(x)\) is needed. To do so, we check to see if the degree of the numerator, \(N(x)\text{,}\) is strictly smaller than the degree of the denominator \(D(x)\text{.}\) In this example, the numerator, \(x-3\text{,}\) has degree one and that is indeed strictly smaller than the degree of the denominator, \(x^2-3x+2\text{,}\) which is two. In this casewe do not need to extract a polynomial \(P(x)\) and we move on to step 2.
3
We will soon get to an example (Example 1.10.2 in fact) in which the numerator degree is at least as large as the denominator degree — in that situation we have to extract a polynomial \(P(x)\) before we can move on to step 2. - Step 2. The second step is to factor the denominator\begin{align*} x^2-3x+2&=(x-1)(x-2) \end{align*}In this example it is quite easy, but in future examples (and quite possibly in your homework, quizzes and exam) you will have to work harder to factor the denominator. In Appendix A.16 we have written up some simple tricks for factoring polynomials. We will illustrate them in Example 1.10.3 below.
-
Step 3. The third step is to write \(\frac{x-3}{x^2-3x+2}\) in the form\begin{gather*} \frac{x-3}{x^2-3x+2} =\frac{A}{x-1}+\frac{B}{x-2} \end{gather*}for some constants \(A\) and \(B\text{.}\) More generally, if the denominator consists of \(n\) different linear factors, then we decompose the ratio as\begin{align*} \text{rational function} &= \frac{A_1}{\text{linear factor 1}} + \frac{A_2}{\text{linear factor 2}} + \cdots + \frac{A_n}{\text{linear factor n}} \end{align*}To proceed we need to determine the values of the constants \(A,\ B\) and there are several different methods to do so. Here are two methods
-
Step 3 — Algebra Method. This approach has the benefit of being conceptually clearer and easier, but the downside is that it is more tedious.To determine the values of the constants \(A,\ B\text{,}\) we putthe right-hand side back over the common denominator \((x-1)(x-2)\text{.}\)
4
That is, we take the decomposed form and sum it back together.\begin{gather*} \frac{x-3}{x^2-3x+2} =\frac{A}{x-1}+\frac{B}{x-2} =\frac{A(x-2)+B(x-1)}{(x-1)(x-2)} \end{gather*}The fraction on the far left is the same as the fraction on the far right if and only if their numerators are the same.\begin{align*} x-3&=A(x-2)+B(x-1)\\ \end{align*}Write the right hand side as a polynomial in standard form (i.e. collect up all \(x\) terms and all constant terms)
\begin{align*} x-3&=(A+B)x +(-2A-B) \end{align*}For these two polynomials to be the same, the coefficient of \(x\) on the left hand side and the coefficient of \(x\) on the right hand side must be the same. Similarly the coefficients of \(x^0\) (i.e. the constant terms) must match. This gives us a system of two equations.\begin{align*} A+B&=1 & -2A-B&=-3 \end{align*}in the two unknowns \(A,B\text{.}\) We can solve this system by- using the first equation, namely \(A+B=1\text{,}\) to determine \(A\) in terms of \(B\text{:}\)\begin{gather*} A=1-B \end{gather*}
- Substituting this into the remaining equation eliminates the \(A\) from second equation, leaving one equation in the one unknown \(B\text{,}\) which can then be solved for \(B\text{:}\)\begin{align*} -2A-B&=-3 & \text{substitute $A=1-B$}\\ -2(1-B)-B&=-3 & \text{clean up}\\ -2+B &=-3 & \text{so $B=-1$} \end{align*}
- Once we know \(B\text{,}\) we can substitute it back into \(A=1-B\) to get \(A\text{.}\)\begin{gather*} A=1-B=1-(-1)=2 \end{gather*}
Hence\begin{gather*} \frac{x-3}{x^2-3x+2} =\frac{2}{x-1}-\frac{1}{x-2} \end{gather*} -
Step 3 — Sneaky Method. This takes a little more work to understand, but it is more efficient than the algebra method.We wish to find \(A\) and \(B\) for which\begin{gather*} \frac{x-3}{(x-1)(x-2)} =\frac{A}{x-1}+\frac{B}{x-2} \end{gather*}Note that the denominator on the left hand side has been written in factored form.
- To determine \(A\text{,}\) we multiply both sides of the equation by \(A\)’s denominator, which is \(x-1\text{,}\)\begin{gather*} \frac{x-3}{x-2} =A+\frac{(x-1)B}{x-2} \end{gather*}and then we completely eliminate \(B\) from the equation by evaluating at \(x=1\text{.}\) This value of \(x\) is chosen to make \(x-1=0\text{.}\)\begin{gather*} \frac{x-3}{x-2}\bigg|_{x=1} =A+\frac{(x-1)B}{x-2}\bigg|_{x=1} \implies A = \frac{1-3}{1-2} = 2 \end{gather*}
- To determine \(B\text{,}\) we multiply both sides of the equation by \(B\)’s denominator, which is \(x-2\text{,}\)\begin{gather*} \frac{x-3}{x-1} =\frac{(x-2)A}{x-1} + B \end{gather*}and then we completely eliminate \(A\) from the equation by evaluating at \(x=2\text{.}\) This value of \(x\) is chosen to make \(x-2=0\text{.}\)\begin{gather*} \frac{x-3}{x-1}\bigg|_{x=2} =\frac{(x-2)A}{x-1}\bigg|_{x=2} +B \implies B = \frac{2-3}{2-1} = -1 \end{gather*}
Hence we have (the thankfully consistent answer)\begin{gather*} \frac{x-3}{x^2-3x+2} =\frac{2}{x-1}-\frac{1}{x-2} \end{gather*}Notice that no matter which method we use to find the constants we can easily check our answer by summing the terms back together:\begin{align*} \frac{2}{x-1}-\frac{1}{x-2} &= \frac{2(x-2)-(x-1)}{(x-2)(x-1)}\\ & = \frac{2x-4-x+1}{x^2-3x+2} = \frac{x-3}{x^2-3x+2} \checkmark \end{align*} - Step 4. The final step is to integrate.\begin{align*} \int\frac{x-3}{x^2-3x+2}\dee{x} & =\int \frac{2}{x-1}\dee{x} +\int \frac{-1}{x-2}\dee{x}\\ & =2\log|x-1|-\log|x-2|+C \end{align*}