What does a sum of cubes look like?

The other two special factoring formulas you'll need to memorize are very similar to one another; they're the formulas for factoring the sums and the differences of cubes. Here are the two formulas:

Factoring a Sum of Cubes:

a3 + b3 = (a + b)(a2 − ab + b2)

Factoring a Difference of Cubes:

a3 − b3 = (a − b)(a2 + ab + b2)

You'll learn in more advanced classes how they came up with these formulas. For now, just memorize them.

What does a sum of cubes look like?

To help with the memorization, first notice that the terms in each of the two factorization formulas are exactly the same. Then notice that each formula has only one "minus" sign. The distinction between the two formulas is in the location of that one "minus" sign:

For the difference of cubes, the "minus" sign goes in the linear factor, a − b; for the sum of cubes, the "minus" sign goes in the quadratic factor, a2 − ab + b2.

Some people use the mnemonic "SOAP" to help keep track of the signs; the letters stand for the linear factor having the "same" sign as the sign in the middle of the original expression, then the quadratic factor starting with the "opposite" sign from what was in the original expression, and finally the second sign inside the quadratic factor is "always positive".

a3 ± b3 = (a [Same sign] b)(a2 [Opposite sign] ab [Always Positive] b2)

Whatever method best helps you keep these formulas straight, use it, because you should not assume that you'll be given these formulas on the test. You should expect to need to know them.

Note: The quadratic portion of each cube formula does not factor, so don't waste time attempting to factor it. Yes, a2 − 2ab + b2 and a2+ 2ab + b2 factor, but that's because of the 2's on their middle terms. These sum- and difference-of-cubes formulas' quadratic terms do not have that "2", and thus cannot factor.

When you're given a pair of cubes to factor, carefully apply the appropriate rule. By "carefully", I mean "using parentheses to keep track of everything, especially the negative signs". Here are some typical problems:

This is equivalent to x3 − 23. With the "minus" sign in the middle, this is a difference of cubes. To do the factoring, I'll be plugging x and 2 into the difference-of-cubes formula. Doing so, I get:

x3 − 8 = x3 − 23

= (x − 2)(x2 + 2x + 22)

= (x − 2)(x2 + 2x + 4)

The first term contains the cube of 3 and the cube of x. But what about the second term?

Before panicking about the lack of an apparent cube, I remember that 1 can be regarded as having been raised to any power I like, since 1 to any power is still just 1. In this case the power I'd like is 3, since this will give me a sum of cubes. This means that the expression they've given me can be expressed as:

So, to factor, I'll be plugging 3x and 1 into the sum-of-cubes formula. This gives me:

27x3 + 1 = (3x)3 + 13

= (3x + 1)((3x)2 − (3x)(1) + 12)

= (3x + 1)(9x2 − 3x + 1)

First, I note that they've given me a binomial (a two-term polynomial) and that the power on the x in the first term is 3 so, even if I weren't working in the "sums and differences of cubes" section of my textbook, I'd be on notice that maybe I should be thinking in terms of those formulas.

Looking at the other variable, I note that a power of 6 is the cube of a power of 2, so the other variable in the first term can be expressed in terms of cubing, too; namely, as the cube of the square of y.

The second term is 64,  which I remember is the cube of 4. (If I didn't remember, or if I hadn't been certain, I'd have grabbed my calculator and tried cubing stuff until I got the right value, or else I'd have taken the cube root of 64.)

So I now know that, with the "minus" in the middle, this is a difference of two cubes; namely, this is:

Plugging into the appropriate formula, I get:

x3y6 − 64 = (xy2)3 − 43

= (xy2 − 4)((xy2)2 + (xy2)(4) + 42)

= (xy2 − 4)(x2y4 + 4xy2 + 16)

Um... I know that 16 is not a cube of anything; it's actually equal to 24. What's up?

What's up is that they expect me to use what I've learned about simple factoring to first convert this to a difference of cubes. Yes, 16 = 24, but 8 = 23, a cube. I can get 8 from 16 by dividing by 2. What happens if I divide 250 by 2? I get 125, which is the cube of 5. So what they've given me can be restated as:

I can apply the difference-of-cubes formula to what's inside the parentheses:

23x3 − 53 = (2x)3 − (5)3

= (2x − 5)((2x)2 + (2x)(5) + (5)2)

= (2x − 5)(4x2 + 10x + 25)

Putting it all together, I get a final factored form of:

2(2x − 5)(4x2 + 10x + 25)

My first reaction might be to go straight to applying the difference-of-cubes formula, since 125 = 53. But what about that "minus" sign in front?

Since neither of the factoring formulas they've given me includes a "minus" in front, maybe I can factor the "minus" out...?

−x3 − 125 = −1x3 − 125

Aha! Now what's inside the parentheses is a sum of cubes, which I can factor. I've got the sum of the cube of x and the cube of 5, so:

x3 + 53 = (x + 5)((x)2 − (x)(5) + (5)2)

Putting it all together, I get:

You can use the Mathway widget below to practice factoring a sum of cubes. Try the entered exercise, or type in your own exercise. Then click the button to compare your answer to Mathway's. (Or skip the widget and continue with the lesson.)

Please accept "preferences" cookies in order to enable this widget.

(Clicking on "Tap to view steps" on the widget's answer screen will take you to the Mathway site for a paid upgrade.)

URL: https://www.purplemath.com/modules/specfact2.htm

The sum or difference of two cubes can be factored into a product of a binomial times a trinomial.

That is, x 3 + y 3 = ( x + y ) ( x 2 − x y + y 2 ) and x 3 − y 3 = ( x − y ) ( x 2 + x y + y 2 ) .

A mnemonic for the signs of the factorization is the word "SOAP", the letters stand for "Same sign" as in the middle of the original expression, "Opposite sign", and "Always Positive".

That is, x 3 ± y 3 = ( x [ Same     sign ] y ) ( x 2 [ Opposite     sign ] x y [ Always     Positive ] y 2 )

Example 1:

Factor 27 p 3 + q 3 .

Try to write each of the terms as a cube of an expression.

27 p 3 + q 3 = ( 3 p ) 3 + ( q ) 3

Use the factorization of sum of cubes to rewrite.

27 p 3 + q 3 = ( 3 p ) 3 + ( q ) 3                                               = ( 3 p + q ) ( ( 3 p ) 2 − 3 p q + q 2 )                                               = ( 3 p + q ) ( 9 p 2 − 3 p q + q 2 )

Example 2:

Factor 40 u 3 − 625 v 3 .

Factor out the GCF from the two terms.

40 u 3 − 625 v 3 = 5 ( 8 u 3 − 125 v 3 )

Try to write each of the terms in the binomial as a cube of an expression.

8 u 3 − 125 v 3 = ( 2 u ) 3 − ( 5 v ) 3

Use the factorization of difference of cubes to rewrite.

5 ( 8 u 3 − 125 v 3 ) = 5 ( ( 2 u ) 3 − ( 5 v ) 3 )                                                                       = 5 [ ( 2 u − 5 v ) ( ( 2 u ) 2 + 10 u v + ( 5 v ) 2 ) ]                                                                       = 5 ( 2 u − 5 v ) ( 4 u 2 + 10 u v + 25 v 2 )