A difference of cubes sounds an awful lot like a difference of squares , but it factors quite differently. A difference of cubes always starts off as a binomial with a subtraction sign in between.

In this section we will learn new formula that will allow us to factor the difference of two cubes.

For example, we want to factor the binomial $x^{3}-27$, which is the difference of two cubes. To see that it is the difference of two cubes, it can be written as $x^{3}-3^{3}$.

## Difference of Cubes Formula

The formula that allow us to factor the difference of two cubes are given below:

$a^{3}-b^{3}$ =
$(a-b)(a^{2}+ab+b^{2})$

## Factoring Difference of Cubes

To discover the formula for factoring the difference of two cubes, we find the following product

$(a-b)(a^{2}+ab+b^{2})$ = $a(a^{2}+ab+b^{2}) - b(a^{2}+ab+b^{2})$

= $a^{3}+a^{2}b+ab^{2}-a^{2}b-ab^{2}-b^{3}$

= $a^{3}-b^{3}$

Hence the factors of difference of cubes $a^{3}-b^{3}$ are the difference $(a-b)$ and the trinomial $a^{2}+ab+b^{2}$

## Difference of Cubes Examples

The following are the example for difference of cubes.

### Solved Examples

Question 1: Factor $a^{3}-64b^{3}$
Solution:

The binomial $a^{3}-64b^{3}$ is the difference of two cubes.

$a^{3}-64b^{3}$ = $a^{3}-(4b)^{3}$

Factors can be written by using the formula

$a^{3}-b^{3}$ = $(a-b)(a^{2}+ab+b^{2})$

That is $a^{3}-(4b)^{3}$ = $(a-4b)(a^{2}+4ab+16b^{2})$

Thus, its factors are the difference $(a-4b)$ and the trinomial $a^{2}+4ab+16b^{2}$

Question 2: Factor $8a^{6}-125b^{3}$
Solution:

The binomial $8a^{6}-125b^{3}$ is the difference of two cubes.

$8a^{6}-125b^{3}$ = $(2a^{2})^{3}-(5b)^{3}$

Factors can be written by using the formula

$a^{3}-b^{3}$ = $(a-b)(a^{2}+ab+b^{2})$

That is $(2a^{2})^{3}-(5b)^{3}$ = $(2a^{2}-5b)((2a^{2})^{2}+10a^{2}b+25b^{2})$

= $(2a^{2}-5b)(4a^{4}+10a^{2}b+25b^{2})$

Thus, its factors are the difference $(2a^{2}-5b)$ and the trinomial $4a^{4}+10a^{2}b+25b^{2}$

Question 3: Factor $x^{3}-8$
Solution:

The binomial $x^{3}-8$ is the difference of two cubes.

$x^{3}-8$ = $x^{3}-(2)^{3}$

Factors can be written by using the formula

$a^{3}-b^{3}$ = $(a-b)(a^{2}+ab+b^{2})$

That is $x^{3}-(2)^{3}$ = $(x-2)(x^{2}+2x+4)$

Thus, its factors are the difference $(x-2)$ and the trinomial $x^{2}+2x+4$