 In this video, we're going to evaluate the integral of 3x over x plus 2 times x minus 1 with respect to x. And as this is a rational function, we're going to have to use the technique of partial fraction decomposition to help us find the antiderivative. Now this is a proper fraction. The top has degree 1 and the bottom has degree 2. Since it's proper, we don't have to do any polynomial division whatsoever. And also because the denominator is factored, we don't have to factor the denominator and we can find the template of the partial fraction decomposition quite quickly. The template is going to look something like the following, 3x over x plus 2 times x minus 1. It'll look like a over x plus 2 plus b over x minus 1. You have to have a partial fraction for each and every factor that shows up in the denominator. And as these are proper fractions, the numerator has to be smaller than the denominator. Linear factors mean the numerators have to be constants. Clearing the denominators, we're going to multiply both sides of the equation by x plus 2 times x minus 1. Do that on the right hand side as well. This is our LCD. On the left hand side, it will cancel out perfectly. On the right hand side, when you distribute this onto the b into the a, the x plus 2 will cancel with the first one leaving you an x minus 1. And the x minus 1 will cancel on the second one leaving you an x plus 2. So that'll look like 3x equals a times x minus 1 plus b times x plus 2. You'll notice that the coefficient a is going to be partnered up with a factor that wasn't below it. So x plus 2 is below the a. Now it's going to be attached to an x minus 1. Same thing with the b. The factor that was below it, which is x minus 1, gets canceled out and you'll be partnered with the factor that it was missing, the x plus 2. So here we see that we've cleared the denominators. And if you want to solve this using a system of equations, many people like that, you would end up with something like the following a plus b equals 3. And then we would also have that minus a plus 2b equals 0. You could solve that system equation. It's not too much difficult, not too much difficulty to do that. But I want to do a show a different technique is that after all this right here is an equation. a and b are numbers. We don't know if they are yet, but we're trying to figure out they are. x on the other hand is a variable. It's a function which case we could accept any number x for this equation here. So what if you choose some strategic numbers for x are some cool numbers for x, right? What if we pick the very cool number x equals 1? It's very suave. Why is x equal 1? It's such a good choice. Well, if you plug in x equals 1, the left hand side becomes 3 times 1, which is equal to 3. On the right hand side will look like a times 1 minus 1 plus b times 1 plus 2, which that simplifies to be 0a plus 3b, that is 3b. Remember what we have here? We have 3 equals 3b. If you divide both sides by 3, you're going to get that b equals 1. So that was really nice. We actually figured out what b was without having to solve a system of equations whatsoever. By plugging in x equals 1, we figured out what b was. Wow, that was a cool value. But what was so significant about x equals 1? Notice x equals 1 is what makes the factor x minus 1 go to 0. It's its root. Well, if we try that, if we want to continue that game, take x plus 2. What makes x plus 2 go to 0? Well, that would be x is equal to negative 2. And so if we do that, let's try this cool value, 3 times negative 2 is equal to negative 6. That's the left hand side. Don't forget it. On the right hand side, we get a times negative 2 minus 1. And then we're going to get b times negative 2 plus 2. You'll notice here that negative 2 plus 2 is 0 and therefore b is annihilated here. Previously, a was annihilated by choosing x is 1. So we annihilate b by choosing x to be negative 2. And so we get negative 6 is equal to negative 3a. Divide both sides by negative 3. We get a equals 2. And so using these cool values of x, that is, these ones that annihilate, we actually only figure out that b is 1 and a is 2 pretty quickly without any system of equations. That's kind of a nice alternative. Lots of students, I think, really prefer this method of annihilation as opposed to the systems of equations. So let's return to the original problem. We're trying to find an antiderivative. So 3x over x plus 2 and x minus 1. Now is our original fraction. By the technique of partial fraction decomposition, we've now discovered that this is the same thing as 2 over x plus 2 dx. And we add that to 1 over x minus 1 dx. And so now we were able to write the original fraction as partial fractions. And with these partial fractions, we can very quickly find our antiderivatives. We're going to get 2 times the natural log of the absolute value of x plus 2 plus the natural log of the absolute value of x minus 1 plus a constant. And this is our antiderivative. The calculus actually is not the hard part of this problem. The calculus is super easy. It's a U substitution that we're going to do a gazillion times that we'll be able to do it in our sleep eventually. The partial fractions are what it might be intimidating for these type of questions. Now, we saw in this example using annihilation, we can actually find the partial fractions pretty quickly just by choosing those cool values of x. That is the roots of the original denominator. So that can be very helpful when we have these linear factors. And so, yeah, use this technique of systems of equations or annihilation to help you find these partial fraction decompositions.