# Show that $X-Y = X \cap \overline{Y}$

Very basic problem, just wanted to be sure I did this correctly. The problem is "Show that $X-Y = X \cap \overline{Y}$". There was hint in the problem telling one to let our universe $U=X \cup Y$. Here's my work:

Notation: $\overline{A}$ is the complement of a set, $A$, and the operator $-$ is meant to be a set difference, so that give two sets, $A,B$ we have $A-B=\{x\in A : x\not\in B\}$.

$$X \cap \overline{Y} = X \cap [(X\cup Y)-Y]$$ $$=X \cap [(X-Y)\cup(Y-Y)]$$ $$=X \cap [(X-Y) \cup \emptyset]$$ $$=X \cap (X-Y)$$ $$=X-Y$$ $$\implies X \cap \overline{Y}=X-Y$$

Q.E.D

I think I got it. It seemed really trivial, considering the whole "let $U=X \cup Y$" bit. Just wanted to be sure I didn't overlook anything

-
What's the bar over in this context mean? – Nameless Jul 21 '14 at 1:27
Can you define your terminology? Is the $-$ supposed to be a set difference or a translate? Your notation $\overline{Y}$ usually means "closure" but I think you want $Y^c$, the complement of $Y$. – Adam Hughes Jul 21 '14 at 1:28
@Nameless I'm almost certain he means that to be the set difference, what I would write: $X\setminus Y$. – Adam Hughes Jul 21 '14 at 1:29
Sorry when I first began seeing set theory from another book, $\overline Y$ denoted a complement. I did indeed mean $Y^c$, now realizing that that is standard notation – user146925 Jul 21 '14 at 1:30
@user146925 your proof looks OK, assuming the edits I made to clarify notation are correct. – Adam Hughes Jul 21 '14 at 1:31

To prove set equality one needs to show that each set is a subset of the other. That is, $$A=B \, \, \iff\left(A\subseteq B\right)\, \land \left(B\subseteq A\right)$$

So, to prove problem presented we need to show $X \cap Y^{c} \subseteq X\setminus Y$ and $X\setminus Y \subseteq X \cap Y^{c}$

Proof:
Part 1: $X \cap Y^{c} \subseteq X\setminus Y$
Assume: $x \in X \cap Y^{c} \quad$ Show: $x \in X\setminus Y$
So by definition of set intersection, $x \in X$ and $x \in Y^{c}$
Set complement is defined as $Y^{c} = U \setminus Y$, so $x \in U$ and $x \notin Y$, where $U$ is defined to be our universe.
So, $x \in X$ and $x \notin Y$
So by the definition of set difference, $x \in X\setminus Y$

Part 2: $X\setminus Y \subseteq X \cap Y^{c}$
Assume: $x \in X\setminus Y \quad$ Show: $x \in X \cap Y^{c}$
So by the definition of set difference, $x \in X$ and $x \notin Y$
Trivially (assuming well-defined sets), $x \in U$, where $U$ is our universe.
So, $x \in U$ and $x \notin Y$, which by the definition of set difference implies $x \in U \setminus Y$
Set compliment is defined as $Y^{c} = U \setminus Y$, where $U$ is defined to be our universe.
Therefore, since $x \in U \setminus Y$, $\, \, x \in Y^{c}$
Since $x \in X$ and $x \in Y^{c}$ and by the definition of set intersection, $x \in X \cap Y^{c}$
$\Box$

-