Functions

Stage 10 of 23 Strand 1 of 9 26 lessons

26 illustrated lessons, each teaching the why before the how.

Start with Function Notation in the app →
Revise Functions with flashcards →

Jump to a lesson

Function Notation

f(4) means put 4 in, not f times 4.

A function is a machine that turns each input into exactly one output

Read the full lesson →

x× 33x+ 13x + 1f(x) = 3x + 1

f(x) names a rule. Whatever goes in, the rule says what comes out.

4× 312+ 113f(4) = 13

f(4) does not mean f times 4. It means substitute 4 for x: 3 × 4 + 1 = 13.

xy

Plot every input against its output and the rule becomes a picture.

which inputs give 10?
two inputs, the same output
x = 3 or x = −3

Working backward, g(x) = 10 asks which inputs give 10: both x = 3 and x = −3 do.

Now you

xy

f(x) = 6x + 1. What is f(5)?

xy

f(x) = 6x − 4. What is f(6)?

Domain and Range

What may go in, and what can come out.

The domain is what you are allowed to put in and the range is what can come out

Read the full lesson →

xy

Any number can be squared, so every number is an allowed input. The set of allowed inputs is the domain.

xy

But x² is never negative, so the range, the set of outputs, is every number from 0 up.

xy

Here x cannot be zero at all, because dividing by zero has no answer.

domain [0, ∞)range [0, ∞)f(0) = 0

And a square root needs what is inside to be 0 or more, so its domain starts at 0.

Now you

x

f(x) = 1 / (x − 6). Which input is not allowed?

xy

f(x) = x² + 9. What is the smallest output?

Piecewise Functions

One rule for some inputs, another for the rest.

A piecewise function gives a different rule on each interval of its domain

Read the full lesson →

f(x) = 2x + 1 for x < 3one function, two rules
f(x) = 10 − x for

One function can carry two rules, each with the inputs it governs.

f(0): 0 < 3, so use 2x + 1f(0) = 1

To evaluate, first find which interval the input is in, then use that rule.

f(8): , so use 10 − x
the other rule, for the other interval
f(8) = 2

x = 8 is in the other interval, so use the second rule: 10 − 8 = 2.

f(3): 3 is not less than 3the ≥ includes the boundaryf(3) = 10 − 3 = 7

The boundary belongs to whichever rule carries the "or equal to".

Now you

f(x) = 4x + 1 for x < 5
f(x) = 14 − x for

f(x) = 4x + 1 for x < 5, and 14 − x for x ≥ 5. What is f(5)?

f(x) = 3x + 1 for x < 2
f(x) = 10 − x for

f(x) = 3x + 1 for x < 2, and 10 − x for x ≥ 2. What is f(4)?

Graphing a Piecewise Function

Filled where the point is in, hollow where not.

Each rule is drawn only over its own interval, and the endpoints show which piece includes the boundary

Read the full lesson →

f(x) = x + 1 for x < 2
f(x) = 6 − x for

Two rules again, and this time they disagree about x = 2.

xy

Draw each rule only over its own interval, and the graph breaks at x = 2.

xy(2, 3)(2, 4)

A hollow dot marks a point that is not there; a filled dot marks one that is.

x < 2 stops short of 2so (2, 4) is filled
includes 2

The strict < leaves that end open; the ≥ closes the other one.

xy

Change the second rule to 5 − x and both give 3 at x = 2, so the break closes.

Now you

xy

f(x) = x + 1 for x < 2, and 7 − x for x ≥ 2. Does the graph break at x = 2?

xy

f(x) = x + 1 for x < 3, and 8 − x for x ≥ 3. What is the filled endpoint?

Making a Piecewise Function Continuous

Choose the constant that closes the jump.

The two pieces join without a jump exactly when both rules agree at the boundary

Read the full lesson →

xy

f(x) = 2x for x < 2 and x + 4 for x ≥ 2: the graph jumps by 2 at the boundary.

f(x) = 2x for x < 2k is ours to choose
f(x) = x + k for

Replace the 4 with an unknown k, and ask which value of k closes the jump.

from the left: 2 × 2 = 4from the right: 2 + k

Work out both rules at the boundary: one gives 4, the other gives 2 + k.

2 + k = 4the only value that joins themk = 2

Set the two equal, and one value of k is left: k = 2.

xy

With k = 2 both rules give 4 at x = 2, so the graph has no break: f is continuous.

Now you

f(x) = 3x for x < 2
f(x) = x + k for

