# Inverse functions

Canonical: https://duckyhelper.com/learn/algebra-2/inverse-functions/
Updated: 2026-10-01

An inverse function undoes a function: if \(f(2) = 7\), then \(f^{-1}(7) = 2\). To find it, write \(y = f(x)\), swap x and y, and solve for y. The graph of \(f^{-1}\) is the graph of f reflected over the line \(y = x\). Check your answer by composing: \(f(f^{-1}(x))\) should equal x. Only one-to-one functions have inverses, so sometimes you restrict the domain first.

## The key idea

A function sends inputs to outputs. Its inverse sends each output back to the input it came from. So inputs and outputs trade places, and every point \((a, b)\) on f becomes \((b, a)\) on \(f^{-1}\).

$$
f(a) = b \iff f^{-1}(b) = a, \qquad f\big(f^{-1}(x)\big) = x = f^{-1}\big(f(x)\big)
$$

The \(-1\) is not an exponent here. \(f^{-1}(x)\) means the inverse function, not \(\frac{1}{f(x)}\).

### Steps to find an inverse

1. Replace \(f(x)\) with y.
2. Swap x and y.
3. Solve the new equation for y.
4. Replace y with \(f^{-1}(x)\) and state any domain limits.
5. Check that \(f(f^{-1}(x)) = x\).

## Worked examples

**Example 1: a linear function**

Problem: Find the inverse of \(f(x) = 3x - 5\) and check it.

1. Write y for \(f(x)\).

   $$
   y = 3x - 5
   $$
2. Swap x and y.

   $$
   x = 3y - 5
   $$
3. Add 5 to both sides.

   $$
   x + 5 = 3y
   $$
4. Divide by 3.

   $$
   y = \frac{x + 5}{3}
   $$
5. Check: put \(\frac{x + 5}{3}\) into f.

   $$
   3 \cdot \frac{x + 5}{3} - 5 = x
   $$

Answer: \(f^{-1}(x) = \frac{x + 5}{3}\)

**Example 2: a rational function**

Problem: Find the inverse of \(f(x) = \frac{2x + 1}{x - 3}\).

1. Write \(y = \frac{2x + 1}{x - 3}\), then swap x and y.

   $$
   x = \frac{2y + 1}{y - 3}
   $$
2. Multiply both sides by \(y - 3\).

   $$
   x(y - 3) = 2y + 1
   $$
3. Distribute.

   $$
   xy - 3x = 2y + 1
   $$
4. Get every y term on one side and everything else on the other.

   $$
   xy - 2y = 3x + 1
   $$
5. Factor out y.

   $$
   y(x - 2) = 3x + 1
   $$
6. Divide by \(x - 2\).

   $$
   y = \frac{3x + 1}{x - 2}
   $$

Answer: \(f^{-1}(x) = \frac{3x + 1}{x - 2}\), for \(x \ne 2\)

**Example 3: restrict the domain first**

Problem: \(f(x) = (x - 2)^2 + 1\) is not one-to-one, so restrict it to \(x \ge 2\). Find the inverse.

1. Swap x and y in \(y = (x - 2)^2 + 1\).

   $$
   x = (y - 2)^2 + 1
   $$
2. Subtract 1.

   $$
   x - 1 = (y - 2)^2
   $$
3. Take the square root. The outputs of the inverse are the old inputs, which were at least 2, so \(y - 2 \ge 0\) and only the positive root fits.

   $$
   y - 2 = \sqrt{x - 1}
   $$
4. Add 2.

   $$
   y = 2 + \sqrt{x - 1}
   $$

Answer: \(f^{-1}(x) = 2 + \sqrt{x - 1}\), with domain \(x \ge 1\)

**Example 4 (test-hard): an inverse value without the formula**

Problem: Let \(f(x) = x^3 + x + 1\). Find \(f^{-1}(11)\).

1. \(f^{-1}(11)\) is the input that gives 11. Set up that equation instead of hunting for a formula.

   $$
   x^3 + x + 1 = 11
   $$
2. Move 11 over.

   $$
   x^3 + x - 10 = 0
   $$
3. Try small integers. \(x = 2\) works.

   $$
   2^3 + 2 - 10 = 0
   $$
4. f is always increasing (both \(x^3\) and x grow), so no other input gives 11.

Answer: \(f^{-1}(11) = 2\)

## Common mistakes

- **Writing \(\frac{1}{f(x)}\).** The inverse of \(3x - 5\) is not \(\frac{1}{3x - 5}\). Fix: swap x and y and solve.
- **Forgetting to swap.** Solving \(y = 3x - 5\) for x gives the same function written backwards. Fix: swap first, then solve for y, so the answer is in terms of x.
- **Leaving y on both sides.** In \(xy - 3x = 2y + 1\), collect every y term on one side and factor y out.
- **Keeping both square roots.** With a restricted domain, only one sign makes sense. Fix: the outputs of \(f^{-1}\) must match the inputs you allowed for f.
- **Skipping the check.** A quick composition catches most algebra slips. Fix: plug a number like \(x = 4\) into f, then into your inverse, and see if you get 4 back.

