Fast matrix algebra for dense matrices with rank-deficient off-diagonal blocks

Similar documents
A fast randomized algorithm for computing a Hierarchically Semi-Separable representation of a matrix

A direct solver for elliptic PDEs in three dimensions based on hierarchical merging of Poincaré-Steklov operators

A direct solver with O(N) complexity for integral equations on one-dimensional domains

Hierarchical Matrices. Jon Cockayne April 18, 2017

Fast algorithms for hierarchically semiseparable matrices

MULTI-LAYER HIERARCHICAL STRUCTURES AND FACTORIZATIONS

Lecture 2: The Fast Multipole Method

A Fast Direct Solver for a Class of Elliptic Partial Differential Equations

(1) u i = g(x i, x j )q j, i = 1, 2,..., N, where g(x, y) is the interaction potential of electrostatics in the plane. 0 x = y.

A robust inner-outer HSS preconditioner

AMS526: Numerical Analysis I (Numerical Linear Algebra for Computational and Data Sciences)

A sparse multifrontal solver using hierarchically semi-separable frontal matrices

Effective matrix-free preconditioning for the augmented immersed interface method

Conceptual Questions for Review

Course Notes: Week 1

Matrices and Vectors. Definition of Matrix. An MxN matrix A is a two-dimensional array of numbers A =

An H-LU Based Direct Finite Element Solver Accelerated by Nested Dissection for Large-scale Modeling of ICs and Packages

Sparse Linear Systems. Iterative Methods for Sparse Linear Systems. Motivation for Studying Sparse Linear Systems. Partial Differential Equations

Scientific Computing with Case Studies SIAM Press, Lecture Notes for Unit VII Sparse Matrix

Math 671: Tensor Train decomposition methods

In this section again we shall assume that the matrix A is m m, real and symmetric.

Linear Algebra Section 2.6 : LU Decomposition Section 2.7 : Permutations and transposes Wednesday, February 13th Math 301 Week #4

H 2 -matrices with adaptive bases

LU Factorization. LU factorization is the most common way of solving linear systems! Ax = b LUx = b

EE731 Lecture Notes: Matrix Computations for Signal Processing

Incomplete Cholesky preconditioners that exploit the low-rank property

arxiv: v1 [math.na] 5 May 2011

30.3. LU Decomposition. Introduction. Prerequisites. Learning Outcomes

Linear Algebra and Eigenproblems

Bridging the gap between flat and hierarchical low-rank matrix formats: the multilevel BLR format

The antitriangular factorisation of saddle point matrices

arxiv: v1 [cs.na] 20 Jul 2015

CME 302: NUMERICAL LINEAR ALGEBRA FALL 2005/06 LECTURE 6

Numerical Methods I Non-Square and Sparse Linear Systems

A DISTRIBUTED-MEMORY RANDOMIZED STRUCTURED MULTIFRONTAL METHOD FOR SPARSE DIRECT SOLUTIONS

J.I. Aliaga 1 M. Bollhöfer 2 A.F. Martín 1 E.S. Quintana-Ortí 1. March, 2009

AMS 209, Fall 2015 Final Project Type A Numerical Linear Algebra: Gaussian Elimination with Pivoting for Solving Linear Systems

FAST STRUCTURED EIGENSOLVER FOR DISCRETIZED PARTIAL DIFFERENTIAL OPERATORS ON GENERAL MESHES

Next topics: Solving systems of linear equations

Review of matrices. Let m, n IN. A rectangle of numbers written like A =

A DISTRIBUTED-MEMORY RANDOMIZED STRUCTURED MULTIFRONTAL METHOD FOR SPARSE DIRECT SOLUTIONS

Parallel Numerical Algorithms

Sparse factorization using low rank submatrices. Cleve Ashcraft LSTC 2010 MUMPS User Group Meeting April 15-16, 2010 Toulouse, FRANCE

6. Iterative Methods for Linear Systems. The stepwise approach to the solution...

Low Rank Approximation Lecture 3. Daniel Kressner Chair for Numerical Algorithms and HPC Institute of Mathematics, EPFL

Classes of Boolean Functions

A HIGH-ORDER ACCURATE ACCELERATED DIRECT SOLVER FOR ACOUSTIC SCATTERING FROM SURFACES

Math 671: Tensor Train decomposition methods II

