140 likes | 262 Views
Matrix Solvers Direct Methods. Phil Bording Memorial University. What makes the matrix structure?. The mathematical formulation!! Finite Elements Finite Differences Boundary Element Methods. I, j+1 i-1,j-1 I,j i+1,j I,j-1.
E N D
Matrix SolversDirect Methods Phil Bording Memorial University
What makes the matrix structure? The mathematical formulation!! Finite Elements Finite Differences Boundary Element Methods
I, j+1 i-1,j-1 I,j i+1,j I,j-1 Penta-Diagonal - FIVE Star Pattern Two Dimensional Problems
I, j+1 i-1,j-1 I,j i+1,j I,j-1 i+1,j-1 Tri – tri Diagonal - Nine Star Pattern Two Dimensional Problems
I, j+1 i-1,j-1 I,j i+1,j I,j-1 i+1,j-1 Add k to index list, I,j,,k Tri – tri – tri Diagonal - 15 Star Pattern Three Dimensional Problems
Boundary Element No diagonals – totally dense matrix
Gaussian Processes Use row operations to make a triangle matrix. Only does right had sides at time of solve Factor Matrix into A = L U ( two triangular matrices) Why do row operations ? – because the simple high school problems were too small
Gaussian Processes How about using matrix multiply? N^3 work with N^2 I/O – Fastest thing we can do on a computer – 2-4 gigaflops on PC 33 gigaflops on Cell Processor Factor Matrix into A = L U ( two triangular matrices) But L = L 0 So we have block matrix operations A L Inside the LU factorization
Open Source Codes • Atlas – uses automatic learning to set matrix block sizes to maximize performance of system cache, etc. • PlaPack – written to make solving large dense systems easy. High speed matrix multipy • Scalapack – sparse matrix solvers • PetSc – family of solvers • And many others – do a web search
Open Source Codes • Mesh generators • 2D triangles • 3D tetrahedral - hex • And many others – do a web search
Programs • First Session Run Gauss.f on system – in your directory Build code for matrix - vector multiplication. • Second Session Modify MXM to do Gaussian elimination