Basics of Counting Techniques

Post on 07-Nov-2014

360 views 0 download

Tags:

description

Before learning the basics of Probability Theory, one must have a good command of Counting Techniques

transcript

COUNTING TECHNIQUES

Efren A. Medallo

Why learn counting?

Counting techniques are the very bases of being able to find the different probabilities of events in any kind of situation.

Why learn counting?

This is not counting one-to-one but this is collectively counting all possible ways of a given instance. (Ex. Counting all 4-digit numbers whose digits are different among one another)

COUNTING TECHNIQUES

FCP Factorial Notation Permutation Combination

Fundamental Counting Principle

PROBLEM Liza brought 3 different pairs of pants and 4 shirts

in a camp. How many combinations of a shirt and a pair of pants can she choose from to wear?

Fundamental Counting Principle

Let’s name the shirts of Liza as Shirts A, B, C, and D. Let’s also name her pants as Pants 1, 2, and 3.

Let us now enumerate the possible combinations that Liza can wear.

Fundamental Counting Principle

The answer is there are 12 possible combinations.

We found the answer by drawing a diagram. But what if there are large numbers given in the problem (say, 179 pairs of pants and 83 shirts)?

Fundamental Counting Principle

If an independent event can occur in m ways, another independent event can occur in n ways, and another in p ways, then the total number of ways that all events can occur simultaneously is

n(E) = m ∙n∙p ways

Fundamental Counting Principle

In the given problem,

n(E) = 4 x 3 = 12 ways

Drill

How many 4 digit numbers are there that have no single digit repeated in it?

Solution

Let us analyze.

How many numbers (from 0-9) can fit in the first digit?

Solution

There are only 9. This is because 0 cannot be the first digit. If it were, then it would not be a 4-digit number anymore.

Solution

How about the second digit?

Here, zero can already be included, which makes 10 possibilities.

HOWEVER, in the problem, it is stated that digits must not be repeated.

Solution

Therefore, whatever was used on the first digit cannot be used on the second digit anymore, which gives us 9 possibilities.

Solution

How about the third digit?

Again here, we have ten possibilities, but we have to put into account what was used in the previous digits, so that makes 8.

Solution

In the last digit, since 3 digits have been used already, it is safe to say that there are only 7 possibilities.

Solution

All in all, we have

Digit 1st 2nd 3rd 4th

9 x 9 x 8 x 7

Answer: 4536 numbers

Tip

For every independent event, count carefully the number of possibilities before multiplying them.

Drill

How many three letter combinations can you make with the following conditions (separate)? a. Repetition is allowed b. Repetition is not allowed c. The first letter must be a vowel with no repetition

of letters d. There must be no vowel in the first two letters,

repetition is not allowed and the last letter must be a vowel.

Factorial Notation

The factorial of an integer k is the product of all integers from 1 to k.

This is usually denoted as k! read as “k factorial”

Factorial Notation

Examples: 7! = 7∙6∙5∙4∙3∙2∙1 = 5040 5! = 5∙4∙3∙2∙1 = 120

Properties of Factorial Notation

The factorial operation is NOT distributive. Ex. (5-3)! ≠ 5! – 3!

The factorial operation cannot be performed on non-integer numbers. Ex. (2.5)!, (√6)!

Properties of Factorial Notation

The factorial notation precedes multiplication and/or division. Ex. 5!3! ≠ (5∙3)! 8! / 2! ≠ (8/2)!

0! = 1

Properties of Factorial Notation

n! = n(n-1)!= n(n-1)(n-2)!= n(n-1)(n-2)(n-3)…(n-k+1)(n-k)!

This property is very crucial in making cancellations in factorial expressions.

Properties of Factorial Notation

Example

= 4896

Permutation

A permutation is an ordered arrangement of objects.

It tells us how many possible orders there can be given a number of objects.

In permutation, if all objects are distinct, then they cannot be repeated.

Permutation

Example How many ways can three books be arranged in a

shelf?

Possible ArrangementsABC BCA

ACB CAB

BAC CBA

Permutation

Take Note: Since order is essential, ABC is different from

ACB, and all other similar instances.

Permutation

Permutation is usually denoted by

nPr

read as “the permutation of n objects taken r at a time”

Permutation

The general formula for permutation is

nPr = n(n-1)(n-2)…(n-r+1)

or

Permutation

n is the total number of objects r is the number of objects in consideration

In the problem given, r=n

If r=n, the equation becomes

Drill

How many ways can you choose your top 2 senators from a list of 35 candidates?

Drill

Remember Liza and her clothes? Find the number of ways she can wear her clothes if the camp lasts for three days and she can only wear each garment once.

