CHAPTER 08.01: PRIMER ON ORDINARY DIFFERENTIAL EQUATIONS: Exact Solution of 2nd Order ODE: Complex Roots of Characteristic Equation

 

In this segment, we're going to take, again, a second-order ordinary differential equation. We're going to take an example, and try to find out what the exact solution is.  So let's go ahead and look at a differential equation example.  We have y double-prime, plus 2 y prime, plus 5 y equal to 10 x. We are also given the initial conditions to be y of 0 equal to 5, and y prime of 0 equal to 2.  So let's go ahead and find out what the solution is.  So again, we're going to write down this particular differential equation which we have, we're going to write down in the operator form.  We get D squared, plus 2 D plus 5, operating on y is equal to 10 times x.  So the homogenous part of the solution will be based on what we get in the operator form.  So the characteristic equation for the homogenous part is going to match what we have here, so it will be of the form m squared, plus 2 m, plus 5 equal to 0.  Now, I will need to find out what the roots of this particular equation are, and the roots of this particular equation, I'm going to use my quadratic equation formula.  So it's minus b, which is -2, plus minus b squared, which is 4, minus 4 times a, which is 1, and c, which is 5, divided by 2 times a, which is 1. So this is my value of a, that's my value of b, and that's my value of c, if you are looking at the typical a x squared, plus b x, plus c formula.  So from here, I get -2 plus minus square root of -16, divided by 2. So what you are finding out here is that the number which is under the square root notation here is a negative number, so we're going to get imaginary numbers for square root of -16.  So what we're going to get is -2 plus -4 j, divided by 2, where j stands for square root of -1. So we simplify this, we get -1 plus minus 2 j.  So the roots of this particular quadratic equation are not real. They are not real and distinct, or real and repeated, they are, in fact, complex.  You're getting a real part, which is -1, and a complex part, which is plus or minus 2 there.  So the roots of this equation which you're going to find at -1 plus 2 j and -1 minus 2 j, and the roots which you are getting are complex conjugates of each other, as you would expect that whenever you find roots of equations, if complex roots show up, they will show up as complex conjugates.  Now, how do we write down the homogenous part of the solution for this one then?  The homogenous part of the solution is k e to the power minus whatever the . . . k e to the power whatever the real part is, which is minus here, minus x, -1, so you get e to the power minus x, then you will have, k1 of course, and then you'll have cos of 2 x, okay?  So it's cos of whatever the imaginary part of the solution is.  Then plus k2, again, e to the power whatever this quantity here is, which is e to the power minus x . . . and multiply it by x, and then this is -2 j, since we have already taken care of the cos 2 x part, we'll have the sine 2 x part in here. So that's how you will write down the homogenous part of the solution when you have complex roots in your . . . in your characteristic equation. The particular part of the solution, of course will be A times x, plus B, and the reason why it's A times x, plus B is because your right-hand side, your forcing function, your right-hand side is 10 x, so you will choose all the forms of the right-hand side as well as its derivatives, and in that case it turns out to be A x, plus B.  So the full solution will be k1 e to the power minus x, cos 2 x, plus k2 e to the power minus x, sine 2 x, plus A x, plus B.  Now, how are we going to find out what A x, plus B is?  It is the first thing which you're going to do is you're going to take and plug this back into your differential equation which you have the particular part, which will be A x, plus B here, plus 2 times d by dx, A x, plus B, plus 5 times A x, plus B equal to 10 times x.  And since we have done these example before.  What you're going to get from here is you're going to get A equal to 2, and B equal to -0.8.  That's what you're going to get once you equate the coefficients of x and the coefficients of the constant, you're going to get A equal to 2, and B equal to -0.8. Having said that, then your whole solution will look like y is equal to k1 e to the power minus x, cos 2 x, plus k2 e to the power minus x, sine 2 x, plus A x, plus B, which is 2 times x, plus B, which is -0.8. Now the burden of finding out the k1 and k2 values falls on applying the initial conditions.  We have y of 0 equal to . . . equal to 5.  So we get 5 is equal to k1 e to the power -0, cos 2 times 0, plus k2 e to the power -0, sine 2 times 0, minus 2 times 0, minus 0.8.  So you get 5 is equal to k1, plus 0, because sine of 0 is 0, that is 0, minus 0.8. So from here, you're going to get k1 is equal to 5.8. So that's what you're going to get for k1.  In order to find k2, I'm going to leave that as an exercise for you. We need to find . . . we need to apply this boundary condition . . . this initial condition, y prime of 0 is equal to 2.  So what that means is that you will have to, in order to be able to find out what the value of k2 is, you'll have to go ahead and take the derivative of this expression here. You'll have to take the derivative of this expression, put x equal to 0 in there, and then substitute the value of 2 on the right-hand side. So you'll have to take the derivative of this expression right here, substitute the value of x equal to 0, and equate it equal to 2, and you're going to get the value of k2 equal to 2.9, that's what you're going to get for the value of k2, by substituting the value of x equal to 0 in the expression for y, and then equating it to 2, because that's what the initial condition is.  So that's how you are able to find out what these two constants of the homogenous part of the solution is. So once we have found k1 and k2, we have the full solution.  So I'm going to write this down again here.  We'll have y is equal to k1 e to the power -2 x, cos 2 x . . . e to the power minus x, cos 2 x, plus k2 e to the power minus x, sine 2 x, plus 2 x, minus 0.8, that's how we started.  We just found out what the values of k1 and k2 are, k1 is 5.8, k2 is 2.9, and that gives us the complete solution to the differential equation. The main reason why we did this example is to show you an example of how, when you have a characteristic equation and you get complex roots, you do have to then use sinusoidal functions of this form to be able to account for that in the homogenous part of the solution.  And that's the end of this segment.