Inverse Function

Can the effect of a function be undone by an inverse function? We first define what an inverse function is

Definition 1.5.1. For a function f: XY an inverse function is a function g: YX such that fg and gf are the identity functions on Y and X respectively, that is

f(g(y) = y  and  g(f(x) = x

for all x in X and y in Y. Or

gf = idX  and  fg = idY

A function which has an inverse is said to be invertible.

Example 1.5.2 Consider the function f and g with domain and codomain ℝ which are defined by f(x) = 2x − 1 and g(x) = (x + 1)/2. The g is an inverse function of F since fg = id. Indeed

fg(x) = f ((x + 1)/2) = 2((x + 1)/2) − 1 = x

with a similar comupation for gf. ■

A function f: XY need not have an inverse. For example, if f is not injective then there is a pre-image f−1 for some yY which contains at least two elements. In this case, it is not clear which of these two elements to choose for the value of the proospective inverse function with argument y. Likewise, if f is not surjective there exists an empty pre-image f−1 so in this case there is no candidate for the value of a prospective inverse function at y.
A basic theorem asserts that only bijective functions are invertible.

Theorem 1.5.3. A function f: XY has an inverse if and only if it is bijective.

Proof. Suppose first that f has an inverse function g: YX. If f(x1) = f(x2), then, on applying g to both sides, we obtain gf(x1) = gf(x2). But gf is the identity function so x1 = x2. Hence f is injective. Next let y be any element of Y; then, since fg is the identity function, y = fg(y) = f(g(y)), which shows that y belongs to the image of f and f is surjective. Therefore f is bijective.
Conversely, assume that f is a bijective function. We need to find an inverse function g: YX for f. To this end let yY; then, since F is surjective, y = f(x) for some xX; moreover x is uniquely determined by y since f is injective. This allows us to define g(y) to be x. Then g(f(x)) = g(y) = x and f(g(y)) = f(x) = y. Here it is necessary to observe that every element of X is of the form g(y) for some y in Y, so that g(f(x)) equals x for all elements xX. Therefore g is an inverse function for f.  □

The next observations is that when inverse functions do exists, they are unique.

Theorem 1.5.4. Every bijective function f: XY has a unique inverse function.

Proof. Suppose that f has two inverse functions, say g1 and g2. Then (g1f) ∘ g2 = idXg2 = g2 by Theorem 1.4.6 On the other hand, by Theorem 1.4.5 this function is also equatl to g1 ∘ (fg2) = g1 ⋅ idY = g1. Thus g1 = g2.  □

Note. Don't confuse f−1(T) with the inverse function f−1. The inverse function cannot be defined for any function, whereas the pre-image can always be defined.

(f−1)−1 = f

Formally, this follows because both f and (f−1)−1 satisfy the condition in Def. 1.5.1.

Example 1.3.8. Let f: XY defined as in the example above, and let X1 = {2,4} and B1 = {B,C,E} then f(X1) = {B, C} and f−1(B1) = {2,3,4}. ■

Example 1.3.9. Consider the function f: ℝ → ℝ defined as f(x) = x2. Note that f({0,1,2}) = {0,1,4} and f−1({0,1,4}) = {−2,−1,0,1,2}. This shows that f−1(f(X)) ≠ X, since the function is not injective. ■

Graphic of the inverse function

Il grafico della funzione inversa si ottiene da quello di f scambiando tra loro le coordinate di ciascun punto (x0, y0). I punti (x0, y0) e (y0, x0), risultano simmetrici rispetto la retta y=x, bisettrice del I e III quadrante quindi i grafici di f e della sua inversa risultano uno l'immagine speculare dell'altro.

We want to represent the grap of f andf−1 on the same cartesian plane. Since f(a) = b iff f−1(b) = a, the point (a,b) belongs to the graph of f iff (b,a) belongs to the graph of f−1. The point (b,a) is obtained from (a,b) by reflection about the line y = x

graph of the inverse function

Some examples of function and inverse functions are the following

Un esempio è dato dalla funzione cubica: f(x) = x3 and f−1(y) = (y)1/3.

funzione cubica
«Composition of functions Index Peano axioms »