Permutation with Repetitions

If we were asked how many permutations we can get if we rearrange the letters of the word “cat”, we get 3!

What if we rearrange the letters of the word “dad”?

Permutation with Repetitions

Permutations of the word “dad” dad dda add

Permutation with Repetitions

Actually, there are still 3! permutations for the word “dad”. However, since we cannot distinguish the first ‘d’ from the second, then “dad” with the first ‘d’ first will be the same as “dad” with the second ‘d’ first.

This leaves us with 3 distinguishable permutations.

Permutation with Repetitions

The formula for finding the distinguishable permutations from n set of objects is

where a, b, and c are the number of times a particular object exists on n.

Drill

Example Find the number of distinguishable permutations of

the word “technicalities”

Circular Permutation

How many ways can 4 people line up?

The answer is 4P4 or 4! = 24 ways

Let us enumerate them.

Circular Permutation

ABCD BACD CABD DABCABDC BADC CADB DACBACBD BCAD CBAD DBACACDB BCDA CBDA DBCAADBC BDAC CDAB DCABADCB BDCA CDBA DCBA

Circular Permutation

Now, how many ways can these 4 people sit on a round table?

Circular Permutation

ABCD BACD CABD DABCABDC BADC CADB DACBACBD BCAD CBAD DBACACDB BCDA CBDA DBCAADBC BDAC CDAB DCABADCB BDCA CDBA DCBA

Look closely at the bold italicized letters. If theyare arranged in a circular manner, they allresemble the same pattern.

Circular Permutation

ABCD BACD CABD DABCABDC BADC CADB DACBACBD BCAD CBAD DBACACDB BCDA CBDA DBCAADBC BDAC CDAB DCABADCB BDCA CDBA DCBA

Look closely at the bold italicized letters. If theyare arranged in a circular manner, they allresemble the same pattern.

Circular Permutation

ABCD BACD CABD DABCABDC BADC CADB DACBACBD BCAD CBAD DBACACDB BCDA CBDA DBCAADBC BDAC CDAB DCABADCB BDCA CDBA DCBA

Look closely at the bold italicized letters. If theyare arranged in a circular manner, they allresemble the same pattern.

Circular Permutation

ABCD BACD CABD DABCABDC BADC CADB DACBACBD BCAD CBAD DBACACDB BCDA CBDA DBCAADBC BDAC CDAB DCABADCB BDCA CDBA DCBA

Look closely at the bold italicized letters. If theyare arranged in a circular manner, they allresemble the same pattern.

Circular Permutation

ABCD BACD CABD DABCABDC BADC CADB DACBACBD BCAD CBAD DBACACDB BCDA CBDA DBCAADBC BDAC CDAB DCABADCB BDCA CDBA DCBA

Look closely at the bold italicized letters. If theyare arranged in a circular manner, they allresemble the same pattern.

Circular Permutation

ABCD BACD CABD DABCABDC BADC CADB DACBACBD BCAD CBAD DBACACDB BCDA CBDA DBCAADBC BDAC CDAB DCABADCB BDCA CDBA DCBA

Look closely at the bold italicized letters. If theyare arranged in a circular manner, they allresemble the same pattern.

Circular Permutation

The number of ways n objects can be arranged in a circular manner is given by

Circular Permutation

In the given problem,

Combination

A combination is an arrangement of objects with no respect to order.

Example. Find the possible permutations and combinations

of the word “cat”

Combination

For permutations:CAT CTAACT ATCTAC TCA

There are 6 permutations for the word “cat”.

Combination

For combinations,

Since order is regardless, thenCAT = CTA = ACT = ATC = TAC = TCA

which gives us only 1 combination.

Combination

What if we take only two letters from the word “cat”? How many permutations and combinations are there?

Combination

For permutations, According to the formula, there are 3P2 = 6

permutations, which are

AC AT

CA CT

TA TC

Combination

For combinations,

Again, order is not essential, so AC=CA, TC=CT, and AT=TA.

This gives us only 3 combinations.

Combination

The general formula for a combination is

and it is read “the combination of n objects taken r at a time”

Drill

Find how many possible combinations there are of 5 cards when randomly selected from a standard deck of 52 cards.

Solution

Since in getting 5 cards, order is not essential (i.e getting K♦ 3♠ K♣ 3♦ K♥ is the same as getting K♥ K♦ 3♠ 3♦ K♣, and all other orders), then we use combination.

Drill

Find the number of ways of getting just a pair when randomly getting three cards from a standard deck.

Drill

Find the number of ways of getting at least a pair when randomly getting three cards from a standard deck.

Drill

In a party, there are 53 guests who shook hands with one another exactly once. How many handshakes took place?