Sometimes, the only way to get through mathematical calculations is by brute force. But every so often, you can save a lot of work by recognizing special problems that you can use a standardized formula to solve. Finding the sum of cubes and finding the difference of cubes are two examples of exactly that: Once you know the formulas for factoring *a*^{3} + *b*^{3} or *a*^{3} - *b*^{3}, finding the answer is as easy as substituting the values for a and b into the correct formula.

## Putting It Into Context

First, a quick look at why you might want to find – or more appropriately "factor" – the sums or difference of cubes. When the concept is first introduced, it's a simple math problem in and of itself. But if you keep studying math, later on this will become an intermediate step in more complex calculations. So if you get *a*^{3} + *b*^{3} or *a*^{3} − *b*^{3} as an answer during other calculations, you can use the skills you're about to learn to break those cubed numbers apart into simpler components, which often makes it easier to continue solving the original problem.

## Factoring the Sum of Cubes

Imagine that you've arrived at the binomial

and are asked to simplify it. The first term, *x*^{3}, is obviously a cubed number. After a little examination, you can see that the second number is actually a cubed number too: 27 is the same as 3^{3}. Now that you know both numbers are cubes, you can apply the formula for the sum of cubes.

## Write Both Numbers as Cubes

## Write Out the Formula for the Sum of Cubes

## Substitute the Values From Step 1 Into the Formula

Write out both numbers in their cubed form, if that isn't already the case. To continue this example, you'd have:

Once you're used to the process, you might skip this step and go straight to filling the values from Step 1 into the formula. But especially when you're learning, it's best to go step by step and remind yourself of the formula:

Compare the left side of this equation to the result from Step 1. Note that you can substitute *x* in place of *a,* and 3 in place of *b.*

Substitute the values from Step 1 into the formula in Step 2. So you have:

For now, arriving at the right side of the equation represents your answer. This is the result of factoring the sum of two cubed numbers.

## Factoring the Difference of Cubes

Factoring the difference of two cubed numbers works the same way. In fact, the formula is almost identical to the formula for the sum of cubes. But there is one critical difference: Pay special attention to where the minus sign goes.

## Identify Your Cubes

## Write Out the Formula for Difference of Cubes

## Substitute the Values From Step 1 Into the Formula

Imagine that you get the problem

and have to factor it. As before, *y*^{3} is an obvious cube, and with a little thought you should be able to recognize that 125 is actually 5^{3}. So you have:

As before, write out the formula for the difference of cubes. Notice that you can substitute *y* for *a* and 5 for *b*, and take special note of where the minus sign goes in this formula. The location of the minus sign is the only difference between this formula and the formula for the sum of cubes.

Write the formula out again, this time substituting the values from Step 1. This yields:

Again, if all you have to do is factor the difference of the cubes, this is your answer.