Skip to content

Chapter 71. Rational Canonical Form

Rational canonical form is a canonical form for square matrices over an arbitrary field.

Jordan canonical form requires the characteristic polynomial to split into linear factors. This means that all eigenvalues must lie in the field. Rational canonical form avoids that restriction. It works over the original field without adjoining missing eigenvalues.

For this reason, rational canonical form is often the correct replacement for Jordan form over fields such as

Q,R,Fp. \mathbb{Q}, \qquad \mathbb{R}, \qquad \mathbb{F}_p.

It classifies matrices up to similarity by using invariant factors and companion matrices. A matrix is similar to exactly one rational canonical form, up to the ordering convention of its blocks.

71.1 Similarity and the Need for Canonical Form

Two square matrices AA and BB over a field FF are similar if there exists an invertible matrix PP over FF such that

B=P1AP. B=P^{-1}AP.

Similar matrices represent the same linear transformation in different bases.

A canonical form chooses one standard representative from each similarity class. If two matrices have the same canonical form, then they are similar. If they have different canonical forms, then they are not similar.

Diagonal form is the simplest canonical form, but it exists only for diagonalizable matrices. Jordan form applies more broadly, but it requires the characteristic polynomial to split over the field. Rational canonical form applies to every square matrix over any field.

71.2 Companion Matrices

Let

f(t)=td+ad1td1++a1t+a0 f(t)=t^d+a_{d-1}t^{d-1}+\cdots+a_1t+a_0

be a monic polynomial over FF.

The companion matrix of ff is

C(f)=[000a0100a1010a2000ad1]. C(f)= \begin{bmatrix} 0 & 0 & 0 & \cdots & -a_0 \\ 1 & 0 & 0 & \cdots & -a_1 \\ 0 & 1 & 0 & \cdots & -a_2 \\ \vdots & \vdots & \vdots & \ddots & \vdots \\ 0 & 0 & 0 & \cdots & -a_{d-1} \end{bmatrix}.

This matrix is designed so that its characteristic polynomial and minimal polynomial are both f(t)f(t).

The companion matrix represents multiplication by tt on the quotient space

F[t]/(f(t)). F[t]/(f(t)).

The basis is

1,t,t2,,td1. 1,t,t^2,\ldots,t^{d-1}.

Multiplication by tt shifts basis elements until the last one. The relation

td=ad1td1a1ta0 t^d=-a_{d-1}t^{d-1}-\cdots-a_1t-a_0

produces the last column of the companion matrix.

71.3 Example of a Companion Matrix

Let

f(t)=t32t+5. f(t)=t^3-2t+5.

Then

a2=0,a1=2,a0=5. a_2=0, \qquad a_1=-2, \qquad a_0=5.

The companion matrix is

C(f)=[005102010]. C(f)= \begin{bmatrix} 0 & 0 & -5 \\ 1 & 0 & 2 \\ 0 & 1 & 0 \end{bmatrix}.

The relation behind the matrix is

t3=2t5. t^3=2t-5.

Thus multiplication by tt sends

1t,tt2,t2t3=2t5. 1\mapsto t, \qquad t\mapsto t^2, \qquad t^2\mapsto t^3=2t-5.

In the basis 1,t,t21,t,t^2, this gives the columns

[010],[001],[520]. \begin{bmatrix} 0\\1\\0 \end{bmatrix}, \qquad \begin{bmatrix} 0\\0\\1 \end{bmatrix}, \qquad \begin{bmatrix} -5\\2\\0 \end{bmatrix}.

71.4 Cyclic Subspaces

Let T:VVT:V\to V be a linear transformation over FF.

A subspace WVW\subseteq V is cyclic for TT if there exists a vector vWv\in W such that

W=span{v,Tv,T2v,,Td1v}. W=\operatorname{span}\{v,Tv,T^2v,\ldots,T^{d-1}v\}.

The vector vv is called a cyclic vector for WW.

On a cyclic subspace, the matrix of TT has companion matrix form. If the first polynomial relation among

