📌 AP Calc AB Unit 7 — Differential Equations6–12% of exam · Slope fields & solution curves · Separation of variables (4-step AP protocol) · Initial value problems & particular solutions · Exponential growth & decay dy/dt = ky
Unit 7 bridges rate relationships to unknown dynamical states. We explore the qualitative geometric architecture of first-order differential equations through slope fields, master the 4-step separation of variables protocol mandatory on the AP Free Response section, and derive exponential growth and decay models.
A slope field visualizes the family of tangent line segments corresponding to dy/dx = f(x, y). Particular solutions are individual flow lines passing through a given initial condition.
Slope field for fraction dy over dx = x - ydxdy=x−y showing zero-slope isocline along y = xy=x and the particular solution passing through \((0, 1)\).Autonomous differential equation \(\frac{dy}{dx} = 0.5y\): slopes depend solely on \(y\) (constant across horizontal rows) with equilibrium \(y = 0\).
A first-order ordinary differential equation is an equation of the form: \[ \frac{dy}{dx} = f(x, y) \] A function \(y = g(x)\) is a solution on an interval \(I\) if \(g'(x) = f(x, g(x))\) for all \(x \in I\).
Slope Fields (Direction Fields): At each grid point \((x_i, y_j)\), a short line segment is drawn with slope equal to \(f(x_i, y_j)\). Key visual diagnostics:
Isoclines: Curves along which the slope is constant: \(f(x, y) = c\).
Horizontal segments: Points where \(f(x, y) = 0\) (potential relative extrema of solution curves).
Vertical / Undefined segments: Points where \(f(x, y)\) is undefined or has a zero denominator (potential vertical asymptotes or boundaries of the domain).
Purely x-dependent (\(\frac{dy}{dx} = f(x)\)): Slopes are identical along any vertical column.
Purely y-dependent (\(\frac{dy}{dx} = f(y)\)): Slopes are identical along any horizontal row.
⊙ Explorer · Slope fields & solution curves
interactive
Grid point coordinates, instantaneous slopes \(\frac{dy}{dx}\), and solution trajectory
Grid Point \((x, y)\)
Instantaneous \(\frac{dy}{dx}\)
Tangent Segment Orientation
Solution Status
Initial point \((0, y_{0})\)\((0.0, 1.0)\)
Solution \(y(1)\)\(0.736\)
Slant Asymptote\(y = x - 1\)
The solution curve follows the flow of the tangent field. For \(\frac{dy}{dx} = x -y\) with \(y(0) = y_{0}\), the analytical solution is \(y(x) = x -1 + (y_{0} + 1)e^{-x}\).
◆ Why It Works — Chain Rule Justification for Separation of Variables
Why Separating \(dy\) and \(dx\) Is Rigorous: If \(\frac{dy}{dx} = f(x)g(y)\) with \(g(y) \neq 0\), dividing by \(g(y)\) and integrating both sides with respect to \(x\) gives \[ \int \frac{1}{g(y(x))} y'(x)\,dx = \int f(x)\,dx \] By substitution \(u = y(x), du = y'(x)\,dx\), the left side equals \(\int \frac{1}{g(y)}\,dy\), validating separation of variables.
Level 1 (Foundations) — Worked Example · Slope Field Construction & Solution Verification
Problem. Consider the differential equation \(\frac{dy}{dx} = x(y - 2)\).
▸ Show step-by-step solution
Determine the slopes at the six points: \((0, 3)\), \((1, 2)\), \((1, 3)\), \((2, 1)\), \((-1, 4)\), and \((-2, 2)\).
Verify that \(y(x) = 2 + C e^{x^2/2}\) is a solution for any constant \(C\).
Find the particular solution satisfying \(y(0) = 5\).
Solution:
Calculate \(\frac{dy}{dx} = x(y - 2)\) at each point:
Differentiate \(y(x) = 2 + Ce^{x^2/2}\): \[ \frac{dy}{dx} = \frac{d}{dx}\left[ 2 + C e^{x^2/2} \right] = C e^{x^2/2} \cdot \frac{d}{dx}\left(\frac{x^2}{2}\right) = C e^{x^2/2} \cdot x = x\left(C e^{x^2/2}\right) \] Now evaluate the right-hand side \(x(y - 2)\): \[ x(y - 2) = x\left( (2 + Ce^{x^2/2}) - 2 \right) = x(C e^{x^2/2}) \] Since \(\frac{dy}{dx} = x(y - 2)\) identically for all \(x\), \(y(x) = 2 + C e^{x^2/2}\) is verified. \(\blacksquare\)
Substitute initial condition \(x = 0, y = 5\): \[ 5 = 2 + C e^0 = 2 + C \implies C = 3 \] Particular solution is \(y(x) = 2 + 3e^{x^2/2}\).
Worked Example \(B\) — Unit 7 · Differential Equations (Hard Application)
Problem. A differentiable function \( y = f(x) \) satisfies the differential equation \( \frac{dy}{dx} = 3x - 2 \). If \( f(1) = 5 \), what is the value of \( f(3) \)?
▸ Show step-by-step solution
The given differential equation is \( \frac{dy}{dx} = 3x - 2 \). To find \( f(x) \), we need to integrate \( \frac{dy}{dx} \) with respect to \( x \). \( y = f(x) = \int (3x - 2) \, dx \). \( f(x) = \frac{3}{2}x^2 - 2x + C \), where \( C \) is the constant of integration. We are given that \( f(1) = 5 \). Substituting \( x=1 \) into the equation for \( f(x) \): \( 5 = \frac{3}{2}(1)^2 - 2(1) + C \). \( 5 = \frac{3}{2} - 2 + C \). \( 5 = \frac{3}{2} - \frac{4}{2} + C \). \( 5 = -\frac{1}{2} + C \). \( C = 5 + \frac{1}{2} = \frac{10}{2} + \frac{1}{2} = \frac{11}{2} \). So, the function is \( f(x) = \frac{3}{2}x^2 - 2x + \frac{11}{2} \). Now we need to find \( f(3) \). \( f(3) = \frac{3}{2}(3)^2 - 2(3) + \frac{11}{2} \). \( f(3) = \frac{3}{2}(9) - 6 + \frac{11}{2} \). \( f(3) = \frac{27}{2} - \frac{12}{2} + \frac{11}{2} \). \( f(3) = \frac{27 - 12 + 11}{2} = \frac{15 + 11}{2} = \frac{26}{2} = 13 \).
⚠️ Common Exam Traps — Unit 7 · Differential Equations
1. Adding \(+C\) Only After Exponentiating in Separable ODEs: In \(\dfrac{dy}{dx} = 5xy\), integrating gives \(\ln|y| = \tfrac{5}{2}x^2 + C \implies y = Ae^{5x^2/2}\) where \(A = \pm e^C\). Writing \(y = e^{5x^2/2} + C\) is a fatal algebraic error that forfeits all follow-up marks on College Board AP Calculus AB.
2. Forgetting to Transform Limits in \(u\)-Substitution: In definite integrals \(\int_a^b f(g(x))g'(x)\,dx\), you must replace the limits \(x = a, b\) with \(u = g(a), g(b)\) immediately.
Error Diagnosis — Common Student Traps vs. Exam-Board Method (Unit 7 · Differential Equations)
Common Student Trap
Why It Fails Mathematically
Correct Exam-Board Method
Writing \(\ln|y| = x^2 + C \implies y = e^{x^2} + C\)
Exponentiation distributes over addition as multiplication (\(e^{a+b} = e^a e^b\)), not addition.
Write \(y = e^{x^2 + C} = Ae^{x^2}\) and solve for \(A\) using the initial condition.
Leaving original \(x\)-limits on a \(u\)-substituted definite integral
Evaluates the antiderivative \(F(u)\) at \(x\)-values instead of \(u(x)\)-values.
Convert bounds immediately: \(u_{\text{low}} = u(a)\) and \(u_{\text{high}} = u(b)\).
Computing total distance as \(\left|\int_{t_1}^{t_2} v(t)\,dt\right|\)
Cancels forward and backward motion (net displacement) instead of accumulating total path length.
Split the integral at every root where \(v(t) = 0\) and integrate \(|v(t)|\).
Quick Verification Trick (College Board AP Calculus AB): For any indefinite integral \(\int f(x)\,dx = F(x) + C\), differentiate your answer \(F'(x)\) mentally—especially the coefficient \(1/k\) from chain-rule reversal \(\int e^{kx}\,dx = \tfrac{1}{k}e^{kx} + C\)—before moving on.
Level 1 · Foundations
Which of the following functions is a solution to the differential equation \(y'' + 4y = 0\)? (A) \(y = e^{2x}\) (B) \(y = \sin(2x) - 3\cos(2x)\) (C) \(y = 4\cos(4x)\) (D) \(y = x^2 - 4\)
💡 Hint 1 of 3
Test (B): \(y = \sin(2x) - 3\cos(2x)\).
💡 Hint 2 of 3
First derivative: \(y' = 2\cos(2x) + 6\sin(2x)\) Second derivative: \(y'' = -4\sin(2x) + 12\cos(2x) = -4\left(\sin(2x) - 3\cos(2x)\right) = -4y\) Substitute into the differential equation: \(y'' + 4y = -4y + 4y = 0\).
💡 Hint 3 of 3
The equation is satisfied identically. Correct answer is the final result.
Test (B): \(y = \sin(2x) - 3\cos(2x)\). First derivative: \[ y' = 2\cos(2x) + 6\sin(2x) \] Second derivative: \[ y'' = -4\sin(2x) + 12\cos(2x) = -4\left(\sin(2x) - 3\cos(2x)\right) = -4y \] Substitute into the differential equation: \[ y'' + 4y = -4y + 4y = 0 \] The equation is satisfied identically. Correct answer is (B).
Level 2 · Medium — Separation of Variables (4-Step AP FRQ Protocol)
Separation of variables is the premier analytical technique tested on AP Calculus Free Response Questions. Rigorous execution follows an exact 4-step grading protocol.
● The 4-Step Separation of Variables AP Scoring Standard
Step 1 · Algebraic Separation: Rewrite \(\frac{dy}{dx} = f(x)g(y)\) so that all \(y\)-terms are with \(dy\) and all \(x\)-terms with \(dx\): \[ \frac{1}{g(y)}\,dy = f(x)\,dx \] Scoring Rule: If you do not separate variables, you receive 0 out of 5 (or 6) points on the entire problem.
Step 2 · Antidifferentiation & Integration Constant: Integrate both sides independently and write \(+C\) immediately: \[ \int \frac{1}{g(y)}\,dy = \int f(x)\,dx + C \] Scoring Rule: Forgetting \(+C\) at the moment of integration forfeits all remaining points.
Step 3 · Initial Condition Evaluation: Substitute \((x_0, y_0)\) immediately to solve for the exact numerical value of \(C\).
Step 4 · Explicit Function & Domain Restriction: Isolate \(y\) explicitly as a function of \(x\): \(y = h(x)\). If a square root arises (\(y^2 = \dots\)), select the positive or negative branch that matches the initial condition \(y_0\). Ensure the solution's domain is an open interval containing \(x_0\) where \(y\) is differentiable.
Level 2 (Medium) — Worked Example · Classical AP FRQ Particular Solution
Problem. Find the particular solution \(y = f(x)\) to the differential equation \(\frac{dy}{dx} = \frac{2x + 1}{y^2}\) with initial condition \(f(1) = 3\), and state its domain.
Step 2 · Integrate both sides: \[ \int y^2\,dy = \int (2x + 1)\,dx \implies \frac{y^3}{3} = x^2 + x + C_1 \] Multiply by 3: \[ y^3 = 3x^2 + 3x + C \quad (\text{where } C = 3C_1) \]
Step 3 · Apply Initial Condition \(x = 1, y = 3\): \[ (3)^3 = 3(1)^2 + 3(1) + C \implies 27 = 3 + 3 + C = 6 + C \implies C = 21 \]
Step 4 · Solve explicitly for \(y\): \[ y^3 = 3x^2 + 3x + 21 \implies \mathbf{y = \sqrt[3]{3x^2 + 3x + 21}} \] Domain: The cube root is defined for all real numbers. Since the discriminant of \(3x^2 + 3x + 21\) is \(b^2 - 4ac = 9 - 4(3)(21) = 9 - 252 = -243 < 0\), the radicand is strictly positive for all \(x\). Thus \(y \neq 0\) everywhere, and \(\frac{dy}{dx}\) exists for all \(x\). Domain is \((-\infty, \infty)\).
Level 2 · Medium
Find the particular solution to the differential equation \(\frac{dy}{dx} = \frac{x}{y}\) with initial condition \(y(0) = -4\). State the domain of the solution.
Differential equations where the rate of change is proportional to the quantity present lead to exponential models. We derive the analytical solution and apply it to radioactive decay and Newton's Law of Cooling.
● Theorem & Proof: Exponential Law of Natural Growth and Decay
Theorem: The only solutions to the differential equation: \[ \frac{dy}{dt} = ky \] are the exponential functions: \[ y(t) = y_0 e^{kt} \] where \(y_0 = y(0)\) is the initial value at \(t = 0\), and \(k\) is the growth constant (\(k > 0\)) or decay constant (\(k < 0\)).
Proof via Separation of Variables: For \(y \neq 0\): \[ \frac{1}{y}\,dy = k\,dt \] Integrate both sides: \[ \int \frac{1}{y}\,dy = \int k\,dt \implies \ln|y| = kt + C_1 \] Exponentiating both sides: \[ |y| = e^{kt + C_1} = e^{C_1}e^{kt} \implies y(t) = \pm e^{C_1} e^{kt} \] Let \(A = \pm e^{C_1}\). When \(t = 0\): \(y(0) = A e^0 = A\). Setting \(A = y_0\) yields: \[ y(t) = y_0 e^{kt}. \quad \blacksquare \]
Half-Life Formula: In radioactive decay (\(k < 0\)), the half-life \(t_{1/2}\) is the time required for \(y(t) = \frac{1}{2}y_0\): \[ \frac{1}{2}y_0 = y_0 e^{k t_{1/2}} \implies e^{k t_{1/2}} = \frac{1}{2} \implies k t_{1/2} = \ln\left(\frac{1}{2}\right) = -\ln 2 \implies \mathbf{t_{1/2} = -\frac{\ln 2}{k} = \frac{\ln 2}{|k|}} \]
Level 3 (Advanced / FRQ) — Worked Example · Newton's Law of Cooling
Problem. A freshly brewed pot of coffee at temperature \(95^\circ\text{C}\) cools in a room kept at constant ambient temperature \(T_{\text{env}} = 20^\circ\text{C}\). Newton's Law of Cooling states: \[ \frac{dT}{dt} = -k(T - 20) \] After 10 minutes, the coffee temperature drops to \(70^\circ\text{C}\). Find the temperature after 25 minutes, and find when the coffee reaches a drinking temperature of \(50^\circ\text{C}\).
A population of bacteria grows at a rate proportional to its size: \(\frac{dP}{dt} = kP\). At \(t = 2\text{ hours}\), the population is 400. At \(t = 6\text{ hours}\), the population is 1600. What was the initial population \(P(0)\), and what is the doubling time?
💡 Hint 1 of 3
General solution: \(P(t) = P_0 e^{kt}\).
💡 Hint 2 of 3
From given data: \(P(2) = P_0 e^{2k} = 400\) \(P(6) = P_0 e^{6k}\).
💡 Hint 3 of 3
To find \(P_0\): \(P_0 e^{2k} = P_0 (2) = 400\).
General solution: \(P(t) = P_0 e^{kt}\). From given data: \[ P(2) = P_0 e^{2k} = 400 \] \[ P(6) = P_0 e^{6k} = 1600 \] Divide the two equations: \[ \frac{P_0 e^{6k}}{P_0 e^{2k}} = \frac{1600}{400} \implies e^{4k} = 4 \implies e^{2k} = \sqrt{4} = 2 \] Since \(e^{2k} = 2\), the population doubles every 2 hours: Doubling time is 2 hours. To find \(P_0\): \[ P_0 e^{2k} = P_0 (2) = 400 \implies \mathbf{P_0 = 200}. \]
[Practice 4 · Easy] The slope field for a differential equation is shown above. The differential equation is of the form \( \frac{dy}{dx} = ky \) for some constant \( k \). If the solution curve passes through the point \( (0, 1) \) and \( (1, 2) \), find the value of \( k \).
💡 Hint 1 of 3
The differential equation is given by \( \frac{dy}{dx} = ky \). This is a separable differential equation. We can rewrite it as \( \frac{dy}{y} = k \, dx \). Integrating both sides, we get \( \int \frac{dy}{y} = \int k \, dx \), which yields \( \ln|y| = kx + C_1 \). Exponentiating both sides, we have \( |y| = e^{kx + C_1} = e^{C_1} e^{kx} \). Let \( C = \pm e^{C_1} \), so \( y = Ce^{kx} \).
💡 Hint 2 of 3
We are given that the solution curve passes through the point \( (0, 1) \). Substituting these values into the general solution: \( 1 = Ce^{k(0)} \) \( 1 = C e^0 \).
💡 Hint 3 of 3
Therefore, the value of \(k\) is \(\ln 2\).
The differential equation is given by \( \frac{dy}{dx} = ky \). This is a separable differential equation. We can rewrite it as \( \frac{dy}{y} = k \, dx \). Integrating both sides, we get \( \int \frac{dy}{y} = \int k \, dx \), which yields \( \ln|y| = kx + C_1 \). Exponentiating both sides, we have \( |y| = e^{kx + C_1} = e^{C_1} e^{kx} \). Let \( C = \pm e^{C_1} \), so \( y = Ce^{kx} \).
We are given that the solution curve passes through the point \( (0, 1) \). Substituting these values into the general solution:
\( 1 = Ce^{k(0)} \)
\( 1 = C e^0 \)
\( 1 = C \cdot 1 \)
\( C = 1 \).
So the particular solution is \( y = e^{kx} \).
We are also given that the solution curve passes through the point \( (1, 2) \). Substituting these values into the particular solution:
\( 2 = e^{k(1)} \)
\( 2 = e^k \).
To solve for \( k \), we take the natural logarithm of both sides:
\( \ln 2 = \ln(e^k) \)
\( \ln 2 = k \).
Therefore, the value of \( k \) is \( \ln 2 \).
Evaluate the definite integral of the constant function: \( \int_{8}^{11} 21 \, dx \).
💡 Hint 1 of 3
The antiderivative is \( 21x \).
💡 Hint 2 of 3
Evaluating from \( 8 \) to \( 11 \) gives. Set up the numerical expression: \(21(11 - 8)\).
💡 Hint 3 of 3
Evaluate \(21(11 - 8)\) step by step to obtain the final answer.
The antiderivative is \( 21x \). Evaluating from \( 8 \) to \( 11 \) gives \( 21(11 - 8) = 63 \).
Sampled points and slopes along the solution curve passing through \((x_0, y_0)\).
\(x\)
\(y(x)\) (RK4)
Slope \(f(x, y)\)
Active ODEdy/dx = x − y
Initial point & slope(0.00, 1.00) | slope m₀ = −1.000
Qualitative behaviorApproaches linear asymptote y = x − 1 as x → ∞
RK4 vs. Euler at \(x_0 + 1\)—
Click or drag anywhere on the slope field to move \((x_0, y_0)\) in real time, and double-click to pin multiple family curves for side-by-side comparison. Decrease step \(h\) to watch the dashed teal Euler approximation converge to the amber solution curve.
Unit 7 · Differential Equations — 9-Point 4-Part FRQ
9 pts
No Calculator
In solar array output differential model #64, consider the separable differential equation \(\dfrac{dy}{dx} = 4xy\) whose slope field is shown, with particular solution \(y = f(x)\) satisfying \(f(0) = 2\).
(a)2 pts
Evaluate the slope field segment slope \(\dfrac{dy}{dx}\) at the lattice point \((1, 2)\).
Scoring Guideline & Justification
[M1]Substitutes x = 1, y = 2 into 4xy(1 pt)
[A1]Evaluates slope = 8(1 pt)
(b)2 pts
Find the second derivative \(\dfrac{d^2y}{dx^2}\) evaluated at \((0, 2)\).
Scoring Guideline & Justification
[M1]Differentiates dy/dx implicitly by product rule(1 pt)
[A1]Obtains 8(1 pt)
(c)3 pts
Solve the separable equation with \(f(0) = 2\) to find \(\ln\!\left(\dfrac{f(1)}{2}\right)\).
Scoring Guideline & Justification
[M1]Separates variables: (1/y) dy = 4x dx(1 pt)
[M1]Antidifferentiates: ln|y| = 2x^2 + C(1 pt)
[A1]Evaluates ln(f(1)/2) = 2(1 pt)
(d)2 pts
Use the tangent line at \((0, 2)\) to approximate \(f(0.5)\).
Scoring Guideline & Justification
[M1]Finds dy/dx|_(0,2) = 0(1 pt)
[A1]Tangent approximation yields 2(1 pt)
Complete Worked Solution
(a) \(4(1)(2) = 8\). (b) \(y'' = 4y + 4xy'\), so at \((0,2)\), \(y'' = 8\). (c) \(\ln|y| = 2x^2 + \ln 2\), hence \(\ln(f(1)/2) = 2\). (d) Since \(f'(0) = 0\), the tangent line is \(y = 2\), giving \(f(0.5) \approx 2\).