Grade by Grade
A. Counting and Probability · Permutations and Combinations

Permutations with Conditions

A2.2 A2.3About 70 minutes
Learning goals
  • I can count arrangements in which certain objects must be in certain positions.
  • I can use the block method when objects must stay together.
  • I can use indirect counting or the gap method when objects must be kept apart.
  • I can split a problem into cases and add them when one formula is not enough.

Words to know

restriction (condition)
A rule that limits the allowed arrangements, such as "the word must start with a vowel" or "Ana and Ben must sit together".
block method
To keep some objects together, tape them into one block, arrange the block with the other objects, then multiply by the number of ways to arrange the objects inside the block.
gap method
To keep some objects apart, arrange the other objects first, then place the restricted objects into the gaps between and around them, at most one per gap.
case
One of several mutually exclusive situations a problem is split into; the counts for the cases are added.

Rules change the count

Your family is booking 6 seats in a row for a professional women's hockey game, and two younger cousins must sit together. Or your class photo needs the tallest students at the ends. Real arrangements usually come with conditions.

There is no single formula for every condition, but there are four reliable strategies:

  1. Restricted positions first. Fill the positions with rules before the free ones.
  2. Block method for objects that must be together.
  3. Indirect counting or the gap method for objects that must be apart.
  4. Cases: split the problem into non-overlapping cases, count each, and add.

In every example below we use the word CANOES, which has 6 distinct letters: three vowels (A, O, E) and three consonants (C, N, S). With no conditions there are 6! = 720 arrangements.

Worked example

Example 1: Restricted positions

How many arrangements of CANOES (a) begin with a vowel, (b) begin with a consonant and end with a vowel?

  1. (a) First position: 3 vowels. The other 5 letters fill the remaining 5 places: 5! = 120. Total 3 × 120 = 360.
  2. (b) First position: 3 consonants. Last position: 3 vowels. The middle 4 places hold the other 4 letters: 4! = 24.
  3. 3 × 3 × 24 = 216.

(a) 360; (b) 216.

Objects that must be together: the block method

If A, O and E must be side by side (in any order), imagine taping them together into one block. Now there are only 4 units to arrange: C, N, S and the block. That gives 4! orders.

But inside the block, the vowels can be in any of 3! orders (AOE, AEO, OAE, …). By the multiplicative principle:

4! × 3! = 24 × 6 = 144 arrangements.

CNSAOE4 units to arrange: 4!inside the block: 3!4! × 3! = 24 × 6 = 144
The block method. The taped block counts as one unit among four; then the letters inside the block can be arranged in 3! ways.

Objects that must be apart

Indirect counting. "The vowels are not all together" is the complement of "all together": 720 − 144 = 576.

Gap method. "No two vowels are next to each other" is a stronger condition (AOCNES is "not all together" but A and O are still neighbours). Arrange the 3 consonants first: 3! = 6 ways. This creates 4 gaps: _ C _ N _ S _. Put each vowel into a different gap. Since the vowels are different, the order matters: P(4, 3) = 24 ways.

3! × P(4, 3) = 6 × 24 = 144 arrangements with no two vowels adjacent.

^gap 1C^gap 2N^gap 3S^gap 4Place the consonants first (3! ways)Put A, O, E into 3 ofthe 4 gaps, in order:P(4, 3) = 243! × P(4, 3) = 144
The gap method. Three consonants make four gaps. Putting each vowel in its own gap guarantees that no two vowels touch.
Worked example

Example 2: Two people together or apart

Eight friends, including Maya and Liam, sit in a row of 8 seats at a movie. How many seatings have (a) Maya and Liam together, (b) Maya and Liam not together?

  1. (a) Block method: Maya and Liam form one block, so there are 7 units: 7! = 5040. Inside the block they can sit in 2! = 2 orders. 5040 × 2 = 10 080.
  2. (b) Indirect: all seatings 8! = 40 320. Subtract those with them together: 40 320 − 10 080 = 30 240.

(a) 10 080; (b) 30 240.

Worked example

Example 3: Alternating

Four boys and three girls stand in a row so that boys and girls alternate. How many arrangements are possible?

  1. With 4 boys and 3 girls, the only alternating pattern is B G B G B G B (the row must start and end with a boy).
  2. Boys in the 4 boy positions: 4! = 24. Girls in the 3 girl positions: 3! = 6.
  3. 24 × 6 = 144. (With equal numbers, for example 3 boys and 3 girls, there are two patterns, BGBGBG and GBGBGB, so you would multiply by 2.)

144 arrangements.

Worked example

Example 4: Cases with digits