v,Tv,T2v, v,Tv,T^2v,\ldots

is

f(T)v=0, f(T)v=0,

where ff is monic of degree dd, then the matrix of TT on this cyclic subspace is C(f)C(f).

Thus companion matrices are the building blocks of rational canonical form.

71.5 Invariant Factors

The rational canonical form is built from a sequence of monic polynomials

f1(t),f2(t),,fr(t) f_1(t),f_2(t),\ldots,f_r(t)

called invariant factors.

They satisfy the divisibility chain

f1(t)f2(t)fr(t). f_1(t)\mid f_2(t)\mid \cdots \mid f_r(t).

The rational canonical form is the block diagonal matrix

C(f1)C(f2)C(fr). C(f_1)\oplus C(f_2)\oplus\cdots\oplus C(f_r).

The invariant factors determine the matrix up to similarity. Conversely, the similarity class determines the invariant factors.

The largest invariant factor is the minimal polynomial:

fr(t)=mA(t). f_r(t)=m_A(t).

The product of all invariant factors is the characteristic polynomial:

f1(t)f2(t)fr(t)=pA(t). f_1(t)f_2(t)\cdots f_r(t)=p_A(t).

These two facts connect rational canonical form with the previous chapters on the characteristic and minimal polynomials.

71.6 Definition of Rational Canonical Form

Let AA be an n×nn\times n matrix over a field FF.

The rational canonical form of AA is the block diagonal matrix

R=C(f1)C(f2)C(fr), R= C(f_1)\oplus C(f_2)\oplus\cdots\oplus C(f_r),

where

f1f2fr f_1\mid f_2\mid \cdots \mid f_r

are the invariant factors of AA.

There exists an invertible matrix PP over FF such that

P1AP=R. P^{-1}AP=R.

The form is canonical: two matrices over FF are similar if and only if they have the same rational canonical form.

71.7 Why the Word Rational Appears

The word rational does not mean that the entries must be rational numbers.

It means that the form is defined over the original field using polynomial arithmetic over that field. It does not require factoring the characteristic polynomial into linear factors.

For example, over R\mathbb{R}, the polynomial

t2+1 t^2+1

does not split into real linear factors. Jordan form over R\mathbb{R} using eigenvalues ii and i-i is unavailable.

But the companion matrix

C(t2+1)=[0110] C(t^2+1)= \begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix}

is a real matrix. It is already a rational canonical block over R\mathbb{R}.

Thus rational canonical form works without leaving the base field.

71.8 Example: Rotation by 9090^\circ

Consider

A=[0110] A= \begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix}

over R\mathbb{R}.

The characteristic polynomial is

pA(t)=t2+1. p_A(t)=t^2+1.

The minimal polynomial is also

mA(t)=t2+1. m_A(t)=t^2+1.

Since the minimal polynomial equals the characteristic polynomial, there is one invariant factor:

f1(t)=t2+1. f_1(t)=t^2+1.

Therefore the rational canonical form is

C(t2+1)=[0110]. C(t^2+1) = \begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix}.

So AA is already in rational canonical form.

Over C\mathbb{C}, the same matrix has eigenvalues ii and i-i, and it diagonalizes. This shows that rational canonical form depends on the chosen base field.

71.9 Example: One Cyclic Matrix

Let

A=[0061011016]. A= \begin{bmatrix} 0 & 0 & -6 \\ 1 & 0 & 11 \\ 0 & 1 & -6 \end{bmatrix}.

This is the companion matrix of

f(t)=t3+6t211t+6. f(t)=t^3+6t^2-11t+6.

Actually, using the companion convention above, the last column is

[a0a1a2]=[6116]. \begin{bmatrix} -a_0\\ -a_1\\ -a_2 \end{bmatrix} = \begin{bmatrix} -6\\ 11\\ -6 \end{bmatrix}.

Thus

a0=6,a1=11,a2=6. a_0=6, \qquad a_1=-11, \qquad a_2=6.

The characteristic polynomial and minimal polynomial are both f(t)f(t).

