Descartes Rule of Signs Calculator
Count sign changes in polynomial coefficients to predict the number of positive and negative real roots.
Enter the polynomial coefficients in descending order of degree, separated by commas, then click Analyze.
Descartes Rule of Signs Calculator
Count sign changes in polynomial coefficients to predict the number of positive and negative real roots.
About Descartes' Rule of Signs
Descartes' Rule of Signs is a classical theorem in algebra, first published by René Descartes in his 1637 work La Géométrie. The rule provides a quick upper bound on the number of positive and negative real roots a polynomial can have, simply by inspecting the signs of its coefficients — without finding the roots themselves.
The rule for positive roots states: the number of positive real roots of a polynomial f(x) with real coefficients is either equal to the number of sign changes in the sequence of non-zero coefficients, or is less than that count by an even number. Each reduction by two accounts for a pair of complex conjugate roots replacing a pair of real roots.
To apply the rule for negative roots, substitute −x for x in the polynomial to form f(−x), then count the sign changes in the resulting coefficient sequence. The count gives the maximum number of negative real roots, again reducible by even integers.
For example, consider f(x) = x³ − 2x² + 5x − 3. The coefficients in order are 1, −2, 5, −3. Reading the signs: +, −, +, − gives three sign changes (+ to −, − to +, + to −). So f(x) has either 3 or 1 positive real roots. For f(−x) = −x³ − 2x² − 5x − 3, the signs are −, −, −, −, giving 0 sign changes and therefore 0 negative real roots.
An important subtlety: zero coefficients (terms that are absent from the polynomial) are ignored when counting sign changes. Only non-zero coefficients participate in the sign sequence. This means that x⁴ − x² + 1 is analyzed using coefficients [1, −1, 1], not [1, 0, −1, 0, 1].
The rule is powerful because it is computationally trivial — you only need to inspect signs, not compute any roots. This makes it an ideal first step in polynomial analysis: if the rule tells you a polynomial has at most one positive root, you can focus your numerical root-finding efforts accordingly.
However, the rule provides only an upper bound, not an exact count. A polynomial may have fewer positive or negative roots than the maximum because complex conjugate pairs can 'replace' real root pairs. The rule also says nothing about the magnitude or multiplicity of the roots, and it does not detect complex roots at all.
In practice, Descartes' Rule is used in conjunction with other techniques such as the Rational Root Theorem, Sturm's theorem, or numerical methods. Engineers use it for stability analysis of control systems, economists use it to bound equilibria in market models, and mathematicians use it as a teaching tool to connect the algebraic structure of polynomials with their geometric behavior.
Sign Analysis Examples
Step-by-step examples showing how sign changes predict root counts.
| Coefficients | Positive roots | Negative roots |
|---|---|---|
| 1, −3, 2 → f(x) = x²−3x+2 | 2 or 0 | Signs +−+ → 2 changes. f(−x) signs ++: 0 changes → 0 negative roots. Actual roots: x=1, x=2. |
| 1, −2, 5, −3 → f(x) = x³−2x²+5x−3 | 3 or 1 | Signs +−+− → 3 changes. f(−x) = −x³−2x²−5x−3 signs −−−−: 0 changes → 0 negative roots. |
| 1, 0, −1 → f(x) = x²−1 | 1 | Non-zero signs +−: 1 change → exactly 1 positive root. f(−x) = x²−1 signs +−: 1 change → 1 negative root. Roots: x=1, x=−1. |
| 1, 1, 1 → f(x) = x²+x+1 | 0 | Signs +++: 0 changes → 0 positive roots. f(−x) = x²−x+1 signs +−+: 2 changes → 2 or 0 negative roots. Complex roots only. |
How to Use the Descartes Rule of Signs Calculator
- Write your polynomial in standard form, with terms in descending order of degree (highest power first).
- List the coefficients of each term, including zero for any missing powers, separated by commas. For example, x³ − 2x² + 5x − 3 becomes 1,-2,5,-3.
- Click Analyze Signs. The calculator counts sign changes in the coefficient sequence for f(x) and for f(−x) separately.
- Read the Positive Real Roots section to see the maximum number of positive real roots and all possible counts (reduced by even numbers).
- Read the Negative Real Roots section for the corresponding analysis of f(−x) to find bounds on negative real roots.
Descartes Rule of Signs FAQ
What does a sign change mean in Descartes' Rule?
A sign change occurs whenever two consecutive non-zero coefficients in the polynomial have opposite signs. For example, in the sequence +, −, +, − there are three sign changes. Zero coefficients are skipped entirely when scanning for sign changes.
Why can the actual root count be less than the number of sign changes?
Every time a pair of complex conjugate roots exists, it 'replaces' two real roots. Because complex roots come in pairs for polynomials with real coefficients, the reduction from the maximum is always by an even number (2, 4, 6, …). This is why possible positive root counts are the sign-change count minus 0, 2, 4, and so on.
How do I apply the rule for negative roots?
Replace every x with −x in the polynomial to form f(−x). This flips the sign of every term with an odd-degree variable. Then count sign changes in the new coefficient sequence. The result gives the maximum number of negative real roots of the original polynomial f(x).
Should I include zero coefficients when counting sign changes?
No. Zero coefficients are ignored. Only the signs of non-zero coefficients matter. The polynomial x⁴ − x² + 1 has non-zero coefficients [1, −1, 1], giving two sign changes (positive/negative/positive), not four changes from the full five-term sequence.
Does the rule work for all polynomials?
The rule applies to any polynomial with real coefficients. It does not apply to polynomials with complex coefficients. It also provides no information about complex roots — only about real positive and negative roots. The degree of the polynomial tells you the total number of roots (counting multiplicity and complex roots) via the Fundamental Theorem of Algebra.
What does it mean when the rule predicts 0 positive roots?
If there are zero sign changes in the coefficient sequence of f(x), the polynomial has no positive real roots. All real roots are either negative, zero, or the polynomial has no real roots at all. You can then use the f(−x) analysis to check for negative roots, and any remaining roots must be complex.