edusolum

📖 Unit 7: Differential Equations

Unit 7: Differential Equations

1. INTRODUCTION

Imagine you are a scientist tracking the spread of a new virus, an engineer designing a cooling system for a high-performance engine, or an economist predicting how a market reaches equilibrium. In all these scenarios, you aren't just looking at a static snapshot of data; you are looking at change.

In Calculus, we have spent a great deal of time learning how to find the derivative (the rate of change) of a function. However, in the real world, we often know the rate of change before we know the function itself. For example, we know that the rate at which a population grows is often proportional to the size of the population. This relationship is expressed as an equation involving a derivative, known as a Differential Equation.

Differential equations are the language of the universe. They describe how planets move, how heat flows, and how signals travel through our nerves. In this unit, we will explore how to model these real-world phenomena, how to visualize them using slope fields, and how to solve them analytically and numerically. By the end of this chapter, you will move from the basic definition of a differential equation to solving complex logistic growth models that represent the constraints of our physical world.


2. ALL KEY CONCEPTS, TERMS, FOUNDATIONAL KNOWLEDGE, and PRINCIPLES

To master differential equations, one must understand the following foundational terms and principles:

  1. Differential Equation (DE): An equation that contains an unknown function and one or more of its derivatives. Example: $\frac{dy}{dx} = 3x + y$.
  2. Order of a Differential Equation: The order of the highest-order derivative present in the equation. In AP Calculus, we primarily focus on first-order differential equations.
  3. Solution to a Differential Equation: A function $y = f(x)$ that satisfies the differential equation when $f(x)$ and its derivatives are substituted into the equation.
  4. General Solution: A solution that includes an arbitrary constant (usually $C$), representing a family of functions that satisfy the DE.
  5. Particular Solution: A specific solution derived from the general solution by using an Initial Condition (a specific point $(x_0, y_0)$ through which the function must pass).
  6. Initial Value Problem (IVP): A differential equation paired with an initial condition.
  7. Slope Field (Direction Field): A graphical representation of the slopes of a first-order DE at various points in the $xy$-plane. It consists of small line segments with slopes calculated from the DE.
  8. Separable Differential Equation: A first-order DE that can be written in the form $\frac{dy}{dx} = g(x)h(y)$, allowing all $y$ terms to be moved to one side and all $x$ terms to the other.
  9. Euler’s Method (BC Only): A numerical approach for approximating the solution of a differential equation by taking small "steps" along tangent lines.
  10. Exponential Growth/Decay: A model where the rate of change is directly proportional to the amount present: $\frac{dy}{dt} = ky$.
  11. Logistic Growth (BC Only): A model where growth is proportional to both the current amount and the remaining "room" for growth relative to a carrying capacity $L$: $\frac{dy}{dt} = ky(L - y)$.
  12. Carrying Capacity ($L$): The maximum population or value that an environment can sustain over time in a logistic model.

3. IN-DEPTH EXPLANATION of EVERY CONCEPT and PRINCIPLE

3.1 Verification and Modeling (Level 0-20)

At the most basic level, a differential equation is simply a statement about how a function changes.

Verification: To verify if $y = e^{2x}$ is a solution to $\frac{dy}{dx} = 2y$, we find the derivative: $$\frac{d}{dx}(e^{2x}) = 2e^{2x}$$ Substituting $y = e^{2x}$ into the right side: $2(e^{2x}) = 2e^{2x}$. Since the left side equals the right side, the function is a solution.

Modeling: Translating words to math is crucial.

  • "The rate of change of $y$ with respect to $x$ is proportional to $x^2$": $\frac{dy}{dx} = kx^2$.
  • "The rate of change of $Q$ with respect to $t$ is inversely proportional to $Q$": $\frac{dQ}{dt} = \frac{k}{Q}$.

3.2 Slope Fields (Level 21-40)

