arXiv:2103.02086v1 [math.NA] 2 Mar 2021 References h vrl loih n ueia eut 26 results numerical and algorithm overall The 7 structure Jordan numerical the Computing 6 optn tics ietiltwt nw tutr 13 11 structure known a with eigentriplet staircase a sensitivity Computing its and 5 eigentriplet staircase numerical The eigentriplet 4 staircase a of Regularity 3 Preliminaries 2 Introduction 1 Contents . ueia eut ...... results Numerical algorithm overall 7.2 The 7.1 . ueia xmlsfrcmuigtesaraefr . . . . . form . . staircase . the . . . computing decomposition . for . Jordan examples . to . Numerical . form . staircase . eigentriplet a 5.4 staircase Converting . a for refinement eigentriplet 5.3 Iterative staircase initial the 5.2 Computing 5.1 . h iia oyoil...... stratification . bundle . . . matrix . and . reduction polynomials . Hessenberg . Minimal via . polynomial polynomials minimal . minimal 6.4 The via . structure . Jordan 6.3 The . polynomial minimal 6.2 The 6.1 . h tics om...... Form . Canonical . . . Jordan . . numerical . the . . . of . . notion . The . . form . . staircase 2.4 . The characteristics . Weyr and . 2.3 Segre terminology and 2.2 Notation 2.1 optn h odnCnnclForm Canonical Jordan the Computing hngn Zeng Zhonggang ueia Method Numerical A for and inYe Li Tien-Yien 15 ...... 16 16 ...... 14 ...... 25 ...... 21 ...... 20 ...... 5 ...... 4 ...... 3 . . . . 27 . . . 26 . . . 18 . . . 4 . . 29 18 7 3 1 i A numerical method for computing the Jordan Canonical Form
Zhonggang Zeng∗ Tien-Yien Li†
March 4, 2021
Abstract
The Jordan Canonical Form of a matrix is highly sensitive to perturbations, and its nu- merical computation remains a formidable challenge. This paper presents a regularization theory that establishes a well-posed least squares problem of finding the nearest staircase decomposition in the matrix bundle of the highest codimension. A two-staged algorithm is developed for computing the numerical Jordan Canonical Form. At the first stage, the method calculates the Jordan structure of the matrix and an initial approximation to the multiple eigenvalues. The staircase decomposition is then constructed by an iterative algorithm at the second stage. As a result, the numerical Jordan Canonical decomposition along with multiple eigenvalues can be computed with high accuracy even if the underlying matrix is perturbed. keywords Jordan canonical form, eigenvalue, staircase form,
1 Introduction This paper presents an algorithm and a regularization theory for computing the Jordan Canon- ical Form accurately even if the matrix is perturbed.
The existence of the Jordan Canonical Form is one of the fundamental theorems in linear algebra as an indispensable tool in matrix theory and beyond. In practical applications, however, it is well documented that the Jordan Canonical Form is extremely difficult, if not impossible, for numerical computation [3, p.25], [5, p.52], [8, p.189], [9, p.165], [13, p.146], [23, p.371], [26, p.132], [44, p.22]. In short, as remarked in a celebrated survey article by Moler and Van Loan [38]: “The difficulty is that the JCF cannot be computed using floating point arithmetic. A single rounding error may cause some multiple eigenvalue to become distinct or vise versa, altering the entire structure of J and P .”
Indeed, defective multiple eigenvalues in a non-trivial Jordan Canonical Form degrade to clus- ters of simple eigenvalues in practical numerical computation. A main theme of the early
∗Department of Mathematics, Northeastern Illinois University, Chicago, IL 60625 (email: [email protected]). Research supported in part by NSF under Grant DMS-0412003. †Department of Mathematics, Michigan State University, East Lansing, MI 48824 (email: [email protected]). Research supported in part by NSF under Grant DMS-0411165.
1 attempts for numerical computation of the Jordan Canonical Form is to locate a multiple eigenvalue as the mean of a cluster that is selected from eigenvalues computed by QR algo- rithm and, when it succeeds, the Jordan structure may be determined by computing a staircase form at the multiple eigenvalue. This approach includes works of Kublanovskaya [33] (1966), Ruhe [41] (1970), Sdridhar et al [43] (1973), and culminated in Golub and Wilkinson’s review [24] (1976) as well as K˚agstr¨om and Ruhe’s JNF [29, 30] (1980). Theoretical issues have been analyzed in, e.g. [11, 12, 48, 49].
However, the absence of a reliable method for identifying the proper cluster renders a major difficulty for this approach. Even if the correct cluster can be identified, its arithmetic mean may not be sufficiently accurate for identifying the Jordan structure, as shown in Example 1 (§4). While improvements have been made steadily [6, 37], a qualitative approach is proposed in [8], and a partial canonical form computation is studied in [31], “attempts to compute the Jordan canonical form of a matrix have not been very successful” as commented by Stewart in [44, p. 22].
A related development is to find a well-conditioned matrix G such that G-1AG is block diagonal [23, §7.6.3]. Gu proved this approach is NP-hard [25], with a suggestion that “it is still possible that there are algorithms that can solve most practical cases” for the problem. Another closely related problem is the computation of the Kronecker Canonical Form for a matrix pencil A λB (see [15, 16, 17, 28]). For a given Jordan structure, a minimization − method is proposed in [36] to find the nearest matrix with the same Jordan structure.
Multiple eigenvalues are multiple roots of the characteristic polynomial of the underlying ma- trix. There is a perceived barrier of “attainable accuracy” associated with multiple zeros of algebraic equations which, in terms of number of digits, is the larger one between data error and machine precision divided by the multiplicity [39, 50, 53]. Thus, as mentioned above, ac- curate computation of multiple eigenvalues remains a major obstacle of computing the Jordan Canonical Form using floating point arithmetic. Recently, a substantial progress has been achieved in computing multiple roots of polynomials. An algorithm is developed in [53] along with a software package [52] that consistently determines multiple roots and their multiplicity structures of a polynomial with remarkable accuracy without using multiprecision arithmetic even if the polynomial is perturbed. The method and results realized Kahan’s observation in 1972 that multiple roots are well behaved under perturbation when the multiplicity structure is preserved [32].
Similar to the methodology in [53], we propose a two-stage algorithm in this paper for com- puting the numerical Jordan Canonical Form. To begin, we first find the Jordan structure in terms of the Segre/Weyr characteristics at each distinct eigenvalue. With this structure as a constraint, the problem of computing the Jordan Canonical Form is reformulated as a least squares problem. We then iteratively determine the accurate eigenvalues and a staircase decomposition, and the Jordan decomposition can follow as an option.
We must emphasize the numerical aspect of our algorithm that focuses on computing the numerical Jordan Canonical Form of inexact matrices. The exact Jordan Canonical Form of a matrix with exact data may be obtainable in many cases using symbolic computation (see, e.g. [10, 21, 22, 35]). Due to ill-posedness of the Jordan Canonical Form, however, symbolic computation may not be suitable for applications where matrices will most likely be perturbed
2 in practice. For those applications, we must formulate the notion of the numerical Jordan Canonical Form that is structurally invariant under small data perturbation, and continuous in a neighborhood of the matrix with the exact Jordan Canonical Form in question.
More precisely, matrices sharing a particular Jordan structure form a matrix bundle, or, a manifold. For a given matrix A, we compute the exact Jordan Canonical Form of the nearest matrix A˜ in a bundle Π of the highest co-dimension within a neighborhood of A. Under this formulation, computing the numerical Jordan Canonical Form of A should be a well-posed problem when A is sufficiently close to bundle Π. In other words, under perturbation of sufficiently small magnitudes, the deviation of the numerical Jordan Canonical Form is tiny with the structure intact.
The main results of this paper can be summarized as follows. In §3, we formulate a system of quadratic equations that uniquely determines a local staircase decomposition at a multiple eigenvalue from a given Jordan structure. Regularity theorems (Theorem 1 and Theorem 2) in this section establish the well-posedness of the staircase decomposition that ensures accurate computation of multiple eigenvalues. Based on this regularity, the numerical unitary-staircase eigentriplets is formulated in §4, along with the backward error measurement and a proposed condition number.
In §5, we present an iterative algorithm for computing the well-posed unitary-staircase eigen- triplet assuming the Jordan structure is given. The algorithm employs the Gauss-Newton it- eration whose local convergence is a result of the regularity theorems given in §3. The method itself can be used as a stand-alone algorithm for calculating the nearest staircase/Jordan de- composition of a given structure, as demonstrated via numerical examples in §5.4.
The algorithm in §5 requires a priori knowledge of the Jordan structure, which can be com- puted by an algorithm we propose in §6. The algorithm employs a special purpose Hessenberg reduction and a rank-revealing mechanism that produces the sequence of minimal polynomials. Critically important in our algorithm is the application of the recently established robust mul- tiple root algorithm [53] to those numerically computed minimal polynomials in determining the Jordan structure as well as an initial approximation of the multiple eigenvalues, providing the crucial input items needed in the staircase algorithm in §5. In §7, we summarize the overall algorithm and present numerical results
2 Preliminaries 2.1 Notation and terminology Throughout this paper, matrices are denoted by upper case letters A, B, etc., and O denotes a zero matrix with known dimensions. Vectors are in columns and represented by lower case boldface letters like u, v and x. A zero vector is denoted by 0, or 0n to emphasize the dimension. The notation ( )⊤ represents the transpose of a matrix or a vector ( ), and ( )H · · · is its Hermitian adjoint (or conjugate transpose). The fields of real and complex numbers are denoted by R and C respectively.
For any matrix B Cm×n, the rank, nullity, range and kernel of B are denoted by rank B , ∈ nullity B , ( B ) and ( B ) respectively. The n n identity matrix is In, or simply R K × I when its size is clear. The column vectors of I are canonical vectors e , , en. A 1 · · ·
3 matrix U Cm×n is said to be unitary if U HU = I. A matrix V Cm×(n-m) is called a ∈ ∈ unitary complement of unitary matrix U if [U, V ] is a square unitary matrix. Subspaces of Cn are denoted by calligraphic letters , , with dimensions dim , dim , etc., and X Y X Y ⊥ stands for the orthogonal complement of subspace . The set of distinct eigenvalues of X X A is the spectrum of A and is denoted by Λ A .
2.2 Segre and Weyr characteristics The Jordan structure and the corresponding staircase structure (see §2.3) of an eigenvalue can be characterized by the Segre characteristic and the Weyr characteristic respectively. These two characteristics are conjugate partitions of the algebraic multiplicity of the underlying eigenvalue. Here, a sequence of nonnegative integers k k is called a partition of { 1 ≥ 2 ≥···} a positive integer k if k = k +k + . For such a partition, sequence lj = max i ki j , 1 2 · · · ≥ j = 1, 2, is called the conjugate partition of k1, k2, . For example,n [3, 2, 2, 1]o is · · · { ···} a partition of 8 with conjugate [4, 3, 1] and vice versa.
Let λ be an eigenvalue of A with an algebraic multiplicity m corresponding to elementary Jordan blocks of orders n n nl > 0. The infinite sequence n , ,nl, 0, 0, is 1 ≥ 2 ≥···≥ { 1 · · · ···} called the Segre characteristic of A associated with λ. The Segre characteristic forms a partition of the algebraic multiplicity m of λ. Its conjugate partition is called the Weyr characteristic of A associated with λ. We also take the Weyr characteristic as an infinite sequence for convenience. The nonzero part of such sequences will be called the nonzero Segre/Weyr characteristics. Let A be an n n matrix with Weyr characteristic × m m associated with an eigenvalue λ. Then [14, Definition 3.6 and Lemma { 1 ≥ 2 ≥ ···} 3.2], for j = 1, 2, , · · · j j-1 mj = nullity (A λI) nullity (A λI) − − − which immediately implies the uniqueness of the two charact eristics and their invariance under unitary similarity transformations, since the rank of (P AP -1 λI)j = P (A λI)jP -1 is the − − same as the rank of (A λI)j for j = 1, 2, . In particular, both characteristics are − · · · invariant under Hessenberg reduction [23, §7.4.3].
2.3 The staircase form Discovered by Kublanovskaya [33], a matrix is associated with a staircase form given below.
Cn×n k Lemma 1 Let A be a matrix with nonzero Weyr characteristic mj j=1 associated ∈ { n×m} with an m-fold eigenvalue λ. For consecutive j = 1, , k, let Yj C j be a matrix j · · · ∈ satisfying Y , ,Yj = (A λI) . Then Y , ,Yk is of full rank and R 1 · · · K − 1 · · · A Y , ,Yk = Y , ,Yk (λIm + S) (1) 1 · · · 1 · · · m1 m2 ··· mk O S12 ··· S1k m1 .. .. . . where S = . . . . (2) .. . S - mk-1 k 1,k O k m
Furthermore, all super-diagonal blocks S ,S , ,Sk- ,k are matrices of full rank. 12 23 · · · 1
4 Proof. Equation (1) and the existence of S in (2) can be proved by a straightforward l verfication using ( Yl )= (A λI) for l = 1, , k. From (2), we have R K − · · · l-1 l-2 l-2 (A λI) Yl = (A λI) Y1S1,l + + Yl-1Sl-1,l = (A λI) Yl-1Sl-1,l. − − · · · − ml-1×ml This implies Sl-1,l C is of full rank since Sl-1,l z = 0 with z = 0 will lead to l∈-1 6 Yl z (A λI) = Y1, ,Yl-1 , contradicting to the linear independence of ∈ K − R · · · columns of Y , ,Yl . ✷ 1 · · · The matrix λmI + S in (1) is called a local staircase form of A associated with λ. The matrix S is called a staircase nilpotent matrix associated with eigenvalue λ. Writing Y = Y , ,Yk , we call the array (λ, Y, S) as in (1) a staircase eigentriplet of A associated 1 · · · with Weyr characteristic m m . It is called unitary-staircase eigentriplet { 1 ≥ 2 ≥ ···} of A if Y is a unitary matrix. The unitary-staircase form is often preferable to Jordan Canonical Form itself since the columns of Y = Y , ,Yk in (1) form an orthonormal 1 · · · basis for the invariant subspace of A associated with λ. n×n Let Λ A = λ , , λl . Lemma 1 lead to the existence of a unitary matrix U C sat- { 1 · · · } ∈ isfying [24, 33, 41]
λ1I + S1 T12 ··· T1l .. . H λ I S . A = UTU , where T = 2 + 2 . (3) . .. T l-1,l λlI + Sl The matrix T in (3) is called a staircase form of A and the matrix factoring UTU H is called a unitary-staircase decomposition of A. A staircase decomposition of matrix A can be converted to Jordan decomposition via a series of similarity transformations [24, 30, 33, 41].
2.4 The notion of the numerical Jordan Canonical Form
Corresponding to a fixed set of k integer partitions ni ni for i = 1, k with { 1 ≥ 2 ≥···} · · · i,j nij = n, the collection of all n n matrices with k distinct eigenvalues associated ∞ × with Segre characteristics nij for i = 1, , k forms a manifold, known as a matrix P { }j=1 · · · bundle originated by A. I. Arnold [1]. This bundle has a codimension that can be represented in terms of Segre/Wyre characteristics [1, 14]
k ∞ k ∞ 2 1+ (2j 1)nij 1+ m . (4) i=1 − j=1 − ≡ i=1 − j=1 ij ∞P P P P where mij for 1 i k are corresponding Weyr characteristics. When a matrix { }j=1 ≤ ≤ A belongs to such a bundle, it can also be in the closure of many bundles with respect to different Segre characteristics. In other words, a matrix with certain Jordan structure can be arbitrarily close to matrices with other Jordan structures. For example, matrix deformations
λ 1 λ 1 λ 1 λ ε ε→0 λ δ→0 λ λ δ λ δ λ λ λ λ (5) bundle codimention = 3 −→ bundle codimention = 7 −→ bundle codimention = 9 show that a matrix with Segre characteristic 2, 1, 1 is arbitrarily close to some matrices with { } Segre characteristic 2, 2 , which are arbitrarily near certain matrices with Segre characteristic { }
5 4 . Let ( ) denote the matrix bundle with respect to the Segre characteristics listed in { } B · ( ) and ( ) denote its closure. Then (5) suggests that ( 2, 1, 1 ) ( 2, 2 ) and · B · B { } ⊂ B { } ( 2, 2 ) ( 4 ). Extensively studied in e.g. [7, 14, 16, 17, 20], these closure relationships B { } ⊂ B { } form a hierarchy or stratification of Jordan structures that can be conveniently decoded by a covering relationship theorem by Edelman, Elmroth and K˚agstr¨om [17, Theorem 2.6]. As an example, Figure 1 lists all the Jordan structures and their closure stratification for 4 4 × matrices in different Segre characteristics and codimensions of matrix bundles.
Number of distinct eigenvalues Codim 1 2 3 4
15 {1,1,1,1}
9 {2,1,1} : 8 {1,1,1} {1} "is in the closure of"
7 {2,2}
6 {1,1}{1,1}
5 {3,1}
4 {2}{1,1} {2,1} {1}
3 {4} {1,1}{1}{1}
2 {2}{2}{3} {1}
1 {2}{1}{1}
0 {1}{1}{1}{1}
Figure 1: Stratification of Jordan structures for 4 × 4 matrices [17]. General stratification graphs can be drawn automatically using software package StratiGraph [19, 27].
Let dist A, Π = inf A B F B Π present the distance of a matrix A to a bundle × k − k ∈ Π. When A Cn n is near a bundle Π, say Π = ( 2, 2 ) listed in Figure 1, then ∈ B { } clearly dist A, Π dist A, ( 3, 1 ) since Π = ( 2, 2 ) ( 3, 1 ). Indeed, matrix ≥ B { } B { } ⊂ B { } A is automatically as close, or even closer, to ten other bundles of lower codimensions below 2, 2 following the hierarchy. In practical applications and numerical computation, the given { } matrix A comes with imperfect data and/or roundoff error. We must assume A = A + E with a perturbation E of small magnitude E F on the original matrix A. The main theme k k of this article is: How to compute the Jordan Canonical Form of the matrix A accuratelyb from its inexact data A. b b Suppose matrix A has an exact nontrivial Jordan Canonical Form and thus belongs to a bundle Π of codimension d, then there is a lower bound δ > 0 for the distance from A to any other bundleb Π′ of codimension d′ d. When A is the given data of A with an ≥ imperfect accuracy, that is, A = A + E with a perturbation E, then A generically resides in the bundle ( 1 , 1 , , 1 ) of codimension 0. As a result, the Jordan structureb of B { } { } · · · { } b 6 A is lost in exact computation on A for its (exact) Jordan Canonical Form. However, the original bundle Π where A belongs to has a distinct feature: it is of the highest codimension amongb all the bundles passing through the ε-neighborhood of A, as long as ε satisfies dist A, Π <ε<δ. Therefore,b to recover the desired Jordan structure of A from its empirical data A, we first identify the matrix bundle Π of the highest codimension in the neighborhood of A, followed by determining the matrix A on Π that is closestb to A. The numerical Jordan Canonical Form of A will then be defined as the exact Jordan Canonical Form of A. In summary, the notion of the numerical Jordane Canonical Form is formulated according to the following three principles: e • Backward nearness: The numerical Jordan Canonical Form of A is the exact Jordan Canonical Form of certain matrix A within a given distance ε, namely A A F < ε. k − k • Maximum codimension: Among all matrix bundles having distance less than ε of A, matrix A lies in the bundle Π withe the highest codimension. e • Minimum distance: Matrix A is closest to A among all matrices in the bundle Π. e e Definition 1 For A Cn×n and ε> 0, let Π Cn×n be the matrix bundle such that ∈ ⊂ codim Π = max codim Π′ dist A, Π′ < ε , and A Π satisfying A A F = min A B F with (exact) Jordan decomposition ∈ k − k B∈Π k − k - A = XJX 1. Then J is called the numerical Jordan Canonical Form of A within ε, e - e and XJX 1 is called the numerical Jordan decomposition of A within ε. e Remark: The same three principles have been successfully applied to formulate other ill- posed problems with well-posed numerical solutions such as numerical multiple roots [53] and numerical polynomial GCD [51, 54]. In this section, we shall attempt to determine the structure of the bundle Π with the highest codimension in the neighborhood of A. The iterative algorithm EigentripletRefine developed in §5.2 is essentially used to find the matrix A in the bundle Π which is nearest to matrix A. ✷
There ise an inherent difficulty in computing the Jordan structure from inexact data and/or using floating point arithmetic. If, for instance, a matrix is near several bundles of the same codimension with almost identical distances, then the structure identification may not be a well determined problem. Therefore, occasional failures [18] for computing the numerical Jordan Canonical Form can not be completely eliminated.
3 Regularity of a staircase eigentriplet For an eigenvalue λ of matrix A with a fixed Weyr characteristic, the components U and S of the staircase eigentriplet in the staircase decomposition AU = U (λI + S) are not unique. We shall impose additional constraints for achieving uniqueness which is important in establishing the well-posedness of computing the numerical staircase form.
Theorem 1 Let A Cn×n and λ Λ A of multiplicity m with nonzero Weyr ∈ ∈ n characteristic m mk. Then for almost all b , , bm C there is a unitary 1 ≥ ··· ≥ 1 · · · ∈
7 n×m m×m matrix U = u , , um C and a staircase nilpotent matrix S C as in (2) 1 · · · ∈ ∈ such that AU U(λI + S) = O − H (6) u bj = 0 for every (i, j) Φλ i ∈ where Φλ (i, j) µ - < i µ , i and µ0 = 0, µj = m 1 + + mj, j = 1, , k. (8) · · · · · · Moreover, if there is another unitary matrix Uˆ = [uˆ1, , uˆm] and a staircase nilpotent · · · H matrix Sˆ that can substitute U and S in (6), then Sˆ = Uˆ (A λI)Uˆ where Uˆ = UD − for a diagonal matrix D = diag α , , αm with α = = αm = 1. 1 · · · | 1| · · · | | Remark : The second equation in (6) along ∗ 0 0 0 ∗ ∗ ∗ ∗ ∗ ∗ ∗ 0 0 ∗ ∗ ∗ ∗ ∗ with the index set Φλ in (7) means that, for ∗ ∗ ∗ 0 ∗ ∗ ∗ ∗ ∗ ∗ ∗ ∗ ∗ ∗ ∗ ∗ ∗ ∗ j = 1, , k, the matrix UjBj is lower tri- ∗ ∗ ∗∗ ∗ 0 0 ∗ ∗ · · · ∗∗∗∗∗∗ 0 ∗ ∗ angular where Uj = uµj-1+1, , uµj and ∗∗∗∗∗∗∗ ∗ ∗ · · · ∗∗∗∗∗∗∗∗ 0 Bj = bµ + , , bµ . For example: Let j-1 1 · · · j ∗∗∗∗∗∗∗∗∗ λ be an eigenvalue with Weyr characteris- tic 4, 3, 2 , we have multiplicity m = 9, Figure 2: Index set Φλ for Weyr characteristic { } {4, 3, 2}. Every (i, j) ∈ Φλ entry is zero. [µ0,µ1,µ2,µ3] = [0, 4, 7, 9], and Φλ = (1, 2), { H (1, 3), (1, 4), (2, 3), (2, 4), (3, 4), (5, 6), (5, 7), (6, 7), (8, 9) . The matrix U [b , , b ] has zero at every } 1 · · · 9 (i, j) Φλ entry. As shown in Figure 2, those zeros are under the staircase and above the ∈ diagonal. ✷ Proof of Theorem 1. For j = 1, , k, the subspace (A λI)j (A λI)j-1 ⊥ · · · K − ∩ K − is of dimension mj. For almost all vectors bi, i = µj-1+1, ,µj, the subspace · · · j j-1 ⊥ ⊥ (A λI) (A λI) span bµ + , bµ K − ∩ K − ∩ j-1 2 · · · j is of dimension one and spanned by a unit vector uµj-1+1 which is unique up to a unit constant multiple. After obtaining uµ + , uµ +l, the subspace j-1 1 · · · j-1 j j-1 ⊥ ⊥ (A λI) (A λI) span uµ + , uµ +l, bµ +l+ , bµ K − ∩ K − ∩ j-1 1 · · · j-1 j-1 2 · · · j is of dimension one and spanned by uµj-1+l+1 which is again unique up to a unit constant multiple. Therefore, we have a unitary matrix Uj = uµ + , , uµ , whose columns j-1 1 · · · j j j-1 ⊥ satisfy the second equation in (6) and span the subspace (A λI) (A λI) K − H∩ K − for j = 1, , k. These unitary matrices uniquely determines Sij = U (A λI)Uj in (2). · · · i − It is straightforward to verify (6) for U = U , ,Uk = u , , um . ✷ 1 · · · 1 · · · One of the main components of our algorithm is an iterative refinement of the eigentriplet (λ, U, S) using the Gauss-Newton iteration. For this purpose we need to construct a system of analytic equations for the eigentriplet (λ, U, S) specified in Theorem 1. If the matrix A and the eigenvalue λ are real, it is straightforward to set up the system using equations in (6 along with the orthogonality equaiton U ⊤U I = O. When either matrix A or eigenvalue − H λ is complex, however, the unitary constraint U U I = O is not analytic. One way to H − circumvent this difficulty is converting (6) and U U I = O to real equations by splitting − A and the eigentriplet (λ, U, S) into real and imaginary parts. The resulting system of real equations would be real analytic. 8 Alternatively, we developed a simple and effective strategy to overcome this difficulty by a two step approach. As an initial approximation, a staircase eigentriplet (λ, Y, S) is computed and Y does not need to be unitary. We replace the unitary constraint U HU I with a − nonsingularity requirement 1 0 ··· 0 . . . . C H Y = ∗ 1 . . (9) . . . ...... 0 ∗ ··· ∗ 1 m×m n via a constant matrix C = c , , cm C . The solution Y = [y , , ym] to the { 1 · · · } ⊂ 1 · · · equation (9) combined with (6) is a nonsingular matrix whose columns span the invariant subspace of A associated with λ. Then, at the second step, Y can be stably orthogonalized to U = u , , um and provide the solution of (6). If necessary, we repeat the process 1 · · · as refinement by replacing C with U in (9) along with (6) and solve for Y again using the previous eigentriplet results as the initial iterate. In the spirit of Kahan’s well-regarded “twice is enough” observation [40, p. 110], this reorthogonalization never needs the third run. n In general, let b1, , bm C be the set of predetermined random complex vectors as in { · · · }⊂ n Theorem 1. A second set of complex vectors c , , cm C will also be chosen to set up 1 · · · ∈ the overdetermined quadratic system (A λI)Y = Y S − H H c1, , ci yi = [0, , 0, 1] , for 1 i m (10) · · · H · · · ≤ ≤ b yi = 0, for (i, j) Φλ j ∈ where Φλ is defined in (7). There are η equations and ζ unknowns in (10) where m2 1 k 2 η = nm + 2 + 2 j=1 mj and ζ = 1+ nm + i