Maths › Algebra and functions › Functions, inverses and the modulus
Functions, inverses and the modulus
A function maps every input in its domain to exactly one output. Compose functions in the stated order, restrict a domain where necessary before defining an inverse, and solve modulus equations and inequalities by cases, or by squaring where that gives an equivalent statement, checking any conditions introduced.
Builds on Graphs, proportion and transformations.
IN THIS TOPIC
- Distinguish a one-to-one mapping from a many-to-one mapping, and state a function's domain and range.
- Build composite functions in the right order.
- Find an inverse and give its domain and range.
- Sketch modulus graphs, and solve modulus equations and inequalities from them.
- Use the two modulus relations: equal moduli mean equal squares, and a modulus held under b is a two-sided interval.
COMMON MISCONCEPTION
Every function has an inverse.
Only a one-one function has an inverse. A many-one function sends two inputs to one output, so there is no way to decide which input the inverse should return: x2 sends both 2 and −2 to 4. Restricting the domain is the remedy, and x2 + 4 on x ≥ 0 keeps one arm of the parabola and becomes invertible.
Domain, range and the two kinds of mapping
A function assigns to each input exactly one output, written f(x) or f: x ↦ 2x + 1. Its domain is the set of inputs it accepts and its range is the set of outputs it actually produces. A function is one-one when distinct inputs always give distinct outputs, and many-one when two inputs can share an output, as x2 does by sending both 2 and −2 to 4. Only a one-one function has an inverse.
Composites, and which one goes first
Chain two functions together and the notation reads right to left. In fg(x), the function nearest the input acts first, so g goes first. Swapping the order usually changes the answer.
WORKED EXAMPLE
Composites, in the right order
With f(x) = 2x + 1 and g(x) = x2, find fg(2) and gf(2), and the formula for fg(x).
fg means g first. g(2) = 4, then f(4) = 9, so fg(2) = 9.
The other order. f(2) = 5, then g(5) = 25, so gf(2) = 25.
In general fg(x) = f(x2) = 2x2 + 1.
The two results differ, so the order of composition matters. Evaluate the inner function first and write its output down before applying the outer function.
Inverses, and which functions have them
The inverse f−1 undoes f, so f−1f(x) = x for every x in the domain, and its graph is the graph of f reflected in y = x, because undoing swaps input with output. Only one-one functions have inverses. A many-one function sends two inputs to one output, so there would be no way to determine which input the inverse should return. The standard remedy is a restricted domain. Take x2 + 4 on x ≥ 0, keep one arm of the parabola, and it becomes invertible.
WORKED EXAMPLE
An inverse with its domain and range
Find the inverse of f(x) = x2 + 4 with domain x ≥ 0, stating the domain and range of f−1.
Write y = x2 + 4 and solve for x, giving x = √(y − 4), taking the positive root because the domain of f is x ≥ 0.
Swap the letters. f−1(x) = √(x − 4).
The range of f is y ≥ 4, so the domain of f−1 is x ≥ 4 and its range is y ≥ 0. Domain and range trade places under inversion.
The domain and range are part of the answer: without the domain x ≥ 4, √(x − 4) is not the inverse of this function.
The modulus
The modulus |x| removes the sign, so the graph of y = |ax + b| is the line ax + b with the part below the x-axis reflected into the upper half-plane, a V with its vertex at the line's root. Keep two similar-looking notations separate from it: y = f(−x) replaces x by −x and reflects the whole graph in the y-axis, while y = f(|x|) replaces x by |x|, copying the right-hand half of the graph onto the left. The number of solutions of a modulus equation is the number of intersections of the two graphs, so sketch both sides before solving.
The graph of y = |f(x)| reflects the part of y = f(x) below the x-axis into the upper half-plane. Zeros remain fixed. By contrast, zeros of f become vertical asymptotes of y = 1/f(x).
WORKED EXAMPLE
A modulus equation, both arms
Solve |2x − 1| = x.
Original arm. 2x − 1 = x gives x = 1, and the check |1| = 1 holds.
Reflected arm. −(2x − 1) = x gives 1 − 2x = x, so x = ⅓, and |−⅓| = ⅓ holds.
Solutions: x = ⅓ and x = 1, matching the two crossings on the sketch.
Each case gives one candidate, and each candidate must be substituted into the original equation, because a case may give a value that does not satisfy it.
GUIDED PRACTICE
The matching inequality
Solve |2x − 1| > x, before opening the working.
Show the working
The critical points are the crossings just found, x = ⅓ and x = 1.
Between them the V dips below the line, so the modulus is the larger outside them: x < ⅓ or x > 1.
A test value settles any doubt. At x = ½ the left side is 0 and the right is ½, so the middle interval genuinely fails.
A sketch handles one arm at a time. Two relations do the same work algebraically. Squaring discards a sign in the way the modulus does, which gives the first: |a| = |b| ⇔ a2 = b2, equal moduli and equal squares being one condition written two ways. The second reads |x − a| as the distance from x to a along the number line, so |x − a| < b ⇔ a − b < x < a + b, a modulus held under b saying the same thing as an interval of width 2b centred on a. That one finishes an inequality against a constant in a line: |x − 3| < 5 becomes −2 < x < 8, and ≤ behaves the same throughout.
The first relation is what licenses squaring, and also what limits it. With a modulus on each side, squaring is a two-way step and nothing is lost. Against a plain expression it is not, because squaring |f(x)| = g(x) gives f(x)2 = g(x)2, which is the statement |f(x)| = |g(x)|: the working has answered a larger question, and a root at which g(x) is negative belongs to that larger question rather than to this one. Substituting back into the original is what removes it.
WORKED EXAMPLE
A modulus on both sides
Solve |x + 2| ≤ |2x − 1|.
A modulus stands on each side, so squaring loses nothing: (x + 2)2 ≤ (2x − 1)2.
Expanding gives x2 + 4x + 4 ≤ 4x2 − 4x + 1, so 0 ≤ 3x2 − 8x − 3, and that quadratic factorises as (3x + 1)(x − 3).
It opens upward, so it is at or above zero outside its roots: x ≤ −⅓ or x ≥ 3.
The graph route agrees. The two Vs have vertices at x = −2 and x = ½, their arms cross at x = −⅓ and x = 3, and between those crossings the left-hand V is the higher of the two, which is where the inequality fails. At x = 0 it reads 2 ≤ 1, so the middle interval is out.
Squaring was safe here because both sides carried a modulus. Ask instead for |x + 2| = 2x − 1, square it, and the same quadratic returns the same pair, but |−⅓ + 2| = 5/3 while 2(−⅓) − 1 = −5/3. That root solves |x + 2| = |2x − 1| rather than the equation asked, and the check against the original is what discards it.
INDEPENDENT PRACTICE
A composite with two answers
With f(x) = 2x + 1 and g(x) = x2, solve gf(x) = 9.
Show the working
gf(x) = (2x + 1)2, so (2x + 1)2 = 9 and 2x + 1 = ±3.
The two arms give x = 1 and −2.
Squaring is many-one, so one output has two preimages, and that is what gives the ± in the first line.
ASSESSMENT FOCUS
- fg means g first. Write the inner function's output down before touching the outer one.
- To invert, set y = f(x), solve for x, swap the letters, then state the new domain and range: the domain of f−1 is the range of f, and its range is the domain of f.
- Only one-one functions have inverses. To explain why a given f has no inverse, name two inputs with the same output.
- Sketch a modulus equation and count the intersections first, then solve one linear equation per case and check each solution in the original equation.
- With a modulus on both sides, square instead: |a| = |b| ⇔ a2 = b2 gives a quadratic. Squaring against an expression without a modulus solves |f(x)| = |g(x)| instead, so any root failing the original equation must be discarded.
- A modulus against a constant needs no working at all: |x − a| < b is the interval a − b < x < a + b, and the same with ≤.
- For |f(x)|, reflect the part below the x-axis into the upper half-plane and leave the rest unchanged. For f(−x), reflect in the y-axis; for f(|x|), copy the right-hand half of the graph onto the left.
CHECK YOURSELF
With f(x) = 3x − 2 on all of ℝ, find f−1(x), and solve |3x − 2| = 4.
Show a hint
Linear functions are one-one everywhere; the modulus needs both arms.
Show the answer
Solving y = 3x − 2 for x gives x = (y + 2)/3, so f−1(x) = (x + 2)/3, with no restriction needed.
The arms of |3x − 2| = 4. 3x − 2 = 4 gives x = 2, and 3x − 2 = −4 gives x = −⅔.
Solutions x = 2 and x = −⅔, and both satisfy the original equation when substituted back.
fg applies g first. An inverse reverses the function, is the reflection of its graph in y = x, and exchanges domain with range.
Only one-one functions invert.
Equal moduli mean equal squares, and |x − a| < b is the interval a − b < x < a + b.
WORKBOOK
Printable practice for this topic: original exam-style questions with room to work, and a fully worked answer book. Free to use; please do not redistribute or sell.
Or read them with their worked answers on the functions, inverses and the modulus questions page.
USED LATER IN
CHECK YOUR PROGRESS
Rate how confident you feel with each objective for this lesson. Ratings are saved in this browser, on this device, unless you sign in.
- Distinguish a one-to-one mapping from a many-to-one mapping, and state a function's domain and range.
- Build composite functions in the right order.
- Find an inverse and give its domain and range.
- Sketch modulus graphs, and solve modulus equations and inequalities from them.
- Use the two modulus relations: equal moduli mean equal squares, and a modulus held under b is a two-sided interval.
Open the full revision checklist to see every objective in the course in one place.