Inverse Tangent Calculator

Inverse Function Calculator

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:

  1. Write y = (3x − 2)/5.
  2. Swap x and y: x = (3y − 2)/5.
  3. Multiply by 5: 5x = 3y − 2.
  4. Add 2: 5x + 2 = 3y.
  5. 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:

  1. Choose Find f⁻¹(x) for a formula, f⁻¹ at a value for a number, or Check 2 functions to test a pair.
  2. 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).
  3. Read f⁻¹(x), the domain notes and a numeric check.
  4. 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.
  • x² + 4x + 3: write (x + 2)² − 1, swap, solve: f⁻¹(x) = √(x + 1) − 2 on x ≥ −1.
  • 5/(x + 1): x appears once, so undo the steps: f⁻¹(x) = 5/x − 1.

Rational and quadratic inverses

Type a ratio of linear terms or a quadratic.

Finding f⁻¹ at One Value

To find f⁻¹(b) without a formula, solve f(x) = b for x: f⁻¹(b) is the x that f sends to b.

  • f(x) = x³ + x has no simple inverse formula, but f(2) = 10, so f⁻¹(10) = 2.
  • Numerically: find 2 inputs where f(x) − b changes sign, then halve the gap until it is tiny (bisection).
  • From a table: f⁻¹(b) is the x in the row where f(x) = b.
  • The slope of the inverse is the reciprocal of the slope of f: (f⁻¹)′(10) = 1/f′(2) = 1/13 ≈ 0.0769.

Solve f(x) = y

Type a function and a value y.

Inverse Function in Wolfram, SymPy and MATLAB

Computer algebra systems invert functions by solving y = f(x) for x: Solve in Wolfram Language, solve in SymPy and finverse in MATLAB.

  • Wolfram Language: InverseFunction[2 # + 3 &] or Solve[y == 2x + 3, x].
  • SymPy: solve(Eq(y, 2*x + 3), x) returns [y/2 − 3/2].
  • MATLAB: syms x; finverse(2*x + 3) returns x/2 − 3/2.
  • GeoGebra: Inverse(2x + 3).
  • TI-Nspire CAS: solve(y = 2x + 3, x).

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)/2all x
mx + b, m ≠ 0(x − b)/mall x
x³∛xall 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
√xx²x ≥ 0
x², x ≥ 0√xx ≥ 0
1/x1/xx ≠ 0
(2x + 1)/(x − 3)(3x + 1)/(x − 2)x ≠ 2
sin x, |x| ≤ π/2arcsin(x)−1 ≤ x ≤ 1
tan x, |x| < π/2arctan(x)all x
x² + 4x + 3, x ≥ −2√(x + 1) − 2x ≥ −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

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.