## Quick methods

> **Tip: The horizontal line test**
>
> If any horizontal line hits a graph more than once, the function is not one-to-one and has no inverse on that domain. A parabola fails; a line that is not horizontal passes. This is a reliable visual check.

> **Tip: Undo the steps in reverse**
>
> For simple functions, list what f does to x and undo it backwards. \(f(x) = 3x - 5\) multiplies by 3 then subtracts 5, so \(f^{-1}\) adds 5 then divides by 3: \(\frac{x + 5}{3}\).

## Practice

**5 practice questions**

1. What is the inverse of \(f(x) = \frac{x + 4}{2}\)?
   A. \(f^{-1}(x) = 2x - 4\)
   B. \(f^{-1}(x) = 2x + 4\)
   C. \(f^{-1}(x) = \frac{x - 4}{2}\)
   D. \(f^{-1}(x) = \frac{2}{x + 4}\)

   Answer: \(f^{-1}(x) = 2x - 4\). Swap: \(x = \frac{y + 4}{2}\). Multiply by 2: \(2x = y + 4\), so \(y = 2x - 4\). \(\frac{2}{x + 4}\) is the reciprocal, which is not the inverse.

2. f is one-to-one and \(f(3) = 10\). Which point must be on the graph of \(f^{-1}\)?
   A. \((3, 10)\)
   B. \((10, 3)\)
   C. \((-3, -10)\)
   D. \((3, -10)\)

   Answer: \((10, 3)\). \((3, 10)\) is on f, and the inverse swaps inputs and outputs, so \((10, 3)\) is on \(f^{-1}\). That is the reflection of \((3, 10)\) over \(y = x\).

3. Which function does NOT have an inverse function on its whole domain?
   A. \(f(x) = 2x + 7\)
   B. \(g(x) = x^3\)
   C. \(h(x) = x^2 + 1\)
   D. \(k(x) = \sqrt{x}\)

   Answer: \(h(x) = x^2 + 1\). \(h(2) = h(-2) = 5\), so two inputs share an output and h fails the horizontal line test. The other three never repeat an output.

4. What is the inverse of \(f(x) = x^3 - 1\)?
   A. \(f^{-1}(x) = \sqrt[3]{x + 1}\)
   B. \(f^{-1}(x) = \sqrt[3]{x} + 1\)
   C. \(f^{-1}(x) = \frac{1}{x^3 - 1}\)
   D. \(f^{-1}(x) = \sqrt[3]{x - 1}\)

   Answer: \(f^{-1}(x) = \sqrt[3]{x + 1}\). Swap: \(x = y^3 - 1\), so \(y^3 = x + 1\) and \(y = \sqrt[3]{x + 1}\). Adding 1 after the cube root undoes the steps in the wrong order.

5. If \(f(x) = 5x - 7\), what is \(f^{-1}(18)\)?

   Answer: 5. Find the input that gives 18: \(5x - 7 = 18\), so \(5x = 25\) and \(x = 5\). Check: \(f(5) = 25 - 7 = 18\).

## Frequently asked questions

### Is f^-1(x) the same as 1/f(x)?

No. \(f^{-1}\) is the function that undoes f, while \(\frac{1}{f(x)}\) is the reciprocal of the output. For \(f(x) = 2x\), the inverse is \(\frac{x}{2}\), but the reciprocal is \(\frac{1}{2x}\). The notation is confusing, so read it from context.

### How do I check that two functions are inverses?

Compose them both ways. If \(f(g(x)) = x\) and \(g(f(x)) = x\) for every allowed x, they are inverses. A quick spot check: put a number into one, put the result into the other, and you should get your number back.

### What does one-to-one mean?

Every output comes from exactly one input. If two different inputs give the same output, like \(x^2\) at 3 and \(-3\), the inverse would not know which input to return. Restricting the domain, for example to \(x \ge 0\), fixes that.

### How are the graphs of a function and its inverse related?

They are mirror images over the line \(y = x\), because every point \((a, b)\) becomes \((b, a)\). If you fold the graph paper along \(y = x\), the two graphs land on top of each other.

## Related

- [Transformations of functions](https://duckyhelper.com/learn/algebra-2/function-transformations/)
- [Logarithms](https://duckyhelper.com/learn/algebra-2/logarithms/)
- [Functions, function notation, domain and range](https://duckyhelper.com/learn/algebra-1/functions/)
- [Functions and function notation on the SAT](https://duckyhelper.com/learn/sat-math/functions/)
- [Algebra 2 study guides](https://duckyhelper.com/learn/algebra-2/)

## Try asking Ducky

- "Why do we swap x and y? It feels like cheating."
- "Can you check my inverse by composing it with the original?"
- "Why does only the positive square root work in the restricted one?"

## Get DuckyHelper

Free to start. The web app works in any browser, Chromebooks included; the Mac app can also draw on your real screen. [Try it free in your browser](https://app.duckyhelper.com/?utm_source=duckyhelper.com&utm_medium=learn) or [Get the Mac app](https://duckyhelper.com/download/)
