Both patterns turn two cubed terms into a binomial times a trinomial, and the trinomial stops there. The sections below show why the patterns work, which traps cost the most points (a missed common factor, a sixth power, a doubled middle term), and quick ways to verify an answer in seconds.
What are the sum and difference of cubes formulas?
Here are the two patterns side by side:
The letters and stand for whatever is being cubed: a number, a variable, or a product like . These belong to the family of special products of binomials, but unlike squares, a cube pattern works for both the sum and the difference.
The signs follow SOAP: Same, Opposite, Always Positive. The binomial keeps the sign of the original expression, the middle sign of the trinomial is the opposite one, and the last sign is always positive. The trinomial’s outer terms are and , which can never be negative, so a minus sign in front of is an instant red flag.
| Expression | Binomial factor | Trinomial factor |
|---|---|---|
Before using either pattern, confirm that both terms are perfect cubes. The coefficient must be one of , and every variable exponent must be a multiple of . So and qualify, but and do not.
Quick check
Answer:
Why does the cube factoring pattern work?
The quickest proof is to multiply it out. The trinomial is designed so that every middle term cancels:
The cancels with , and cancels with . If you want practice with that expansion, multiplying polynomials covers the distributing step in detail.
There is a second way to see it, and it explains where the trinomial comes from. If , then , so must be a factor, which is exactly what the factor theorem says. Divide by and the quotient is . The same reasoning with gives the factor for the sum.
Replace with in . Since , you get . Memorize one pattern and the other follows.
How do you factor a sum or difference of cubes?
The test is simple: two terms, both perfect cubes, joined by a plus or minus sign. The process has five steps:
- Take out any common factor first.
- Rewrite each term as something cubed.
- Read off and , the cube roots.
- Substitute into the matching formula, keeping and inside parentheses.
- Simplify, and stop. The trinomial will not factor.
Example 1. Factor .
Here and , so and . The plus sign calls for the sum of cubes:
The parentheses in step 4 prevent the most common slip: writing as instead of . With two variables the method is identical. For , take and to get , where the middle term is .
Factoring cubes with a GCF, negatives or fractions
Many expressions hide their cubes behind a common factor. If the coefficients are not perfect cubes, check for a GCF before giving up. Factoring out the GCF first is also a rule for every cube problem, because it keeps the numbers small.
Example 2. Factor .
Neither nor is a cube, but . Pull out the :
The stays in front of the final answer. Dropping it is one of the most common ways to lose a point. A variable can be a hidden GCF too: .
When the cube term comes second, as in , treat the expression as . Then and :
For fractions, you can cube the fraction directly or factor out the fraction first. Using the first approach, . Using the second, . Both are the same expression, since and .
Sixth powers: difference of squares or cubes first?

An expression like is both a difference of squares and a difference of cubes, because . Both routes are legal, but only one is easy. The rule: squares first.
Example 3. Factor completely.
Using squares first, . Each piece is now a cube pattern:
Using cubes first, . The first factor splits as , but the quartic looks stuck. It is not: . That is the same answer, but you needed a difference of two squares hidden inside a perfect-square rewrite. Starting with squares avoids that detour.
A sum of sixth powers behaves differently. is not a difference of squares, so only the cube route exists: . That quartic equals , and since is not a perfect square, it does not factor over the integers. Stop there.
Quick check
Answer:
Why the trinomial in a sum of cubes never factors
Treat as a quadratic in . Its discriminant is , which is negative for every real except . A negative discriminant means no real roots, so no real linear factors. The same calculation works for .
Expanding and subtracting leaves . So , which shows why is not simply .
Students often waste time hunting for factors of the trinomial anyway. For , you would need two numbers that multiply to and add to , and none exist. If you want to see how the discriminant decides this, quadratic formula practice problems work through that test, and factoring trinomials shows what a trinomial that does split looks like.
Two look-alikes cause most of the confusion. A perfect square trinomial has a middle coefficient of , as in . The cube trinomial has a middle coefficient of , so it is never a perfect square. And comes from the binomial theorem, not from the sum of cubes pattern.
Solving equations and simplifying fractions with cubes
Factoring turns a cubic equation into a product that equals zero. To solve :
The first factor gives . The quadratic has discriminant , so the other two solutions are complex: . Every nonzero number has exactly one real cube root and two complex ones, and the trinomial is where the complex pair lives. The rational root theorem would find from a list of candidates, but the formula gives you the full factorization without any trial and error.
Cube patterns also simplify rational expressions. Factor the top and bottom, then cancel:
Test at : the original gives , and the simplified form gives . This cancellation is exactly the step used in calculus limits like , where the simplified form shows the limit is .
Real use: the volume of a hollow cube

Picture a cube with side and a cube-shaped cavity of side cut out of one corner. The material left has volume , and the formula gives it in a more useful shape:
The three terms in the trinomial are areas of three slabs. Each slab has height , and their bases are , and . Together they make up the whole shell, with no overlap.
Try and . Direct subtraction gives . The factored form gives . The two methods agree, and the factored form is the one engineers use when is a known wall thickness.
The sum pattern has a neat numeric use as well. Since , it factors as . Any number just above or below a perfect cube can often be split this way.
Quick check
Answer: cubic centimeters
How do you check a sum or difference of cubes answer?
Three quick checks catch nearly every error:
- Substitute an easy number such as into both the original and your answer. They must match. For Example 1, and .
- Scan the signs. The trinomial’s outer terms must be positive, and its middle term must be the product of the two binomial pieces, with the opposite sign from the binomial.
- Test the root. The binomial factor gives a root of the original expression, so should make equal to zero. Synthetic division by gives the coefficients with remainder , which is exactly the trinomial .
Avoid as your test value. It only checks the constant term, so a wrong sign in the middle of the trinomial would slip through. Use , then if you want a second confirmation.
Try this: Factor , then check your answer at . The left side should equal , which is .
For mixed sets that combine cubes with grouping, trinomials and squares, work through factoring practice problems and decide which pattern fits before you start.
Practice problems
0 of 5 solved
- Factor .
Answer:
Write , so and . Use the sum of cubes pattern . The result is . - Factor .
Answer:
Write , so and . Use . The result is . - Factor .
Answer:
Write , so and . Then , and . The sum of cubes pattern gives . - Factor .
Answer:
Take out the GCF: . Now , so and . This gives . - Factor completely.
Answer:
Take out the GCF : . Then , so and . The difference of cubes pattern gives .
Common questions
What is the formula for the sum and difference of cubes?
The sum of cubes is and the difference of cubes is . Each one turns a two-term expression into a binomial times a trinomial.
How do you remember the signs in the cubes formulas?
Use SOAP: the binomial has the Same sign as the original expression, the trinomial's middle sign is Opposite, and its last term is Always Positive. The pattern works because the cross terms must cancel when you multiply back.
Can you factor a sum of squares like ?
Not over the real numbers. A sum of cubes does factor, but a sum of squares stays prime unless you allow complex numbers, where .
Can the trinomial in a sum or difference of cubes be factored further?
Not with real numbers. Treated as a quadratic, its discriminant is , which is negative for every real other than , so it has no real roots and no real linear factors.
How do you factor ?
Start with the difference of squares: . Then factor each piece as a difference and a sum of cubes, which gives four factors in total.
What if the coefficients are not perfect cubes?
Look for a common factor first. In , neither nor is a cube, but leaves a perfect cube inside the parentheses.