VecCreateMPI#
Creates a parallel vector.
Synopsis#
#include "petscvec.h"
PetscErrorCode VecCreateMPI(MPI_Comm comm, PetscInt n, PetscInt N, Vec *v)
Collective
Input Parameters#
comm - the MPI communicator to use
n - local vector length (or
PETSC_DECIDE
to have calculated ifN
is given)N - global vector length (or
PETSC_DETERMINE
to have calculated ifn
is given)
Output Parameter#
v - the vector
Notes#
It is recommended to use VecCreateFromOptions()
instead of this routine
Use VecDuplicate()
or VecDuplicateVecs()
to form additional vectors of the
same type as an existing vector.
See Also#
Vectors and Parallel Data, Vec
, VecType
, VecCreateSeq()
, VecCreate()
, VecDuplicate()
, VecDuplicateVecs()
, VecCreateGhost()
,
VecCreateMPIWithArray()
, VecCreateGhostWithArray()
, VecMPISetGhost()
Level#
intermediate
Location#
Examples#
src/tao/bound/tutorials/plate2.c
Index of all Vec routines
Table of Contents for all manual pages
Index of all manual pages