When we cannot solve a DE analytically, we visualize it. A Slope Field allows us to see the "flow" of the solutions. At any point $(x, y)$, the value of $\frac{dy}{dx}$ gives the slope of the solution curve passing through that point.

  • How to Draw: Choose a grid of points. At each point, calculate the value of the derivative and draw a short line segment with that slope.
  • Interpretation:
    • If $\frac{dy}{dx}$ depends only on $x$, all segments in a vertical column will be parallel.
    • If $\frac{dy}{dx}$ depends only on $y$, all segments in a horizontal row will be parallel.
    • If $\frac{dy}{dx} = 0$, the segment is horizontal (potential extrema).

3.3 Euler's Method (Level 41-60 - BC ONLY)

Euler's Method is the numerical version of following a slope field. Given an initial point $(x_0, y_0)$ and a step size $\Delta x = h$, we approximate the next point $(x_1, y_1)$ using the tangent line: $$x_{n+1} = x_n + h$$ $$y_{n+1} = y_n + f'(x_n, y_n) \cdot h$$ This process is repeated to march across the domain. Note that smaller step sizes generally lead to more accurate approximations, though the error accumulates.

3.4 Separation of Variables (Level 61-80)

This is the primary analytical method for solving DEs in AP Calculus. It applies to equations of the form: $$\frac{dy}{dx} = f(x)g(y)$$ Step-by-Step Process:

  1. Separate: Move all $y$ terms to the left and $x$ terms to the right: $\frac{1}{g(y)} dy = f(x) dx$.
  2. Integrate: Evaluate the integral on both sides: $\int \frac{1}{g(y)} dy = \int f(x) dx$.
  3. Constant of Integration: Don't forget $+ C$. This is usually added to the $x$ side.
  4. Solve for $y$: Use algebra to isolate $y$.
  5. Initial Condition: If a point $(x_0, y_0)$ is given, use it to find the specific value of $C$.

Important Note: You must separate variables before integrating. Integrating without separating (e.g., $\int \frac{dy}{dx} = \int (x+y) dx$) is a common error and will not yield a valid solution.

3.5 Growth Models: Exponential and Logistic (Level 81-100)

3.5.1 Exponential Growth

The equation $\frac{dy}{dt} = ky$ describes growth where the rate is proportional to the amount. Separating variables: $$\int \frac{1}{y} dy = \int k dt \implies \ln|y| = kt + C \implies y = e^{kt+C} \implies y = Ae^{kt}$$ Where $A = e^C$ is the initial amount at $t=0$.

3.5.2 Logistic Growth (BC ONLY)

In nature, populations cannot grow forever; they are limited by resources. This is modeled by: $$\frac{dy}{dt} = ky(L - y) \quad \text{or} \quad \frac{dy}{dt} = ky\left(1 - \frac{y}{L}\right)$$

  • Properties:
    • If $y < L$, $\frac{dy}{dt} > 0$ (growth).
    • If $y > L$, $\frac{dy}{dt} < 0$ (decay toward capacity).
    • The maximum rate of growth occurs at $y = \frac{L}{2}$.
    • $\lim_{t \to \infty} y(t) = L$.
  • The Solution: Using partial fraction decomposition to integrate $\int \frac{1}{y(L-y)} dy$, we find the general solution: $$y = \frac{L}{1 + be^{-Lkt}}$$ (Note: $b$ is a constant determined by the initial condition).

4. EXAMPLES

Example 1: Verification

Question: Verify that $y = C_1 \cos(x) + C_2 \sin(x)$ is a solution to $y'' + y = 0$. Solution:

  1. $y' = -C_1 \sin(x) + C_2 \cos(x)$
  2. $y'' = -C_1 \cos(x) - C_2 \sin(x)$
  3. Substitute into $y'' + y$: $(-C_1 \cos(x) - C_2 \sin(x)) + (C_1 \cos(x) + C_2 \sin(x)) = 0$. The identity $0=0$ holds.

Example 2: Modeling Newton's Law of Cooling

Question: The rate of change of temperature $T$ of an object is proportional to the difference between $T$ and the ambient temperature $T_a$. Write the DE. Solution: $$\frac{dT}{dt} = k(T - T_a)$$

