Main content

## AP®︎/College Calculus BC

### Course: AP®︎/College Calculus BC > Unit 7

Lesson 6: Finding general solutions using separation of variables- Separable equations introduction
- Addressing treating differentials algebraically
- Separable differential equations
- Separable differential equations: find the error
- Worked example: separable differential equations
- Separable differential equations
- Worked example: identifying separable equations
- Identifying separable equations
- Identify separable equations

© 2023 Khan AcademyTerms of usePrivacy PolicyCookie Notice

# Separable differential equations

Separation of variables is a common method for solving differential equations. Learn how it's done and why it's called this way.

**Separation of variables**is a common method for solving differential equations. Let's see how it's done by solving the differential equation start fraction, d, y, divided by, d, x, end fraction, equals, start fraction, 2, x, divided by, 3, y, squared, end fraction:

#### Let's review this solution.

In rows left parenthesis, 1, right parenthesis to left parenthesis, 3, right parenthesis we manipulated the equation so it was in the form f, left parenthesis, y, right parenthesis, d, y, equals, g, left parenthesis, x, right parenthesis, d, x. In other words, we separated x and y so each variable had its own side, including the d, x and the d, y that formed the derivative expression start fraction, d, y, divided by, d, x, end fraction. This is why the method is called "separation of variables."

In row left parenthesis, 4, right parenthesis we took the indefinite integral of each side of the equation. The underlying principle, as always with equations, is that if f, left parenthesis, y, right parenthesis, d, y is equal to g, left parenthesis, x, right parenthesis, d, x, then their indefinite integrals must also be equal.

In rows left parenthesis, 5, right parenthesis and left parenthesis, 6, right parenthesis we performed the integration with respect to y (on the left-hand side) and with respect to x (on the right-hand side) and then isolated y.

We only added a constant C on the right-hand side. Adding a constant to both sides would be unnecessary, because we can then move one of the constants to the other side and end up with a single constant.

In conclusion, the general solution of start fraction, d, y, divided by, d, x, end fraction, equals, start fraction, 2, x, divided by, 3, y, squared, end fraction is y, equals, cube root of, x, squared, plus, C, end cube root. You can differentiate y to verify this solution.

Looking back at the equation's solution, notice how the separation of variables that we performed in rows left parenthesis, 1, right parenthesis to left parenthesis, 3, right parenthesis allowed us to integrate each side and obtain an equation without a derivative.

## Want to join the conversation?

- How can we say that we're "integrating" both sides, if we're really just adding two long s, then pretending that the dy and dx we're part of the integration operator notation in the first place? How is this valid?

Also, you're integrating with respects to two different variables. How does this keep the equality?(11 votes)- It's easier to see if we work our way backwards.

Let 𝑔(𝑦) = 𝑓(𝑥) + 𝐶

Since these two functions are equal, that implicitly states that 𝑦 is a function of 𝑥, and we can write

𝑔(ℎ(𝑥)) = 𝑓(𝑥) + 𝐶

Also, since the functions are equal, the slopes of their tangent lines at any point must also be equal.

In other words, their derivatives are equal:

𝑔'(ℎ(𝑥)) ∙ ℎ'(𝑥) = 𝑓 '(𝑥)

𝑦 = ℎ(𝑥) ⇒ 𝑑𝑦∕𝑑𝑥 = ℎ'(𝑥), and we can write

𝑔'(𝑦) ∙ 𝑑𝑦∕𝑑𝑥 = 𝑓 '(𝑥)

Dividing both sides by 𝑔'(𝑦) we get the separable differential equation

𝑑𝑦∕𝑑𝑥 = 𝑓 '(𝑥)∕𝑔'(𝑦)

To conclude, a separable equation is basically nothing but the result of implicit differentiation, and to solve it we just reverse that process, namely take the antiderivative of both sides.(23 votes)

