A. Counting and Probability · Permutations and CombinationsFactorial Notation and Arranging Distinct Objects
A2.2About 65 minutes
Learning goals- I can evaluate n! and explain why 0! = 1.
- I can count the arrangements of n different objects in a row as n!.
- I can simplify expressions and solve equations that contain factorials.
- I can count arrangements where some positions are fixed.
Words to know
factorial
For a positive integer n, n! (read "n factorial") = n × (n − 1) × (n − 2) × … × 2 × 1. By definition, 0! = 1.
arrangement
An ordering of objects in a row (or in positions). ABC and BAC are different arrangements of the same three letters.
distinct
All different from each other. The letters of MAPLE are distinct; the letters of CANADA are not.
recursive property of factorials
n! = n × (n − 1)!, for example 6! = 6 × 5!.
How many ways can you line up?
Five friends line up for a photo at a Winterlude ice sculpture. How many different orders are there?
Use the multiplicative counting principle with 5 slots. Any of the 5 friends can stand first. Whoever it is, 4 are left for the second spot, then 3, then 2, and the last person fills the last spot.
5 × 4 × 3 × 2 × 1 = 120 orders.
Products like this appear so often in counting that they have their own notation.
Factorial notation
For a positive integer n,
n! = n × (n − 1) × (n − 2) × … × 3 × 2 × 1
Read n! as "n factorial". So 5! = 120, 4! = 24, 3! = 6, 2! = 2 and 1! = 1.
The number of ways to arrange n distinct (different) objects in a row is n!.
Factorials grow incredibly fast: 10! = 3 628 800, and 13! is already more than 6 billion. Your calculator has a factorial key (often labelled x! or n!, sometimes under a probability menu with nPr and nCr).
Every arrangement of the letters A, B and C, grouped by the first letter. There are 3! = 6.One slot per position. The choices shrink by one each time because each letter can be used only once.Why is 0! equal to 1?
Look at the pattern: 4! = 4 × 3!, 3! = 3 × 2!, and in general n! = n × (n − 1)!. Put n = 1: 1! = 1 × 0!. Since 1! = 1, we need 0! = 1.
It also makes sense as a count: there is exactly one way to arrange zero objects (do nothing). You will see in the next lesson that 0! = 1 is what makes the permutation formula work when every object is used.
Simplifying factorial expressions
Never multiply out two huge factorials and then divide. Write the larger one in terms of the smaller one and cancel:
10!/8! = (10 × 9 × 8!)/8! = 10 × 9 = 90.
The same idea works with algebra: (n + 1)!/(n − 1)! = (n + 1) × n × (n − 1)!/(n − 1)! = n(n + 1).
Everything from 8 down to 1 appears in both the numerator and the denominator, so it cancels, leaving 10 × 9.Worked exampleExample 1: Evaluating
Evaluate (a) 7!, (b) 12!/9!, (c) 8!/(5! 3!).
- (a) 7! = 7 × 6 × 5 × 4 × 3 × 2 × 1 = 5040.
- (b) 12!/9! = 12 × 11 × 10 × 9!/9! = 12 × 11 × 10 = 1320.
- (c) 8!/5! = 8 × 7 × 6 = 336. Then divide by 3! = 6: 336 ÷ 6 = 56.
(a) 5040; (b) 1320; (c) 56.
Worked exampleExample 2: Solving a factorial equation
Solve n!/(n − 2)! = 56, where n is a whole number and n ≥ 2.
- Write n! = n × (n − 1) × (n − 2)!. Cancel (n − 2)!: n(n − 1) = 56.
- Expand: n² − n − 56 = 0.
- Factor: (n − 8)(n + 7) = 0, so n = 8 or n = −7.
- Factorials are defined only for whole numbers, so reject n = −7.
n = 8. Check: 8!/6! = 8 × 7 = 56 ✓.
Worked exampleExample 3: Some positions fixed
Seven students, including Ana and Ben, line up for a yearbook photo. In how many ways can they line up (a) with no restrictions, (b) if Ana must stand at the left end, (c) if Ana and Ben must stand at the two ends?
- (a) 7 distinct people in 7 places: 7! = 5040.
- (b) Ana's place is fixed. The other 6 students fill the other 6 places: 6! = 720.
- (c) First place the restricted people: Ana at the left and Ben at the right, or the other way round: 2 ways. The other 5 fill the middle: 5! = 120. Multiply: 2 × 120 = 240.
(a) 5040; (b) 720; (c) 240.
Just for funThere are 52! ways to order a deck of cards, about 8 × 10⁶⁷. That is so large that a well-shuffled deck is almost certainly in an order no deck has ever been in before.
Hands-on activityLine up the cutlery
You need: four different small household objects (for example a spoon, a fork, a cup and a pencil), paper, a pencil and a timer.
- Predict how many different left-to-right orders the four objects can be placed in.
- Find them all by hand, systematically: fix the first object (say the spoon) and list all orders of the other three; then put a different object first, and so on. Record each order with initials (S F C P).
- Time how long it takes you. How many orders begin with each object?
- Now estimate how long it would take to list every order of 10 objects at the same rate.
What to look for: 4! = 24 orders, 6 starting with each object (3! orders of the rest). If 24 orders took about 3 minutes, 10! = 3 628 800 orders would take about 3 628 800 ÷ 24 × 3 ≈ 450 000 minutes, roughly 10 months without sleep. That is why we count with formulas instead of lists.
Your turn
6 × 5 × 4 × 3 × 2 × 1 = 720.
12!/10! = 12 × 11 = 132, and 132 ÷ 2 = 66.
4In how many ways can 7 different books be arranged on a shelf?
6In how many ways can the letters of the word WINTER be arranged?
6 distinct letters: 6! = 720.
n(n − 1) = 42, so n² − n − 42 = 0, (n − 7)(n + 6) = 0. n = 7 (reject −6).
More practice: warm-up
5In how many ways can 3 friends stand in a line?
More practice: on your own
1Write 8 × 7 × 6 as a quotient of two factorials.
8 × 7 × 6 = 8!/5!, because 8! = 8 × 7 × 6 × 5!.
(n + 2)(n + 1) = n² + 3n + 2.
3Solve (n + 1)!/(n − 1)! = 72.
(n + 1)n = 72, so n² + n − 72 = 0, (n + 9)(n − 8) = 0. n = 8 (reject −9).
4Eight runners finish a race with no ties. In how many orders can they finish?
5Six people sit in a row for a photo, and the two tallest must sit at the two ends. How many arrangements are possible?
The two tallest at the ends: 2 ways. The other 4 in the middle: 4! = 24. 2 × 24 = 48.
Challenge
1Show that n! + (n + 1)! = (n + 2) × n! for every whole number n.
Factor out n!: n! + (n + 1)! = n! + (n + 1) × n! = n!(1 + n + 1) = (n + 2) × n! ✓
2How many zeros are at the end of 25! when it is written out in full?
Each final zero comes from a factor 10 = 2 × 5, and there are more 2s than 5s. Count the 5s: 5, 10, 15, 20 give one each, and 25 = 5 × 5 gives two: 4 + 2 = 6. So 25! ends in 6 zeros.
3Six people sit around a round table. Two seatings count as the same if everyone has the same neighbours on the left and right (rotating everyone does not make a new seating). How many seatings are there?
Fix one person's seat to remove the rotations; the other 5 can be arranged in 5! = 120 ways. (In general, n people around a circle: (n − 1)!.)
Check your understandingQuiz
4. In how many ways can 6 different books be arranged on a shelf?
For parents and teachersBig idea (A2.2): n! counts the ways to arrange n different objects in a row, and factorial expressions are simplified by cancelling, not by multiplying everything out.
How to help: Have your teen explain where 5 × 4 × 3 × 2 × 1 comes from (5 choices for the first place, 4 for the next, …). Quick mental checks: 8!/6! = 8 × 7.
Common difficulties:
- Thinking 0! = 0. It is 1.
- Cancelling incorrectly, for example treating 10!/5! as 2!. Factorials do not divide like ordinary numbers.
- Forgetting to reject negative solutions when solving factorial equations.
- Overflow: calculators cannot show very large factorials, which is another reason to simplify first.