Example 3: Slope Field Analysis

Question: For $\frac{dy}{dx} = x - y$, where are the slopes zero? Solution: Set $\frac{dy}{dx} = 0 \implies x - y = 0 \implies y = x$. Slopes are zero along the line $y=x$.

Example 4: Separable DE - Basic

Question: Solve $\frac{dy}{dx} = \frac{2x}{y}$. Solution:

  1. $y , dy = 2x , dx$
  2. $\int y , dy = \int 2x , dx$
  3. $\frac{y^2}{2} = x^2 + C$
  4. $y = \pm\sqrt{2x^2 + C}$

Example 5: Particular Solution (Initial Value Problem)

Question: Solve $\frac{dy}{dx} = (1+y^2)x$ given $y(0) = 1$. Solution:

  1. $\frac{1}{1+y^2} dy = x , dx$
  2. $\int \frac{1}{1+y^2} dy = \int x , dx \implies \arctan(y) = \frac{x^2}{2} + C$
  3. Use $(0, 1)$: $\arctan(1) = \frac{0^2}{2} + C \implies \frac{\pi}{4} = C$.
  4. $\arctan(y) = \frac{x^2}{2} + \frac{\pi}{4} \implies y = \tan\left(\frac{x^2}{2} + \frac{\pi}{4}\right)$.

Example 6: Euler’s Method (BC)

Question: Given $\frac{dy}{dx} = x + y$ and $y(0) = 1$, approximate $y(0.2)$ using two steps of size $h=0.1$. Solution:

$n$ $x_n$ $y_n$ $dy/dx = x+y$ $\Delta y = (dy/dx)h$
0 0 1 $0+1=1$ $1(0.1) = 0.1$
1 0.1 1.1 $0.1+1.1=1.2$ $1.2(0.1) = 0.12$
2 0.2 1.22

$y(0.2) \approx 1.22$.

Example 7: Exponential Decay (Radioactive Isotopes)

Question: A substance decays such that $\frac{dy}{dt} = -0.05y$. If $y(0) = 100$, find $y(10)$. Solution: The solution is $y(t) = 100e^{-0.05t}$. $y(10) = 100e^{-0.5} \approx 60.65$.

Example 8: Logistic Growth - Identify Parameters (BC)

Question: A population grows according to $\frac{dP}{dt} = 0.4P - 0.001P^2$. Find the carrying capacity. Solution: Rewrite as $\frac{dP}{dt} = 0.001P(400 - P)$. Comparing to $\frac{dP}{dt} = kP(L - P)$, $L = 400$.

Example 9: Logistic Growth - Max Rate (BC)

Question: In Example 8, at what population size is the growth rate maximum? Solution: Growth rate is maximum at $P = \frac{L}{2} = \frac{400}{2} = 200$.

Example 10: Separable DE with natural log

Question: Solve $\frac{dy}{dx} = \frac{y}{x}$ for $x > 0$. Solution: $\int \frac{1}{y} dy = \int \frac{1}{x} dx \implies \ln|y| = \ln|x| + C \implies |y| = e^{\ln|x|+C} = e^C |x|$. $y = kx$ (where $k = \pm e^C$).

Example 11: Finding C with Exponential terms

Question: Solve $\frac{dy}{dt} = y^2 e^t$ with $y(0) = 1$. Solution: $y^{-2} dy = e^t dt \implies -y^{-1} = e^t + C$. $-1 = e^0 + C \implies -1 = 1 + C \implies C = -2$. $-1/y = e^t - 2 \implies y = \frac{1}{2 - e^t}$.

Example 12: Slope Field - Horizontal and Vertical

Question: Describe the slope field of $\frac{dy}{dx} = \frac{x}{y}$. Solution:

  • Slopes are 0 when $x=0$ (the y-axis), except at origin.
  • Slopes are undefined when $y=0$ (the x-axis).
  • In Quadrant I ($x,y > 0$), slopes are positive.

Example 13: Solving for y in a complex fraction

