Use x as the variable. Write powers with ^, such as x^3, and roots as sqrt( ) or √.
f(x)
y
Try:
Finds every real x with f(x) = y, even when f⁻¹ has no formula.
f(x)
g(x)
Try:
f and g are inverses when f(g(x)) = x and g(f(x)) = x.
Results update as you type. Press Enter to save to history and / to jump to the input.
Visualize
f (solid) and f⁻¹ (light) are mirror images in the dashed line y = x. The point (1.3, 5.6) on f matches (5.6, 1.3) on f⁻¹.
Result
f(x) = 2x + 3
Check: f(1.3) = 5.6 and f⁻¹(5.6) = 1.3
✓ Exact formula
f(x)
2x + 3
f⁻¹(x)
(x − 3)/2
Domain notes
none
Check
f⁻¹(f(1.3)) = 1.3
Graph
f⁻¹ is the mirror image of f in y = x
History
Your recent calculations will appear here.
Step-by-step solution
Write y = f(x)
y = 2x + 3
Swap x and y
x = 2y + 3
Subtract 3 from both sides
x − 3 = 2y
Divide both sides by 2
(x − 3)/2 = y
Write the inverse
f⁻¹(x) = (x − 3)/2
Check
f(1.3) = 5.6
f⁻¹(5.6) = 1.3 ✓
Did this solve your problem?
An inverse function calculator finds f⁻¹(x), the function that undoes f(x). Type f(x) to get the inverse with every swap-and-solve step, the domain restriction, a numeric check and the graph mirrored in y = x. It solves f(x) = y numerically when no formula exists, and tests whether 2 functions are inverses.
What is an Inverse Function?
An inverse function f⁻¹ undoes f: if f(a) = b, then f⁻¹(b) = a. For f(x) = 2x + 3, f(4) = 11 and f⁻¹(11) = 4, with f⁻¹(x) = (x − 3)/2.
f(a) = b ⇔ f⁻¹(b) = a
f⁻¹ swaps inputs and outputs: the domain of f is the range of f⁻¹, and the range of f is the domain of f⁻¹.
The graph of f⁻¹ is the graph of f reflected in the line y = x: each point (a, b) becomes (b, a).
Only one-to-one functions have inverses. f(x) = x² sends 3 and −3 to 9, so 9 has no single way back.
f⁻¹(x) is not 1/f(x). For f(x) = 2x + 3, 1/f(x) = 1/(2x + 3), a different function.
A point and its mirror image
Pick a function and move the point. Its mirror image in y = x lies on the inverse.
How to Find the Inverse of a Function?
To find the inverse of a function, write y = f(x), swap x and y, and solve the new equation for y. For f(x) = (3x − 2)/5:
Write y = (3x − 2)/5.
Swap x and y: x = (3y − 2)/5.
Multiply by 5: 5x = 3y − 2.
Add 2: 5x + 2 = 3y.
Divide by 3: y = (5x + 2)/3, so f⁻¹(x) = (5x + 2)/3.
Check with a number: f(4) = (12 − 2)/5 = 2, and f⁻¹(2) = (10 + 2)/3 = 4.
The steps undo the operations of f in reverse order: f multiplies by 3, subtracts 2 and divides by 5, so f⁻¹ multiplies by 5, adds 2 and divides by 3.
Swap and solve, step by step
Type any function of x. The steps update as you type.
How to Use This Inverse Function Calculator?
Type f(x) and the calculator returns f⁻¹(x) with every algebra step, a check and the mirror graph. The steps:
Choose Find f⁻¹(x) for a formula, f⁻¹ at a value for a number, or Check 2 functions to test a pair.
Type the function with x as the variable: 2x + 3, x^3, e^(2x), ln(x − 2), sqrt(x + 4) or (2x + 1)/(x − 3).
Read f⁻¹(x), the domain notes and a numeric check.
Open the mirror graph or the arrow diagram, and the worked steps.
Formulas come out when x appears once, or when f is linear, a ratio of 2 linear terms, or a quadratic. For anything else, the value mode solves f(x) = y numerically.
Try an example
Each button fills the calculator above and scrolls to the result.
How to Check if 2 Functions are Inverses?
f and g are inverses when f(g(x)) = x and g(f(x)) = x for every x in their domains.
f(x) = 2x + 3 and g(x) = (x − 3)/2: f(g(x)) = 2 · (x − 3)/2 + 3 = x, and g(f(x)) = (2x + 3 − 3)/2 = x. They are inverses.
f(x) = eˣ and g(x) = ln x: e^(ln x) = x for x > 0, and ln(eˣ) = x for every x. They are inverses.
f(x) = x² and g(x) = √x: g(f(−3)) = √9 = 3, not −3. They are inverses only after f is restricted to x ≥ 0.
Both compositions are needed. One of them can return x while the other fails, as with x² and √x.
Test a pair
Type f and g. The widget composes them both ways.
Horizontal Line Test
A function has an inverse when every horizontal line crosses its graph at most once; that makes it one-to-one.
x³ and eˣ pass: they always rise, so each output comes from one input.
x² fails: the line y = 4 crosses at x = −2 and x = 2.
sin x fails: the line y = 0.5 crosses infinitely often.
|x| fails: |−3| = |3| = 3.
A function that only rises (or only falls) always passes. A positive derivative everywhere is a quick proof: f(x) = x³ + x has f′(x) = 3x² + 1 > 0, so it has an inverse even without a formula.
Horizontal line test
Pick a function and move the line. More than 1 crossing means no inverse on that domain.
Restricting the Domain to Get an Inverse
A function that fails the horizontal line test gets an inverse once its domain is cut to a one-to-one piece.
x² on x ≥ 0 has inverse √x. On x ≤ 0 it has inverse −√x.
x² + 4x + 3 = (x + 2)² − 1. On x ≥ −2 its inverse is √(x + 1) − 2.
sin x on −π/2 ≤ x ≤ π/2 has inverse arcsin x; cos x on 0 ≤ x ≤ π has inverse arccos x.
The chosen piece becomes the range of the inverse. That is why arcsin returns angles from −90° to 90° only, and √x never returns a negative number.
2 halves of a parabola
Pick a branch of x² and move the point. Each branch has its own inverse.
Inverse of Rational and Quadratic Functions
For f(x) = (ax + b)/(cx + d), the inverse is f⁻¹(x) = (dx − b)/(a − cx); for a quadratic, complete the square and take one branch.
(2x + 1)/(x − 3): swap to x = (2y + 1)/(y − 3), multiply out to xy − 3x = 2y + 1, collect y(x − 2) = 3x + 1, so f⁻¹(x) = (3x + 1)/(x − 2).
The inverse has its vertical asymptote at x = a/c = 2, the horizontal asymptote of f.
These tools return every branch, so x² gives ±√y. Pick the branch that matches the domain you need.
The same inverse in software
Type f(x), then pick a tool.
Table of Common Functions and Their Inverses
The table pairs common functions with their inverses and the domain where each inverse works. Click a row to load the function into the calculator.
Exponentials and logarithms undo each other, powers and roots undo each other, and each trigonometric function is undone by its arc function on a restricted interval.
Functions and inverses
Filter by value, or click a row to send it to the calculator.
f(x)
f⁻¹(x)
Domain of f⁻¹
2x + 3
(x − 3)/2
all x
mx + b, m ≠ 0
(x − b)/m
all x
x³
∛x
all x
eˣ
ln(x)
x > 0
10ˣ
log₁₀(x)
x > 0
2ˣ
log₂(x) = ln(x)/ln(2)
x > 0
ln(x)
eˣ
all x
√x
x²
x ≥ 0
x², x ≥ 0
√x
x ≥ 0
1/x
1/x
x ≠ 0
(2x + 1)/(x − 3)
(3x + 1)/(x − 2)
x ≠ 2
sin x, |x| ≤ π/2
arcsin(x)
−1 ≤ x ≤ 1
tan x, |x| < π/2
arctan(x)
all x
x² + 4x + 3, x ≥ −2
√(x + 1) − 2
x ≥ −1
Inverse Functions in Real Life
An inverse function answers the reverse question: given the result, what was the input?
Temperature: F = 9C/5 + 32 turns Celsius into Fahrenheit; C = 5(F − 32)/9 turns it back. 98.6 °F is 37 °C.
Taxi fare: cost = 3 + 2.5d. A $23 fare means d = (23 − 3)/2.5 = 8 km.
Savings: A = 1000 · 1.05ᵗ. Doubling to $2000 takes t = ln 2 / ln 1.05 = 14.21 years.
Sound: L = 10 log₁₀(I/I₀) in decibels; I = I₀ · 10^(L/10). 60 dB is 1,000,000 times I₀.
Codes: decryption is the inverse of encryption, so an encryption map must be one-to-one.
Run a formula backwards
Pick an example and set the result. The inverse gives the input.
Inverse Function FAQ
No question matches your search.
What is an inverse function?
A function f⁻¹ that undoes f: if f(a) = b, then f⁻¹(b) = a. Its graph is the reflection of the graph of f in the line y = x.
How do you find the inverse of a function?
Write y = f(x), swap x and y, and solve for y. For f(x) = 2x + 3: x = 2y + 3, so y = (x − 3)/2.
Is f⁻¹(x) the same as 1/f(x)?
No. f⁻¹ undoes f; 1/f(x) is the reciprocal. For f(x) = 2x + 3, f⁻¹(x) = (x − 3)/2 but 1/f(x) = 1/(2x + 3).
Which functions have an inverse?
One-to-one functions: each output comes from exactly one input. The graph must pass the horizontal line test.
What is the inverse of x²?
x² is not one-to-one on all real numbers. Restricted to x ≥ 0, its inverse is √x; restricted to x ≤ 0, it is −√x.
What is the inverse of eˣ?
ln(x), the natural logarithm, defined for x > 0. e^(ln x) = x and ln(eˣ) = x.
What is the inverse of (ax + b)/(cx + d)?
(dx − b)/(a − cx). For (2x + 1)/(x − 3), the inverse is (3x + 1)/(x − 2).
How do I check that 2 functions are inverses?
Compute f(g(x)) and g(f(x)). If both simplify to x, f and g are inverses.
How are the graphs of f and f⁻¹ related?
They are mirror images in the line y = x. The point (a, b) on f matches (b, a) on f⁻¹.
What are the domain and range of an inverse function?
They swap: the domain of f⁻¹ is the range of f, and the range of f⁻¹ is the domain of f.
Can a function be its own inverse?
Yes. f(x) = 1/x, f(x) = −x and f(x) = 5 − x are their own inverses: f(f(x)) = x.
What is the derivative of an inverse function?
(f⁻¹)′(b) = 1/f′(a), where f(a) = b. For f(x) = x³ + x, f(2) = 10 and f′(2) = 13, so (f⁻¹)′(10) = 1/13.
Why does the calculator say there is no formula?
Some functions, such as x³ + x or x + eˣ, have inverses with no formula in basic functions. Use the f⁻¹ at a value mode to get numbers.
How do I type powers and roots?
Use ^ for powers (x^3, e^(2x)) and sqrt( ) or √ for square roots. ln, log, sin, cos and tan work too.
What is the inverse of a linear function?
For f(x) = mx + b with m ≠ 0, f⁻¹(x) = (x − b)/m. The slope of the inverse is 1/m.