Math Insight

Inverse function examples

An inverse function is a function that undoes the action of the another function. Using function machine metaphor, forming an inverse function means running the function machine backwards. The backwards function machine will work only if the original function machine produces a unique output for each unique input.

In the following examples, we demonstrate a few simple cases where one can calculate the inverse function. In most cases, though, we cannot write down a nice formula for the inverse function.

Example 1

Let $f: \R \to \R$ (confused?) be defined by $f(x)=3x+1$. Find the inverse function $f^{-1}$.

Solution: For any input $x$, the function machine corresponding to $f$ spits out the value $y=f(x)=3x+1$. We want to find the function $f^{-1}$ that takes the value $y$ as an input and spits out $x$ as the output. In other words, $y=f(x)$ gives $y$ as a function of $x$, and we want to find $x=f^{-1}(y)$ that will give us $x$ as a function of $y$.

To calculate $x$ as a function of $y$, we just take the expression $y=3x+1$ for $y$ as a function of $x$ and solve for $x$. \begin{align*} y &= 3x+1\\ y-1 &= 3x\\ \frac{y-1}{3} &= x \end{align*} Therefore, we found out that $x=y/3 - 1/3$, so we can write the inverse function as $$f^{-1}(y) = \frac{y}{3} - \frac{1}{3}.$$

In the definition of the function $f^{-1}$, there's nothing special about using the variable $y$. We could use any other variable, and write the answer as $f^{-1}(x) = x/3-1/3$ or $f^{-1}(\bigstar) = \bigstar/3 -1/3$. The placeholder variable used in the formula for a function doesn't matter.