Separating the Variables
Open the lesson
How to solve a differential equation dy/dx = g(x)h(y) by separating the variables: one constant only, fixing it at once from an initial condition, and the trap of lost constant solutions when you divide by h(y). Solved examples: y' = xy, (1+x^2)dy = (1+y^2)dx with y(0) = 1, and all solutions of y' = y^2 - 1.
Chapters
Transcript
0:00Introduction
Hello everyone! Here is a small puzzle: d y by d x equals x times y. We want y, but the right side contains y, and y itself depends on x, so we cannot simply integrate it with respect to x. So what do we do? Here is the idea: what if every y could move to one side, and every x to the other? Then each side is an ordinary integral, which you already know. That is the method of separating the variables. And there is a twist: done carelessly, it can quietly lose a solution. We will catch one today. Equations like this come up often in JEE, so let's begin.
0:43Separate, then integrate
So, here is the shape we look for. d y by d x, the derivative of y with respect to x, equals g of x times h of y. g of x has only x in it, h of y has only y, and the two are multiplied. Okay? Now tell me: how do we get every y to the left side, and every x to the right side? Yes, exactly, we divide both sides by h of y, and multiply by d x. So d y over h of y equals g of x, d x. Only y on the left, only x on the right. The variables are separated! Right? Now integrate both sides. The tall curly S on screen is the integral sign. The integral of d y over h of y equals the integral of g of x, d x, plus capital C, the arbitrary constant. Two ordinary integrals. Clear?
1:43Back to our puzzle: y'=xy
Now back to our puzzle. The small dash after y is called a prime, and y prime means d y by d x. So y prime equals x times y, with h of y equal to y and g of x equal to x. Divide by y, multiply by d x, and we get d y over y equals x, d x. With me? Integrate both sides. On the left, the integral of one over y is the natural log of mod y. The letters l n stand for the natural log, and the two vertical bars mean the modulus. On the right, we get x squared over two, plus small c, a constant on one side only. Got it? Now take e to the power of both sides. The constant e to the power c, together with the plus or minus sign from the modulus, becomes one new constant, written capital C in the answer. So y equals capital C times e to the power x squared over two. And capital C equal to zero gives y equals zero, which is also a solution; it is the one our division by y set aside. Easy, right?
2:50Three rules that save marks
Now, three rules that save marks. When we integrate, each side could get its own constant. So should we write a constant on both sides? There is no need, because two constants on the two sides just combine into one. So rule one: one constant is enough; put it on one side only. Clear? Rule two is where the JEE trap hides. To separate, we divided by h of y. That assumes h of y is not zero; the equals sign with a slash through it means not equal to. Right? Now suppose some number, y naught, makes h of y naught equal to zero. The small zero written below y is a subscript, so y naught is just one fixed number. Is the constant function, y equals y naught, a solution? Yes, it is a solution, because for a constant function d y by d x is zero, and the right side, g of x times h of y naught, is zero too. But our division threw it away. So such constant solutions can be lost; check them separately. Got it? And rule three: when the question gives an initial condition, like the value of y at x equals zero, fix capital C at once, then simplify. With me?
4:08Example 1: (1+x2)dy = (1+y2)dx with y(0) = 1
Now, Example one. Solve one plus x squared, times d y, equals one plus y squared, times d x, given that y of zero equals one, which means y is one when x is zero. Pause the video and try it first. Done? Okay, let's check. Divide both sides by one plus x squared, and by one plus y squared. So d y over one plus y squared equals d x over one plus x squared. Did we lose anything? No, because one plus y squared is never zero. Right? Both sides are standard integrals. Tan inverse y equals tan inverse x, plus capital C, with one constant only. The little minus one written up on tan means inverse, not one over tan. Got it? Now use rule three, and fix capital C at once. Put x equals zero and y equals one. What is capital C? Tan inverse of one is pi over four, where pi is the Greek letter on screen, and tan inverse of zero is zero. So capital C equals pi over four. Did you get that? So y equals tan of the bracket, tan inverse x plus pi over four. Now let us simplify it, as rule three says. Use the formula for the tan of a sum. Tan of tan inverse x is x, and tan of pi over four is one. So the top is x plus one, and the bottom is one minus x times one; the cross on screen means times. So y equals one plus x, over one minus x. Neat, isn't it?
5:48Example 2: all solutions of y' = y2 - 1, incl. lost y = -1
Now Example two, a little harder. Find all solutions of y prime equals y squared minus one. Notice the word all; that is your hint. Pause the video and try it first. Done? Okay, let's check. Rule two says find the constant solutions before dividing. y squared minus one is zero when y is plus or minus one; the sign on screen means plus or minus. So y equals one, and y equals minus one, are both solutions. Clear? Now, for y not equal to plus or minus one, we may divide. y squared minus one factorises as y minus one, times y plus one. So d y over that product equals d x. Okay? Split the left side into partial fractions and integrate. We get one half of the natural log of the modulus of y minus one over y plus one, equal to x plus small c. Right? Multiply by two, and take e to the power of both sides. As before, the plus or minus sign and the constant combine into one capital C again. So y minus one, over y plus one, equals capital C times e to the power two x. Got it? Now, many students stop right here and write this as the final answer. But wait, this family came from dividing. Does it contain y equals one? And does it contain y equals minus one? Put capital C equals zero: then y minus one is zero, so y equals one comes back. But y equals minus one makes the bottom zero, so no value of capital C gives it. This is the lost solution we promised to catch. With me? So the complete answer is this: y minus one, over y plus one, equals capital C times e to the power two x, together with y equals minus one. Skip the check, and you lose a solution, and the marks. Okay?
7:51Quick revision: separate, one constant, check lost solutions
So, quick revision. Write d y by d x equals g of x times h of y as d y over h of y equals g of x, d x, and integrate both sides. Use one constant only, and fix it at once from an initial condition. And check the zeros of what you divide by, because constant solutions can be lost. You have got this. Now go and try the practice problems on this page, and all the best!
More videos in Unit 9 · Differential Equations
- Order and Degree
- Forming the Differential Equation of a Family
- Solutions of a Differential Equation
- Equations Reducible to Separable Form
- Growth, Decay and Other Rate Problems
- The Substitution y=vx
- Equations Reducible to Homogeneous Form
- JEE Advanced Questions: Homogeneous Equations
- The Integrating Factor
- Bernoulli Equations and Other Substitutions
- Exact Differentials
- Geometric Applications
- Integral Equations, Functional Equations and Inequalities
- JEE Advanced Questions: Inequalities and Functional Equations
- Overview
- Mixed Problems: Set 1
- Mixed Problems: Set 2
- Mixed Problems: Set 3
- Overview
- Part A: JEE Main Level
- Part C: Concept Checks