There is one invariant factor:

f1(t)=f(t). f_1(t)=f(t).

Therefore the rational canonical form of AA is AA itself.

A matrix whose minimal polynomial equals its characteristic polynomial is called cyclic. Its rational canonical form has one companion block.

71.10 Example with Two Invariant Factors

Suppose a 4×44\times4 matrix AA has invariant factors

f1(t)=t2 f_1(t)=t-2

and

f2(t)=(t2)3. f_2(t)=(t-2)^3.

They satisfy

f1f2. f_1\mid f_2.

The rational canonical form is

R=C(t2)C((t2)3). R=C(t-2)\oplus C((t-2)^3).

Now

C(t2)=[2]. C(t-2)=[2].

Also,

(t2)3=t36t2+12t8. (t-2)^3=t^3-6t^2+12t-8.

Thus

C((t2)3)=[0081012016]. C((t-2)^3)= \begin{bmatrix} 0 & 0 & 8 \\ 1 & 0 & -12 \\ 0 & 1 & 6 \end{bmatrix}.

Therefore

R=[20000008010120016]. R= \begin{bmatrix} 2 & 0 & 0 & 0 \\ 0 & 0 & 0 & 8 \\ 0 & 1 & 0 & -12 \\ 0 & 0 & 1 & 6 \end{bmatrix}.

The characteristic polynomial is

pA(t)=(t2)4, p_A(t)=(t-2)^4,

and the minimal polynomial is

mA(t)=(t2)3. m_A(t)=(t-2)^3.

71.11 Relation to Jordan Form

When the characteristic polynomial splits into linear factors, rational canonical form and Jordan form contain the same structural information, but package it differently.

Jordan form uses blocks

Jk(λ). J_k(\lambda).

Rational canonical form uses companion matrices of invariant factors.

For a single Jordan block Jk(λ)J_k(\lambda), the corresponding polynomial is

(tλ)k. (t-\lambda)^k.

The companion matrix C((tλ)k)C((t-\lambda)^k) is similar to the Jordan block Jk(λ)J_k(\lambda), but it uses a different basis.

Thus Jordan form is eigenvector-chain based. Rational canonical form is polynomial-module based.

Jordan form is more geometric. Rational canonical form is more field-independent.

71.12 Rational Form Over Non-Algebraically Closed Fields

Let

A=[0110]. A= \begin{bmatrix} 0 & -1 \\ 1 & 0 \end{bmatrix}.

Over R\mathbb{R}, the polynomial

t2+1 t^2+1

is irreducible. The rational canonical form has one block C(t2+1)C(t^2+1).

Over C\mathbb{C},

t2+1=(ti)(t+i). t^2+1=(t-i)(t+i).

The matrix becomes diagonalizable:

A[i00i]. A\sim \begin{bmatrix} i & 0 \\ 0 & -i \end{bmatrix}.

Thus extending the field can change the Jordan description. The rational canonical form over the original field avoids choosing roots outside the field.

71.13 The Module Viewpoint

Rational canonical form is most naturally explained using modules.

Let VV be a finite-dimensional vector space over FF, and let T:VVT:V\to V be linear.

Make VV into an F[t]F[t]-module by defining

p(t)v=p(T)v. p(t)\cdot v=p(T)v.

Since F[t]F[t] is a principal ideal domain, the structure theorem for finitely generated modules over a PID applies.

It gives a decomposition

VF[t]/(f1(t))F[t]/(fr(t)), V\cong F[t]/(f_1(t))\oplus\cdots\oplus F[t]/(f_r(t)),

where

f1f2fr. f_1\mid f_2\mid\cdots\mid f_r.

These polynomials are the invariant factors. Writing multiplication by tt on each quotient gives the companion matrix C(fi)C(f_i). The block diagonal sum of these companion matrices is the rational canonical form.

71.14 Characteristic Polynomial from Invariant Factors

If

R=C(f1)C(fr), R=C(f_1)\oplus\cdots\oplus C(f_r),

