Algebra › Section J · Exponential and logarithmic functions › Topic J.1

Composite and inverse functions

Functions can be chained into assembly lines, and assembly lines can be run backwards. Composition wires outputs into inputs; the inverse function hits rewind - and only some functions are built with a rewind button at all.

Composition: the assembly line

The composition \((f \circ g)(x) = f(g(x))\) sends each input through \(g\) first, then feeds \(g\)'s output into \(f\). Read the notation right-to-left, like an assembly line read from the raw material end: the inside function acts first, the outside function acts on what comes off the belt. Composition is genuinely new - not addition, not multiplication of functions, but piping. And unlike arithmetic, the order of the stations on the line is part of the design.

Worked example: order matters

Let \(f(x) = 2x - 1\) and \(g(x) = x^2 + 4\). Then \(f(g(x)) = 2(x^2 + 4) - 1 = 2x^2 + 7\), while \(g(f(x)) = (2x - 1)^2 + 4 = 4x^2 - 4x + 5\) - visibly different formulas, and different at numbers too: \(f(g(3)) = f(13) = 25\), while \(g(f(3)) = g(5) = 29\). In general \(f \circ g \neq g \circ f\); composition is not commutative. The only safe habit is to read which function is inside and let it act first.

Composition as a model of chains

Real processes chain, and composition is their algebra. A store marks up a wholesale price \(w\) by $30: \(M(w) = w + 30\). At the register, sales tax adds 10%: \(T(x) = 1.10x\). The customer pays \(T(M(w)) = 1.10(w + 30)\). For a $70 wholesale price, that is 1.10 times 100, or $110 at the till. Run the line backwards - tax first, then markup - and the same wholesale item would cost \(1.10(70) + 30 = 107\) dollars: a different answer. When a word problem feeds one quantity through two processes, composition is the grammar, and the order is the meaning.

One-to-one: the rewind license

A function earns an inverse only if it is one-to-one: different inputs always produce different outputs, so no output is ambiguous about where it came from. The visual test is the horizontal line test - no horizontal line may cross the graph more than once. The parabola \(y = x^2\) fails over all real numbers, since a horizontal line at height 4 catches both \(x = 2\) and \(x = -2\): an inverse would not know whether 4 came from 2 or from -2. Restrict the domain to \(x \ge 0\), and the license is granted. Strictly increasing or decreasing functions - like \(y = x^3\) - pass everywhere.

What an inverse does

The inverse \(f^{-1}\) runs \(f\) backwards: if \(f(a) = b\), then \(f^{-1}(b) = a\). Composing them in either order returns the input untouched: \(f^{-1}(f(x)) = x\) and \(f(f^{-1}(x)) = x\). A warning baked into the notation: \(f^{-1}\) means the inverse function, never the reciprocal \(\frac{1}{f}\) - the exponent-looking \(-1\) is a historical accident that misleads every generation. The domain of \(f\) becomes the range of \(f^{-1}\), and the range of \(f\) becomes its domain: the two functions trade places exactly.

Finding an inverse algebraically

The routine is three moves: write \(y = f(x)\), swap \(x\) and \(y\), then solve for \(y\) - the solution is \(f^{-1}(x)\). The swap encodes the reversal: points \((a, b)\) on \(f\) become points \((b, a)\) on \(f^{-1}\), so trading the variables in the equation trades them on the graph. For \(f(x) = 5x - 8\): swap to \(x = 5y - 8\), add 8 for \(x + 8 = 5y\), divide by 5 for \(f^{-1}(x) = \frac{x + 8}{5}\). The check is a round trip: \(f(4) = 12\), and \(f^{-1}(12) = \frac{20}{5} = 4\) - back where we started.

Worked example: a nonlinear inverse

Find the inverse of \(f(x) = x^3 + 1\). Swap: \(x = y^3 + 1\). Solve: \(y^3 = x - 1\), so \(y = \sqrt[3]{x - 1}\) and \(f^{-1}(x) = \sqrt[3]{x - 1}\). The cube root undoes the cube, and the subtracted 1 undoes the added 1 - inverses peel a function's layers off in reverse order, which is composition running backwards. Point-check: \(f(2) = 9\), so \(f^{-1}(9)\) should be 2, and \(\sqrt[3]{8} = 2\). Graphically, \(f\) passes through \((2, 9)\) and \(f^{-1}\) through \((9, 2)\): every point swapped, which is exactly a reflection across the line \(y = x\).

Worked example: an inverse that answers a question

A taxi charges $3.50 to enter plus $2.50 per kilometre: \(F(m) = 2.5m + 3.5\) turns kilometres into dollars. The natural question runs backwards - a $28.50 fare covered how many kilometres? Find the inverse: swap to \(x = 2.5y + 3.5\), subtract 3.5 and divide by 2.5: \(F^{-1}(x) = \frac{x - 3.5}{2.5}\). Then \(F^{-1}(28.5) = \frac{25}{2.5} = 10\) kilometres. This is the everyday role of inverses: formulas written input-to-output, while questions ask output-to-input. Every unit-conversion formula you own - currency, temperature, shoe sizes - comes paired with its inverse for exactly this reason.

Common mistakes to avoid

First, reading \(f^{-1}(x)\) as \(\frac{1}{f(x)}\) - it is the undoing function, not the reciprocal. Second, composing in the wrong order: \(f \circ g\) starts with \(g\), always - read inside-out. Third, inverting without the one-to-one check: \(x^2\) over all reals has no inverse, and "solving" anyway manufactures an expression that fails the round trip for negative inputs. Fourth, skipping the swap and just solving \(y = f(x)\) for \(x\): without exchanging the variables, you have \(x\) in terms of \(y\), not a function of \(x\). Fifth, never verifying: the round trip \(f^{-1}(f(x)) = x\) takes seconds and certifies everything.

Key takeaways

Composition \(f(g(x))\) runs the inside function first, and the order matters - \(f \circ g\) is generally not \(g \circ f\), in algebra and in word problems alike. A function is invertible exactly when it is one-to-one, checked by the horizontal line test, and domain restriction can grant the license. The inverse satisfies \(f^{-1}(f(x)) = x\); its domain and range are \(f\)'s range and domain traded. Find it by writing \(y = f(x)\), swapping \(x\) and \(y\), solving for \(y\), and checking the round trip. Its graph is the reflection across \(y = x\), every point \((a, b)\) swapped to \((b, a)\).

Flashcards

Flashcard

Composition

f(g(x)), inside first

Assembly line.

Test your understanding

Question 1 of 5

If f(x) = 2x - 1 and g(x) = x^2 + 4, what is f(g(3))?

Question 2 of 5

Which function is one-to-one on all real numbers?

Question 3 of 5

If f(x) = 5x - 8, what is f^-1(x)?

Question 4 of 5

If f(x) = x^3 + 1, what is f^-1(x)?

Question 5 of 5

How does the graph of f^-1 compare with the graph of f?

← Previous topicNext topic →