This SL mini-lesson is about modelling with functions: reading and using linear, quadratic, cubic, exponential, logarithmic and trigonometric models, plus direct/inverse variation, and — the heart of AI — fitting models to data with regression and judging fit with the correlation coefficient r.
AI flavour: you rarely derive functions from scratch; you choose the right model, fit it on your GDC and interpret parameters in context.
Work through each screen, answer the questions as you go (some are wordy, some are calculations) and collect ⭐ stars. Every number on the calculation screens has been re-derived and checked. Press Start when you are ready.
Each real situation suggests a shape:
For f(x)=mx+c, the gradient m is the rate of change and c the initial value. In context, units matter: a taxi at $2.50 flat + $1.20/km is C = 1.20d + 2.50.
Points (1, 52) and (5, 80).
m = (80 − 52) ÷ (5 − 1) = 28 ÷ 4 = 7
c: 52 = 7(1) + c ⇒ c = 45, so f(x) = 7x + 45
Least-squares regression finds the line y = a + bx that best fits data. The correlation coefficient r (−1 ≤ r ≤ 1) measures linear strength; r² is the fraction of variation explained.
Data x = 1,2,3,4,5 with y = 52,58,67,71,80.
GDC gives y = 44.9 + 6.9x, with r = 0.995 and r² = 0.989.
Predict x = 6: y = 44.9 + 6.9×6 = 86.3
Interpret, do not over-claim: r near ±1 means strong linear association — not causation. Only interpolate within the data range.
f(x)=k·ax grows (a>1) or decays (0<a<1) by a constant percentage. A population of 100 growing 8% per year is P = 100 × 1.08t.
Horizontal asymptote: f(x)=k·ax+c approaches y = c but never reaches it — the model's long-run level.
A quadratic f(x)=ax²+bx+c has a vertex (turning point) at x = −b⁄(2a). If a < 0 the vertex is a maximum (e.g. maximum height or profit).
Height h = −5t² + 20t (metres).
Vertex at t = −20 ÷ (2×−5) = 2 s
Max height = −5(2²) + 20(2) = −20 + 40 = 20 m
Tap a real situation, then the model family that fits it best.
Tap an item on the left, then its match on the right.
Two more AI staples: direct variation y = kx (double x → double y) and inverse variation y = k⁄x (double x → halve y).
Inverse-square laws (light, gravity) use y = k⁄x²; recognise the shape and fit k from one data point.
Model families: linear, quadratic, cubic, exponential, logarithmic, sinusoidal
Linear: f(x)=mx+c; m is the rate of change
Regression: GDC gives y = a + bx; r measures linear strength, r² the variation explained
Exponential: k·a^x — constant % change, horizontal asymptote
Quadratic: vertex at x = −b⁄(2a) for max/min
Golden rule: correlation ≠ causation; interpolate, do not extrapolate wildly
You have worked through the whole topic. Press Finish to see your score.
You have covered SL Functions & Modelling for AI. 🎉
Your stars: 0 / 0
Next: test yourself in the Evaluate stage, then lock it in with Verify.