Square of a Binomial Calculator
Use this Square of a Binomial Calculator to expand expressions such as \( (x+3)^2 \), \( (2x-5)^2 \), and \( (ax+b)^2 \). The calculator applies the identities \( (a+b)^2=a^2+2ab+b^2 \) and \( (a-b)^2=a^2-2ab+b^2 \), then shows the result.
Select formula and enter parameters
Choose the binomial structure and enter numeric coefficients. The calculator treats the first term as \(px\) and the second term as \(q\).
Enter \(p\) and \(q\) for \( (px+q)^2 \).
For \( (2x+3)^2 \), the expanded result is \(4x^2+12x+9\). For \( (2x-3)^2 \), the middle term changes sign: \(4x^2-12x+9\).
Results
Square of a binomial formula
The square of a binomial is one of the most important algebra identities. A binomial is an expression with two terms, such as \(x+3\), \(2x-5\), \(a+b\), or \(3m+7\). When a binomial is squared, it means the binomial is multiplied by itself. The two main formulas are:
These formulas are sometimes called special products or perfect square identities. They are useful because they let you expand expressions quickly without doing the full multiplication every time. The calculator above applies the same identities to expressions of the form \( (px+q)^2 \), \( (px-q)^2 \), or a signed expression \( (px+q)^2 \) where \(q\) may be negative.
The most common mistake is writing \( (a+b)^2=a^2+b^2 \). That is incorrect because it leaves out the middle term \(2ab\). The correct expansion contains three terms: the square of the first term, twice the product of the two terms, and the square of the second term.
How to use the Square of a Binomial Calculator
- Select the formula form. Choose \( (px+q)^2 \), \( (px-q)^2 \), or the signed custom form.
- Enter the coefficient \(p\). This is the number multiplying the variable. For \(2x+3\), \(p=2\).
- Enter the number \(q\). This is the constant term. For \(2x+3\), \(q=3\).
- Choose the variable. You can use \(x\), \(y\), \(m\), \(t\), or another simple variable symbol.
- Click Expand Binomial. The calculator expands the binomial and shows the identity used.
- Read the steps. The step-by-step section explains how the first term, middle term, and last term are produced.
This calculator is designed to help students understand the pattern, not just get an answer. The formula is shown in mathematical notation, the substitution is displayed, and the final trinomial is written in simplified form. This makes it useful for algebra homework, classroom demonstrations, test preparation, and quick checking.
What does “square of a binomial” mean?
The phrase square of a binomial means multiplying a two-term expression by itself. For example, \( (x+5)^2 \) does not mean \(x^2+5^2\). It means:
Now expand by multiplying every term in the first parentheses by every term in the second parentheses:
The two middle terms combine:
That is why the formula contains \(2ab\). The middle term appears twice: once from \(a\cdot b\) and once from \(b\cdot a\). In the case of \( (x+5)^2 \), the two middle products are \(5x\) and \(5x\), giving \(10x\).
Why \( (a+b)^2 \neq a^2+b^2 \)
This is one of the most common algebra errors. The square applies to the entire binomial, not separately to the two terms. Because \(a+b\) is a sum, squaring it means multiplying the whole sum by itself:
Expanding gives:
Then combine like terms:
The missing term \(2ab\) is usually the reason students lose marks on this topic. The expression \(a^2+b^2\) would only be part of the expansion. It ignores the two cross-products created by multiplication. A quick numerical check proves the difference. If \(a=2\) and \(b=3\), then \( (2+3)^2=25 \), but \(2^2+3^2=4+9=13\). Since \(25\neq13\), the shortcut \( (a+b)^2=a^2+b^2 \) is false.
Plus form: expanding \( (a+b)^2 \)
The plus form is used when the two terms are added. The identity is:
For example, expand \( (2x+3)^2 \). Let \(a=2x\) and \(b=3\). Then:
Now simplify each part:
So the final answer is:
The result is a trinomial because it has three terms. More specifically, it is a perfect square trinomial because it comes from squaring a binomial.
Minus form: expanding \( (a-b)^2 \)
The minus form is used when the second term is subtracted. The identity is:
The first and last terms are still positive because they are squares. The middle term is negative because the product of the first term and second term appears twice with a negative sign. For example, expand \( (2x-3)^2 \). Let \(a=2x\) and \(b=3\):
Simplify each part:
So:
Notice that the only difference between \( (2x+3)^2 \) and \( (2x-3)^2 \) is the sign of the middle term. The first and last terms remain \(4x^2\) and \(9\).
General form for \( (px+q)^2 \)
The calculator is built around the common algebra form \( (px+q)^2 \). Here, \(p\) is the coefficient of the variable and \(q\) is the constant term. To expand it, treat \(px\) as the first term and \(q\) as the second term:
Simplify:
For the minus version:
These formulas are exactly what the calculator uses. It computes the coefficient of \(x^2\) as \(p^2\), the coefficient of \(x\) as \(2pq\) or \(-2pq\), and the constant term as \(q^2\). If you use the signed custom mode and enter a negative value for \(q\), the same formula \(p^2x^2+2pqx+q^2\) automatically handles the sign.
Worked example: \( (3x+4)^2 \)
Let:
Identify the two terms:
Use the plus identity:
Substitute:
Simplify:
Final answer:
You can check this by multiplying \( (3x+4)(3x+4) \). The result is the same: \(9x^2+12x+12x+16=9x^2+24x+16\).
Worked example: \( (5y-2)^2 \)
Now consider a binomial with subtraction:
Let:
Use the minus identity:
Substitute:
Simplify each part:
Final answer:
The middle term is negative because the binomial contains subtraction. The constant term is still positive because \(2^2=4\).
Perfect square trinomials
When the square of a binomial is expanded, the result is a perfect square trinomial. For example:
The trinomial \(x^2+12x+36\) is a perfect square trinomial because it can be factored back into \( (x+6)^2 \). Similarly:
Both trinomials have the same first and last terms. The middle term changes sign depending on whether the binomial uses plus or minus. Recognizing perfect square trinomials is useful when factoring, solving quadratic equations, completing the square, graphing parabolas, and simplifying algebraic expressions.
A trinomial is a perfect square when the first term and last term are perfect squares and the middle term is twice the product of their square roots. For example, in \(x^2+10x+25\), the square roots of \(x^2\) and \(25\) are \(x\) and \(5\). Twice their product is \(2(x)(5)=10x\), so the trinomial factors as \( (x+5)^2 \).
Connection to completing the square
The square of a binomial is the foundation of completing the square. Completing the square is a method used to rewrite a quadratic expression in vertex form. For example, start with:
To make this into a perfect square trinomial, take half of \(8\), which is \(4\), and square it:
Then:
This works because \( (x+4)^2=x^2+8x+16 \). Completing the square is used to derive the quadratic formula, graph parabolas, find vertices, solve quadratic equations, and analyze maximum or minimum values. That is why mastering binomial squares is important before moving to more advanced algebra topics.
Geometric meaning of \( (a+b)^2 \)
The identity \( (a+b)^2=a^2+2ab+b^2 \) has a clear geometric interpretation. Imagine a square whose side length is \(a+b\). Its area is:
Now split each side into two parts, \(a\) and \(b\). The large square can be divided into four smaller regions: one square of area \(a^2\), two rectangles of area \(ab\), and one square of area \(b^2\). Therefore:
This area model explains why the middle term exists. It is not an arbitrary rule. The two rectangles represent the two cross-products created when the binomial is multiplied by itself. This visual explanation is especially helpful for students who struggle to remember why \(2ab\) appears.
Square of a binomial and FOIL
FOIL stands for First, Outer, Inner, Last. It is a method for multiplying two binomials. Since \( (a+b)^2=(a+b)(a+b) \), FOIL gives the same result:
First terms:
Outer terms:
Inner terms:
Last terms:
Combine:
The formula is essentially a shortcut for FOIL. Once you understand the shortcut, expansion becomes faster and less error-prone.
Common mistakes when squaring binomials
- Leaving out the middle term. The expansion of \( (a+b)^2 \) is not \(a^2+b^2\). The correct expansion includes \(2ab\).
- Using the wrong sign in the middle term. For \( (a-b)^2 \), the middle term is negative: \(a^2-2ab+b^2\).
- Making the last term negative. In \( (a-b)^2 \), the last term is \(+b^2\), not \(-b^2\).
- Forgetting to square coefficients. \( (3x)^2=9x^2 \), not \(3x^2\).
- Forgetting to square the variable. \( (px)^2=p^2x^2 \).
- Mixing up \( (a-b)^2 \) and \( a^2-b^2 \). These are different identities. \( (a-b)^2=a^2-2ab+b^2 \), while \(a^2-b^2=(a-b)(a+b)\).
- Rushing the sign when \(q\) is negative. If \(q\) is negative in \( (px+q)^2 \), the middle term becomes negative automatically because \(2pq\) is negative.
The safest approach is to identify the first term and second term before expanding. Then use the phrase: square the first, double the product, square the last.
Square of a binomial versus difference of squares
Students often confuse binomial squares with the difference of squares. These are related but different identities. The square of a binomial is:
The difference of squares is:
The difference of squares has no middle term because the cross-products cancel:
In a square of a binomial, the two factors are the same. In a difference of squares, the two factors are conjugates. This distinction is essential for factoring and expanding correctly.
Square of a binomial summary table
| Expression | Identity | Example | Expanded result |
|---|---|---|---|
| \((a+b)^2\) | \(a^2+2ab+b^2\) | \((x+4)^2\) | \(x^2+8x+16\) |
| \((a-b)^2\) | \(a^2-2ab+b^2\) | \((x-4)^2\) | \(x^2-8x+16\) |
| \((px+q)^2\) | \(p^2x^2+2pqx+q^2\) | \((2x+3)^2\) | \(4x^2+12x+9\) |
| \((px-q)^2\) | \(p^2x^2-2pqx+q^2\) | \((2x-3)^2\) | \(4x^2-12x+9\) |
Why this calculator is useful
A square of a binomial calculator is useful because it shows both the result and the reasoning. Many online tools only output the expanded expression, but students often need to understand the identity behind the answer. This calculator shows the original expression, the formula pattern, the first-term square, the middle term, the last-term square, and the simplified trinomial.
It is especially helpful when coefficients are involved. Expanding \( (x+3)^2 \) is simple, but expanding \( (7x-11)^2 \) requires more careful arithmetic. The first term is \(49x^2\), the middle term is \(-154x\), and the last term is \(121\). The calculator reduces the chance of arithmetic errors and reinforces the correct pattern.
It also supports different variables, so users can expand expressions such as \( (4y+5)^2 \), \( (2t-9)^2 \), or \( (6m+1)^2 \). The variable changes, but the formula stays the same.
Related calculators and study tools
After learning how to square a binomial, students often continue with factoring, quadratics, completing the square, and polynomial identities. These related tools can help users continue naturally through algebra practice.
Update these internal links if your final NUM8ERS URL structure uses different calculator paths.
Square of a Binomial Calculator FAQs
What is the square of a binomial?
The square of a binomial means multiplying a two-term expression by itself. For example, \( (x+3)^2=(x+3)(x+3) \).
What is the formula for \( (a+b)^2 \)?
The formula is \( (a+b)^2=a^2+2ab+b^2 \). The middle term \(2ab\) comes from the two cross-products.
What is the formula for \( (a-b)^2 \)?
The formula is \( (a-b)^2=a^2-2ab+b^2 \). The middle term is negative, but the last term \(b^2\) is positive.
Is \( (a+b)^2=a^2+b^2 \)?
No. That is a common mistake. The correct identity is \( (a+b)^2=a^2+2ab+b^2 \).
What is a perfect square trinomial?
A perfect square trinomial is a trinomial that comes from squaring a binomial, such as \(x^2+10x+25=(x+5)^2\).
How do I expand \( (px+q)^2 \)?
Use \( (px+q)^2=p^2x^2+2pqx+q^2 \). Square the first term, double the product of both terms, and square the last term.