AMS526: Numerical Analysis I (Numerical Linear Algebra)

TRANSPORTATION PROBLEMS

Linear System of Equations

MATRIX MULTIPLICATION AND INVERSION

Semidefinite and Second Order Cone Programming Seminar Fall 2001 Lecture 5

Kasetsart University Workshop. Multigrid methods: An introduction

Partial Left-Looking Structured Multifrontal Factorization & Algorithms for Compressed Sensing. Cinna Julie Wu

Lecture 12 (Tue, Mar 5) Gaussian elimination and LU factorization (II)

EFFECTIVE AND ROBUST PRECONDITIONING OF GENERAL SPD MATRICES VIA STRUCTURED INCOMPLETE FACTORIZATION

An Introduction to Hierachical (H ) Rank and TT Rank of Tensors with Examples

Foundations of Matrix Analysis

Fast direct solvers for elliptic PDEs

SPARSE signal representations have gained popularity in recent

GAUSSIAN ELIMINATION AND LU DECOMPOSITION (SUPPLEMENT FOR MA511)

Linear algebra for MATH2601: Theory

Introduction to the Tensor Train Decomposition and Its Applications in Machine Learning

Singular Value Decompsition

TENSOR APPROXIMATION TOOLS FREE OF THE CURSE OF DIMENSIONALITY

ECE133A Applied Numerical Computing Additional Lecture Notes

Improvements for Implicit Linear Equation Solvers

MATRIX ALGEBRA AND SYSTEMS OF EQUATIONS. + + x 1 x 2. x n 8 (4) 3 4 2

Solving linear systems (6 lectures)

arxiv: v1 [cs.lg] 26 Jul 2017

Numerical Solution Techniques in Mechanical and Aerospace Engineering

Key words. numerical linear algebra, direct methods, Cholesky factorization, sparse matrices, mathematical software, matrix updates.

The Fast Multipole Method and other Fast Summation Techniques

This can be accomplished by left matrix multiplication as follows: I

AM 205: lecture 8. Last time: Cholesky factorization, QR factorization Today: how to compute the QR factorization, the Singular Value Decomposition

4 ORTHOGONALITY ORTHOGONALITY OF THE FOUR SUBSPACES 4.1

Chapter 2 Notes, Linear Algebra 5e Lay

Gaussian Elimination and Back Substitution

Singular Value Decomposition

Solving an Elliptic PDE Eigenvalue Problem via Automated Multi-Level Substructuring and Hierarchical Matrices

Santa Claus Schedules Jobs on Unrelated Machines

Applied Mathematics 205. Unit II: Numerical Linear Algebra. Lecturer: Dr. David Knezevic

14.2 QR Factorization with Column Pivoting

A Review of Matrix Analysis

7. LU factorization. factor-solve method. LU factorization. solving Ax = b with A nonsingular. the inverse of a nonsingular matrix

18.06 Professor Johnson Quiz 1 October 3, 2007

Cholesky factorisation of linear systems coming from finite difference approximations of singularly perturbed problems

Numerical Analysis Fall. Gauss Elimination

Introduction, basic but important concepts

On the Skeel condition number, growth factor and pivoting strategies for Gaussian elimination

Notes on Eigenvalues, Singular Values and QR

ANALYTICAL MATHEMATICS FOR APPLICATIONS 2018 LECTURE NOTES 3

Scientific Computing

Chapter 7. Tridiagonal linear systems. Solving tridiagonal systems of equations. and subdiagonal. E.g. a 21 a 22 a A =

A Review of Linear Algebra

CLASSICAL ITERATIVE METHODS

Fast evaluation of boundary integral operators arising from an eddy current problem. MPI MIS Leipzig

Multilevel Preconditioning of Graph-Laplacians: Polynomial Approximation of the Pivot Blocks Inverses

Matrix-Product-States/ Tensor-Trains

Transcription:

