DMSwarmDestroyGlobalVectorFromFields — PETSc 3.23.0 documentation

Skip to main content
`Ctrl`+`K`

# DMSwarmDestroyGlobalVectorFromFields

Destroys the `Vec` object which share the array associated with a given field set

## Synopsis

    #include "petscdmswarm.h"
    PetscErrorCode DMSwarmDestroyGlobalVectorFromFields(DM dm, PetscInt Nf, const char *fieldnames[], Vec *vec)

Collective

## Input Parameters

- dm - a `DMSWARM`

- Nf - the number of fields

- fieldnames - the textual names given to the registered fields

## Output Parameter

- vec - the vector

## See Also

`DM`, `DMSWARM`, `DMSwarmRegisterPetscDatatypeField()`, `DMSwarmCreateGlobalVectorFromField()`

## Level

beginner

## Location

src/dm/impls/swarm/swarm.c

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