IB Maths AI HL
Differential Equations
Paper 1 & 2
~6 min read
Separation of Variables
Separation of variables solves a first-order differential equation when dydx splits into a function of x times a function of y. Get all the y‘s on one side, all the x‘s on the other, integrate both sides, and one constant of integration carries the whole family of solutions.
📘 What you need to know
- Recognise the form: dydx = g(x) h(y) — a function of x multiplied by a function of y.
- Separate: 1h(y) dy = g(x) dx, then integrate both sides.
- One constant: two integrals, but only one “+ c” is needed.
- g(x) may be a constant: dydx = 6y still separates, with g(x) = 6.
- Use the condition: a boundary/initial value fixes c.
- Watch the letters: exam variables may not be x and y; only rearrange to y = f(x) if asked.
When can you separate?
Separable first-order DE
dydx = g(x) h(y) ⟶ ∫ 1h(y) dy = ∫ g(x) dx
✓ separation method is on the AI HL syllabus
Separable
dydx = ex+4x3y2
Splits as (ex+4x) × 13y2 — a product of an x-part and a y-part.
Not separable
dydx = 4xy − 2ln x
A sum, not a product — it can’t be written as g(x)h(y), so use another method.
🤔 Why does “multiply dx across” work?
Treating dydx as a fraction isn’t strictly what’s happening — but it gives the right answer. Properly, you integrate 1h(y) dydx with respect to x, and the chain rule turns the left side into an integral in y. The shortcut “move dx over, integrate each side” lands in exactly the same place.
🧠 “Split, integrate, one + c, then fix it”
Split the variables, integrate both sides, add just one “+ c”, then fix c with the boundary condition. Rearrange to y = f(x) only if the question asks.
The five steps
🧭 Recipe — separation of variables
- Rearrange to 1h(y) dydx = g(x).
- Integrate both sides: ∫ 1h(y) dy = ∫ g(x) dx.
- Work out both integrals — include a single “+ c” for the general solution.
- Apply the condition to find c (skip if none given).
- Rearrange into the required form if asked.
Modulus from the log: ∫ 1y dy gives ln|y|. A boundary condition with y > 0 lets you drop the modulus when solving for y.
Worked examples
WE 1Solve dydx = ex + 4x3y2, giving y = f(x)
Separate the y2 across, then integrate each side.
3y² dydx = ex + 4x
∫ 3y² dy = ∫ (ex + 4x) dx
y³ = ex + 2x² + c
y = ∛(ex + 2x² + c)
WE 2Can dydx = 4xy − 2ln x be solved by separation? Explain.
Test whether the right side is a single product g(x)h(y).
4xy − 2ln x is a sum, not a product
No — it isn’t of the form g(x)h(y), so separation cannot be used
WE 3Solve dydx = 3y given y = 2 when x = 0, in the form y = f(x)
Here g(x) = 3 (a constant) and h(y) = y.
∫ 1y dy = ∫ 3 dx → ln|y| = 3x + c
y = 2, x = 0: ln 2 = c
y > 0, so y = e3x + ln 2 = e3x·eln 2
y = 2e3x
WE 4Find the general solution of dydx = 6y
Same shape as WE 3 with no condition, so leave the constant in.
∫ 1y dy = ∫ 6 dx → ln|y| = 6x + c
y = e6x + c = ec·e6x
y = A e6x (A = ec)
WE 5Solve dydx = xy given y = 1 when x = 0
Separable: g(x) = x, h(y) = y.
∫ 1y dy = ∫ x dx → ln|y| = x²2 + c
y = 1, x = 0: ln 1 = 0 → c = 0
y = ex²/2
💡 Top tips
- Check the form first — a product g(x)h(y) separates; a sum usually doesn’t.
- Only one “+ c“ across both integrals.
- Remember g(x) can be a constant — don’t dismiss dydx = ky.
- Drop the modulus carefully, justified by the condition’s sign.
- Match the letters in the question — they may not be x, y.
- Leave the form alone unless y = f(x) is requested.
⚠ Common mistakes
- Trying to separate a sum like 4xy − 2ln x.
- Writing two constants instead of one.
- Forgetting the modulus from ∫ 1y dy = ln|y|.
- Not using the condition to find c when one is given.
- Forcing y = f(x) when an implicit form is fine (or losing solutions in the algebra).
Next up — Modelling with Differential Equations. You can now solve a separable equation end to end. The next topic works the other way first: building the differential equation from a real-world context, where a “rate of change” proportional to some quantity becomes dPdt = kP — which you’ll then often solve by separation.
Need help with Differential Equations?
Get 1-on-1 help from an IB examiner who knows exactly what Paper 1 & 2 are looking for.
Book Free Session →