Composite and inverse functions in IGCSE Maths, with worked examples
8 minute read · Updated 2026-11-05
What a function is
A function is a rule. You put a number in, the rule works on it, and one number comes out. If f(x) = 2x + 3, then f(4) = 2 × 4 + 3 = 11. The letter x is only a place holder for whatever you put in.
Composite functions: one rule after another
fg(x) means do g first, then f. It is written as f(g(x)). The order is the opposite of how it reads, which is the usual trap.
Let f(x) = 2x + 3 and g(x) = x². To find fg(x), put g(x) into f in place of x: fg(x) = 2(x²) + 3 = 2x² + 3. To find gf(x), put f(x) into g: gf(x) = (2x + 3)² = 4x² + 12x + 9. The two answers are different, so the order matters.
For a single value you can do it in two steps. fg(2): first g(2) = 4, then f(4) = 11. And gf(2): first f(2) = 7, then g(7) = 49.
Solving an equation with a composite function
Solve fg(x) = 35 for the same f and g. We found fg(x) = 2x² + 3, so 2x² + 3 = 35. Subtract 3: 2x² = 32. Divide by 2: x² = 16. So x = 4 or x = −4. Remember both roots when you take a square root.
Inverse functions: undoing a rule
The inverse function f⁻¹ undoes f. If f turns 4 into 11, then f⁻¹ turns 11 back into 4. To find it, write y = f(x), then rearrange to make x the subject, then swap the letters so the answer is written with x.
For f(x) = 2x + 3: y = 2x + 3, so y − 3 = 2x, so x = (y − 3)/2. Writing it with x, f⁻¹(x) = (x − 3)/2. Check: f⁻¹(11) = 8/2 = 4, which is where we started.
A fraction works the same way. For h(x) = 5/(x − 2): y = 5/(x − 2), so x − 2 = 5/y, so x = 5/y + 2. Writing it with x, h⁻¹(x) = 5/x + 2.
Common mistakes
- Doing fg in the wrong order. Work from the right: g acts first.
- Writing f⁻¹(x) as 1/f(x). The inverse is not the reciprocal.
- Forgetting the negative root when solving an equation with x².
- Not checking. Put a number into f, then put the answer into f⁻¹: you must get your first number back.
Try these questions
Work each one on paper first, then open the answer to check your working.
1. f(x) = 3x − 1 and g(x) = x + 4. Find fg(x), gf(x) and fg(2).
Show the answer
fg(x) = 3(x + 4) − 1 = 3x + 11. gf(x) = (3x − 1) + 4 = 3x + 3. fg(2) = 3 × 2 + 11 = 17.
2. f(x) = 4x − 5. Find f⁻¹(x) and f⁻¹(11).
Show the answer
f⁻¹(x) = (x + 5)/4. f⁻¹(11) = 16/4 = 4.
3. g(x) = x² − 1 and f(x) = x + 2. Find gf(x) and solve gf(x) = 0.
Show the answer
gf(x) = (x + 2)² − 1 = x² + 4x + 3. Then x² + 4x + 3 = (x + 1)(x + 3) = 0, so x = −1 or x = −3.
4. h(x) = 2/(x + 1). Find h⁻¹(x) and h⁻¹(4).
Show the answer
y = 2/(x + 1) gives x + 1 = 2/y, so h⁻¹(x) = 2/x − 1. h⁻¹(4) = 0.5 − 1 = −0.5. Check: h(−0.5) = 2/0.5 = 4.
Want fresh functions questions, with a mark scheme?
Paperly-NT makes a new IGCSE Maths paper in minutes. You can start free.
Try Paperly-NT free