Skip to main content
`Ctrl`+`K`

# DMSwarmGetCellDMActive

Returns the active cell `DM` for a `DMSWARM`

## Synopsis

    #include "petscdmswarm.h"
    PetscErrorCode DMSwarmGetCellDMActive(DM sw, DMSwarmCellDM *celldm)

Collective

## Input Parameter

- sw - a `DMSWARM`

## Output Parameter

- celldm - the active `DMSwarmCellDM`

## See Also

`DM`, `DMSWARM`, `DMSwarmCellDM`, `DMSwarmSetType()`, `DMSwarmAddCellDM()`, `DMSwarmSetCellDM()`, `DMSwarmMigrate()`

## Level

beginner

## Location

src/dm/impls/swarm/swarm.c

## Examples

src/ksp/ksp/tutorials/ex70.c
src/ts/tutorials/ex77.c

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