Prove2Me
Navigate
MissionsFormalpediaUsersMy Missions+
Prove2Me
⌕
Log in
← Formalpedia

The Jordan block multiset is an invariant of the matrix

Proved
HefferonLinAlg.jordanBlocks_unique

by tianyipeng · Aug 7, 2026 · Mathlib c5ea003 (Lean v4.30.0)

canonical-formjordan-formlinear-algebrasimilarityuniqueness

Any two Jordan forms of the same square complex matrix have the same multiset of (block size,eigenvalue)(\text{block size}, \text{eigenvalue})(block size,eigenvalue) pairs. In other words the Jordan block data is an invariant of the matrix: the blocks may be listed in any order, but which blocks occur, and with what multiplicity, is determined by AAA alone. This is the uniqueness half of the canonical form, and it is where the difficulty of the goal theorem lives — given it, the goal follows by packaging it with existence.

Preamble
import Mathlib
import Definitions.Def_HefferonLinAlg_jordan

open Matrix
Formal statement
namespace HefferonLinAlg

theorem jordanBlocks_unique
    {n : ℕ} {A : Matrix (Fin n) (Fin n) ℂ} {k₁ k₂ : ℕ}
    {sz₁ : Fin k₁ → ℕ} {lam₁ : Fin k₁ → ℂ}
    {sz₂ : Fin k₂ → ℕ} {lam₂ : Fin k₂ → ℂ}
    (h₁ : IsJordanFormOf A sz₁ lam₁) (h₂ : IsJordanFormOf A sz₂ lam₂) :
    jordanBlocks sz₁ lam₁ = jordanBlocks sz₂ lam₂ := by
  sorry

end HefferonLinAlg
Source
Jim Hefferon, *Linear Algebra*, Saint Michael's College, 2020 printing, Chapter Five, Section IV.2, Remark 2.9, printed p. 456, together with Section III.2, Theorem 2.16, printed p. 434
Read-back

What the Lean code literally says, in plain math · claude-opus-5

Read-back: HefferonLinAlg.jordanBlocks_unique

What the statement asserts

For every natural number nnn, every n×nn \times nn×n matrix AAA with complex entries, every pair of natural numbers k1,k2k_1, k_2k1​,k2​, and every choice of four functions

sz1:{0,…,k1−1}→N,λ1:{0,…,k1−1}→C,\mathrm{sz}_1 : \{0,\dots,k_1-1\} \to \mathbb{N}, \qquad \lambda_1 : \{0,\dots,k_1-1\} \to \mathbb{C},sz1​:{0,…,k1​−1}→N,λ1​:{0,…,k1​−1}→C, sz2:{0,…,k2−1}→N,λ2:{0,…,k2−1}→C,\mathrm{sz}_2 : \{0,\dots,k_2-1\} \to \mathbb{N}, \qquad \lambda_2 : \{0,\dots,k_2-1\} \to \mathbb{C},sz2​:{0,…,k2​−1}→N,λ2​:{0,…,k2​−1}→C,

if the block data (sz1,λ1)(\mathrm{sz}_1, \lambda_1)(sz1​,λ1​) is a Jordan form of AAA and the block data (sz2,λ2)(\mathrm{sz}_2, \lambda_2)(sz2​,λ2​) is a Jordan form of AAA — both in the precise sense unfolded below — then the two multisets of size–eigenvalue pairs coincide:

{ ⁣{ (sz1(i),λ1(i))  :  i=0,…,k1−1 } ⁣}  =  { ⁣{ (sz2(j),λ2(j))  :  j=0,…,k2−1 } ⁣}\{\!\{\,(\mathrm{sz}_1(i), \lambda_1(i)) \;:\; i = 0,\dots,k_1-1 \,\}\!\} \;=\; \{\!\{\,(\mathrm{sz}_2(j), \lambda_2(j)) \;:\; j = 0,\dots,k_2-1 \,\}\!\}{{(sz1​(i),λ1​(i)):i=0,…,k1​−1}}={{(sz2​(j),λ2​(j)):j=0,…,k2​−1}}

as multisets of elements of N×C\mathbb{N} \times \mathbb{C}N×C. All of nnn, AAA, k1k_1k1​, k2k_2k2​, sz1\mathrm{sz}_1sz1​, λ1\lambda_1λ1​, sz2\mathrm{sz}_2sz2​, λ2\lambda_2λ2​ are implicit arguments universally quantified over; the two Jordan-form hypotheses are the only hypotheses. There is no hypothesis of invertibility, nonzero size, distinctness of eigenvalues, ordering of block sizes, or anything else about AAA.

