7. Differential Equations

Finding General Solutions Using Separation Of Variables

Finding General Solutions Using Separation of Variables

Welcome, students! 🌟 In this lesson, you will learn how to solve a special but very important type of differential equation called a separable differential equation. These equations show up when a rate of change depends on both the input and the output in a way that lets us split the variables apart. By the end of this lesson, you should be able to explain the idea of separation of variables, solve a separable equation step by step, and understand how the general solution describes a whole family of possible solution curves.

Why Separation of Variables Matters

Differential equations are equations that involve a function and its derivative, such as $\frac{dy}{dx}=x^2$ or $\frac{dy}{dx}=xy$. They are used to model real situations where something changes over time or with respect to another variable. For example, population growth, cooling, spread of diseases, and motion under resistance can all be modeled with differential equations 📈.

A differential equation is called separable if it can be rewritten so that all the $y$-terms are on one side and all the $x$-terms are on the other side. This is powerful because it lets us integrate both sides separately. That is the main idea of separation of variables.

The goal is not just to find one answer. In AP Calculus BC, we often want the general solution, which is a formula containing an arbitrary constant, usually written as $C$. This represents all possible solutions before any initial condition is applied.

For example, if a differential equation leads to a solution like $y=x^2+C$, then this is a family of curves. Different values of $C$ produce different graphs, all satisfying the same differential equation.

Step 1: Recognize a Separable Differential Equation

A separable differential equation often looks like

$$

$\frac{dy}{dx}=f(x)g(y)$

$$

or something that can be rearranged into that form. The key is that the right side can be factored into one part with $x$ and one part with $y$.

Example 1

Consider

$$

$\frac{dy}{dx}=xy$

$$

This is separable because the $x$ and $y$ pieces are already multiplied together. We can rewrite it by dividing by $y$ and multiplying by $dx$:

$$

$\frac{1}{y}\,dy=x\,dx$

$$

Now all the $y$-terms are with $dy$ and all the $x$-terms are with $dx$.

Why this works

If we think of $\frac{dy}{dx}$ as a rate, separation of variables is like sorting ingredients into two bowls before cooking. You move the $y$-stuff to one side and the $x$-stuff to the other so each side can be integrated independently 🍲.

Be careful: this step may require dividing by an expression involving $y$. If you divide by something that could be zero, you must check whether that creates a missing solution. For example, if you divide by $y$, then the constant solution $y=0$ might be lost and should be checked separately.

Step 2: Separate the Variables Correctly

Once you identify that an equation is separable, rewrite it so the variables are separated.

Example 2

Solve

$$

$\frac{dy}{dx}=\frac{x}{y}$

$$

First separate the variables:

$$

$ y\,dy=x\,dx$

$$

Now integrate both sides:

$$

$\int y\,dy=\int x\,dx$

$$

This gives

$$

$\frac{y^2}{2}=\frac{x^2}{2}+C$

$$

Multiply by $2$:

$$

$ y^2=x^2+C$

$$

This is the general solution. You could also write it as

$$

$ y=\pm\sqrt{x^2+C}$

$$

but the form $y^2=x^2+C$ is usually cleaner and keeps the family of solutions together.

Important AP tip

In calculus, the constant of integration does not need to be written twice. If you integrate both sides and get two constants, they can be combined into one constant $C$. For example,

$$

$\int f(x)\,dx=\int g(y)\,dy$

$$

might become

$$

$F(x)=G(y)+C$

$$

or after rearranging,

$$

$G(y)=F(x)+C$

$$

That single constant is enough because it represents all possible vertical shifts in the family of solutions.

Step 3: Integrate Both Sides

After separation, integrate each side with respect to its own variable. This is the main algebra-calculus move in the process.

Example 3

Solve

$$

$\frac{dy}{dx}=3y$

$$

Separate variables:

$$

$\frac{1}{y}\,dy=3\,dx$

$$

Integrate:

$$

$\int \frac{1}{y}\,dy=\int 3\,dx$

$$

So

$$

$\ln|y|=3x+C$

$$

Now solve for $y$:

$$

$|y|=e^{3x+C}$

$$

Since $e^{3x+C}=e^C e^{3x}$, let $A=e^C$, where $A>0$. Then

$$

$|y|=Ae^{3x}$

$$

This becomes

$$

$ y=Ce^{3x}$

$$

