AP Calculus BC Unit 7 Notes: Solving Differential Equations (Separable, Exponential, Logistic)
Separation of Variables: General and Particular Solutions
A differential equation is an equation that relates a function to one or more of its derivatives. In AP Calculus, you most often see first-order differential equations, where the derivative looks like \frac{dy}{dx} or \frac{dP}{dt}. Solving a differential equation means finding a function (or family of functions) whose derivative behavior matches the equation.
A powerful and commonly testable technique is separation of variables. You use it when the differential equation can be rearranged so that all the y-terms are on one side and all the x-terms are on the other side. Once separated, you integrate both sides to “undo” the derivatives.
What “separable” means (and why it matters)
A first-order differential equation is separable if it can be written (or rearranged) in the form
\frac{dy}{dx} = g(x)h(y)
where g(x) is a function of x only and h(y) is a function of y only. This matters because it lets you treat the derivative as a fraction (with care) and move factors around:
\frac{1}{h(y)}\frac{dy}{dx} = g(x)
and then
\frac{1}{h(y)}dy = g(x)dx
At that point, each side involves only one variable, so you can integrate both sides.
Conceptually, separation of variables works because you’re rewriting the statement “the rate of change of y depends on both x and y” into a form where changes in y can be matched to changes in x through integrals.
General solution vs. particular solution
When you integrate, you introduce an arbitrary constant. That’s because many different functions can have the same derivative “pattern” except for a vertical shift or scaling.
- A general solution is a whole family of solutions that includes an arbitrary constant (often C).
- A particular solution is the single solution you get after using an initial condition, like y(0)=5, to determine that constant.
In AP questions, you’re often expected to find the general solution first, then apply an initial condition to produce the particular solution.
The standard separation procedure (mechanism)
Suppose you’re given a separable differential equation.
- Rewrite the equation so that you clearly see which parts depend on x and which depend on y.
- Separate: move all y expressions (including dy) to one side and all x expressions (including dx) to the other.
- Integrate both sides.
- Combine constants into a single constant C.
- Solve for y if possible (sometimes an implicit solution is acceptable or even expected).
- Apply the initial condition (if given) to find the particular solution.
A common point of confusion: you’ll sometimes see an implicit step where \frac{dy}{dx} is treated like a fraction. This is justified here because the separation comes from algebraic manipulation consistent with the chain rule, but you still need to separate correctly before integrating.
Important notation (so you don’t get tripped up)
In calculus, the derivative can be written in different ways. These are equivalent when y depends on x:
| Meaning | Common notation | Another common notation |
|---|---|---|
| derivative of y with respect to x | \frac{dy}{dx} | y' |
| derivative of P with respect to t | \frac{dP}{dt} | P' |
On the AP exam, \frac{dy}{dx} and Leibniz notation are common in differential equations because they make separation more visually natural.
Example 1: Solving a separable differential equation (general solution)
Solve
\frac{dy}{dx} = xy^2
Step 1: Separate variables. Put all y terms with dy and all x terms with dx.
\frac{1}{y^2}dy = xdx
Step 2: Integrate both sides.
\int y^{-2}dy = \int xdx
-y^{-1} = \frac{x^2}{2} + C
Step 3: Solve for y.
-\frac{1}{y} = \frac{x^2}{2} + C
Multiply by -1 and absorb the sign into the constant (renaming constants is allowed):
\frac{1}{y} = -\frac{x^2}{2} + C
Invert:
y = \frac{1}{C - \frac{x^2}{2}}
This is a general solution because it contains an arbitrary constant C.
What can go wrong here: forgetting that \int y^{-2}dy = -y^{-1}+C (the negative sign is easy to miss), or incorrectly integrating \int xdx.
Example 2: Particular solution using an initial condition
Solve the initial value problem
\frac{dy}{dx} = xy
with y(0)=3.
Separate:
\frac{1}{y}dy = xdx
Integrate:
\int \frac{1}{y}dy = \int xdx
A key detail: \int \frac{1}{y}dy = \ln|y| + C, not \ln(y) without absolute value.
\ln|y| = \frac{x^2}{2} + C
Exponentiate to solve for y:
|y| = e^{\frac{x^2}{2}+C}
Rewrite e^C as a positive constant K:
|y| = Ke^{\frac{x^2}{2}}
This implies
y = Ae^{\frac{x^2}{2}}
where A can be any nonzero real constant (positive or negative), which accounts for the absolute value.
Apply the initial condition y(0)=3:
3 = Ae^{0}
A=3
So the particular solution is
y = 3e^{\frac{x^2}{2}}
What can go wrong here: dropping the absolute value too early and accidentally excluding negative solutions, or mishandling exponent rules when solving for y.
A subtle but important point: equilibrium (constant) solutions
Sometimes you divide by an expression involving y to separate variables. If that expression can be zero, you may accidentally lose solutions.
For example, if
\frac{dy}{dx} = y(1-y)
and you divide by y(1-y), you are assuming y \neq 0 and y \neq 1. But y=0 and y=1 are actually valid constant (equilibrium) solutions because they make \frac{dy}{dx}=0 everywhere.
A good habit: before dividing by something involving y, quickly ask, “Could that be zero? If so, does it create a constant solution?”
Exam Focus
- Typical question patterns:
- “Solve the differential equation” followed by “use y(a)=b to find the particular solution.”
- “Find y as a function of x” and then evaluate y at a new input.
- “Show that the solution can be written as …” (often expecting separation, integration, and algebraic rearrangement).
- Common mistakes:
- Forgetting the constant of integration C or failing to use the initial condition to determine it.
- Incorrect integration, especially \int \frac{1}{y}dy and negative exponents.
- Dividing by a factor like y and losing an equilibrium solution (not always tested, but it’s a classic trap).
Exponential Models with Differential Equations
An exponential growth/decay model is based on the idea that the rate of change of a quantity is proportional to the amount present. This is one of the most important modeling ideas in calculus because it turns a real-world statement about “rate” into a differential equation you can solve.
The core idea: “proportional to the amount present”
If y(t) is a quantity depending on time t, “the rate of change is proportional to the amount present” translates to
\frac{dy}{dt} = ky
Here:
- y(t) is the amount at time t.
- k is a constant of proportionality.
- k>0 means growth.
- k
- Units: k has units of “per unit time” (for example, per year).
This differential equation is separable, so you can solve it with the method from the previous section.
Solving the exponential differential equation
Start with
\frac{dy}{dt} = ky
Separate variables:
\frac{1}{y}dy = kdt
Integrate:
\int \frac{1}{y}dy = \int kdt
\ln|y| = kt + C
Exponentiate:
|y| = e^{kt+C}
Rewrite e^C as a positive constant A:
|y| = Ae^{kt}
So
y = Ce^{kt}
where C can be any nonzero real constant. In most applied settings, y represents a positive amount, so you usually take C>0.
Why initial conditions matter in models
In modeling problems, you rarely want the whole family y=Ce^{kt}. You want the specific model that matches the initial amount:
If y(0)=y_0, then
y_0 = Ce^{0}
C=y_0
so
y(t) = y_0e^{kt}
This gives a clear interpretation: y_0 is the starting amount, and k controls how quickly it grows or decays.
Doubling time and half-life (how they connect)
Even when a problem doesn’t explicitly ask for k, you may be given a doubling time (growth) or half-life (decay). These come from solving for the time when the amount is multiplied by a factor.
If y(t)=y_0e^{kt}:
- Doubling time T_d satisfies 2y_0 = y_0e^{kT_d}, so
2 = e^{kT_d}
\ln 2 = kT_d
T_d = \frac{\ln 2}{k}
- Half-life T_{1/2} satisfies \frac{1}{2}y_0 = y_0e^{kT_{1/2}}, so
\frac{1}{2} = e^{kT_{1/2}}
\ln\left(\frac{1}{2}\right) = kT_{1/2}
T_{1/2} = \frac{\ln\left(\frac{1}{2}\right)}{k}
For decay, k