How many subsets containing 5 elements can be formed from the set?
I have encountered this problem in one of my books on discrete mathematics: How many subsets of the set {1, 2, 3, 4, 5, 6, 7, 8, 9} contains exactly two odd numbers? There is no restriction on how many even numbers the subset can contain. Show
I quickly realized that the number subsets of the set is so large that is stupid to solve it by just writing and counting it. I solved it using Python instead, like you can see in the attached image file. But now I want to know how you can solve it with just math? There must be a proper way to solve problems like these. If I programmed it correctly then the correct answer is 160. Please help, thanks. Please read Introduction to Sets first! This activity investigates how many subsets a set has. What is a Subset?A subset is a set contained in another set It is like you can choose ice cream from the following flavors: {banana, chocolate, vanilla} You could choose any one flavor {banana}, {chocolate}, or {vanilla}, Or any two flavors: {banana, chocolate}, {banana, vanilla}, or {chocolate, vanilla}, Or all three flavors (no that isn't greedy), Or you could say "none at all thanks", which is the "empty set": {} Example: The set {alex, billy, casey, dale}Has the subsets:
It also has the subsets:
Also:
And also:
Now let's start with the Empty Set and move on up ... The Empty SetHow many subsets does the empty set have? You could choose:
But, hang on a minute, in this case those are the same thing! So the empty set really has just 1 subset (which is itself, the empty set). It is like asking "There is nothing available, so what do you choose?" Answer "nothing". That is your only choice. Done. A Set With One ElementThe set could be anything, but let's just say it is: {apple} How many subsets does the set {apple} have?
And that's all. You can choose the one element, or nothing. So any set with one element will have 2 subsets. A Set With Two ElementsLet's add another element to our example set: {apple, banana} How many subsets does the set {apple, banana} have? It could have {apple}, or {banana}, and don't forget:
So a set with two elements has 4 subsets. A Set With Three ElementsHow about: {apple, banana, cherry} OK, let's be more systematic now, and list the subsets by how many elements they have: Subsets with one element: {apple}, {banana}, {cherry} Subsets with two elements: {apple, banana}, {apple, cherry}, {banana, cherry} And:
In fact we could put it in a table:
(Note: did you see a pattern in the numbers there?) Sets with Four Elements (Your Turn!)Now try to do the same for this set: {apple, banana, cherry, date} Here is a table for you:
(Note: if you did this right, there will be a pattern to the numbers.) Sets with Five ElementsAnd now: {apple, banana, cherry, date, egg} Here is a table for you:
(Was there a pattern to the numbers?) Sets with Six ElementsWhat about: {apple, banana, cherry, date, egg, fudge} OK ... we don't need to complete a table, because... ... you should be able to see a pattern by now! DoublingThe first thing to notice is that the total number of subsets doubles each time: A set with n elements has 2n subsets So you should be able to answer:
Another PatternNow let's think about subsets and sizes:
Do you recognize this pattern of numbers? They are the numbers from Pascal's Triangle! This is very useful, because now you can check if you have the right number of subsets. Note: the rows start at 0, and likewise the columns. Example: For the set {apple, banana, cherry, date, egg} you list subsets of length three:
But that is only 4 subsets, how many should there be? Well, you are choosing 3 out of 5, so go to row 5, position 3 of Pascal's Triangle (remember to start counting at 0) to find you need 10 subsets, so you must think harder! In fact these are the results: {apple,banana,cherry} {apple,banana,date} {apple,banana,egg} {apple,cherry,date} {apple,cherry,egg} {apple,date,egg} {banana,cherry,date} {banana,cherry,egg} {banana,date,egg} {cherry,date,egg} Calculating The NumbersIs there a way of calculating the numbers such as 1, 4, 6, 4 and 1 (instead of looking them up in Pascal's Triangle)? Yes, we can find the number of ways of selecting each number of elements using Combinations. There are four elements in the set, and:
Can you do the same for a set with five elements? Complete the following:
ConclusionIn this activity you have:
More importantly you have learned how different branches of mathematics can be combined together. How many subsets of a set has containing 5 elements?A set containing n elements has 2n subsets and 2n - 1 proper subset. The given set {1, 2, 3, 4, 5} contains 5 elements. So, it has 25 = 32 subsets in all and 31 proper subsets.
How many 5 elements are there?There are (n−k+1k) subsets of {1,2,3…n} with k elements and no two consecutive. Since it has an inverse it is bijective and so the proof is established. Hence there are (145) total and (105) with no consecutive terms. So the final answer is (145)−(105)=1750.
How many 3 element subsets can be formed from a set of 5 elements?It's the number of three-element subsets that can be formed from the set {B, C, D, E, F, G}, which is 5 + 4 + 3 + 2 + 1 = 5 * 6 / 2 = 15.
How many subsets of 5 elements does a set of 7 elements have?The number of subsets of S with at most 5 elements = 128-7-1 =120. Q. A set S has 7 elements.
|