{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

Counting3 - 1.3 Of Sequences Permutations and Combinations...

Info icon This preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
1.3. Of Sequences, Permutations and Combinations 11 Example 28 Given the set of r symbols { a 1 ,...,a r } , how many different strings of length n > 0 exist that contain at least two a 1 ’s (allowing repetition)? Answer Recall that whenever you encounter “at least” you should consider using the rule of complements. The number of strings that contain at least two a 1 ’s equals the total strings that can be made less the number of strings that contain exactly one a 1 or no a 1 ’s. The total number of strings with repeats is r n . The number of strings with exactly one a 1 we saw in the last exercise is ( n 1) r n - 1 . The number of strings with no a 1 ’s is ( r 1) n . Thus, the answer is r n ( n 1) r n - 1 ( r 1) n . End of Answer Example 29 Given the set of r symbols { a 1 ,...,a r } , how many different strings of length n > 0 exist ( not allowing repetition)? Answer We recognize this as a permutation: P ( r,n ) = r ! ( r - n )! . Alternatively, you can argue from basic principles that there are r choices for the first entry in the strings, ( r 1) for the second, etc. So the answer is r ( r 1)( r 2) · · · ( r n + 1) = r ! ( r - n )! . End of Answer Example 30 Given the set of r symbols { a 1 ,...,a r } , how many different strings of length n > 0 exist that contain exactly one a 1 ? ( not allowing repetition)? Answer Recall that whenever a problem asks “How many strings are there with exactly a certain number of specified elements?” one can break the task into a sequence of three subtasks. The first subtask choses the places for the specified elements and counts how many ways these places can be chosen. In this example, the place for a 1 can be chosen in parenleftbigg n 1 parenrightbigg = n ! ( n - 1)!1! = n (“n choose 1”) ways. The second subtask fills the places and counts how many ways they can be filled. In this example that is 1 (for the one place there is only one choice). The third subtask fills the remaining places and counts how many ways they can be filled. In this example that is a permutation, P ( r 1 ,n 1) = ( r - 1)! (( r - 1) - ( n - 1))! = ( r - 1)! ( r - n )! The answer is therefore n ( r - 1)! ( r - n )! . End of Answer Example 31 Given the set of r symbols { a 1 ,...,a r } , how many different strings of length n > 0 exist that contain exactly at least one a 1 ? ( not allowing repetition)? Answer There are two answers. The first answer is to recognize that “at least one” when no repetition is allowed means “exactly one”. Thus, the answer is the same as for the last example. Alternatively, we can employ the rule of complements: The desired result is equal to the number of strings that can be made from the given set of without repetition, less the number of stings that do not contain a a 1 . The answer is P ( r,n ) P ( r 1 ,n ) = r ! ( r - n )! ( r - 1)! ( r - 1 - n )! = r ( r - 1)! ( r - n )! ( r n ) ( r - 1)! ( r - n )! = n ( r - 1)! ( r - n )! . End of Answer
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
12 Chapter 1. Counting Example 32 Given the set of r symbols { a 1 ,...,a r } , how many selections (subsets) of length n > 0 exist (ignoring order and not allowing repetition)?
Image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern