Optimal symplectic Householder transformations for SR-decomposition

Oct 29, 2006 - It is now clear how to choose the remaining free parameter µ in the expression of .... by block Krylov subspace methods, http://www.dm.unibo.it/ ...
152KB taille 10 téléchargements 306 vues
Optimal symplectic Householder transformations for SR-decomposition A. Salam a,∗, E. Al-Aidarous b , A. El Farouk c a

Laboratoire de Mathématiques Pures et Appliquées, Université du Littoral-Côte d’Opale. C.U. de la Mi-Voix, 50 rue F. Buisson, B.P. 699, 62228 Calais, Cedex, France. b

King Abdul Aziz University (KAU), Department of Mathematics, Girls Section, P.O. Box 80203, Jeddah 21589, Kingdom of Saudi Arabia c

Laboratoire de Mathématiques Pures et Appliquées, Université du Littoral-Côte d’Opale. C.U. de la Mi-Voix, 50 rue F. Buisson, B.P. 699, 62228 Calais, Cedex, France.

Abstract SR factorization is a key step for some important structure-preserving eigenproblem. In this work, we revisit in a modern way Householder transformations in a symplectic linear space context. Then, their main features are given. A new algorithm based on such transformations for a SR-factorization is detailed. It is the analogous of QR factorization, via Householder transformations. Unlike the classical QR factorization, this algorithm involves free parameters. We demonstrate how an optimal choice of these parameters can be obtained. An optimal SR-factorization algorithm is then derived. We end our study by numerical experiments comparing the new algorithm with the best symplectic Gram-Schmidt algorithms for a SR factorization. We conjecture that the new algorithm is forward stable, for the computation of the factor S. Key words: Skew-symmetric inner product, symplectic geometry, symplectic transvections, symplectic Householder transformations, SR factorization, structure and symplectic orthogonality preservation. 1991 MSC: 65F15, 65F50

1 Introduction The SR factorization [5,6,9,14] is a key step for constructing structure-preserving methods for solving the eigenproblem of an important class of structured matrices, ∗ Corresponding author Email address: [email protected] (A. Salam ).

Preprint submitted to Linear Algebra and Its Applications

October 29, 2006

or for preserving geometric properties of some matrix function [12]. It can be interpreted as the equivalent of the classical QR factorization, when instead of an Euclidean space (with usual scalar product), one consider an indefinite inner product space, equipped with a skew-symmetric inner product (See for example [17] and the references therein). This space is called symplectic and its orthogonal group is called the symplectic group. In contrast with the Euclidean case, the symplectic group is not compact. Thus, the Iwasawa’s decomposition for a symplectic matrix is useful for highlighting the link between symplectic and orthogonal groups. It gives in particular the unbounded part of a symplectic matrix. An efficient computational method using QR factorization is recently proposed by Benzi et al. in [2]. A numerical determination of a canonical form of a symplectic matrix is studied by Godunov et al. in [10]. In the Euclidean case, the computational QR factorization is currently handled by two type of algorithms. The first one is a factorization via Gram-Schmidt orthogonalization process, the second one is a factorization using Householder transformations [11,16,21]. The second algorithm is accurate up to the machine precision since it is obtained via a product of orthogonal matrices. The first is more sensitive to the numerical errors. However, the modified version improve the performance of such algorithm. For more details, one can see [3,4]. In the symplectic case, the computational SR factorization, via a symplectic GramSchmidt algorithm is well established and studied (see for example [17,18]). However, to our knowledge, there exists no SR factorization algorithm of the second kind. In the literature, only some empirical attempts has been tried in this sense. Thus, in the context of Hamiltonian or skew-Hamiltonian transformations, methods using elementary symplectic and orthogonal transformations, based on the classical Householder transformations has been proposed in [20,14]. Another kind of empirical transformations has been added to these transformations by Bunse-Gerstner et al. [7], in order to obtain a general SR factorization. Thus, their algorithm, involves three kind of empirical elementary transformations. Its form is heterogeneous and the algorithm does not correspond to the desirable analogous of the classical QR factorization via Householder transformations. In order to remedy to the fact that such methods lack a mathematical analysis study (contrary to the Euclidean case), mathematical tools were introduced and studied in details in [19]. In this paper, we revisit from a linear algebra point of view, the analogous of the Euclidean Householder transformations in a symplectic linear space context. Then, their main features, which will be used, are highlighted. Especially, the mapping problem is updated to our problem. A new algorithm based on such transformations (we refer to as symplectic Householder transformations) for a SR-factorization is detailed. Unlike the classical QR factorization via the classical Householder trans2

formations, this algorithm involves free parameters. It is important to take advantage from this fact. We demonstrate how an optimal choice of these parameters can be obtained. An optimal SR-factorization algorithm is then derived. We end our study by numerical experiments comparisons between the new algorithm and the best symplectic Gram-Schmidt algorithms for a SR factorization. As expected, the superiority of the new algorithm is attested by extensive numerical experiments. We conjecture that the new algorithm is forward stable for the computation of the symplectic factor S is the SR factorization. The remainder of this paper is organized as follows. In section 2, we revisit the symplectic Householder transformations, from algebraic point of view. The main results and properties are detailed. Section 3 describes the SR factorization algorithm, via symplectic Householder transformations. In section 4 deals with our optimal Householder transformations. An optimal choice of free parameters, motivated by the numerical stability is determined. Such transformations will serve to construct an optimal algorithm for a SR factorization. Section 5 is devoted to numerical experiments. The conclusion is reported in section 6.