- How do we know what method to choose to solve a differential equations (whether that be by u-substitution, by parts, or by separating the variables)?(6 votes)
- Separable equations have dy/dx (or dy/dt) equal to some expression. U-substitution is when you see an expression within another (think of the chain rule) and also see the derivative. For example, 2x/(x^2+1), you can see x^2+1 as an expression within another (1/x) and its derivative(2x). Solving by parts is when you see something you can simplify when deriving or integrating by itself. Usually it is deriving something simple like x, or something you can't integrate easily like ln(x).(15 votes)

- Why when you take the integral of "y" in the left side there is no C?(4 votes)
- Whenever we have two constants C1 and C2, we can combine them to form one single constant C.

At first this may seem like cheating but really all we are saying is C1 and C2 are two mysterious unknown quantities, but we can think of C1 + C2 as 1 mysterious unknown as quantity, and we still haven't changed the value of the equation.

So given x + C1 = y + C2 we can simplify by writing y = x + C.

Happy learning! :-)(6 votes)

- How do we describe a natural phenomenon through a differential equation? Is there any video about that?(2 votes)
- The introductory ones in this unit deal with that. Even watering your plants can be written in differential equation! I can not attest it myself but I have heard that university-level physics is all about calculus and physics is basically the part of science that is trying to describe all natural phenomenons.Doing the problems in writing differential equations in this unit will give you a primary idea.(6 votes)

- In some cases i have been taught that an derivative dy/dx can't be treated as an ratio of the variables dy and dx. But in other cases like this one they are treated just like a ratio. In this example above you can multiply and divide dy and dx. Why is that? I asked my teachers and they say that its not included in the course but im curious.

kind regards,

Viktor(2 votes)- Khan made a video on it. https://www.khanacademy.org/math/ap-calculus-ab/ab-differential-equations-new/ab-7-6/v/addressing-treating-differentials-algebraically

He treats the dx's and dy's as super small changes in x and y, which makes them values that can be multiplied and divided. Keep in mind though that he does say it's a rather hand-wavy method, not too rigorous.(3 votes)

- If I had a step something like: (-y = -x + C), why does it become (y = x + C) and not (y = x - C)?(1 vote)
- If you had a step like:
*(-y = -x + C)*,

let's rewrite this as:*(-y) = (-x) + (C)*

Now, let's multiply both the sides by (-1):*(-1)*(-y) = (-1)*[(-x) + (C)]*

Distributing the (-1) on the R.H.S. gives:*(-1)*(-y) = [(-1)*(-x)] + [(-1)*(C)]*

Here, the constant (C), when multiplied by (-1) will give another constant; which can be denoted by (C) again.

In the expression,*(-y = -x + C)*

We don't know the value of the constant (C). It can can be either positive or negative. So, multiplying with (-1) can give respective result. It's safe to keep the '+' sign in the original expression intact and the constant (C) in parenthesis.

Thus,*y = x + C*(2 votes)

- dy/dx=-xy

Solve separation of variables(1 vote)- 𝑑𝑦∕𝑑𝑥 = −𝑥𝑦

Multiplying both sides by (1∕𝑦)𝑑𝑥, we get

(1∕𝑦)𝑑𝑦 = −𝑥𝑑𝑥

Integrating both sides, we get

ln |𝑦| = −𝑥²∕2 + 𝐶, where 𝐶 is an arbitrary constant.

Solving for 𝑦, we get

𝑦 = ±𝑒^(−𝑥²∕2 + 𝐶) = ±𝑒^(−𝑥²∕2)⋅𝑒^𝐶

However, because 𝐶 is an arbitrary constant, then ±𝑒^𝐶 is also an arbitrary constant.

Thus, we can write 𝑦 = 𝐶𝑒^(−𝑥²∕2)(2 votes)

- why did you divide e^x+C by 1 in the second part of the last step(1 vote)
- For problem 1.C, how do you know when to put C by itself or in the denominator when rearranging other variables?(1 vote)
- C in general should never be in the denominator. Even if you solve everything and get a 1/C, you should take 1/C = C.(1 vote)

- I know that in some cases, the C value moves to the front and is multiplied by e^(u). I just forget how and why that happens, it has something to "e" and "ln".(1 vote)