# Factoring Difference of Two Perfect Squares

At some point in your study of algebra, you’ll be asked to factor expressions by recognizing some special patterns. The **difference of two squares** is one of the most common. The good news is, this form is very easy to identify.

Whenever you have a binomial with each term being squared (having an exponent of 2), and they have subtraction as the middle sign, you are guaranteed to have the case of difference of two squares.

The diagram below should provide an intuitive understanding of this concept.

After verifying that you have a difference of two squares, you can now factor it out as a product of two binomials with **alternating signs** in the middle, positive and negative.

## Formula for Difference of Two Squares

These are **other ways** to write the formula of the difference of two squares using variables. Learn to recognize them in various appearances so that you know exactly how to handle them.

### Examples of How to Factor Difference of Two Perfect Squares

Let’s go over some examples!

**Example 1:** Factor the binomial below using the difference of two squares method.

The first term of the binomial is definitely a perfect square because the variable x is being raised to the second power. However, the second term of the binomial is not written as a square. So we need to rewrite it in such a way that 9 is expressed as some number with a power of 2. I hope you can see that 9 = {\left( 3 \right)^2}. Clearly, we have a difference of two squares because the sign between the two squared terms is subtraction.

For this example, the solution is broken down in just a few steps to highlight the procedure. Once you get comfortable with the process, you can skip a lot of steps. In fact, you can go straight from the difference of two squares to its factors.

**Example 2:** Factor the binomial below.

At first, it appears that this is not a difference of two squares. What we need is to try rewriting it in the form that is easily recognizable.

For the first term of the binomial, what term when multiplied by itself gives 4{x^2}? That should be 2x since

For the second term, the number when multiplied by itself gives 49 is 7 because

The solution to this problem looks like this,

**Example 3:** Factor the binomial below.

This problem is a little bit different because both terms of the binomial contain variables. If we can show that they are perfect squares then we should be alright!

- The first term is a perfect square since

- More so, the second is also a perfect square because

Applying the formula for the difference of two squares we get,

**Example 4:** Factor the binomial below.

Here’s an interesting problem. Maybe you already recognize that the pure numbers, 16 and 81, are perfect squares. That’s good. The variable y though doesn’t have an exponent of 2, but instead has an exponent of 4. Does this qualify to be a square?

Don’t be quick to conclude that it is not. Can you think of a term which when multiplied by itself gives {y^4}? You can do a trial and error on this. But if you apply your previous knowledge of the Product Rule of Exponents, it makes sense that

In fact, whenever the exponent of a variable is an even number, that expression can be expressed as a perfect square. Why? Because all even numbers are factorable by the number 2.

Now, we can truly rewrite this binomial as the difference of two squares with distinct terms that are being raised to the second power; where 16{y^4} = {\left( {4{y^2}} \right)^2} and 81 = {\left( 9 \right)^2}

Putting this together, we get

Now you can break this up into two binomial factors with alternating signs,

Are we done already? Well, examine carefully the binomials you factored out. The second parenthesis is possibly a case of difference of two squares as well since 4{y^2} = \left( {2y} \right)\left( {2y} \right) and clearly, 9 = \left( 3 \right)\left( 3 \right).

This means you have to apply the formula for the difference of two squares one more time.

Here’s the complete solution to this problem.

**Example 5:** Factor the binomial below.

Notice that the binomial has only one kind of variable which is “x“. The basic strategy when you see something similar to this is to factor out the greatest common factor (GCF) among the variables.

Between {x^4} and {x^{12}}, the GCF is {x^4}. If you factor this out, you get

Now we can deal with the binomial inside the parenthesis. It is actually a difference of two squares because we can express each term of the binomial as an expression with a power of 2.

Then we apply the formula for the difference of two squares,

Are we done? Nope! The second parenthesis is still a case of difference of two squares. We have no choice but to factor it out one more time.

Scan through the binomials again to see if there is still a case of difference of two squares. The last binomial definitely fits the criteria.

Let’s work this out one last time and we’re done!

**Example 6:** Factor the binomial below.

I want to throw in this type of problem because you may encounter something similar to this in your studies. First, recognize that it is a binomial where the first term is {\left( {x - 3} \right)^2} and the second term is 4. Since both are squared terms and being separated by subtraction, this is truly a case of difference of two squares.

You may keep it in that form as your final answer. But the best answer is to combine like terms by adding or subtracting the constants. This also simplifies the answer by getting rid of the inner parenthesis.

**You might also be interested in:**

Factoring Difference of Two Squares Practice Problems

Factoring Sum and Difference of Two Cubes

Factoring Sum and Difference of Two Cubes Practice Problems