How many 4-digit numbers greater than 5000 can be made from the digits 1, 2, 3, 4, 5, 6 and 7 with no digit repeated?

  1. A 4-digit number is greater than 5000 exactly when its first digit is 5, 6 or 7 (with digits 1 to 7 there is no 5000 itself). That is 3 choices.
  2. The other 3 places take any 3 of the remaining 6 digits, in order: P(6, 3) = 120.
  3. 3 × 120 = 360.

360 numbers.

A checklist for restricted arrangements

  1. Count the total with no conditions first. It is a useful upper limit and often needed for indirect counting.
  2. Handle the most restricted positions or objects first.
  3. "Together" → block method, and do not forget the arrangements inside the block.
  4. "Not together" for two objects → total minus together. "No two together" for three or more → gap method.
  5. If a choice changes the number of options later (for example, whether 0 has been used), split into cases and add.
Just for fun

Ten people can sit in a row in 10! = 3 628 800 different orders. Trying a new order every day would take about 9935 years, so you might want to make a seating plan.

Hands-on activity

Keep the ace and 2 together

You need: the ace, 2, 3, 4 and 5 of one suit (5 cards) and a strip of tape (or just hold two cards together).

  1. Predict with the block method how many left-to-right orders of the 5 cards have the ace and the 2 side by side.
  2. Tape the ace and 2 together as a block (ace on the left). List all orders of the block with the 3, 4 and 5. How many are there?
  3. Flip the block (2 on the left) and list again. Add the two counts. Does it match your prediction?
  4. Now count the orders where the ace and 2 are not side by side, using the total 5!.
  5. Use the gap method to count the orders where no two of the ace, 2 and 3 are side by side (arrange the 4 and 5 first).

What to look for: 4! = 24 orders for each direction of the block, so 4! × 2! = 48 in total. Not side by side: 120 − 48 = 72. Gap method: 2! ways for the 4 and 5, making 3 gaps, and P(3, 3) = 6 ways to place the ace, 2 and 3: 2 × 6 = 12 orders (for example A 4 2 5 3).

Your turn

1

How many arrangements of the letters of PLANET begin with P?

2

How many arrangements of PLANET begin with a consonant and end with a vowel?

3

Six people sit in a row. In how many ways can two particular people sit together?

4

In the previous question, in how many ways can those two people sit apart?

5

Three different math books and four different English books go on a shelf, with the books of each subject kept together. How many arrangements are possible?

6

How many even 4-digit numbers can be made from the digits 1 to 6 with no repetition?

7

Five boys and five girls stand in a row, alternating boy and girl. How many arrangements are possible?

More practice: warm-up

1

How many arrangements of ABCDE begin with A?

2

How many arrangements of ABCDE end with E?

3

How many arrangements of ABCDE have A and B side by side?

4

Three friends and two other people stand in a row, and the three friends must be together. How many arrangements?

5

How many arrangements of the letters of WORD begin with W?

More practice: on your own

1

Seven people stand in a row, and 3 particular people must be together. How many arrangements?

2

How many arrangements of FRIDAY have the vowels I and A not next to each other?

3

Four couples sit in a row of 8 seats, and each couple sits together. How many seatings are possible?

4

How many 4-digit numbers greater than 3000 can be made from the digits 0, 1, 2, 3, 4 and 5 with no repetition?

5

How many arrangements of YUKON have Y and K not next to each other?

Challenge

1

Five boys and three girls sit in a row so that no two girls sit together. How many seatings are possible?

2

How many arrangements of FACTOR have the A somewhere to the left of the O (not necessarily next to it)?

3

How many 5-digit numbers with all different digits are divisible by 5?

Check your understanding

Quiz

1.

How many arrangements of the letters of CANOES have the three vowels together?

2.

Six people sit in a row. In how many ways can two particular friends sit together?

3.

Which method counts arrangements where two particular objects are NOT next to each other?

4.

How many arrangements of ABCDE begin with a vowel?

5.

Three boys and three girls stand in a row, alternating boy and girl. How many arrangements?

6.

Four boys and three girls stand in a row with no two girls next to each other. How many arrangements?

For parents and teachers

Big idea (A2.2, A2.3): conditions are handled by a small set of strategies: restricted positions first, the block method for "together", subtraction or the gap method for "apart", and splitting into cases.

How to help: Act problems out with cards, cutlery or family members. Asking "what is the total with no rules?" first gives a useful check: every restricted answer must be smaller.

Common difficulties:

  • Forgetting to multiply by the arrangements inside a block.
  • Confusing "not all together" (subtract) with "no two together" (gap method).
  • Forgetting that alternating patterns with equal numbers of each type can start with either type.
  • Missing that 0 cannot be a first digit; splitting into cases fixes this.