# How to prove $A \cap B$ = $A \cup B \iff A = B$?

Trying to prove that the union and intersection of two sets $A$ and $B$ are equal if and only if $A= B$ ($A \cap B$ = $A \cup B$ iff $A = B$). I initially started by saying letting $x \in A$. Then $A \subset A \cup B$. However, I think that starting like this is inadequate and will not lead to an adequate or logically sound proof. Any suggestions on how I should proceed?

$A\subset A\cup B=A\cap B\subset B$ and $B\subset A\cup B=A\cap B\subset A$.

• Why is $A\subset A\cup B=A\cap B\subset B$ so? Dec 20, 2015 at 0:30
• @dreamin: $A\subset A\cup B$ is a property of $\cup$. $A\cup B=A\cap B$ by assumption. $A\cap B\subset B$ is a property of $\cup$. Note that this proves only one direction, but the other direction works essentially the same. Dec 20, 2015 at 9:58

The side $[A\cup B\subseteq A\cap B]\implies A = B$ is "this question". The other side is very easy because, if $A=B$, then $A \cap B=A \cap A=A$ and $A \cup B=A \cup A=A.$

Hint: Supposed that $A\neq B$, then there is $x\in A$, and $x\notin B$, or $x\in B$, and $x\notin A$, you have a contradiction.

i. $x\in A$, and $x\notin B$. If $x\in A\implies x\in A\cup B\implies x\in A\cap B$, then $x\in A$, and $x\in B$ $(\Rightarrow\Leftarrow)$

ii. $x\in B$, and $x\notin A$. If $x\in B\implies x\in A\cup B\implies x\in A\cap B$, then $x\in A$, and $x\in B$ $(\Rightarrow\Leftarrow)$

Therefor $A=B$.

Following that
$$A = B \iff \forall a \in A, a \in B$$ $$A = B \iff \forall b \in B, b \in A$$

The proof can also go like: Suppose that $A \neq B$. Then $\exists a \in A$ such that $a \notin B$ or $\exists b \in B$ such that $b \notin A$. Assume then that $\exists a \in A$ such that $a \notin B$. Then, $a \notin A\cap B$ but $a \in A \cup B$. So $A \cup B \neq A \cup B$.

Since the original statement is a bidirectional implication, the proof should written "both ways". So the second part could go: Assume $A = B$. Then $A \cup B = A$ and $A \cap B = A$. So, $A \cup B = A \cap B$.