IB Maths AA SL Topic 2 — Functions Paper 1 & 2 🎯 Skill ~3 min practice

AA SL Composite Functions skills

A composite function is a function inside another. Read it inside-out: the inner function’s output becomes the outer function’s input. Get the order right and the algebra is just careful substitution.

The Method

(f ∘ g)(x) = f(g(x)) do g first, then put the result inside f
  1. Identify the inner function — it’s the one written closest to x (or the one inside the brackets).
  2. Substitute the inner function’s output into every x of the outer function.
  3. Expand and simplify if asked, or leave in factored form if cleaner.

Read it inside-out

Example: f(x) = x² + 1,   g(x) = 2x − 3,   find (f ∘ g)(x)

Step 1 — input x
→
Step 2 — apply g g(x) = 2x − 3
→
Step 3 — apply f (2x − 3)² + 1

The output of g replaces every x inside f. Only then do you expand.

⚠️

Order matters: f(g(x)) ≠ g(f(x))

The order of composition changes the answer. f ∘ g means “f after g” — apply g first. Always write down which is inner and which is outer before you start.

Worked examples

WE 1 EASY

f(x) = x² + 4 and g(x) = x − 5. Find (f ∘ g)(x).

step 1 — identify outer/inner f is outer, g is innerstep 2 — substitute g(x) into f (f ∘ g)(x) = f(g(x)) = f(x − 5) = (x − 5)² + 4step 3 — expand = x² − 10x + 25 + 4(f ∘ g)(x) = x² − 10x + 29 replace every x inside f with the whole expression (x − 5) — including brackets!
WE 2 MEDIUM

f(x) = 3x + 2 and g(x) = x². Find (f ∘ g)(x) and (g ∘ f)(x).

part (a) — f ∘ g (g first) f(g(x)) = f(x²) = 3(x²) + 2 = 3x² + 2part (b) — g ∘ f (f first) g(f(x)) = g(3x + 2) = (3x + 2)² = 9x² + 12x + 4f ∘ g = 3x² + 2   vs   g ∘ f = 9x² + 12x + 4 order matters — completely different answers!
WE 3 HARD

f(x) = √(x + 7) and g(x) = 2x² − 5. Find (f ∘ g)(3).

step 1 — find g(3) first g(3) = 2(3)² − 5 = 18 − 5 = 13step 2 — feed result into f f(13) = √(13 + 7) = √20step 3 — simplify the surd √20 = √(4 × 5) = 2√5(f ∘ g)(3) = 2√5 when given a numerical input, do it in two stages — much faster than building the full composite!

Practice questions

Try each one yourself first, then click the question to reveal the worked answer. Always identify outer and inner before substituting.
Q1 EASY f(x) = 2x + 1, g(x) = x − 4. Find (f ∘ g)(x). Show answer ▼Hide answer ▲
f(g(x)) = f(x − 4) = 2(x − 4) + 1 = 2x − 8 + 1 (f ∘ g)(x) = 2x − 7
Q2 EASY f(x) = x² and g(x) = x + 3. Find (g ∘ f)(x). Show answer ▼Hide answer ▲
f is inner — apply first g(f(x)) = g(x²) = x² + 3 (g ∘ f)(x) = x² + 3
Q3 MEDIUM f(x) = x² − 2x, g(x) = x + 1. Find (f ∘ g)(x). Show answer ▼Hide answer ▲
f(g(x)) = f(x + 1) = (x + 1)² − 2(x + 1) = x² + 2x + 1 − 2x − 2 (f ∘ g)(x) = x² − 1 replace EVERY x in f with (x + 1), not just the first one!
Q4 MEDIUM f(x) = 1x, g(x) = x + 2. Find (f ∘ g)(5). Show answer ▼Hide answer ▲
step 1 — g(5) g(5) = 5 + 2 = 7 step 2 — f(7) f(7) = 1/7 (f ∘ g)(5) = 1/7
Q5 HARD f(x) = 3x − 2 and (f ∘ g)(x) = 6x + 4. Find g(x). Show answer ▼Hide answer ▲
step 1 — write the composite definition f(g(x)) = 3¡g(x) − 2step 2 — set equal to given 3¡g(x) − 2 = 6x + 4 3¡g(x) = 6x + 6g(x) = 2x + 2 when given the composite, work backwards from f’s structure!

⚠ Common mistakes

📖

Want the theory?

Read the full Composite Functions notes for the link to inverse functions, the relationship f(f⁝š(x)) = x, and how composition appears in the chain rule.

Need help with Composite Functions?

Get 1-on-1 help from an IB examiner who knows exactly what Paper 1 & 2 are looking for.

Book Free Session →