Scaling, Sensitivity and Stability in Numerical Solution of the Quadratic Eigenvalue Problem Nick Higham School of Mathematics The University of Manchester higham@ma.man.ac.uk http://www.ma.man.ac.uk/~higham/ Joint work with Seamus Garvey, Steve Mackey and Françoise Tisseur
NLEVP Toolbox with T. Betcke, V. Mehrmann, C. Schröder, F. Tisseur Collection of Nonlinear Eigenvalue Problems : F(λ)x = 0, where F : C C m n. Provided as a MATLAB Toolbox. Problems from real-life applications + specially constructed problems. Available from http://www.mims.manchester.ac.uk/research/ numerical-analysis/nlevp.html MIMS Nick Higham Quadratic Eigenproblem 2 / 31
NLEVP Toolbox with T. Betcke, V. Mehrmann, C. Schröder, F. Tisseur Collection of Nonlinear Eigenvalue Problems : F(λ)x = 0, where F : C C m n. Provided as a MATLAB Toolbox. Problems from real-life applications + specially constructed problems. Available from http://www.mims.manchester.ac.uk/research/ numerical-analysis/nlevp.html Further contributions are welcome. MIMS Nick Higham Quadratic Eigenproblem 2 / 31
Outline 1 QEP and Linearization Background 2 Conditioning of Linearizations 3 Scaling 4 Algorithm based on Linearization MIMS Nick Higham Quadratic Eigenproblem 3 / 31
Quadratic Eigenproblems Consider Q(λ) = λ 2 M + λd + K, M, D, K C n n. QEP: find scalars λ and nonzero x, y C n satisfying Q(λ)x = 0 and y Q(λ) = 0. λ is an e val, x, y are corresponding right and left e vecs. Q(λ) has 2n eigenvalues, solutions of det(q(λ)) = 0. MIMS Nick Higham Quadratic Eigenproblem 4 / 31
Quadratic Eigenproblems Consider Q(λ) = λ 2 M + λd + K, M, D, K C n n. QEP: find scalars λ and nonzero x, y C n satisfying Q(λ)x = 0 and y Q(λ) = 0. λ is an e val, x, y are corresponding right and left e vecs. Q(λ) has 2n eigenvalues, solutions of det(q(λ)) = 0. When λ =, consider homogeneous form of Q: Q(α,β) = α 2 M + αβd + β 2 K. E vals are pairs (α,β) (0, 0) s.t. det Q(α,β) = 0. MIMS Nick Higham Quadratic Eigenproblem 4 / 31
Linearizations L(λ) = λx + Y, X, Y C 2n 2n is a linearization of Q(λ) = λ 2 M + λd + K if [ ] Q(λ) 0 E(λ)L(λ)F(λ) = 0 I n for some unimodular E(λ) and F(λ). Example [ ] M 0 For companion pencil C 1 (λ) = λ + 0 I n ( ) holds with [ In λm + D E(λ) = 0 I n ( ) [ ] D K, I n 0 ] [ ] λin I, F(λ) = n. I n 0 MIMS Nick Higham Quadratic Eigenproblem 5 / 31
Solution Process for QEP Linearize Q(λ) into L(λ) = λx + Y. Solve generalized eigenproblem L(λ)z = 0. Recover eigenvectors of Q from those of L. Usual choice of linearization: companion linearization, [ ] [ ] M 0 D K C 1 (λ) = λ + 0 I I 0 for which right and left e vecs have the form [ ] λx z =, w = x x, y being right and left e vecs of Q(λ). [ y λk y MIMS Nick Higham Quadratic Eigenproblem 6 / 31 ],
Beam Problem /////// L /////// //////////// Transverse displacement u(x, t) governed by ρa 2 u t 2 + c(x) u t + EI 4 u x 4 = 0. Boundary conditions: u(x, t) = u (x, t) = 0 at x = 0, L. u(x, t) = e λt v(x,λ) yields e val problem for the free vibrations : λ 2 ρav(x,λ) + λc(x)v(x,λ) + EI 4 v(x,λ) = 0. x4 MIMS Nick Higham Quadratic Eigenproblem 7 / 31
Discretized Beam Problem Finite element method leads to Q(λ) = λ 2 M + λd + K with symmetric M, D, K R n n. Roots of x Q(λ)x = 0, λ = (x Dx) ± (x Dx) 2 4(x Mx)(x Kx). 2(x Mx) M > 0, K > 0, D 0 all ei vals have Re(λ) 0. D is rank 1. Can show n pure imaginary ei vals. MIMS Nick Higham Quadratic Eigenproblem 8 / 31
Eigenvalues of Q via First Companion C 1 Q(λ) = λ 2 M + λd + K, C 1 (λ) = λ [ ] [ ] M 0 D K +. 0 I I 0 nele = 100; coeffs = nlevp( damped_beam,nele); K = coeffs{1}; D = coeffs{2}; M = coeffs{3}; I = eye(2*nele); O = zeros(2*nele); eval = eig([d K; -I O],-[M O; O I]); plot(eval,.r ) MIMS Nick Higham Quadratic Eigenproblem 9 / 31
[ eig on Companion C 1 (λ)=λ M0 ] [ 0 I + D I ] K 0 4 x 106 3 2 1 0 1 2 3 4 16 14 12 10 8 6 4 2 0 2 4 MIMS Nick Higham Quadratic Eigenproblem 10 / 31
eig on Linearization L 1 (λ)=λ[ M0 ] [ 0 K + DK ] K 0 4 x 106 3 2 1 0 1 2 3 4 16 14 12 10 8 6 4 2 0 2 4 MIMS Nick Higham Quadratic Eigenproblem 11 / 31
[ eig on Linearization L 2 (λ)=λ 0M ] [ M M0 ] D + 0 K 4 x 106 3 2 1 0 1 2 3 4 16 14 12 10 8 6 4 2 0 2 4 MIMS Nick Higham Quadratic Eigenproblem 12 / 31
Spectrum of Beam Problem 4 x 106 3 2 1 0 1 2 3 4 16 14 12 10 8 6 4 2 0 2 4 MIMS Nick Higham Quadratic Eigenproblem 13 / 31
Sensitivity and Stability of Linearizations Condition number measures sensitivity of the solution of a problem to perturbations in the data. Backward error measures how well the problem has been solved. error in solution < condition number backward error. MIMS Nick Higham Quadratic Eigenproblem 14 / 31
Sensitivity and Stability of Linearizations Condition number measures sensitivity of the solution of a problem to perturbations in the data. Backward error measures how well the problem has been solved. error in solution < condition number backward error. For a given Q(λ), infinitely many linearizations exist: can have widely varying eigenvalue condition numbers, computed eigenpairs can have widely varying backward errors. MIMS Nick Higham Quadratic Eigenproblem 14 / 31
Desiderata for a Linearization Good conditioning. Backward stability. Suitable eigenvector recovery formulae. Preservation of structure, e.g. symmetry. Numerical preservation of key qualitative properties, including location and symmetries of spectrum. Preserve partial multiplicities of e vals (strong linearization). MIMS Nick Higham Quadratic Eigenproblem 15 / 31
Vector Spaces L 1, L 2 Mackey, Mackey, Mehl & Mehrmann (2006) define L 1 (Q) = { L(λ) : L(λ)(Λ I n ) = v Q(λ), v C } 2, L 2 (Q) = { L(λ) : (Λ T I n )L(λ) = ṽ T Q(λ), ṽ C } 2, where Λ := [λ, 1] T. MIMS Nick Higham Quadratic Eigenproblem 16 / 31
Vector Spaces L 1, L 2 Mackey, Mackey, Mehl & Mehrmann (2006) define L 1 (Q) = { L(λ) : L(λ)(Λ I n ) = v Q(λ), v C 2 }, L 2 (Q) = { L(λ) : (Λ T I n )L(λ) = ṽ T Q(λ), ṽ C 2 }, where Λ := [λ, 1] T. L(λ) = λx + Y L 1 (Q) with v C 2 iff [ ] [ v1 M v 1 D v 1 K X11 X = 12 + Y 11 Y 12 v 2 M v 2 D v 2 K X 21 X 22 + Y 21 Y 22 ]. MIMS Nick Higham Quadratic Eigenproblem 16 / 31
Vector Spaces L 1, L 2 Mackey, Mackey, Mehl & Mehrmann (2006) define L 1 (Q) = { L(λ) : L(λ)(Λ I n ) = v Q(λ), v C } 2, L 2 (Q) = { L(λ) : (Λ T I n )L(λ) = ṽ T Q(λ), ṽ C } 2, where Λ := [λ, 1] T. Dimensions: L 1, L 2 : 2n 2 + 2. Almost all pencils in L 1 and L 2 are linearizations. MIMS Nick Higham Quadratic Eigenproblem 16 / 31
Eigenvector Recovery for L 1 (Q) L 1 (Q) = { L(λ) : L(λ)(Λ I n ) = v Q(λ), v C 2 } Λ := [λ, 1] T. If L L 1 (Q) with vector v then every right e vec of L with finite e val λ is of the form Λ x for some right e vec x of P, [M 4, 2006] if w is a left e vec of L with e val λ then y = (v I n )w is a left e vec of P with e val λ. [H, Li, Tisseur, 2007]. E vecs of Q easily recovered from e vecs of L L 1. MIMS Nick Higham Quadratic Eigenproblem 17 / 31
Outline 1 QEP and Linearization Background 2 Conditioning of Linearizations 3 Scaling 4 Algorithm based on Linearization MIMS Nick Higham Quadratic Eigenproblem 18 / 31
Eigenvalue Condition Numbers κ Q (λ) Q(λ)x = 0, y Q(λ) = 0. Q(λ) = λ 2 M + λ D + K For λ simple, nonzero and finite, { λ κ Q (λ) = lim sup : [ (Q + Q)(λ + λ) ] (x + x) = 0, ǫ 0 ǫ λ } M 2 ǫm, D 2 ǫd, K 2 ǫk, κ Q (λ) = ( λ 2 m + λ d + k ) y 2 x 2. (Tisseur, 2000) λ y (2λM + D)x MIMS Nick Higham Quadratic Eigenproblem 19 / 31
Eigenvalue Conditioning of Linearizations For L(λ) = λx + Y, L(λ)z = 0, w L(λ) = 0, κ L (λ) = ( λ X 2 + Y 2 ) w 2 z 2. λ w Xz Define growth factor φ L : κ L (λ) = φ L (λ) κ Q (λ). Theorem (H, Mackey, Tisseur, 2006) Let L(λ) = λx + Y B(Q) with vector v. For λ simple, nonzero and finite, where Λ = [λ, 1] T. φ L (λ; v) = λ X 2 + Y 2 λ 2 m + λd + k Λ 2 2 Λ T v, MIMS Nick Higham Quadratic Eigenproblem 20 / 31
Sufficient conditions for κ Q κ L ρ = max(m, d, k)/ min(m, k), Linearization Eigenvalue Condition [ ] [ M 0 D K L 1 (λ) = λ + 0 K K 0 C 1 No restriction m d k 1 λ > L 1 1 ρ 1 λ 1 not available" λ > L 2 1 not available" λ 1 ρ 1 [ ] [ M 0 D K C 1 (λ) = λ + 0 I I 0 ], L 2 (λ) = λ [ 0 M M D ], ] [ ] M 0 +. 0 K MIMS Nick Higham Quadratic Eigenproblem 21 / 31
Beam Problem M 2 = 6.7 10 3, D 2 = 5, K 2 = 1.7 10 9. Thus ρ = 2.6 10 11 beam problem is badly scaled. Approximations to growth factors φ L (λ) = κ L (λ)/κ Q (λ): φ C1 (λ) φ L1 (λ) φ L2 (λ) λ = 10 2 1 10 2 1 10 4 1 10 4 λ = 10 4 1 10 4 1 10 8 1 10 8 λ = 10 6 2 10 5 2 10 11 2 10 11 For λ = 10 6, ǫ 10 16, λ < ǫ λ κ Li (λ) = ǫ λ φ Li (λ)κ Q (λ) = O(1), i = 1, 2. E vals on imaginary axis can be perturbed by distance O(1) into the right half-plane. MIMS Nick Higham Quadratic Eigenproblem 22 / 31
Computed Spectrum of L 1, L 2 and C 1 4 x 106 4 x 106 3 3 2 2 1 1 0 0 1 1 2 2 3 3 4 16 14 12 10 8 6 4 2 0 2 4 4 16 14 12 10 8 6 4 2 0 2 4 4 x 106 3 2 1 0 1 2 3 4 16 14 12 10 8 6 4 2 0 2 4 MIMS Nick Higham Quadratic Eigenproblem 23 / 31
Outline 1 QEP and Linearization Background 2 Conditioning of Linearizations 3 Scaling 4 Algorithm based on Linearization MIMS Nick Higham Quadratic Eigenproblem 24 / 31
Scaling Q(λ) = λ 2 M + λd + K Let λ = µγ and convert Q(λ) = λ 2 M + λd + K δq(µγ) = µ 2 (δγ 2 M) + µ(δγd) + δk = µ 2 M + µ D + K =: Q(µ), where γ = K 2 / M 2, δ = 2/( K 2 + D 2 γ). Fan, Lin and Van Dooren (2004). 2/3 max( M 2, D 2, K 2 ) 2. Does not affect sparsity of M, D, K. Has no effect on κ Q and η Q. γ minimizes scaling factor ρ. MIMS Nick Higham Quadratic Eigenproblem 25 / 31
Effect of Scaling on Beam Problem Before scaling After scaling M 2 10 2 1 D 2 1 10 3 K 2 10 9 1 ρ = 10 11 ρ = 1 Our theory guarantees optimal conditioning and stability for the companion linearization, E val bound µ 1 2 τκ 2(M) ( 1 + 1 + 4/(τ 2 κ 2 (M)) ) = 7.25. Can show this implies symm linearization L 2 optimal in terms of both conditioning and stability. MIMS Nick Higham Quadratic Eigenproblem 26 / 31
Spectrum of C 1, L 2 before/after Scaling 4 x 106 4 x 106 3 3 2 2 1 1 0 0 1 1 2 2 3 3 4 16 14 12 10 8 6 4 2 0 2 4 4 x 106 4 16 14 12 10 8 6 4 2 0 2 4 4 x 106 3 3 2 2 1 1 0 0 1 1 2 2 3 3 4 16 14 12 10 8 6 4 2 0 2 4 4 16 14 12 10 8 6 4 2 0 2 4 MIMS Nick Higham Quadratic Eigenproblem 27 / 31
Outline 1 QEP and Linearization Background 2 Conditioning of Linearizations 3 Scaling 4 Algorithm based on Linearization MIMS Nick Higham Quadratic Eigenproblem 28 / 31
Meta-Algorithm for PEP 1 Balance, scale P (Fan, Lin & Van Dooren, 2004) 2 for one or more (scaled) linearizations L 3 Deflate L 4 Balance, scale L 5 Apply QZ to L (maybe HZ if structured) 6 Obtain relevant e vals 7 Recover left and right e vecs 8 Iteratively refine e vecs 9 Compute/estimate b errs and condition numbers 10 Detect nonregular problem 11 end MIMS Nick Higham Quadratic Eigenproblem 29 / 31
Balancing Ward (1981) for pencils. Lemonnier & Van Dooren (2006) for pencils. Betcke (2009) for polynomials. MIMS Nick Higham Quadratic Eigenproblem 30 / 31
Concluding Remarks Analysis of conditioning & backward error for wide variety of linearizations. E vector recovery formulae crucial. Scaling crucial. Favour L = companion form for general QEPs. Results useful to develop a general QEP algorithm & code. New version ofpolyeig in preparation. For papers and Eprints, http://www.ma.man.ac.uk/~higham MIMS Nick Higham Quadratic Eigenproblem 31 / 31
References I T. Betcke. Optimal scaling of generalized and polynomial eigenvalue problems. SIAM J. Matrix Anal. Appl., 30(4):1320 1338, 2008. T. Betcke, N. J. Higham, V. Mehrmann, C. Schröder, and F. Tisseur. NLEVP: A collection of nonlinear eigenvalue problems. http://www.mims.manchester.ac.uk/ research/numerical-analysis/nlevp.html. MIMS Nick Higham Quadratic Eigenproblem 27 / 31
References II T. Betcke, N. J. Higham, V. Mehrmann, C. Schröder, and F. Tisseur. NLEVP: A collection of nonlinear eigenvalue problems. MIMS EPrint 2008.40, Manchester Institute for Mathematical Sciences, The University of Manchester, UK, Apr. 2008. 18 pp. N. J. Higham, R.-C. Li, and F. Tisseur. Backward error of polynomial eigenproblems solved by linearization. SIAM J. Matrix Anal. Appl., 29(4):1218 1241, 2007. MIMS Nick Higham Quadratic Eigenproblem 28 / 31
References III N. J. Higham, D. S. Mackey, N. Mackey, and F. Tisseur. Symmetric linearizations for matrix polynomials. SIAM J. Matrix Anal. Appl., 29(1):143 159, 2006. N. J. Higham, D. S. Mackey, and F. Tisseur. The conditioning of linearizations of matrix polynomials. SIAM J. Matrix Anal. Appl., 28(4):1005 1028, 2006. N. J. Higham, D. S. Mackey, F. Tisseur, and S. D. Garvey. Scaling, sensitivity and stability in the numerical solution of quadratic eigenvalue problems. Internat. J. Numer. Methods Eng., 73(3):344 360, 2008. MIMS Nick Higham Quadratic Eigenproblem 29 / 31
References IV D. Lemonnier and P. M. Van Dooren. Balancing regular matrix pencils. SIAM J. Matrix Anal. Appl., 28(1):253 263, 2006. D. S. Mackey, N. Mackey, C. Mehl, and V. Mehrmann. Structured polynomial eigenvalue problems: Good vibrations from good linearizations. SIAM J. Matrix Anal. Appl., 28(4):1029 1051, 2006. D. S. Mackey, N. Mackey, C. Mehl, and V. Mehrmann. Vector spaces of linearizations for matrix polynomials. SIAM J. Matrix Anal. Appl., 28(4):971 1004, 2006. MIMS Nick Higham Quadratic Eigenproblem 30 / 31
References V R. C. Ward. Balancing the generalized eigenvalue problem. SIAM J. Sci. Statist. Comput., 2(2):141 152, 1981. MIMS Nick Higham Quadratic Eigenproblem 31 / 31