Sub topic 10
Multiplying Two Binomials with FOIL
This chapter assumes you can multiply a monomial by a polynomial with the distributive property, apply the product rule for exponents (x^a · x^b = x^(a+b)), and combine like terms. It also assumes you are comfortable with negative integers. FOIL is a memory aid built on those skills. It is not a new rule.
What FOIL is
A binomial is a polynomial with exactly two terms, such as x + 3 or 2x − 5. When you multiply two binomials, each term of the first factor must multiply each term of the second. That gives 2 × 2 = 4 products. FOIL names the four products in a fixed order:
- First: multiply the first term of each binomial.
- Outer: multiply the two terms at the outside ends.
- Inner: multiply the two terms in the middle.
- Last: multiply the last term of each binomial.
After you list the four products, you add them and combine any like terms.
Here is a worked example, (2x + 3)(x + 4):
| Step | Pair | Product |
|---|---|---|
| First | 2x · x | 2x² |
| Outer | 2x · 4 | 8x |
| Inner | 3 · x | 3x |
| Last | 3 · 4 | 12 |
The sum is 2x² + 8x + 3x + 12. The outer and inner products are both multiples of x, so they are like terms. Combining them gives 2x² + 11x + 12.
Why FOIL works
FOIL is the distributive property used twice. Treat the second binomial as a single block and distribute the first binomial over it:
(a + b)(c + d) = a(c + d) + b(c + d)
Distribute again inside each part:
a(c + d) + b(c + d) = ac + ad + bc + bd
The four terms are First (ac), Outer (ad), Inner (bc), and Last (bd). The diagram shows the two-stage expansion.
This explains two things that FOIL alone does not. First, the order of the four products does not matter, because addition is commutative. Second, the method only guarantees a correct answer when you really do form all four products.
A general pattern
For binomials with a single variable, you can skip the list and write the result directly:
(ax + b)(cx + d) = ac·x² + (ad + bc)·x + bd
Read it as follows:
- The x² coefficient is the product of the two leading coefficients.
- The x coefficient is the sum of the outer and inner products.
- The constant is the product of the two constants.
For (2x + 3)(x + 4), a = 2, b = 3, c = 1, d = 4. The x² coefficient is 2·1 = 2. The x coefficient is 2·4 + 3·1 = 11. The constant is 3·4 = 12. This matches the result above.
Handling signs
Most FOIL mistakes are sign mistakes. Attach each sign to the term that follows it, and treat subtraction as adding a negative. Rewrite (x − 3)(2x + 5) as (x + (−3))(2x + 5), then:
- First: x · 2x = 2x²
- Outer: x · 5 = 5x
- Inner: (−3) · 2x = −6x
- Last: (−3) · 5 = −15
Combine the middle terms: 5x + (−6x) = −x. The result is 2x² − x − 15.
When both binomials contain subtraction, the last term becomes positive. In (x − 4)(x − 2), the Last product is (−4)(−2) = +8. The Outer and Inner products are −2x and −4x, so the result is x² − 6x + 8.
Two variables and higher powers
FOIL does not require the terms to be single-variable or linear. It only requires two terms in each factor.
For (2x + y)(x − 3y):
- First: 2x · x = 2x²
- Outer: 2x · (−3y) = −6xy
- Inner: y · x = xy
- Last: y · (−3y) = −3y²
The Outer and Inner products are both xy terms, so −6xy + xy = −5xy. The result is 2x² − 5xy − 3y².
For (x² + 3)(x³ − 2x), use the product rule for exponents on each pair, which means adding the exponents:
- First: x² · x³ = x⁵
- Outer: x² · (−2x) = −2x³
- Inner: 3 · x³ = 3x³
- Last: 3 · (−2x) = −6x
Here Outer and Inner are both x³ terms, so −2x³ + 3x³ = x³. The result is x⁵ + x³ − 6x.
Sometimes the Outer and Inner products are not like terms. For (x + 1)(y + 2), the four products are xy, 2x, y, and 2. Nothing combines, so the answer has four terms: xy + 2x + y + 2. A four-term answer is not an error.
Common errors
Watch for these other errors:
- Sign slips on negative terms. Writing (x − 3)(x + 5) = x² + 5x + 3x − 15 treats the −3 as +3 in the Inner product. The Inner product is (−3)(x) = −3x.
- Combining unlike terms. In x² + 7x + 12, you cannot merge 7x and x². Only terms with the same variable part combine.
- Dropping a term. If you list only three products, the result is missing a term. Count your products before you combine anything.
- Using FOIL on non-binomials. FOIL names four products, so it only fits two-term factors. A binomial times a trinomial needs six products. The next chapter covers that case, and the same idea of distributing every term applies.
- Squaring by distributing the exponent. (x + 3)² is not x² + 9. It means (x + 3)(x + 3), so FOIL gives x² + 3x + 3x + 9 = x² + 6x + 9. Special products are covered in a later chapter.
Predicting the shape of the answer
You can predict the degree before you start. Each binomial above has degree 1 in x, and the product of two degree-1 terms has degree 2. In general, the highest-degree term of the product is the First product, so the degree of the result is the sum of the degrees of the two factors. In the last example, 2 + 3 = 5, and the answer starts with x⁵.
You can also predict the end of the answer. The constant term is always the Last product. If it is missing, as in x⁵ + x³ − 6x, then one factor had no constant term or the pieces cancelled.
Checking with substitution
Choose a value for the variable and evaluate the factored form and the expanded form. If they differ, one is wrong. For (x − 3)(2x + 5) and 2x² − x − 15, try x = 2:
- Factored: (2 − 3)(4 + 5) = (−1)(9) = −9
- Expanded: 2(4) − 2 − 15 = 8 − 2 − 15 = −9
Both give −9, so the expansion passes this test. Avoid x = 0 and x = 1 as your only checks. At x = 0 only the constant term is tested. At x = 1 many errors cancel.
Doing it in code
The following program computes the four FOIL products for (ax + b)(cx + d), combines them into a coefficient list (constant term first), and checks the result at several values of x.
def foil_terms(a, b, c, d):
# (a*x + b)(c*x + d)
return {"first": a * c, "outer": a * d, "inner": b * c, "last": b * d}
def expand(a, b, c, d):
t = foil_terms(a, b, c, d)
# Coefficients from the constant term upward: [constant, x, x^2]
return [t["last"], t["outer"] + t["inner"], t["first"]]
def evaluate(p, x):
return sum(coef * x**i for i, coef in enumerate(p))
a, b, c, d = 2, 3, 1, 4 # (2x + 3)(x + 4)
print(foil_terms(a, b, c, d))
coeffs = expand(a, b, c, d)
print(coeffs)
for x in range(-3, 4):
assert (a * x + b) * (c * x + d) == evaluate(coeffs, x)
print("all checks passed")It prints {'first': 2, 'outer': 8, 'inner': 3, 'last': 12}, then [12, 11, 2], then all checks passed. The list [12, 11, 2] means 12 + 11x + 2x², which matches the hand result.
Summary of the method
- Confirm both factors have exactly two terms.
- Write each subtraction as adding a negative.
- Form the four products, adding exponents for repeated variables.
- Combine like terms, usually the Outer and Inner products.
- Check the degree, then substitute a value such as x = 2 to verify.
Exercise
Expand (3x − 2)(x + 6). Show the four FOIL products, give the final answer, and check it at x = 2.
Show answer
First: 3x · x = 3x². Outer: 3x · 6 = 18x. Inner: (−2) · x = −2x. Last: (−2) · 6 = −12. Combining 18x − 2x = 16x gives 3x² + 16x − 12. Check at x = 2: (6 − 2)(2 + 6) = 4 · 8 = 32, and 3(4) + 32 − 12 = 12 + 32 − 12 = 32. They match.
Exercise
A student expands (x + 5)(x − 5) and writes x² − 25 after listing First and Last only. The answer is correct, but the method skipped steps. Write the full FOIL expansion and explain why the middle terms disappear.
Show answer
First: x · x = x². Outer: x · (−5) = −5x. Inner: 5 · x = 5x. Last: 5 · (−5) = −25. The Outer and Inner products are opposites, so −5x + 5x = 0, which leaves x² − 25. This happens whenever the two binomials differ only in the sign of the second term.
Exercise
Expand (2x² − y)(x + 3y) and state the degree of the result in x and y together.
Show answer
First: 2x² · x = 2x³. Outer: 2x² · 3y = 6x²y. Inner: (−y) · x = −xy. Last: (−y) · 3y = −3y². Nothing combines, so the result is 2x³ + 6x²y − xy − 3y². The term 2x³ has degree 3 and 6x²y has degree 3, so the degree is 3.