approximating eigenpairs in quantum chemistry · 2001-11-16 · 11/15/01 1 approximating eigenpairs...

42
11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer Science, University of Tennessee Richard P. Muller Materials and Process Simulation Center, Beckman Institute, California Institute of Technology

Upload: others

Post on 13-Apr-2020

2 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 1

Approximating Eigenpairs inQuantum Chemistry

Robert C. Ward,Wilfried Gansterer

Department of Computer Science,University of Tennessee

Richard P. MullerMaterials and Process Simulation Center,

Beckman Institute,California Institute of Technology

Page 2: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 2

• Supported by DOE ASCI/ASAP

Page 3: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 3

Outline

• Introduction, problem statement• Framework: Approximation levels• D&C (tridiagonal/block-tridiagonal)• Analysis and experimental results• Summary and outlook

Page 4: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 4

Introduction

Page 5: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 5

Central Problem I

• Given: Symmetric matrix ,preferably “diagonally heavy”

n nA ×∈ R

Page 6: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 6

Central Problem II

• Given: Symmetric matrix(preferably “diagonally heavy”),tolerance parameter

• Wanted: Approximate spectraldecomposition , s.t.

and

- Essentially the full spectrum required

ˆ ˆ ˆ|| ||TA V V τ− Λ ≤

ˆ ˆ ˆ TA V V≈ Λ

machˆ ˆ|| ||TV V I ε− ≤

n nA ×∈ R

τ

Page 7: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 7

Application:Quantum Chemistry

• Quantum-mechanical equations formany-electron systems (non-relativistictime-independent Schroedinger Equation)

• Restricted Closed-Shell Hartree-FockApproximation

• Linearization: expand unknown molecularorbitals into finite series of basis functions

Page 8: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 8

Application:Quantum Chemistry

• Construct the Fock matrix Fand the Overlap matrix S fi

• Roothaan Equations (nonlineareigenvalue problem): F(C) C = S C E

• Self-consistent-field (SCF) procedure fisequence of (generalized) lineareigenproblems

Page 9: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 9

Application:Quantum Chemistry

• Objective:- Develop efficient approximate linear

eigensolver for use in SCF procedure

• Desirable properties (“wish list”):- Variable accuracy parameter- Efficiency- Parallelization

Page 10: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 10

Approximation Levels

Page 11: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 11

3 Levels of Approximation• Approximate A by a symmetric block-

tridiagonal matrix B.

(thresholding, reordering, bandwidthreduction,...)

Page 12: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 12

Original Matrix

Page 13: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 13

Block-TridiagonalApproximation B

Page 14: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 14

QC Linear Alkane:alkane80

Page 15: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 15

Approximation Error I

• Error caused by thresholding andreordering can be bounded

where …eigenvalues of A …eigenvalues of B …thresholding tolerance

1| |i i nα β τ− ≤

iαiβ

Page 16: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 16

3 Levels of Approximation• Approximate A by a symmetric block-

tridiagonal matrix B.• Approximate the off-diagonal blocks of B

by low(er) rank matrices ( B’).

(SVD-based rank-ri approximations)

Page 17: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 17

Block-TridiagonalApproximation B

Page 18: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 18

Rank-1 Approximation ofOff-Diagonal Blocks

Page 19: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 19

Relative Errors in2nd Iteration Energy

Page 20: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 20

Approximation Error II

• Error caused by rank approximation ofoff-diagonal blocks can be bounded as

where …eigenvalues of B …eigenvalues of B’ (approximated blocks) …j-th singular value of the k-th subdiagonal block

1,2,..., 11

| | 2 maxk

k

mk

i i jk pj r

nβ λ σ= −

= +

− ≤ ∑iβiλkjσ

Page 21: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 21

3 Levels of Approximation• Approximate A by a symmetric block-

tridiagonal matrix B.• Approximate the off-diagonal blocks of B

by low(er) rank matrices ( B’).• Apply (approximative) block divide-and-

conquer algorithm to B’.

(relaxed deflation,…)

Page 22: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 22

Divide-and-Conquer forTridiagonalTridiagonal Problems

[Golub (1973); Bunch et al. (1978); Cuppen(1981); Dongarra & Sorensen (1987); Gu &Eisenstat (1994/1995); Tisseur & Dongarra(1999);...]

Page 23: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 23

Divide-and-Conquer

Split

Transform - Solve - Back-TransformTransform - Solve - Back-Transform

.

.

.Transform - Solve - Back-Transform

Synthesize

Page 24: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 24

TridiagonalDivide-and-Conquer

