# 1) Lets say we have a function f:X \rightarrow Y that has an inverse function. How do I find the function I(x) = f^{-1}(f(x)) and how can I find the domain and range of I(x) ? This one is very confusing and I love an good explanation for it.

Discrete math question about surjective, injective function and domain, range
1) Lets say we have a function $f:X\to Y$ that has an inverse function. How do I find the function $I\left(x\right)={f}^{-1}\left(f\left(x\right)\right)$ and how can I find the domain and range of I(x) ? This one is very confusing and I love an good explanation for it.
2) Prove that if f and g are both surjective, then g∘f is surjective. I think that I have to prove that its image is equal to its codomain, but I have no idea how to do this.
You can still ask an expert for help

## Want to know more about Discrete math?

• Live experts 24/7
• Questions are typically answered in as fast as 30 minutes
• Personalized clear answers

Solve your problem for the price of one coffee

• Math expert for every subject
• Pay only if we can solve it

lelapem
Step 1
1) Saying that $f:X\to Y$ has an inverse is equivalent to saying that f is bijective, otherwise ${f}^{-1}:Y\to X$ couldn’t be defined. Furthermore, composing the two always gives the Identity function, whether $X\to X$ or $Y\to Y$ depends on the order of composition (which one is it, in your example?).
Step 2
2) To prove stuff like this it is always a good idea to work with a specific element of your set and prove the inclusions in question. So, looking back at the definition: $f:X\to Y$ is surjective iff $\mathrm{\forall }y\in Y,\mathrm{\exists }x\in X$ such that $f\left(x\right)=y$ (which is the same thing you said). Now, pick a z in the domain of $g\circ f$ and try to prove its pre image x exists.
###### Not exactly what you’re looking for?
Lillie Pittman
Step 1
That is not always easy to find the inverse function when you have general sets X and Y.
However, if X and Y are subsets of $\mathbb{R}$, for instance, you can find ${f}^{-1}$ with the following idea: Solve the equation $f\left(y\right)=x$ for y, then y will give you the formula for the inverse.
For instance, consider the function $f:\left(0,1\right)⟶\mathbb{R}$ given by $f\left(x\right)=\frac{x}{1+x}.$
Then f is bijective. Let us find ${f}^{-1}$. Well:
$f\left(y\right)=x⇔\frac{y}{1+y}=x⇔y=x\left(1+y\right)⇔y-xy=x⇔y\left(1-x\right)=x⇔y=\frac{x}{1-x}.$
The inverse will be given by
${f}^{-1}\left(x\right)=\frac{x}{1-x}.$
Step 2
Let us check how this works:
$f\left({f}^{-1}\left(x\right)\right)=\frac{{f}^{-1}\left(x\right)}{1+{f}^{-1}\left(x\right)}=\frac{x/\left(1-x\right)}{1+\left(x/\left(1-x\right)}=\frac{x/\left(1-x\right)}{\left(1-x+x\right)/\left(1-x\right)}=\frac{x/\left(1-x\right)}{1/\left(1-x\right)}=x.$
Of the other hand:
${f}^{-1}\left(f\left(x\right)\right)=\frac{f\left(x\right)}{1-f\left(x\right)}=\frac{x/\left(1+x\right)}{1-\left(x/\left(1+x\right)\right)}=\frac{x/\left(1+x\right)}{\left(1+x-x\right)/\left(1+x\right)}=\frac{x/\left(1+x\right)}{1/\left(1+x\right)}=x.$
In general, if $f:X⟶Y$ is bijective then ${f}^{-1}$ will have Y as domain, and X as image.
Finally, if $f:X⟶Y$ and $g:Y⟶Z$ are surjective then $g\circ f:X⟶Z$ is surjective. In fact, given $z\in Z$ there exists $y\in Y$ such that $g\left(y\right)=z$ since g is surjective. Once f is surjective, there exists $x\in X$ such that $f\left(x\right)=y$. Hence, the element $x\in X$ is such that
$\left(g\circ f\right)\left(x\right)=g\left(f\left(x\right)\right)=g\left(y\right)=z,$
that is, every element of Z is in the imagem of $g\circ f$, this show $Z\subset \text{Im}\left(g\circ f\right)$. Since, $\text{Im}\left(g\circ f\right)$ is always a subset of Z, it follows $Z=\text{Im}\left(g\circ f\right)$, therefore $g\circ f$ is surjective.