petsc-3.7.1 2016-05-15
VecGetLocalVector
Maps the local portion of a vector into a vector.
Synopsis
#include "petscvec.h"
#undef __FUNCT__
#define __FUNCT__ "VecGetLocalVector"
PetscErrorCode VecGetLocalVector(Vec v,Vec w)
Collective on v, not collective on w. Many br
Input parameter
v -The vector for which the local vector is desired. Many br
Output parameter
w -Upon exit this contains the local vector. Many br
Many br
Notes
This function is similar to VecGetArray() which maps the local Many brportion into a raw pointer. VecGetLocalVector() is usually about as Many brefficient as VecGetArray() but in certain circumstances Many brVecGetLocalVector() can be much more efficient than VecGetArray(). Many brThis is because the construction of a contiguous array representing Many brthe vector data required by VecGetArray() can be an expensive Many broperation for certain vector types. For example, for GPU vectors Many brVecGetArray() requires that the data between device and host is Many brsynchronized. Many br
See Also
VecRestoreLocalVector(), VecGetLocalVectorRead(), VecGetArrayRead(), VecGetArray()
Level:beginner
Location:src/vec/vec/interface/rvector.c
Index of all Vec routines
Table of Contents for all manual pages
Index of all manual pages