2 Symplectic Householder transformations

Two type of orthogonal and symplectic matrices has been described by Paige et al. in [14]. The first type is 

 diag(Ik−1 , P )

H(k, w) = 

0

0 diag(Ik−1 , P )



 ,

(2.1)

where P = I − 2ww T /w T w, w ∈ Rn−k+1 . H(k, w) is just a direct sum of two "ordinary" n−by−n Householder matrices [21]. Since H(k, w) is also symplectic, they called it symplectic Householder matrix. This denomination is not adequate, as it will be explained below. The second type is   C

J(k, θ) = 

where

S

−S C

,

(2.2)

C = diag(Ik−1 , cosθ, In−k ) S = diag(0k−1 , sinθ, 0n−k ). J(k, θ) is a Givens symplectic matrix, which is an "ordinary" 2n-by-2n Givens rotations that rotates in planes k and k + n [21]. These transformations are introduced as elementary symplectic transformations for zeroing prescribed entries in vector, in a structure-preserving QR-like algorithm 3

(see [20,14]). The advantage of such transformations is that they are both orthogonal and symplectic. However, the drawback is that they can be used only in the limited case of Hamiltonian or skew Hamiltonian matrices. In addition to these matrices H(k, w) and J(k, θ), Bunse-Gerstner et al. introduced a third type defined by 

D

G(k, ν) = 



F

0 D

−1

 ,

(2.3)

where k ∈ {2, . . . , n}, ν ∈ R and D, F are the n × n matrices D = In + ( F =

1 − 1)(ek−1 eTk−1 + ek eTk ), (1 + ν 2 )1/4

ν (ek−1 eTk + ek eTk−1 ). (1 + ν 2 )1/4