CHAPTER 2 Fast matrix algebra for dense matrices with rank-deficient off-diagonal blocks Chapter summary: The chapter describes techniques for rapidly performing algebraic operations on dense matrices whose off diagonal blocks are of low (numerical) rank The primary focus is on matrix inversion, but algorithms for matrix-vector and matrix-matrix multiplication are also described 21 Introduction All direct solvers described in this text make frequent use of matrix operations such as matrixmatrix multiplications, matrix inversions, LU factorizations, etc The matrices that are manipulated are almost all dense, but fortunately, they will be either of small size, or will have internal structure that allows the required operations to be performed rapidly even though the matrices are dense To be precise, the internal structure that is exploited is that off-diagonal blocks of the matrices can be well approximated by matrices of low rank The chapter will illustrate the key ideas by introducing a very simple set of compressible matrices, and then showing how to rapidly perform algebraic operations on such compressible matrices We note that there is in the literature a large amount of literature on structured matrix computations The type of structure we discuss in this text is closely related to the well-established H and H 2 matrices of Hackbusch and co-workers 1, 2, 3, 4 The format we discuss is much simpler than the H-matrix framework This means that it applies to fewer matrices, but it happens to be sufficiently general for our purposes One reason for restricting attention to a simpler format is that it makes the text more accessible, but a much more important reason is that it leads (at least in this case) to faster algorithms The chapter starts by describing a very simple format in Sections 22 and 23 to illustrate the key ideas Then in Sections 24 27, a more sophisticated format that leads to faster algorithms is introduced Note: The more complex format introduced in Sections 24 27 is only needed for the direct solvers for boundary integral equations described in Chapter 7 Sections 24 27 can safely be postponed (or skipped) by a reader interested only in direct solvers for sparse matrices 22 Simply compressible matrices (S-matrices) Roughly speaking, we say that a matrix is simply compressible, or an S-matrix, if it can be tessellated into submatrices in a pattern such as the one illustrated in Figure 21, and each off-diagonal block in the tessellation can be approximated by a low-rank matrix 1

(8,8) (8,9) (4,5) (9,8) (9,9) (2,3) (10,10) (10,11) (5,4) (11,10) (11,11) (12,12) (12,13) (6,7) (13,12) (13,13) (3,2) (14,14) (14,15) (7,6) (15,14) (15,15) Figure 21 Matrix tessellation The diagonal blocks are dense submatrices, while the off-diagonal blocks have rank at most p In order to give a precise definition of the term S-matrix, we let p denote the maximal rank allowed for the off-diagonal blocks, and we then define the compressibility property recursively by saying that a square matrix A is an S-matrix if, upon partitioning it into four pieces of equal size, A = A11 A 12, A 21 A 22 it is the case that A 12 and A 21 have rank at most p, and A 11 and A 22 are compressible An S-matrix of size N N and (and compression rank p) can be stored using O(p N log N) real numbers, and a matrix-vector product involving a compressible matrix can be evaluated using O(p N log N) arithmetic operations, as shown in Algorithm I Remark 21 In practical applications, the off-diagonal blocks will almost never be exactly rankdeficient Instead, it will be the case that they can to high accuracy be approximated by a matrix of low rank To be precise, we say that a matrix B has ε-rank at most p is there exists a matrix C of rank exactly p such that B C ε Technically, this means that the ε-rank of B is the number of singular values of B larger than ε As it happens, the off-diagonal blocks of the matrices under consideration in this text have singular values that decay exponentially fast, so the cut-off parameter ε can often be set to a very small number, say ε = 10 10 This means that in practice, there is very little difference between a matrix of exact rank k, and of ε-rank k Remark 22 For notational simplicity, we assume in this chapter that the ranks of all off-diagonal blocks are the same It is a simple matter to use adaptively tuned ranks when implementing the algorithms 2

