MRRR assigns every eigenvalue one vector, its twisted vectors have residuals bounded by the eigenvalue error, and the representation tree is finite full
This proof shows: correctness, termination.
Exact arithmetic throughout, except where an approximation λ^ of an eigenvalue is fed in; the floating-point behaviour is cited at the end. Notation of the page: T is real symmetric tridiagonal of order n, unreduced on each block; a representation is LDLT with L unit lower bidiagonal (li in position (i+1,i)) and D=diag(d1,…,dn); its tridiagonal has diagonal αi=di+di−1li−12 (with d0l02=0) and off-diagonal βi=dili. We assume that no pivot Di+ or Di− below is zero (the code replaces an exact zero by a tiny number, which is a perturbation of size 2−1000).
Lemma 1 (stationary qd). With s1=−τ, Di+=di+si, Li+=dili/Di+, si+1=Li+lisi−τ and Dn+=dn+sn, we have L+D+(L+)T=LDLT−τI.
Proof. Both sides are symmetric tridiagonal. Off-diagonal: Di+Li+=dili=βi. Diagonal 1: D1+=d1−τ=α1−τ. Diagonal i+1: we need Di+1++Di+(Li+)2=di+1+dili2−τ. Now dili2−Di+(Li+)2=dili2−diliLi+=li(Di+Li+−diLi+)=liLi+(Di+−di)=Li+lisi, so the requirement is Di+1+=di+1+Li+lisi−τ=di+1+si+1, which is the definition. □
Lemma 2 (progressive qd from the bottom). With pn=dn−μ and, for i=n−1,…,1, Di+1−=dili2+pi+1, Ui−=dili/Di+1−, pi=pi+1di/Di+1−−μ, and D1−=p1, we have U−D−(U−)T=LDLT−μI with U− unit upper bidiagonal (Ui− in position (i,i+1)).
Proof. The product has off-diagonal Di+1−Ui−=dili and diagonal Di−+Di+1−(Ui−)2, with the second term absent for i=n. For i=n: Dn−=dn−1ln−12+dn−μ=αn−μ. For i<n, using Di−=di−1li−12+pi (or p1 for i=1), the requirement Di−+(dili)2/Di+1−=αi−μ becomes pi=di−μ−di2li2/Di+1−=di(Di+1−−dili2)/Di+1−−μ=dipi+1/Di+1−−μ, the definition. □
Lemma 3 (twisted factorization). Let M=LDLT−μI, γk=sk+pk+μ, and fix r. Define zr=1, zi=−Li+zi+1 for i=r−1,…,1, and zi+1=−Ui−zi for i=r,…,n−1. Then Mz=γrer. If M is nonsingular, γr=1/(M−1)rr.
Proof. By Lemma 1, Mz=L+D+w with w=(L+)Tz, and wi=zi+Li+zi+1=0 for i<r. Row i of L+D+w is Di+wi+Li−1+Di−1+wi−1, which vanishes for i<r. By Lemma 2, Mz=U−D−v with v=(U−)Tz, and vi=zi+Ui−1−zi−1=0 for i>r; row i of U−D−v is Di−vi+Ui−Di+1−vi+1, which vanishes for i>r. So Mz=cer with c=(Mz)r=βr−1zr−1+(αr−μ)+βrzr+1. Now βr−1zr−1=−Dr−1+(Lr−1+)2=Dr+−(αr−μ) by the diagonal of Lemma 1, and βrzr+1=−Dr+1−(Ur−)2=Dr−−(αr−μ) by the diagonal of Lemma 2 (terms with index 0 or n+1 are absent, and the identities still hold with D1+=α1−μ, Dn−=αn−μ). Hence c=Dr++Dr−−(αr−μ)=(dr+sr)+(dr−1lr−12+pr)−(dr+dr−1lr−12−μ)=γr. Finally z=γrM−1er, and zr=1 gives γr(M−1)rr=1. □
Lemma 4 (counts). The number of negative Di+ in Lemma 1 equals the number of eigenvalues of LDLT less than τ.
Proof. LDLT−τI=L+D+(L+)T is congruent to D+, and by Sylvester's law of inertia it has as many negative eigenvalues as D+ has negative entries. Its eigenvalues are λ−τ. □
Lemma 5 (bisection). Let ν(x) be the count of Lemma 4. The routine bisect(k) ends with lo<hi, ν(lo)<k≤ν(hi), and returns the midpoint λ^; hence the k-th smallest eigenvalue λk of LDLT satisfies ∣λ^−λk∣≤(hi−lo)/2≤umax(∣lo∣,∣hi∣) when the width test stops it, and the loop runs at most 400 steps after finitely many bracket expansions.
Proof. ν is nondecreasing, 0 below the spectrum and n above it, so moving lo down by doubling steps reaches ν(lo)<k and moving hi up reaches ν(hi)≥k after finitely many steps. Each bisection step keeps the half on which the invariant holds. The invariant gives λk∈[lo,hi): at most k−1 eigenvalues lie below lo, so λk≥lo, and at least k lie below hi, so λk<hi. The midpoint is then within (hi−lo)/2 of λk. □
Lemma 6 (residual and angle of a twisted vector). Let λj be the eigenvalue of LDLT nearest to μ, δ=∣λj−μ∣, g=mini=j∣λi−μ∣, and suppose δ<g/(2n). For r minimizing ∣γk∣ and z^=z/∥z∥2: ∥Mz^∥2≤∣γr∣≤2nδ, and sin∠(z^,vj)≤2nδ/g.
Proof. With orthonormal eigenvectors vi, (M−1)kk=∑ivi(k)2/(λi−μ). Pick k with vj(k)2≥1/n. Then ∣(M−1)kk∣≥1/(nδ)−1/g≥1/(2nδ), so by Lemma 3 ∣γk∣≤2nδ and the minimum is no larger. By Lemma 3, ∥Mz^∥=∣γr∣/∥z∥≤∣γr∣, since ∥z∥≥∣zr∣=1. Write z^=cosθvj+sinθw with w⊥vj a unit vector; then ∥Mz^∥≥∥Mw∥sinθ≥gsinθ, because M maps the orthogonal complement of vj into itself with smallest singular value g. □
Theorem 7 (correctness and termination). On each unreduced block: (a) the loop terminates; (b) every eigenvalue index is assigned exactly one value and one unit vector; (c) every representation on the stack equals T−σI for its accumulated shift σ; (d) for an index finished as a singleton in a representation where the relative gap condition holds, the returned pair (σ+λ^,z^) satisfies ∥(T−(σ+λ^)I)z^∥2≤2nδ and sin∠(z^,v)≤2nδ/g with δ, g as in Lemma 6 for that representation; (e) vectors from a fallback cluster are orthonormal.
Proof. (c) The root satisfies LDLT=T−σI by Gaussian elimination without pivoting, whose pivots are all positive by the test in root_ldl (so T−σI is positive definite). A child built from (LDLT,τ) satisfies L+D+(L+)T=LDLT−τI=T−(σ+τ)I by Lemma 1, and is pushed with shift σ+τ. Induction on the depth.
(b) The root is pushed with all indices 1,…,m. When a node is popped, _groups partitions its index list into consecutive runs; each run of length one is assigned at once, each longer run is either assigned at once (fallback) or pushed as a child with exactly that index list. So the index lists of the nodes ever pushed form a tree in which the children of a node partition a subset of its indices and the remaining indices are assigned in the node; every index is assigned exactly once. The eigenvalues of a child are the same indices because a shift preserves the order: the k-th smallest eigenvalue of T−σI minus τ is the k-th smallest of T−(σ+τ)I.
(a) A child is pushed only when the depth of its parent is below maxdepth, so the tree has height at most maxdepth, and each node has at most m/2 children because each child has at least two indices. So the tree is finite. Each node does finitely many operations: by Lemma 5 each bisection ends, the shift search tries at most 2⋅TRIES shifts, and the fallback tries at most m twist indices per eigenvalue.
(d) By (c), T−(σ+λ^)I=LDLT−λ^I=M, and Lemma 6 applies.
(e) Each kept vector is normalized after being made orthogonal to the earlier ones (twice, which in exact arithmetic is once); the Rayleigh-Ritz step multiplies this orthonormal set by the orthogonal eigenvector matrix of a small symmetric matrix. □
Remarks (what is cited, not proved). (1) The size of δ. By Lemma 5, δ≤u∣λj(rep)∣ for an eigenvalue λj(rep) of the representation, so Lemma 6 gives sin∠≤2nu/relgap with relgap=g/∣λj(rep)∣; the clustering rule makes relgap at least about gaptol for singletons. This is why MRRR shifts a cluster until its members have large relative gaps. (2) Floating point. That the computed stationary and progressive transforms are exact for small relative perturbations of L, D and the outputs (mixed relative stability), that a relatively robust representation determines its eigenvalues and eigenvectors to high relative accuracy, and that the computed vectors from different representations are numerically orthogonal, ∣z^iTz^j∣=O(nu/gaptol), and have residuals O(nu∥T∥), are the theorems of Dhillon and Parlett (2004a, 2004b) and Dhillon, Parlett and Vömel (2006), under the hypothesis that every representation used is relatively robust for its cluster. The element growth test of the code is the heuristic check of that hypothesis used in LAPACK; it is not a proof. The tests observe residuals below 1.3nu∥T∥, orthogonality below 9nu on random matrices and on glued Wilkinson matrices, and 68nu on W21+, whose singletons have relative gaps just above gaptol.