Set Operations

Union

The union of two sets is defined as the set of all elements in either set. We can write the union of two sets in set-builder notation as AB = { x | xA or xB }.

Union of Sets

Difference

The difference of two sets is defined as the set of all elements in the first set but that are not in the second set. We can write the difference of two sets in set-builder notation as A - B = { x | xA and xB }.

Difference of Sets

Intersection

The intersection of two sets is defined as the set of all elements in both sets. We can write the intersection of two sets in set-builder notation as AB = { x | xA and xB }.

Intersection of Sets

Complement

The complement of a set is defined as the set of all elements in the universal set that are not in the set itself. We can write the complement of a set in set-builder notation as U - A = { x | xU and xA } or as -A = { x | xA } when the universal set is implied.

Complement of a Set

Symmetric Difference

The symmetric difference of two sets is defined as the set of all elements in either set but not in both sets. We can write the symmetric difference of two sets in set-builder notation as AB = { x | xA - B or xB - A }.

Symmetric Difference of Sets