f(x) = 3x for x < 2, and x + k for x ≥ 2. Which k joins the pieces?

f(x) = 5x for x < 5
f(x) = x + k for

f(x) = 5x for x < 5, and x + k for x ≥ 5. Which k joins the pieces?

Composite Functions

One machine fed into the next, right to left.

Feeding one function into another makes a composite, and the order changes the answer

Read the full lesson →

xf: + 3x + 3and g: × 2

Here are two functions: f adds 3, and g doubles.

4f: + 37g: × 214gf(4) — f first, despite the writing

gf means do f first: 4 becomes 7, then doubling gives 14.

4g: × 28f: + 311fg(4) — g first. Same boxes, different answer

fg means do g first: 4 becomes 8, then adding 3 gives 11. The order matters.

Now you

gf(4)what does this come to?

f(x) = x + 2, g(x) = 3x. What is gf(4)?

gf(3)what does this come to?

f(x) = x + 6, g(x) = 4x. What is gf(3)?

Inverse Functions

Reverse the steps, and reverse each one.

The inverse undoes a function by running every step backwards

Read the full lesson →

x× 33x+ 13x + 1f(x) = 3x + 1

Read the rule as steps in order: multiply by 3, then add 1.

y− 1y − 1÷ 3(y − 1)/3f⁻¹ undoes it backwards

To undo it, reverse the order of the steps and swap each step for its opposite.

xy

The inverse is the original reflected in the line y = x.

Now you

xy

f(x) = 4x + 7. What is the inverse?

xy

f(x) = 3x + 8. What is the inverse?

Restricting the Domain for an Inverse

Cut a curve at its turning point so it can be undone.

A function has an inverse only where each output comes from one input, so restrict its domain until it does

Read the full lesson →

xy

y = x² gives 4 at both x = −2 and x = 2, so an inverse would not know which one to return.

xy

Keep only x ≥ 0 and every horizontal line meets the curve at most once: f is now one-to-one.

xyy = x

On x ≥ 0 the inverse is f⁻¹(x) = √x, the reflection of that half in the line y = x.

the vertex is at (2, 1)
f(2) = 1the largest one-to-one piece starting at the vertex
domain
the positive root, since x ≥ 2
, so
the domain of f⁻¹ is the range of f
, for

For (x − 2)² + 1, start the domain at the vertex, x ≥ 2, and take the positive root.

Now you

x

f(x) = (x − 5)² + 1. What is the largest domain x ≥ a on which f has an inverse?

xy

f(x) = (x − 2)² + 3, for x ≥ 2. What is f⁻¹(x)?

When a Composite Function Exists

The range of g has to fit inside the domain of f.

fg exists only when every output of g is an input f accepts: the range of g lies inside the domain of f

Read the full lesson →

domain of frange of g−4−3−2−101234

fg feeds the outputs of g into f. With f(x) = √x and g(x) = x − 3, g gives −2 at x = 1, and √(−2) does not exist.

domain of frange of g, for x ≥ 3−4−3−2−101234

So fg exists only when the range of g lies inside the domain of f. On x ≥ 3, g gives y ≥ 0, which fits.

g(x) = x − 3,
the range of g fits inside the domain of f
x goes into g first
fg,

Then fg(x) = √(x − 3), and its domain is the domain of g, x ≥ 3, because x goes into g first.

domain of grange of f−4−3−2−101234

The order matters. gf feeds the outputs of f, y ≥ 0, into g, which takes every number, so gf exists.

Now you

domain of frange of x²−2−1012345678

f(x) = √(x − 3) and g(x) = x² + k. What is the least k for which fg exists?

domain of frange of x²−2−1012345678

f(x) = √(x − 2) and g(x) = x² + k. What is the least k for which fg exists?

Transforming Graphs

Outside the bracket moves it the way you expect.

Adding outside the bracket moves the graph up or down; adding inside moves it sideways, against the sign

Read the full lesson →

xy

Start with y = x², whose vertex is at the origin.

y = x² + 3

Add 3 outside the function and every point moves up 3.

y = (x − 3)²

Subtract 3 inside the bracket, (x − 3)², and the curve moves 3 to the right.

gives 0 at x = 0
3 − 3 = 0, the same value inside the bracket
gives 0 at x = 3
a translation: the shape is unchanged
every point moves 3 to the right

x must be 3 larger to give the same value inside the bracket, so every point moves 3 to the right.

