MathIsimple
ODE-01
Course 1

Introduction and Elementary Methods

Master the fundamentals of ordinary differential equations, including basic concepts, direction fields, separable equations, and homogeneous equations with applications to population dynamics.

Learning Objectives
  • Define ordinary differential equations and classify by order and linearity
  • Interpret direction fields and identify equilibrium solutions
  • Solve separable differential equations using integration
  • Recognize and solve homogeneous equations via substitution
  • Apply ODEs to model population dynamics and epidemics
  • Distinguish between general solutions, particular solutions, and singular solutions
  • Formulate initial value problems and verify solutions
  • Understand the geometric meaning of isoclines

1. Basic Concepts

Differential equations are equations that relate a function to its derivatives. They appear throughout science and engineering, modeling everything from population growth to planetary motion. We begin by distinguishing between two major types.

Definition 1.1: Ordinary Differential Equation (ODE)

An ordinary differential equation is an equation involving an unknown function x(t)x(t) of a single independent variable tt and one or more of its derivatives. The general form is:

F(t,x,dxdt,d2xdt2,,dnxdtn)=0F\left(t, x, \frac{dx}{dt}, \frac{d^2x}{dt^2}, \ldots, \frac{d^nx}{dt^n}\right) = 0

In contrast, a partial differential equation (PDE) involves partial derivatives with respect to multiple independent variables.

Example 1.1: ODE vs PDE

ODEs:

  • dxdt=kx\frac{dx}{dt} = kx (exponential growth/decay)
  • d2xdt2+ω2x=0\frac{d^2x}{dt^2} + \omega^2 x = 0 (simple harmonic motion)
  • dxdt=rx(1x/K)\frac{dx}{dt} = rx(1-x/K) (logistic equation)

