InfyCalculator
➗

Inverse Function Calculator — Linear and Rational f(x) = (ax + b)/(cx + d)

Find the inverse of a linear or rational function f(x) = (ax + b)/(cx + d): f⁻¹(x) in simplest form, the domain and range of f and f⁻¹, and a numeric check that f⁻¹(f(x)) = x.

a (x coefficient, numerator)
b (constant, numerator)
c (x coefficient, denominator)
d (constant, denominator)
Check at x
Loading calculator…

How it works

y = (ax + b)/(cx + d) → swap x and y → x(cy + d) = ay + b → f⁻¹(x) = (dx − b)/(−cx + a) · linear case (c = 0): f⁻¹(x) = (dx − b)/a · an inverse exists when ad − bc ≠ 0

To invert a function, write y = f(x), swap x and y, and solve for y. For the rational (Möbius) form (ax + b)/(cx + d) this always gives (dx − b)/(−cx + a), and for a line it gives (x − b)/a after dividing by d. The function is one-to-one exactly when ad − bc ≠ 0; otherwise it is a constant and has no inverse. The domain of f excludes the zero of the denominator, x = −d/c, and its range excludes the horizontal asymptote y = a/c — these swap roles for f⁻¹ (OpenStax Precalculus §3.7).

Worked example

f(x) = (2x + 1)/(x − 3), so a = 2, b = 1, c = 1, d = −3. Swap and solve: x(y − 3) = 2y + 1 → xy − 2y = 3x + 1 → f⁻¹(x) = (3x + 1)/(x − 2). ad − bc = −6 − 1 = −7 ≠ 0, so the inverse exists. Domain of f: x ≠ 3, range of f: y ≠ 2. Check: f(4) = 9/1 = 9 and f⁻¹(9) = 28/7 = 4.

Sources: OpenStax Precalculus 2e — 3.7 Inverse Functions · Paul’s Online Math Notes — Inverse Functions

Frequently asked questions

How do you find the inverse of a function?

Replace f(x) with y, swap x and y, and solve the new equation for y. The result is f⁻¹(x). Check it with f(f⁻¹(x)) = x.

How do you find the inverse of a rational function?

For y = (ax + b)/(cx + d), swap to x = (ay + b)/(cy + d), multiply out x(cy + d) = ay + b, collect the y terms (cxy − ay = b − dx) and divide: y = (dx − b)/(−cx + a).

When does a function have no inverse?

When it is not one-to-one. For (ax + b)/(cx + d) that happens only when ad − bc = 0, which makes f a constant. Parabolas and other non-one-to-one functions need a restricted domain first.

How are the domain and range of f and f⁻¹ related?

They swap: the domain of f⁻¹ is the range of f, and the range of f⁻¹ is the domain of f.

Is f⁻¹(x) the same as 1/f(x)?

No. f⁻¹ undoes f; 1/f(x) is the reciprocal of the output. For f(x) = 2x, f⁻¹(x) = x/2 but 1/f(x) = 1/(2x).

Related calculators

This calculator is for educational purposes. Double-check important results before acting on them.