Prove that equality holds only if $f$ is one-to-one. I am just looking for a hint. Not a solution as I am just trying to solve these for fun. 
Let $f:A \rightarrow B$ with $A_0 \subset A$ and $B_0 \subset B$. Show that $$A_0 \subset f^{-1}(f(A_0))$$ but equality holds only if $f$ is injective.
Here is what I am thinking so far. I will choose two points $a_0,a^{\prime}_0 \in A_0$ with $a_0 \ne a^{\prime}_0$ and $f(a_0)=f(a^{\prime}_0)$. We have $$f^{-1}(f(a_0)) \in A_0 \implies a_0 \in f^{-1}(f(A_0))$$ $$f^{-1}(f(a^{\prime}_0)) \in A_0 \implies a^{\prime}_0 \in f^{-1}(f(A_0)) $$ $$\implies A_0 \subset f^{-1}(f(A_0)) $$ but $$f^{-1}(f(a_0)) \ne f^{-1}(f(a^{\prime}_0))$$
I am sort of stuck here. It looks as though I chose points that are both in the subset $A_0$ but it is possible that the pre-image of one may be outside of $A_0$ making the reverse containment impossible unless $f$ is one-to-one.
 A: Hope you've solved it by now, but here is a complete proof for others who may find themselves looking for answers
Showing the first inclusion is straight forward
def. $f(A) = \{f(x) : x \in A \}$
def. $f^{-1}(B) = \{x : f(x) \in B \}$


*

*$x \in A \subset X$

*$f(x) \in f(A)$

*$f^{-1}(f(A)) = \{x : f(x) \in f(A) \}$

*$x \in f^{-1}(f(A))$

*$A \subset f^{-1}(f(A))$


Now all that needs to be shown is that if $f$ is injective $A \supset f^{-1}(f(A))$
def. $f:X \rightarrow Y$ is injective $\Leftrightarrow (f(x)=f(y) \implies x = y)$
Proof by contradiction. Assume the opposite


*

*$A \not \supset f^{-1}(f(A))$ 

*$\exists x \in f^{-1}(f(A)) : x \not \in A$

*$x \in f^{-1}(f(A))$ and $x \not \in A$

*$f(x) \in f(A)$ and $x \not \in A$

*$y \in f(A) \Leftrightarrow \exists z\in A : f(z)=y$

*$\exists z \in A : f(z) = f(x)$

*$z = x$

*$x \in A$ contradiction


Thus we have $A \supset f^{-1}(f(A))$ and thereby $A = f^{-1}(f(A))$
A: For the $A_0 \subseteq f^{-1}(f(A_0))$, you don't need to consider two points. Take $a_0 \in A_0$ and check that $a_0 \in f^{-1}(f(A_0))$. Look at $f(a_0)$, where is this element?
For the $f^{-1}(f(A_0))\subseteq A_0$ part assuming injectivity, take $a_0 \in f^{-1}(f(A_0))$. So $f(a_0) \in f(A_0)$. This doesn't mean that $a_0 \in A_0$. Now you use the definition of the set $f(A_0)$, and follow up with injectivity.
Think about it a little and call me in the comments if you need more help.
A: Here's an example which should help. Let $f(x)=x^2$ and consider $f^{-1}(f(\{2\}))$.
$$f^{-1}(f(\{2\}))=f^{-1}(\{4\})=\{2,-2\}.$$
$f^{-1}(f(2))$ has an element which $\{2\}$ doesn't precisely because $f$ is not one-to-one.
