DMSTAG#

"stag" - A DM object for working with a staggered grid (or mesh) or a structured cell complex.

Notes#

This implementation parallels the DMDA implementation in many ways, but allows degrees of freedom to be associated with all “strata” in a logically-rectangular grid. That is, points, edges, faces, and cells (called elements).

Each stratum can be characterized by the dimension of the entities (“points”, to borrow the DMPLEX terminology), from 0- to 3-dimensional.

In some cases this numbering is used directly, for example with DMStagGetDOF(). To allow easier reading and to some extent more similar code between different-dimensional implementations of the same problem, we associate canonical names for each type of point, for each dimension of DMStag.

  • 1-dimensional DMSTAG objects have vertices (0D) and elements (cells) (1D).

  • 2-dimensional DMSTAG objects have vertices (0D), faces (1D), and elements (cells) (2D).

  • 3-dimensional DMSTAG objects have vertices (0D), edges (1D), faces (2D), and elements (cells) (3D).

This naming is reflected when viewing a DMSTAG object with DMView(), and in forming convenient options prefixes when creating a decomposition with DMCreateFieldDecomposition().

For a DMSTAG each point on the same dimension has the same number of dof associated with it. For example, all cell points may have a single degree of freedom representing a pressure. This uniformity makes it possible to more efficiently “index into” (using a computable offset) vectors and arrays than for DMPLEX where each point may have a different number of degrees of freedom so the each offset (as well as the dof`) must be explicitly stored.

See Also#

DMSTAG: Staggered, Structured Grid, DM, DMPRODUCT, DMDA, DMPLEX, DMStagCreate1d(), DMStagCreate2d(), DMStagCreate3d(), DMType, DMCreate(), DMSetType(), DMStagVecSplitToDMDA()

Level#

beginner

Location#

src/dm/impls/stag/stag.c


Index of all DMStag routines
Table of Contents for all manual pages
Index of all manual pages