- Practice
- About 18 min
- 5 practice questions
Composition of functions and graphs of standard functions
Form the composite functions f∘g and g∘f, see that composition is not commutative but is associative, solve for unknowns using composition, and recognise the graphs of linear, modulus, quadratic, cubic, reciprocal and constant functions.
If something looks wrong, please tell us.
By the end of this lesson you can
- Find (f∘g)(x) = f(g(x)) and (g∘f)(x) = g(f(x)) and show that they are usually different.
- Verify (f∘g)∘h = f∘(g∘h) and find unknown constants from conditions such as f∘g = g∘f.
- Match linear, modulus, quadratic, cubic, reciprocal and constant functions with the shapes of their graphs.
Pressing a car's accelerator changes the fuel flow, and the fuel flow changes the speed: one process feeds the next. Joining two functions so that the output of the first becomes the input of the second is called composition. The chapter ends by putting names to the graphs of the functions you will meet most often.
Composite functions
Let f : A → B and g : B → C. The composition g∘f : A → C is defined by (g∘f)(x) = g(f(x)): first apply f, then apply g to the result. The composite g∘f exists only when the range of f is a subset of the domain of g.
How (g∘f)(x) is formed
- Start with x in A The input.
- Apply f Get f(x) in B.
- Apply g to f(x) Get g(f(x)) in C.
- Result: (g∘f)(x) One combined function from A to C.
Worked example 1: f∘g and g∘f are different
Let f(x) = x + 3 and g(x) = 2x². Working: (f∘g)(x) = f(g(x)) = f(2x²) = 2x² + 3. (g∘f)(x) = g(f(x)) = g(x + 3) = 2(x + 3)² = 2(x² + 6x + 9) = 2x² + 12x + 18. These are not equal, so f∘g ≠ g∘f: composition of functions is not commutative in general.
Worked example 2: find k when f∘g = g∘f
Let f(x) = 2x − 1 and g(x) = 3x + k. Working: (f∘g)(x) = 2(3x + k) − 1 = 6x + 2k − 1. (g∘f)(x) = 3(2x − 1) + k = 6x − 3 + k. Setting them equal: 6x + 2k − 1 = 6x − 3 + k. Cancel 6x: 2k − 1 = k − 3, so k = −2. Check: with k = −2 both give 6x − 5.
Worked example 3: solving (f∘f)(x) = 26
Let f(x) = 3x + 2. Working: (f∘f)(x) = f(3x + 2) = 3(3x + 2) + 2 = 9x + 8. Set 9x + 8 = 26: 9x = 18, so x = 2. Check: f(2) = 8 and f(8) = 26.
Composition of three functions is associative
For f : A → B, g : B → C and h : C → D, the composition is associative: (f∘g)∘h = f∘(g∘h). Check with f(x) = x − 2, g(x) = 3x and h(x) = x + 5. Working: (f∘g)(x) = 3x − 2, so ((f∘g)∘h)(x) = 3(x + 5) − 2 = 3x + 13. Also (g∘h)(x) = 3(x + 5) = 3x + 15, so (f∘(g∘h))(x) = (3x + 15) − 2 = 3x + 13. Both sides agree.
Composition also works backwards: a complicated function can be split into simple ones. For example F(x) = (2x + 1)² is h∘g with g(x) = 2x + 1 (act first) and h(x) = x² (act second).
(g∘f)(x) = g(f(x)). In general f∘g ≠ g∘f (not commutative), but (f∘g)∘h = f∘(g∘h) always (associative).
Graphs of standard functions
The Tamil Nadu textbook asks you to recognise these graphs on sight. In each row f is defined on ℝ unless stated.
| Function | Rule | Shape of the graph | One-one? |
|---|---|---|---|
| Linear | f(x) = mx + c, m ≠ 0 | A straight line (identity f(x) = x and additive inverse f(x) = −x are special cases) | Yes |
| Modulus (absolute value) | f(x) = |x|: x when x ≥ 0, −x when x < 0 | A V shape with its corner at the origin; range [0, ∞) | No |
| Quadratic | f(x) = ax² + bx + c, a ≠ 0 | A parabola: y = x² opens upward with range [0, ∞); y = −x² opens downward with range (−∞, 0] | No |
| Cubic | f(x) = ax³ + bx² + cx + d, a ≠ 0 | y = x³ rises from bottom left to top right, flattening at the origin | y = x³ is one-one |
| Reciprocal | f(x) = 1/x on ℝ − {0} | Two separate branches in the first and third quadrants, never touching the axes | Yes |
| Constant | f(x) = c | A horizontal line through (0, c) | No |
Note that the modulus function is not linear: it is made of two linear pieces, x and −x, joined at the origin.
Worked example 4: a linear function from two values
A linear function f(x) = mx + c has f(1) = 5 and f(3) = 11. Find f(−2). Working: m + c = 5 and 3m + c = 11. Subtract: 2m = 6, so m = 3, and c = 5 − 3 = 2. So f(x) = 3x + 2 and f(−2) = −6 + 2 = −4.
Key takeaways: (g∘f)(x) = g(f(x)); work from the inside out. Composition is not commutative but it is associative. To find an unknown constant, compose both ways, simplify and compare. Know the shapes: straight line (linear), V (modulus), parabola (quadratic), S-like curve (cubic), two branches (reciprocal), horizontal line (constant).
Check your understanding
-
1. If f(x) = x² and g(x) = x + 4, what is (f∘g)(x)?
- x² + 4
- x² + 8x + 16
- x² + 16
- 4x²
Show answer
Answer: B. (f∘g)(x) = f(g(x)) = f(x + 4) = (x + 4)² = x² + 8x + 16. Note x² + 4 is (g∘f)(x), which is different.
-
2. If f(x) = 2x + 3, g(x) = 3x + k and f∘g = g∘f, what is k?
- 6
- 3
- −6
- 9
Show answer
Answer: A. (f∘g)(x) = 2(3x + k) + 3 = 6x + 2k + 3. (g∘f)(x) = 3(2x + 3) + k = 6x + 9 + k. So 2k + 3 = 9 + k, giving k = 6.
-
3. If f(x) = 2x − 3, what is f(f(2))?
- 1
- 5
- −5
- −1
Show answer
Answer: D. Work from the inside: f(2) = 2 × 2 − 3 = 1. Then f(1) = 2 × 1 − 3 = −1. So f(f(2)) = −1.
-
4. Which describes the graph of f(x) = −x² on ℝ?
- A straight line through the origin
- A V shape opening upward
- A parabola opening downward with range (−∞, 0]
- Two branches in the first and third quadrants
Show answer
Answer: C. −x² is a quadratic function, so its graph is a parabola. Since −x² ≤ 0 for every x, it opens downward and its range is (−∞, 0].
-
5. Which function from ℝ to ℝ is NOT one-one?
- f(x) = x³
- f(x) = x²
- f(x) = 3x − 2
- f(x) = x
Show answer
Answer: B. f(x) = x² gives f(3) = f(−3) = 9, so two inputs share an output and it is many-one; its graph fails the horizontal line test. The cubic x³, the linear 3x − 2 and the identity x are all one-one.
Sign in to keep track of the lessons you finish.