Unit 6 · Lesson 4 of 6

Special factoring patterns

About 25 minutes · 5 steps · one idea: spot a pattern, use its formula

You'll be able to: recognize and factor a difference of squares, a perfect square trinomial, and a sum or difference of cubes.

  1. 1 Warm-up
  2. 2 The idea
  3. 3 Examples
  4. 4 Practice
  5. 5 Wrap-up

Step 1 of 5Warm-up

Two quick questions from earlier lessons. Try them from memory first.

Factor \(2x^2 + 5x - 3\).

\(ac = 2 \cdot (-3) = -6\). Multiply to \(-6\), add to 5: \(6\) and \(-1\).

Split: \(2x^2 + 6x - x - 3 = 2x(x + 3) - 1(x + 3)\).

Answer: \((2x - 1)(x + 3)\).

Fill in the missing number: \((x+3)^2 = x^2 + \underline{\quad}\,x + 9\).

\((x+3)^2 = (x+3)(x+3) = x^2 + 3x + 3x + 9 = x^2 + 6x + 9\).

The missing number is \(6\). Remember: \((x+3)^2\) is not \(x^2 + 9\). The middle term is twice \(x \cdot 3\).

Step 2 of 5The idea

In Special products you multiplied out a few patterns. Factoring runs those same patterns backward. If you spot the pattern, you can skip the ac method and write the answer straight from a formula.

Each pattern is built from perfect squares (\(1, 4, 9, 16, 25, \dots\) and \(x^2, 4x^2, 9x^2\)) or perfect cubes (\(1, 8, 27, 64, 125\) and \(x^3, 8x^3\)).

Difference of squares: \(a^2 - b^2 = (a + b)(a - b)\)

Perfect square trinomial: \(a^2 + 2ab + b^2 = (a + b)^2\) and \(a^2 - 2ab + b^2 = (a - b)^2\)

Sum and difference of cubes: \(a^3 + b^3 = (a + b)(a^2 - ab + b^2)\) and \(a^3 - b^3 = (a - b)(a^2 + ab + b^2)\)

Sum of squares \(a^2 + b^2\) does not factor. It is prime.

For the cubes, remember the signs with SOAP: the first sign is the Same as the original, the second is Opposite, the last is Always Positive.

To test a trinomial for a perfect square: the first and last terms must be squares, and the middle must be \(2 \cdot a \cdot b\).

Why this shows up on the placement test: these patterns hide inside many problems (simplifying fractions, solving equations), and spotting them saves a lot of time.

Step 3 of 5Worked examples

Example 1: Factor \(9x^2 - 25\), then \(x^2 - 10x + 25\)

  1. \(9x^2 - 25\) is two squares with a minus between: \(9x^2 = (3x)^2\) and \(25 = 5^2\). So \(a = 3x\), \(b = 5\).
  2. Difference of squares: \((3x + 5)(3x - 5)\). Check: \(9x^2 - 15x + 15x - 25 = 9x^2 - 25\).
  3. \(x^2 - 10x + 25\): first term \(x^2 = (x)^2\), last term \(25 = 5^2\). So \(a = x\), \(b = 5\).
  4. Middle test: \(2 \cdot x \cdot 5 = 10x\). It matches, and the middle sign is minus.
  5. Perfect square trinomial: \((x - 5)^2\).

Example 2: Factor \(8x^3 - 27\)

  1. Both are cubes: \(8x^3 = (2x)^3\) and \(27 = 3^3\). So \(a = 2x\), \(b = 3\).
  2. Difference of cubes: \((a - b)(a^2 + ab + b^2)\). SOAP: same (−), opposite (+), always positive (+).
  3. Fill in: \(a^2 = 4x^2\), \(ab = 6x\), \(b^2 = 9\).
  4. Answer: \((2x - 3)(4x^2 + 6x + 9)\). The trinomial part \(4x^2 + 6x + 9\) has no common factor and doesn't factor further, so you are done.

Step 4 of 5Practice

Type your answer and press Check. For a squared factor, type it like (x+6)^2. If you miss twice, open the worked solution. Then mark how it went.

Factor \(x^2 - 49\).

\(x^2 = (x)^2\) and \(49 = 7^2\), with a minus between. Difference of squares with \(a = x\), \(b = 7\).

Answer: \((x + 7)(x - 7)\).

Factor \(16x^2 - 9\).

\(16x^2 = (4x)^2\) and \(9 = 3^2\). Difference of squares with \(a = 4x\), \(b = 3\).

Answer: \((4x + 3)(4x - 3)\).

Factor \(x^2 + 12x + 36\).

\(x^2 = (x)^2\) and \(36 = 6^2\). Middle test: \(2 \cdot x \cdot 6 = 12x\). It matches, with a plus sign.

Answer: \((x + 6)^2\).

Factor \(4x^2 - 20x + 25\).

\(4x^2 = (2x)^2\) and \(25 = 5^2\). Middle test: \(2 \cdot 2x \cdot 5 = 20x\). It matches, with a minus sign.

Answer: \((2x - 5)^2\). Check: \((2x-5)(2x-5) = 4x^2 - 10x - 10x + 25 = 4x^2 - 20x + 25\).

Factor \(x^3 + 64\).

\(x^3 = (x)^3\) and \(64 = 4^3\). Sum of cubes with \(a = x\), \(b = 4\).

SOAP: \((a + b)(a^2 - ab + b^2)\). Fill in \(a^2 = x^2\), \(ab = 4x\), \(b^2 = 16\).

Answer: \((x + 4)(x^2 - 4x + 16)\).

Factor \(27x^3 - 1\).

\(27x^3 = (3x)^3\) and \(1 = 1^3\). Difference of cubes with \(a = 3x\), \(b = 1\).

SOAP: \((a - b)(a^2 + ab + b^2)\). Fill in \(a^2 = 9x^2\), \(ab = 3x\), \(b^2 = 1\).

Answer: \((3x - 1)(9x^2 + 3x + 1)\).

Factor completely: \(2x^2 - 50\).

Neither 2 nor 50 is a perfect square, so take out the GCF first: \(2x^2 - 50 = 2(x^2 - 25)\).

Inside is a difference of squares: \(x^2 - 25 = (x + 5)(x - 5)\).

Answer: \(2(x + 5)(x - 5)\). Stopping at \(2(x^2 - 25)\) is not complete, because \(x^2 - 25\) still factors.

Which polynomial is prime (cannot be factored)?

  1. \(x^2 - 36\)
  2. \(x^2 + 36\)
  3. \(x^3 + 8\)
  4. \(x^2 + 4x + 4\)

(a) Difference of squares: \((x + 6)(x - 6)\). Factors.

(b) A sum of squares. No pattern fits. Thinking of it as \(x^2 + 0x + 36\): two numbers that add to 0 are opposites (like \(6\) and \(-6\)), so they multiply to a negative number or to 0, never \(36\). Prime. This one.

(c) Sum of cubes: \((x + 2)(x^2 - 2x + 4)\). Factors.

(d) Perfect square trinomial: \((x + 2)^2\). Factors.

Step 5 of 5Wrap-up

You can now spot four patterns and factor them in one step: difference of squares, perfect square trinomials, and sums and differences of cubes. You also know that a sum of squares is prime.

Read or watch next: OpenStax Intermediate Algebra 2e, 6.3 Factor Special Products (free textbook, with more practice at the end of the section).

Also good: Khan Academy: Factoring quadratics: perfect squares (short videos). Quick rules: Factoring cheat sheet.

Something unclear? Ask your teacher bot a follow-up question, for example: "How can I tell quickly whether a number like 196 is a perfect square?" It knows this course and can explain things another way.