Question: $\frac{dy}{dx} = \frac{x+1}{y}$. Find general solution. Solution: $y , dy = (x+1) dx \implies \frac{y^2}{2} = \frac{x^2}{2} + x + C \implies y^2 = x^2 + 2x + C_1 \implies y = \pm\sqrt{x^2 + 2x + C_1}$.

Example 14: Population Modeling (BC)

Question: A rumor spreads such that $\frac{dy}{dt} = 2y(1 - \frac{y}{1000})$. If $y(0) = 50$, find $\lim_{t \to \infty} y(t)$. Solution: This is a logistic equation with $L = 1000$. The limit as $t \to \infty$ is always the carrying capacity $L = 1000$.

Example 15: Solving $\frac{dy}{dx} = ky$ with initial condition

Question: $\frac{dy}{dx} = 3y, y(0) = 5$. Solution: $y = 5e^{3x}$.

Example 16: Non-separable recognition

Question: Is $\frac{dy}{dx} = x + y$ separable? Solution: No. You cannot write $x+y$ as a product of $f(x)$ and $g(y)$. (Requires other methods or slope fields).

Example 17: Euler's Method Error (BC)

Question: If $\frac{d^2y}{dx^2} > 0$, will Euler's method under- or over-estimate the solution? Solution: If $y'' > 0$, the function is concave up. The tangent line lies below the curve. Therefore, Euler's method will underestimate the solution.

Example 18: Integration with Substitution in DE

Question: $\frac{dy}{dx} = x\sqrt{1-y^2}$. Solution: $\int \frac{1}{\sqrt{1-y^2}} dy = \int x , dx \implies \arcsin(y) = \frac{x^2}{2} + C \implies y = \sin\left(\frac{x^2}{2} + C\right)$.

Example 19: Relative Growth Rate

Question: If $\frac{1}{y} \frac{dy}{dt} = 0.02$, describe the growth. Solution: This is $\frac{dy}{dt} = 0.02y$. It is exponential growth with a continuous growth rate of $2%$.

Example 20: Slope Field Matching

Question: Which DE matches a slope field where slopes are constant along the lines $y = -x + c$? Solution: A DE where $\frac{dy}{dx}$ depends on the sum $(x+y)$. For example, $\frac{dy}{dx} = x+y$.

Example 21: Separation with $\cos^2(y)$

Question: $\frac{dy}{dx} = \cos^2(y)$. Solution: $\sec^2(y) dy = dx \implies \tan(y) = x + C \implies y = \arctan(x + C)$.

Example 22: Newton's Law of Cooling - Solving

Question: $\frac{dT}{dt} = -0.1(T - 20)$, $T(0) = 80$. Find $T(t)$. Solution: $\int \frac{1}{T-20} dT = \int -0.1 dt \implies \ln|T-20| = -0.1t + C$. $T-20 = Ae^{-0.1t}$. At $t=0, 80-20=60 \implies A=60$. $T(t) = 20 + 60e^{-0.1t}$.

Example 23: Logistic Growth - Finding k (BC)

Question: $\frac{dy}{dt} = 0.2y(10 - y)$. Find the growth constant $k$ as defined in $\frac{dy}{dt} = ky(L-y)$. Solution: $k = 0.2$. Note: some textbooks use $\frac{dy}{dt} = r y (1 - y/L)$. In that form, $r = 0.2 \times 10 = 2$.

Example 24: Separation with $e^{x-y}$

Question: $\frac{dy}{dx} = e^{x-y}$. Solution: $\frac{dy}{dx} = \frac{e^x}{e^y} \implies e^y dy = e^x dx \implies e^y = e^x + C \implies y = \ln(e^x + C)$.

Example 25: Initial Condition with Ln

Question: $\frac{dy}{dx} = \frac{1}{x+2}, y(-1) = 0$. Solution: $y = \ln|x+2| + C \implies 0 = \ln|-1+2| + C \implies 0 = 0 + C \implies C=0$. $y = \ln(x+2)$ for $x > -2$.

Example 26: Domain of a Solution