y = 2(x − 2) + 1 = 2x − 3

A line follows the same rule. Moved 2 right, y = 2x + 1 becomes y = 2x − 3: the intercept falls by 2 × 2.

Now you

xy

y = x² + 5. Which way does the curve move?

xy

y = (x − 5)². Which way does the curve move?

Stretching a Graph Vertically

Outside the bracket, every height multiplies.

Multiplying a function from outside the bracket multiplies every height by the same factor

Read the full lesson →

xy

y = 2x² doubles every height, so the curve is stretched away from the x-axis.

x = 2:
twice as high, at the same x
x = 2:

At x = 2 the height goes from 4 to 8. The heights double, and no point moves sideways.

xy

A factor less than 1 squashes it toward the x-axis, by the same rule.

xy

A negative factor sends every height to the other side: y = −x² is the reflection of y = x² in the x-axis.

y = a f(x)so the crossings never moveheight 0 × a = 0

Points on the x-axis have height 0, so they do not move, while every other point is stretched.

Now you

y = 2f(x)

y = f(x) has a lowest value of 9. What is the lowest value of y = 2f(x)?

y = 2f(x)

(1, 6) is on y = f(x). Where is it on y = 2f(x)?

Stretching a Graph Horizontally

Inside the bracket, the widths divide instead.

Replacing x by ax inside the bracket squashes the graph toward the y-axis by that factor

Read the full lesson →

xy−22

Start from y = x² − 4, which meets the x-axis at −2 and at 2.

is 0 at x = 2
x = 1
f(2x) is 0 when 2x = 2

Replace x by 2x, and the inside of the bracket reaches each old value at half the x.

xy−11

So y = (2x)² − 4 crosses at −1 and 1: the curve is squashed toward the axis.

xy−44

Replacing x by x/2 stretches it outward instead, to −4 and 4.

a f(x): heights × aoutside multiplies, inside dividesf(ax): widths ÷ a

Outside the bracket multiplies the height; inside it divides the width.

Now you

y = f(3x)

y = f(x) crosses the x-axis at x = 9. Where does y = f(3x) cross?

y = f(5x)

Which one squashes the graph of y = f(x) toward the y-axis?

Combining Graph Transformations

Two changes in a row, and the order decides where a point lands.

Follow one point: outside the bracket the height goes through the arithmetic in order; inside, x goes through it backwards

Read the full lesson →

xy(4, 2)(4, 5)

y = 2f(x) + 1 changes y = f(x) twice. Here f(x) = √x, and the point (4, 2) ends at (4, 5).

f(4) = 2first a stretch, scale factor 2, parallel to the y-axis2f(4) = 4then a translation 1 up2f(4) + 1 = 5

Outside the bracket, follow the arithmetic in order: the height is doubled first, and 1 is added after.

translate 1 up first, then stretch
a different graph

The order matters: translating first and stretching after gives 2f(x) + 2, not 2f(x) + 1.

y = f(2x + 4)which x feeds f the old input 4?

Inside the bracket, work backwards: x = 0 makes 2x + 4 = 4, so the point at x = 4 moves to x = 0.

y = f(x)a translation 4 to the left
then a stretch, scale factor ½, parallel to the x-axis

So f(2x + 4) is a translation 4 to the left, followed by a stretch of scale factor ½ parallel to the x-axis.

Now you

y = 2f(x) + 1

(2, 1) is on y = f(x). Where is it on y = 2f(x) + 1?

3x + 3 = 9

(9, 3) is on y = f(x). Where is it on y = f(3x + 3)?

Exponentials and Logarithms

A log asks what power the base was raised to.

A logarithm asks what power the base was raised to, so it undoes an exponential

Read the full lesson →

xy

y = 2ˣ doubles each time x goes up by 1, so it rises slowly at first, then very fast.

52 to the …32log₂5the log undoes the power

The same fact, read the other way: what power of 2 gives 32?

xy

The graph of y = log₂ x is the reflection of y = 2ˣ across the line y = x: the domain and range change places.

Now you

which power makes this true?

What is log base 10 of 10000?

which power makes this true?

What is log base 2 of 16?

Exponential Growth

Multiplying by the same factor every step.

Exponential growth multiplies by the same factor every step, so it accelerates

Read the full lesson →

01234

Doubling each step: 1, 2, 4, 8, 16. Each jump is as big as everything before it.

xy

Adding the same amount each time gives a line. Multiplying gives this curve.

