Goal: Understand like terms, expanding, and factoring.

As always, looking for the structure of an expression before even writing anything down is crucial to using the correct properties!

Algebraic expressions are just operations, numbers, and variables mixed together. For example \[2x^2 - 3x + 4 \qquad \sqrt{x} + 10 \qquad (x + 1)(x + 2) \qquad (a + b + c)^2(x^2y + 3)\] are all algebraic expressions.

To add and subtract algebraic expressions, look for **like terms**.

Like terms are terms with the same factors except possibly for the numerical factor (called the **coefficient**).

Which are like terms?

- $x^3$ and $3x^3$
- $-4x^2y^2$ and $3y^2x^2$
- $-(x+2)(x+1)$ and $3(x+1)(x+2)$

Remember: identify the factors. This is your guiding light.

To add like terms, we undo the distributive law: \[x^3 + 2x^3 = 1\cdot x^3 + 2\cdot x^3 = x^3(1 + 2) = 3x^3\]

In essence, add together the coefficients for like terms.

Add and subtract the following:

- $x^3 + 2x^2 + 3x^3$
- $(4x^2y + 3xy^2) - (3x^2y^2 - 2xy^2)$

Multiplying is also called **expanding**. Expanding problems are just the distributive law applied.

In expanding problems, you always start with **factors** and you end with **terms** (context if not explicitly mentioned is always the entire expression).

Look at the distibutive law: \[a\cdot(b + c) = a\cdot b + a \cdot c\]

The Law is saying for the **factor** $a$ outside the parenthesis, distibutive it to each **term** within the parenthesis.

Expand the following:

- $(2x + 1)(3x - 5)$
- $(x^2 + 2x + 1)(x + 1)$

Here are three formulas you should be able to recall by heart. Your calculus professor will expect you to immediately be able to see these, especially the first one.

- $(A + B)(A - B) = A^2 - B^2$
- $(A + B)^2 = A^2 + 2AB + B^2$
- $(A - B)^2 = A^2 - 2AB + B^2$

Note that $A$ just needs to be a **term**. $A$ could be $(x + y)$. It could be $2x$. Hopefully you are starting to see the importance of identifying terms/factors. It is in everything we do!

Expand the following using the formulas:

- $(2x + 1)^2$
- $(2x - 3)(2x + 3)$ \
- $(x + y - z)(x + y + z)$

Consider this expanding problem: \[(x+4)(x+3) = x^2 + 7x + 12\] The expression structure on the left is all factors.

On the right, it is all terms.

If we start from the right and move backwards instead, this process is called **factoring**.

Factoring converts terms into factors and is the reverse process of expanding.

Identify all terms.

For each term, identify the factors.

From each term, pull out all factors in common among all terms.

Factor each expression:

- $3x^2 - 6x$
- $8x^4y^2 + 6x^3y^3 - 2xy^4$
- $(2x + 4)(x-3) - 5(x-3)$

This method works on three terms. Some examples include \[x^2 + 4x + 3 \qquad\qquad x^2 - 4 \qquad\qquad 2(x+1)^2 - 7(x+1) + 3\]

See this handout for the idea. Let's call this the "new" X method.

Factor:

- $x^2 + 7x + 12$
- $6x^2 + 7x - 5$
- $(5a+1)^2 - 2(5a+1) - 3$

The three special product formulas give the special factoring formulas.

- $A^2 - B^2 = (A-B)(A+B)$
- $A^2 + 2AB + B^2 = (A+B)^2$
- $A^2 - 2AB + B^2 = (A-B)^2$

Factor:

- $4x^2 - 25$
- $(x+y)^2 - z^2$

This method works on four terms.

We group first two/last two terms together, then use GCF on both groups.

Factor:

- $x^3 +x^2 + 4x + 4$
- $x^3 - 2x^2 - 9x + 18$

The last example shows even though we did have all factors, we sometimes can keep factoring a factor. We may need to use multiple methods.

Remember, before even starting a factoring problem, **identify the terms and how many there are.**

Doing so helps you to choose a correct strategy.

Factor:

- $2x^4 - 8x^2$
- $3x^2y - 16xy + 5y$