Solving a Nonhomogeneous 2nd Order ODE with Initial Conditions

  • Thread starter Thread starter nlsherrill
  • Start date Start date
  • Tags Tags
    2nd order
nlsherrill
Messages
320
Reaction score
1

Homework Statement



This was an example the teacher gave us to do in class. Unfortunately, I was a little behind on the notes so was not able to copy down the steps to solving this one. I did, however, get an answer

problem:

y'' + y = e^x + x^3, initial conditions y(0)=2, y'(0)=0


Homework Equations





The Attempt at a Solution



The answer my prof gave was y=(3/2)cos(x)+(11/2)sin(x)+(1/2)e^(x)+x^3-6x

I get how he got the complimentary part, but the particular solution I feel I am very close too, and may have just made some slightly wrong assumption as a 'trial' solution.

what I did for a trial to the particular solution was...

yp=Ae^x +Bx^3+Cx^2+Dx+E and set this equal too e^x + x^3.

I found the second derivative to be (Ae^x + 6Bx + 2c). So far I have:

(Ae^x + 6Bx + 2c) + (Ae^x +Bx^3+Cx^2+Dx+E) = e^x + x^3

I then gathered terms and solved for coefficients to get A=.5, B=1, C=0, D=-6, and E=0.

simplifying I ended up with e^x +x^3 = e^x +x^3... so I did something wrong somewhere I guess.

I understand everything except how my prof got (1/2)e^(x)+x^3-6x as the particular solution. I even got all the terms he listed as the particular solution, but some of them ended up canceling out so my particular I believe is wrong.
 
Physics news on Phys.org
nlsherrill said:

The Attempt at a Solution


I found the second derivative to be (Ae^x + 6Bx + 2c). So far I have:

(Ae^x + 6Bx + 2c) + (Ae^x +Bx^3+Cx^2+Dx+E) = e^x + x^3

I then gathered terms and solved for coefficients to get A=.5, B=1, C=0, D=-6, and E=0.

simplifying I ended up with e^x +x^3 = e^x +x^3... so I did something wrong somewhere I guess.

I understand everything except how my prof got (1/2)e^(x)+x^3-6x as the particular solution. I even got all the terms he listed as the particular solution, but some of them ended up canceling out so my particular I believe is wrong.

According to your PI, you should get yPI= (1/2)ex+x3-6x.

Which is correct.
 
There are two things I don't understand about this problem. First, when finding the nth root of a number, there should in theory be n solutions. However, the formula produces n+1 roots. Here is how. The first root is simply ##\left(r\right)^{\left(\frac{1}{n}\right)}##. Then you multiply this first root by n additional expressions given by the formula, as you go through k=0,1,...n-1. So you end up with n+1 roots, which cannot be correct. Let me illustrate what I mean. For this...
Back
Top