IB Maths AA HLTopic 5 — CalculusPaper 1 & 2HL~11 min read
Integrating Factor
For first-order DEs in standard form dy/dx + P(x)y = Q(x) (linear in y), multiply both sides by μ = e∫P(x)dx. The LHS then collapses into the exact derivative d/dx(μy), and one integration finishes the job. The standard form, and the IF formula, are both in your formula booklet.
📘 What you need to know
Standard form: dy/dx + P(x) y = Q(x). Must have a plus P(x)y term and dy/dx with coefficient 1 — rearrange if needed.
Integrating factor (formula booklet): μ(x) = e∫P(x) dx. No +c needed in this integral.
Multiply through by μ. The LHS automatically becomes d/dx(μy) — this is the whole point of the IF.
Integrate both sides: μy = ∫μ Q(x) dx + c. Then divide by μ to isolate y.
P(x) and Q(x) can be constants — e.g., in dy/dx + 3y = 1, both are. The method still works.
P(x) = k/x gives μ = xk (because ek ln x = xk) — a very common IB pattern.
P(x) = tan x gives μ = sec x; P(x) = cot x gives μ = sin x. Useful trig IFs.
Apply IC after integrating to find c. Don’t apply it earlier — c only appears once you’ve integrated.
How the integrating factor works
Integrating factor — formula booklet
Standard form: dydx + P(x) y = Q(x) ⟹ μ(x) = e∫P(x) dx
Why does this work? Because the LHS of dy/dx + Py = Q, when multiplied by μ, becomes μ·dy/dx + μ·P·y. The product rule tells us that’s exactly d/dx(μy) — but only when μ′ = P·μ, which the formula μ = e∫P dx guarantees.
The “collapse” in Step 3 is automatic — once you multiply by the right μ, the LHS μ·dy/dx + μ·P·y is, by construction, the product-rule expansion of d/dx(μy). No verification needed — that’s why μ = e∫P dx is chosen.
Common P(x) patterns and their IFs
P(x)
∫P(x) dx
μ = e∫P dx
constant k
kx
ekx
k/x
k ln \|x\|
xk
2x
x²
ex²
tan x
−ln \|cos x\|
sec x
cot x
ln \|sin x\|
sin x
The two most common IB patterns: P(x) = constant (gives exponential IF) and P(x) = k/x (gives power IF). If you see either, you can write down μ immediately without integrating from scratch.
🧭 Recipe — solving with the integrating factor
Rearrange to standard form: dy/dx + P(x) y = Q(x). Divide through if dy/dx has a coefficient other than 1.
Identify P(x) and Q(x), then compute μ(x) = e∫P dx. No +c in this step.
Multiply both sides by μ. The LHS now equals d/dx(μy) — write this directly, no checking needed.
Integrate both sides: μy = ∫ μ·Q(x) dx + c. Use Further Integration techniques on the RHS as required.
Divide by μ to get y = (1/μ) [∫ μ Q dx + c]. Apply IC if given, then rearrange.
Worked examples
WE 1
Rearrange to standard form, identify P(x) and Q(x)
The differential equation x dy/dx − y = x² is to be solved by the integrating factor method. Rearrange to standard form and state P(x), Q(x), and the integrating factor μ(x).
Step 1 — divide through by x to make dy/dx coefficient 1x dy/dx – y = x²dy/dx – (1/x) y = xStep 2 — read off P(x) and Q(x)P(x) = -1/x, Q(x) = xStep 3 — compute the IF∫ P(x) dx = ∫ -1/x dx = -ln|x|μ(x) = e^(-ln|x|) = 1/|x| (use 1/x for x > 0)Standard form: dy/dx − (1/x)y = x; μ(x) = 1/xalways divide by the dy/dx coefficient FIRST. Forgetting this is the #1 cause of wrong IFs. Once in standard form, P(x) is whatever multiplies y on the LHS (sign included!).
WE 2
Constant P — exponential IF
Find the general solution of dy/dx + 3y = ex.
Step 1 — already in standard form. P(x) = 3, Q(x) = e^xStep 2 — find the IFμ = e^∫3 dx = e^(3x)Step 3 — multiply through; LHS collapsesd/dx (y e^(3x)) = e^(3x) · e^x = e^(4x)Step 4 — integratey e^(3x) = ∫ e^(4x) dx = e^(4x)/4 + CStep 5 — divide by μ to isolate yy = e^x / 4 + C e^(-3x)y = eˣ4 + Ce⁻³ˣverify: dy/dx + 3y = (e^x/4 – 3Ce^(-3x)) + 3(e^x/4 + Ce^(-3x)) = e^x/4 + 3e^x/4 = e^x ✓. The “Ce^(-3x)” piece is the general homogeneous solution; “e^x/4” is the particular solution.
WE 3
With initial condition — constant P and Q
Solve dy/dx + 2y = 4 given y(0) = 5.
Step 1 — standard form. P = 2, Q = 4Step 2 — IFμ = e^(2x)Step 3 — collapse LHS, write exact derivatived/dx (y e^(2x)) = 4 e^(2x)Step 4 — integratey e^(2x) = ∫ 4 e^(2x) dx = 2 e^(2x) + Cy = 2 + C e^(-2x)Step 5 — apply IC y(0) = 55 = 2 + C · 1 ⟹ C = 3y = 2 + 3e⁻²ˣnotice the structure: as x → ∞, y → 2 (the “steady-state”); the 3e^(-2x) is the transient decaying from the IC. Common pattern when Q is constant.
WE 4
P(x) = 1/x — power IF
Find the general solution of x dy/dx + y = x³.
Step 1 — divide through by xdy/dx + (1/x) y = x²; P = 1/x, Q = x²Step 2 — IF∫ 1/x dx = ln|x|μ = e^(ln|x|) = x (for x > 0)Step 3 — multiply by μ = xx dy/dx + y = x³ ← original form! (this happens when IF cancels the divide-by-x step)d/dx (x y) = x³Step 4 — integratexy = ∫ x³ dx = x⁴/4 + CStep 5 — divide by xy = x³/4 + C/xy = x³4 + Cxa beautiful shortcut: when P(x) = 1/x, the IF brings you right back to the original equation in d/dx(xy) form. Recognize this and you can sometimes skip the multiplication step.
WE 5
P(x) = -2/x with initial condition
Solve x dy/dx − 2y = x⁴ given y(1) = 1.
Step 1 — divide through by xdy/dx – (2/x) y = x³; P = -2/x, Q = x³Step 2 — IF∫ -2/x dx = -2 ln|x|μ = e^(-2 ln|x|) = x^(-2) = 1/x²Step 3 — multiply by μ = 1/x²(1/x²) dy/dx – (2/x³) y = xd/dx (y/x²) = xStep 4 — integratey/x² = ∫ x dx = x²/2 + Cy = x⁴/2 + C x²Step 5 — apply IC y(1) = 11 = 1/2 + C ⟹ C = 1/2y = x⁴/2 + x²/2 = x²(x² + 1)/2y = x²(x² + 1)2the IF for P = k/x is μ = x^k. Here k = -2, so μ = x^(-2) = 1/x². The minus sign matters — check carefully when you have negative P.
WE 6
Trig IF — P(x) = tan x
Solve dy/dx + (tan x) y = sec x given y(0) = 1.
Step 1 — standard form. P(x) = tan x, Q(x) = sec xStep 2 — find the IF∫ tan x dx = -ln|cos x|μ = e^(-ln|cos x|) = 1/|cos x| = sec x (cos x > 0 near x = 0)Step 3 — multiply by μ = sec xsec x · dy/dx + sec x · tan x · y = sec²xd/dx (y sec x) = sec²xStep 4 — integrate (∫ sec²x dx = tan x)y sec x = tan x + CStep 5 — divide by sec xy = tan x / sec x + C / sec x = sin x + C cos xStep 6 — apply IC y(0) = 11 = sin 0 + C cos 0 = 0 + C ⟹ C = 1y = sin x + cos xverify: dy/dx + (tan x) y = (cos x – sin x) + tan x (sin x + cos x) = cos x – sin x + sin²x/cos x + sin x = cos x + sin²x/cos x = (cos²x + sin²x)/cos x = 1/cos x = sec x ✓. The trig IFs (sec x for tan x, sin x for cot x) are worth memorizing.
💡 Top tips
Get to standard form FIRST. Always divide so dy/dx has coefficient 1. Skipping this step gives the wrong P, and therefore the wrong μ.
No +c in the IF. The integral inside μ doesn’t need a constant — any constant just gets absorbed later anyway.
LHS automatically collapses. After multiplying by the correct μ, the LHS IS d/dx(μy) — don’t waste time verifying by differentiating.
Apply IC at the end. The +c appears only after the integration step; substituting (x₀, y₀) earlier is meaningless.
Memorize common IFs: P = k → ekx; P = k/x → xk; P = tan x → sec x; P = cot x → sin x.
⚠ Common mistakes
Wrong sign on P: in x dy/dx − y = x², P(x) = −1/x (NEGATIVE). Forgetting the minus gives μ = x instead of 1/x — and a wrong answer.
Forgetting to divide by the coefficient: in x dy/dx + 2y = …, P is NOT 2; you must first divide by x to get P = 2/x.
Adding +c inside the IF integral: that’s not needed and clutters the algebra. Only one +c, at the final integration.
Re-differentiating to “verify” the LHS collapse: by construction, after multiplying by the correct μ, the LHS IS d/dx(μy). Wasted effort.
Algebra error in dividing by μ at the end: when isolating y, distribute carefully — every term, including +c, gets divided.
Up next: Modelling with Differential Equations. You’ll set up DEs from real-world contexts — “the rate of change of P is proportional to …” translates directly into a DE. Then you’ll use one of the techniques (separation, IF, etc.) to solve. Examples: population growth, Newton’s law of cooling, radioactive decay, fluid mixing.
Need help with Calculus?
Get 1-on-1 help from an IB examiner who knows exactly what Paper 1 & 2 are looking for.