where $C$ can now be any nonzero real number, and it also can represent $0$ if needed. This is the general solution.

Why logarithms appear

Whenever you integrate a function like $\frac{1}{y}$, the result is a logarithm. This is common in separable differential equations. On the AP exam, it is important to know that

$$

$\int \frac{1}{y}\,dy=\ln|y|+C$

$$

The absolute value matters because $\ln(y)$ is only defined for positive $y$, but solutions may be positive or negative.

Step 4: Write the General Solution Clearly

A general solution is a solution with an arbitrary constant. It describes all members of the family of curves that satisfy the differential equation.

Example 4

Solve

$$

$\frac{dy}{dx}=x^2y^2$

$$

Separate variables:

$$

$\frac{1}{y^2}\,dy=x^2\,dx$

$$

Integrate:

$$

$\int y^{-2}\,dy=\int x^2\,dx$

$$

This gives

$$

$-\frac{1}{y}=\frac{x^3}{3}+C$

$$

Now solve for $y$:

$$

$\frac{1}{y}=-\frac{x^3}{3}+C$

$$

or equivalently,

$$

$ y=\frac{1}{C-\frac{x^3}{3}}$

$$

Either form is acceptable if written correctly. The key idea is that the final answer should contain a constant and represent a whole family of solutions.

Checking your work

A good habit is to differentiate your answer and compare it to the original differential equation. If your solution is

$$

$ y=\frac{1}{C-\frac{x^3}{3}}$

$$

then computing $\frac{dy}{dx}$ should give back $x^2y^2$. This is an excellent way to verify your algebra and calculus ✅.

Step 5: Understand Special Solutions and Initial Conditions

Sometimes the general solution includes a constant that must be found using an initial condition, such as $y(0)=2$. Then the general solution becomes a particular solution.

Example 5

Suppose

$$

$\frac{dy}{dx}=xy$

$$

and $y(0)=5$.

We already know the general solution is

$$

$ y=Ce^{x^2/2}$

$$

Now apply the initial condition:

$$

$5=Ce^{0}$

$$

so

$$

$C=5$

$$

Therefore the particular solution is

$$

$ y=5e^{x^2/2}$

$$

This shows the difference between a general solution and a particular solution. The general solution is the full family, and the particular solution is one specific curve chosen by extra information.

A common AP mistake

Do not forget to include constant solutions. If you divide by $y$, you may accidentally lose $y=0$. Always check whether $y=0$ satisfies the original differential equation.

For example, in

$$

$\frac{dy}{dx}=xy$

$$

if $y=0$, then the right side is $0$, and $\frac{dy}{dx}=0$ is true. So $y=0$ is also a solution.

Conclusion

Separation of variables is one of the most important tools for solving differential equations in AP Calculus BC. The method works by rewriting the equation so that $x$-terms and $y$-terms are on opposite sides, integrating both sides, and then solving for the function when possible. students, remember that the result is often a general solution containing an arbitrary constant $C$, and that initial conditions can turn it into a particular solution.

This topic connects directly to the larger study of differential equations because it gives a practical way to build mathematical models and predict change. Whether the context is population growth, cooling, or motion, separation of variables helps convert a rate equation into a usable formula. Mastering this method will help you on AP problems involving modeling, solution curves, and the interpretation of differential equations 📚.

Study Notes

  • A separable differential equation can be rewritten so that all $y$-terms are on one side and all $x$-terms are on the other.
  • The general pattern is often $\frac{dy}{dx}=f(x)g(y)$.
  • Separate variables by rewriting the equation as $g(y)\,dy=f(x)\,dx$.
  • Integrate both sides: $\int g(y)\,dy=\int f(x)\,dx$.
  • Include the constant of integration as $C$ in the final general solution.
  • A general solution describes a family of curves, not just one curve.
  • A particular solution is found by using an initial condition such as $y(0)=2$.
  • Be careful not to lose solutions when dividing by an expression like $y$.
  • Always check for constant solutions that may satisfy the original differential equation.
  • Common integrals in separable equations include $\int \frac{1}{y}\,dy=\ln|y|+C$ and $\int y^n\,dy=\frac{y^{n+1}}{n+1}+C$ for $n\neq -1$.
  • Separation of variables is a major AP Calculus BC skill for modeling change with differential equations.

Practice Quiz

5 questions to test your understanding