A short-cut to multiplying binomials


Very often in math and science, we need to calculate powers of binomials like

$$(x + 3)^2 \; \; \text{ or } \; \; (2x - 7)^5$$

(Remember that a binomial is something of the form (x + a) that includes at least one variable.)

The first example, squaring a binomial, is pretty easy, something we do all the time. The second, however, would take a while to work out, with ample opportunity for error.

The good news is that these expansions always have some patterns, and we can exploit them to make them easy to do.


Quadratics: $(x + a)^2$


Just to review, expanding a squared binomial to form a quadratic function looks like this.

Sometimes we employ the mnemonic F.O.I.L., for "first, outer, inner, last," in order to remember all of the pairings we need to multiply.

The result is always one term that purely contains the variable x, one that purely contains y, and a mixed term containing both.

Here's a geometric view of why that's true. If we remember that area is length × width, and we find the area of a box with sides of length (x + a), we find that the sub-areas correspond to the terms of our expansion.

X

mnemonic

A mnemonic (nee·mon'·ick) is a word or phrase designed to help a person remember something. An example would be the pseudo-word "ROYGBIV" or the phrase "Rogers of York Gave Battle in Vain." Both are designed to help us remember the colors of the visible spectrum: red, orange, yellow, green, blue, indigo & violet.

Beware: I once chatted with a couple of math professors at an Ivy-League university who lamented that so many incoming students thought that (x + y)2 = x2 + y2. In fact, (x + y)2 = x2 + 2xy + y2. This mistaken idea popped up so often, if fact, that the professors referred to it as "the second fundamental theorem of algebra," an inside math joke. So remember:

$$(a ± b)^n \ne a^n + b^n$$

unless n = 1


Looking for patterns in higher expansions


Now let's see if we can find a pattern as we raise the binomial (x + a) to higher powers.

First the lower powers:

$$ \begin{align} (x + a)^0 &= 1 \\ (x + a)^1 &= x + a \\ (x + a)^2 &= x^2 + 2ax + a^2 \end{align}$$

These we are familiar with. Anything raised to the zero power is one. (x + a)1 = (x + a), and the squared binomial was reviewed above.

Now (x + a)3 is just (x + a) multiplied by the result of squaring (x + a), and so on.


Narrow screens
← scroll long equations L/R →

The cubed binomial is

$$ \begin{align} (x + 3)^3 &= (x + a)(x^2 + 2ax + a^2) \\ &= x^3 + 2ax^2 + a^2x + ax^2 + 2a^2x + a^3 \\ &= x^3 + 3ax^2 + 3a^2x + a^3 \end{align}$$

The fourth power is just (x + a) times the result from above:

$$ \begin{align} (x + 3)^4 &= (x^2 + 2ax + a^2)^2 \\ &= x^4 + 2ax^3 + a^2x^2 + 2ax^3 + 4a^2x^2 + 2a^3x + a^2x^2 + 2a^3x + a^4 \\ &= x^4 + 4ax^3 + 6a^2x^2 + 4a^3x + a^4 \end{align}$$

Notice that I've organized these polynomials so that the powers of x diminish and the powers of a increase — just a custom, but a helpful one. Here's a summary of those binomial powers. The gray box summarizes the emerging pattern.

$$ \begin{align} (x + a)^0 &= 1 \\ (x + a)^1 &= x + a \\ (x + a)^2 &= x^2 + 2ax + a^2 \\ (x + a)^3 &= x^3 + 3ax^2 + 3a^2x + a^3 \\ (x + a)^4 &= x^4 + 4ax^3 + 6a^2x^2 + 4a^3x + a^4 \\ &\vdots \\ (x + a)^n &= c_ox^na^0 + c_1a^1x^{n - 1} + c_2a^2x^{n - 2} + \dots + c_{n - 1}a^{n - 1}x^1 + c_na^nx^0 \end{align}$$


General binomial expansion

The general formula for expanding a power of a binomial, like (x + a)n, where either x or a or both can be variables, and n is a positive integer, is:

$$(x + a)^n = c_ox^n a^0 + c_1 a^1 x^{n - 1} + c_2 a^2 x^{n - 2} + \; \dots \; + c_{n - 1} a^{n - 1}x^1 + c_n a^n x^o,$$

where the {cn} are constant (numerical) coefficients.

Now take a close look at that general formula for the expansion of (x + a)n in the gray box above. Notice that as we move from left to right, the powers of x decrease from n down to zero (x0 = 1), and the powers of a increase from 0 up to n.

That's a consistent pattern for all such expansions, if we put the terms in the right order. The numerical coefficients – the c's – are somewhat different for each successive power of the binomial, but they always have the same pattern.

For example, reading from left-to-right across the expanded terms of (x + a)4, the coefficients are 1, 4, 6, 4, and 1.

If we ignore the precise form of the constant coefficients for now, we can write the expansion in summation notation like this:

$$(x + a)^n = \sum_{i = 0}^n c^i \, x^{n - i} \, a^i$$

In this notation, the powers of x are decreasing to zero as we work left to right across the expansion, and the powers of a are increasing to n. We'll come back to this in a bit. First we need to address those coefficients.


Pascal's triangle gives the coefficients


Magically, those coefficients appear in the rows of Pascal's triangle.

  1. The first three rows of the triangle are shown above. It is constructed like this.

  2. Write a 1 on the first row and move to the second.

  3. From here on, each row must begin with a 1 and end with a 1.

  4. The intervening numbers (like the 2 above) are generated by adding the two numbers directly above and to the left and right. In this case, the 2 is 1 + 1.

Here's a larger version of the triangle, for n (the power of the binomial) = 0 to 6.

Roll over or tap the table to see the linkages between numbers in the table. For example, in the n = 3 row, the 3's are sums of the 1's and 2's directly above. Pascal's triangle is a recursive construction, each new row in the triangle depending on the row above it.



Now Pascal's triangle is very handy for coming up with those coefficients, but imagine writing, say, all 12 rows of it out if you need to expand (x + a)11. What we need is a formula that will give us the coefficients for any n. That's what the next section is about.


A formula for the binomial coefficients


Now to find a formula for those numerical coefficients. Let's use the 5th row (n = 4) of Pascal's triangle as an example.

The expansion of (x + a)4 is:

So what is the origin of those coefficients? Because of the way we successively multiply binomials when expanding (x + a)n, we automatically find every permutation of a's and x's possible for each term.

As an example, let's square a binomial once again:

$$(x + a)^2 = x^2 + xa + ax + a^2$$

Notice that there are two ways to arrange the mixed terms containing x1 and a1 and that both are represented here: xa and ax. That 2 would be the coefficient of ax in the expansion:

$$(x + a)^2 = x^2 + 2ax + a^2$$

Likewise there is only one way to express x2 and one way to express a2, so those terms have coefficients of 1. Now back to n = 4, we find several more permutations of four objects of two types (x and a). They are:

So our coefficients are the number of ways of organizing each kind of term.

Now the study of permutations and combinations gives us these expressions for the number of ways or organizing n objects taken n at a time using factorial functions. For our n = 4 example:

$$ \begin{align} c_0 &= 1 \\ c_1 &= n \\ c_2 &= \frac{n(n - 1)}{2!} \\ c_3 &= \frac{n(n - 1)(n - 2)}{3!} \\ c_4 &= \frac{n(n - 1)(n - 2)(n - 3)}{4!} \end{align}$$

where x! is the factorial function. For example, 5! = 5·4·3·2·1 = 120, and 3! = 3·2·1 = 6. We can condense these terms into one equation like this:

$$c_{n, k} = \frac{n!}{k!(n - k)!}$$

where n is the power of the binomial and k labels the term of the expansion from left to right. For (x + a)4, we can now calculate those coefficients with our new formula:

$$ \begin{align} c_0 &= \frac{4!}{0!(4 - 0)!} = 1 \\ \\ c_1 &= \frac{4!}{1!(4 - 1)!} = \frac{4!}{3!} = \frac{24}{6} = 4 \\ \\ c_2 &= \frac{4!}{2!(4 - 2)!} = \frac{4!}{2!2!} = \frac{24}{4} = 6 \\ \\ c_3 &= \frac{4!}{3!(4 - 3)!} = \frac{4!}{3!} = \frac{24}{6} = 4 \\ \\ c_4 &= \frac{4!}{4!(4 - 4)!} = \frac{4!}{4!} = 1 \end{align}$$

Those coefficients are often called binomial coefficients, and they are often given an alternative symbol:

which is read "n - choose - k," meaning that the number of combinations of objects taken from a group of n, and taken k at a time.

The binomial coefficient

$$\binom{n}{k} = \frac{n!}{k!(n - k)!}$$


Number of permutations of n objects taken k at a time, if order doesn't matter.


The binomial expansion


Finally, we can put this work all together to write a compact expression for the binomial expansion of $(a + b)^n$ using binomial coefficients:$

$$(a + b)^n = \sum_{k = 0}^n \binom{n}{k} a^{n - k} b^k$$

A useful theorem


An often-useful theorem involving the binomial coefficients is

$$\binom{n}{k} = \binom{n}{n - k}$$

A short proof of this is given below.


Proof that $\binom{n}{k} = \binom{n}{n - k}$

$$\text{Let } \; \; \binom{n}{k} = \frac{n!}{k!(n - k)!}, \; \text{ then}$$

$$\binom{n}{n - k} = \frac{n!}{(n - (n - k))!(n - k)!} = \frac{n!}{k!(n - k)!}$$


Example 1

Write the expansion of   $(a + b)^7$   using binomial coefficients.


Solution: The a and b components, with their powers, go as $a^7, \; a^6 b, \; a^5 b^2, \; \dots \; a b^6, \; b^7.$ The coefficients are given by the binomial coefficients,

$$\binom{7}{0}, \binom{7}{1}, \binom{7}{2}, \dots \binom{7}{6}.$$

Let's go ahead and calculate those:

$$ \begin{align} \binom{7}{0} &= \frac{7!}{0!(7-0)!} = 1\\[5pt] \binom{7}{1} &= \frac{7!}{1!(7-1)!} = 7\\[5pt] \binom{7}{2} &= \frac{7!}{2!(7-2)!} = 21\\[5pt] \binom{7}{3} &= \frac{7!}{3!(7-3)!} = 35\\[5pt] \binom{7}{4} &= \frac{7!}{4!(7-4)!} = 35\\[5pt] \end{align}$$

$$ \begin{align} \binom{7}{5} &= \frac{7!}{5!(7-5)!} = 21\\[5pt] \binom{7}{6} &= \frac{7!}{6!(7-6)!} = 7\\[5pt] \binom{7}{6} &= \frac{7!}{7!(7-7)!} = 1\\[5pt] \end{align}$$

So our expanded binomial is

$$ \begin{align} (a + b)^7 &= \\[3pt] &a^7 + 7a^6 b + 21a^5 b^2 + 35a^4 b^3 \\[3pt] &+ 35a^3 b^4+ 21a^2 b^5 + 7a b^6 + b^7 \end{align}$$

Those coefficients are the same as you'd get from the 7th row of Pascal's triangle. Notice also that if we'd used our handy theorem above that we only needed to calculate the first half of the coefficients because   $\binom{7}{2} = \binom{7}{5},$ and so on.


Example 2

How many possible teams of nine baseball players can be made from a group of 14 total players?


Solution: We assume here that order doesn't matter, meaning that any order of a team of the same nine players is as good as any other order. That makes this a binomial problem.

The solution is just the binomial coefficient $\binom{14}{9}.$

Notice how the arithmetic is done with factorials. Expand them just to the point where what you have left (see the 9! in the numerator of the calculation) cancels nicely. That's a quick way of simplifying. You wouldn't really even need a calculator for this problem, just divide by 10, 2:

$$\frac{24024}{12} = \frac{12012}{6} = \frac{6006}{3} = 2002$$

$$ \begin{align} \binom{14}{9} &= \frac{14!}{9!(14 - 9)!} \\[5pt] &= \frac{14\cdot 13\cdot 12\cdot\ 11\cdot 10\cdot 9!}{9!5!} \\[5pt] &= \frac{14\cdot 13\cdot 12\cdot\ 11\cdot 10}{5!} \\[5pt] &= \frac{240,240}{120} = \bf 2002 \; \text{teams} \end{align}$$

So out of a pool of 14 players, there are 2002 possible teams of nine.


Practice problems

1. Write the expansion of   $(x - 2)^{10}.$
2. A bag contains 15 black marbles and 10 white marbles. How many ways can 5 black and 5 white marbles be chosen?
3. In the game of poker, there are 4 suits of cards (hearts, diamonds, clubs, spades), and 13 denominations (A, 2, 3, ... J, Q, K). A full house consists of 3 cards of one denomination and 2 of another, regardless of suit. How many different full-houses are there in poker?
4. A restaurant offers hamburgers with a choice of other ingredients, including pickles, onions, mushrooms, cheese, tomato, bacon and lettuce. The first three ingredients come with the price of the burger. How many kinds of three-ingredient burgers can be made?

Creative Commons License   optimized for firefox
xaktly.com by Dr. Jeff Cruzan is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License. © 2012, Jeff Cruzan. All text and images on this website not specifically attributed to another source were created by me and I reserve all rights as to their use. Any opinions expressed on this website are entirely mine, and do not necessarily reflect the views of any of my employers. Please feel free to send any questions or comments to jeff.cruzan@verizon.net.