Results 1 to 14 of 14

Thread: 2nd Order Non-Homogeneous DE

  1. #1
    Junior Member
    Joined
    Dec 2008
    Posts
    70

    2nd Order Non-Homogeneous DE

    Firstly Sorry for all the threads, but i have a test on DE's quite soon and i want to clarify as much as possible really without getting on my tutors bad books(i.e. annoying the hell out of her )

    I can solve this sort

    $\displaystyle y'' + Ay' + B' = Ax^2 + Bx^2 + C$

    However this question is like this

    $\displaystyle y'' - y = 2cosx - 2sinx$

    I haven't a clue how to solve the particular when it ends like that. With my first example you just say $\displaystyle Ax^2 + Bx^2 + C$ and work out the constants, but with this i am unsure.

    I have worked out the $\displaystyle y_{c}(x)$ part

    and get

    $\displaystyle y_{c}(x) = c_{1}e^{-x}+c_{2}e^x$

    But i haven't a clue where to start with $\displaystyle y_{p}(x)$

    Please help, thanks.
    Last edited by Rapid_W; Jun 4th 2009 at 02:17 PM.
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Flow Master
    mr fantastic's Avatar
    Joined
    Dec 2007
    From
    Zeitgeist
    Posts
    16,948
    Thanks
    9
    Quote Originally Posted by Rapid_W View Post
    Firstly Sorry for all the threads, but i have a test on DE's quite soon and i want to clarify as much as possible really without getting on my tutors bad books(i.e. annoying the hell out of her )

    I can solve this sort

    $\displaystyle y'' + Ay' + B' = Ax^2 + Bx^2 + C$

    However this question is like this

    $\displaystyle y'' - y = 2cosx - 2sinx$

    I haven't a clue how to solve the particular when it ends like that. With my first example you just say $\displaystyle Ax^2 + Bx^2 + C$ and work out the constants, but with this i am unsure.

    I have worked out the $\displaystyle y_{c}(x)$ part

    and get

    $\displaystyle y_{c}(x) = c_{1}e^{-x}+c_{2}e^x$

    But i haven't a clue where to start with $\displaystyle y_{p}(x)$

    Please help, thanks.
    Use $\displaystyle y_p = A \cos (x) + B \sin (x)$.
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Junior Member
    Joined
    Dec 2008
    Posts
    70
    Thanks ever so much!

    If for example it was = to 10cosx, what would my plan of action be then?
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Flow Master
    mr fantastic's Avatar
    Joined
    Dec 2007
    From
    Zeitgeist
    Posts
    16,948
    Thanks
    9
    Quote Originally Posted by Rapid_W View Post
    Thanks ever so much!

    If for example it was = to 10cosx, what would my plan of action be then?
    Use $\displaystyle y_p = A \cos (x) + B \sin (x)$.
    Follow Math Help Forum on Facebook and Google+

  5. #5
    Member
    Joined
    May 2009
    Posts
    127
    The easiest way of finding $\displaystyle y_p$ when function on the right is a sum of trigonometric functions is to try

    $\displaystyle y_p = A \sin x + B \cos x$

    and equate coefficients.

    I.e.

    $\displaystyle y_{p}' = A \cos x - B \sin x$

    $\displaystyle y_{p}'' = - (A \sin x + B \cos x) = - y_p$

    so substituting for $\displaystyle y_{p}''$ in your equation gives

    $\displaystyle y_{p}'' - y_{p} = -2 y_{p} = 2 \cos x - 2 \sin x$

    $\displaystyle \Leftrightarrow -A \sin x - B \cos x = \cos x - \sin x$.

    I.e. $\displaystyle A = 1$ and $\displaystyle B = -1$ .

    So the final solution given by $\displaystyle y = y_c + y_p$ is

    $\displaystyle \boxed{ y= c_1 e^{-x} + c_2 e^{x} + \sin x - \cos x }$ .
    Follow Math Help Forum on Facebook and Google+

  6. #6
    Member
    Joined
    May 2009
    Posts
    127
    Sorry, Mr. Fantastic's posts weren't there when I started posting.
    Follow Math Help Forum on Facebook and Google+

  7. #7
    Flow Master
    mr fantastic's Avatar
    Joined
    Dec 2007
    From
    Zeitgeist
    Posts
    16,948
    Thanks
    9
    Quote Originally Posted by the_doc View Post
    The easiest way of finding $\displaystyle y_p$ when function on the right is a sum of trigonometric functions is to try

    $\displaystyle y_p = A \sin x + B \cos x$

    and equate coefficients.

    I.e.

    $\displaystyle y_{p}' = A \cos x - B \sin x$

    $\displaystyle y_{p}'' = - (A \sin x + B \cos x) = - y_p$

    [snip]
    @OP: I will add that this type of particular solution will not work when the non-homogeneous bit of the DE contains $\displaystyle \cos (\lambda x)$ or $\displaystyle \sin (\lambda x)$ terms where $\displaystyle \lambda$ is a solution to the auxillary equation.
    Follow Math Help Forum on Facebook and Google+

  8. #8
    Junior Member
    Joined
    Dec 2008
    Posts
    70
    Thanks i know your answer is correct, but my arithmatic is wrong and i can't work out where

    $\displaystyle y_{p}(x)=Asinx+Bcosx$
    $\displaystyle y'=Acosx-Bsinx$
    $\displaystyle y''=-Asinx - Bsinx$
    so
    $\displaystyle (-A-B)sinx+(A-B)cosx$
    giving
    $\displaystyle -A-B=-2$
    $\displaystyle A-B=2$
    and i keep getting B=0 and A=-2.

    i'll run through what you have done again but i can't work out the jump where you have used the iff symbol
    Follow Math Help Forum on Facebook and Google+

  9. #9
    Junior Member
    Joined
    Dec 2008
    Posts
    70
    Worked out where i've gone wrong. I used y', where i should have used y. I've been awake too long lol, thanks everyone for all your help, i think i've cracked this type of DE now!
    Follow Math Help Forum on Facebook and Google+

  10. #10
    Junior Member
    Joined
    Dec 2008
    Posts
    70
    Hit another obstacle, sorry guys...

    $\displaystyle y''-7y'+10y=9e^{2x}$

    $\displaystyle y_{c}(x) = c_{1}e^{2x}+c_{2}e^{5x}$

    and i took what i though was a logical step for $\displaystyle y_{p}(x)$

    $\displaystyle y_{p}(x)=Ae^{2x}$

    however when i simplified all the substituting i ended up with $\displaystyle 0Ae^{2x}$
    giving $\displaystyle 0A=9$

    which is obviously no help because i highly doubt $\displaystyle y_{p}(x)$ can equal $\displaystyle \infty$.

    Thanks.
    Follow Math Help Forum on Facebook and Google+

  11. #11
    Member
    Joined
    May 2009
    Posts
    127
    Try:

    $\displaystyle y_p (x) = A \,x \,e^{2x}$.

    When the non-homogeneous part is a multiple of a part of your complementary function (in this case $\displaystyle e^{2x}$) then you should try $\displaystyle x$ times it.

    In general you can always use the method of 'Variation of parameters' but it can be alot of work!
    Follow Math Help Forum on Facebook and Google+

  12. #12
    Junior Member
    Joined
    Dec 2008
    Posts
    70
    Thanks, i had just started to try that, there is a lot of work, but i get it down to this

    $\displaystyle y_{p}=Axe^{2x}$
    $\displaystyle y_{p}'=2Axex^{2x} + Ae^{2x}$
    $\displaystyle y_{p}''=4Axe^{2x} + 4Ae^{2x}$

    and plugged back in give

    $\displaystyle -3Ae^{2x}$

    So $\displaystyle -3A = 9$
    $\displaystyle A=-3$

    so $\displaystyle y_{p}(x)=-3xe^{2x}$

    Now, i'm not fully confident with this as Wolfram Alpha lists the particular interval as $\displaystyle -e^{2x}(3x+1)$

    y''-7y'+10y=9e^(2x) - Wolfram|Alpha

    I understand why the 3x is in the bracket, but where has the +1 come from?
    Follow Math Help Forum on Facebook and Google+

  13. #13
    Flow Master
    mr fantastic's Avatar
    Joined
    Dec 2007
    From
    Zeitgeist
    Posts
    16,948
    Thanks
    9
    Quote Originally Posted by Rapid_W View Post
    Thanks, i had just started to try that, there is a lot of work, but i get it down to this

    $\displaystyle y_{p}=Axe^{2x}$
    $\displaystyle y_{p}'=2Axex^{2x} + Ae^{2x}$
    $\displaystyle y_{p}''=4Axe^{2x} + 4Ae^{2x}$

    and plugged back in give

    $\displaystyle -3Ae^{2x}$

    So $\displaystyle -3A = 9$
    $\displaystyle A=-3$

    so $\displaystyle y_{p}(x)=-3xe^{2x}$

    Now, i'm not fully confident with this as Wolfram Alpha lists the particular interval as $\displaystyle -e^{2x}(3x+1)$

    y''-7y'+10y=9e^(2x) - Wolfram|Alpha

    I understand why the 3x is in the bracket, but where has the +1 come from?
    $\displaystyle y_p = -3x e^{2x}$ is the correct particular solution.

    If you add the Wolfram Alpha particular solution to $\displaystyle y_c$ you will see why the +1 is irrelevant.
    Follow Math Help Forum on Facebook and Google+

  14. #14
    Senior Member Sampras's Avatar
    Joined
    May 2009
    Posts
    301
    Quote Originally Posted by Rapid_W View Post
    Firstly Sorry for all the threads, but i have a test on DE's quite soon and i want to clarify as much as possible really without getting on my tutors bad books(i.e. annoying the hell out of her )

    I can solve this sort

    $\displaystyle y'' + Ay' + B' = Ax^2 + Bx^2 + C$

    However this question is like this

    $\displaystyle y'' - y = 2cosx - 2sinx$

    I haven't a clue how to solve the particular when it ends like that. With my first example you just say $\displaystyle Ax^2 + Bx^2 + C$ and work out the constants, but with this i am unsure.

    I have worked out the $\displaystyle y_{c}(x)$ part

    and get

    $\displaystyle y_{c}(x) = c_{1}e^{-x}+c_{2}e^x$

    But i haven't a clue where to start with $\displaystyle y_{p}(x)$

    Please help, thanks.
    Alternatively, we could take the Laplace transform of both sides. Let $\displaystyle \mathcal{L} \{y(x) \} = Y(s) $. We have $\displaystyle y'' - y = 2 \cos x - 2 \sin x$. Then $\displaystyle \mathcal{L} \{y'' - y \} = \mathcal{L} \{2 \cos x - 2 \sin x \} $. Solve for $\displaystyle Y(s) $. Then take inverse Laplace transforms to get $\displaystyle y(x) $.

    We can use this method because this is a second order differential equation with constant coefficients. The point of taking Laplace transforms is to convert the differential equation into an "algebraic" one.
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. 1st order homogeneous
    Posted in the Differential Equations Forum
    Replies: 1
    Last Post: May 21st 2011, 11:34 AM
  2. Homogeneous First-order ODE.
    Posted in the Differential Equations Forum
    Replies: 1
    Last Post: Mar 2nd 2011, 04:37 PM
  3. Second order non-homogeneous ODE
    Posted in the Differential Equations Forum
    Replies: 2
    Last Post: Jan 1st 2011, 10:31 PM
  4. 1st order homogeneous ODE
    Posted in the Differential Equations Forum
    Replies: 2
    Last Post: Dec 31st 2010, 04:28 AM
  5. 3rd order ODE, help with homogeneous
    Posted in the Calculus Forum
    Replies: 0
    Last Post: Apr 5th 2009, 03:49 PM

Search Tags


/mathhelpforum @mathhelpforum