The matrix G(k, ν) is a non-orthogonal symplectic matrix. Such a type was introduced in order to proceed to a SR factorization for at least almost arbitrary matrices, i.e up to a set of measure zero. In the sequel, we present a linear algebra approach, leading us to the correct definition of symplectic Householder transformations. This will serve to construct, in the symplectic case, the analogous of the Euclidean QR factorization via Householder transformations, for at least almost any arbitrary matrix A. In [19], it has been highlighted that there is no need to distinguish between H(k, w) and (J(k, θ). We will see below that the introduction of G(k, ν) is unnecessary for our algorithm.

2.1 Linear algebra approach

We denote J2n (or simply J) the matrix 

 0n

J2n = 



In 

−In 0n

.

(2.4)

The linear space R2n equipped with the indefinite inner product (x, y)J = xJ y

(2.5)

xJ = xT J,

(2.6)

is called symplectic. xJ is defined by

4

and represents the symplectic adjoint of x. The symplectic adjoint of M ∈ R 2n×2k is defined by T M J = J2k M T J2n . (2.7) Definition 2.1 A matrix S ∈ R2n×2k is called symplectic if S J S = I2k .

(2.8)

The symplectic group (multiplicative group of square symplectic matrices) is denoted S. Definition 2.2 T : Rν −→ Rν is a transvection if T satisfies ∃v ∈ Rν , ∀x ∈ Rν , T (x) = x + ϕ(x)v,

(2.9)

where ϕ is a linear form. When a transvection T is orthogonal, its form is given by T = I − 2vv T , where v ∈ Rν , v T v = 1.

(2.10)

In this case, it is commonly called Householder transformation. This leads us to define a symplectic Householder transformation, as a transvection, which is symplectic. We get Lemma 2.3 A transvection T is symplectic iff T is of the form T = I + cvv J where c ∈ R, v ∈ Rν (with ν even).

(2.11)

The vector v is called the direction of T. Proof Since T is symplectic (T isometry with respect to ( , )J ), we have ∀x ∈ R2n , ∀y ∈ R2n (T (x), T (y))J = (x, y)J . Simplifying by xJ y and using v J v = 0, we get ∀x ∈ R2n , ∀y ∈ R2n ϕ(x)v J y = ϕ(y)v J x. Let y0 ∈ R2n such that v J y0 6= 0. One obtains ϕ(x) =

ϕ(y0 ) J v x. Thus, ∃c ∈ R v J y0

such that T = I + cvv J . Reciprocally, I + cvv J is obviously a symplectic transvection.

Property 2.4 The symplectic Householder transformation T = I + cvv J is skewHamiltonian, i.e. T J = T.

5

2.2 Mapping problem Let us denote by T1 (R2n ) the set of symplectic transvections given by (2.11). One notes that the algebraic expressions of orthogonal and symplectic transvections are basically different. Therefore, the mapping problem in the Euclidean case is as follows Theorem 2.5 There exists an orthogonal transvection moving x onto y if kxk 2 = kyk2 . The direction is y − x. For the symplectic case, it takes the form Theorem 2.6 There exists a symplectic transvection moving x onto y if x = y or xJ y 6= 0. The direction is y − x. Moreover, if (xJ y 6= 0), the transvection is given by 1 T = I − J (y − x)(y − x)J . x y Proof The case x = y is trivial. Suppose that x 6= y and set T = I + c(y − x)(y − x)J . Thus, y = T x ⇔ y − x = c(y − x)(y − x)J x = c(y − x)y J x. 1 1 We deduce c = J = − J . y x x y One remarks that the mapping problem in an Euclidean space differ from the symplectic space. The contrast between features of orthogonal and symplectic transvections is more highlighted by Theorem 2.7 Any non null vector x can be moved onto any non null vector y by a product of at the most two symplectic transvections. Proof If x = y or xJ y 6= 0, we get the result from Theorem 2.6. Otherwise, x 6= y 0 and xJ y = 0. We choose z such that z J x 6= 0 and y J z 6= 0. In fact, if < x >⊥ =< 0 0 0 0 y >⊥ then z can be chosen outside of < x >⊥ . If < x >⊥ 6=< y >⊥ , consider 0 0 0 0 u ∈< x >⊥ \ < y >⊥ and w ∈< y >⊥ \ < x >⊥ . Then, for z = u + w we obtain xJ z = xJ w 6= 0 and y J z = y J u 6= 0. From Theorem 2.6, there exists T1 , T2 ∈ T1 (R2n ) such that T1 x = z and T2 z = y. This theorem has no analogue in Euclidean space. We give without proof, the following Theorem 2.8 The symplectic group S is generated by symplectic transvections. Theorem 2.9 Any symplectic transvection T is a rotation, i.e. det(T ) = 1. 6

Proof Set Tc = I + cvv J . From TcJ Tc = I, we get det(Tc ) = ±1. Then, since Tc = (T 2c )2 , we obtain det(Tc ) = 1. The contain of this section, is a translation in matrix language, of results given by Artin in his book [1], in an abstract algebraic language. An updating of similar results in a general scalar product spaces is proposed in [13]. More on algebraic and geometric features of symplectic transvections can be found in [19]. In the sequel, the symplectic transvections will be called symplectic Householder transformations.

3 SR factorization, via symplectic Householder transformations We show here how the analogous of the QR factorization via Householder transformations, can be constructed in the symplectic case. With this aim, we need first some useful properties.

3.1 Properties The orthogonality with respect to the indefinite inner product ( , )J will be denoted by ⊥0 . Lemma 3.1 Let U, V, W be subspaces of R2n such that V = U ⊕ W, with U ⊥0 W.

(3.1)

Let σ1 : U −→ U (respectively σ2 : W −→ W ) a symplectic isometry. The map σ1 ⊥0 σ2 : V −→ V defined by ∀u ∈ U, ∀w ∈ W, σ1 ⊥0 σ2 (u + w) = σ1 (u) + σ2 (w)

(3.2)

is a symplectic isometry. Proof Let u1 , u2 ∈ U and w1 , w2 ∈ W and set v1 = u1 + w1 and v2 = u2 + w2 . Set σ3 = σ1 ⊥0 σ2 . We have σ3 (v1 )J σ3 (v2 ) = σ3 (v1 )T Jσ3 (v2 ) = (σ1 (u1 ) + σ2 (w1 ))T J(σ1 (u2 ) + σ2 (w2 )). From (3.1), we obtain σ1 (u1 )T Jσ2 (w2 ) = σ2 (w1 )T Jσ1 (u2 ) = 0. Thus σ3 (v1 )J σ3 (v2 ) = σ1 (u1 )T Jσ1 (u2 ) + σ2 (w1 )T Jσ2 (w2 ). 7

Since σ1 , σ2 are isometries, we have σ1 (u1 )T Jσ1 (u2 ) = u1 T Ju2 and σ2 (w1 )T Jσ2 (w2 ) = w1 T Jw2 . Then we obtain σ3 (v1 )J σ3 (v2 ) = uT1 Ju2 + w1T Jw2 = (u1 + w1 )T J(u2 + w2 ) = v1J v2 . We highlight here, an important step which will be involved in the algorithm. Let e1 and en+1 be respectively the first and the n + 1th canonical vectors of R2n . Let [a, b] ∈ R2n×2 . Let ρ, µ, ν arbitrary scalars. We seek for a symplectic Householder transformation T1 moving a onto ρe1 , i.e. T1 (a) = ρe1 . The existence of T1 is guaranteed by Theorem 2.6. Thus, if aJ e1 6= 0 (aJ e1 is equal to the n + 1th component of a), then T1 is given by T1 = I −

1 (ρe1 − a)(ρe1 − a)J . aJ ρe1

We seek then for a symplectic Householder transformation T2 which keeps the vector T1 (a) = ρe1 unchanged and moves the new vector T1 (b) onto µe1 + νen+1 , i.e. T2 (e1 ) = e1 and T2 T1 (b) = µe1 + νen+1 . The solution of this problem is not obvious. We proceed by necessary conditions. Since T1 , T2 are symplectic isometries, we get (T2 (T1 (a)), T2 (T1 (b))J = (T1 (a), T1 (b)J = (a, b)J = aJ b and (T2 (T1 (a)), T2 (T1 (b))J = (ρe1 , µe1 + νen+1 )J = ρν. It follows ρν = aJ b.

(3.3)

Thus, we assume that this condition (3.3) is satisfied. Only two parameters are now free. Theorem 2.6 determines completely such transformation. Indeed, T 2 is given by T2 = I −

1 [µe1 + νen+1 − T1 (b)][µe1 + νen+1 − T1 (b)]J . (T1 (b))J (µe1 + νen+1 )

We verify now that such T2 keeps unchanged e1 . Setting v = µe1 + νen+1 − T1 (b), we have v J (ρe1 ) = νeJn+1 ρe1 − [T1 (b)]J ρe1 = −νρ − (T1 (b), T1 (a))J = −νρ − bJ a = −νρ + aJ b = 0. It follows that T2 (e1 ) = e1 . We summarize this in the following 8

Theorem 3.2 Let [a, b] ∈ R2n×2 and ρ, µ, ν be arbitrary scalars satisfying ρν = aJ b. Setting 1 c1 = − J , v1 = ρe1 − a, a ρe1 1 c2 = − , v2 = µe1 + νen+1 − T1 (b) J (T1 (b)) (µe1 + νen+1 ) and T1 = I + c1 v1 v1J , T2 = I + c2 v2 v2J . (3.4) Then T1 (a) = ρe1 , T2 (T1 (a)) = T1 (a), T2 (T1 (b)) = µe1 + νen+1 . (3.5) 3.2 The algorithm We present here the new algorithm for performing the SR factorization via symplectic Householder transformations. A SR factorization is often used for square matrices. However, for some applications, it is needed for non square matrices. We provide here a general version. Let A = [a1 , . . . , ap , ap+1 , . . . , a2p ] ∈ R2n×2p . Let r11 , r1,p+1 , rp+1,p+1 arbitrary scalars satisfying r11 rp+1,p+1 = aJ1 ap+1 . Then • Find a symplectic Householder transformation T1 such that T1 (a1 ) = r11 e1 . • Find a symplectic Householder transformation T2 such that T2 (T1 (a1 )) = T1 (a1 ) and T2 T1 (ap+1 ) = r1,p+1 e1 + rp+1,p+1 en+1 . As explained above, this step involves two free parameters. The action of T 2 T1 on A is as follows 

T2 T1 A =

 r11   0   0  

0

• Next step. Set

r(1, 2 : p) (2) A11

r1,p+1

r(1, p + 2 : 2p)

0

(2) A12

r(p + 1, 2 : p) rp+1,p+1 r(p + 1, p + 2 : (2)

A21

(2)

0



(2)  A11

A˜(2) = 

(2) A21

9

A22

(2) A12 (2) A22



 .



    .  2p)   

Let r22 , r2,p+2 , rp+2,p+2 arbitrary scalars, with A˜(2) (1, :)J A˜(2) (p, :) = r22 rp+2,p+2 . Apply the previous step to A˜(2) i.e. 

• Find T˜3 , T˜4 such that T˜4 T˜3 A˜(2) =

 r22   0   0  

0



 • Set T˜3 = I2n−2 + c3 v˜3 v˜3J , with v˜3 = 

r(2, 3 : p) (3) A11

0

(3) A12

r(p + 2, 3 : p) rp+2,p+2 r(p + 2, p + 3 : (3)

A21



u3  w3



 

 u4  

• Set T˜4 = I2n−2 + c4 v˜4 v˜4J , with v˜4 = 

r(2,p+2) r(2, p + 3 : 2p)

w4

0

(3)

A22



    .  2p)   

∈ R2n−2 , ∈ R2n−2 ,





0       u3 

• Set T3 = I2n + c3 v3 v3 J , with v3 =  

  0     

∈ R2n ,

w3





0       u4 

• Set T4 = I2n + c4 v4 v4 J , with v4 =  

  0     

∈ R2n ,

w4 • T3 , T4 are symplectic Householder transformations and 

r r  11 12 T4 T3 T2 T1 A =

 0    0    0   0  

0

r(1, 3 : p)

r22

r(2, 3 : p)

0

A11

(3)

r1,p+1

r1,p+2

r(1, p + 3 : 2p)

0

r2,p+2

r(2, p + 3 : 2p)

0

0

A12

(3)

rp+1,2 r(p + 1, 3 : p) rp+1,p+1 rp+1,p+2 r(p + 1, p + 3 : 0

r(p + 2, 3 : p) 0

rp+2,p+2 r(p + 2, p + 3 :

0

(3) A21

0

0

(3)

A22

        .  2p)    2p)   

This step needs more explanation. It is based on Lemma 3.1. In fact, consider U =< 0 e1 , en+1 > and V =< e1 , en+1>⊥ . It  is easy to check that V =< e1 , en+1 >⊥ . 

0 x x  For (x, y) ∈ Rn−1×2 , we set T˜   =   . We define T˜˜3 on the linear space V y y0

10









    x ˜ ˜  by T3    0     

= 

0 

y



0     0 x 

 . It is easy to check that T˜ ˜3  0     

= IV +c3 v3 v3J and T3 = IU ⊥0 T˜˜3 .

y0

In a similar way, we get T4 = IU ⊥0 T˜˜4 . • At the last step (pth step)





 R11 R12 

T2p T2p−1 . . . T4 T3 T2 T1 A = 



= R ∈ R2p×2p , with R11 , R12 , R22

R21 R22 upper triangular and R21 upper triangular with null diagonal. R is called J upper triangular. The example p = 3 becomes 



r r r r r r  11 12 13 14 15 16    0 r r 0 r r   25 26  22 23 T6 T5 . . . T 4 T3 T2 T1 A =

  0    0   0  

0

0

r33 0

0

 

r36    

=R

r42 r43 r44 r45 r46    0 r53 0 r55 r56   0

r63 0

0

r66



J • We get A = SR with S = T1J T2J . . . T2p−1 T2p = T1 T2 . . . T2p−1 T2p .

It is important to remark that, unlike to the QR factorization via Householder transformations, this algorithm involves free parameter. Moreover, at each iteration j, three parameters rjj , rj,p+j , rj+p,j+p are involved in T2j−1 , T2j . The following two parameters rjj , rj,p+j or rj,p+j , rj+p,j+p can be chosen freely.

4 SR factorization via optimal symplectic Householder transformations

We give here new results on symplectic Householder transformations. These results are useful for constructing the optimal version of the algorithm.

11

4.1 Symplectic Householder transformation’s condition number Lemma 4.1 Let Tv be the non trivial (α 6= 0) symplectic Householder transformation Tv = I − αvv T J. The 2-norm condition of Tv is given by [cond(Tv )]2 =

2 + α2 kvk42 +

2 + α2 kvk42 −

q

α4 kvk82 + 4α2 kvk42

q

α4 kvk82 + 4α2 kvk42

.

Proof We have TvT Tv = I − αvv T J + αJvv T − α2 kvk2 Jvv T J.

(4.1)

Let L be the linear space defined by L =< v, Jv >⊥ , where ⊥ denotes the Euclidean orthogonality and < v, Jv > the linear space spanned by v, Jv. The linear space R2n can be written as a direct sum R2n = L⊕ < v, Jv > .

(4.2)

Since v ⊥ Jv, we get dim < v, Jv >= 2 and dimL = 2n − 2. Let u ∈ L, then v T Ju = v T u = 0 and thus TvT Tv u = u. It follows that TvT Tv (L) = L (4.3) and 1 is an eigenvalue with multiplicity at least 2n − 2. Let now w ∈< v, Jv > . From (4.1), we get TvT Tv (w) ∈< v, Jv > . We deduce then TvT Tv (< v, Jv >) =< v, Jv > . (4.4) T T Tv Tv admits an eigenvalue δ 6= 1 since Tv Tv 6= I. Let x = u + w (with u ∈ L and w ∈< v, Jv >) an eigenvector associated to δ. We obtain TvT Tv x = TvT Tv u + TvT Tv w = u + TvT Tv w = δu + δw.

(4.5)

Furthermore, from (4.2-4.4) and (1 − δ)u = δw − TvT Tv w, we get u = 0. The eigenvector space associated to δ is then contained in < v, Jv > . Let w = β1 v + β2 Jv 6= 0 an eigenvector associated to an eigenvalue δ 6= 1. We will determine δ. Computing TvT Tv w = (β1 + αβ2 kvk22 )v + (β2 + β1 αkvk22 + β2 α2 kvk42 )Jv, 12

and setting TvT Tv w = δw, we obtain   

β1 + αβ2 kvk22 = δβ1 ,

  β2

(4.6)

+ β1 αkvk22 + β2 α2 kvk42 = δβ2 .

If β1 = 0 then from 4.6, we deduce β2 = 0 and thus w = 0, which is a contradiction. One can assume β1 6= 0 and for simplicity, one can take β1 = 1. The system (4.6) becomes   

  αkvk2

1 + αβ2 kvk22 = δ,

(4.7)

2 4 2 + β2 (1 + α kvk2 ) = δβ2 .

Substituting δ in the second equation, we get αkvk22 β22 − α2 kvk42 β2 − αkvk22 = 0.

(4.8)

The solutions of (4.8) are     (1)    β2    (2)    β2

=

α2 kvk42 +

=

α2 kvk42 −

q

α4 kvk82 + 4α2 kvk42 2

q2αkvk2

α4 kvk82 + 4α2 kvk42

2αkvk22

, (4.9) .

Substituting in the first equation of (4.7), we obtain two eigenvalues of T vT Tv : δ1 = 1 +

α2 kvk42 +

q

α2 kvk42 −

q

α4 kvk82 + 4α2 kvk42 2

,

α4 kvk82 + 4α2 kvk42 . 2 We have δ1 ≥ δ2 . Then the 2-norm condition of Tv is given by δ2 = 1 +

q

2 + α2 kvk42 + α4 kvk82 + 4α2 kvk42 δ1 2 q [cond(Tv )] = = . δ2 2 + α2 kvk42 − α4 kvk82 + 4α2 kvk42 The following Lemma will be used in the sequel Lemma 4.2 Let f be the function defined by √ 2 + γ + 4γ + α2 √ f (γ) = , 2 + γ − 4γ + α2 f is increasing. 13

with γ ≥ 0.

Proof The result is straightforward from f 0 (γ) =

(2 + γ −



8 √ > 0. 4γ + α2 )2 4γ + γ 2

Remark 4.3 [cond(Tv )]2 = f (γ), with γ = α2 kvk42 . 4.2 Optimal free parameters

We come back now to the symplectic Householder transformation T1 = I −

1 aJ ρe

1

(ρe1 − a)(ρe1 − a)J ,

which moves a1 onto ρe1 . The parameter ρ is free. What could be a best choice of such parameter? We recall some facts that will lead us to a positive answer. The symplectic group is not compact. The algorithm is a sequence of products T A, where T is the current symplectic Householder transformation and A the updated matrix A. This product is numerically as stable as T is near to be orthogonal [8]. 0 The transformation T = I + cvv J keeps invariant the hyperplan < v >⊥ . Moreover, 1 is an eigenvalue of geometric multiplicity 2n − 1. Thus T coincides with 0 the identity I over the hyperplan < v >⊥ . The problem is that 1 is of algebraic multiplicity 2n. Thus, T can never be orthogonal (except for the trivial case c = 0). However, T is as near to be orthogonal as its 2-norm condition is near to be 1. Thus, a best choice of the free parameter ρ corresponds for minimizing the 2-norm condition of T1 . Lemma 4.4 The 2-norm condition of T1 is minimum for ρ = ±kak2 . Proof From Lemma 4.1-4.2, the 2-norm condition of T1 is minimum when ρ minimizes 1 g(ρ) = 2 J 2 ka − ρe1 k42 . ρ (a e1 ) We assume here a − ρe1 6= 0 (the non-trivial case). We get −2ka − ρe1 k22 2(a1 − ρ)[ρ2 (aJ e1 )2 ] − ka − ρe1 k42 [2ρ(aJ e1 )2 ] g (ρ) = [ρ2 (aJ e1 )2 ]2 2 J 2 2ka − ρe1 k2 ρ(a e1 ) [−2(a1 − ρ) − ka − ρe1 k22 ] = , [ρ2 (aJ e1 )2 ]2 0

where a1 is the first component of a. Thus, g 0 (ρ = 0) ⇐⇒ −2(a1 − ρ) − ka − ρe1 k22 = 0 ⇐⇒ ρ2 = kak22 ⇐⇒ ρ = ±kak2 . Remark 4.5 If a is close to a multiple of e1 then |ρ| ≈ kak2 and severe cancellation may occur in v1 = ρe1 − a. To avoid this, one usually takes ρ = −sign(a1 )kak2 . 14

However, the small drawback of such choice is that the vector a may be mapped onto −e1 . The other choice ρ = kak2 has the nice property that a is mapped onto a positive multiple of e1 . The risk is that it may give rise to numerical cancellation in ρ2 − a1 (1)2 a1 (2)2 + . . . a1 (2n)2 v1 = ρe1 −a. The formula v1 (1) = ρ − a(1) = = ρ + a1 (1) ρ + a1 (1) suggested by Parlett [15] (for Euclidean Householder transformations) does not suffer from this defect in the case a1 (1) > 0 and may be also applied here. It is now clear how to choose the remaining free parameter µ in the expression of T2 . It may be such the 2-norm conditionqof T2 is minimum. This is satisfied when kµe1 + νe2n−1 k22 = kT1 (b)k22 i.e. µ = ± kT1 (b)k22 − ν 2 . Remark 4.6 In a similar way, to avoid q severe cancellation when computing v 2 ,it T is adequate to take µ = −sign[e1 T1 (b)] kT1 (b)k22 − ν 2 . Parlet’s idea can not be updated here. Hence, the nice property that ν could be chosen positive is lost. We summarize these results in the following Theorem 4.7 Let [a, b] ∈ R2n×2 . The optimal free parameters are given by ρ = −sign(a1 )kak2 , µ =

−sign[eT1 T1 (b)]

q

kT1 (b)k22 − ν 2 and ρν = aJ b.

Setting c1 = − c2 = −

1 aJ ρe

1

, v1 = ρe1 − a,

1 (T1

(b))J (µe

1

+ νen+1 )

, v2 = µe1 + νen+1 − T1 (b),

and T1 = I + c1 v1 v1J , T2 = I + c2 v2 v2J ,

(4.10)

then T1 , T2 have minimal 2-norm condition number and satisfy T1 (a) = ρe1 , T2 (T1 (a)) = T1 (a), T2 (T1 (b)) = µe1 + νen+1 .

(4.11)

We refer to T1 , T2 as optimal symplectic Householder transformations.

4.3 Algorithms

We include here two algorithms (in pseudo MATLAB code) used for performing SR factorization, via the optimal symplectic Householder transformations. The product of a symplectic Householder matrix T = I + cvv J with a given vector a can easily computed without explicitly forming T itself since T a = a + cv(v J a). 15

If follows that, if A ∈ R2n×2p is a matrix, there is no need to form explicitly P for computing the product P A. This product is performed with 4np flops. Writing the product as P A = A + cv(v J A) = A + cv(v T JA) = A + cvw T , (with w = −AT Jv) shows that A is updated by a rank-one matrix. Algorithm 4.1 function [v1 , v2 , c1 , c2 ]=symhouse(a, b) % Compute T1 , T2 such that T2 T1 [a, b] = [ρe1 , µe1 + νen+1 ]. % T1 , T2 are optimal symplectic Householder transformations of Theorem 4.7 % We give here the simplest procedure (break and near breakdown not treated). den = length(a); n = den/2; if a(n + 1) = 0 break; else ρ = −sign(a(1))kak2 ; 1 ; c1 = a(n + 1)ρ v1 = ρe1 − a; % T1 = I + c1 v1 v1J is not formed explicitly. aJ b ; ν= ρ w = T1 (b); q µ = −sign(w(1)) kwk22 − ν 2 ; if (T1 (b))J (µe1 + νen+1 ) = 0 break; else 1 ; c2 = − J (T1 (b)) (µe1 + νen+1 ) v2 = µe1 + νen+1 − T1 (b); % T2 = I + c2 v2 v2J is not formed explicitly. end end

The following algorithm performs the SR factorization via optimal symplectic Householder transformations. Let A ∈ R2n×2p and assume that p ≤ n. Let A([j : m, k : 2n], [j 0 : m0 , k 0 : 2p]) (with j ≤ m ≤ k ≤ 2n, j 0 ≤ m0 ≤ k 0 ≤ 2p) denotes the submatrix obtained from A by deleting all rows except rows j until m and k until 2n and all columns except j 0 until m0 and k 0 until 2p. Algorithm 4.2 function [S, R]= optsrhouse(A) % Computes the factorization A = SR via optimal symplectic Householder trans%formations % R overwrites A. [den, dep]=size(A); 16

n = den/2; p = dep/2; for j = 1 : p [v(:, j), v(:, j + p), c(j), c(j + p)]=symhouse(A([j : n, j + n : den], j), A([j : n, j + n : den], j + p)); %T2j−1 = [I2n−2j+2 + c(j)v(:, j)v(:, j)J ] not formed explicitly. %T2j = [I2n−2j+2 + c(j + p)v(:, j + p)v(:, j + p)J ] not formed explicitly. % The overwriting of A with T2j T2j−1 A. A([j : n, j + n : den], [j : p, j + p : dep]) = T2j T2j−1 A([j : n, j + n : den], [j : p, j + p : dep]); end R = A; J J S = T1J T2J . . . T2p−1 T2p = T1 T2 . . . T2p−1 T2p ; There is more to say about the implementation of the algorithm. Indeed, the storage of the symplectic Householder transformations vectors vj and the corresponding cj , the forward and backward accumulation in the product S = T1 T2 . . . T2p−1 T2p and other related topics will be treated in a forthcoming paper.

5

Numerical experiments

The motivation behind introducing symplectic Householder transformations is to construct an efficient algorithm for computing a SR factorization. The difficulty is that a symplectic transformation is not orthogonal. However, the fact that free parameters are chosen so that that transformations are as near as possible to orthogonal transformations, we expect an acceptable behaviour of the algorithm. We report here some numerical experiments showing the gain furnished by our algorithm (based on Optimal Symplectic Householder transformations (OSH)). The usual way to compute SR factorization is via symplectic Gram-Schmidt algorithm (SGS). Different versions (SGS1, SGS2, SGS3) has been studied in [17]. With these methods, the computed factor S may not satisfy the symplecticity conditions to an acceptable relative accuracy. Their modified versions (MSGS1, MSGS2, MSGS3) improve significantly this relative accuracy [17]. The algorithm MSGS2 is the best one among them. Here, we compare our algorithm (denoted OSH in the figures), with those based on symplectic Gram-Schmidt and their modified versions. The computed factor S by OSH satisfy the symplecticity condition to a good relative accuracy. The interpretation of figures suggests that the algorithm (for computing the factor S) is forward stable. In figure 1, the loss of symplecticity (the symplecticity condition to relative accuracy for the computed factor S) is of order 10 −9 for OSH, while it is of order 10−6 for the best SGS type algorithm. Thus, an improvement by a factor 10−3 is realized by OSH. Remark here that 10−9 is "not so far" from MATLAB precision machine. In figure 2, the loss of symplecticity is of order 10−9 for OSH, while it is of order 10−4 for the best SGS type algorithm. Thus, an improvement by a factor 10−5 is realized by OSH. Remark that we have again 10−9 17

as relative accuracy.

6 Conclusion

This study is concerned with the construction of the analogous, in the symplectic case, of the classical QR factorization via Householder transformations. To this aim, symplectic transvections are revisited [1]. Then, their main features, are highlighted. Some new results are given. We focus then on the possibility to built a QRlike factorization via these symplectic Householder transformations. We show how it is possible to construct such algorithm. Unlike the classical QR factorization via the classical Householder transformations, this algorithm involves free parameters. We demonstrate how to take advantage from this fact. We highlight how an optimal choice of these parameters can be obtained. An optimal SR-factorization algorithm is then derived. The new algorithm is homogeneous (only symplectic Householder transformations are involved) and easy to implement. Some implementation details are reported. The numerical results , as expected, are very satisfactory. We revealed from the numerical experiments that the algorithm seems to be forward stable, for computing the factor S. Numerical aspects (as roundoff properties, storage, implementation’s details,...) will be the aim of a forthcoming paper.

References

[1] E. Artin, Geometric Algebra, Interscience Publishers, New York, 1957. [2] M. Benzi and N. Razouk, On the Iwasawa decomposition of a symplectic matrix, AML: 2209, pp.1-6, 2006. [3] Å. Björck, Numerical Methods For Least Squares Problems, SIAM, (1996). [4]

, Numerics of Gram-Schmidt orthogonalization, Linear Algebra Appl. 197/198 (1994), 297–316.

[5] A. Bunse-Gerstner, An analysis of the HR algorithm for computing the eigenvalues of a matrix, Linear Algebra Appl. 35 (1981), 155–173. [6]

, Matrix factorizations for symplectic QR-like methods, Linear Algebra Appl. 83 (1986), 49–77.

[7] A. Bunse-Gerstner and V. Mehrmann, A symplectic QR-like algorithm for the solution of the real algebraic Riccati equation, IEEE Trans. Automat. Control AC-31 (1986), 1104–1113. [8] J.W. Demmel, Applied Numerical Linear Algebra, SIAM, 1997.

18

[9] J. Della-Dora, Numerical linear algorithms and group theory, Linear Algebra Appl. 10 (1975), 267–283. [10] S.K. Godunov and M. Sadkane, Numerical determination of a canonical form of a symplectic matrix, Siberian Math. J. 42, No. 4 (2001), 629-647. [11] G. Golub and C. Van Loan, Matrix Computations, third ed., The Johns Hopkins U.P., Baltimore, 1996. [12] L. Lopez and V. Simoncini, Preserving geometric properties of the exponential matrix by block Krylov subspace methods, http://www.dm.unibo.it/ simoncin/skew6.pdf, submitted. [13] D.S. Mackey, N. Mackey, and F. Tisseur, G-reflectors: analogues of Householder transformations in scalar product spaces, Linear Algebra Appl. 385 (2004), 187–213. [14] C. Paige and C. Van Loan, A Schur decomposition for Hamiltonian matrices, Linear Algebra Appl. 41 (1981), 11–32. [15] B.N. Parlett, Analysis of Algorithms for Reflections in Bisectors, SIAM Review 13 (1971) 197–208. [16] Y. Saad, Iterative Methods for Sparse Linear Systems, PWS Publishing Co., Boston, 1996. [17] A. Salam, On theoretical and numerical aspects of symplectic Gram-Schmidt-like algorithms, Numer. Algo., 39 (2005), 237-242. [18] A. Salam and A. El Farouk, Round off error analysis of symplectic Gram-Schmidt-like algorithms, submitted. [19] A. Salam and A. Elfarouk and E. Al-Aidarous, Symplectic Householder Transformations for a QR-like decomposition, a Geometric and Algebraic Approaches, submitted. [20] C. Van Loan, A symplectic method for approximating all the eigenvalues of a Hamiltonian matrix, Linear Algebra Appl. 61 (1984), 233–251. [21] J.H. Wilkinson, England.

The Algebraic Eigenvalue Problem, Clarendon Press, Oxford,

19

Figure 1. pascal(12) cond(A)=8.7639e+011

4

10

SGS1 SGS2 SGS3 MSGS1 MSGS2 MSGS3 OSH

2

10

0

10

J

||S S −I||

2

−2

10

−4

10

−6

10

−8

10

−10

10

−1

−0.8

−0.6

−0.4

−0.2

0

0.2

0.4

0.6

0.8

1

free parameter

Figure 2. pascal(14) cond(A)=1.9076e+014

6

10

SGS1 SGS2 SGS3 MSGS1 MSGS2 MSGS3 OSH

4

10

2

10

0

−2

10

J

||S S −I||

2

10

−4

10

−6

10

−8

10

−10

10

−1

−0.8

−0.6

−0.4

−0.2

0

0.2

free parameter

20

0.4

0.6

0.8

1

cond(A)=8.7521e+018 Figure 3. pascal(18)

8

10

SGS1 SGS2 SGS3 MSGS1 MSGS2 MSGS3 OSH

6

10

4

10

2

0

10

J

||S S −I||

2

10

−2

10

−4

10

−6

10

−8

10

−10

10

−1

−0.8

−0.6

−0.4

−0.2

0

0.2

0.4

0.6

0.8

1

free parameter

In figure 3, the loss of symplecticity is of order 10−9 for OSH, while it is completely lost for SGS type algorithms. It is of order 1 for the best of them. Thus, an improvement by a factor 10−9 is realized by OSH. W have again 10−9 as relative accuracy. This (with many other numerical experiments) allow us to conjecture that OSH algorithm is forward stable.

21