Is $f(A)\cap f(B)$ a subset of $f(A\cap B)$? Let $X$ and $Y$ be sets and let $f\colon X\to Y$ be a function from $X$ to $Y$. If $A$ and $B$ are subsets of $X$, is it true that 
$f(A)\cap f(B)$ is a subset of $f(A\cap B)$?
If so, prove your answer; otherwise, provide a counterexample. 
If we assume that $f$ is injective, is the above inclusion true?
If we assume that $f$ is surjective, is the above inclusion true?
If we assume that $f$ is bijective, is the above inclusion true?
My thoughts: 
No, it is not true. Counterexample, consider sets $A = \{1,2\}$ and $B = \{2,3\}$. Let $f\colon A\to B$ where $1$ maps to $4$, $2$ to nothing, and $3$ maps to $4$ and $5$. 
Then $f(\{1,2\})\cap f(\{2,3\}) = \{4\}\cap\{4,5\} = \{4\}$. However, $f(\{1,2\}\cap\{2,3\}) = f(\{2\}) = \varnothing$. $\{4\}$ is not a subset of the empty set.
I think it's true if the function is injective (and also bijective obviously) but not surjective. 
 A: Your definition of $f$ is awkward. First of all $f$ is supposed to be defined on $A$, but the domain of $f$ seems to be $\{1,3,4\}\neq A$, and the range of $f$ which should be a subset of $B$ is $\{4,5\}$. Moreover, $f(3)$ is both $4$ and $5$.
So $f$ is not well-defined at all. But the idea behind your suggestion is in fact plausible. Let's fix $f$ first.
We can take $X=\{1,2\}$ and $Y=\{1\}$ and define $f(1)=f(2)=1$. Now taking $A=\{1\}$ and $B=\{2\}$ we obtain that $f(A\cap B)=\varnothing$ while $f(A)\cap f(B)=\{1\}$. Which is indeed a counterexample.
If you look closely this example is also surjective. So this rules out surjectivity as a possible solution. What about injectivity?
If $f$ is injective, and $y\in f(A)\cap f(B)$ then there is some $a\in A$ and $b\in B$ such that $f(a)=f(b)=y$, using injectivity we obtain that $a=b$ and therefore $a\in A\cap B$ so $y\in f(A\cap B)$. And this establishes the inclusion; and since it holds for injectivity it will hold for bijective functions as well.
A: 
More thorough
If $c \in f(A) \cap f(B)$ then $c \in f(A)$ and $c \in f(B)$.  So there exisits a $a \in A$ s.t. $f(a) = c$ and there is a $b \in B$ s.t. $f(b) = c$ and $f(a) = f(b)=c$.
That's fine... but that's all it is.
Does it follow that $c \in f(A\cap B)$?  In other words does it follow that there is a $d \in A\cap B$ such that $f(d) = c$?  Not really, maybe we can find an $a \in A \cap B^c$ where $f(a) = c$ and a $b \in B \cap A^c$ where $f(a) = c$ but there are no $d \in A \cap B$ where $f(d) = c$.  Is that possible.
Sure. take $f(x) = |x|$.  Let $A = (-\infty, 0)$ and $B = (0, \infty)$ and $A \cap B = \emptyset$.  If $a > 0$ then $-a \in A$ and $a = f(-a) \in f(A)$.  $a = f(a) \in f(B)$.  So $a \in f(A) \cap f(B)$ but $a \not \in f(A\cap B) = \emptyset$.
So $f(A) \cap f(B)$ need not be $ \subseteq f(A\cap B)$ .

But what if $f$ is injective?  That is.  If $f(a) = f(b) = c$ then it must be that $a = b$.
If $c \in f(A) \cap f(B)$ then $c \in f(A)$ and $c \in f(B)$.  So there must exists an $a \in A$ such that $f(a) = c$.  And there exists a $b \in B$ such that $f(b) = c$.  But that means $a = b$  That means $a=b \in A \cap B$.  So $c \in f(A \cap B)$.  
So if $f$ is injective $f(A) \cap f(B) \subseteq f(A \cap B)$.

What if $f$ is surjective?  Well, surjectivity really doesn't have anything to do with anything.  
We can, after all, redefine $f:X \rightarrow Y$ as $g:X \rightarrow g(X)$ and $g$ is magically surjective.
But... A better example might be $f(x) = (x - 1)(x + 1)(x - 2)$.  That's surjective.  Let $A = (-2,0)$ so $f(-1) = 0 \in f(A)$ and let $B = (0, 2)$ and so $f(1) = 0 \in f(B)$.  So $0 \in f(A) \cap f(B)$ but $A \cap B = \emptyset$ and, once again, $0 \not \in f(A \cap B) = \emptyset$.  
So it doesn't need to hold for $f$ surjective.

If $f$ is a bijection then $f$ is injective and it has to hold.
A: It looks like the converse is true. Since If $x$ is in both $A$ and $B$, then $f(x)$ is in both $f(A)$ and $f(B)$ so this means $f(A \cap B)$ is a subset of $f(A) \cap f(B)$. 
To get an example that $f(A\cap B)\neq f(A)\cap f(B)$, Take $A = (-1, 0), B = (0, 1)$. Let $f(x) = x^2$. So $f(A \cap B)=f(\{0\})=0$, but $f(A) = f(B) = \{0, 1\}$ .
A: For sets $S$ and $T$, 
$f(S\cup T) = f(S) \cup f(T).$
Since $A = (A\cap B) \cup (A\setminus B)$,
$f(A) = f(A\cap B) \cup f(A\setminus B)$.
Similarly, $f(B) = f(A\cap B) \cup f(B\setminus A)$.
Therefore
\begin{align}
f(A) \cap f(B)
&= (f(A\cap B) \cup f(A\setminus B)) \cap (f(A\cap B) \cup f(B\setminus A))\\
&= (f(A\cap B) \cap f(A\cap B))
    \cup (f(A\cap B) \cap f(B\setminus A)) \\
& \qquad  \cup (f(A\setminus B) \cap f(A\cap B))
    \cup (f(A\setminus B) \cap f(B\setminus A)) \\
&= f(A\cap B) \cup (f(A\setminus B) \cap f(B\setminus A)).
\end{align}
So $f(A\cap B) \subseteq f(A) \cap f(B)$, but the reverse direction
holds only if $f(A\setminus B) \cap f(B\setminus A) = \emptyset$.
If there exist an
$x \in f(A\setminus B)$ and a $y \in f(B\setminus A)$
such that $f(x) = f(y)$, then $f(x) \in f(A\setminus B) \cap f(B\setminus A)$
and $f(A) \cap f(B) \not\subseteq f(A\cap B)$.
But if there do not exist any such $x$ and $y$,
then $f(A\setminus B)$ and $f(B\setminus A)$ are disjoint, and
$f(A) \cap f(B) \subseteq f(A\cap B)$.
This is an indication how to construct a counterexample such that
$f(A) \cap f(B) \not\subseteq f(A\cap B)$.
It is possible to construct a surjective $f$ that serves as such a
counterexample, provided that $f$ is not also injective.
But if $f$ is injective, the existence of such a
counterexample is ruled out.
A: Not in the least. Take $f : X\rightarrow Y$ with 
$$
X=Y=\{0,1\};\ f(0)=f(1)=0\ ; A=\{0\};\ B=\{1\}\ .
$$
A: No. $f(a)$ is in $f(A)$ intersect $f(B)$ iff $f(a)$ is the image of some $a$ in $A$ and $f(a)$ is the image of some $b$ in $B$. It is not given that $a=b$ and when $f$ is not 1-1 you can always construct $A$, $B$ such that this fails.
