cs240a-cgstencil

# cs240a-cgstencil - Model Problem: Solving Poissons equation...

This preview shows pages 1–7. Sign up to view the full content.

Model Problem: Solving Poisson’s equation for temperature Model Problem: Solving Poisson’s equation for temperature k = n 1/3 For each i from 1 to n, except on the boundaries: – x(i-k 2 ) – x(i-k) – x(i-1) + 6*x(i) – x(i+1) – x(i+k) – x(i+k 2 ) = 0 n equations in n unknowns: A*x = b Each row of A has at most 7 nonzeros

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
The Landscape of Ax=b Solvers The Landscape of Ax=b Solvers Pivoting LU GMRES, BiCGSTAB, Cholesky Conjugate gradient Direct A = LU Iterative y’ = Ay Non- symmetric Symmetric positive definite More Robust Less Storage (if sparse) More Robust More General
Complexity of linear solvers Complexity of linear solvers 2D 3D Sparse Cholesky: O(n 1.5 ) O(n 2 ) CG, exact arithmetic: O(n 2 ) O(n 2 ) CG, no precond: O(n 1.5 ) O(n 1.33 ) CG, modified IC: O(n 1.25 ) O(n 1.17 ) CG, support trees: O(n 1.20 ) -> O(n 1+ ) O(n 1.75 ) -> O(n 1+ ) n 1/2 n 1/3 Time to solve model problem (Poisson’s equation) on regular mesh

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
CS 240A: Solving Ax = b in parallel CS 240A: Solving Ax = b in parallel Dense A: Gaussian elimination with partial pivoting (LU) See Jim Demmel’s slides Same flavor as matrix * matrix, but more complicated Sparse A: Iterative methods – Conjugate gradient, etc. Sparse matrix times dense vector Sparse A: Gaussian elimination – Cholesky, LU, etc. Graph algorithms Sparse A: Preconditioned iterative methods and multigrid Mixture of lots of things
CS 240A: Solving Ax = b in parallel CS 240A: Solving Ax = b in parallel Dense A: Gaussian elimination with partial pivoting See Jim Demmel’s slides Same flavor as matrix * matrix, but more complicated Sparse A: Iterative methods – Conjugate gradient etc. Sparse matrix times dense vector Sparse A: Gaussian elimination – Cholesky, LU, etc. Graph algorithms Sparse A: Preconditioned iterative methods and multigrid Mixture of lots of things

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Conjugate gradient iteration for Ax = b x 0 = 0 approx solution r 0 = b residual = b - Ax d 0 = r 0 search direction for k = 1, 2, 3, . . . x
This is the end of the preview. Sign up to access the rest of the document.

## This note was uploaded on 12/27/2011 for the course CMPSC 240A taught by Professor Gilbert during the Fall '09 term at UCSB.

### Page1 / 25

cs240a-cgstencil - Model Problem: Solving Poissons equation...

This preview shows document pages 1 - 7. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online