 In the previous lecture, we looked at solving quadratic equations. Those are second-order polynomials. But what about cubic equations? Those are third-order polynomials. Let's take a look at how to solve those. Let's start thinking about cubic equations. Let's do our definition right there of a cubic equation. We're going to say that that is equal to AX cubed plus BX squared plus CX plus D equals zero. We know that A cannot be equal to zero because of that zero, that first term disappears and that's just a quadratic equation. So here we have a cubic equation. The highest power of our variable is three. Now we've already looked at some of these. Let's look at A cubed. But let's make that X cubed plus A cubed. Now we can indeed factor that. You might remember that's going to be X plus A multiplied by X squared. That's minus AX and then plus A squared. And we cannot just factor that very easily. We also had X cubed minus A cubed. And remember in both these instances, A is just going to be some constant. And then we had X minus A and then X squared plus AX plus A squared. And again, it's not easy just to factor that. Let's look at an example of one of these. Let's do X cubed. Let's do plus 27. And this is an equation. So we're going to set that equal to zero. Can we find solutions for X that satisfy this equation? Now we can rewrite this. Of course it's X cubed plus three cubed equals zero. And now it's just that what we have right up here, A is now this constant three. And so we can just plug in three everywhere where we see A. So we're going to have X plus three and we're going to have X squared minus three X and then plus nine because three squared is just equal to nine. Now this equals zero. Now we just have to think about what to do here. Now we've got two terms here, one and a second one. And we multiply those and that equals zero. That means we must have that either X plus three equals zero or we must have the fact that this polynomial X squared minus three X plus nine is equal to zero. So we will have that X is equal to negative three. I'm just subtracting three from both sides. Or I must have this equal to zero. And what we're going to do now, let's do some work on the side. This is AX squared plus BX plus C. So don't think about these A's and B's now. Let's just concentrate on this quadratic. My leading coefficient for X squared is going to be one. My B is going to equal negative three and my C is going to equal nine. I'm just doing AX squared plus BX plus C. Let's put it out there AX squared plus BX plus C equals zero. So don't think about and worry about what we had up there. It's a brand new problem that I'm dealing with as far as this quadratic's concerned. And I do remember that we have that X equals minus B plus or minus the square root of B squared minus four AC. Let's draw neat lines. That's going to be divided by two A. So let's substitute for A, B, and C. So we're going to say X equals negative B. Now B is already negative three. So negative negative three, that's just going to be positive three. Then plus or minus the square root of B squared is going to be negative three squared. So that's nine minus four times one times nine. So four times one times nine. And that of course is 36. And we're going to divide that by two times A and A is just one, so that divides by two. This leaves us with X equals three plus or minus the square root of, and now we have the square root of negative 27. And so we will absolutely have to involve complex numbers. Now let's look at what 27 is. Remember 27, that's just going to be three times three times three times negative one. Now this negative one, if we take the square root of negative one, that's just going to be I. And if we consider two of these, we can bring one out and then be left with a single square root of three. This would come from the fact that if we have the square root of three squared, well that's just going to equal three because if I take this very nice square root, I get three squared. So we know that we can say X equals three plus or minus. That's going to be three square root of three times I divided by two. And so now we have three solutions and we really want three solutions because this, the problem that we started with is a cubic equation. So we're going to have X equals negative three or we're going to have X equals, let's do three over two. Let's do the plus first plus three square root of three divided by two I or X is going to equal three over two minus three square root of three divided by two I. And we see our three solutions. Now in some cases, we're going to be very fortunate. Let's write out again AX cubed plus BX squared plus CX plus D equals zero. In some cases, we're going to be very lucky in as much as D equals zero. So let's look at an example there. Let's do a very simple one. Let's have X cubed, let's do minus eight X. Now in this instance, we also see that B is equal to zero. There's no X squared term, but definitely D is zero. We don't see any constant there. Now this is very easy to do because I can take out a single X as a common factor because do remember this is X times X times X minus eight X. In this term, I have a single X, I have a single X on this side. I can take that out as a common factor. So there's my X. What am I left with? Well, I'm left with X times X, which is this X squared and then I'm left with negative eight. Negative eight equals zero. So now either one of these two has to equal zero. It's either gonna be X equals zero or we have X squared minus eight is equal to zero. I can add eight to both sides and I get X squared equals eight and then X equals plus or minus the square root of eight. I'm just taking the square root of both sides. Now what can I do with eight? I can say eight equals two times two times two. Well, there's two twos there. I can bring that outside of the square root symbol. So that's gonna X equals plus or minus two and I'm left with a single square root of two. So my final solution, I get X equals zero or X equals two square root of two or negative the square root of two, as we can see there, underline that. So let's do another example. Let's have X cubed minus four X squared minus five X equals zero. Again, you can see the D term is not there. The constant term is not there, is equal to zero. Once again, I can take out a common factor, a single X, which means I'm left with X squared minus four X minus five is equal to zero. So either X is equal to zero or our polynomial here X squared minus four X minus five is equal to zero. Fortunately, we can look at this polynomial on the site, this quadratic I can do X and X. And if I look at five, well, I can think of this as negative five plus one because negative five times one, that's gonna give me the negative five. But I have negative five X plus one X leaves me with negative four X equals zero. And this one is very easy. I'm gonna have X equals zero or X equals five, looking at that term. And for this term, or X equals negative one. That was a simple one to do. Sometimes we're very fortunate that we can do grouping. Let's have a look at this example. Let's have X cubed plus X squared minus four X minus four equals zero. Now let's just do some association. Let's put X cubed plus X squared minus, let's do four X, let's do plus four. Why the positive there? Well, I've taken out negative one. If I distribute this negative, I'm gonna get negative four X, negative four. And I'm left with the original problem. Let's look at this first term. Let's take out X squared as a common factor. So I'm left with X plus one, X cubed, X squared. That looks fine. Let's take out four as a common factor here. And I'm left with X plus one. You can verify that, just do the distribution. You're gonna land up with the exact same problem. Now look at this. I have some term in common for both of these. So let's take out X plus one as a common factor. Yes, you can do that. And I'm left with X squared minus four equals zero. Again, with two terms equaling zero, that means either X plus one is equal to zero or X squared minus four is equal to zero. I can subtract one from both sides. I'm left with X equals negative one. And on this side, X squared equals, add four to both sides. X squared equals four. I can take the square root of both sides. That leaves me X equals plus or minus. The square root of four. And that means X equals plus or minus two. And so it's a cubic and I have my three solutions. X equals negative one or X equals two or X equals negative two. And one by one, you can substitute negative one. On the left hand side, you should get zero. Two, you can substitute. You should get zero. Negative two, you can substitute into X and you should get zero. So you can always verify your work. Now let's take the exact same problem. I'm gonna have X cubed plus X squared minus four X minus four equals zero. And I'm going to do a different technique. I'm going to look at my constant term D. My D is equal to negative four and I'm gonna look at my constant term A. In this instance, it's one. Now I'm going to look at all the factors of these two numbers. By factors, I mean what integers will divide these numbers leaving me with no remainder. So let's start with D. Well, certainly positive and negative one will divide negative four without remainder. So we'll positive and negative two and so we'll positive negative four. My A term is very easy. This is gonna be positive negative one. You can divide either positive or negative one by one and you're not going to have a remainder. Now the next step in this division technique is to take each one of these terms and divide it by each one of the terms for A. Now this one's gonna be very easy because we only have positive negative one. So that will leave us with positive negative one, positive negative two, positive negative four, which means I can write six terms. I can have X plus one, X minus one, X plus two, X minus two, and X plus four, and X minus four. So it's just gonna take each of these values and we're gonna pop them in there. There's my positive one, negative one, positive two, negative two, positive four, negative four. Now I want to know, do any of these terms divide my original problem? So let's start with this first one. I'm thinking X cubed plus X squared minus four X minus four. Let's start with this very first one, X plus one. So I'm gonna say divide that by X plus one. I want to know, does this divide the numerator without any remainder? Well, I'll have to do some long division. X cubed plus X squared minus four X minus four. I'm gonna divide that by X plus one. So just some long division from school. Now we do that by looking only at the first term. How do I get from X to X cubed? Well, I multiply that by X squared. So X squared times X plus one. What would that be? X squared times X, well that's X cubed. X squared times one, that's positive. X squared, and now I'm going to do subtraction. X cubed minus X cubed, that's nothing. X squared minus X squared, well that's the zero X squared left there, now I bring the negative four X down. And I'm thinking, how do I get from X to X squared? Well, I multiply that by zero X. Zero X times X, that's zero X squared. Now zero X times one, well that's just positive zero X. And I do my subtraction once again. Zero X squared minus zero X squared, that's nothing. Negative four X minus zero X, that leaves me with negative four X. I bring down my negative four. How do I get from X to negative four X? Well, that's just minus four. Negative four times X, that's negative four X. Negative four times one, that's negative four. And look at that, if I do the subtraction, there's nothing left, there's no remainder. So indeed, X plus one does divide X cubed plus X squared minus four X minus four. And I can write X plus one times X squared. I can drop that zero X minus four equals zero. If I multiply these two terms, I get back to there because I did the division and there was no remainder. And now look at this, it is what we had before. X equals negative one or this term, X squared minus four equals zero or X squared equals four or X equals plus or minus the square root of four or X equals two or X equals negative two. And you can see as before, I have the very same results. Let's do one more example. Let's do two X cubed, let's do plus three X squared minus 11 X minus six equals zero. Now my D term there is gonna be negative six, it's right there, my A term is going to be positive two. Let's think about all the integers that I can divide into negative six that leaves me no remainder. So let's look at the negative six. Obviously that's gonna be a plus or minus one because negative six divided by one, that leaves me with no remainder. Negative six divided by negative one leaves me with no remainder. It's very easy to do. Two will also divide, negative six plus or minus two, plus or minus three will divide negative six and plus or minus six will do the same. Let's look at the term, that's my A term there. Remember A X cubed and there's my D term there. This is gonna be plus or minus one and plus or minus two. Now let's do all our divisions, plus or minus one divided by plus or minus one, that leaves me with plus or minus one. If I take plus or minus one and divided by plus or minus two, that's gonna leave me plus or minus A half. So I can move on to the next one, plus or minus two divided by plus or minus one, that leaves me with plus or minus two, plus or minus two divided by plus or minus two. remember there's four divisions going on here plus two divided by plus two plus two divided by negative two negative two divided by plus two and negative two divided by negative two all of them is going to leave me with plus or minus one so that's fine I can now move on to the three three and the one that's going to leave me plus or minus three three divided by the two that's going to leave me with plus or minus three over two and then six divided by the one that's going to leave me plus or minus six and six divided by the two, well that just leaves me with a plus or minus three. So I've actually got many, many terms here. There's going to be an x plus one or an x minus one. There's going to be x plus a half and x minus a half. There's going to be x plus two, x minus two. There's going to be an x plus three and x minus three. There's going to be x plus three over two, x minus three over two. There's going to be an x plus six. There's going to be an x minus six. One, two, three, four, five, six, seven, eight, nine, ten, eleven, twelve. You'll have to check twelve of these. It'll take a long, long time. Now do go one by one. I'm going to skip a few. I'm going to go straight for trying x minus two. But please, you can't just skip around. You'll have to do one by one. So let's do x minus two. We'll have two x cubed plus three x squared minus eleven x minus six. Let's see if x minus two indeed divides that expression. Let's put our long division. We've got our lines there. And so how do I get from x to two x cubed? Well, that'll be a two x squared because two x squared times x, that's two x cubed. Two x squared times two, that leaves me with negative four x squared. I do subtraction, two minus two, that's zero. Three minus negative four, so that's three plus four, that leaves me with seven x squared. I'm going to bring down the negative eleven x. How do I get from x to seven x squared? Well, I've got to multiply by seven x. Now that's it for this video. There's an equation that will solve for cubic equations. There's actually also one that will solve all of these that are polynomials raised to the power of four, fourth-order polynomials. Once we get to fifth-order polynomials, or higher though, there are no longer any such easy equations to solve them.