Composition and inverse functions
Functions can be chained together, with one output feeding the next input. An inverse function runs a function backwards, undoing what it does.
Combining functions
Functions can be added, subtracted, multiplied, and divided pointwise: \((f + g)(x) = f(x) + g(x)\). If \(f(x) = 2x\) and \(g(x) = x + 3\), then \((fg)(x) = 2x(x + 3)\). The domain is where both functions are defined, excluding any zeros of the denominator for a quotient.
Composition
The composition \((f \circ g)(x) = f(g(x))\) applies g first, then f. With \(f(x) = x^2\) and \(g(x) = x + 3\): \(f(g(x)) = (x + 3)^2\), while \(g(f(x)) = x^2 + 3\). Order matters: in general \(f \circ g \neq g \circ f\). For a number, \(f(g(2)) = f(5) = 25\).
Composition in practice
Composition models chains of processes. If a store takes 20% off, then a coupon removes $10, the final price is c(d(p)) with d(p) = 0.8p and c(x) = x - 10. For p = $100, that is 80 - 10 = $70; applying the coupon first gives 0.8 x 90 = $72, a different answer, so order matters in real life too.
One-to-one functions
An inverse exists only if the function is one-to-one: different inputs always give different outputs. The horizontal line test checks this; no horizontal line may cross the graph more than once. y = x squared fails on all real numbers, since 2 and -2 both give 4, but passes if the domain is restricted to x >= 0.
Inverse functions
The inverse \(f^{-1}\) undoes f: if \(f(a) = b\), then \(f^{-1}(b) = a\), so \(f^{-1}(f(x)) = x\) and \(f(f^{-1}(x)) = x\). The notation \(f^{-1}\) does not mean \(\frac{1}{f}\). The domain of f becomes the range of \(f^{-1}\), and vice versa.
Finding an inverse
Write \(y = f(x)\), swap x and y, and solve for y. For \(f(x) = 3x - 5\): \(x = 3y - 5\), so \(y = \frac{x + 5}{3}\), and \(f^{-1}(x) = \frac{x + 5}{3}\). Check: \(f^{-1}(f(2)) = f^{-1}(1) = 2\).
Graphs of inverses
The graph of \(f^{-1}\) is the reflection of the graph of f across the line \(y = x\), because swapping x and y swaps every point (a, b) to (b, a). The graphs of \(y = x^2\) for \(x \ge 0\) and \(y = \sqrt{x}\) are mirror images in this line.
Worked example
To convert Celsius to Fahrenheit, \(F(C) = \tfrac{9}{5}C + 32\). Its inverse converts back: swap and solve to get \(C(F) = \tfrac{5}{9}(F - 32)\). Checking, \(F(100) = 212\) and \(C(212) = \tfrac{5}{9}(180) = 100\), so the inverse undoes the original.
Key takeaways
Functions combine by addition, subtraction, multiplication, and division, on the domain where both are defined. Composition f(g(x)) applies g first, and order usually matters. A function has an inverse only if it is one-to-one, which the horizontal line test checks; restricting the domain can make it one-to-one. The inverse undoes the function, so f^-1(f(x)) = x, and f^-1 is not 1/f. Find it by swapping x and y and solving for y. Inverse graphs are reflections across y = x.
Flashcard
(f + g)(x) = f(x) + g(x)
Check your understanding
If \(f(x) = 3x - 5\), what is \(f^{-1}(x)\)?
