petsc-3.7.1 2016-05-15
VecGetArray3dRead
Returns a pointer to a 3d contiguous array that contains this processor's portion of the vector data. You MUST call VecRestoreArray3dRead() when you no longer need access to the array.
Synopsis
#include "petscvec.h"
PetscErrorCode VecGetArray3dRead(Vec x,PetscInt m,PetscInt n,PetscInt p,PetscInt mstart,PetscInt nstart,PetscInt pstart,PetscScalar ***a[])
Logically Collective Many br
Input Parameter
| x | - the vector Many br |
| m | - first dimension of three dimensional array Many br |
| n | - second dimension of three dimensional array Many br |
| p | - third dimension of three dimensional array Many br |
| mstart | - first index you will use in first coordinate direction (often 0) Many br |
| nstart | - first index in the second coordinate direction (often 0) Many br |
| pstart | - first index in the third coordinate direction (often 0) Many br |
Output Parameter
a -location to put pointer to the array Many br
Many br
Notes
For a vector obtained from DMCreateLocalVector() mstart, nstart, and pstart are likely Many brobtained from the corner indices obtained from DMDAGetGhostCorners() while for Many brDMCreateGlobalVector() they are the corner indices from DMDAGetCorners(). In both cases Many brthe arguments from DMDAGet[Ghost]Corners() are reversed in the call to VecGetArray3dRead(). Many br
For standard PETSc vectors this is an inexpensive call; it does not copy the vector values. Many br
See Also
VecGetArray(), VecRestoreArray(), VecGetArrays(), VecGetArrayF90(), VecPlaceArray(),
VecRestoreArray2d(), DMDAVecGetarray(), DMDAVecRestoreArray(), VecGetArray3d(), VecRestoreArray3d(), Many brVecGetArray1d(), VecRestoreArray1d(), VecGetArray4d(), VecRestoreArray4d() Many br
Level:developer
Location:src/vec/vec/interface/rvector.c
Index of all Vec routines
Table of Contents for all manual pages
Index of all manual pages