Composite Functions: Finding fg(x) and Its Domain | AQA A Level Maths notes

Free preview: Composite Functions: Finding fg(x) and Its Domain

A Function of a Function

Year 2 (A level only)

Watch: 1-minute explainer

Let's start with a machine picture. Put a number into one machine, then feed its output straight into a second machine. A juicer and then a freezer turn an orange into an ice lolly. Freezer first, then juicer? You'd get something very different.

  • A composite function applies one function and then another to the result.
  • If g is applied first and f second, we write fg(x).

fg(x)=f(g(x))

๐Ÿ’ก In plain words

  • Read it from the inside out: the function written nearest to x acts first.
  • So in fg(x), first find g(x), then put that answer into f.

Flow diagram: 3 goes through g (add 1) to give 4, then through f (square) to give fg(3) = 16; and 3 goes through f to give 9, then g to give gf(3) = 10

Following the diagram

  • Take f(x)=x2 and g(x)=x+1.
  • Top row, fg(3): g acts first, g(3)=4, then f(4)=16.
  • Bottom row, gf(3): f acts first, f(3)=9, then g(9)=10.
  • The answers differ, so the order matters: in general fg(x)≠gf(x).

The recipe: finding the expression for fg(x)

  1. Write fg(x)=f(…) with the whole of g(x) inside the bracket. Why: this middle line shows the examiner your method.
  2. In the rule for f, replace every x by g(x), in brackets.
  3. Simplify, then check with one number.

๐Ÿ‘€ Watch me do it: find fg(x) and gf(x) for f(x)=x2, g(x)=x+1

What I writeWhy I do it
fg(x)=f(x+1)Step 1: g goes inside f.
=(x+1)2Step 2: f squares whatever it is given.
gf(x)=g(x2)=x2+1Now f inside g: g adds 1 to whatever it is given.
Check x=3: (3+1)2=16 and 32+1=10.Step 3: both match the diagram.
  • You can also compose a function with itself: ff(x)=f(f(x)), sometimes written f2(x).
  • With f(x)=x2, ff(x)=(x2)2=x4.

๐Ÿ“ Write the middle step

Show fg(x)=f(x+1)=(x+1)2, not just the final line. If you make a slip later, the middle step can still earn the method mark.

โœ๏ธ YOUR TURN 1

Try this first:

f(x)=2x+3 and g(x)=x2. Find fg(2), gf(2), fg(x) and gf(x).

Answer:

  • fg(2)=f(4)=11; gf(2)=g(7)=49.
  • fg(x)=f(x2)=2x2+3; gf(x)=g(2x+3)=(2x+3)2.
  • Check: 2(4)+3=11 and 72=49.

Composites with Fractions, and f Composed with Itself

The recipe doesn't change when the functions get messier. The brackets are what keep you safe.

๐Ÿ‘€ Watch me do it: find fg(x) and gf(x) for f(x)=3x−1 and g(x)=2x+1

What I writeWhy I do it
fg(x)=f(2x+1)=3(2x+1)−1Replace the x in f by (2x+1).
=32xSimplify the bottom.
gf(x)=g(3x−1)=2(3x−1)+1g doubles and adds 1.
=6x−1+x−1x−1=x+5x−1Single fraction over the common denominator.
Check x=3: g(3)=7, f(7)=12 and 36=12.Agrees.

A function composed with itself

  • ff(x) means apply f, then apply f again to the answer.
  • Same recipe: put the whole of f(x) inside f.

๐Ÿ‘€ Watch me do it: find ff(x) for f(x)=1x, x≠0

What I writeWhy I do it
ff(x)=f(1x)=11/xf flips whatever it is given.
=xFlipping twice gets you back where you started.
So f undoes itself.You'll meet this idea again with inverse functions.

๐Ÿ“ fg is not f times g

Wrong: fg(x)=x2(x+1) for f(x)=x2, g(x)=x+1. That is the product f(x)g(x). Right: fg(x)=(x+1)2.

โœ๏ธ YOUR TURN 2

Try this first:

f(x)=2x−5. Find ff(x) and solve ff(x)=1.

Answer:

  • ff(x)=2(2x−5)−5=4x−15.
  • 4x−15=1, x=4. Check: f(4)=3, f(3)=1.

โœ๏ธ YOUR TURN 3

Try this first:

f(x)=x+2 and g(x)=1x for x≠0. Find fg(x) and gf(x).

Answer:

  • fg(x)=f(1x)=1x+2.
  • gf(x)=g(x+2)=1x+2 (needs x≠−2).

Domain and Range of a Composite Function

The output of g is the input of f. So for fg(x) to make sense, two things must be true:

  • x must be in the domain of g (so g(x) exists), and
  • g(x) must be in the domain of f (so f can accept it).
  • If the range of g includes values f cannot take, you must cut down the domain of fg.

Unlock the full note: start 7 days free.

Log in or subscribe to read the rest of this note. Members also get the AI tutor, practice quizzes, mock exams and flashcards for this topic.

Log in ยท Subscribe ยท Start free trial

All notes in Functions and Graphs

  1. Sketching Cubic and Quartic Graphs from Their Factors
  2. Reciprocal Graphs y = a/x and y = a/xยฒ and Their Asymptotes
  3. Using Points of Intersection to Solve Equations
  4. Direct and Inverse Proportion and Their Graphs
  5. Translating Graphs: y = f(x) + a and y = f(x + a)
  6. Stretching and Reflecting Graphs: y = af(x), y = f(ax), y = โˆ’f(x) and y = f(โˆ’x)
  7. Combining Transformations of Graphs
  8. What Makes a Function: Domain, Range, One-One and Many-One
  9. Composite Functions: Finding fg(x) and Its Domain
  10. Inverse Functions and Their Graphs: Reflecting in y = x
  11. The Modulus Function and the Graph of y = |ax + b|
  12. Modelling with Functions: Limitations and Refinements
  13. Move Up a Grade: A Level Maths Functions and Graphs
  14. Tricky Bits: A Level Maths Functions and Graphs

Video

What's inside for this topic

14 teacher notes, 223 practice questions, 60 flashcards, 7 quizzes.

Get the full notes, every practice question, flashcards, quizzes and mock papers.

Start your free 7-day trial

Questions? Chat with us on WhatsApp ยท Try one live lesson

Previous note: What Makes a Function: Domain, Range, One-One and Many-One Next note: Inverse Functions and Their Graphs: Reflecting in y = x

Composite Functions: Finding fg(x) and Its Domain on other exam boards

All AQA A Level Maths topics ยท A Level Maths