About Difference of Squares Calculator
This difference of squares calculator factors any expression of the form a² - b² into (a - b)(a + b) and shows the pattern being applied. It is free, needs no sign-up and runs in your browser, so nothing you enter is uploaded.
Both terms must be perfect squares and the sign between them must be a minus. The page opens on 4x² - 25, where 4x² is (2x)² and 25 is 5², giving (2x - 5)(2x + 5).
The calculator keeps going while a factor is still a difference of squares, so x⁴ - 16 becomes (x - 2)(x + 2)(x² + 4). The x² + 4 factor is a sum of squares and does not factor over the real numbers.
How to use Difference of Squares Calculator
- Pick Polynomial or Whole number.
- For a polynomial, type it using ^ for powers, for example x^3 + x^2 + 2x + 2, or use the keypad.
- Read the factored form at the top. It updates as you type.
- Open the steps to see each method applied, and the expansion check underneath.
- For a whole number, read the factor pairs, the full list of factors and the prime factorization.
Features
- Greatest common factor taken out first, including numbers and powers of x.
- Difference of squares, sum of cubes and difference of cubes recognised by pattern.
- Perfect square trinomials and general trinomials through the rational root theorem.
- Factoring by grouping for four-term polynomials.
- Repeated application, so x⁴ - 16 splits into (x - 2)(x + 2)(x² + 4).
- An expansion check that multiplies the factors back out.
- Whole-number mode with factor pairs, all factors and the prime factorization.
- Math keypad and live preview, usable on a phone.
Difference of squares
The middle terms cancel when the two brackets are multiplied.
a² - b² = (a - b)(a + b)Worked examples
4x² - 25 gives (2x - 5)(2x + 5)
(2x)² - 5².
x⁴ - 16 gives (x - 2)(x + 2)(x^2 + 4)
Applied twice: x⁴ - 16 = (x² - 4)(x² + 4), then x² - 4 = (x - 2)(x + 2).
3x² - 12 gives 3(x - 2)(x + 2)
Take out 3 first, then factor x² - 4.
Privacy: how it works
- Everything is calculated by code running in your browser tab. The expressions you enter are not sent to Ulkaa or to any other server, and there is nothing to sign in to.
Tips
- Always take out the greatest common factor first. It often turns a hard trinomial into an easy one.
- Multiply your factors back out to check them. The calculator does this for you under the steps.
- If a quadratic is irreducible over the rationals, its discriminant is not a perfect square. Try the quadratic formula calculator for its exact roots.
Frequently asked questions
Is it really free?
Yes. There is no price, no trial and no credit card. Ulkaa Tool does the work with your own device, so there is no server bill to pass on to you.
Do I need an account?
No. There is no sign-up and no login. Open the page and use it. An Ulkaa account is not needed for anything on this tool.
Does it run in my browser?
Yes. Expressions are processed by code running in your browser tab, on your own device.
Is my data uploaded?
No. Expressions are never sent to Ulkaa or to anyone else. You can check this yourself by watching the Network tab in your browser developer tools while you use the tool.
Does a sum of squares factor?
Not over the real numbers. x² + 9 has no real factors, although it factors with complex numbers as (x - 3i)(x + 3i).
What if there is a common factor?
Take it out first. 3x² - 12 becomes 3(x² - 4), and then the difference of squares gives 3(x - 2)(x + 2).
More Factoring Calculator pages
- Factoring CalculatorType a polynomial to factor it with every step, or switch to a whole number for its factor pairs.
- Factor Trinomials CalculatorType a trinomial and get its two factors with the working.
- Sum and Difference of Cubes CalculatorType a cubic like 27x³ + 8 and see it factored with the cube formulas.
- Factor by Grouping CalculatorType a four-term polynomial and see it factored by grouping.
- Perfect Square Trinomial CalculatorType a trinomial and see whether it is a perfect square.
- GCF of a Polynomial CalculatorType a polynomial and see its greatest common factor taken out.
- Factor Pairs CalculatorEnter a whole number to get all its factor pairs and factors.