First-order equations · Definition
Integrating factor
Before you start you need to know
It is the key to the general method for linear equations: it turns a problem with no obvious shortcut into a direct integration.
Definition
An integrating factor is a function \(\mu\) that, when multiplied by a first-order linear equation with coefficient \(p\), turns the left side into the derivative of a product.
Start from the standard form \(y'+p(x)\,y=q(x)\). If we multiply by \(\mu\) and require \(\mu'=p\mu\), the product rule gives \((\mu y)'=\mu y'+\mu' y=\mu(y'+py)\). The equation becomes \((\mu y)'=\mu q\), which is solved by integrating: \(y=\frac{1}{\mu}\left(\int \mu q\,dx+C\right)\).
The condition \(\mu'=p\mu\) is separable and its positive solution is \(\mu=e^{\int p\,dx}\). Which antiderivative of \(p\) you take does not matter: another constant only multiplies \(\mu\) by a number, which cancels on both sides. That is why the constant is dropped in the first integral and kept only in the second.
Guiding example: in \(y'+2y=e^{-x}\) the coefficient is \(p=2\), so \(\mu=e^{2x}\). Multiplying gives \((e^{2x}y)'=e^{x}\), then \(e^{2x}y=e^{x}+C\) and \(y=e^{-x}+Ce^{-2x}\). An initial condition fixes the value of \(C\).
Typical mistakes: applying the formula without first putting the equation in standard form (for \(xy'+2y=x^2\), divide by \(x\) first so \(p=2/x\)), flipping the sign of \(p\), or forgetting that solving for \(y\) also divides the constant by \(\mu\). If \(p=0\), then \(\mu=1\) and there is nothing to do.
Think about it
What integrating factor does \(y'-\dfrac{2}{x}\,y=x\) have for \(x>0\)?
Here \(p=-2/x\), so \(\mu=e^{-2\ln x}=x^{-2}\). Multiplying gives \((y/x^2)'=1/x\), hence \(y=x^2(\ln x+C)\).
Why does the method not work as is for \(y'+y^2=x\)?
Because the equation is not linear: the property \(\mu'=p\mu\) relies on the \(y\) term being \(p(x)\,y\), first power.
Exercises 10
- Find an integrating factor of \(y'+2y=x\).
- For \(x>0\), find an integrating factor of \(y'+\dfrac{1}{x}\,y=x^2\).
- Find an integrating factor of \(y'+3x^2y=x^2\).
- Write \(y'=y+e^{2x}\) in standard form and find an integrating factor.
- With \(\mu=e^{x}\), the equation \(y'+y=x\) becomes \((e^{x}y)'=xe^{x}\). What is its general solution?
- Solve \(y'+2y=e^{-x}\).
- For \(x>0\), solve \(xy'+2y=x^2\).
- Solve \(y'+2y=4\) with \(y(0)=3\).
- On \((-\pi/2,\pi/2)\), which is an integrating factor of \(y'+(\tan x)\,y=1\)?
- When computing \(\int p\,dx\) for the integrating factor, the constant of integration is dropped. Why is that allowed?
What comes next
References
- William E. Boyce, Richard C. DiPrima, Douglas B. Meade, Elementary Differential Equations and Boundary Value Problems, 12th edition, Wiley, 2021. §2.1
- Dennis G. Zill, A First Course in Differential Equations with Modeling Applications, 11th edition, Cengage, 2018. §2.3