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.
Before you solve
Ideas in this lesson
Idea 1 of 3
Standard linear form
Divide first to obtain y′+P(x)y=Q(x). The integrating factor is exp(∫Pdx).
Worked example 1
Choose an integrating factor for y′+2y=x. - P(x)=2
- ∫P(x)dx=2x
- μ(x)=exp(∫Pdx)=e2x
Answer: e2x
Worked example 2
Choose an integrating factor for y′+(x3)y=1(x>0). - P(x)=x3
- ∫P(x)dx=3lnx
- μ(x)=exp(∫Pdx)=x3
Answer: x3
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)=1. Find y(0). - μ(x)=ex; (exy)′=2ex
- y=2+ Ce −x; y(0)=1⟹C=−1
- y(0)=1
Answer: 1
Worked example 2
Solve y′+y=3,y(0)=2. Find y(1). - μ(x)=ex; (exy)′=3ex
- y=3+ Ce −x; y(0)=2⟹C=−1
- y(1)=3+e−1=3+e−1≈2.63
Answer: 3+e−1≈2.63
Idea 3 of 3
Long-term behavior
Inspect the explicit solution as x grows. A decaying transient can leave a nonzero equilibrium.
Worked example 1
Solve y′+y=2,y(0)=1. Find y(0). - μ(x)=ex; (exy)′=2ex
- y=2+ Ce −x; y(0)=1⟹C=−1
- y(0)=1
Answer: 1
Worked example 2
Solve y′+y=3,y(0)=2. Find y(1). - μ(x)=ex; (exy)′=3ex
- y=3+ Ce −x; y(0)=2⟹C=−1
- y(1)=3+e−1=3+e−1≈2.63
Answer: 3+e−1≈2.63
Resource alignment: Larson & Edwards, Calculus of a Single Variable, Tenth Edition, §6.4,p. 424. Explanations, diagrams and numerical practice variants are original MathLab content aligned to this section.