🔭 Eigenvalue Calculator – Solve Matrix Eigenvalues Instantly
The Eigenvalue Calculator computes the eigenvalues of any real square matrix from 2×2 up to 8×8. Whether you are a student working through linear algebra assignments, an engineer performing vibration or stability analysis, or a data scientist computing principal components, this tool delivers fast, accurate results together with a full step-by-step derivation for 2×2 matrices and a verification summary for all sizes.
What Are Eigenvalues?
Given a square matrix A, a scalar λ (lambda) is an eigenvalue if there exists a non-zero vector v satisfying:
Av = λvThe vector v is called an eigenvector. Geometrically, applying the transformation A to v only stretches or compresses it (by factor λ) without changing its direction. Eigenvalues therefore reveal the fundamental scaling axes of a linear transformation.
How Eigenvalues Are Computed
The Characteristic Polynomial
Eigenvalues are the roots of the characteristic polynomial det(A − λI) = 0, where I is the identity matrix. For a 2×2 matrix A = [[a, b], [c, d]], this expands to:
λ² − (a+d)λ + (ad − bc) = 0Equivalently: λ² − trace(A)·λ + det(A) = 0. Applying the quadratic formula yields the two eigenvalues exactly.
2×2 Exact Mode
For 2×2 matrices the tool uses the closed-form quadratic formula and shows every derivation step: setting up the characteristic equation, expanding the determinant, writing out the polynomial, and computing the final roots. If the discriminant Δ = trace² − 4·det is negative, the eigenvalues are a complex conjugate pair; if it equals zero, there is a repeated eigenvalue.
Larger Matrices – QR Iteration
For matrices of size 3×3 and above, the tool applies the QR iteration algorithm with Wilkinson shifts — the industry-standard numeric method for dense eigenvalue problems. Starting from matrix A:
- Compute the QR decomposition
A = QR(via Gram-Schmidt orthogonalisation). - Form the new iterate
A ← RQ(conjugation by Q preserves eigenvalues). - Apply a Wilkinson shift for accelerated convergence near deflation points.
- Repeat until the sub-diagonal entries converge to zero.
- Read eigenvalues from the resulting quasi-upper triangular (Schur) form: 1×1 diagonal blocks give real eigenvalues; irreducible 2×2 blocks give complex conjugate pairs.
Special Eigenvalue Cases
| Case | Indicator | Example |
|---|---|---|
| Real distinct | Δ > 0 | [[4,2],[1,3]] → λ = 5, 2 |
| Repeated | Δ = 0 | [[2,1],[0,2]] → λ = 2 (×2) |
| Complex pair | Δ < 0 | [[0,−1],[1,0]] → λ = ±i |
Verification: Trace and Determinant Checks
The tool verifies results using two fundamental relationships:
- Sum check:
λ₁ + λ₂ + … + λₙ = trace(A) - Product check:
λ₁ · λ₂ · … · λₙ = det(A)
These identities hold for any square matrix and serve as a quick sanity check on numerical accuracy.
Applications of Eigenvalues
- Principal Component Analysis (PCA): The eigenvectors of the covariance matrix define the principal components; the eigenvalues measure the explained variance along each component.
- Structural engineering: Natural frequencies of vibration in a structure correspond to eigenvalues of the stiffness-mass matrix.
- Control systems: Stability of a dynamic system depends on whether all eigenvalues of the state matrix have negative real parts.
- Google PageRank: Page importance scores are the dominant eigenvector of the web's adjacency matrix.
- Quantum mechanics: Observable quantities (energy, momentum) are eigenvalues of the corresponding quantum operators.
Use the Preset button to instantly load classic matrices such as a rotation matrix (complex eigenvalues), a Jordan block (repeated eigenvalue), or a diagonal matrix. These are great starting points for exploring eigenvalue behaviour.
Frequently Used Formulas
2×2 characteristic polynomial:
λ² − tr(A)·λ + det(A) = 0
Eigenvalue discriminant:
Δ = tr(A)² − 4·det(A)
Quadratic eigenvalues:
λ = (tr(A) ± √Δ) / 2
Trace–eigenvalue identity:
λ₁ + λ₂ + … + λₙ = tr(A)
Determinant–eigenvalue identity:
λ₁ · λ₂ · … · λₙ = det(A)Tips for Accurate Results
- Fractions like
1/2or-3/4can be entered directly in any cell — the tool parses them automatically. - Scientific notation such as
2.5e-4is supported for very small or large values. - For ill-conditioned matrices (very large condition number), increase the decimal precision to see whether results are stable.
- Use the Sort by magnitude option to rank eigenvalues from largest to smallest — useful in PCA and dominant-mode analysis.