# If $f$ is 1-1, prove that $f(A\setminus B) = f(A)\setminus f(B)$

I'm having a tough time with this one. Here's the background:

Let $X$ and $Y$ be sets, let $f:X\rightarrow Y$ and let $A,B\subseteq X$. For this proof, we also assume that $f$ is 1-1.

I've already proven $f(A\setminus B)\supseteq f(A)\setminus f(B)$, but where should I start to prove the other way around?

To show that $f(A\setminus B) \subset f(A) \setminus f(B)$, show that each element of the first lies in $f(A)$, but not in $f(B)$. You need injectivity for this.
Take an arbitrary element, $x\in F(A-B)$. Then $\exists y\in A:y\notin B$and $f(y)=x$. Thus, $x\in F(A)$. But since F is injective, y is the only preimage, and since $y \notin B$, $x \notin F(B)$
Choose $y \in f(A \setminus B)$ then there exists $x \in A \setminus B$ such that $y = f(x)$. Observe that $f(x) \in f(A)$ since $A \setminus B \subseteq A$. Now why is $y \notin f(B)$? If it were, say $y \in f(B)$ then $y = f(x')$ for some $x' \in B$. But then we have $f(x) = y = f(x')$ and by injectivity we have $x = x'$. This means that $x' \notin B$, a contradiction. Conclude that $y \notin f(B)$ and hence $y \in f(A) \setminus f(B)$.
• "Since $A \setminus B \subseteq B$" this can't be right; what if $B = \emptyset$? I think you mean $A \setminus B \subseteq A$. – goblin Sep 25 '14 at 5:51