Results 1 to 9 of 9

Math Help - Initial value problem

  1. #1
    Newbie
    Joined
    Jan 2010
    Posts
    7

    Initial value problem

    I'm so close to the answer, I've narrowed it down to two possibilites, here is the question:

    Find the initial value problem:

    cos(x)dy/dx-ysin(x)=xcos(x)

    Here are my two answers, only varying by the negative sign in front:

    y= -(x)tan(x)+1-4sec(x) or y= (x)tan(x)+1-4sec(x)

    Any help is greatly appreciated!
    Follow Math Help Forum on Facebook and Google+

  2. #2
    MHF Contributor
    Jester's Avatar
    Joined
    Dec 2008
    From
    Conway AR
    Posts
    2,340
    Thanks
    21
    Quote Originally Posted by KennyP33 View Post
    I'm so close to the answer, I've narrowed it down to two possibilites, here is the question:

    Find the initial value problem:

    cos(x)dy/dx-ysin(x)=xcos(x)

    Here are my two answers, only varying by the negative sign in front:

    y= -(x)tan(x)+1-4sec(x) or y= (x)tan(x)+1-4sec(x)

    Any help is greatly appreciated!
    Assuming that the IC is y(0)=-3, it's the second answer.
    Follow Math Help Forum on Facebook and Google+

  3. #3
    MHF Contributor
    Prove It's Avatar
    Joined
    Aug 2008
    Posts
    11,319
    Thanks
    1238
    Quote Originally Posted by KennyP33 View Post
    I'm so close to the answer, I've narrowed it down to two possibilites, here is the question:

    Find the initial value problem:

    cos(x)dy/dx-ysin(x)=xcos(x)

    Here are my two answers, only varying by the negative sign in front:

    y= -(x)tan(x)+1-4sec(x) or y= (x)tan(x)+1-4sec(x)

    Any help is greatly appreciated!
    \cos{x}\frac{dy}{dx} - (\sin{x})y = x\cos{x}

    \frac{dy}{dx} - (\tan{x})y = x.


    This is first order linear, so use the integrating factor:

    e^{\int{\tan{x}\,dx}} = e^{-\ln{(\cos{x})}} = e^{\ln{\sec{x}}} = \sec{x}.

    Multiplying through by the integrating factor gives:


    \sec{x}\frac{dy}{dx} - (\sec{x}\tan{x})y = x\sec{x}

    The left hand side is a product rule expansion of (\sec{x})y, so


    \frac{d}{dx}[(\sec{x})y] = x\sec{x}

    (\sec{x})y = \int{x\sec{x}\,dx}.


    So y = \cos{x}\int{x\sec{x}\,dx}.
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Newbie
    Joined
    Jan 2010
    Posts
    7
    oh, wow, i forgot to add y(pi)=5
    Follow Math Help Forum on Facebook and Google+

  5. #5
    MHF Contributor
    Jester's Avatar
    Joined
    Dec 2008
    From
    Conway AR
    Posts
    2,340
    Thanks
    21
    Quote Originally Posted by Prove It View Post
    \cos{x}\frac{dy}{dx} - (\sin{x})y = x\cos{x}

    \frac{dy}{dx} - (\tan{x})y = x.


    This is first order linear, so use the integrating factor:

    e^{\int{\tan{x}\,dx}} = e^{-\ln{(\cos{x})}} = e^{\ln{\sec{x}}} = \sec{x}.

    Multiplying through by the integrating factor gives:


    \sec{x}\frac{dy}{dx} - (\sec{x}\tan{x})y = x\sec{x}

    The left hand side is a product rule expansion of (\sec{x})y, so


    \frac{d}{dx}[(\sec{x})y] = x\sec{x}

    (\sec{x})y = \int{x\sec{x}\,dx}.


    So y = \cos{x}\int{x\sec{x}\,dx}.
    I believe that P(x) = - \tan x and not what you have P(x) = \tan x.
    Follow Math Help Forum on Facebook and Google+

  6. #6
    MHF Contributor
    Jester's Avatar
    Joined
    Dec 2008
    From
    Conway AR
    Posts
    2,340
    Thanks
    21
    Quote Originally Posted by KennyP33 View Post
    oh, wow, i forgot to add y(pi)=5
    Still - it's the second one.
    Follow Math Help Forum on Facebook and Google+

  7. #7
    Newbie
    Joined
    Jan 2010
    Posts
    7
    so the one without the negative sign?
    Follow Math Help Forum on Facebook and Google+

  8. #8
    MHF Contributor
    Jester's Avatar
    Joined
    Dec 2008
    From
    Conway AR
    Posts
    2,340
    Thanks
    21
    Quote Originally Posted by KennyP33 View Post
    so the one without the negative sign?
    Yep!
    Follow Math Help Forum on Facebook and Google+

  9. #9
    MHF Contributor
    Prove It's Avatar
    Joined
    Aug 2008
    Posts
    11,319
    Thanks
    1238
    Quote Originally Posted by Danny View Post
    I believe that P(x) = - \tan x and not what you have P(x) = \tan x.
    Thanks.

    So to fix up my mistake...

    The integrating factor is e^{\int{-\tan{x}\,dx}} = e^{\ln{(\cos{x})}} = \cos{x}.


    So multiplying through we find

    \cos{x}\,\frac{dy}{dx} - (\sin{x})y = x\cos{x}.


    The LHS is a product rule expansion, so

    \frac{d}{dx}[(\cos{x})y] = x\cos{x}

    So (\cos{x})y = \int{x\cos{x}\,dx}.


    Now integrating by parts with u = x so that du = 1 and dv = \cos{x} so that v = \sin{x}, we have


    (\cos{x})y = x\sin{x} - \int{\sin{x}\,dx}

    (\cos{x})y = x\sin{x} + \cos{x} + C

    y = x\tan{x} + 1 + C\sec{x}.



    Now apply your initial conditions.
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Initial Value Problem
    Posted in the Differential Equations Forum
    Replies: 5
    Last Post: September 6th 2011, 05:29 PM
  2. Initial Value Problem: PLEASE HELP!
    Posted in the Differential Equations Forum
    Replies: 1
    Last Post: December 8th 2009, 11:21 AM
  3. Initial value problem
    Posted in the Differential Equations Forum
    Replies: 11
    Last Post: August 21st 2009, 09:55 AM
  4. initial value problem for ODE's
    Posted in the Calculus Forum
    Replies: 6
    Last Post: February 7th 2007, 04:56 AM
  5. Initial Value Problem
    Posted in the Calculus Forum
    Replies: 7
    Last Post: August 26th 2005, 01:59 AM

Search Tags


/mathhelpforum @mathhelpforum