PDEs:

  • ut=k2ux2\frac{\partial u}{\partial t} = k\frac{\partial^2 u}{\partial x^2} (heat equation)
  • 2ux2+2uy2=0\frac{\partial^2 u}{\partial x^2} + \frac{\partial^2 u}{\partial y^2} = 0 (Laplace's equation)

Definition 1.2: Order of a Differential Equation

The order of a differential equation is the highest order derivative that appears in the equation. A first-order ODE involves only dxdt\frac{dx}{dt}, a second-order ODE involves d2xdt2\frac{d^2x}{dt^2}, and so on.

Definition 1.3: Linear and Nonlinear ODEs

An nnth-order ODE is linear if it can be written in the form:

an(t)dnxdtn+an1(t)dn1xdtn1++a1(t)dxdt+a0(t)x=f(t)a_n(t)\frac{d^nx}{dt^n} + a_{n-1}(t)\frac{d^{n-1}x}{dt^{n-1}} + \cdots + a_1(t)\frac{dx}{dt} + a_0(t)x = f(t)

where the coefficients ai(t)a_i(t) and forcing term f(t)f(t) depend only on tt, not on xx or its derivatives. Otherwise, the ODE is nonlinear.

Example 1.2: Linear vs Nonlinear

Linear ODEs:

  • x+3x+2x=sintx'' + 3x' + 2x = \sin t (second-order linear)
  • x+p(t)x=q(t)x' + p(t)x = q(t) (first-order linear)

Nonlinear ODEs:

  • x=x2x' = x^2 (nonlinear in xx)
  • x+sinx=0x'' + \sin x = 0 (nonlinear due to sinx\sin x)
  • xx=tx' \cdot x'' = t (nonlinear in derivatives)

Definition 1.4: Solution Types

A solution to an ODE on an interval II is a function x=ϕ(t)x = \phi(t) that satisfies the equation for all tIt \in I.

  • General solution: Contains arbitrary constants (as many as the order of the ODE)
  • Particular solution: A specific solution obtained by assigning values to the constants
  • Singular solution: A solution that cannot be obtained from the general solution

Definition 1.5: Initial Value Problem (IVP)

An initial value problem (or Cauchy problem) consists of a differential equation together with initial conditions that specify the value of the solution and its derivatives at a specific point:

{dxdt=f(t,x)x(t0)=x0\begin{cases} \frac{dx}{dt} = f(t, x) \\ x(t_0) = x_0 \end{cases}

For higher-order equations, additional initial conditions are needed for the derivatives.

2. Direction Fields and Geometric Interpretation

Before solving ODEs analytically, we can gain valuable insight through geometric visualization. For a first-order equation dxdt=f(t,x)\frac{dx}{dt} = f(t, x), the function f(t,x)f(t, x) gives the slope of the solution curve at each point (t,x)(t, x).

Definition 2.1: Direction Field (Slope Field)

A direction field for the equation dxdt=f(t,x)\frac{dx}{dt} = f(t, x) is a collection of short line segments drawn at points (t,x)(t, x) in the plane, where each segment has slope f(t,x)f(t, x). Solution curves are tangent to these segments at every point.

Definition 2.2: Isocline

An isocline is a curve in the (t,x)(t, x)-plane along which the slope f(t,x)f(t, x) is constant. For a slope value mm, the isocline is the set of points satisfying:

f(t,x)=mf(t, x) = m

The nullcline (zero isocline) is where f(t,x)=0f(t, x) = 0, corresponding to horizontal tangent lines. Points on the nullcline may be equilibrium solutions.

Example 2.1: Direction Field Analysis

Consider the logistic equation dxdt=x(1x)\frac{dx}{dt} = x(1-x).

Nullcline analysis: Setting x(1x)=0x(1-x) = 0 gives x=0x = 0 and x=1x = 1.

  • For 0<x<10 < x < 1: x(1x)>0x(1-x) > 0, so slopes are positive (solutions increase)
  • For x<0x < 0 or x>1x > 1: x(1x)<0x(1-x) < 0, so slopes are negative (solutions decrease)

This tells us that x=0x = 0 is an unstable equilibrium (solutions move away) and x=1x = 1 is a stable equilibrium (solutions approach it).

Remark:

Direction fields are especially useful when analytical solutions are difficult or impossible to find. They provide qualitative information about solution behavior: where solutions increase/decrease, equilibria, and asymptotic behavior.

3. Separable Equations

The simplest first-order ODEs to solve are separable equations, where the variables can be completely separated to opposite sides of the equation.

Definition 3.1: Separable Equation

A first-order ODE is separable if it can be written in the form:

dxdt=f(t)g(x)\frac{dx}{dt} = f(t) \cdot g(x)

where the right-hand side is a product of a function of tt alone and a function of xx alone.

Algorithm 3.1: Solving Separable Equations

Input: Separable equation dxdt=f(t)g(x)\frac{dx}{dt} = f(t)g(x)

Output: General solution x(t)x(t)

1. Separate variables: Write dxg(x)=f(t)dt\frac{dx}{g(x)} = f(t)\,dt

2. Integrate both sides: 1g(x)dx=f(t)dt+C\int \frac{1}{g(x)}\,dx = \int f(t)\,dt + C

3. Solve for x: If possible, express xx explicitly as a function of tt

4. Check for singular solutions: Points where g(x)=0g(x) = 0 may give additional solutions

Example 3.1: Basic Separable Equation

Solve: dxdt=tx\frac{dx}{dt} = tx

Solution:

Step 1: Separate variables (assuming x0x \neq 0):

dxx=tdt\frac{dx}{x} = t\,dt

Step 2: Integrate both sides:

dxx=tdt    lnx=t22+C\int \frac{dx}{x} = \int t\,dt \implies \ln|x| = \frac{t^2}{2} + C

Step 3: Solve for xx:

x=et2/2+C=eCet2/2    x=Aet2/2|x| = e^{t^2/2 + C} = e^C \cdot e^{t^2/2} \implies x = Ae^{t^2/2}

where A=±eCA = \pm e^C is an arbitrary constant. Note that x=0x = 0 (when A=0A = 0) is also a solution.

Example 3.2: Separable Equation with IVP

Solve the IVP: dxdt=tx\frac{dx}{dt} = \frac{t}{x}, x(0)=2x(0) = 2

Solution:

Separating: xdx=tdtx\,dx = t\,dt

Integrating:

x22=t22+C    x2=t2+2C\frac{x^2}{2} = \frac{t^2}{2} + C \implies x^2 = t^2 + 2C

Using initial condition x(0)=2x(0) = 2:

4=0+2C    C=24 = 0 + 2C \implies C = 2

Therefore:

x2=t2+4    x=t2+4x^2 = t^2 + 4 \implies x = \sqrt{t^2 + 4}

(taking positive root since x(0)=2>0x(0) = 2 > 0)

Theorem 3.1: Existence of Solutions for Separable Equations

For the separable equation dxdt=f(t)g(x)\frac{dx}{dt} = f(t)g(x), if ff is continuous on an interval containing t0t_0 and gg is continuous on an interval containing x0x_0 with g(x0)0g(x_0) \neq 0, then the IVP with x(t0)=x0x(t_0) = x_0 has a unique solution in some neighborhood of t0t_0.

Example 3.3: Singular Solutions

Solve: dxdt=x2/3\frac{dx}{dt} = x^{2/3}

Solution:

For x0x \neq 0, separating and integrating:

x2/3dx=dt    3x1/3=t+C\int x^{-2/3}\,dx = \int dt \implies 3x^{1/3} = t + C
x=(t+C3)3x = \left(\frac{t + C}{3}\right)^3

However, x=0x = 0 is also a solution (singular solution).

Important: The IVP with x(0)=0x(0) = 0 has infinitely many solutions! This shows uniqueness can fail when g(x0)=0g(x_0) = 0.

4. Homogeneous Equations

Another important class of first-order ODEs are homogeneous equations, which can be transformed into separable equations through an appropriate substitution.

Definition 4.1: Homogeneous Function

A function F(t,x)F(t, x) is homogeneous of degree nn if for all λ>0\lambda > 0:

F(λt,λx)=λnF(t,x)F(\lambda t, \lambda x) = \lambda^n F(t, x)

Example 4.1: Homogeneous Functions

  • F(t,x)=t2+x2F(t,x) = t^2 + x^2 is homogeneous of degree 2: (λt)2+(λx)2=λ2(t2+x2)(\lambda t)^2 + (\lambda x)^2 = \lambda^2(t^2 + x^2)
  • F(t,x)=xtF(t,x) = \frac{x}{t} is homogeneous of degree 0: λxλt=xt\frac{\lambda x}{\lambda t} = \frac{x}{t}
  • F(t,x)=t+x2F(t,x) = t + x^2 is not homogeneous

Definition 4.2: Homogeneous First-Order ODE

A first-order ODE dxdt=F(t,x)\frac{dx}{dt} = F(t, x) is homogeneous if F(t,x)F(t, x) is homogeneous of degree 0. Equivalently, the equation can be written as:

dxdt=G(xt)\frac{dx}{dt} = G\left(\frac{x}{t}\right)

for some function GG.

Algorithm 4.1: Solving Homogeneous Equations

Input: Homogeneous equation dxdt=G(x/t)\frac{dx}{dt} = G(x/t)

Output: General solution x(t)x(t)

1. Substitute: Let u=x/tu = x/t, so x=utx = ut

2. Differentiate: dxdt=u+tdudt\frac{dx}{dt} = u + t\frac{du}{dt}

3. Transform equation: u+tdudt=G(u)u + t\frac{du}{dt} = G(u)

4. Separate: duG(u)u=dtt\frac{du}{G(u) - u} = \frac{dt}{t}

5. Integrate both sides

6. Back-substitute: Replace uu with x/tx/t

Example 4.2: Solving a Homogeneous Equation

Solve: dxdt=t+xt\frac{dx}{dt} = \frac{t + x}{t}

Solution:

First verify it's homogeneous: t+xt=1+xt=G(x/t)\frac{t+x}{t} = 1 + \frac{x}{t} = G(x/t)

Let u=x/tu = x/t, so x=utx = ut and dxdt=u+tdudt\frac{dx}{dt} = u + t\frac{du}{dt}.

Substituting:

u+tdudt=1+u    tdudt=1u + t\frac{du}{dt} = 1 + u \implies t\frac{du}{dt} = 1

This is now separable:

du=dtt    u=lnt+Cdu = \frac{dt}{t} \implies u = \ln|t| + C

Back-substituting u=x/tu = x/t:

xt=lnt+C    x=tlnt+Ct\frac{x}{t} = \ln|t| + C \implies x = t\ln|t| + Ct

Example 4.3: More Complex Homogeneous Equation

Solve: dxdt=x2+t22tx\frac{dx}{dt} = \frac{x^2 + t^2}{2tx}

Solution:

Check homogeneity: x2+t22tx=(x/t)2+12(x/t)=u2+12u\frac{x^2 + t^2}{2tx} = \frac{(x/t)^2 + 1}{2(x/t)} = \frac{u^2 + 1}{2u} where u=x/tu = x/t. ✓

With x=utx = ut:

u+tdudt=u2+12uu + t\frac{du}{dt} = \frac{u^2 + 1}{2u}
tdudt=u2+12uu=u2+12u22u=1u22ut\frac{du}{dt} = \frac{u^2 + 1}{2u} - u = \frac{u^2 + 1 - 2u^2}{2u} = \frac{1 - u^2}{2u}

Separating:

2udu1u2=dtt\frac{2u\,du}{1 - u^2} = \frac{dt}{t}

Integrating (LHS with substitution v=1u2v = 1 - u^2):

ln1u2=lnt+C1    1u2=Ct-\ln|1 - u^2| = \ln|t| + C_1 \implies |1 - u^2| = \frac{C}{|t|}

Back-substituting and simplifying:

1x2t2=Ct    t2x2=Ct1 - \frac{x^2}{t^2} = \frac{C}{t} \implies t^2 - x^2 = Ct
Remark:

Homogeneous equations of the form M(t,x)dt+N(t,x)dx=0M(t,x)\,dt + N(t,x)\,dx = 0 where both MM and NN are homogeneous of the same degree can be solved similarly. The substitution x=utx = ut (or t=vxt = vx) always works.

5. Applications: Population Models

Differential equations are powerful tools for modeling real-world phenomena. We examine several population models that lead to separable equations.

5.1 Exponential Growth/Decay (Malthusian Model)

The simplest population model assumes the rate of change is proportional to the current population:

dNdt=rN\frac{dN}{dt} = rN

where rr is the intrinsic growth rate. This separable equation has solution:

N(t)=N0ertN(t) = N_0 e^{rt}

For r>0r > 0: exponential growth. For r<0r < 0: exponential decay.

5.2 Logistic Growth

The logistic model accounts for limited resources by introducing a carrying capacity KK:

dNdt=rN(1NK)\frac{dN}{dt} = rN\left(1 - \frac{N}{K}\right)

Example 5.1: Solving the Logistic Equation

This is a separable equation. Using partial fractions:

dNN(1N/K)=rdt\frac{dN}{N(1 - N/K)} = r\,dt
1N(1N/K)=1N+1/K1N/K=1N+1KN\frac{1}{N(1-N/K)} = \frac{1}{N} + \frac{1/K}{1-N/K} = \frac{1}{N} + \frac{1}{K-N}

Integrating:

lnNlnKN=rt+C\ln|N| - \ln|K-N| = rt + C
lnNKN=rt+C\ln\left|\frac{N}{K-N}\right| = rt + C

Solving for NN with initial condition N(0)=N0N(0) = N_0:

N(t)=K1+(KN01)ertN(t) = \frac{K}{1 + \left(\frac{K}{N_0} - 1\right)e^{-rt}}

Key properties:

  • N(t)KN(t) \to K as tt \to \infty
  • S-shaped (sigmoid) growth curve
  • Maximum growth rate at N=K/2N = K/2

5.3 Epidemic Models

Definition 5.1: SI Model

In the SI (Susceptible-Infected) model, let i(t)i(t) be the fraction of infected individuals. The model assumes that infected individuals meet susceptibles at a rate proportional to both populations:

didt=λi(1i)\frac{di}{dt} = \lambda i(1-i)

where lambda\\lambda is the contact rate. This is mathematically identical to the logistic equation with K=1K = 1.

Example 5.2: SI Model Solution

With initial infection fraction i0i_0, the solution is:

i(t)=11+(1i01)eλti(t) = \frac{1}{1 + \left(\frac{1}{i_0} - 1\right)e^{-\lambda t}}

For example, if i0=0.01i_0 = 0.01 and lambda=0.5\\lambda = 0.5, then i(t)1i(t) \to 1 as tt \to \infty, meaning eventually everyone gets infected.

Definition 5.2: SIS Model

In the SIS model, infected individuals can recover and become susceptible again:

didt=λi(1i)γi=i(λ(1i)γ)\frac{di}{dt} = \lambda i(1-i) - \gamma i = i(\lambda(1-i) - \gamma)

where gamma\\gamma is the recovery rate.

Theorem 5.1: SIS Epidemic Threshold

For the SIS model, define the basic reproduction number R0=λ/γR_0 = \lambda/\gamma.

  • If R0<1R_0 < 1: The infection dies out (i(t)0i(t) \to 0)
  • If R0>1R_0 > 1: The infection persists at endemic level i=11/R0i^* = 1 - 1/R_0
Note:

The basic reproduction number R0R_0 represents the average number of secondary infections caused by one infected individual in a fully susceptible population. It is a key concept in epidemiology.

Practice Quiz: Introduction and Elementary Methods
10
Questions
0
Correct
0%
Accuracy
1
Which of the following is an ordinary differential equation?
Easy
Not attempted
2
What is the order of the differential equation x+3x+2x=sintx'' + 3x' + 2x = \sin t?
Easy
Not attempted
3
Which equation is separable?
Easy
Not attempted
4
For the separable equation dxdt=tx\frac{dx}{dt} = \frac{t}{x}, what is the general solution?
Medium
Not attempted
5
The equation dxdt=x+tt\frac{dx}{dt} = \frac{x + t}{t} is homogeneous. What substitution should be used?
Medium
Not attempted
6
In the direction field of dxdt=x(1x)\frac{dx}{dt} = x(1-x), at what values of xx are the slopes zero?
Medium
Not attempted
7
What is the solution to the IVP dxdt=2x\frac{dx}{dt} = 2x, x(0)=3x(0) = 3?
Medium
Not attempted
8
For the logistic equation dxdt=rx(1x/K)\frac{dx}{dt} = rx(1 - x/K), what is the equilibrium solution with x>0x > 0?
Hard
Not attempted
9
The function F(t,x)=t2+x2txF(t,x) = \frac{t^2 + x^2}{tx} is homogeneous of degree:
Hard
Not attempted
10
In the SI epidemic model with infection rate λ\lambda, if i(0)=0.01i(0) = 0.01 and i(t)1i(t) \to 1 as tt \to \infty, the equation is:
Hard
Not attempted

Frequently Asked Questions

What is the difference between an ODE and a PDE?

An ordinary differential equation (ODE) involves derivatives with respect to only one independent variable (usually time tt). A partial differential equation (PDE) involves partial derivatives with respect to multiple independent variables (like time and space). For example, dxdt=x\frac{dx}{dt} = x is an ODE, while ut=2ux2\frac{\partial u}{\partial t} = \frac{\partial^2 u}{\partial x^2} is a PDE.

How do I know if an equation is separable?

An equation is separable if you can write it as dxdt=f(t)g(x)\frac{dx}{dt} = f(t) \cdot g(x), where the right side is a product of a function of tt only and a function of xx only. Try to factor the right-hand side this way. For instance, dxdt=t2x\frac{dx}{dt} = t^2 x is separable (f(t)=t2f(t) = t^2, g(x)=xg(x) = x), but dxdt=t+x\frac{dx}{dt} = t + x is not.

What is a direction field used for?

A direction field (or slope field) provides a geometric visualization of an ODE's behavior without solving it. By drawing short line segments with slopes given by f(t,x)f(t,x) at various points, you can sketch solution curves, identify equilibria, and understand qualitative behavior (where solutions increase, decrease, or approach certain values). This is especially useful for equations that cannot be solved analytically.

What happens when the separation method fails?

When separating variables, if g(x)=0g(x) = 0 for some xx, you cannot divide by g(x)g(x). However, such values often correspond to constant solutions (equilibrium solutions). You should always check these cases separately. Additionally, some solutions found by separation may need domain restrictions (e.g., x=0x = 0 excluded), and singular solutions may exist that don't appear in the general solution.

Why do we use the substitution u = x/t for homogeneous equations?

For a homogeneous equation dxdt=F(t,x)\frac{dx}{dt} = F(t,x) where FF is degree 0, the right side depends only on the ratio x/tx/t. The substitution u=x/tu = x/t exploits this structure, transforming the equation into a separable equation in uu and tt. This works because F(t,x)=F(1,x/t)=G(u)F(t,x) = F(1, x/t) = G(u) for some function GG, reducing the problem to one we can solve.

What is the biological meaning of the logistic equation?

The logistic equation dNdt=rN(1N/K)\frac{dN}{dt} = rN(1-N/K) models population growth with limited resources. The parameter rr is the intrinsic growth rate (how fast the population would grow with unlimited resources), and KK is the carrying capacity (maximum sustainable population). When NN is small, growth is nearly exponential; as NN approaches KK, growth slows and eventually stops. The factor (1N/K)(1-N/K) represents competition for limited resources.