The named constructions, unfolded

Jordan block. For m∈Nm \in \mathbb{N}m∈N and a scalar μ\muμ, Jm(μ)J_m(\mu)Jm​(μ) is the m×mm \times mm×m matrix whose (i,j)(i,j)(i,j) entry is

(Jm(μ))ij  =  {μif i=j,1if i=j+1,0otherwise,\bigl(J_m(\mu)\bigr)_{ij} \;=\; \begin{cases} \mu & \text{if } i = j,\\ 1 & \text{if } i = j+1,\\ 0 & \text{otherwise,}\end{cases}(Jm​(μ))ij​=⎩⎨⎧​μ10​if i=j,if i=j+1,otherwise,​

with i,ji, ji,j read as integers in {0,…,m−1}\{0,\dots,m-1\}{0,…,m−1}. The 111's therefore sit on the subdiagonal (directly below the diagonal), not above it. For m=0m = 0m=0 this is the empty matrix.

Index type of a Jordan matrix. Given kkk and sz:{0,…,k−1}→N\mathrm{sz} : \{0,\dots,k-1\} \to \mathbb{N}sz:{0,…,k−1}→N, the index set is the disjoint union

I(sz)  =  ∐i=0k−1{0,…,sz(i)−1},I(\mathrm{sz}) \;=\; \coprod_{i=0}^{k-1} \{0,\dots,\mathrm{sz}(i)-1\},I(sz)=i=0∐k−1​{0,…,sz(i)−1},

whose elements are pairs ⟨i,a⟩\langle i, a\rangle⟨i,a⟩ with a<sz(i)a < \mathrm{sz}(i)a<sz(i). Its cardinality is ∑i=0k−1sz(i)\sum_{i=0}^{k-1} \mathrm{sz}(i)∑i=0k−1​sz(i).

Jordan matrix. J(sz,λ)J(\mathrm{sz},\lambda)J(sz,λ) is the matrix indexed by I(sz)×I(sz)I(\mathrm{sz}) \times I(\mathrm{sz})I(sz)×I(sz) that is block diagonal with the iii-th diagonal block equal to Jsz(i)(λ(i))J_{\mathrm{sz}(i)}(\lambda(i))Jsz(i)​(λ(i)):

J(sz,λ)⟨i,a⟩, ⟨j,b⟩  =  {(Jsz(i)(λ(i)))abif i=j,0if i≠j.J(\mathrm{sz},\lambda)_{\langle i,a\rangle,\,\langle j,b\rangle} \;=\; \begin{cases} \bigl(J_{\mathrm{sz}(i)}(\lambda(i))\bigr)_{ab} & \text{if } i = j,\\ 0 & \text{if } i \neq j.\end{cases}J(sz,λ)⟨i,a⟩,⟨j,b⟩​={(Jsz(i)​(λ(i)))ab​0​if i=j,if i=j.​

Similarity. For square matrices X,YX, YX,Y over a commutative ring, indexed by the same finite index set, "XXX is similar to YYY" means: there exists a matrix PPP of the same shape such that det⁡P\det PdetP is a unit (over C\mathbb{C}C: det⁡P≠0\det P \neq 0detP=0) and

P−1XP  =  Y,P^{-1} X P \;=\; Y,P−1XP=Y,

where P−1P^{-1}P−1 is the total matrix-inverse operation, which — because det⁡P\det PdetP is assumed to be a unit — is the genuine two-sided inverse of PPP. Note the direction: it is XXX that is conjugated into YYY.

"(sz,λ)(\mathrm{sz}, \lambda)(sz,λ) is a Jordan form of AAA." For AAA indexed by {0,…,n−1}\{0,\dots,n-1\}{0,…,n−1}, this is the conjunction of two conditions:

  1. Every block is nonempty: sz(i)>0\mathrm{sz}(i) > 0sz(i)>0 for all i∈{0,…,k−1}i \in \{0,\dots,k-1\}i∈{0,…,k−1}.
  2. There exists a bijection e:{0,…,n−1}→ ∼ I(sz)e : \{0,\dots,n-1\} \xrightarrow{\ \sim\ } I(\mathrm{sz})e:{0,…,n−1} ∼ ​I(sz) such that AAA is similar (in the sense just given, as matrices indexed by {0,…,n−1}\{0,\dots,n-1\}{0,…,n−1}) to the matrix obtained from J(sz,λ)J(\mathrm{sz},\lambda)J(sz,λ) by relabelling its rows and columns along eee — i.e. to the matrix MMM with Mab=J(sz,λ)e(a), e(b)M_{ab} = J(\mathrm{sz},\lambda)_{e(a),\,e(b)}Mab​=J(sz,λ)e(a),e(b)​. Explicitly: there exist eee and a matrix PPP over C\mathbb{C}C indexed by {0,…,n−1}\{0,\dots,n-1\}{0,…,n−1} with det⁡P≠0\det P \neq 0detP=0 and P−1AP=MP^{-1} A P = MP−1AP=M.

The bijection eee and the conjugator PPP are existentially quantified separately inside each hypothesis; nothing links the ones supplied by the first hypothesis to the ones supplied by the second.

The multiset of blocks. jordanBlocks(sz,λ)\mathrm{jordanBlocks}(\mathrm{sz},\lambda)jordanBlocks(sz,λ) is the multiset obtained by running iii over all of {0,…,k−1}\{0,\dots,k-1\}{0,…,k−1} and collecting the pairs (sz(i),λ(i))(\mathrm{sz}(i), \lambda(i))(sz(i),λ(i)), keeping repetitions. It has exactly kkk elements counted with multiplicity; the pair (sz(i),λ(i))(\mathrm{sz}(i), \lambda(i))(sz(i),λ(i)) appears once for each index iii producing it.

What the conclusion does and does not say

  • Multiset equality means: the two collections contain the same size–eigenvalue pairs with the same multiplicities. Size and eigenvalue are matched jointly, not separately — the pair (3,5)(3, 5)(3,5) on one side must be answered by a pair (3,5)(3,5)(3,5) on the other, not merely by "some block of size 333" and "some block with eigenvalue 555".
  • Because a multiset's cardinality is preserved, the conclusion in particular forces k1=k2k_1 = k_2k1​=k2​; equivalently, it is logically the same as the existence of a bijection σ\sigmaσ from {0,…,k1−1}\{0,\dots,k_1-1\}{0,…,k1​−1} to {0,…,k2−1}\{0,\dots,k_2-1\}{0,…,k2​−1} with sz1(i)=sz2(σ(i))\mathrm{sz}_1(i) = \mathrm{sz}_2(\sigma(i))sz1​(i)=sz2​(σ(i)) and λ1(i)=λ2(σ(i))\lambda_1(i) = \lambda_2(\sigma(i))λ1​(i)=λ2​(σ(i)) for all iii.
  • It says nothing about the ordering of the blocks, and nothing about the bijections eee or the conjugating matrices PPP appearing in the two hypotheses; no relation between them is claimed.
  • It does not assert that a Jordan form exists for any given AAA, nor that the λ\lambdaλ's are eigenvalues of AAA, nor that eigenvalues appearing in different blocks are distinct, nor that block sizes are listed in any order. It is a conditional statement: if two such block descriptions are given, they agree as multisets.

Degenerate and boundary cases covered by the quantifiers

  • n=0n = 0n=0: AAA is the empty matrix. A bijection {0,…,n−1}≃I(sz)\{0,\dots,n-1\} \simeq I(\mathrm{sz}){0,…,n−1}≃I(sz) requires ∑isz(i)=n\sum_i \mathrm{sz}(i) = n∑i​sz(i)=n; combined with condition 1 (sz(i)>0\mathrm{sz}(i) > 0sz(i)>0 for every iii), n=0n = 0n=0 forces k=0k = 0k=0 and hence both multisets are empty.
  • k=0k = 0k=0: allowed for either hypothesis; condition 1 is then vacuously true, I(sz)I(\mathrm{sz})I(sz) is empty, and the resulting multiset is empty. As above, this is compatible with the hypotheses only when n=0n = 0n=0.
  • Size-zero blocks are excluded by condition 1, so a block description may not be padded with empty blocks carrying arbitrary eigenvalues.
  • Dimension constraint: more generally, each hypothesis silently forces n=∑i=0k−1sz(i)n = \sum_{i=0}^{k-1} \mathrm{sz}(i)n=∑i=0k−1​sz(i), via the existence of the bijection eee.
  • Repeated pairs: the multiset construction keeps duplicates, so two distinct indices with the same size and the same eigenvalue contribute two copies.
  • The hypotheses are simultaneous assumptions about a single fixed AAA; if for a particular AAA no such data exists, the statement holds vacuously for that AAA.

Note on the artifact

The declaration is stated with its proof omitted (the proof body is a placeholder), so the file contains the statement above and no argument for it.

Human review
  • Endorsed by Shuze Chen · Aug 7, 2026

  • Endorsed by tianyipeng · Aug 7, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeLaunch a missionPropose a formalization projectFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions.

How Prove2Me works
SKILL.mdTourFAQContactJoin Slack© 2026 Prove2Me