then the characteristic polynomial of RR is the product of the characteristic polynomials of the blocks.

Since

pC(fi)(t)=fi(t), p_{C(f_i)}(t)=f_i(t),

we get

pA(t)=f1(t)f2(t)fr(t). p_A(t)=f_1(t)f_2(t)\cdots f_r(t).

Thus the invariant factors multiply to the characteristic polynomial.

This means the degrees satisfy

degf1+degf2++degfr=n. \deg f_1+\deg f_2+\cdots+\deg f_r=n.

The total size of all companion blocks equals the dimension of the vector space.

71.15 Minimal Polynomial from Invariant Factors

For a block diagonal matrix, the minimal polynomial is the least common multiple of the minimal polynomials of the blocks.

Each companion block C(fi)C(f_i) has minimal polynomial fif_i.

Therefore

mA(t)=lcm(f1,,fr). m_A(t)=\operatorname{lcm}(f_1,\ldots,f_r).

Since

f1f2fr, f_1\mid f_2\mid\cdots\mid f_r,

the least common multiple is

fr. f_r.

Thus the largest invariant factor is the minimal polynomial:

mA(t)=fr(t). m_A(t)=f_r(t).

This is one of the main computational checks on rational canonical form.

71.16 Similarity Classification

The rational canonical form solves the similarity classification problem over a field.

For square matrices AA and BB over FF,

AB A \sim B

if and only if they have the same invariant factors.

Equivalently,

A A

and

B B

are similar if and only if they have the same rational canonical form.

This is stronger than comparing characteristic polynomials or minimal polynomials alone. Two matrices may have the same characteristic and minimal polynomials but different invariant factors.

71.17 Characteristic and Minimal Polynomials Are Not Enough

Consider two matrices with invariant factors

f1(t)=t1,f2(t)=(t1)2, f_1(t)=t-1, \qquad f_2(t)=(t-1)^2,

and another matrix with invariant factors

g1(t)=(t1)2,g2(t)=t1. g_1(t)=(t-1)^2, \qquad g_2(t)=t-1.

After ordering by divisibility, these are the same list.

But compare instead:

f1(t)=t1,f2(t)=(t1)2 f_1(t)=t-1, \qquad f_2(t)=(t-1)^2

with

g1(t)=1,g2(t)=(t1)3. g_1(t)=1, \qquad g_2(t)=(t-1)^3.

Ignoring trivial factors, the second matrix has one nontrivial invariant factor (t1)3(t-1)^3, while the first has two nontrivial invariant factors.

Both may have related eigenvalue data, but the rational canonical forms differ.

The invariant factor list gives the exact similarity class.

71.18 Relation to Elementary Divisors

Invariant factors can be refined into elementary divisors by factoring them into powers of irreducible polynomials.

For example, suppose

f1(t)=(t1)(t2+1) f_1(t)=(t-1)(t^2+1)

and

f2(t)=(t1)3(t2+1)2. f_2(t)=(t-1)^3(t^2+1)^2.

The elementary divisors are the prime-power factors:

t1,t2+1,(t1)3,(t2+1)2. t-1, \qquad t^2+1, \qquad (t-1)^3, \qquad (t^2+1)^2.

The primary rational canonical form uses these elementary divisors. The invariant-factor rational canonical form uses the divisibility chain f1f2f_1\mid f_2\mid\cdots.

Both forms are useful. The invariant-factor form avoids unnecessary factorization and gives a compact uniqueness statement.

71.19 Rational Canonical Form and Diagonalization

A matrix is diagonalizable over FF if and only if its minimal polynomial splits over FF into distinct linear factors.

Since

mA(t)=fr(t), m_A(t)=f_r(t),

this means that the largest invariant factor must split into distinct linear factors.

For example, if

mA(t)=(t1)(t3)(t+2), m_A(t)=(t-1)(t-3)(t+2),

then the matrix is diagonalizable over FF, assuming those scalars lie in FF.

If

mA(t)=(t1)2(t+2), m_A(t)=(t-1)^2(t+2),

