MathLab with Mr. Ahmed

MathLab with Mr. Ahmed is a math learning website by Ahmed Amasha, a mathematics teacher teaching the American curriculum. Explore Algebra 2, Precalculus, Calculus, and SAT and PSAT Math Prep through lessons, focused practice and printable resources.

MathLabwith Mr. Ahmed
Differential Equations

6.4 First-Order Linear Differential Equations

Focus on standard linear form, solve an initial-value problem, long-term behavior.

Free preview Explore the lesson before creating an account.

Play games for this section

Before you solve

Ideas in this lesson

Idea 1 of 3

Standard linear form

Divide first to obtain y′+P(x)y=Q(x)y' + P(x)y = Q(x). The integrating factor is exp⁡(∫Pdx)\exp (\int P dx).

Worked example 1

Choose an integrating factor for y′+2y=xy' + 2y = x.
  1. P(x)=2P(x) = 2
  2. ∫P(x)dx=2x\int P(x) dx = 2x
  3. μ(x)=exp⁡(∫Pdx)=e2x\mu (x) = \exp (\int P dx) = e^{2x}

Answer: e2xe^{2x}

Worked example 2

Choose an integrating factor for y′+(3x)y=1(x>0)y' + (\dfrac{3}{x})y = 1 (x > 0).
  1. P(x)=3xP(x) = \dfrac{3}{x}
  2. ∫P(x)dx=3ln⁡x\int P(x) dx = 3 \ln x
  3. μ(x)=exp⁡(∫Pdx)=x3\mu (x) = \exp (\int P dx) = x^{3}

Answer: x3x^{3}

Idea 2 of 3

Solve an initial-value problem

Multiplying by the integrating factor makes the left side a product derivative. Integrate, then determine the constant.

Worked example 1

Solve y′+y=2,y(0)=1y' + y = 2, y(0) = 1. Find y(0)y(0).
  1. μ(x)=ex\mu (x) = e^{x}; (exy)′=2ex(e^{x}y)' = 2e^{x}
  2. y=2+y = 2 + Ce −x^{-x}; y(0)=1  ⟹  C=−1y(0) = 1 \implies C = -1
  3. y(0)=1y(0) = 1

Answer: 11

Worked example 2

Solve y′+y=3,y(0)=2y' + y = 3, y(0) = 2. Find y(1)y(1).
  1. μ(x)=ex\mu (x) = e^{x}; (exy)′=3ex(e^{x}y)' = 3e^{x}
  2. y=3+y = 3 + Ce −x^{-x}; y(0)=2  ⟹  C=−1y(0) = 2 \implies C = -1
  3. y(1)=3+−1e=3+−1e≈2.63y(1) = 3 + \dfrac{-1}{e} = 3 + \dfrac{-1}{e} \approx 2.63

Answer: 3+−1e≈2.633 + \dfrac{-1}{e} \approx 2.63

Idea 3 of 3

Long-term behavior

Inspect the explicit solution as xx grows. A decaying transient can leave a nonzero equilibrium.

Worked example 1

Solve y′+y=2,y(0)=1y' + y = 2, y(0) = 1. Find y(0)y(0).
  1. μ(x)=ex\mu (x) = e^{x}; (exy)′=2ex(e^{x}y)' = 2e^{x}
  2. y=2+y = 2 + Ce −x^{-x}; y(0)=1  ⟹  C=−1y(0) = 1 \implies C = -1
  3. y(0)=1y(0) = 1

Answer: 11

Worked example 2

Solve y′+y=3,y(0)=2y' + y = 3, y(0) = 2. Find y(1)y(1).
  1. μ(x)=ex\mu (x) = e^{x}; (exy)′=3ex(e^{x}y)' = 3e^{x}
  2. y=3+y = 3 + Ce −x^{-x}; y(0)=2  ⟹  C=−1y(0) = 2 \implies C = -1
  3. y(1)=3+−1e=3+−1e≈2.63y(1) = 3 + \dfrac{-1}{e} = 3 + \dfrac{-1}{e} \approx 2.63

Answer: 3+−1e≈2.633 + \dfrac{-1}{e} \approx 2.63

Resource alignment: Larson & Edwards, Calculus of a Single Variable, Tenth Edition, §6.4,p6.4, p. 424424. Explanations, diagrams and numerical practice variants are original MathLab content aligned to this section.