DMSwarmCreateLocalVectorFromFields#
Creates a Vec
object sharing the array associated with a given field set
Synopsis#
#include "petscdmswarm.h"
PetscErrorCode DMSwarmCreateLocalVectorFromFields(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
Notes#
The vector must be returned using a matching call to DMSwarmDestroyLocalVectorFromField().
This vector is copyin-copyout, rather than a direct pointer like DMSwarmCreateLocalVectorFromField()
See Also#
DM
, DMSWARM
, DMSwarmRegisterPetscDatatypeField()
, DMSwarmDestroyLocalVectorFromField()
Level#
beginner
Location#
Index of all DMSwarm routines
Table of Contents for all manual pages
Index of all manual pages