 We were looking at the solution to the Duffing equation using the method of multiple scales. We had written down the equation at order epsilon, note that there was a small error in writing down the first term, I have indicated that in a red box here. We had also got terms from this second term which was to the power 3 and I had shown you that how I get this term and that term and then there are complex conjugates of those which we do not write down. So, we have this line which is the first term and then the next two terms come from the cubic term and then plus cc which indicates that complex conjugate of all the three terms. It is useful to put in one bracket all terms which have e to the power i omega 0 t0. So, that I have done here and then e to the power i 3 i omega 0 2 0 is there and then there is a complex conjugate part. Now, the reason why we are looking at terms of the which are proportional to e to the power i omega 0 t0 is because like earlier they are resonant forcing terms, they basically these are terms which will oscillate at the same frequency as the natural frequency of the oscillator. If this is a solution to the homogeneous equation d0 square plus omega 0 square into u1 is equal to 0. So, we have to set this term equal to 0 to eliminate resonant forcing and this will give us an equation for capital A as a function of t1. Let us solve that equation. So, the equation is twice i omega 0 to 0. For convenience we choose a, a is a complex function. So, a is equal to half small a which is a function of t1 and t2 into e to the power some phi some phase which is also a function of t1 and t2. So, now if I go back and replace it in this equation, then we obtain twice i omega 0. This half is just for convenience because there is a factor of 2 in the equation. So, if you put a half things will get cancelled out. So, I have half del A by del t1 e to the power i phi and then we will have twice i omega 0 and then I have to take the derivative of e to the power i phi which is just i. So, that will give me i square and then I have a factor of half A e to the power i phi into del phi by del t1. This is the derivative of the first term in the equation which governs A. I have one more term which is 3 and A square makes it 1 by 4 small a square e to the power twice i phi into A bar. A bar is just the complex conjugate of capital A. So, half small a into e to the power minus i phi is equal to 0. So, we get this equation which is i omega 0 del A by del t1 e to the power i phi minus, minus because there is an i square and then this is omega 0 A e to the power i phi del phi by del t1 plus 3 by 8 e to the power i phi and you can see that there is an A cube here and e to the power i phi is equal to 0. So, we can simplify this by getting rid of e to the power i phi because e to the power i phi is in general not 0. So, this simplifies to recall that small a and small phi are actually real functions because we are writing them in complex notation. So, it is A times e to the power i phi. So, A is a real function and phi is also a real function. So, this equation has an imaginary term here you can see that the first term in the equation is has a i. So, this equation can in general be split into a real part and an imaginary part and both of them have to be separately equated to 0. So, we will have, so if I the real part is just the second and the third terms. So, that gives me omega 0 del phi by del t1 is equal to 3 by 8 A square of cancel out 1A. This is the real part. The imaginary part is just the first term and we have to say because omega 0 is not 0. So, del A by del t1 is equal to 0. This is the imaginary part and this implies that A is not a function of t1. So, A at most is a function of t2. We will later take A to be a constant because we are not really going to solve the problem up to order epsilon square. So, if there is any variation of A you will find it only at order only at long enough times of the order epsilon square into t. So, of your time small t is of the order 1 by epsilon square. So, we are later going to take A as a constant, but let us work on the real part. So, the real part gives us del phi by del t1 is equal to 3 by 8 omega 0 into A square. And we have just seen that A is not a function of t1. So, A while doing this integration you can treat A as a constant because A is at most a function of t1. So, this integration we are doing with respect to t1. So, phi just becomes 3 by 8 omega 0 A square t1 plus some constant phi naught which could potentially be a function of t2. But once again we will treat phi naught as a constant because as I have said before we are not going to solve the problem up to t2 or up to order epsilon square. But we will need to go write down equations up to order epsilon square in order to determine the solution up to order epsilon completely. So, we thus obtain A, we had to recall that we had written capital A as small A which was a function of which we thought was a function of t1 t2 into e to the power i phi which was also a function of t1 t2. Now we have determined that small A is not a function of t1. So, I will just write it as a function of t2 and later take it to be a constant at order epsilon. So, this into and I am going to write down whatever we found for phi here. So, this would be 3 A square by 8 omega naught t1 plus some function phi naught of this. So, we now know how A depends on t1. So, now the solution at this order is a function so we are looking at the problem at order epsilon and so the solution at this order looks like d0 square plus omega 0 square into u1. Recall that we had two terms we had a part which depended on e to the power i omega naught t naught and another part which depended on e to the power 3 i omega naught t naught. You can see that the first part has been set equal to 0 so that is not there anymore. So, the equation at this order is just equal to the second term plus its complex conjugate. If we write that then it is just minus A cube e to the power 3 i omega naught t naught plus complex conjugate. The term which is proportional to e to the power i omega naught t naught it has been eliminated by setting a coefficient equal to 0 and that has told us what is the expression for capital A. So, now we have to determine so you can see that this has the structure this although this is a partial differential equation d0 is actually del by del square by del t0 square but we can solve it like an ordinary differential equation and we have to determine the particular integral. The particular integral in this case has to be proportional to e to the power 3 i omega naught t naught. So, we set it equal to alpha times e to the power 3 i omega naught t naught and if we substitute it into this equation then we are supposed to determine the value of alpha. So, if you substitute it here you will find so substitute and you will find that alpha is equal to A cube by 8 omega naught square just one can substitute and find this. Therefore, the general solution at order epsilon is u1 t0 t1 t2 is some the complementary function some constant which potential depends on t1 t2 into e to the power i omega naught t naught plus the particular integral which is A cube alpha times e to the power 3 i omega naught t naught alpha we have determined to be A cube by 8 omega naught square. So, this is just alpha times e naught plus complex conjugate. This is the structure of the general solution at this order. Now, we cannot stop at this order the reason being that we do not know B as a function of t1. If we knew B as a function of t1 the problem would be over at order epsilon we would not have to proceed to the next order. Recall that I have told you that we are not going to solve the problem correctly all the way up to order epsilon square. So, we do not need to worry about the t2 dependence of B, but we do need to worry about the t1 dependence of B. So, for that let us proceed to the next order to see if we can find an equation which tells us what is B as a function of t1. So, let us do that. So, this is the equation at order epsilon square I have already written this equation here, here there are 4 terms on the right. So, I will label them 1, 2, 3, 4. Some amount of algebra needs to be done in evaluating these terms. The algebra tends to be slightly lengthy. I am going to work out some of these terms and I am going to leave the rest of the terms to you as an exercise. The exercise is quite straightforward and I will tell you how to do it. I leave it to you to show that the expressions are indeed what I will write down here. So, just let me rewrite the equation once again. So, at order epsilon square d0 square plus omega 0 square u2 is equal to 1 plus 2 plus 3 plus 4, 4 terms. What is 1? 1 is minus 2 d0 d1 u. I will work out this term. So, minus 2 d0 d1 on u1. And we have just found that u1 I have written it in the last slide is just b plus the particular integral that we just found plus complex conjugate. So, I have to differentiate this expression. So, this is minus 2 d1. The differentiation with respect to d0, b does not participate in it because b is just a function of t1 and t2. So, this will just become i omega 0 b. And from the second term similarly, a is again a function of t1 and t2 that will also not participate. So, I will just get thrice i omega 0 aq. Now I am going to differentiate with respect to t1 or I am going to operate the d1 on b. So, you can see that this is going to become twice i omega 0 d1 operating on b, which is basically del b by del t1 into e to the power i omega naught t naught minus 6 i. If I cancel out an omega naught, then I get a omega naught only in the denominator. And then I have d1 of a cube that can be simplified. D1 is just del by del. So, d1 of a cube, this is what I have to do. This is just del by del t1 of a cube, which is 3 a square d1 of a. So, this becomes 3 a square d1 of a into e to the power thrice i omega 0 t0. Now, this is the place where I am going to introduce some simplification which will help the algebra. We have an expression for d1 of a from before. Recall that in the previous order, we had an equation which looked like this. This was obtained by setting a resonant forcing term on the right hand side at that order to 0. Note that this is just d1 of a, del a by del t1 by definition is d1 of a. So, I am just going to take this expression next, replace d1 of a from this and substitute it in the equation that I have. This will just make it easier for me to do the algebra. So, from that equation that I just showed you, we obtain, this is obtained from the equation twice i omega 0 del a by del t1 plus 3 a square a bar is equal to 0. This was the equation which allowed us to determine a, capital A. So, this is just d1 of a. So, I am just going to replace the expression for d1 of a from this into there. If I do that and simplify a little bit, then you can easily show that you get this expression twice i omega 0 d1 of b e to the power i omega 0 t0. That term remains untouched and then if you replace d1 of a with that term, you get 27 by 8 omega 0 square, you get a 4 and then you get a a bar e to the power 3 i omega 0 t0. So, this is my expression for term 1. So, I will put term 1 here, bracket around it. Now, let us go to term 2. Term 2 is a simple term. I will leave that to work it out yourself and I will give you the final expression. It is just two lines of algebra. And if you do that algebra, you will find just use the expression that we have for u0. u0 we already have in my previous slides. So, u0 is there at the top of the slide at order 1. You have to just substitute u0. So, this is just twice i omega 0. That is because of the derivative with respect to d0 into d2 into a. We can replace this d2 into a later e to the power i omega 0 t0 plus complex conjugate. This is easy to do. So, this is my second term on the right hand side. Let us work on the third term. The third term is minus d1 square u0. This term is again easy to do. Again, like the first term, you will have to replace the expression for d1 of a later on. And somewhere you will have to use the fact that d1 of a bar is equal to d1 of a bar. So, if you have to use this, then you should be able to get this term. So, this term actually turns out to be equal to after some few lines of algebra. It just turns out to be equal to 9 by 4 a cube a bar square by omega 0 square e to the power i omega 0 t0 plus complex conjugate. There is some algebra here which I encourage you to try yourself. It is not difficult. One just has to be careful and do those lines of algebra to get this. This is my expression for the third term. Then fourth term. And this term, I will show it how to how do we do this because there is a product involved and one has to be a bit careful. Otherwise, there is a possibility of doing mistakes. So, the fourth term is u0 square u1. Now, let us work this term out. So, here there is a product of u0 square into u1 and so one has to be careful while doing this. So, then we will have u0 by definition is a e to the power i omega 0 t0. And now instead of writing a cc, I am going to actually write down the complex conjugate term. So, the complex conjugate is just a bar into this and there is a square here. Multiply it by u1. u1 had a complementary function part which was b e to the power i omega 0 t0 plus a particular integral which was a cube by 8 omega 0 square e to the power 3i omega 0 t0. And here also like the previous term, I am going to write down its complex conjugate because that will help us do the multiplication and keep only the ones that we want to keep and the rest will go under complex conjugation. So, I will put b bar. So, that is the complex conjugate of this term e to the power minus i omega 0 t0 plus a bar cube e to the power minus 3i omega 0 t0. And now let us see what do we obtain from here. So, for this let us square the first term. The first term is just a square e to the power twice i omega 0 t0 plus a bar square e to the power minus twice i omega 0 t0 plus twice the first term into the second term. The exponentials will cancel and then we will just have a bar. Multiply it by the second term exactly remains the same as what I have written earlier. Now, let us see how do we multiply these things term by term. So, we can immediately see that if I multiply, so I am just going to indicate which terms I am multiplying by which. So, I will compare the multiplication of this term with the multiplication of that term because what I have put here is just the term on the top. So, let us multiply the first term of this with the first term of that. That will give me minus 3 a square b e to the power 3i omega 0 t0. Then I will multiply the first term of this with the third term of that. That will give me minus 3 a square b bar into e to the power i omega 0 t0. Notice the pattern that I am following. I only want e to the power a positive exponent. We do not want any multiplications where it leads to e to the power a negative exponent. So, for example, if I multiply this term with this term, then you can immediately see that it will give me exponential minus i omega 0 t0. We do not want that term because we will get the complex conjugate of that term and that will be plus i omega 0 t0. So, I am going to follow this procedure where I multiply every term and make sure that I write only those terms whose exponent for the exponential is positive. I do not write any term where the exponent is negative. I will put them all under cc. So, I leave it to you to understand this. I am writing down the final expression. You can multiply each term in these two brackets. You will get a whole lot of terms and you will see that I have not missed out anything which has a positive exponent. I am only not writing those terms where the exponent is negative and I will put them under cc. So, you will see that there is a, it always occurs in pairs. I only write one of the pair and I put the other one in cc. So, with that structure the final answer here looks like, so again we are looking at the fourth term minus 3 u0 square u1 and this gives us quite a few terms which are minus 3 a square b e to the power thrice i omega naught t naught minus thrice a square b bar i omega naught t naught. So, of course, I have not combined all the terms. You can see that there are some terms which can be combined here, but I am just writing what we obtain after multiplication. We will continue this.