For theset {a,b,c}:
<span>The empty set {} is a subset of {a,b,c}And these are subsets: {a}, {b} and {c}And these are also subsets: {a,b}, {a,c} and {b,c}And {a,b,c} is a subset of {a,b,c}</span>And when we list all the subsets of S={a,b,c} we get the Power Set of {a,b,c}:
P(S) = { {}, {a}, {b}, {c}, {a, b}, {a, c}, {b, c}, {a, b, c} }
Think of it as all the different ways we can select the items (the order of the items doesn't matter), including selecting none, or all.
Example: The shop has banana, chocolate and lemon ice cream.
What do you order?
<span>Nothing at all: {}Or maybe just banana: {banana}. Or just {chocolate} or just {lemon}Or two together: {banana,chocolate} or {banana,lemon} or {chocolate,lemon}Or all three! {banana, chocolate,lemon}</span>Question: if the shop also has strawberry flavor what are your options? Solution later.
How Many SubsetsEasy! If the original set has n members, then the Power Set will have <span>2n</span> members
Example: in the {a,b,c} example above, there are three members (a,b and c).
So, the Power Set should have 23 = 8, which it does!
NotationThe number of members of a set is often written as |S|, so when S has n members we can write:
|P(S)| = 2nExample: for the set S={1,2,3,4,5} how many members will the power set have?
Well, S has 5 members, so:
|P(S)| = 2n = 25 = 32
You will see in a minute why the number of members is a power of 2
It's Binary!And here is the most amazing thing. To create the Power Set, write down the sequence of binary numbers (using n digits), and then let "1" mean "put the matching member into this subset".
So "101" is replaced by 1 a, 0 b and 1 c to get us {a,c}
Like this:
<span><span> abcSubset</span><span>0000{ }</span><span>1001{c}</span><span>2010{b}</span><span>3011{b,c}</span><span>4100{a}</span><span>5101{a,c}</span><span>6110{a,b}</span><span>7111{a,b,c}</span></span>Well, they are not in a pretty order, but they are all there.
Another Example<span>Let's eat! We have four flavors of ice cream: banana, chocolate, lemon, and strawberry. How many different ways can we have them?Let's use letters for the flavors: {b, c, l, s}. Example selections include:<span>{} (nothing, you are on a diet){b, c, l, s} (every flavor){b, c} (banana and chocolate are good together)etc</span></span>Let's make the table using "binary":<span><span> bclsSubset</span><span>00000{}</span><span>10001{s}</span><span>20010{l}</span><span>30011{l,s}</span><span>...... etc ..... etc ...</span><span>121100{b,c}</span><span>131101{b,c,s}</span><span>141110{b,c,l}</span><span>151111{b,c,l,s}</span></span>And the result is (more neatly arranged):
P = { {}, {b}, {c}, {l}, {s}, {b,c}, {b,l}, {b,s}, {c,l}, {c,s}, {l,s}, {b,c,l}, {b,c,s},
{b,l,s}, {c,l,s}, {b,c,l,s} }
<span><span>SymmetryIn the table above, did you notice that the first subset is empty and the last has every member?But did you also notice that the second subset has "s", and the second last subset has everything except "s"?</span><span> </span><span>In fact when we mirror that table about the middle we see there is a kind of symmetry.This is because the binary numbers (that we used to help us get all those combinations) have a beautiful and elegant pattern.</span></span>A Prime Example
The Power Set can be useful in unexpected areas.
I wanted to find all factors (not just the prime factors, but all factors) of a number.
I could test all possible numbers: I could check 2, 3, 4, 5, 6, 7, etc...
That took a long time for large numbers.
But could I try to combine the prime factors?
Let me see, the prime factors of 510 are 2×3×5×17 (using prime factor tool).
So, all the factors of 510 are:
<span>2, 3, 5 and 17,2×3, 2×5 and 2×17 as well, and2×3×5 and 2×3×17 and ..... aha! Just like ice cream I needed a Power Set!</span>And this is what I got:
<span><span> 2,3,5,17SubsetFactors of 510</span><span>00000{ }1</span><span>10001{17}17</span><span>20010{5}5</span><span>30011{5,17}5 × 17 = 85</span><span>40100{3}3</span><span>50101{3,17}3 × 17 = 51</span><span> ... etc ...... etc ...... etc ...</span><span>151111{2,3,5,17}2 × 3 × 5 × 17 = 510</span></span>
And the result? The factors of 510 are 1, 2, 3, 5, 6, 10, 15, 17, 30, 34, 51, 85, 102, 170, 255 and 510 (and −1, −2, −3, etc as well). See the All Factors Tool.
I couldn't resist making Power Sets available to you in an automated way.
So, when you need a power set, try Power Set Maker.