n twos
after n steps: start × 2 × 2 × … × 2and ×3 each step would give start × 3ⁿ
start

So after n steps the count is the start times 2ⁿ — with ×3 each step, times 3ⁿ.

Now you

what does this come to?

3 multiplied by 2, 4 times over

what does this come to?

3 multiplied by 2, 3 times over

Exponential Decay

The same rule with a factor below one.

The same rule with a factor below one shrinks toward zero without reaching it

Read the full lesson →

01234

Halving each step: 80, 40, 20, 10, 5. The same rule, with a factor below 1.

xy

The curve falls steeply, then flattens as there is less left to halve.

xy

It closes in on zero forever without reaching it — half of something is never zero.

Now you

0123

64 halved 3 times

012

48 halved 2 times

Growth and Decay Problems

Doubling colonies and half-lives, one rule twice.

Repeated doubling and half-lives are the two exponential shapes at work

Read the full lesson →

0123

Doubling each hour is exponential growth: after n hours, 100 has become 100 × 2ⁿ.

0369

A half-life of 3 days: 9 days is three halvings, so 80 g drops to 40, 20, then 10.

savings: balance × 1.05 each yeardecaycoffee: the extra heat × 0.9 each minute

A savings account grows this way, a cooling coffee cools this way — the same two shapes.

Now you

After n half-lives, what fraction of a sample remains?

0123

A colony of 100 bacteria doubles every hour. How many after 3 hours?

Logistic Growth and Carrying Capacity

Growth that slows as the room runs out.

A logistic model grows like an exponential at first and then flattens onto the largest size the space allows

Read the full lesson →

xy

Exponential growth never lets up. Doubling forever would need unlimited room.

xy

A real population flattens onto a ceiling instead: the carrying capacity.

t large:
the ceiling is L

As t grows the exponential fades to nothing, so P closes on L and stops.

t = 0:
the size it starts from

At the start the same formula hands back the starting size, L over 1 + A.

xy

Growth is fastest halfway up, then slows as the remaining room runs out.

Now you

P = 40 + 4t

Which model stops growing at a ceiling?

xy

P = 125/(1 + 4e⁻ᵗ). What is the carrying capacity?

The Laws of Logarithms

A log turns multiplying into adding.

A logarithm turns multiplying into adding, which is what makes it useful

Read the full lesson →

write out what each power means
(2·2·2) × (2·2·2·2)seven 2s multiplied in all

The law of exponents: multiplying powers of one base adds the exponents, 2³ × 2⁴ = 2⁷.

log 66 = 2 × 3log(2 × 3)multiplying inside becomes adding outsidelog 2 + log 3

So log(ab) = log a + log b, in any base — so long as it is one base throughout.

a cube is three copies multiplied
log(x · x · x)multiplying becomes addinglog x + log x + log xthree of the same thing3 log x

And log(xⁿ) = n log x: a power is repeated multiplying, so the n comes to the front.

dividing inside becomes subtracting
log 20 − log 4

And log(a / b) = log a − log b: dividing inside becomes subtracting outside.

Now you

dividing becomes subtracting
log a − log b

log 20 − log 4 = log ?

log(a × b)multiplying becomes addinglog a + log b

log 4 + log 5 = log ?

The Change of Base Rule

Any log is a quotient of logs you can compute.

One rule turns any logarithm into a quotient of logs the calculator has

Read the full lesson →

take the common log of both sides
the power law brings x down
x log 2 = log N

This x is log₂ N: applying the common logarithm isolates it, through the change-of-base identity.

x log 2 = log Ndivide by log 2
x was log₂ N all along

So log₂ N is log N / log 2 — and any base converts the same way.

two buttons the calculator has

A calculator offers only log₁₀ and ln — this rule reaches every base from those two.

two readings a calculator gives
= 1.4771 ÷ 0.6990= 2.113put it back and it checks

So log₅ 30 is 2.113 — and 5 to that power really does come back to 30.

Now you

which quotient?

Which quotient computes log₇ 20?

change of base, base 2

What is log₄ 8, exactly?

The Natural Logarithm

The log with base e, partner of e to the x.

ln is the logarithm with base e, and it obeys every law the others do

Read the full lesson →

0123e

ln is the log with base e ≈ 2.718, the base that turns up wherever growth is continuous.

xe to the …eˣlnxln undoes the power of e

ln eˣ = x: whatever power e was raised to, ln hands it straight back.

xlnln xe to the …xe^(ln x) = x