Question: Given $\frac{dy}{dx} = y^2$, $y(0) = 1$. Find the domain of the particular solution. Solution: $\int y^{-2} dy = \int dx \implies -1/y = x + C$. $-1/1 = 0 + C \implies C = -1$. $-1/y = x - 1 \implies y = \frac{1}{1-x}$. The domain is $x < 1$ because the initial condition is at $x=0$.

Example 27: Point of Inflection in Logistic Growth (BC)

Question: $\frac{dP}{dt} = 3P - 0.01P^2$. Where does the inflection point occur? Solution: $L = \frac{3}{0.01} = 300$. Inflection occurs at $P = L/2 = 150$.

Example 28: Separation with Trigonometry

Question: $\frac{dy}{dx} = y \sin x, y(0) = e$. Solution: $\int \frac{1}{y} dy = \int \sin x , dx \implies \ln|y| = -\cos x + C$. $\ln(e) = -\cos(0) + C \implies 1 = -1 + C \implies C = 2$. $\ln y = 2 - \cos x \implies y = e^{2 - \cos x}$.

Example 29: Second Derivative from First-Order DE

Question: If $\frac{dy}{dx} = x^2 + y$, find $\frac{d^2y}{dx^2}$ at $(1, 2)$. Solution: $\frac{d^2y}{dx^2} = \frac{d}{dx}(x^2 + y) = 2x + \frac{dy}{dx}$. At $(1, 2)$, $\frac{dy}{dx} = 1^2 + 2 = 3$. $\frac{d^2y}{dx^2} = 2(1) + 3 = 5$.

Example 30: Euler's Method - Negative Step (BC)

Question: $y(1) = 5, \frac{dy}{dx} = 2x$. Approximate $y(0)$ with $h = -0.5$. Solution:

  1. $x_0=1, y_0=5, f'=2(1)=2. \Delta y = 2(-0.5) = -1$.
  2. $x_1=0.5, y_1=4, f'=2(0.5)=1. \Delta y = 1(-0.5) = -0.5$.
  3. $x_2=0, y_2=3.5$. $y(0) \approx 3.5$.

Example 31: Logistic Differential Equation with Partial Fractions (BC)

Question: Solve $\frac{dy}{dt} = y(1-y)$. Solution: $\int \frac{1}{y(1-y)} dy = \int dt \implies \int (\frac{1}{y} + \frac{1}{1-y}) dy = t + C$. $\ln|y| - \ln|1-y| = t + C \implies \ln|\frac{y}{1-y}| = t + C$. $\frac{y}{1-y} = Ae^t$. Solving for $y$ gives $y = \frac{Ae^t}{1+Ae^t} = \frac{1}{1+Ce^{-t}}$.

Example 32: Analyzing $dy/dx = x^2 + y^2$

Question: Can this be solved via separation of variables? Solution: No. $x^2 + y^2$ cannot be factored into $f(x)g(y)$. We must use numerical methods or slope fields.

Example 33: Slope Field and Limits

Question: For $\frac{dy}{dx} = \sin(x)$, what is the behavior of $y$ as $x \to \infty$? Solution: $y = \int \sin x dx = -\cos x + C$. The function oscillates and does not approach a single limit.

Example 34: Logistic Growth - Rate at Carrying Capacity (BC)

Question: What is $\frac{dy}{dt}$ when $y = L$? Solution: $\frac{dy}{dt} = k(L)(L - L) = 0$. The population stops growing.

Example 35: The All-Important $+C$

Question: Solve $\frac{dy}{dx} = \frac{1}{x}$ with $y(1) = 3$. Solution: $y = \ln|x| + C \implies 3 = \ln(1) + C \implies C = 3$. $y = \ln|x| + 3$. For $x>0$, $y = \ln(x) + 3$.

Certificate terms & implications

Course Mastery Certificates require an active Unlimited subscription at the time of generation and 100% course completion. They recognise learning content completion only — not an accredited qualification, licence, or professional credential unless explicitly stated. edusolum may modify eligibility, design, and issuance requirements per its Terms of Service.