Audited 05 Aug 2026·Last updated 28 Oct 2026·3 citations·Tier 2·0 uses

Characteristic Polynomial Calculator

Get the characteristic polynomial of a 2×2 matrix, λ² − tr(A)λ + det(A), from its four entries, with the trace and determinant shown as separate results.

Characteristic Polynomial Calculator

Constant coefficient (determinant)
-2
The determinant ad − bc, which is the constant term of the characteristic polynomial and the product of the two eigenvalues.
Trace
5
Characteristic polynomial
lambda^2 - (5)lambda + (-2)

Background.

Eigenvalues are the numbers that say what a matrix does along its own preferred directions: stretch, shrink, flip or rotate. They decide whether a population model grows or dies out, whether a mechanical system oscillates, and whether an equilibrium of a differential equation is stable. To find them you need the characteristic polynomial first, because the eigenvalues are exactly its roots.

For a 2×2 matrix the polynomial has a pleasingly compact form. Writing out det(λI − A) and expanding gives λ² − (a + d)λ + (ad − bc). The coefficient of λ is minus the trace, the sum of the diagonal entries; the constant term is the determinant. So two numbers you can read off almost at a glance carry everything the polynomial knows, and they have a meaning of their own: the trace is the sum of the two eigenvalues and the determinant is their product.

That link makes the trace and determinant useful even before you solve anything. A negative determinant means the eigenvalues are real and of opposite sign. The quantity tr² − 4·det, the discriminant of the quadratic, tells you whether the eigenvalues are two distinct real numbers, one repeated value, or a complex pair, which is what you get from a matrix that rotates the plane.

This page handles real 2×2 matrices and reports the trace, the determinant and the polynomial built from them. It stops short of solving the quadratic, so the eigenvalues themselves come from applying the quadratic formula to the result. Larger matrices need a determinant expansion or a numerical method and are not covered here.

What is characteristic polynomial calculator?

The characteristic polynomial of a square matrix A is p(λ) = det(λI − A), where I is the identity matrix of the same size and λ is a variable. Its roots are the eigenvalues of A. For a 2×2 matrix it is always a quadratic with leading coefficient 1, whose λ coefficient is minus the trace of A and whose constant term is the determinant of A.

How to use this calculator.

  1. Write the matrix as [[a11, a12], [a21, a22]], row by row, and enter each entry in the field with the same position label. Swapping a12 and a21 leaves the result unchanged, but moving an entry onto or off the diagonal does not.
  2. Use decimals for fractions, for example 0.5 rather than 1/2; entries can be negative.
  3. Read the determinant (the constant coefficient) and the trace, then the polynomial, which is displayed as lambda^2 − (trace)lambda + (determinant) with the signs left inside the brackets.
  4. To get the eigenvalues, solve the quadratic: λ = (trace ± √(trace² − 4 × determinant)) ÷ 2.

The formula.

For a 2x2 matrix, det(lambda I-A)=lambda^2-tr(A)lambda+det(A)

For A = [[a, b], [c, d]], det(λI − A) = (λ − a)(λ − d) − bc = λ² − (a + d)λ + (ad − bc). The trace, tr(A) = a + d, is computed first, then the determinant, det(A) = ad − bc, and the polynomial is assembled as λ² − tr(A)λ + det(A). Some textbooks define the polynomial as det(A − λI) instead; for a 2×2 matrix the two definitions give exactly the same quadratic, because swapping the sign of a 2×2 matrix leaves its determinant unchanged. The off-diagonal entries b and c only enter through their product, so they affect the determinant but never the trace. Every coefficient is exact for the entries you type; no eigenvalues are approximated.

A worked example.

Example

Take A = [[1, 2], [3, 4]]. The trace is the sum of the diagonal, 1 + 4 = 5. The determinant is 1 × 4 − 2 × 3 = 4 − 6 = -2. The characteristic polynomial is therefore λ² − 5λ + (−2), which simplifies to λ² − 5λ − 2. Solving it, the discriminant is 5² − 4 × (−2) = 33, so λ = (5 ± √33) ÷ 2, giving about 5.372 and −0.372. They add to 5, the trace, and multiply to −2, the determinant. One positive and one negative eigenvalue is what a negative determinant predicts: for the system x′ = Ax, the origin is a saddle. As a check, A² = [[7, 10], [15, 22]], and A² − 5A − 2I is the zero matrix, as the Cayley–Hamilton theorem requires.

a1
b2
c3
d4

Frequently asked questions.

How do I get the eigenvalues from this polynomial?
Set the polynomial to zero and use the quadratic formula: λ = (tr ± √(tr² − 4·det)) ÷ 2. For the matrix [[1, 2], [3, 4]] that gives (5 ± √33) ÷ 2, roughly 5.372 and −0.372. If the number under the root is negative, the two eigenvalues are complex conjugates.
My textbook writes det(A − λI). Will I get a different answer?
Not for a 2×2 matrix. In general det(A − λI) equals (−1)ⁿ det(λI − A) for an n × n matrix, so the two conventions differ only by an overall sign when n is odd. With n = 2 the factor is +1 and the quadratics are identical, as are their roots.
What does it mean when the eigenvalues come out complex?
It happens when tr² is smaller than 4·det, and it signals rotation: no real direction is simply stretched. The matrix [[0, −1], [1, 0]], a quarter turn, has trace 0 and determinant 1, so its polynomial is λ² + 1 with roots i and −i. In a differential equation, complex eigenvalues produce oscillation.
How do the trace and determinant tell me if an equilibrium is stable?
For the linear system x′ = Ax, a negative determinant always gives a saddle, which is unstable. With a positive determinant, a negative trace means both eigenvalues have negative real parts and solutions decay to the origin, while a positive trace means they grow. This trace–determinant test lets you classify the equilibrium without solving for the eigenvalues.
Does a zero determinant mean something special?
Yes. If the determinant is zero, the constant term vanishes and λ = 0 is a root, so the matrix has a zero eigenvalue and is not invertible. It collapses some direction in the plane onto a line or a point, and the other eigenvalue is simply equal to the trace.
Can I use this for a 3×3 matrix?
No, only 2×2 matrices are handled. A 3×3 characteristic polynomial is a cubic whose λ² coefficient is still minus the trace and whose constant term is minus the determinant, but the middle coefficient involves the sum of the 2×2 principal minors, which needs all nine entries.

How this page was produced

Published by
Quanta Calculator
Primary sources
3 cited below
Method
For a 2x2 matrix, det(lambda I-A)=lambda^2-tr(A)lambda+det(A)
Published
Last verified

Built with AI assistance and verified by automated tests against the cited sources — every worked example on this page is computed by the same code that runs the calculator. How we build and check calculators.

In this category

Embed

Quanta Pro

Paid features are coming later.

  • All 1560 calculators remain free
  • No billing is enabled
Coming soon