# Prove that when $f(A) \subseteq f(B)$ doesn't always mean that $A \subseteq B$

How to prove, when $f(A) \subseteq f(B)$ doesn't "always" mean that $$A \subseteq B$$

when $f\colon X \to Y$ is total function (not partial)

• Note that in each of the answers below, we are dealing with functions that are not one-to-one. It's a good exercise to show that a function $f:X\to Y$ is one-to-one if and only if $f(A)\subseteq f(B)$ always means $A\subseteq B$ for $A,B\subseteq X.$ Nov 5, 2013 at 14:38

take $f$ to be a real valued constant function defined on the set of all real numbers, ie $f(x) = 1$ for all real $x$. then the relation $f(A) \subset f(B)$ is always satisfied
Consider the function $f(x) = x^2$, $A = \mathbb R,\; B= \mathbb R_{\geq 0}$.
$f(A) = f(B),$ but $A \not\subseteq B$.
• i thought about this too, but the problem is in the defination of the total function which says that $\forall x \in X$, $\exists$ exactly one $y \in Y$, in your example $f(2) = f(-2) = 4$ \|f^(-1)(4)\| > 1$Nov 5, 2013 at 14:31 • I think you're misunderstanding total function vs. partial function. A total function is a function: it maps every$x$in the domain to some$y$in the codomain. This does not require that the function be one-to-one, which is what you are implying. Nov 5, 2013 at 14:36 • Good points. +) Nov 5, 2013 at 15:13 Consider$f: \mathbb R \to \mathbb R^+, x\mapsto x^2$And then see $$f([0, 2]) = f([-2, 0])$$ Take$X=\{1,2\}$,$Y=\{y\}$and$f(1)=f(2)=y$(no ambiguity). Then$f(\{1\})=f(\{2\})=Y$. Just consider the map$f:\mathbb{R}\rightarrow \left\{0\right\}$, and any two disjoint stes in$\mathbb{R}$. For example, consider$I=\left[0,1\right]$and$J=\left[-1,0\right)$. Clearly$I\cap J=\emptyset$and$f(I)=\left\{0\right\}\subseteq f(J)=\left\{0\right\}$. Hence,$f$,$I$, and$J\$ are a counterexample for the given proof.