Algorithm I: Matrix-vector multiplication for an S-matrix Given a vector q and an S-matrix A, form u = Aq (1) function u = matvec(a,q) (2) if (A is small ) then (3) Evaluate by brute force: u = Aq (4) else A11 A 12 (5) Split A = A 21 A 22 (6) u 1 = matvec(a 11, q 1 ) + A 12q 2 (7) u 2 = matvec(a 22, q 2 ) + A 21q 1 u1 (8) u = u 2 (9) end if (10) end function 23 Inversion of compressible matrices A recursive fast inversion scheme for compressible matrices can easily be derived from the following formula for the inverse of a 2 2 block matrix: 1 A11 A (21) 12 X = 11 X 11 A 12 A 1 22 A 21 A 22 A 1 22 A 21 X 11 A 1 22 + A 1 22 A 21 X 11 A 12 A 1, 22 where X 11 = ( A 11 A 12 A 1 22 A 21) 1 From the formula (21), we immediately get the recursive inversion scheme for compressible matrices shown in Algorithm II The efficiency of the algorithm is a consequence of the fact that the matrices A 12 and A 21 have low rank As a result, the matrix-matrix multiplications that occur on lines (7) and (8) in fact consist simply of a small number of multiplications between compressible matrices and vectors Moreover, the matrix additions in lines (7) and (8) are in fact low-rank updates to compressible matrices The simple algorithm described in Algorithm II has a potentially fatal flaw in that the ranks of the off-diagonal blocks could go from p to 2p in steps (7) and (8) since both of these involve adding a matrix of rank p to the off-diagonal blocks of a compressible matrix Since the function invert matrix is called recursively, this successive doubling of the rank quickly becomes untenable What often saves us is that the matrices can often be re-compressed: every time we have performed an operation that could potentially increase the rank of the off-diagonal blocks, we recompress these blocks before proceeding When the recompression procedure succeeds in keeping the ranks of the off-diagonal blocks from exceeding some fixed number p as the computation proceeds, the computational complexity of the scheme described above is O(p 2 N log 2 N) This is the performance typically observed in the context of direct solvers for elliptic PDEs In order to attain O(N) complexity, we will first roll out the recursive definition of a compressible matrix in Section 24, and then introduce a more sophisticated way of representing the off-diagonal blocks in the tessellation in Section 25 (Recall that the discussion in the remainder of this chapter can be safely skipped for a while, since these techniques will not be used until we reach the Chapter 7 on direct solvers for integral equations) 3

Algorithm II: Inversion of an S-matrix Given an S-matrix A, compute its inverse C in S-matrix format (1) function C = invert matrix(a) (2) if (A is small ) then (3) Invert by brute force: C = A 1 (4) else A11 A 12 (5) Split A = A 21 A 22 (6) X 22 = invert matrix(a 22) (7) X 11 = invert matrix(a 11 A 12 X 22 A 21) (8) C = (9) end if (10) end function X 11 X 11 A 12 X 22 X 22 A 21 X 11 X 22 + X 22 A 21 X 11 A 12 X 22 Note: After any matrix addition, recompression back to rank p should be performed Remark 23 Other matrix operations can be derived in a similar fashion For instance, suppose that we seek to compute an LU-factorization of a compressible matrix, A11 A 12 L11 0 U11 U = 12 A 21 A 22 L 21 L 22 0 U 22 The computation can be done via the following steps: L 11, U 11 = lu structured(a 11 ) L 21 = A 21 U 1 11 (execute via triangular solve on one of the factors of A 21 ) U 12 = L 1 11 A 12 (execute via triangular solve on one of the factors of A 12 ) L 22, U 22 = lu structured(a 22 L 21 U 12 ) Note that since A 12 and A 21 are of rank p, the matrices L 21 and U 12 will automatically be of rank p as well In the last step, recompression down to rank p is essential after forming the sum A 22 L 21 U 12 Next consider the multiplication of two compressible matrices C11 C 12 = C 21 C 22 A11 A 12 B11 B 12 = A 21 A 22 B 21 B 22 A11 B 11 + A 12 B 21 A 11 B 12 + A 12 B 22 A 21 B 11 + A 22 B 21 A 21 B 12 + A 22 B 22 We see that all terms in the product involves at least one factor that is a low-rank matrix, except for the two terms A 11 B 11 and A 22 B 22 Again the pattern repeats itself that the task of performing one operation on a matrix of size N N gets reduced to the task of performing two operations on matrices of size N/2 N/2 24 Hierarchical partitions of the index vector In Section 22, we the definition of an S-matrix was recursive To do away with this (for efficiency), we need to introduce a partition of the index vector I = 1, 2,, N into a binary tree structure For simplicity, we limit attention to binary tree structures in which every level is fully populated We let I form the root of the tree, and give it the index 1, I 1 = I We next split the root into two roughly equi-sized vectors I 2 and I 3 so that I 1 = I 2 I 3 The full tree is then formed by continuing to subdivide any interval that holds more than some preset fixed number n of indices We use the integers l = 0, 1,, L to label the different levels, with 0 denoting the coarsest level A leaf is a node corresponding to a vector that never got split For a non-leaf node τ, its children are the two boxes σ 1 and σ 2 such that I τ = I σ1 I σ2, and τ is then the parent of σ 1 and σ 2 Two boxes with the same parent are called siblings These definitions are illustrated in Figure 22 4

