• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Login
Forum — Daily Challenge
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Login

Additional question: how do you find subsets of a set?

Week 3
2
2
14
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T
    The Blade Dancer M0★ M1★ M2★ M3★ M4 M5
    last edited by Sep 16, 2020, 12:58 AM

    Additional question: how do you find subsets of a set? How do those subsets work?

    The Blade Dancer
    League of Legends, Valorant: Harlem Charades (#NA1)
    Discord: Change nickname if gay#7585

    D 1 Reply Last reply Sep 16, 2020, 2:49 AM Reply Quote 1
    • D
      debbie ADMIN M0★ M1 M5 @The Blade Dancer
      last edited by debbie Sep 16, 2020, 2:55 AM Sep 16, 2020, 2:49 AM

      @The-Blade-Dancer Finding the number of subsets of a set is often affectionately, and perhaps even more clearly, explained, using the mnemonic of "counting the number of pizzas you can make with nnn toppings." 🍕 🍕 Does the pizza make this problem easier to understand? Definitely yes!! 🙂

      So please don't be alarmed if you see pizza 🍕 , pepperoni, mushrooms 🍄, bell peppers 🌶, or sausage sprinkled throughout this post.

      In addition to appearing in counting questions, this sort of problem pops up in number theory questions that ask things like, "How many factors does this number have?" So, it's a very useful and general concept that can be applied to a variety of problems.

      I'm going to begin by starting at what seems to be the middle of the problem. Suppose I have a set of toppings: {a,e,i,o, and u}. \{ \textcolor{red}{a, e, i, o, } \text{ and } \textcolor{red}{u} \}.{a,e,i,o, and u}. (Maybe it's an exotic pizza restaurant, so its toppings are a\textcolor{red}{a}anchovy 🐟 ,    e\text{ } \text{ } \text{ } \textcolor{red}{e}   endive, i\textcolor{red}{i}italian sausage, o\textcolor{red}{o}olives, and u\textcolor{red}{u}umami seasoning.)

      Choosing a subset of {a,e,i,o, and u} \{ \textcolor{red}{a, e, i, o, } \text{ and } \textcolor{red}{u} \}{a,e,i,o, and u} is equivalent to composing a pizza using any of the possible toppings, with no toppings being a possible option.

      All of the possible pizzas are shown below, with each pizza's toppings listed beneath it.

      M3W3-aeiou-pizzas.png

      Now let's add a new topping, h,\textcolor{red}{h},h, called "Prof. Loh's Favorite Hot Sauce."

      How many new pizzas can we make that we couldn't make before? Well, all we have to do is take one of the previous pizzas (or topping combinations, whichever way you want to think of it), and add our new topping h.\textcolor{red}{h}.h.

      Below I've illustrated all of the previous pizzas on the left, and all of the new pizzas on the right. Note that each of the new pizzas now includes "Prof. Loh's Favorite Hot Sauce" splattered indiscriminately all over it.

      M3W3-aeiou-pizzas-new-topping.png

      You can see that by adding our new topping, h,\textcolor{red}{h},h, we have doubled the number of pizzas that we can make.

      Similarly, adding a new element to a set doubles the number of subsets that you can make with all those elements.

      🍕 🍕 🍕 🍕 🍕

      Okay, now let's go back to the beginning! Let's start with only one topping (only one element).

      One topping

      Our topping menu looks like this: {a}.\{ \textcolor{red}{a}\}.{a}. The only topping is a\textcolor{red}{a}anchovy. We can make 222 different pizzas: 1.) a pizza with a\textcolor{red}{a}anchovy or 2.) a pizza with nothing. →2 possible pizzas \rightarrow \textcolor{red}{2} \text{ possible pizzas } →2 possible pizzas 

      Two toppings

      Our topping menu looks like this: {a,e}.\{ \textcolor{red}{a, e}\}.{a,e}. With our new topping, e\textcolor{red}{e}endive, we can make twice as many pizzas as we did when there was only one topping. →22 possible pizzas \rightarrow \textcolor{red}{2^2} \text{ possible pizzas } →22 possible pizzas 

      Three toppings

      Our topping menu looks like this: {a,e,i}.\{ \textcolor{red}{a, e, i}\}.{a,e,i}. We can make twice as many pizzas as we did when there were only two toppings. →23 possible pizzas \rightarrow \textcolor{red}{2^3} \text{ possible pizzas } →23 possible pizzas 

      Four toppings

      Our topping menu looks like this: {a,e,i,o}.\{ \textcolor{red}{a, e, i, o}\}.{a,e,i,o}. We can make twice as many pizzas as we did when there were only three toppings. →24 possible pizzas \rightarrow \textcolor{red}{2^4} \text{ possible pizzas } →24 possible pizzas 

      There's a neat pattern! It's that, for nnn toppings, we have 2n2^n2n possible pizzas that we can make. To use general language, this means that for nnn elements in a set, there are 2n2^n2n different subsets of those nnn elements that we can choose.

      The "switches" example 💡 💡 🚨

      Another way to see that the number of subsets of nnn things equals 2n2^n2n is to imagine that for each element in the set, there is a switch that turns it "on" or "off." There are two choices for each element. Thus the ways to arrange all the nnn switches equals 2n.2^n.2n.

      (2 choices for the 1st)×(2 choices for the 2nd)×(2 choices for the 3rd)×(2 choices for the 4th)… \left( 2 \text{ choices for the } 1^{\text{st}} \right) \times \left( 2 \text{ choices for the } 2^{\text{nd}} \right) \times\left( 2 \text{ choices for the } 3^{\text{rd}} \right) \times\left( 2 \text{ choices for the } 4^{\text{th}} \right) \dots (2 choices for the 1st)×(2 choices for the 2nd)×(2 choices for the 3rd)×(2 choices for the 4th)…

      You could also visualize the number of choices for each element by drawing a branching tree 🌲 that splits into a new branch level for every new element that there is. Each branch would split into two smaller branches, and thus the number of total ways (paths to an end-branch tip) would be equal to 2n.2^n.2n.


      🍕 I hope this helped! Please ask if you would like more diagrams or clarification about any of the ideas mentioned. You can also find more Daily Challenge lessons about subsets of nnn things by following the links below.

      Module 0 Week 2 Day 8 Challenge Part 1
      Module 3 Week 1 Day 2 Challenge Part 2

      1 Reply Last reply Reply Quote 2

      • 1 / 1
      1 / 1
      • First post
        1/2
        Last post
      Daily Challenge | Terms | COPPA