1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Homework Help: Solving dy/dx=x-y

  1. Mar 15, 2010 #1
    1. The problem statement, all variables and given/known data

    [tex]\int (x-y) [/tex]

    What is [tex]\int y[/tex] ? I don't mean [tex]\int y dy[/tex].

    3. The attempt at a solution

    [tex]dy/dx = x-y[/tex]
    [tex]y + dy = x dx[/tex]
    [tex]\int y + \int dy = \int x dx[/tex]
    [tex]\int y + y = x^2/2 + c[/tex]

    I am stuck at this point because I don't know how to integrate y without respect to anything...If that even makes sense.

    EDIT:

    Nvm...I am stupid xD

    [tex]\int x dx - \int y dx [/tex]
     
    Last edited: Mar 15, 2010
  2. jcsd
  3. Mar 15, 2010 #2

    gabbagabbahey

    User Avatar
    Homework Helper
    Gold Member

    That still doesn't help you though. How exactly do you plan on integrating [itex]\int y(x) dx[/itex] when you don't know what [itex]y(x)[/itex] is?

    You can't solve this differential equation just by integrating both sides. Instead, try using the substitution [itex]u=x-y[/itex] to rewrite the DE in terms of [itex]u(x)[/itex] and [itex]u'(x)[/itex].
     
  4. Mar 15, 2010 #3

    D H

    User Avatar
    Staff Emeritus
    Science Advisor

    That will result in another nonhomogeneous ODE. A tiny bit simpler perhaps, but still nonhomogeneous.

    computerex: What have you been taught regarding solving nonhomogeneous differential equations?
     
  5. Mar 15, 2010 #4

    gabbagabbahey

    User Avatar
    Homework Helper
    Gold Member

    Something about separable ODE's appeals to me though:wink:
     
  6. Mar 15, 2010 #5

    D H

    User Avatar
    Staff Emeritus
    Science Advisor

    Depends on the OP's background. The original problem can be rewritten as

    [tex]\frac{dy}{dx} + y = x[/tex]

    The homogeneous and particular solutions can be read off just by inspection.
     
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook