Lesson 11: Separable Differential Equations
Separating the Variables
A separable differential equation can be rearranged so that all the y terms are on one side with dy, and all the x terms are on the other side with dx. The equation dy/dx equals x y is separable: divide both sides by y and multiply by dx, and you get dy over y equals x dx. Integrate both sides, and the general solution appears. The method is mechanical, but it only works when the equation separates cleanly, and recognising when it does is part of the skill.
Worked example: solve dy/dx equals x y with y(0) equals 3. Separating gives dy over y equals x dx. Integrating gives the natural log of the absolute value of y equals x squared over 2 plus C. Exponentiating gives y equals A e to the x squared over 2, where A is a constant. The initial condition y(0) equals 3 gives A equals 3, so the particular solution is y equals 3 e to the x squared over 2. Check it: the derivative is 3x e to the x squared over 2, and x y is x times 3 e to the x squared over 2, the same.
Worked example with a trickier separation: solve dy/dx equals y squared times x with y(0) equals 1. Separating gives dy over y squared equals x dx. Integrating gives minus 1 over y equals x squared over 2 plus C. At x equals 0, y is 1, so C is minus 1, and minus 1 over y equals x squared over 2 minus 1, so y equals 1 over 1 minus x squared over 2. The solution blows up when x squared over 2 equals 1, that is, when x is the square root of 2, about 1.41. The model is only valid before that point, and the blow-up is a real feature of the equation, not an error: the growth accelerates so fast that the solution reaches infinity in finite time. Checking the domain of a solution is part of solving the equation.
The Constant and the Absolute Value
Two details cause most errors in separable equations. The first is the constant of integration: it appears on one side only, and it must be carried through the exponentiation, where it becomes a multiplicative constant. Writing plus C on both sides, or forgetting it entirely, loses the family of solutions. The second is the absolute value in the logarithm: the integral of 1 over y is the natural log of the absolute value of y, and dropping the absolute value can lose solutions or produce a wrong sign.
The cleanest habit is to exponentiate as soon as the logarithms appear, and to let the constant absorb the sign. The natural log of the absolute value of y equals x squared over 2 plus C becomes the absolute value of y equals e to the C times e to the x squared over 2, and e to the C is a positive constant, while the absolute value allows either sign, so y equals A e to the x squared over 2 with A any constant. The initial condition then fixes A, sign included.
When Separation Fails
Not every first-order equation is separable. The equation dy/dx equals x plus y cannot be separated, because the right side is a sum, and no rearrangement puts all the y terms on one side and all the x terms on the other. For such equations, the slope field is the tool: you can describe the solutions and sketch them even though you cannot write them down. Recognising a non-separable equation quickly saves time: if you spend five minutes trying to separate x plus y, you have lost five minutes.
A useful test is to ask whether the right side is a product of a function of x and a function of y. If it is, the equation separates. If it is a sum, or if x and y are mixed inside a function, it does not. The equation dy/dx equals x squared times y cubed separates; dy/dx equals x squared plus y cubed does not. That one-word difference, times versus plus, decides the whole method.
Key Terms
- Separable equation
- A differential equation that can be rearranged with all y terms on one side and all x terms on the other.
- Separation of variables
- The method of solving a separable equation by integrating each side separately.
- Constant of integration
- The constant that appears when integrating; it becomes a multiplicative constant after exponentiating.
- Particular solution
- The solution that satisfies a given initial condition.
- Absolute value
- The size of a number ignoring its sign; it appears when integrating 1 over y.
- Non-separable equation
- An equation that cannot be split into x-only and y-only sides, such as dy/dx equals x plus y.
Discussion Questions
- Why does the constant of integration become a multiplicative constant after exponentiating?
- What is the test for whether an equation is separable?
- Why is the slope field still useful when an equation cannot be separated?
Practice Questions
- Solve dy/dx equals x y with y(0) equals 3. What is the particular solution?
- Why does the initial condition y(0) equals 3 give A equals 3?
- Is dy/dx equals x squared plus y cubed separable?
- What is the integral of 1 over y dy?
- How do you verify a solution to a differential equation?
Show answers
- y equals 3 e to the x squared over 2.
- Because at x equals 0, e to the 0 is 1, so y(0) equals A.
- No, because the right side is a sum, not a product of a function of x and a function of y.
- The natural log of the absolute value of y, plus a constant.
- Differentiate it and substitute it and its derivative into the equation, checking both sides match.