:orphan:
# DMStagSetUniformCoordinatesExplicit
set `DMSTAG` coordinates to be a uniform grid, storing all values 
## Synopsis
```
PetscErrorCode DMStagSetUniformCoordinatesExplicit(DM dm, PetscReal xmin, PetscReal xmax, PetscReal ymin, PetscReal ymax, PetscReal zmin, PetscReal zmax)
```
Collective


## Input Parameters

- ***dm -*** the `DMSTAG` object
- ***xmin -*** minimum global coordinate value in the x direction
- ***xmax -*** maximum global coordinate values in the x direction
- ***ymin -*** minimum global coordinate value in the y direction
- ***ymax -*** maximum global coordinate value in the y direction
- ***zmin -*** minimum global coordinate value in the z direction
- ***zmax -*** maximum global coordinate value in the z direction





## Notes
`DMSTAG` supports 2 different types of coordinate `DM`: either another `DMSTAG`, or a `DMPRODUCT`.
If the grid is orthogonal, using `DMPRODUCT` should be more efficient.

Arguments corresponding to higher dimensions are ignored for 1D and 2D grids.

See the manual page for `DMStagSetUniformCoordinates()` for information on how
coordinates for dummy cells outside the physical domain boundary are populated.


## See Also
 [](ch_stag), `DMSTAG`, `DMStagSetUniformCoordinates()`, `DMStagSetUniformCoordinatesProduct()`, `DMStagSetCoordinateDMType()`

## Level
beginner

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/impls/stag/stagutils.c.html#DMStagSetUniformCoordinatesExplicit">src/dm/impls/stag/stagutils.c</A>

## Examples
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/impls/stag/tutorials/ex1.c.html">src/dm/impls/stag/tutorials/ex1.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/impls/stag/tutorials/ex3.c.html">src/dm/impls/stag/tutorials/ex3.c</A><BR>

## Implementations

<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/impls/stag/stag1d.c.html#DMStagSetUniformCoordinatesExplicit_1d">DMStagSetUniformCoordinatesExplicit_1d in src/dm/impls/stag/stag1d.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/impls/stag/stag2d.c.html#DMStagSetUniformCoordinatesExplicit_2d">DMStagSetUniformCoordinatesExplicit_2d in src/dm/impls/stag/stag2d.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/dm/impls/stag/stag3d.c.html#DMStagSetUniformCoordinatesExplicit_3d">DMStagSetUniformCoordinatesExplicit_3d in src/dm/impls/stag/stag3d.c</A><BR>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/dm/impls/stag/stagutils.c)


[Index of all DMStag routines](index.md)  
[Table of Contents for all manual pages](/manualpages/index.md)  
[Index of all manual pages](/manualpages/singleindex.md)  
