Checking my assumptions on the use of DMMG in SNES ex19.c

Barry Smith bsmith at
Sat Mar 8 19:10:43 CST 2008


     This is 100% correct. To prevent confusion I would suggest
the final sentence be: When DMMGSolve is called, PETSc will use its  
default non-linear solver
with its default geometric multigrid solver for the linear system
to attempt to solve F(u) = 0.


On Mar 8, 2008, at 4:01 PM, Aron Ahmadia wrote:

> Hi all,
> I'm preparing a multigrid lecture for Tuesday that will be motivated
> by a demonstration of PETSc using Multigrid to solve the thermally and
> lid-driven cavity flow problem using the DMMG solver framework.
> Since only about 20-30 minutes of time will be spent to describing
> this, I want to make sure my descriptions are both succinct and
> accurate.
> I'd like to describe how DMMG allows a user to rapidly solve (some)
> non-linear problems using multigrid if she's willing to use finite
> differencing to automatically generate her Jacobian matrix at each
> stage.
> Is the following statement correct?  If not, how would you fix it,
> particularly in terms of describing the techniques used in ex19.c
> "To use DMMG to solve a given non-linear PDE using multigrid and
> finite-differencing to automatically generate the Jacobian operator,
> the user is responsible for specifying the coarsest grid that the
> problem will be solved on as well as the number of levels of multigrid
> which will be applied, with the resolution doubling for each level of
> multigrid.
> For example, to solve a non-linear problem on a 2-D grid with a
> fine-grid resolution of 256x256 and 3 levels of multigrid, the user
> creates a DMMG object with 3 levels, then calls DMMGSetDM with a DA
> object of resolution 64x64.
> The user is also responsible for providing SNESLocal, a programmatic
> function that evalutes the mathematical function F(u) locally using
> field values from the stencil specified in the DMMG creation routine.
> When DMMGSolve is called, PETSc will use its default non-linear solver
> to attempt to solve F(u) = 0.
> "
> ~A

More information about the petsc-users mailing list