Level 0 1 I 1 = 1, 2,, 400 Level 1 2 3 I 2 = 1, 2,, 200, I 3 = 201, 202,, 400 Level 2 4 5 6 7 I 4 = 1, 2,, 100, I 5 = 101, 102,, 200, Level 3 8 9 10 11 12 13 14 15 I 8 = 1, 2,, 50, I 9 = 51, 52,, 100, Figure 22 Numbering of nodes in a fully populated binary tree with L = 3 levels The root is the original index vector I = I 1 = 1, 2,, 400 We now say that an N N matrix A is an S-matrix of rank p if for every sibling pair {σ, τ} of nodes in the tree the corresponding off-diagonal block of A admits a low-rank factorization (22) A(I τ, I σ ) = X τ Ã τ,σ Y σ, N τ N σ N τ p p p p N σ where N τ and N σ denote the number of elements in I τ and I σ, respectively 25 Nested basis matrices The S-matrix format has the virtue of simplicity, but it is not very efficient It requires O(Np log N) real numbers for storage, the matrix-vector product has complexity O(N p log N), and higher level operations such as matrix inversion or the matrix-matrix product involve higher powers of the log N factor We will next develop a more efficient format that eliminates these log N factors Our first step in this direction is to develop a more efficient way of storing the basis matrices (we must clearly get storage from O(N log N) down to O(N) if there is to be any hope for O(N) arithmetic!) The general idea is to express the basis matrices for the off-diagonal blocks hierarchically In other words, we will express the basis vectors used at one level in terms of the basis vectors used at the next finer level Using the matrix illustrated in Figure 21 as an example, a basis for the column space of the block labelled (4, 5) is constructed from the bases for the column spaces of the blocks (8, 9) and (9, 8) To formalize this notion, let τ be a node in the tree with sibling σ, and children β 1 and β 2 Then we require that the basis matrix X τ that spans the column space of A(I τ, I σ ) can be expressed in terms of the corresponding basis matrices X β1 and X β2 associated with its children, Xβ1 0 X (23) τ = 0 X β2 U τ N τ k N τ 2k 2k k Observe that when (23) holds, the matrix X τ (which is potentially very tall) need not be stored it can when needed be constructed from X β1 and X β2 using the information in the small matrix U τ The process can then be continued down the tree to eliminate the need for storing the matrices X β1 and X β2 Let ν 1 and ν 2 denote the children of β 1 and let ν 3 and ν 4 be the children of β 2 Then we impose conditions, cf (23), (24) X β1 = Xν1 0 U 0 X β1 and X β2 = ν2 5 Xν3 0 0 X ν4 U β2

Combining (23) and (24) we then find X τ = X ν1 0 0 0 0 X ν2 0 0 0 0 X ν3 0 0 0 0 X ν4 Uβ1 0 0 U β2 U τ N τ k N τ 4k 4k 2k 2k k This process can be continued all the way down to the leaves The end result is that we only need to store the full basis matrices for the leaf nodes (which is fine since these are small), and the small matrices U τ for all parent nodes Of course, we also assume that the basis matrices {Y τ } τ T for the row spaces satisfy an analogous hierarchical property In other words, for any parent node τ with children β 1 and β 2, we require that there exist a 2k k matrix V τ such that Yβ1 0 Y (25) τ = V 0 Y τ β2 N τ k N τ 2k 2k k Remark 24 It is in practice a simple matter to construct basis matrices that satisfy (23) and (25) What we need to do is to make sure that for every leaf τ, the columns of the basis matrix X τ span the column space of A(I τ, I c τ ) where I c τ is the complement of I τ within the vector I Analogously, the columns of Y τ must span the row space of A(I c τ, I τ ) Note that these are quite strict requirements since A(I τ, I c τ ) is a much larger matrix than the matrix A(I τ, I σ ) in (22) (since I σ is a (potentially very small) subset of I c τ ) Note also that while conceptually simple, the factorizations of matrices like A(I τ, I c τ ) would be very expensive is performed by brute force In the direct solvers described in this text, there are usually short-cuts that make these computations very inexpensive, see, eg, Sections 783 and 85 26 The hierarchically block separable (HBS) sparse matrix format We are now prepared to rigorously define what it means for an N N matrix A to be hierarchically block seperable (HBS) with respect to a given binary tree T that partitions the index vector I = 1, 2,, N For simplicity, we suppose that the tree has L fully populated levels, and that for every leaf node τ, the index vector I τ holds precisely n points, so that N = n 2 L Then A is HBS with block rank k if the following two conditions hold: (1) Assumption on ranks of off-diagonal blocks at the finest level: For any two distinct leaf nodes τ and τ, define the n n matrix (26) A τ,τ = A(I τ, I τ ) Then there must exist matrices U τ, V τ, and Ãτ,τ (27) such that A τ,τ = U τ Ã τ,τ V τ n n n k k k k n (2) Assumption on ranks of off-diagonal blocks on level l = L 1, L 2,, 1: The rank assumption at level l is defined in terms of the blocks constructed on the next finer level l + 1: For any distinct nodes τ and τ on level l with children σ 1, σ 2 and σ 1, σ 2, respectively, define (28) A τ,τ = Ãσ1,σ 1 Ã σ2,σ 1 6 Ã σ1,σ 2 Ã σ2,σ 2

