Associated Topics || Dr. Math Home || Search Dr. Math

### Factoring by Grouping

```
Date: 11/24/97 at 20:36:09
From: Tammy
Subject: Factoring by grouping

This is Algebra II. The directions say to factor the expression by
grouping. Here is the problem:

xy + ay - bx - ab

Here is what I did so far.

I put xy+ay together making it y(x+a)
I put bx-ab together making it b(x-a)

now my problem is y(x+a)-b(x-a).

I know that somehow, by making the first (x+a) negative, I can use
that as the first part. It would be something like (a-x)-(y-b) but I
am not sure. How do I get (x+a) and (x-a) to be the same and how do I
do this problem?

Some other problems that I am having trouble on are:

2xy - ay - 6bx + 3ab
x^2 + 2x - 3x^2 - 6

ANY help that you could give me would be greatly appreciated.

Tammy
```

```
Date: 12/01/97 at 12:16:01
From: Doctor Mark
Subject: Re: Factoring by grouping

Hi Tammy,

First of all, when you tried to factor by grouping the first two
terms, and the second two terms, it actually did work, though you
made a small mistake that made it look like it didn't.  You wrote

xy + ay -  bx - ab = [xy + ay] - [bx - ab]

But that's not quite right: isn't - [bx - ab] = -bx + ab? (You
want it to equal - bx - ab!). What you should have gotten was:

xy + ay -  bx - ab = [xy + ay] - [bx + ab]

Don't feel *too* bad, though; this is the kind of "stupid" mistake
that smart people make *all the time*; you just have to be extra
careful around minus signs, since they can drive you *nuts* if you're
not careful. I've probably done about a million problems like this,
and I still make minus sign mistakes (though not that often anymore).

So let's talk about factoring by grouping...

Factoring by grouping when the polynomial has four terms is really
easy, though books don't make it look like it is. Here's how to do it.

Let's look at your example:  xy + ay -  bx - ab.

We can group the first term (xy) with either of the three remaining
terms (with the ay, the - bx, or the - ab). Let's try each of those
possibilities:

(1)  xy + ay -  bx - ab = [xy + ay] - [bx + ab]
(grouping the first with the second, and remembering that
- bx - ab = - [bx +ab]).

(2)  xy + ay -  bx - ab = [xy - bx] + [ay - ab]
(grouping the first with the third)

(3)  xy + ay -  bx - ab = [xy - ab] + [ay - bx]
(grouping the first with the fourth)

Notice that when we group the first term with one of the other
terms, the remaining two terms automatically get grouped together.

Now, for each of these three groupings, we look for a common factor
of each of the pairs we grouped together:

For 1: [xy + ay]: common factor of y, so take it out:
[xy + ay] = y(x + a)

[bx + ab]: common factor of b, so take it out:
[bx + ab] = b(x + a)

Now look at the quantities in the two parentheses. Are they the
same? Here, yes, they are both equal to (x + a). That means that we
can factor out (x + a) :

xy + ay - bx - ab =
[xy + ay] - [bx + ab] =
y(x + a) - b(x + a) =
(y - b)(x + a)

and we're done: there's no reason to look at numbers 2 or 3, since we
already have the answer, but let's see how it would go anyway.

For 2: [xy - bx]: common factor of x, so take it out:
[xy - bx] = x(y - b)

[ay - ab]: common factor of a, so take it out:
[ay - ab] = a(y - b)

Now look at the quantities in the two parentheses. Are they the
same? Here, yes, they are both equal to (y - b). That means that we
can factor out (y - b), obtaining:

xy + ay - bx - ab = =
[xy -bx] + [ay - ab] = =
x(y - b) + a(y - b) = =
(x + a)(y - b).

Notice that this is the same one we got before, except that the
order of the factors is reversed.

Now let's try grouping 3:

[xy - ab] :  no common factors here

[ay - bx]  : and no common factors here either.

What this means is that we can't factor this polynomial by grouping
the first term with the fourth term (and hence the second with the
third). This doesn't mean that we can't factor the polynomial by
grouping (how could it?  we already factored it using number 2 or
number 3!), it just means that we can't factor the polynomial by
grouping in this way!

So here's the deal: either a polynomial can be factored by
grouping, or it can't.

If it can be factored by grouping, then two of the three groupings
will "work," and the other one won't.  Which ones will work?  You
can't tell until you try it.

If the polynomial cannot be factored by grouping, then none of the
three groupings will work.

Said another way, try grouping the first term with the second. If
that "works," then fine:  you're done. If it doesn't "work," try
grouping the first term with the third term.  If it works, fine; if
it doesn't, try grouping the first with the fourth term. If that
works, fine; if it doesn't, then since none of the three possible
groupings "works,"  the polynomial cannot be factored by grouping.

Here's something to think about:  if you've tried two of the
groupings, and neither "worked," then you don't have to try the
third grouping: it won't work either. Do you see why?

Let's try this method on one of the other examples:
x^2 + 2x - 3x^2 - 6. Now I don't think you meant to write that third
term as - 3x^2; I think you meant to write it as - 3x.
If you *did* mean it to be -3x^2, you can still factor it  by
grouping, but it would be easier to just combine the x^2 and the
- 3x^2 as x^2 - 3x^2 = - 2x^2, and then factor the equivalent
polynomial:

- 2x^2 + 2x - 6 = - 2(x^2 - x + 6).

The polynomial in () cannot be factored (at least not "over the
integers"), so we're done.

So let's try factoring the polynomial x^2 + 2x - 3x - 6, using
grouping. Now it would be simpler to just combine the two linear
terms and factor as usual, but let's see how it goes using grouping:

First, let's try grouping the first term (x^2) with the second term
(2x):

x^2 + 2x - 3x - 6= [x^2 + 2x] - [3x + 6].
{It is + 6, right Tammy? ;<)  }

The terms in the first group, [x^2 + 2x], have a common factor of x,
so take it out:

[x^2 + 2x] = x(x+2).

The terms in the second group, [3x + 6], have a common factor of 3,
so take it out:

[3x + 6] = 3(x + 2).

So this way of grouping works, since we found a common factor of
(x + 2): (remembering the minus sign!)

x^2+2x-3x-6 =
[x^2 + 2x] - [3x + 6] =
x(x+2) - 3(x + 2) =
(x - 3) (x + 2)

Since this grouping "worked," you'd have to be a math masochist to
try the others, but let's see:

Grouping the first with the third:

x^2+2x-3x-6 =
[x^2 - 3x] + [2x - 6] =
x(x - 3) + 2(x - 3) =
(x + 2)(x - 3)

which is the same answer as before, but with the order of the
factors reversed.

Grouping the first with the fourth:

x^2+2x-3x-6 [x^2 - 6]+[2x - 3x] =
[x^2 - 6]+x[2 - 3] =
[x^2 - 6]+x[-1]

The two groups do not have a common factor, so this grouping doesn't
work.

Hope this was of help Tammy, and be sure to write back if there was
anything I said that was not clear.

-Doctor Mark,  The Math Forum
Check out our web site!  http://mathforum.org/dr.math/
```
Associated Topics:
Middle School Factoring Expressions

Search the Dr. Math Library:

 Find items containing (put spaces between keywords):   Click only once for faster results: [ Choose "whole words" when searching for a word like age.] all keywords, in any order at least one, that exact phrase parts of words whole words

Submit your own question to Dr. Math
Math Forum Home || Math Library || Quick Reference || Math Forum Search