The other way round too: e^(ln x) = x. Each machine undoes the other.

ln(ab) = ln a + ln bthe same laws, base e

Every law of logarithms carries over unchanged — ln is a log like any other.

Now you

which machine fills the gap?

ln undoes which function?

a log asks which power builds the number

What is ln e³?

Solving Exponential Equations

Take logs and the power comes down.

Taking logs of both sides brings the unknown power down where you can reach it

Read the full lesson →

divide both sides by 2
x is still in the exponent

The unknown is an exponent, so no amount of dividing will free it.

take the log of both sides
the power law brings the x down
x log 2 = log 32

Take the log of both sides, and the power law brings the x down from the exponent.

x log 2 = log 32divide both sides by log 2
and 2 to the 5 really is 32
x = 5

Now it is an ordinary division. Check it: 2 to the 5 really is 32.

the same two steps, unchanged
no whole number of 2s makes 40
x is about 5.32

And here counting could never have got there: 40 is not any whole power of 2.

Now you

small enough to count, and the log agrees
x = ?

3^x = 27. What is x?

x is in the exponent, so dividing will not reach it
x = ?

2^x = 40. Which expression gives x?

Logarithmic Graphs

The exponential reflected in y = x.

The log graph is the exponential reflected in the line y equals x

Read the full lesson →

xy

y = 2ˣ climbs away steeply and never dips below the x-axis.

xy

Undoing swaps input and output, and swapping x with y reflects a graph in y = x.

xy(2, 4)(4, 2)

So y = log₂x is y = 2ˣ reflected in that line: every (a, b) becomes (b, a).

xy

So it dives at 0 and never reaches it: no power of 2 will ever give zero.

Now you

?
a log asks which power builds the number

What is log₂ 8?

?
a log asks which power builds the number

What is log₁₀ 1000?

Straightening Growth with Logarithms

Take logs and the curve becomes a readable line.

Taking logs turns an exponential law into a straight line whose rule can be read

Read the full lesson →

xy

y = 3 × 2ˣ sweeps up in a curve — its 3 and its 2 are hard to read off the picture.

the log of a product
the power law
log y = log a + x · log b

Take logs of both sides: log y = log a + x · log b — a straight line in x.

xy

Plot log y instead of y and the curve straightens: same data, now a line.

slope
10^0.477 ≈ 3
intercept

Undo the logs: the gradient gives b = 2 and the intercept a = 3 — the rule is recovered.

Now you

xy

Why take logs of growth data at all?

xy

On the log plot of y = a · bˣ, what does the slope give?

Straightening a Power Law

On log-log axes the slope is n itself.

A power law straightens on log-log axes, and the slope is n itself

Read the full lesson →

xy

y = 2x³ sweeps up in a curve — is the power 2, 3 or 4? The picture will not say.

the log of a product
the power law
log y = log a + n · log x

Take logs: log y = log a + n · log x — a straight line in log x, not in x.

xy

Plot log y against log x and it straightens — same data, and the slope is n itself.

slope
10^0.301 ≈ 2
intercept

Read the rule off: n = 3 from the slope, and 10 to the intercept gives a = 2.

Now you

xy

A log-log line has slope 2 and intercept 0.7. Which model fits?

xy

On the log-log plot of y = a · xⁿ, what does the slope give?

Fitting a Logarithmic Model

Rising forever, by less and less each step.

A logarithmic model y = a + b ln x keeps rising while each extra unit of x adds less than the last

Read the full lesson →

trialsscore

Scores climb with practice, but each extra trial adds less than the one before.

trialsscore

A logarithmic model y = a + b ln x bends that way: it rises without a ceiling.

ln xscore

Plot the same scores against ln x and the bend straightens into a line.

intercept 8b is the rise per unit of ln xgradient 3y = 8 + 3 ln x

Read a off as the intercept of that line and b off as its gradient.

y = 8 + 3 ln xln 20 = 3.00at x = 20: 8 + 3 × 3.0017

Put a value in and the model predicts: twenty trials gives a score near 17.

log the y valuesgrowth by a constant factor
straightens
log the x valuesgrowth by a shrinking amounty = a + b ln x straightens

Which axis you take logs of is what picks the family of model.

Now you

intercept 6b is the rise per unit of ln xgradient 5

Plotted against ln x the data give the line y = 5·(ln x) + 6. What is the model?

trialsscore

Values rise forever, but each extra unit of x adds less. Which model?

Continue your journey in the app — save your progress