Name: Size: Function: For each leaf D τ n n The diagonal block A(I τ, I τ ) node τ: U τ n k Basis for the columns in the blocks in row τ V τ n k Basis for the rows in the blocks in column τ For each parent B τ 2k 2k Interactions between the children of τ node τ: U τ 2k k Basis for the columns in the (reduced) blocks in row τ V τ 2k k Basis for the rows in the (reduced) blocks in column τ Figure 23 An HBS matrix A associated with a tree T is fully specified if the factors listed above are provided Then there must exist matrices U τ, V τ, and Ãτ,τ (29) such that A τ,τ = U τ Ã τ,τ V τ 2k 2k 2k k k k k 2k The two points above complete the definition An HBS matrix is now fully described if the basis matrices U τ and V τ are provided for each node τ, and in addition, we are for each leaf τ given the n n matrix (210) D τ = A(I τ, I τ ), and for each parent node τ with children σ 1 and σ 2 we are given the 2k 2k matrix 0 Ã (211) B τ = σ1,σ 2 Ã σ2,σ 1 0 Observe in particular that the matrices Ãσ 1,σ 2 are only required when {σ 1, σ 2 } forms a sibling pair Figure 23 summarizes the required matrices, and Algorithm III shows how to evaluate the product x Ax using these factors Remark 25 The definition of the HBS property given in this section is flexible in the sense that we do not enforce any conditions on the factors U τ, V τ, and Ãτ,τ other than that (27) and (29) must hold For purposes of numerical stability, further conditions are sometimes imposed The perhaps strongest such condition is to require the matrices U τ and V τ in (27) and (29) be orthonormal, see eg 5 (one can in this case require that the matrices Ãτ,τ be diagonal, so that (27) and (29) become singular value decompositions) A choice that we have found highly convenient is to require (27) and (29) to be so called interpolatory decompositions (see Section 722) Then every U τ and V τ contains a k k identity matrix (which greatly accelerates computations), and each Ãτ,τ is a submatrix of the original matrix A 27 Inversion of an HBS matrix An important advantage of the HBS matrix format is that it allows a very easy and fast inversion algorithm It is given here as Algorithm IV; it takes as input the matrices {D τ, B τ, U τ, V τ } τ T in an HBS representation of a matrix A and provides as output corresponding factors {G τ, E τ, F τ } τ T in a representation of A 1 Once these factors are available, the product x A 1 x can be constructed via Algorithm V The derivation of the factorization algorithm is given in Chapter 7, here we merely list the inversion algorithm to highlight the fact that the HBS format is not only faster than the S-matrix format, 7

