Clarification on what makes sets equal (from reading Rosen's Discrete Mathematics) I am having trouble understanding this excerpt from the book:
"Sets may have other sets as members. For instance, we have the sets
$A = \{∅, \{a\}, \{b\}, \{a, b\}\}$ and $B$ $=$ $\{$$x$ $|$ $x$ is a subset of the set $\{a, b\}$$\}$.
Note that these two sets are equal, that is, $A = B$. Also note that $\{a\} ∈ A$, but $a \not\subset A$."
I thought that for set $B$, $x$ being just a subset of $\{a,b\}$ meant that the set $\{a,b\}$ has all the elements of $B$, but not vice-versa, so that the set $B$ could just be $\{a\}$. So I don't understand how $A = B$ in this case. I am unsure what I am missing here. 
Thanks!
 A: The set $B$ isn’t itself a subset of $A$. Its elements are subsets of $A$. Translated into words the set builder notation in the definition of $B$ says “$B$ is the set that consists of all subsets of $A$.”
A: $B = \{x| $x is a subset of$ \{a,b\}\}$ means that every possible subset $x$ of $\{a,b\}$ is an element of $B$. Possible subsets of $\{a,b\}$ are $\{ \emptyset , \{a,b\}, \{a\}, \{b\} \}$, so $B=A$, because they contain the same elements. 
A: what it means for two sets to be equal, is that they contain the same elements:
$$A=\{ \emptyset,\{a\},\{b\},\{a,b\}\}$$
$$B=\{x|x \text{ is a subset of \{a,b\}}\}$$
all x that fit that condition B has are the empty set (subset of all sets, denoted $\emptyset$),$\{a\}$,$\{b\}$, and$\{a,b\}$. So B contains all of them, and doesn't contain any others. This is also true of A, so we are talking about the same set. 
A: "I thought that for set $B$, $x$ being just a subset of {a,b} meant that the set $\{a,b\}$ has all the elements of $B$,"
Notice you began the sentence talking about set $x$ and ended the sentence talking about set $B$.  Set $x$ and set $B$ are not the same set.
Let's start with $x$.  $x \subset \{a,b\}$.  It is possible that $x = \{a\}$.  (It is possible that $x$ is a different subset, but $x$ could be $\{a\}$.)  At any rate, yes, the set $\{a,b\}$ has all the elements of $x$.
Now let's talk about $B$.  $B = \{x|x \subset \{a,b\}\}$.  That's... fine.  $\{a\} \subset \{a,b\}$ so $\{a\} \in B$.  $\emptyset \subset \{a,b\}$.  So $\emptyset \in B$. 
And with a little effort we can see $B = \{\emptyset, \{a\}, \{b\}, \{a,b\}\} = A$.
Notice:  $A$ (and $B$) consist of the following four things:  1) $\emptyset$ 2) $\{a\}$ 3) $\{b\}$ and 4) $\{a,b\}$.
Notice: $A$ (nor $B$) do NOT contain the following:  $a$, $b$.  $a$ is not something that $A$ has.  $b$ is not something that $A$ has.  That is that $a$, the thing, is not the same thing as $\{a\}$ the set.
Now $a \in \{a,b\}$ but $a \not \in A$.  So $\{a\} \subset \{a,b\}$ but $\{a\} \not \subset A$.  Even though $\{a\} \in A$, $\{a\} \not \subset A$.  This is because being an element of something is not the same thing as being a subset of something.  This is the same thing as saying John Smith is a student at a university.  The honor roll is a list of students at the university.  John Smith is not a list of students at the university.  And the honor roll is not a student at the university.
Notice $\{\{a\}\} \subset A$.  But $\{\{a\}\} \ne \{a\}$.