• Central task:Eigenvalues and -vectors of arank-one modification problem

with a diagonal matrix D

TD xx+

Page 25: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 25

Deflation

• Zero component fi correspondingeigenpair is known explicitly

• Multiple entry fi correspondingeigenpairs can be computed cheaply

• Problem size can be reduced (deflated)• Cost for eigenvector update is reduced

(block structured eigenvector matrix)

id

0ix =

TD xx+

Page 26: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 26

Tridiagonal D&C

• Accumulation (multiplication) ofeigenvector matrices

• Theoretical arithmetic complexity:

• In practice often lower due to deflation• One of the fastest algorithms available

3 243 ( ) flopsc n O n+

Page 27: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 27

(Approximative)Divide-and-Conquer for

Block-Tridiagonal Matrices

Page 28: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 28

Block-Tridiagonal D&C

• Subdivision (p blocks):- SVDs (off-diagonal)- Corrections and

eigendecompositions(diagonal blocks)

• Synthesis:- ri rank-one modifications

per off-diagonal block- Best merging order:

lowest rank last1

, 1,2,..., 1ir

Ti i ii j j j

j

E u v i pσ=

= = −∑

Page 29: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 29

Relaxed Deflation

• Standard deflation tolerance (LAPACK):

• Relaxed deflation tolerance- Absolute eigenvalue error proportional to- Allows for (potentially) much more deflation- Significant computational savings- Very attractive if medium/low accuracy is

sufficient

':L c Bτ ε=

2 Lτ τ<2τ

Page 30: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 30

Deflation-Experiments I

• 3 test matrices with prescribed eigenvaluedistributions:- “clustered”: clustered around 0- “random”: random between -1 and 1- “uniform”: uniform between -1 and 1

• Additionally, “block random” matrix:- random diagonal blocks, off-diagonal blocks

from random singular vectors

Page 31: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 31

Deflation-Experiments II

Page 32: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 32

Deflation-Experiments III

Page 33: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 33

Runtimes --Comparison with LAPACK

• “block random”: n=3000, p=300 (10x10),eigenvectors accumulated, times in [s]

498.8229.417.510-6

1551.41529.71501.7dsbevd64.134.811.010-2

1429.6582.623.1 10-10

2344.6942.630.2ri=10ri=5ri=1

LAPACK tolerance

Page 34: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 34

Runtimes --Comparison with LAPACK

Page 35: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 35

QC: SCF ProcedureCompute SDetermine U s.t. U*SU = IGuess C0

Do i = 0, 1, 2, …Compute F(Ci)Compute F’i = U*F(Ci)USolve F’iC’(i+1) = C’(i+1)E(i+1)

Compute C(i+1) = UC’(i+1)

Check for convergence

Page 36: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 36

Runtimes --Full SCF Procedure

Page 37: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 37

Experimental Analysis

• Efficient- due to good data locality (maps well onto

modern memory hierarchies)- due to deflation

• Orders of magnitude faster than LAPACKif low accuracy requirements allow for- Low rank approximations- Large deflation tolerances

Page 38: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 38

Summary and Outlook

Page 39: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 39

Documentation

• Eigenvectors via accumulation

- Rank-one off-diagonal approximations:“An Extension of the Divide-and-Conquer Method for a Class ofSymmetric Block-Tridiagonal Eigenproblems”, Gansterer, Ward,Muller, 2000. (submitted, also TR UT-CS-00-447)

- Arbitrary rank off-diagonal approximations:“Computing Approximate Eigenpairs of Symmetric BlockTridiagonal Matrices”, Gansterer, Ward, Muller, 2001.(submitted, also TR UT-CS-01-463)

Page 40: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 40

Work in Progress/Future Work

• Alternative eigenvector computation- URV decomposition + postprocessing- Higher rank modifications, FMM- Newton-type approach

[Dongarra, Moler, Wilkinson (1983)]

• Higher accuracy- Better block-tridiagonal/banded

approximation

• Parallelization

Page 41: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 41

Future Work

• Application to QC Problems (CalTech)- Utilize information from previous SCF-cycle- “Localization”- Alternative eigensolvers (Krylov-subspace

methods, Jacobi-Davidson,… ?)- Methods for nonlinear eigenproblems

• Use the framework as a preconditioner

Page 42: Approximating Eigenpairs in Quantum Chemistry · 2001-11-16 · 11/15/01 1 Approximating Eigenpairs in Quantum Chemistry Robert C. Ward, Wilfried Gansterer Department of Computer

11/15/01 42

More Information

http://www.cs.utk.edu/~cape/