Factoring a trinomial means rewriting as a product of simpler factors, such as . This factoring trinomials calculator does it the way algebra courses teach it: it first takes out the greatest common factor, then applies the ac method — find two integers whose product is and whose sum is , split the middle term and factor by grouping — and shows every line of the work.
It is honest about the cases where factoring is impossible. When no pair of integers works, the trinomial is prime over the integers, and the calculator says so instead of inventing decimal factors. It then uses the discriminant to tell you why: irrational roots such as , or complex roots when the discriminant is negative. It also recognises perfect square trinomials and differences of squares, and it copes with (a linear expression) or (where itself is a common factor).
Enter integer coefficients only. If your trinomial has fractions, multiply every term by the common denominator first; for decimal coefficients or to solve the equation, use the quadratic formula calculator.
How to use this calculator
- Write the trinomial in standard form , highest power first. A missing term has coefficient 0.
- Enter the integers a, b and c, including their signs.
- Read the factored form. If it says "prime over the integers", no factorisation with integer coefficients exists.
- Open the steps to see the GCF, the product , the pair of integers, the split middle term and the grouping.
- Check the discriminant and roots: each factor gives the root .
The formula
ac method. For a primitive trinomial (common factor already removed), look for integers and with
Then split the middle term and factor by grouping:
where and is the binomial left in both groups.
When does it work? A trinomial with integer coefficients factors over the integers exactly when its discriminant is a perfect square (0, 1, 4, 9, 16…). If is positive but not a perfect square, the roots are irrational; if , they are complex.
Special patterns: (perfect square) and (difference of squares).
Worked example
ac method. Factor . Here ; the pair with product 12 and sum 7 is 3 and 4. Split: , so the answer is .
With a common factor. : take out 2 to get ; the pair −1 and 3 gives .
Perfect square. : , pair −6 and −6, so it is and the discriminant is 0.
Prime trinomials. has , not a perfect square: it is prime over the integers and its roots are ≈ -0.414 and 2.414. And has : complex roots .
Choosing a method
| Situation | Fastest method |
|---|---|
| : | Find two numbers with product and sum : |
| ac method and grouping, or trial and error with the factors of and | |
| First and last terms are squares | Check for a perfect square |
| No term, | Difference of squares |
| Discriminant not a perfect square | Not factorable over the integers: use the quadratic formula |
Always look for a greatest common factor first: it makes the numbers smaller and the remaining trinomial easier to factor. To find the GCF of large coefficients, the GCD calculator helps.
Frequently asked questions
What does "prime over the integers" mean?
It means the trinomial cannot be written as a product of two binomials with integer coefficients. It may still factor over the real numbers with square roots, for example x² − 2 = (x − √2)(x + √2), or only over the complex numbers.
How do I know quickly whether a trinomial factors?
Compute the discriminant b² − 4ac (after removing any common factor). If it is a perfect square such as 0, 1, 4, 9 or 25, the trinomial factors over the integers; otherwise it is prime.
Why take out the greatest common factor first?
It keeps the numbers small and is required for a complete factorisation. For 2x² + 4x − 6, stopping at (2x + 6)(x − 1) is not fully factored, because 2x + 6 still contains the factor 2.
What if the leading coefficient is negative?
Factor out −1 (or the negative GCF) first, so the trinomial left inside starts with a positive x² term. The calculator does this automatically and shows the minus sign in front of the factored form.
Can I factor trinomials with fractions or decimals?
Multiply every term by the least common denominator to get integer coefficients, factor, then divide the constant back out. For decimal coefficients that are not exact fractions, use the quadratic formula to find the roots instead.
Sources
- OpenStax, College Algebra 2e — 1.5 Factoring Polynomials
- OpenStax, Intermediate Algebra 2e — 6.2 Factor Trinomials (the “ac” method)
Last updated: