[Math] Demonstrate that if $f$ is surjective then $X = f(f^{-1}(X))$

discrete mathematicselementary-set-theoryfunctions

I haven't been able to do this exercise:

Let $f: A \rightarrow B$ be any function. $f^{-1}(X)$ is the inverse
image of $X$. Demonstrate that if $f$ is surjective then $X = f(f^{-1}(X))$ where $X \subseteq B$.

Since $X \subseteq B$, all the elements in $X$ belong to the codomain of $f$.

Since $f$ is surjective, it means that all elements in the codomain $B$ have some preimage in $A$. Given that $X \subseteq B$, all elements in $X$ must also have a preimage in $A$.

Have $\triangle = f^{-1}(X)$, $\triangle$ is now a set containing the preimages of the elements in $X$. Because of this, $\triangle \subseteq A$.

If we evaluate $f(\triangle)$, we…… nope, I don't know what I'm doing now.


What do you think?

Best Answer

In this cases double inclusion is the way: let $x \in f(f^{-1}(X))$, then there is $a \in f^{-1}(X)$ such that $f(a) = x$. By definition of the pre image, $x \in X$. This gives $$f(f^{-1}(X)) \subset X.$$ Note that we didn't use that the function is surjective to prove this inclusion, meaning that it holds in general.

Now let $x \in X$. Being $f$ surjective, we can find $a \in A$ such that $f(a) = x$. This gives $a \in f^{-1}(X)$ and hence $x = f(a) \in f(f^{-1}(X))$. This shows $$X \subset f(f^{-1}(X)).$$