IB Maths AI HLModelling with FunctionsPaper 1 & 2Slope, intercept, applications~8 min read
Linear Models
A linear model y = mx + c describes any real-world quantity that changes at a constant rate: hire fees, depreciation, conversion scales, anything with a fixed starting value plus a steady per-unit change.
📘 What you need to know
Standard form: y = mx + c, where m is the slope and c is the y-intercept.
Slope m = rate of change of y per unit x; in context it carries units (e.g. £/MB, $/km).
Intercept c = value of y when x = 0; in context it’s the fixed/starting amount.
From two points (x1, y1) and (x2, y2): m = (y2 − y1)/(x2 − x1), then solve for c.
Positive m ⇒ growth/increase; negative m ⇒ depreciation/decrease.
Real models have a restricted domain (e.g. t ≥ 0); extrapolation past it gives unrealistic values.
The linear model and what its parameters mean
Every linear model has two numbers doing two jobs. The slope m says how much y changes for every one-unit increase in x — if the units of x are km and y is in $, then m is in $/km. The intercept c is the value of y when x = 0 — usually the starting amount, the fixed fee, or the initial reading. Naming both in context is what examiners reward; “the slope is 0.18” gets one mark, “the cost increases by $0.18 for each extra km” gets two.
Building a model from data
Given two data points (x1, y1) and (x2, y2), compute the slope first using the rise-over-run formula, then substitute either point back into y = mx + c to find c. Always finish by checking the second point satisfies your equation — that catches sign and arithmetic slips. If the data already gives you the value at x = 0 (e.g. “the initial cost is …”), that’s c for free.
Both lines have the same y-intercept c; the slope’s sign decides whether the model grows or decays.
Linear model at a glancey = mx + cm = y2 − y1x2 − x1 · intercept c = y when x = 0
Using the model: predict, invert, compare
Three jobs come up repeatedly. Predict: substitute an x value to get the y (e.g. the cost of 800 MB). Invert: substitute the target y and solve for x (e.g. how much data for a £45 bill). Compare two models: set them equal and solve for the break-even x, then test a value on either side to see which is cheaper. All three are one-line GDC tasks but the algebra is fast enough by hand.
Watch the units. If x is in MB but the question gives GB, convert first. A unit slip turns 800 MB into 0.8 MB and the answer becomes nonsense.
🧠Recipe — building & using a linear model
Identify the variables and their units; decide which is x (input) and which is y (output).
Find the slopem = Δy/Δx from two given points, or read it directly if a rate is stated.
Find the interceptc: either substitute a point into y = mx + c, or read it off if the initial value is given.
Write the modely = mx + c with the variable names from the question.
Apply: substitute for prediction, rearrange for inversion, or set models equal for break-even.
Worked examples
WE 1
Write a linear model and interpret
A car-hire company charges a fixed booking fee of $35 plus $0.18 for each kilometre driven. Let C($) be the total cost for k km. (a) Write down C(k). (b) State the slope and intercept in context.
(a) form C = mk + cm = 0.18 ($/km), c = 35 ($)C(k) = 0.18k + 35(b) interpret in contextslope: cost increases by $0.18 for each additional km. intercept: $35 fixed booking fee (paid even with 0 km driven).
WE 2
Linear model from two data points
A print shop charges £85 for 50 flyers and £190 for 200 flyers. Assuming a linear pricing model, write C(n) for n flyers.
slope m = ΔC / Δnm = (190 − 85) / (200 − 50)= 105 / 150 = 0.7 £/flyerintercept: sub (50, 85)85 = 0.7(50) + c ⇒ 85 = 35 + cc = 50check (200, 190): 0.7(200) + 50 = 190 ✓C(n) = 0.7n + 50£50 fixed setup, then 70p per flyer.
WE 3
Predict and invert
A mobile phone plan has monthly bill M(d) = 0.06d + 12, where d is data used (MB). (a) Find M(800). (b) Find d if the bill is £45.
(a) substitute d = 800M = 0.06(800) + 12 = 48 + 12 = 60M(800) = £60(b) set M = 45 and solve45 = 0.06d + 12 ⇒ 33 = 0.06dd = 33 / 0.06 = 550d = 550 MB
WE 4
Linear scientific model
In a freshwater lake, pressure P (kPa) varies linearly with depth d (m). At the surface (d = 0) the pressure is 101 kPa; at 50 m it is 591 kPa. (a) Find P(d). (b) Find the pressure at 25 m.
(a) slope m = ΔP / Δdm = (591 − 101) / (50 − 0)= 490 / 50 = 9.8 kPa/mintercept: P(0) = 101 givenc = 101P(d) = 9.8d + 101(b) substitute d = 25P(25) = 9.8(25) + 101 = 245 + 101 = 346P(25) = 346 kPaslope is the rate ~9.8 kPa added per metre of depth.
WE 5
Linear depreciation
A new laptop is bought for €1400 and depreciates linearly at €175 per year. (a) Write its value V(t) after t years. (b) Find t when V = €350. (c) State a sensible domain.
(a) slope = −175 (loses value), c = 1400V(t) = 1400 − 175t(b) set V = 350350 = 1400 − 175t ⇒ 175t = 1050t = 1050 / 175 = 6t = 6 years(c) value can’t go below 01400 − 175t ≥ 0 ⇒ t ≤ 8domain 0 ≤ t ≤ 8
WE 6
Break-even comparison
Taxi company A charges $4 plus $1.20 per km. Company B charges $7 plus $0.90 per km. (a) Find the distance for which both cost the same. (b) Which is cheaper for a 15 km trip?
(a) set A(d) = B(d)4 + 1.2d = 7 + 0.9d1.2d − 0.9d = 7 − 40.3d = 3 ⇒ d = 10break-even at d = 10 km(b) test d = 15A(15) = 4 + 1.2(15) = 4 + 18 = $22B(15) = 7 + 0.9(15) = 7 + 13.5 = $20.50B is cheaper by $1.50B has a higher fixed fee but a lower per-km rate, so it wins for long trips.
💡 Top tips
Always interpret in context: examiners want “$0.18 per km”, not just “0.18”.
Check your equation against the second data point before moving on — catches arithmetic slips.
For depreciation use negative slope; for growth use positive slope.
For break-even, set the two models equal and solve algebraically, or use the GDC’s intersect feature.
State a sensible domain: time ≥ 0, value ≥ 0, units cannot be negative in real contexts.
âš Common mistakes
Flipping the slope fraction: it’s Δy/Δx, not Δx/Δy.
Forgetting the negative sign on depreciation slopes — value decreases over time.
Dropping the intercept: writing C = 0.18k instead of 0.18k + 35.
Bare numbers in interpretation: “slope is 0.18” without saying “$ per km” loses marks.
Extrapolating beyond the domain — using the model when it no longer makes physical sense.
Next up: Quadratic Models — symmetric parabolic models with a vertex (maximum or minimum), useful for projectile paths, profit curves and revenue.
Need help with AI HL Linear Models?
Get 1-on-1 help from an IB examiner who knows exactly what Paper 1 & 2 are looking for.