then the matrix is not diagonalizable.

If

mA(t)=t2+1 m_A(t)=t^2+1

over R\mathbb{R}, then the matrix is not diagonalizable over R\mathbb{R}, since the polynomial does not split over R\mathbb{R}.

71.20 Rational Canonical Form and Cayley-Hamilton

Because

pA(t)=f1(t)fr(t) p_A(t)=f_1(t)\cdots f_r(t)

and

mA(t)=fr(t), m_A(t)=f_r(t),

the divisibility chain implies

mA(t)pA(t). m_A(t)\mid p_A(t).

This is consistent with Cayley-Hamilton, which says

pA(A)=0. p_A(A)=0.

The rational canonical form gives a structural explanation. Each companion block C(fi)C(f_i) is annihilated by fif_i, and therefore by frf_r, since fifrf_i\mid f_r. Hence the whole rational canonical form is annihilated by frf_r, the minimal polynomial.

71.21 Computing Rational Canonical Form

In practice, rational canonical form may be computed from the Smith normal form of the polynomial matrix

tIA. tI-A.

The Smith normal form over F[t]F[t] produces diagonal polynomial entries whose nonunit entries determine the invariant factors.

This method relies on the fact that F[t]F[t] is a principal ideal domain.

A rough procedure is:

StepOperation
1Form the polynomial matrix tIAtI-A.
2Compute its Smith normal form over F[t]F[t].
3Extract the invariant factors.
4Build companion matrices for those factors.
5Assemble their block diagonal direct sum.

This is the algebraic route to rational canonical form. It avoids solving for eigenvalues.

71.22 Example Using Minimal and Characteristic Polynomials

Suppose AA is a 5×55\times5 matrix with

pA(t)=(t2+1)2(t3) p_A(t)=(t^2+1)^2(t-3)

and

mA(t)=(t2+1)(t3). m_A(t)=(t^2+1)(t-3).

Since the largest invariant factor is the minimal polynomial, one invariant factor must be

f2(t)=(t2+1)(t3). f_2(t)=(t^2+1)(t-3).

The product of all invariant factors must be the characteristic polynomial. Therefore the remaining factor must be

f1(t)=t2+1. f_1(t)=t^2+1.

Check the divisibility condition:

t2+1(t2+1)(t3). t^2+1 \mid (t^2+1)(t-3).

Thus the rational canonical form is

C(t2+1)C((t2+1)(t3)). C(t^2+1)\oplus C((t^2+1)(t-3)).

The first block has size 22. The second block has size 33. Together they form a 5×55\times5 matrix.

71.23 Common Errors

The first common error is to confuse rational canonical form with Jordan form. Jordan form uses eigenvalues and Jordan blocks. Rational canonical form uses polynomials and companion matrices.

The second common error is to assume rational means entries are rational numbers. The form works over any field.

The third common error is to ignore the divisibility chain

f1f2fr. f_1\mid f_2\mid\cdots\mid f_r.

Without this chain, a block decomposition by companion matrices is not the invariant-factor rational canonical form.

The fourth common error is to think characteristic and minimal polynomials always determine the rational canonical form. They often help, but the full invariant factor list is needed.

The fifth common error is to factor polynomials unnecessarily. One advantage of rational canonical form is that it can be described over the base field without splitting the characteristic polynomial.

71.24 Summary

Rational canonical form expresses a square matrix over a field FF as a block diagonal matrix of companion matrices:

R=C(f1)C(f2)C(fr), R=C(f_1)\oplus C(f_2)\oplus\cdots\oplus C(f_r),

where

f1f2fr. f_1\mid f_2\mid\cdots\mid f_r.

The polynomials fif_i are the invariant factors.

They satisfy

f1f2fr=pA f_1f_2\cdots f_r=p_A

and

fr=mA. f_r=m_A.

Rational canonical form exists over every field and classifies matrices up to similarity over that field. It is the field-independent counterpart of Jordan form and the natural canonical form arising from the module structure of a vector space under a linear operator.