What is the FOIL Method?
FOIL is a mnemonic for multiplying two binomials: First, Outer, Inner, Last. It guarantees you multiply every term in the first binomial by every term in the second. This calculator takes the four numbers a, b, c, and d from the binomials \((a + b)\) and \((c + d)\) and shows each partial product plus the fully expanded result.
How to Use It
Enter the two terms of each binomial. If you are expanding something like \((2x + 3)(x - 4)\), set \(a = 2\), \(b = 3\), \(c = 1\), \(d = -4\). The calculator treats a and c as the coefficients of x, so the answer is reported as a quadratic: $$\text{a}\,\text{c}\cdot x^{2} + \left(\text{a}\,\text{d} + \text{b}\,\text{c}\right)\cdot x + \text{b}\,\text{d}$$ For purely numeric multiplication, just read the four F/O/I/L products and add them.
The Formula Explained
The distributive property gives $$\left(\text{a} + \text{b}\right)\left(\text{c} + \text{d}\right) = \text{a}\cdot\text{c} + \text{a}\cdot\text{d} + \text{b}\cdot\text{c} + \text{b}\cdot\text{d}$$ Each letter pairing maps to FOIL: First \(= \text{ac}\), Outer \(= \text{ad}\), Inner \(= \text{bc}\), Last \(= \text{bd}\). The Outer and Inner products are the "middle" terms that are usually combined.
Worked Example
Expand \((2x + 3)(x + 4)\): $$\text{F} = 2\cdot 1 = 2,\quad \text{O} = 2\cdot 4 = 8,\quad \text{I} = 3\cdot 1 = 3,\quad \text{L} = 3\cdot 4 = 12$$ Combine the middle terms: \(8 + 3 = 11\). The result is $$2x^{2} + 11x + 12$$
More Worked Examples
Each example uses the FOIL pattern \((ax+b)(cx+d)=ac\,x^2+(ad+bc)x+bd\). Watch how signs carry through every product.
Example 1: A negative term — \((x-5)(x+2)\)
Here \(a=1,\ b=-5,\ c=1,\ d=2\).
- First: \(x\cdot x = x^2\)
- Outer: \(x\cdot 2 = 2x\)
- Inner: \(-5\cdot x = -5x\)
- Last: \(-5\cdot 2 = -10\)
Combine the like middle terms \(2x-5x=-3x\):
$$ (x-5)(x+2) = x^2 - 3x - 10 $$
You can confirm the trinomial \(x^2-3x-10\) factors back to these binomials with the factoring calculator.
Example 2: Difference of squares — \((x+3)(x-3)\)
Here \(a=1,\ b=3,\ c=1,\ d=-3\).
- First: \(x\cdot x = x^2\)
- Outer: \(x\cdot(-3) = -3x\)
- Inner: \(3\cdot x = 3x\)
- Last: \(3\cdot(-3) = -9\)
The Outer and Inner terms cancel: \(-3x+3x=0\), leaving
$$ (x+3)(x-3) = x^2 - 9 $$
This illustrates the difference-of-squares rule \((x+n)(x-n)=x^2-n^2\).
Example 3: A perfect square — \((2x+1)^2\)
Rewrite as \((2x+1)(2x+1)\), so \(a=2,\ b=1,\ c=2,\ d=1\).
- First: \(2x\cdot 2x = 4x^2\)
- Outer: \(2x\cdot 1 = 2x\)
- Inner: \(1\cdot 2x = 2x\)
- Last: \(1\cdot 1 = 1\)
Combine \(2x+2x=4x\):
$$ (2x+1)^2 = 4x^2 + 4x + 1 $$
This matches the perfect-square rule \((mx+n)^2 = m^2x^2 + 2mnx + n^2\).
How to FOIL Step by Step
FOIL is an ordered way to apply the distributive property to two binomials \((ax+b)(cx+d)\). The letters stand for First, Outer, Inner, Last — the four pairs of terms you multiply.
- Multiply the First terms. Multiply the first term of each binomial: \(ax\cdot cx = ac\,x^2\). This gives the squared term.
- Multiply the Outer terms. Multiply the two terms on the outside of the expression: \(ax\cdot d = ad\,x\).
- Multiply the Inner terms. Multiply the two terms on the inside: \(b\cdot cx = bc\,x\).
- Multiply the Last terms. Multiply the last term of each binomial: \(b\cdot d = bd\). This is the constant term.
- Combine like middle terms. The Outer and Inner products both contain \(x\), so add them: \(ad\,x + bc\,x = (ad+bc)x\). Pay close attention to signs here.
- Write the result as \(ax^2+bx+c\). Assemble the three pieces in standard order: $$ ac\,x^2 + (ad+bc)x + bd. $$
Tip: if the two binomials are identical (a perfect square) or are conjugates like \((x+n)(x-n)\), the middle terms either double up or cancel — a quick check that you combined them correctly.
Key Terms
- Binomial
- A polynomial with exactly two terms joined by a plus or minus sign, such as \(x+3\) or \(2x-5\).
- Trinomial
- A polynomial with exactly three terms, such as \(x^2-3x-10\). Multiplying two binomials usually produces a trinomial.
- Coefficient
- The numerical factor multiplying a variable in a term. In \(2x\) the coefficient is \(2\); a term like \(x^2\) has an understood coefficient of \(1\).
- Term
- A single number, variable, or product of numbers and variables separated from others by \(+\) or \(-\). In \(x^2-3x-10\) the terms are \(x^2\), \(-3x\), and \(-10\).
- FOIL
- A mnemonic — First, Outer, Inner, Last — for the four products formed when multiplying two binomials. It is a special case of the distributive property.
- Like terms
- Terms that have the same variable raised to the same power, so they can be added or subtracted. The Outer and Inner products \(ad\,x\) and \(bc\,x\) are like terms and combine into \((ad+bc)x\).
- Distributive property
- The rule \(p(q+r)=pq+pr\). FOIL applies it twice so that every term in the first binomial multiplies every term in the second.
FAQ
Can I use negative numbers? Yes — enter a minus sign, e.g. \(d = -4\) for \((x - 4)\).
Does it work for plain numbers? Absolutely. Set the coefficients to 1 (\(a = 1\), \(c = 1\)) and the F/O/I/L table gives the four products; their sum is your answer.
What if I don't have an x at all? Then set \(a = 1\) and \(c = 1\); the \(x^{2}\) term becomes 1 and you can read the total from the combined terms.