Jordan Normal Form Calculator
Compute the Jordan canonical form of any square matrix. Decompose A = PJP⁻¹ where J is a block diagonal matrix of Jordan blocks, with step-by-step explanations of eigenvalues, generalized eigenvectors, and block structure.
Enter a matrix and click Decompose
or press Enter
What is Jordan Normal Form?
The Jordan normal form (also called Jordan canonical form) is one of the most important results in linear algebra. For any square matrix A with entries in an algebraically closed field (such as the complex numbers), there exists an invertible matrix P such that A = PJP⁻¹, where J is a block diagonal matrix composed of Jordan blocks. This decomposition reveals the fundamental structure of a linear transformation and generalizes the concept of diagonalization to all square matrices.
Named after the French mathematician Camille Jordan, the Jordan normal form provides a canonical representation for every square matrix up to similarity. Two matrices are similar (represent the same linear transformation in different bases) if and only if they share the same Jordan form. This makes the Jordan form a complete invariant of the similarity class of a matrix.
Jordan Blocks Explained
The Jordan matrix J is a block diagonal matrix where each diagonal block is a Jordan block. A Jordan block Jk(λ) of size k associated with eigenvalue λ is a k×k upper triangular matrix with λ on the main diagonal and 1s on the superdiagonal:
For example, a 3×3 Jordan block for eigenvalue λ looks like:
A 1×1 Jordan block is simply the scalar [λ], which corresponds to an ordinary eigenvector. Larger Jordan blocks arise when the matrix is defective—that is, when it does not have a complete set of linearly independent eigenvectors. The 1s on the superdiagonal encode the relationships between generalized eigenvectors in a Jordan chain.
The full Jordan matrix J is the direct sum of all Jordan blocks. For instance, an n×n matrix might have a Jordan form consisting of a 2×2 block for eigenvalue 3 and a 1×1 block for eigenvalue −1, written as J = J2(3) ⊕ J1(−1).
When is Jordan Normal Form Needed?
Not every matrix can be diagonalized. A matrix is diagonalizable if and only if it has a complete set of linearly independent eigenvectors. When a matrix fails to be diagonalizable, we call it defective, and the standard eigendecomposition A = PDP⁻¹ (with D diagonal) does not exist. This is precisely when the Jordan normal form becomes essential.
Defective matrices arise naturally in many contexts. For example, the matrix [[2, 1], [0, 2]] has eigenvalue 2 with algebraic multiplicity 2, but only one linearly independent eigenvector. Its Jordan form is a single 2×2 Jordan block J2(2), which cannot be simplified further. Without the Jordan form, there is no clean canonical representation for such matrices.
Even when a matrix is diagonalizable, computing the Jordan form can be valuable as a theoretical tool for proving properties about matrix functions, convergence of matrix sequences, and behavior of dynamical systems.
Algebraic vs. Geometric Multiplicity
Understanding Jordan form requires distinguishing between two types of multiplicity for each eigenvalue λ:
- Algebraic multiplicity (aλ): The multiplicity of λ as a root of the characteristic polynomial det(A − λI) = 0. This counts how many times λ appears as an eigenvalue, with repetition.
- Geometric multiplicity (gλ): The dimension of the eigenspace ker(A − λI), which equals the number of linearly independent eigenvectors for λ.
The key relationship is 1 ≤ gλ ≤ aλ. A matrix is diagonalizable if and only if gλ = aλ for every eigenvalue λ. When gλ < aλ, the matrix is defective at λ, and the Jordan form for that eigenvalue will contain blocks larger than 1×1.
More specifically, the geometric multiplicity gλ equals the number of Jordan blocks associated with λ, while the algebraic multiplicity aλ equals the sum of the sizes of those blocks. So an eigenvalue with aλ = 4 and gλ = 2 must have exactly two Jordan blocks whose sizes sum to 4 (e.g., one 3×3 block and one 1×1 block, or two 2×2 blocks).
Generalized Eigenvectors
The columns of the invertible matrix P in A = PJP⁻¹ are generalized eigenvectors of A. While ordinary eigenvectors satisfy (A − λI)v = 0, a generalized eigenvector of rank k satisfies (A − λI)kv = 0 but (A − λI)k−1v ≠ 0.
Generalized eigenvectors are organized into Jordan chains. A Jordan chain of length k for eigenvalue λ is a sequence of vectors v1, v2, ..., vk where:
- (A − λI)v1 = 0 (v1 is an ordinary eigenvector)
- (A − λI)v2 = v1
- (A − λI)v3 = v2
- And so on: (A − λI)vj = vj−1
Each Jordan chain corresponds to exactly one Jordan block, and the length of the chain equals the size of the block. The vectors in a chain, when used as columns of P (in reverse order: vk, ..., v2, v1), produce the corresponding Jordan block in J.
How to Compute Jordan Normal Form
Computing the Jordan normal form of a matrix A involves several steps:
- Find eigenvalues: Solve the characteristic polynomial det(A − λI) = 0 to find all eigenvalues and their algebraic multiplicities.
- Determine geometric multiplicities: For each eigenvalue λ, compute the rank of (A − λI) to find the dimension of the null space, which gives the geometric multiplicity gλ and thus the number of Jordan blocks for λ.
- Determine block sizes: Compute the ranks of (A − λI)k for k = 1, 2, 3, ... until the null space stabilizes. The differences in null space dimensions between consecutive powers reveal the block structure. Specifically, the number of blocks of size ≥ k equals dim ker(A − λI)k − dim ker(A − λI)k−1.
- Find generalized eigenvectors: For each Jordan block, construct a Jordan chain by solving the successive equations (A − λI)vj = vj−1, starting from the highest rank and working down to the ordinary eigenvector.
- Assemble P and J: Place the generalized eigenvectors as columns of P and construct the corresponding block diagonal Jordan matrix J.
Connection to Eigendecomposition
The Jordan normal form is a direct generalization of eigendecomposition (diagonalization). When a matrix A is diagonalizable, its Jordan form is simply the diagonal matrix of eigenvalues, and every Jordan block is 1×1. The matrix P becomes the matrix of eigenvectors, and A = PJP⁻¹ reduces to A = PDP⁻¹.
Viewed from this perspective, the Jordan form extends diagonalization to all square matrices by allowing controlled "near-diagonal" structure. The 1s on the superdiagonal of Jordan blocks are the minimal deviation from diagonality needed to represent the matrix canonically. This is why the Jordan form is sometimes described as the "closest to diagonal" form achievable for a given matrix.
In functional analysis and operator theory, the Jordan form corresponds to decomposing the underlying vector space into a direct sum of invariant subspaces (generalized eigenspaces), each of which is further decomposed into cyclic subspaces (Jordan chains).
Applications of Jordan Normal Form
- Matrix exponential: The Jordan form makes computing eAt straightforward. Since eAt = PeJtP⁻¹, and the exponential of a Jordan block has a known closed form involving polynomials in t multiplied by eλt, the Jordan form reduces matrix exponentiation to a routine calculation. This is fundamental in solving systems of linear differential equations dx/dt = Ax.
- Systems of differential equations: Linear ODE systems with constant coefficients are solved by computing eAt. When A is defective, the solution involves terms like tkeλt, where k is determined by the Jordan block structure. Without the Jordan form, these polynomial-exponential solutions are difficult to derive systematically.
- Markov chains and stochastic processes: The long-term behavior of Markov chains is governed by the powers An of the transition matrix. The Jordan form determines how quickly An converges (or whether it converges at all), with the spectral gap and Jordan block sizes controlling the rate of mixing.
- Control theory: In linear control systems, the Jordan form of the system matrix reveals the controllability and observability structure of the system. Jordan blocks corresponding to uncontrollable or unobservable modes identify fundamental limitations of the control design.
- Matrix functions: Any analytic function f(A) can be computed via the Jordan form: f(A) = Pf(J)P⁻¹. For a Jordan block Jk(λ), the function f is applied using the values f(λ), f'(λ), f''(λ)/2!, etc., making the Jordan form the natural tool for defining and computing matrix functions.
- Stability analysis: The Jordan form determines the stability of equilibria in dynamical systems. An equilibrium is asymptotically stable if and only if all eigenvalues have negative real parts, and the presence of Jordan blocks larger than 1×1 on the imaginary axis causes algebraic (polynomial) instability even when eigenvalues alone might suggest marginal stability.
Computational Complexity and Numerical Challenges
While the Jordan normal form is theoretically powerful, computing it numerically is notoriously difficult. The core issue is that the Jordan structure is discontinuous: an arbitrarily small perturbation of a defective matrix can make it diagonalizable. For example, the matrix [[0, 1], [0, 0]] has a 2×2 Jordan block, but [[0, 1], [ε, 0]] is diagonalizable for any ε ≠ 0, no matter how small.
This sensitivity means that floating-point arithmetic, which introduces small rounding errors at every step, can obscure the true Jordan structure. Standard numerical algorithms therefore use tolerances to determine whether eigenvalues should be considered equal and whether null spaces have the expected dimensions.
In practice, numerical linear algebra favors the Schur decomposition (A = QTQ*) as a numerically stable alternative. The Schur form is always upper triangular with eigenvalues on the diagonal and can be computed reliably using the QR algorithm. For theoretical and symbolic computation, however, the Jordan form remains indispensable.
The computational cost of finding the Jordan form is dominated by computing eigenvalues (typically O(n³) using iterative methods) and then determining the generalized eigenspace structure, which involves additional null space computations.
Jordan Form Over Real vs. Complex Numbers
The Jordan normal form as described above requires the base field to be algebraically closed, which means working over the complex numbers. Over the reals, a matrix with complex eigenvalues cannot be put into Jordan form using only real arithmetic, because the eigenvalues and generalized eigenvectors may be complex.
The real counterpart is the real Jordan form (also called the real canonical form). In this form, real eigenvalues produce standard Jordan blocks just as in the complex case. However, a pair of complex conjugate eigenvalues α ± βi produces 2×2 blocks of the form [[α, β], [−β, α]] on the diagonal instead of scalar eigenvalues, with 2×2 identity matrices on the superdiagonal of larger blocks instead of scalar 1s.
This real Jordan form preserves all structural information while keeping all entries real. It is particularly useful in applications involving real-valued differential equations and dynamical systems, where complex arithmetic is undesirable. The oscillatory behavior encoded by complex eigenvalues appears explicitly as rotation blocks in the real Jordan form.
Related factorizations
LU Decomposition
Factor any square matrix into lower and upper triangular matrices with partial pivoting.
Open calculator →QR Decomposition
Decompose into orthogonal Q and upper triangular R. Ideal for least squares problems.
Open calculator →Singular Value Decomposition
The most general decomposition. Factor any matrix into UΣVᵀ.
Open calculator →Cholesky Decomposition
Efficient factorization for symmetric positive definite matrices.
Open calculator →Eigendecomposition
Find eigenvalues and eigenvectors of square matrices.
Open calculator →