15 Nov. 200015-859B - Introduction to Scientific Computing1 Multigrid Methods and Applications Paul Heckbert Computer Science Department Carnegie Mellon.

Slides:



Advertisements
Similar presentations
School of something FACULTY OF OTHER School of Computing An Adaptive Numerical Method for Multi- Scale Problems Arising in Phase-field Modelling Peter.
Advertisements

05/11/2005 Carnegie Mellon School of Computer Science Aladdin Lamps 05 Combinatorial and algebraic tools for multigrid Yiannis Koutis Computer Science.
1 Numerical Solvers for BVPs By Dong Xu State Key Lab of CAD&CG, ZJU.
CS 290H 7 November Introduction to multigrid methods
MULTISCALE COMPUTATIONAL METHODS Achi Brandt The Weizmann Institute of Science UCLA
Geometric (Classical) MultiGrid. Hierarchy of graphs Apply grids in all scales: 2x2, 4x4, …, n 1/2 xn 1/2 Coarsening Interpolate and relax Solve the large.
Fast Iterative Alignment of Pose Graphs with Poor Initial Estimates Edwin Olson John Leonard, Seth Teller
Parallelizing stencil computations Based on slides from David Culler, Jim Demmel, Bob Lucas, Horst Simon, Kathy Yelick, et al., UCB CS267.
An Introduction to Multiscale Modeling Scientific Computing and Numerical Analysis Seminar CAAM 699.
Introduction to numerical simulation of fluid flows
A Bezier Based Approach to Unstructured Moving Meshes ALADDIN and Sangria Gary Miller David Cardoze Todd Phillips Noel Walkington Mark Olah Miklos Bergou.
Graph problems Partition: min cut Clustering bioinformatics Image segmentation VLSI placement Routing Linear arrangement: bandwidth, cutwidth Graph drawing.
MA5233: Computational Mathematics
Copyright © 2002J. E. Akin Rice University, MEMS Dept. CAD and Finite Element Analysis Most ME CAD applications require a FEA in one or more areas: –Stress.
Avoiding Communication in Sparse Iterative Solvers Erin Carson Nick Knight CS294, Fall 2011.
Network and Grid Computing –Modeling, Algorithms, and Software Mo Mu Joint work with Xiao Hong Zhu, Falcon Siu.
High Performance Computing 1 Parallelization Strategies and Load Balancing Some material borrowed from lectures of J. Demmel, UC Berkeley.
1/36 Gridless Method for Solving Moving Boundary Problems Wang Hong Department of Mathematical Information Technology University of Jyväskyklä
CS240A: Conjugate Gradients and the Model Problem.
Multiscale Methods of Data Assimilation Achi Brandt The Weizmann Institute of Science UCLA INRODUCTION EXAMPLE FOR INVERSE PROBLEMS.
CS267 L24 Solving PDEs.1 Demmel Sp 1999 CS 267 Applications of Parallel Computers Lecture 24: Solving Linear Systems arising from PDEs - I James Demmel.
Monica Garika Chandana Guduru. METHODS TO SOLVE LINEAR SYSTEMS Direct methods Gaussian elimination method LU method for factorization Simplex method of.
Chapter 13 Finite Difference Methods: Outline Solving ordinary and partial differential equations Finite difference methods (FDM) vs Finite Element Methods.
MULTISCALE COMPUTATIONAL METHODS Achi Brandt The Weizmann Institute of Science UCLA
Module on Computational Astrophysics Jim Stone Department of Astrophysical Sciences 125 Peyton Hall : ph :
Numerical methods for PDEs PDEs are mathematical models for –Physical Phenomena Heat transfer Wave motion.
© 2011 Autodesk Freely licensed for use by educational institutions. Reuse and changes require a note indicating that content has been modified from the.
1 CFD Analysis Process. 2 1.Formulate the Flow Problem 2.Model the Geometry 3.Model the Flow (Computational) Domain 4.Generate the Grid 5.Specify the.
Applications of Calculus. The logarithmic spiral of the Nautilus shell is a classical image used to depict the growth and change related to calculus.
Conjugate gradients, sparse matrix-vector multiplication, graphs, and meshes Thanks to Aydin Buluc, Umit Catalyurek, Alan Edelman, and Kathy Yelick for.
1 Numerical Integration of Partial Differential Equations (PDEs)
Grid Generation.
MAE 3241: AERODYNAMICS AND FLIGHT MECHANICS Compressible Flow Over Airfoils: Linearized Subsonic Flow Mechanical and Aerospace Engineering Department Florida.
MA5251: Spectral Methods & Applications
Fig.6 Next Generation Airplane ( ■ Design of Next Generation Airplanes - Lightweight airframe - High aspect ratio.
02/18/05© 2005 University of Wisconsin Last Time Radiosity –Converting the LTE into the radiosity equation –Solving with Gauss-Seidel relaxation –Form.
Introduction to Scientific Computing II From Gaussian Elimination to Multigrid – A Recapitulation Dr. Miriam Mehl.
ParCFD Parallel computation of pollutant dispersion in industrial sites Julien Montagnier Marc Buffat David Guibert.
CFD Lab - Department of Engineering - University of Liverpool Ken Badcock & Mark Woodgate Department of Engineering University of Liverpool Liverpool L69.
The swiss-carpet preconditioner: a simple parallel preconditioner of Dirichlet-Neumann type A. Quarteroni (Lausanne and Milan) M. Sala (Lausanne) A. Valli.
CFD Refinement By: Brian Cowley. Overview 1.Background on CFD 2.How it works 3.CFD research group on campus for which problem exists o Our current techniques.
Interactive Computational Sciences Laboratory Clarence O. E. Burg Assistant Professor of Mathematics University of Central Arkansas Science Museum of Minnesota.
Multigrid Computation for Variational Image Segmentation Problems: Multigrid approach  Rosa Maria Spitaleri Istituto per le Applicazioni del Calcolo-CNR.
Parallel Solution of the Poisson Problem Using MPI
CS240A: Conjugate Gradients and the Model Problem.
Domain Decomposition in High-Level Parallelizaton of PDE codes Xing Cai University of Oslo.
Introduction to Scientific Computing II Overview Michael Bader.
Introduction to Scientific Computing II
Discretization Methods Chapter 2. Training Manual May 15, 2001 Inventory # Discretization Methods Topics Equations and The Goal Brief overview.
Discretization for PDEs Chunfang Chen,Danny Thorne Adam Zornes, Deng Li CS 521 Feb., 9,2006.
MULTISCALE COMPUTATIONAL METHODS Achi Brandt The Weizmann Institute of Science UCLA
A Non-iterative Hyperbolic, First-order Conservation Law Approach to Divergence-free Solutions to Maxwell’s Equations Richard J. Thompson 1 and Trevor.
Smoothed Particle Hydrodynamics Matthew Zhu CSCI 5551 — Fall 2015.
1 Data Structures for Scientific Computing Orion Sky Lawlor /04/14.
9 Nov B - Introduction to Scientific Computing1 Sparse Systems and Iterative Methods Paul Heckbert Computer Science Department Carnegie Mellon.
CAD and Finite Element Analysis Most ME CAD applications require a FEA in one or more areas: –Stress Analysis –Thermal Analysis –Structural Dynamics –Computational.
A Parallel Hierarchical Solver for the Poisson Equation Seung Lee Deparment of Mechanical Engineering
Adaptive grid refinement. Adaptivity in Diffpack Error estimatorError estimator Adaptive refinementAdaptive refinement A hierarchy of unstructured gridsA.
Multipole-Based Preconditioners for Sparse Linear Systems. Ananth Grama Purdue University. Supported by the National Science Foundation.
1 Aerodynamic theories. 2 DLM Reference AIAA Journal, Vol. 7, No. 2, February 1969, pp
1 LES of Turbulent Flows: Lecture 7 (ME EN ) Prof. Rob Stoll Department of Mechanical Engineering University of Utah Spring 2011.
Conjugate gradient iteration One matrix-vector multiplication per iteration Two vector dot products per iteration Four n-vectors of working storage x 0.
Xing Cai University of Oslo
Introduction to the Finite Element Method
CAD and Finite Element Analysis
MultiGrid.
© Fluent Inc. 1/10/2018L1 Fluids Review TRN Solution Methods.
Paul Heckbert Computer Science Department Carnegie Mellon University
Ph.D. Thesis Numerical Solution of PDEs and Their Object-oriented Parallel Implementations Xing Cai October 26, 1998.
What are Multiscale Methods?
Presentation transcript:

15 Nov B - Introduction to Scientific Computing1 Multigrid Methods and Applications Paul Heckbert Computer Science Department Carnegie Mellon University

15 Nov B - Introduction to Scientific Computing2 Overview 1.What is the multigrid method? 2.High level survey of applications of multigrid methods across science and engineering. (Articles on this are hard to find!) –what is the state of the art? –what are multigrid’s strengths & weaknesses? –what is current research?

15 Nov B - Introduction to Scientific Computing3 Inspiration for Multigrid Method Typical problem: –Solving a PDE over simple domain (e.g. square) –Get sparse system Av=f If we solve iteratively with Gauss-Seidel –initial iterations reduce residual a lot –later iterations yield less benefit –why? Iterations reduce high frequencies in residual Idea: –iterate on coarser grids to reduce lower frequencies

15 Nov B - Introduction to Scientific Computing4 Example: Poisson’s Equation Sweep of Gauss-Seidel “relaxes” each grid value to be the average of its four neighbors plus an f offset Many relaxations required to solve this on a fixed grid. Multigrid solves it on a hierarchy of grids.

15 Nov B - Introduction to Scientific Computing5 Elements of Multigrid Method relax on a given grid a few times coarsen (restrict) a grid refine (interpolate) a grid

15 Nov B - Introduction to Scientific Computing6 A Common Multigrid Schedule Full Multigrid V Cycle: time coarsest grid 1  1 finest grid k  k k/2  k/2... final solution =relax=interpolate=restrict

15 Nov B - Introduction to Scientific Computing7 Some Iterative Methods Gauss-Seidel –converges for all symmetric positive definite A Conjugate Gradient (CG) Method –convergence rate determined by condition number –note that condition number typically larger for finer grids Preconditioned Conjugate Gradient –instead of solving Av=f, solve M -1 Av=M -1 f where M -1 is cheap and M is close to A –often much faster than CG, but conditioner M is problem-dependent Multigrid –convergence rate is independent of condition number, problem size –but algorithm must be tuned for a given problem; not as general as others note: don’t need matrix A in memory – can compute it on the fly!

15 Nov B - Introduction to Scientific Computing8 Cost Comparison on 2-D Poisson Equation, k  k grid, n=k 2 unknowns METHOD COST Gaussian EliminationO(k 6 )= O(n 3 ) Gauss-SeidelO(k 4 logk)= O(n 2 logn) Conjugate GradientO(k 3 )= O(n 1.5 ) FFT/cyclic reductionO(k 2 logk) = O(nlogn) multigridO(k 2 ) = O(n) optimal!

15 Nov B - Introduction to Scientific Computing9 Memory Requirements of Multigrid 2-D: finest grid: k 2 (v & f arrays) k 2 /4 k 2 /16... coarsest grid: 1 total: k 2 (1+1/4+1/16+1/64+...) = 4/3  k 2 Costs only 33% more memory than storing the solution

15 Nov B - Introduction to Scientific Computing10 Critique of Multigrid 1 wo rks well for certain problems –in particular, elliptic PDE's (linear or nonlinear) with smooth boundary –solves a problem with n unknowns in O(n) time constants usually small, e.g. 10 "work units" 1 work unit = the work of one relaxation on the fine grid but multigrid methods are currently several orders of magnitude slower for non-elliptic steady-state (time- independent BV) problems low memory requirements: need mem for v & f on finest grid, plus coarser grids; don’t need A parallelizes easily –(but requires more communication than some other parallel solvers)

15 Nov B - Introduction to Scientific Computing11 Critique of Multigrid 2 less theory than some other methods –it's a bit of a black art requires careful tuning to get it working on a new problem –not a black box, like, say, the conjugate gradient method or Gauss- Seidel –but when it works well, it's often the fastest but other fast methods often require tuning too –to get top performance out of the conjugate gradient method often requires an application-specific preconditioner

15 Nov B - Introduction to Scientific Computing12 History of Multigrid 1964: first paper, Fedorenko, Russia –large constants: ~40,000 work units, no implementation? 1977: Achi Brandt, Israel, made it practical, wrote seminal paper late 70's: Nicolaides, Hackbusch, and others proved convergence for certain PDE's; Brandt proved fast convergence interest took off around 1981 but there was (and still is) much skepticism from some because there was little theory today used to solve PDE's in many disciplines current research: a drive to achieve "textbook efficiency" for general flow simulations (all Mach numbers and Reynolds numbers) somewhat superseded by wavelet methods?

15 Nov B - Introduction to Scientific Computing13 Multigrid Guidelines “multigridders” prefer structured grids grid and relaxation method are the only parts of the method that are highly problem-dependent; restriction and interpolation are generic on complex domains, need extra relaxation steps near boundary –for rough boundary conditions –for concave corners grid can be adaptive: can restrict processing at finer levels to subdomains schedule parameters (how many relaxation steps and V cycles) can be: –fixed –accommodative e.g. software loops until residual at each step is below some tolerance for CFD, align the grid with the boundary and the flow

15 Nov B - Introduction to Scientific Computing14 Brandt’s Research Philosophy To do multigrid research, you should "very gradually increase the complexity of the problems” you attempt "we insist on obtaining for each problem the full efficiency” (e.g. 10 work units) strives for linear time with small constants "stalling numerical processes must be wrong” constants are particularly important when discussing algorithms that are O(n); more than for algorithms that are, say, O(n 2 ) strives for convergence proofs with small constants: “almost all other multigrid theories give estimates which are not quantitative or very unrealistic, rendering them useless in practice”

15 Nov B - Introduction to Scientific Computing15 Computational Fluid Dynamics (CFD) equations –Euler equation - linear, inviscid (no viscosity) –Navier-Stokes equation - nonlinear, models viscosity now possible to simulate flow around an airplane, with engines –first achieved in 1986 –done with multigrid? Reynolds Number (Re) –a measure of the ratio of inertial and viscous forces –Re large => turbulence, difficult simulation –for an airplane, Re ~ 10^7

15 Nov B - Introduction to Scientific Computing16 CFD 2 transonic flow –flow is both below and above speed of sound (Mach no. 1) –=> PDE is elliptic where subsonic and hyperbolic where supersonic high Reynolds number steady state flows => non-elliptic use boundary-fitted structured grids boundary layer tricky –in viscous simulation, flow near surface (of e.g. wing) has high gradient, since flow speed at surface is zero, but speed inches away could be high –you often want the elements (grid quadrilaterals) to be highly stretched (e.g. "aspect ratio" of 4000:1) in boundary layer to get accurate simulations –high aspect ratio slows convergence or complicates the relaxation method

15 Nov B - Introduction to Scientific Computing17 Multigrid Applications 1 computational fluid dynamics (CFD) –application for which multigrid has been most used –weather prediction (whole earth simulations) structured grid generation –use elliptic PDE to define geometry of grid nodes, create grid using multigrid! ill-posed (underdetermined) problems –edge detection in noisy image can find all straight features (lines, edges) in kxk pixel image in O(k log k) time –image segmentation –tomography (i.e. CAT scan) –approximating noisy data with a piecewise smooth function with known or unknown discontinuities

15 Nov B - Introduction to Scientific Computing18 Multigrid Applications 2 integral operators –multiplication by a dense nxn matrix in O(n) time –easy if matrix (or kernel) is smooth; slower if not –n-body force computations gravity molecular interactions thermal radiation –Fast Multipole Method is faster than O(n 2 ) alg. only for n>1000, they say is Brandt's method faster? (unpublished)

15 Nov B - Introduction to Scientific Computing19 Multigrid Applications 3 global optimization –works even if many local minima –"each step can be interpreted as an optimization over a certain subspace" –protein folding constrained optimization –optimal control, e.g. robot motion planning solid mechanics –set up using finite element methods (unstructured grid), not finite difference

15 Nov B - Introduction to Scientific Computing20 Multigrid Applications 4 quantum chemistry –compute eigenfunctions of Schroedinger's eqn. (the PDE governing quantum mechanics) to find electron density functions macroscopic from microscopic –statistical physics, particle physics (QCD) derive macroscopic properties (e.g. nonlinear elasticity) by using multigrid on microscopic level (on atomic forces) –unified wave/ray methods for simulating electromagnetic radiation combine wave model (to simulate diffraction, interference, when wavelength comparable to scale of objects) and ray model (to simulate free flight of photons in air/vacuum) VLSI design –highly nonlinear

15 Nov B - Introduction to Scientific Computing21 Related Methods unstructured multigrid –uses an unstructured grid (irregular topology), not structured one –this complicates relaxation, restriction, & interpolation, but permits solution on complex domains (e.g. around an aircraft wing with flaps) algebraic multigrid –multigrid without the grid –analyze and do clustering on graph implied by matrix A –input is A only -- no high level problem knowledge domain decomposition –divide domain into (possibly overlapping) pieces –solve alternately on each piece, using solution of other pieces as boundary conditions –useful for complex domains, parallelizes easily

15 Nov B - Introduction to Scientific Computing22 References 1 my comments in italics Brandt, 1988, The Weizmann Insitute Research in Multilevel Computation: 1988 Report, Proc. Copper Mtn. Conf. on Multigrid Methods, 1989 (53 pp.) Survey of recent applications. I found this quite thought-provoking. Brandt, 1982, Guide to Multigrid Development, in Hackbusch & Trottenberg, eds., Multigrid Methods, pp Guidelines for multigrid implementers. Long. Brandt, 1997, The Gauss Center Research in Multiscale Scientific Computation, Proc. Copper Mtn. Conf. on Multigrid Methods, on web (50 pp.) More esoteric than 1988 report above. Brandt, 1980, Multilevel Adaptive Computations in Fluid Dynamics, AIAA J., vol. 18, pp Short, fairly readable. Brandt, 1977, Multi-Level Adaptive Solutions to Boundary-Value Problems, Mathematics of Computation, pp The seminal paper on multigrid.

15 Nov B - Introduction to Scientific Computing23 References 2 Wesseling, 1992, An Intro. to Multigrid Methods, chapter 8. Good textbook. Parsons & Hall 1990, The Multigrid Method in Solid Mechanics, Intl. J. for Numer. Meth. in Eng., vol. 29, pp Experiments applying MG to mechanical engineering. Chan, Go, & Zikatanov, 1997, Lecture Notes on Multilevel Methods for Elliptic Problems on Unstructured Grids, 77 pp., State of the art in unstructured multigrid and domain decomposition. Shlomo Ta’asan, CMU Math (conversation) Gary Miller, CMU CS (conversation) Omar Ghattas, CMU CE (conversation)