Algorithm III (HBS matrix-vector multiply) Given a vector q and a matrix A in HBS format, compute u = A q loop over all leaf boxes τ ˆq τ = V τ q(i τ ) loop over levels, finer to coarser, l = L 1, L 2,, 1 loop over all parent boxes τ on level l, Let σ 1 and σ 2 denote the children of τ ˆq τ = V ˆqσ1 τ ˆq σ2 û 1 = 0 loop over all levels, coarser to finer, l = 1, 2,, L 1 loop over all parent boxes τ on level l Let σ 1 and σ 2 denote the children of τ ûσ1 ˆqσ1 û σ2 = U τ û τ + loop over all leaf boxes τ u(i τ ) = U τ û τ + D τ q(i τ ) 0 B σ1,σ 2 B σ2,σ 1 0 ˆq σ2 Algorithm IV (inversion of an HBS matrix) loop over all levels, finer to coarser, l = L, L 1,, 1 loop over all boxes τ on level l, if τ is a leaf node D τ = D τ else Let σ 1 and σ 2 denote the children of τ ˆD σ1 B σ1,σ D τ = 2 B σ2,σ 1 ˆDσ2 end if ˆD τ = ( V 1 ) 1 τ D τ U τ 1 E τ = D τ U τ ˆDτ F τ = ˆD τ V τ G τ = ˆD τ 1 D τ 1 D τ U τ ˆDτ V τ D 1 τ ˆD2 B 2,3 G 1 = ˆD3 B 3,2 1 but is also in fact easier to use Observe that since the inversion is exact, there is no need for re-compression in Algorithm III In practice, the off-diagonal blocks of a matrix A that we seek to invert are not exactly of rank p, but can to some finite precision be approximated by low-rank matrices Suppose that these errors 8

Algorithm V (application of inverse) Given a vector u, compute q = A 1 u using the compressed representation of A 1 resulting from Algorithm? loop over all leaf boxes τ û τ = F τ u(i τ ) loop over all levels, finer to coarser, l = L, L 1,, 1 loop over all parent boxes τ on level l, Let σ 1 and σ 2 denote the children of τ û τ = F ûσ1 τ ˆq2 û2 = ˆq Ĝ1 3 û 3 û σ2 loop over all levels, coarser to finer, l = 1, 2,, L 1 loop over all parent boxes τ on level l Let σ 1 and σ 2 denote the children of τ ˆqσ1 ˆq σ2 = E τ û τ + G τ ûσ1 û σ2 loop over all leaf boxes τ q(i τ ) = E τ ˆq τ + G τ u(i τ ) are apportioned among the blocks in such a way that the HBS approximant A ε satisfies A A ε ε Then Algorithm IV computes an exact inverse A 1 ε We find that In consequence, A 1 A 1 ε A 1 A 1 ε A 1 = A 1( A ε A ) A 1 ε We see that the error is magnified by a factor of A 1 ε can easily be estimated via a power iteration on ( A 1 its modified version for application of ( A 1 ε A 1 ε A ε A A 1 ε ε ) ) ε, )( which ) is quite natural Note that A 1 ε A 1 ε executed using Algorithm V (and To be slightly more careful, let us next take into account rounding errors incurred when Algorithm IV is executed in floating point arithmetic It would be hard to construct an à priori estimate of these errors, but that is not necessary In practice, we rely instead on an à posteriori estimate as follows: Suppose that we seek to solve the equation Ax = f We approximate A by an HBS matrix A ε and then invert this matrix (in floating point arithmetic) to construct the approximate inverse B Finally, we form the approximate solution via x approx = Bf 9

Then x approx x = Bf x = BAx x BA I x The relative error is therefore bounded by BA I In any situation where we can evaluate the product x Ax to very high accuracy (significantly smaller than ε, in other words), it is then an easy matter to estimate BA I via a power iteration on ( BA I )( BA I ) 10

Bibliography 1 Mario Bebendorf, Hierarchical matrices, Lecture Notes in Computational Science and Engineering, vol 63, Springer-Verlag, Berlin, 2008, A means to efficiently solve elliptic boundary value problems MR 2451321 (2009k:15001) 2 Steffen Börm, Efficient numerical methods for non-local operators, EMS Tracts in Mathematics, vol 14, European Mathematical Society (EMS), Zürich, 2010, H 2 -matrix compression, algorithms and analysis MR 2767920 3 Lars Grasedyck and Wolfgang Hackbusch, Construction and arithmetics of H-matrices, Computing 70 (2003), no 4, 295 334 4 Wolfgang Hackbusch, A sparse matrix arithmetic based on H-matrices; Part I: Introduction to H-matrices, Computing 62 (1999), 89 108 5 Zhifeng Sheng, Patrick Dewilde, and Shivkumar Chandrasekaran, Algorithms to solve hierarchically semiseparable systems, System theory, the Schur algorithm and multidimensional analysis, Oper Theory Adv Appl, vol 176, Birkhäuser, Basel, 2007, pp 255 294 MR MR2342902 11