Proving set propertiesThis lecture will continue on
Material from book: 3.3. SubsetsGiven two sets
Two sets are equal, i.e, Power SetsThe power set of a set Let us first see some examples of power sets: 1. 2. Take the empty set. Its power set is What is the difference between the empty set and set containing it? It is easy to explain through code. Here is code to create empty set in C++ (you can write equivalent in Java): Empty Set
set<int> * s = new set<int>(); // Create an empty set. assert( s-> size() == 0); // s has no elements Here is how we create a set containing the empty set. Set containing the empty set
set<int> * emptySet = new set<int>(); // Create empty set. set< set<int>* > * emptyEmptySet = new set< set<int> > (); emptyEmptySet -> insert (emptySet); // Put the empty set into the empty empty. assert( emptyEmptySet -> size() == 1); // The size of the set containing the empty set is 1. As you can see from the illustration above, the sets Counting the Elements of the Power SetIf set Let us take a smaller example
Note: We have established a one-one correspondence between the power set of
What about We have derived sufficient evidence to write the following theorem: Theorem: The power set of We can prove this claim in various ways. The one-one correspondence between elements of the power set and binary strings of
This naturally brings us to the topic of functions and one-to-one correspondences. Before that, we take a small diversion to define a partition here. It will be useful later when we study equivalence classes. PartitionA parition, formalizes the idea of dividing up the elements of a set into A partition of a set
True or False: Any partition FactoidHere is a problem about partitions: You are given a set of numbers This problem has applications all over the place but is known to be a hard problem (as hard as factoring integers). Proving Properties of SetsWe are often asked to prove certain relations between two sets: they are the same or that one is a subset of another. These proofs tend to be simple provided our approach to them is systematic. Here are a couple of examples: Example-1Claim For any three sets Proof
To prove that two sets are the same, we show that each one is the subset of the other.
Example-2Claim Given two sets Notice that the claim is an if and only if claim. Such claims are actually two subclaims in disguise. We need to prove each of them.
Proof of Subclaim-1:
Let To show
Proof of Subclaim-2
For any two sets
This however, contradicts our assumption that |