Set Difference as Intersection with Relative Complement

From ProofWiki
Jump to navigation Jump to search

Theorem

Let $A, B \subseteq S$.


Then the set difference between $A$ and $B$ can be expressed as the intersection with the relative complement with respect to $S$:

$A \setminus B = A \cap \relcomp S B$


Proof

\(\displaystyle A \setminus B\) \(=\) \(\displaystyle \set {x: x \in A \land x \notin B}\) Definition of Set Difference
\(\displaystyle \) \(=\) \(\displaystyle \set {x: \paren {x \in A \land x \in X} \land x \notin B}\) Definition of Subset, Modus Ponens and Rule of Conjunction
\(\displaystyle \) \(=\) \(\displaystyle \set {x: x \in A \land \paren {x \in X \land x \notin B} }\) Conjunction is Associative
\(\displaystyle \) \(=\) \(\displaystyle \set {x: x \in A \land x \in \relcomp S B}\) Definition of Relative Complement
\(\displaystyle \) \(=\) \(\displaystyle A \cap \relcomp S B\) Definition of Set Intersection

$\blacksquare$


Sources