Box Method Calculator
Multiply two polynomials using the visual box (area model) method. Every partial product and diagonal combination shown.
Enter the coefficients of two polynomials, P(x) across the top and Q(x) down the side. The calculator builds the full multiplication grid, fills in every partial product, and combines the diagonals into the final answer.
Enter coefficients from highest to lowest degree.
What is the box method?
The box method — also called the area model — multiplies two polynomials by arranging their terms along the top and side of a grid, filling in every cell with the product of the term above and the term beside it, and then adding up the results.
The name comes directly from its visual structure: draw a rectangle (the “box”), split it into rows and columns according to the number of terms in each polynomial, and label the top edge with one polynomial’s terms and the left edge with the other’s. Each interior cell then holds exactly one partial product — the multiplication of just that row’s term and that column’s term.
This turns polynomial multiplication, which can feel error-prone when done as a single long expansion, into a series of small, easy single-term multiplications, organized so that nothing gets missed and nothing gets multiplied twice. The underlying algebra is exactly the distributive property, applied repeatedly — multiplying a sum by another sum means multiplying every term of the first by every term of the second, and the grid is simply a way of making sure that “every term by every term” actually happens, visibly, without relying on memory to track which pairs have already been multiplied.
Once every cell is filled in, the terms that share the same total degree — sitting along the same diagonal of the grid — are combined into the final answer. The name “area model” comes from a geometric interpretation covered later in this article: when both polynomials represent side lengths of a rectangle, the grid’s cells literally correspond to the areas of smaller rectangular pieces that together make up the whole.
Building the grid
For a polynomial P(x) with terms across the top and Q(x) with terms down the side, the grid has as many columns as P(x) has terms and as many rows as Q(x) has terms.
Example setup: P(x) = 2x² + 3x − 1 (three terms) and Q(x) = x − 2 (two terms) produces a 3-column, 2-row grid — six cells in total, one for each possible pairing of a term from P(x) with a term from Q(x).
| × | 2x² | 3x | −1 |
|---|---|---|---|
| x | 2x³ | 3x² | −x |
| −2 | −4x² | −6x | 2 |
Each interior cell is the product of its row label and column label: the top-left cell is x × 2x² = 2x³; the cell below it is −2 × 2x² = −4x²; and so on across all six cells.
Combining the diagonals
Once the grid is filled in, the next step is to identify every cell that shares the same total degree and add those cells together. In the grid above, the two cells 3x² and −4x² both have degree 2, so they combine to −x². The cells −x and −6x both have degree 1, combining to −7x.
Reading the full grid this way: degree 3 has only one cell (2x³), degree 2 combines two cells (3x² and −4x², giving −x²), degree 1 combines two cells (−x and −6x, giving −7x), and degree 0 has only one cell (2). Putting these together in standard form gives the final product:
The “diagonal” terminology comes from how these same-degree cells tend to line up visually along a diagonal line through the grid when the terms are arranged in standard order (highest degree first, both across the top and down the side) — though the important thing is which cells share a degree, not their exact visual position.
Relationship to FOIL
FOIL (First, Outer, Inner, Last) is a shortcut specifically for multiplying two binomials — two two-term polynomials — and it’s really just the box method’s grid shrunk down to its smallest possible size: a 2×2 grid with exactly four cells.
| FOIL step | Box method equivalent |
|---|---|
| First | Top-left cell of a 2×2 box |
| Outer | Top-right cell |
| Inner | Bottom-left cell |
| Last | Bottom-right cell |
The reason the box method is worth learning even after FOIL is that FOIL only works for exactly two binomials. The moment either polynomial has three or more terms — a trinomial times a binomial, for instance — FOIL no longer applies as written, since there’s no longer a clean “first, outer, inner, last” structure. The box method scales to any size grid without changing the underlying idea at all, which is why it’s the more general tool of the two.
It’s also worth noting that FOIL itself is really just a memory aid for the order to multiply four specific pairs of terms — it doesn’t describe any different underlying math from the box method’s 2×2 case. Someone who’s comfortable with the box method already knows FOIL, just without needing the separate acronym; someone who’s only ever learned FOIL will need a genuinely new tool the first time they encounter a trinomial-by-binomial or larger multiplication.
Step-by-step process
- Write both polynomials in standard form, highest degree to lowest, with every coefficient (including any that are zero) accounted for.
- Draw a grid with one column per term of the first polynomial and one row per term of the second.
- Fill in every cell with the product of its column label and row label — a single-term multiplication each time.
- Group cells by total degree. Cells whose row-term degree plus column-term degree add up to the same number belong together.
- Sum each group and write the result in standard form, from highest combined degree to lowest.
Worked examples
Example 1: (x + 3)(x + 5), two binomials
A 2×2 grid: x×x=x², x×5=5x, 3×x=3x, 3×5=15. The two degree-1 cells (5x and 3x) combine to 8x.
Example 2: (x² − 4)(x + 3), a binomial times a binomial with a missing middle term
Written in standard form, P(x) = x² + 0x − 4 conceptually has a zero x-term, though the box method only needs actual nonzero terms as grid labels — here just x² and −4 across the top, and x and 3 down the side. Grid cells: x²×x = x³, x²×3 = 3x², −4×x = −4x, −4×3 = −12. No two cells share a degree here, so nothing needs combining.
Example 3: (2x + 1)(3x² − x + 4), a binomial times a trinomial
This produces a 2-row, 3-column grid (six cells): 2x×3x²=6x³, 2x×(−x)=−2x², 2x×4=8x, 1×3x²=3x², 1×(−x)=−x, 1×4=4. Combining by degree: degree 3 has only 6x³. Degree 2 combines −2x² and 3x² into x². Degree 1 combines 8x and −x into 7x. Degree 0 has only 4.
Checking your answer
A quick way to sanity-check a box method result is to substitute a convenient value — usually x = 1 — into both original polynomials and the final product, and confirm that the numbers agree.
Using example 1 above, (x + 3)(x + 5) with result x² + 8x + 15: at x = 1, the original factors give (1+3)(1+5) = 4 × 6 = 24. Evaluating the result at x = 1 gives 1 + 8 + 15 = 24. The two totals match, which is good (though not airtight) evidence the multiplication was carried out correctly — a genuine error in the grid would usually, though not always, throw off this check.
This substitution check works because multiplying two numbers and multiplying two polynomials are the same underlying operation; plugging in x = 1 just replaces “multiply these two expressions” with “multiply these two specific numbers,” which is far easier to verify by hand or in your head. It’s a fast enough check to run on every box method problem as a matter of routine, especially before committing to an answer on a test.
Common mistakes to avoid
Forgetting to combine cells that share a degree. With a grid larger than 2×2, it’s easy to read off every individual cell as if it were already a final term, skipping the step where same-degree cells get added together first. A 3×2 or larger grid almost always has at least one pair of cells that need combining before the answer is complete.
Mislabeling a cell’s degree. Each cell’s degree is the sum of its row and column term’s degrees, not the degree of either one alone — a cell formed from an x² column and an x row has degree 2+1=3, not degree 2 or degree 1.
Losing a negative sign when multiplying two negative terms. A cell formed from two negative terms is positive — (−4)×(−2) = 8, not −8. This is ordinary sign-of-a-product arithmetic, but it’s easy to get wrong when working through many cells quickly.
Building a grid with the wrong dimensions. The number of columns should always match the number of terms in the polynomial across the top, and the number of rows should match the number of terms in the polynomial down the side — including any terms with a coefficient of zero if they were written out explicitly. A grid that’s the wrong size usually means a term was skipped or double-counted somewhere in the setup.
Adding cells before checking they actually share a degree. It’s tempting to combine two cells that merely look similar — for instance, two cells that both happen to be positive, or both happen to involve the same original term — without first confirming their degrees genuinely match. Only cells whose row-degree-plus-column-degree sum is identical belong in the same group; visual similarity or a shared factor isn’t the test.
When the box method is worth using
For two binomials, FOIL and the box method take about the same amount of work, and either is a reasonable choice. The box method starts to clearly pay off once at least one of the polynomials has three or more terms, since there’s no shortcut mnemonic like FOIL for those cases — the grid structure keeps every partial product organized and visible, which becomes increasingly valuable as the number of cells grows.
It’s also a useful teaching and self-checking tool even for problems that could be done by direct expansion, since a visibly wrong or missing cell is much easier to spot in a grid than a dropped term buried inside a long horizontal expansion.
Real-world applications
Area calculations, literally. The box method’s name isn’t just a metaphor — if a rectangular region’s length and width are each described by a polynomial expression (for instance, length = x + 5 and width = x + 3, both in some unit), the box method’s grid directly represents the physical sub-areas that make up the total rectangle, and the final combined result is the rectangle’s total area as a polynomial in x.
Expanding financial growth models. When compounding two independent growth factors — say, a base amount growing according to one polynomial-in-time expression, multiplied by an inflation-adjustment polynomial — the box method organizes the resulting cross-terms cleanly, the same way it organizes any polynomial multiplication.
Signal processing and polynomial multiplication. Multiplying two polynomials is mathematically the same operation as convolving two sequences of numbers, a core operation in digital signal processing. The box method’s grid is a direct visual representation of every pairwise product a convolution computes, making it a useful bridge for understanding that more abstract operation.
Curriculum use beyond basic algebra. Because the box method generalizes so cleanly to any number of terms, it’s also commonly used later on for multiplying larger polynomials in precalculus and introductory calculus courses, and for organizing long division and factoring problems that rely on the same grid-based thinking.
Combinatorics and generating functions. In more advanced math, polynomials are sometimes used to encode counting problems, where multiplying two polynomials together corresponds to combining two independent choices. The box method’s grid mirrors exactly how those combined choices are enumerated — one cell per way of picking one option from each polynomial — even though the “x” in that context represents a placeholder for a count rather than a numeric variable to solve for.